curl --request POST \
--url https://api.getenso.ai/invoices \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"contractPlanId": "<string>",
"invoiceData": {
"date": "2023-10-01",
"fromDate": "2023-10-01",
"toDate": "2023-10-31"
},
"invoiceItems": [
{
"title": "Item Title",
"description": "Item description",
"quantity": 1,
"price": 100,
"fromDate": "2023-10-01",
"toDate": "2023-10-31"
}
]
}
'{
"status": "error",
"message": "Forbidden",
"errors": [
{}
]
}Create a new invoice
curl --request POST \
--url https://api.getenso.ai/invoices \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"contractPlanId": "<string>",
"invoiceData": {
"date": "2023-10-01",
"fromDate": "2023-10-01",
"toDate": "2023-10-31"
},
"invoiceItems": [
{
"title": "Item Title",
"description": "Item description",
"quantity": 1,
"price": 100,
"fromDate": "2023-10-01",
"toDate": "2023-10-31"
}
]
}
'{
"status": "error",
"message": "Forbidden",
"errors": [
{}
]
}InvoiceService:createInvoiceJWT bearer token obtained from POST /auth/system-login using your client credentials.
Invoice data that needs to be created