API to delete invoice by invoice id
Request
Use the Access Token generated with user type as Sub-Account (OR) Private Integration Token of Sub-Account.
Provide your bearer token in the Authorization header when making requests to protected resources.
Example: Authorization: Bearer 123
Provide your bearer token in the Authorization header when making requests to protected resources.
Use the Access Token generated with user type as Agency (OR) Private Integration Token of Agency.
Provide your bearer token in the Authorization header when making requests to protected resources.
Example: Authorization: Bearer 123
Provide your bearer token in the Authorization header when making requests to protected resources.
Path Parameters
invoiceId
stringInvoice Id
Examples:
6578278e879ad2646715ba9c
Body
altId
stringlocation Id / company Id based on altType
Example:
6578278e879ad2646715ba9c
altType
stringAlt Type
Allowed value:
location
Example:
location
Headers
Authorization
stringAccess Token
Example:
Bearer 9c48df2694a849b6089f9d0d3513efe
Version
stringAPI Version
Allowed value:
2021-07-28
Responses
200
Successful response
Body
_id
stringInvoice Id
Example:
6578278e879ad2646715ba9c
status
stringInvoice Status
Allowed values:
draftsentpayment_processingpaidvoidpartially_paid
Example:
draft
liveMode
booleanLive Mode
Example:
false
amountPaid
numberAmount Paid
Example:
0
altId
stringLocation Id or Agency Id
Example:
6578278e879ad2646715ba9c
altType
stringAllowed value:
location
name
stringName of the invoice
Example:
New Invoice
businessDetails
objectBusiness Details
Example:
{"name":"Alex","address":{"addressLine1":"9931 Beechwood","city":"St. Houston","state":"TX","countryCode":"USA","postalCode":"559-6993"},"phoneNo":"+1-214-559-6993","website":"www.example.com"}
invoiceNumber
numberInvoice Number
Example:
19
currency
stringCurrency
Example:
USD
contactDetails
objectContact Details
Example:
{"id":"c6tZZU0rJBf30ZXx9Gli","phoneNo":"+1-214-559-6993","email":"alex@example.com","customFields":[],"name":"Alex","address":{"countryCode":"US"}}
issueDate
stringIssue date in YYYY-MM-DD format
Example:
2023-01-01
dueDate
stringDue date in YYYY-MM-DD format
Example:
2023-01-01
discount
objectDiscount
Example:
{"type":"percentage","value":0}
invoiceItems
array[string]Invoice Items
Example:
[{"taxes":[],"_id":"c6tZZU0rJBf30ZXx9Gli","productId":"c6tZZU0rJBf30ZXx9Gli","priceId":"c6tZZU0rJBf30ZXx9Gli","currency":"USD","name":"Macbook Pro","qty":1,"amount":999}]
total
numberTotal Amount
Example:
999
title
stringTitle
Example:
INVOICE
amountDue
numberTotal Amount Due
Example:
999
createdAt
stringcreated at
Example:
2023-12-12T09:27:42.355Z
updatedAt
stringupdated at
Example:
2023-12-12T09:27:42.355Z
automaticTaxesEnabled
booleanAutomatic taxes enabled for the Invoice
Example:
true
automaticTaxesCalculated
booleanIs Automatic taxes calculated for the Invoice items
Example:
true
paymentSchedule
objectsplit invoice into payment schedule summing up to full invoice amount
422
Unprocessable Entity
Body
statusCode
number
Example:
422
message
array[string]
Example:
["Unprocessable Entity"]
error
string
Example:
Unprocessable Entity
401
Unauthorized
Body
statusCode
number
Example:
401
message
string
Example:
Invalid token: access token is invalid
error
string
Example:
Unauthorized
400
Bad Request
Body
statusCode
number
Example:
400
message
string
Example:
Bad Request