Invoice

Retrieves the collection of Invoice resources.

Retrieves the collection of Invoice resources.

SecurityBearer
Request
query Parameters
page
integer
Default: 1

The collection page number

itemsPerPage
integer >= 0
Default: 30

The number of items per page

createdAt[before]
string
createdAt[strictly_before]
string
createdAt[after]
string
createdAt[strictly_after]
string
createdAt
string
downloaded
boolean
direction
string
Enum: "outgoing" "incoming"
documentDate[before]
string
documentDate[strictly_before]
string
documentDate[after]
string
documentDate[strictly_after]
string
documentNumber
string
senderName
string
senderName[]
Array of strings
senderId
string
senderId[]
Array of strings
recipientName
string
recipientName[]
Array of strings
recipientId
string
recipientId[]
Array of strings
sortBy[createdAt]
string
Enum: "asc" "desc"
sortBy[documentDate]
string
Enum: "asc" "desc"
sortBy[senderName]
string
Enum: "asc" "desc"
sortBy[recipientName]
string
Enum: "asc" "desc"
Responses
200

Invoice collection

get/invoices
Request samples
Response samples
{
  • "hydra:member": [
    ],
  • "hydra:totalItems": 0,
  • "hydra:view": {
    },
  • "hydra:search": {
    }
}

Mark the invoices as downloaded

Mark the document as downloaded. This is useful to keep track of the documents that have been received by the user.

SecurityBearer
Request
Request Body schema: application/json
required

The new Invoice resource

downloaded
required
boolean
uuids
required
Array of strings
Responses
204

Invoice resource created

400

Invalid input

422

Unprocessable entity

post/invoices/downloaded
Request samples
application/json
{
  • "downloaded": true,
  • "uuids": [
    ]
}
Response samples
null

Import a new incoming invoice in UBL format

Import a received UBL 2.1 invoice in either the original XML format or the JSON transposition. You must send the XML or JSON as the request body along with the right Content-Type header (application/xml or application/json).

SecurityBearer
Request
Request Body schema:
required

The new Invoice resource

any
Responses
201

Invoice resource created

400

Invalid input

422

Unprocessable entity

post/invoices/incoming/ubl
Request samples
null
Response samples
{
  • "uuid": "string",
  • "direction": "outgoing",
  • "format": "UBL 2.1 XML",
  • "number": "string",
  • "date": "string",
  • "sender": {
    },
  • "recipient": {
    },
  • "createdAt": "string",
  • "downloaded": true,
  • "peppolMessage": {
    }
}

Create a new invoice in UBL format

Send a UBL 2.1 invoice in either the original XML format or the JSON transposition. You must send the XML or JSON as the request body along with the right Content-Type header (application/xml or application/json).

Optionally you can send the X-Validation-Rule: {validation-rule-code} where {validation-rule-code} is one of the available validation rules you can use. You can retrieve a list of the available validation rules using the API GET /validation-rules. By default the validation rule is autodetected using the latest rule available for the given document.

See here for more information about UBL.

SecurityBearer
Request
Request Body schema:
required

The new Invoice resource

any
Responses
201

Invoice resource created

400

Invalid input

422

Unprocessable entity

post/invoices/outgoing/ubl
Request samples
null
Response samples
{
  • "uuid": "string",
  • "direction": "outgoing",
  • "format": "UBL 2.1 XML",
  • "number": "string",
  • "date": "string",
  • "sender": {
    },
  • "recipient": {
    },
  • "createdAt": "string",
  • "downloaded": true,
  • "peppolMessage": {
    }
}

Retrieves a Invoice resource.

Retrieves a Invoice resource.

SecurityBearer
Request
path Parameters
uuid
required
string

Resource identifier

Responses
200

Invoice resource

404

Resource not found

get/invoices/{uuid}
Request samples
Response samples
{
  • "@context": "string",
  • "@id": "string",
  • "@type": "string",
  • "uuid": "string",
  • "direction": "outgoing",
  • "format": "UBL 2.1 XML",
  • "number": "string",
  • "date": "string",
  • "sender": {
    },
  • "recipient": {
    },
  • "createdAt": "string",
  • "downloaded": true,
  • "peppolMessage": {
    }
}

Get the printed version of the document

If you specify header Accept equal to 'application/pdf' or 'text/html' you will receive a 302 redirect response with the Location header pointing to the downloadable file. Additionally you get the URL to the downloaded file in the JSON response body.

If you specify header Accept equal to 'application/json' you will receive 200 status code and the JSON response containing the URL to follow manually.

You can avoid the 302 redirect response by sending header X-WithRedirect: false

SecurityBearer
Request
path Parameters
uuid
required
string
Responses
200

Invoice resource

404

Resource not found

get/invoices/{uuid}/print
Request samples

Get the original source document

Retrieves a Invoice resource.

SecurityBearer
Request
path Parameters
uuid
required
string
Responses
200

Invoice resource

404

Resource not found

get/invoices/{uuid}/source
Request samples
Response samples
No sample