Documents
API endpoints
Authentication: endpoints listed in this page require header authentication with a user token.
List documents
GET
https://{domain}.biapi/pro/2.0/users/{userId}/documents
List documents associated with a user.
Path Parameters
userId*
Integer or "me"
ID of the related user.
Query Parameters
id_type
Integer
Filter with a document type.
min_amount
Decimal
Minimal (inclusive) amount.
max_amount
Decimal
Maximum (inclusive) amount.
limit*
Integer
Number of documents to return. The maximum value is 1000.
Response body: DocumentsList object
Get a document
GET
https://{domain}.biapi/pro/2.0/documents/{documentId}
Get a single document by ID.
Path Parameters
documentId*
Integer or "me"
ID of the document.
Response body: Document object
Document resources support update operations to edit metadata:
Update a document
POST
https://{domain}.biapi/pro/2.0/documents/{documentId}
Update a single document by ID.
Path Parameters
documentId*
Integer
ID of the document.
Request Body
id_type
Integer
New type of the document.
date
Date
New date of the document.
duedate
Date
New due date of the document.
total_amount
Decimal
New total amount of the document.
untaxed_amount
Decimal
New untaxed amount of the document.
vat
Decimal
New VAT amount of the document.
income
Boolean
Is an income or an outcome.
name
String
New name of the document.
Response body: Document object
Data model
DocumentsList object
documents
List of documents.
first_date
Date
Minimum available date for results.
last_date
Date
Maximum available date for results.
result_min_date
Date
Minimum date of results in the current response.
result_max_date
Date
Maximum date of results in the current response.
Document object
id
Integer
ID of the document.
id_user
Integer
ID of the related user.
id_subscription
Integer or null
ID of the related subscription.
id_type
Integer or null
ID of the related document type.
id_file
Integer or null
ID of the related file.
id_thumbnail
Integer or null
ID of the related thumbnail.
name
String or null
date
DateTime or null
timestamp
DateTime
The moment when this document has been created.
thumb_url
String or null
url
String or null
duedate
Date or null
total_amount
Decimal or null
untaxed_amount
Decimal or null
vat
Decimal or null
income
Boolean or null
readonly
Boolean
number
String or null
issuer
String or null
last_update
DateTime or null
has_file_on_website
Boolean
Whether the file is available on website.
currency
Document currency.
Last updated