Creating an invoice marked as paid

kwisatz
Contributor
Contributor

From the API documentation, I understand that I first have to create an invoice in draft state and then use the send endpoint to actually send it.

However, the create draft invoice endpoint shows support for a parameter named status which can take e.g. the value MARKED_AS_PAID. 

So, if I use the create draft invoice endpoint to create a draft invoice, setting the status to MARKED_AS_PAID from the get-go, do I still need to send it?

What will the status of the invoice be after I sent it?

Login to Me Too
1 ACCEPTED SOLUTION

Accepted Solutions
Solved

Nexus_Software
Contributor
Contributor

The "status""MARKED_AS_PAID" is a response parameter from the Show invoice details API call. It's a result of payments made using the External payment Type.

The payment type options are:

  • PAYPAL. The payment type is PayPal.
  • EXTERNAL. The payment type is an external cash or a check payment.

 

 

View solution in original post

Login to Me Too
9 REPLIES 9

Nexus_Software
Contributor
Contributor

Hello @kwisatz ,

 

Yes, to move the invoice from a draft to payable state, you must send the invoice. Your question is understandable considering the ability to post a status of MARKED_AS_PAID. If the invoice is not in a payable state this parameter is ignored.

 

Thank you.

 

Powered by Custom Software : NexWebSites.com
PayPal Developers

Login to Me Too

kwisatz
Contributor
Contributor

So then, what is the correct workflow to set an invoice to status MARKED_AS_PAID?

 

  1. Create a draft
  2. Send
  3. Update 

 

?

Login to Me Too

Nexus_Software
Contributor
Contributor

After sending, you can Record a payment for an invoice with the payment amount to record against the invoice. If you omit this parameter, the total invoice amount is marked as paid. This amount cannot exceed the amount due.

Login to Me Too

kwisatz
Contributor
Contributor

Thank you. But will the status then not become PAID rather than MARKED_AS_PAID ? Not that it matters much, but I'd like to understand how I can apply a status different from DRAFT and SEND to an invoice, given that they exist.

Login to Me Too
Solved

Nexus_Software
Contributor
Contributor

The "status""MARKED_AS_PAID" is a response parameter from the Show invoice details API call. It's a result of payments made using the External payment Type.

The payment type options are:

  • PAYPAL. The payment type is PayPal.
  • EXTERNAL. The payment type is an external cash or a check payment.

 

 

Login to Me Too

kwisatz
Contributor
Contributor

To me, this looks like a request parameter.

Invoices.png

 

Anyhow, thanks @Nexus_Software for your help so far, I guess I'll just experiment a little with the Sandbox to figure it all out.

Login to Me Too

Nexus_Software
Contributor
Contributor

Yes, it does look like request parameters. In every case the status gets ignored.

 

 

Login to Me Too

kwisatz
Contributor
Contributor

Oh, didn't see that. But i's not the first time I found the documentation really confusing. 

Login to Me Too

Nexus_Software
Contributor
Contributor

You're right. You may have found some invalid documentation, if not, it's surely confusing.

Login to Me Too

Haven't Found your Answer?

It happens. Hit the "Login to Ask the community" button to create a question for the PayPal community.