POST /v2/invoices/{invoice_id}/publish
Publishes the specified draft invoice.
After an invoice is published, Square follows up based on the invoice configuration. For example, Square sends the invoice to the customer's email address, charges the customer's card on file, or does nothing. Square also makes the invoice available on a Square-hosted invoice page.
The invoice status
also changes from DRAFT
to a status
based on the invoice configuration. For example, the status changes to UNPAID
if
Square emails the invoice or PARTIALLY_PAID
if Square charge a card on file for a portion of the
invoice amount.
Servers
- https://connect.squareup.com
Path parameters
Name | Type | Required | Description |
---|---|---|---|
invoice_id |
String | Yes |
The ID of the invoice to publish. |
Request headers
Name | Type | Required | Description |
---|---|---|---|
Content-Type |
String | Yes |
The media type of the request body.
Default value: "application/json" |
Request body fields
Name | Type | Required | Description |
---|---|---|---|
version |
Integer | Yes |
The version of the invoice to publish. This must match the current version of the invoice; otherwise, the request is rejected. |
idempotency_key |
String | No |
A unique string that identifies the For more information, see Idempotency. |
How to start integrating
- Add HTTP Task to your workflow definition.
- Search for the API you want to integrate with and click on the name.
- This loads the API reference documentation and prepares the Http request settings.
- Click Test request to test run your request to the API and see the API's response.