Skip to main content

Invoices

Create New Invoice

post /businesses/:urlKey/invoices

This endpoint allows you to create an invoice

Path Params

urlKey - will be provided by us

Headers

NameTypeValue Description
Content-Type *stringapplication-json
Authorization *stringBearer <jwt>

Body

NameTypeValue Description
invoiceTitlestringInvoice Title
invoiceSubTitlestringInvoice Subtitle
contactobjectContact Details
contact.phonestringphone of contact
contact.emailstringemail of contact
invoiceNumberstringInvoice number - must be unique among your invoices. If not passed in the API call, invoice number will auto-incremented from the last invoice. If the last number is APP-2020-0004 next will be APP-2020-0005
invoiceDatestringISO 8601 Formatted Date String. If not provided, current timestamp will be used.
dueDatestringISO 8601 Formatted Date String
invoiceTypestring (enum)INVOICE -> Tax Invoice
BOS -> Invoice/Bill without tax
currencystringISO 4217 Currency Code -> Default INR
billedTo *objectCustomer's billing details
billedTo.name *stringCustomer's Name
billedTo.streetstringCustomer's String Address
billedTo.pincodestringCustomer's Zip/Postal code
billedTo.gstStatestring(Required Only for India) Vendor's gst state code
billedTo.statestringCustomer's State or province (Ignored for India)
billedTo.country *stringISO 3166-1 alpha-2 Country code
billedTo.panNumberstringPAN (India Only)
billedTo.gstinstringGSTIN Number (India Only)
billedTo.phonestringCustomer's Phone in international format, example - +91 97394 32668
billedTo.emailemailCustomer's email
billedByobjectVendor's billing details -> In same format as billedTo
items *array[object]Invoice line items array
items[].name *stringLine item name
items[].rate *numberunit price of line item
items[].quantity *numbertotal quantity sold of line item
items[].gstRate
or items[].taxRate
numbertax rate if applicable
emailobjectAdd if email should be sent after invoice creation to specified recipients
email.toobjectMain recipient of email
email.to.namestringName of main recipient
email.to.emailemailEmail of main recipient
email.ccarray[object]email CC list
email.cc[].namestringName of recipient
email.cc[].emailemailEmail of recipient

Find Invoices

get /businesses/:urlKey/invoices

This endpoint allows you to find created invoices

Path Params

urlKey - will be provided by us

Headers

NameTypeValue Description
Content-Type *stringapplication-json
Authorization *stringBearer <jwt>

Query Prams

Optinal - Can be used for limiting results

NameTypeValue Description
$limitnumberwill return only the number of results you specify
$skipnumberwill skip the specified number of results.
$sortobjectwill sort based on the object you provide.
$sort[createdAt]numbersort order on created date (1 ascending, -1 descending)
$sort[invoiceNumber]numbersort order on invoice number (1 ascending, -1 descending)
$sort[invoiceDate]numbersort order on invoice date (1 ascending, -1 descending)

Get Invoice

get /businesses/:urlKey/invoices/:invoiceId

This endpoint allows you to get a invoice via invoiceId (_id)

Path Params

urlKey - will be provided by us

invoiceId - unique id of an invoice. (_id returned in create response or find response)

Headers

NameTypeValue Description
Content-Type *stringapplication-json
Authorization *stringBearer <jwt>