Skip to main content
POST
/
api
/
sale-invoices
/
{id}
/
generate-link
Generate sharable sale invoice link (private or public)
curl --request POST \
  --url https://api.example.com/api/sale-invoices/{id}/generate-link \
  --header 'Authorization: <authorization>' \
  --header 'organization-id: <organization-id>'
{
  "link": "http://localhost:3000/payment/123e4567-e89b-12d3-a456-426614174000"
}

Headers

Authorization
string
required

Value must be 'Bearer ' where is an API key prefixed with 'bc_' or a JWT token.

Example:

"Bearer bc_1234567890abcdef"

organization-id
string
required

Required if Authorization is a JWT token. The organization ID to operate within.

Path Parameters

id
number
required

The sale invoice id

Response

201 - application/json

The link has been generated successfully.

Sharable payment link for the sale invoice

Example:

"http://localhost:3000/payment/123e4567-e89b-12d3-a456-426614174000"