About Bill
A Bill represents an amount owed for goods or services provided by a Vendor. Nested BillLineItem
objects record the details of the good or service included within a Bill. Each line item can be assigned to either a Chart Of Account or a product/service Item along with additional Account Tracking.
If a bill requires review for approval a Bill Approver is associated through Approval APIs. The amount owed on a bill can be reduced by application of a Vendor Credit. Remaining amount owed is recorded or charged via SentPay.
Partner-specific parameters
These are read-only, generated by the PayBills request.
payFromBankAccountId
- This parameter references the BankAccount used to PayBillspayFromChartOfAcccountId
- This parameter highlights the ChartOfAccount assigned to BankAccount used to PayBills
Create
Request
<API_URL_EndPoint>/Crud/Create/Bill.json
data={
"obj" : {
"entity" : "Bill",
"isActive" : "1",
"vendorId" : "00901FABIIZFVKV2pzsy",
"invoiceNumber" : "14800",
"invoiceDate" : "2021-12-05",
"dueDate" : "2021-12-05",
"glPostingDate" : "2021-12-05",
"description" : "Purchase for a new band",
"poNumber" : "1122",
"billLineItems" : [ {
"entity" : "BillLineItem",
"amount" : 1189.99,
"chartOfAccountId" : "0ca01AJKBYXPHRFFdgng",
"departmentId" : "0de01ORPHXZXIHFPazci",
"locationId" : "loc01ZCLEVLXDQRB9z1o",
"jobId" : "job01HCOSIFZPZBFczyc",
"customerId" : "0cu01WIMZDDXALNZhm7p",
"jobBillable" : true,
"description" : "",
"itemId" : "0ii01YCDSBIDTPTJbhcb",
"quantity" : 1,
"unitPrice" : 1189.99,
"employeeId" : "emp01OVBLNBWSHBP89kw",
"actgClassId" : "cls01NFJTPXLWTCW8qc5"
}, {
"entity" : "BillLineItem",
"amount" : 849.99,
"chartOfAccountId" : "0ca01AJKBYXPHRFFdgng",
"departmentId" : "0de01ORPHXZXIHFPazci",
"locationId" : "loc01ZCLEVLXDQRB9z1o",
"jobId" : "job01HCOSIFZPZBFczyc",
"customerId" : "0cu01WIMZDDXALNZhm7p",
"jobBillable" : true,
"description" : "",
"itemId" : "0ii01WBHUZZJGNDTbv0o",
"quantity" : 1,
"unitPrice" : 849.99,
"employeeId" : "emp01OVBLNBWSHBP89kw",
"actgClassId" : "cls01MBCYMNEBCGO8qb2"
} ]
}
}
Response
{
"response_status" : 0,
"response_message" : "Success",
"response_data" : {
"entity" : "Bill",
"id" : "00n01EYSCERXCUT3ybo9",
"isActive" : "1",
"vendorId" : "00901FABIIZFVKV2pzsy",
"invoiceNumber" : "14800",
"approvalStatus" : "0",
"invoiceDate" : "2021-12-05",
"dueDate" : "2021-12-05",
"glPostingDate" : "2021-12-05",
"amount" : 2039.98,
"scheduledAmount" : 0.00,
"paidAmount" : null,
"dueAmount" : 2039.98,
"paymentStatus" : "1",
"description" : "Purchase for a new band",
"poNumber" : "1122",
"createdTime" : "2021-12-09T16:00:43.000+0000",
"updatedTime" : "2021-12-09T16:04:52.000+0000",
"payFromBankAccountId" : "00000000000000000000",
"payFromChartOfAccountId" : "00000000000000000000",
"billLineItems" : [ {
"entity" : "BillLineItem",
"id" : "bli01NTNFBQQEMF43qvu",
"billId" : "00n01EYSCERXCUT3ybo9",
"amount" : 1189.99,
"chartOfAccountId" : "0ca01AJKBYXPHRFFdgng",
"departmentId" : "0de01ORPHXZXIHFPazci",
"locationId" : "loc01ZCLEVLXDQRB9z1o",
"jobId" : "job01HCOSIFZPZBFczyc",
"customerId" : "0cu01WIMZDDXALNZhm7p",
"jobBillable" : true,
"description" : null,
"createdTime" : "2021-12-09T16:00:43.000+0000",
"updatedTime" : "2021-12-09T16:00:43.000+0000",
"lineType" : "2",
"itemId" : "0ii01YCDSBIDTPTJbhcb",
"quantity" : 1,
"unitPrice" : 1189.99,
"employeeId" : "emp01OVBLNBWSHBP89kw",
"actgClassId" : "cls01NFJTPXLWTCW8qc5"
}, {
"entity" : "BillLineItem",
"id" : "bli01HATUZKIMGP43qvv",
"billId" : "00n01EYSCERXCUT3ybo9",
"amount" : 849.99,
"chartOfAccountId" : "0ca01AJKBYXPHRFFdgng",
"departmentId" : "0de01ORPHXZXIHFPazci",
"locationId" : "loc01ZCLEVLXDQRB9z1o",
"jobId" : "job01HCOSIFZPZBFczyc",
"customerId" : "0cu01WIMZDDXALNZhm7p",
"jobBillable" : true,
"description" : null,
"createdTime" : "2021-12-09T16:00:43.000+0000",
"updatedTime" : "2021-12-09T16:00:43.000+0000",
"lineType" : "2",
"itemId" : "0ii01WBHUZZJGNDTbv0o",
"quantity" : 1,
"unitPrice" : 849.99,
"employeeId" : "emp01OVBLNBWSHBP89kw",
"actgClassId" : "cls01MBCYMNEBCGO8qb2"
} ]
}
}
Read
The response of a read request contains all bill attributes as well as bill line item attributes of a specific bill.
Request
<API_URL_EndPoint>/Crud/Read/Bill.json
data={
"id" : "00n01EYSCERXCUT3ybo9"
}
Response
{
"response_status" : 0,
"response_message" : "Success",
"response_data" : {
"entity" : "Bill",
"id" : "00n01EYSCERXCUT3ybo9",
"isActive" : "1",
"vendorId" : "00901FABIIZFVKV2pzsy",
"invoiceNumber" : "14800",
"approvalStatus" : "0",
"invoiceDate" : "2021-12-05",
"dueDate" : "2021-12-05",
"glPostingDate" : "2021-12-05",
"amount" : 2039.98,
"scheduledAmount" : 0.00,
"paidAmount" : null,
"dueAmount" : 2039.98,
"paymentStatus" : "1",
"description" : "Purchase for a new band",
"poNumber" : "1122",
"createdTime" : "2021-12-09T16:00:43.000+0000",
"updatedTime" : "2021-12-09T16:00:43.000+0000",
"payFromBankAccountId" : "00000000000000000000",
"payFromChartOfAccountId" : "00000000000000000000",
"billLineItems" : [ {
"entity" : "BillLineItem",
"id" : "bli01NTNFBQQEMF43qvu",
"billId" : "00n01EYSCERXCUT3ybo9",
"amount" : 1189.99,
"chartOfAccountId" : "0ca01AJKBYXPHRFFdgng",
"departmentId" : "0de01ORPHXZXIHFPazci",
"locationId" : "loc01ZCLEVLXDQRB9z1o",
"jobId" : "job01HCOSIFZPZBFczyc",
"customerId" : "0cu01WIMZDDXALNZhm7p",
"jobBillable" : true,
"description" : null,
"createdTime" : "2021-12-09T16:00:43.000+0000",
"updatedTime" : "2021-12-09T16:00:43.000+0000",
"lineType" : "2",
"itemId" : "0ii01YCDSBIDTPTJbhcb",
"quantity" : 1,
"unitPrice" : 1189.99,
"employeeId" : "emp01OVBLNBWSHBP89kw",
"actgClassId" : "cls01NFJTPXLWTCW8qc5"
}, {
"entity" : "BillLineItem",
"id" : "bli01HATUZKIMGP43qvv",
"billId" : "00n01EYSCERXCUT3ybo9",
"amount" : 849.99,
"chartOfAccountId" : "0ca01AJKBYXPHRFFdgng",
"departmentId" : "0de01ORPHXZXIHFPazci",
"locationId" : "loc01ZCLEVLXDQRB9z1o",
"jobId" : "job01HCOSIFZPZBFczyc",
"customerId" : "0cu01WIMZDDXALNZhm7p",
"jobBillable" : true,
"description" : null,
"createdTime" : "2021-12-09T16:00:43.000+0000",
"updatedTime" : "2021-12-09T16:00:43.000+0000",
"lineType" : "2",
"itemId" : "0ii01WBHUZZJGNDTbv0o",
"quantity" : 1,
"unitPrice" : 849.99,
"employeeId" : "emp01OVBLNBWSHBP89kw",
"actgClassId" : "cls01MBCYMNEBCGO8qb2"
} ]
}
}
Update
The details of the specified Bill are overwritten with the details you pass at the time of updating it. For example, if you want to update the details of a specific Bill line item, you need to enter all the details of the bill and the other billLineItems
.
Request
<API_URL_EndPoint>/Crud/Update/Bill.json
data={
"obj" : {
"entity" : "Bill",
"id" : "00n01EYSCERXCUT3ybo9",
"isActive" : "1",
"vendorId" : "00901FABIIZFVKV2pzsy",
"invoiceNumber" : "14800",
"invoiceDate" : "2021-12-05",
"dueDate" : "2021-12-31",
"glPostingDate" : "2021-12-05",
"description" : "Purchase for a new band",
"poNumber" : "1122",
"payFromBankAccountId" : "00000000000000000000",
"payFromChartOfAccountId" : "00000000000000000000",
"billLineItems" : [ {
"entity" : "BillLineItem",
"id" : "bli01NTNFBQQEMF43qvu",
"billId" : "00n01EYSCERXCUT3ybo9",
"amount" : 1200.00,
"chartOfAccountId" : "0ca01AJKBYXPHRFFdgng",
"departmentId" : "0de01ORPHXZXIHFPazci",
"locationId" : "loc01ZCLEVLXDQRB9z1o",
"jobId" : "job01HCOSIFZPZBFczyc",
"customerId" : "0cu01WIMZDDXALNZhm7p",
"jobBillable" : true,
"description" : null,
"lineType" : "2",
"itemId" : "0ii01YCDSBIDTPTJbhcb",
"quantity" : 1,
"unitPrice" : 1200.00,
"employeeId" : "emp01OVBLNBWSHBP89kw",
"actgClassId" : "cls01NFJTPXLWTCW8qc5"
}, {
"entity" : "BillLineItem",
"id" : "bli01HATUZKIMGP43qvv",
"billId" : "00n01EYSCERXCUT3ybo9",
"amount" : 850.00,
"chartOfAccountId" : "0ca01AJKBYXPHRFFdgng",
"departmentId" : "0de01ORPHXZXIHFPazci",
"locationId" : "loc01ZCLEVLXDQRB9z1o",
"jobId" : "job01HCOSIFZPZBFczyc",
"customerId" : "0cu01WIMZDDXALNZhm7p",
"jobBillable" : true,
"description" : null,
"lineType" : "2",
"itemId" : "0ii01WBHUZZJGNDTbv0o",
"quantity" : 1,
"unitPrice" : 850.00,
"employeeId" : "emp01OVBLNBWSHBP89kw",
"actgClassId" : "cls01MBCYMNEBCGO8qb2"
} ]
}
}
Response
{
"response_status" : 0,
"response_message" : "Success",
"response_data" : {
"entity" : "Bill",
"id" : "00n01EYSCERXCUT3ybo9",
"isActive" : "1",
"vendorId" : "00901FABIIZFVKV2pzsy",
"invoiceNumber" : "14800",
"approvalStatus" : "0",
"invoiceDate" : "2021-12-05",
"dueDate" : "2021-12-31",
"glPostingDate" : "2021-12-05",
"amount" : 2050.00,
"scheduledAmount" : 0.00,
"paidAmount" : null,
"dueAmount" : 2050.00,
"paymentStatus" : "1",
"description" : "Purchase for a new band",
"poNumber" : "1122",
"createdTime" : "2021-12-09T16:00:43.000+0000",
"updatedTime" : "2021-12-09T16:12:23.000+0000",
"payFromBankAccountId" : "00000000000000000000",
"payFromChartOfAccountId" : "00000000000000000000",
"billLineItems" : [ {
"entity" : "BillLineItem",
"id" : "bli01NTNFBQQEMF43qvu",
"billId" : "00n01EYSCERXCUT3ybo9",
"amount" : 1200.00,
"chartOfAccountId" : "0ca01AJKBYXPHRFFdgng",
"departmentId" : "0de01ORPHXZXIHFPazci",
"locationId" : "loc01ZCLEVLXDQRB9z1o",
"jobId" : "job01HCOSIFZPZBFczyc",
"customerId" : "0cu01WIMZDDXALNZhm7p",
"jobBillable" : true,
"description" : null,
"createdTime" : "2021-12-09T16:00:43.000+0000",
"updatedTime" : "2021-12-09T16:12:23.000+0000",
"lineType" : "2",
"itemId" : "0ii01YCDSBIDTPTJbhcb",
"quantity" : 1,
"unitPrice" : 1200.00,
"employeeId" : "emp01OVBLNBWSHBP89kw",
"actgClassId" : "cls01NFJTPXLWTCW8qc5"
}, {
"entity" : "BillLineItem",
"id" : "bli01HATUZKIMGP43qvv",
"billId" : "00n01EYSCERXCUT3ybo9",
"amount" : 850.00,
"chartOfAccountId" : "0ca01AJKBYXPHRFFdgng",
"departmentId" : "0de01ORPHXZXIHFPazci",
"locationId" : "loc01ZCLEVLXDQRB9z1o",
"jobId" : "job01HCOSIFZPZBFczyc",
"customerId" : "0cu01WIMZDDXALNZhm7p",
"jobBillable" : true,
"description" : null,
"createdTime" : "2021-12-09T16:00:43.000+0000",
"updatedTime" : "2021-12-09T16:12:23.000+0000",
"lineType" : "2",
"itemId" : "0ii01WBHUZZJGNDTbv0o",
"quantity" : 1,
"unitPrice" : 850.00,
"employeeId" : "emp01OVBLNBWSHBP89kw",
"actgClassId" : "cls01MBCYMNEBCGO8qb2"
} ]
}
}
Delete
Once the Bill is deleted, it is marked as inactive ["isActive" : "2"
].
Request
<API_URL_EndPoint>/Crud/Delete/Bill.json
data={
"id" : "00n01EYSCERXCUT3ybo9"
}
Response
{
"response_status" : 0,
"response_message" : "Success",
"response_data" : {
"entity" : "Bill",
"id" : "00n01EYSCERXCUT3ybo9",
"isActive" : "2",
"vendorId" : "00901FABIIZFVKV2pzsy",
"invoiceNumber" : "14800",
"approvalStatus" : "0",
"invoiceDate" : "2021-12-05",
"dueDate" : "2021-12-05",
"glPostingDate" : "2021-12-05",
"amount" : 2039.98,
"scheduledAmount" : 0.00,
"paidAmount" : null,
"dueAmount" : 2039.98,
"paymentStatus" : "1",
"description" : "Purchase for a new band",
"poNumber" : "1122",
"createdTime" : "2021-12-09T16:00:43.000+0000",
"updatedTime" : "2021-12-09T16:04:52.000+0000",
"payFromBankAccountId" : "00000000000000000000",
"payFromChartOfAccountId" : "00000000000000000000",
"billLineItems" : [ {
"entity" : "BillLineItem",
"id" : "bli01NTNFBQQEMF43qvu",
"billId" : "00n01EYSCERXCUT3ybo9",
"amount" : 1189.99,
"chartOfAccountId" : "0ca01AJKBYXPHRFFdgng",
"departmentId" : "0de01ORPHXZXIHFPazci",
"locationId" : "loc01ZCLEVLXDQRB9z1o",
"jobId" : "job01HCOSIFZPZBFczyc",
"customerId" : "0cu01WIMZDDXALNZhm7p",
"jobBillable" : true,
"description" : null,
"createdTime" : "2021-12-09T16:00:43.000+0000",
"updatedTime" : "2021-12-09T16:00:43.000+0000",
"lineType" : "2",
"itemId" : "0ii01YCDSBIDTPTJbhcb",
"quantity" : 1,
"unitPrice" : 1189.99,
"employeeId" : "emp01OVBLNBWSHBP89kw",
"actgClassId" : "cls01NFJTPXLWTCW8qc5"
}, {
"entity" : "BillLineItem",
"id" : "bli01HATUZKIMGP43qvv",
"billId" : "00n01EYSCERXCUT3ybo9",
"amount" : 849.99,
"chartOfAccountId" : "0ca01AJKBYXPHRFFdgng",
"departmentId" : "0de01ORPHXZXIHFPazci",
"locationId" : "loc01ZCLEVLXDQRB9z1o",
"jobId" : "job01HCOSIFZPZBFczyc",
"customerId" : "0cu01WIMZDDXALNZhm7p",
"jobBillable" : true,
"description" : null,
"createdTime" : "2021-12-09T16:00:43.000+0000",
"updatedTime" : "2021-12-09T16:00:43.000+0000",
"lineType" : "2",
"itemId" : "0ii01WBHUZZJGNDTbv0o",
"quantity" : 1,
"unitPrice" : 849.99,
"employeeId" : "emp01OVBLNBWSHBP89kw",
"actgClassId" : "cls01MBCYMNEBCGO8qb2"
} ]
}
}
Undelete
Once the Bill is undeleted, it is marked as active ["isActive" : "1"
].
Request
<API_URL_EndPoint>/Crud/Undelete/Bill.json
data={
"id" : "00n01EYSCERXCUT3ybo9"
}
Response
{
"response_status" : 0,
"response_message" : "Success",
"response_data" : {
"entity" : "Bill",
"id" : "00n01EYSCERXCUT3ybo9",
"isActive" : "1",
"vendorId" : "00901FABIIZFVKV2pzsy",
"invoiceNumber" : "14800",
"approvalStatus" : "0",
"invoiceDate" : "2021-12-05",
"dueDate" : "2021-12-05",
"glPostingDate" : "2021-12-05",
"amount" : 2039.98,
"scheduledAmount" : 0.00,
"paidAmount" : null,
"dueAmount" : 2039.98,
"paymentStatus" : "1",
"description" : "Purchase for a new band",
"poNumber" : "1122",
"createdTime" : "2021-12-09T16:00:43.000+0000",
"updatedTime" : "2021-12-09T16:04:52.000+0000",
"payFromBankAccountId" : "00000000000000000000",
"payFromChartOfAccountId" : "00000000000000000000",
"billLineItems" : [ {
"entity" : "BillLineItem",
"id" : "bli01NTNFBQQEMF43qvu",
"billId" : "00n01EYSCERXCUT3ybo9",
"amount" : 1189.99,
"chartOfAccountId" : "0ca01AJKBYXPHRFFdgng",
"departmentId" : "0de01ORPHXZXIHFPazci",
"locationId" : "loc01ZCLEVLXDQRB9z1o",
"jobId" : "job01HCOSIFZPZBFczyc",
"customerId" : "0cu01WIMZDDXALNZhm7p",
"jobBillable" : true,
"description" : null,
"createdTime" : "2021-12-09T16:00:43.000+0000",
"updatedTime" : "2021-12-09T16:00:43.000+0000",
"lineType" : "2",
"itemId" : "0ii01YCDSBIDTPTJbhcb",
"quantity" : 1,
"unitPrice" : 1189.99,
"employeeId" : "emp01OVBLNBWSHBP89kw",
"actgClassId" : "cls01NFJTPXLWTCW8qc5"
}, {
"entity" : "BillLineItem",
"id" : "bli01HATUZKIMGP43qvv",
"billId" : "00n01EYSCERXCUT3ybo9",
"amount" : 849.99,
"chartOfAccountId" : "0ca01AJKBYXPHRFFdgng",
"departmentId" : "0de01ORPHXZXIHFPazci",
"locationId" : "loc01ZCLEVLXDQRB9z1o",
"jobId" : "job01HCOSIFZPZBFczyc",
"customerId" : "0cu01WIMZDDXALNZhm7p",
"jobBillable" : true,
"description" : null,
"createdTime" : "2021-12-09T16:00:43.000+0000",
"updatedTime" : "2021-12-09T16:00:43.000+0000",
"lineType" : "2",
"itemId" : "0ii01WBHUZZJGNDTbv0o",
"quantity" : 1,
"unitPrice" : 849.99,
"employeeId" : "emp01OVBLNBWSHBP89kw",
"actgClassId" : "cls01MBCYMNEBCGO8qb2"
} ]
}
}
Bills for international vendors
Since the Bill.com foreign exchange rate changes periodically, a current exchangeRate
is an additional required parameter while creating bills for international vendors.
See GetDynamicExchangeRateQuote for information about retrieving exchangeRate
.
In your bill creation request with <API_URL_EndPoint>/Crud/Create/Bill.json
, set exchangeRate
as the retrieved value and amount
as the bill amount to be paid in the foreign currency.
In this example, since the retrieved exchangeRate
is for Canadian Dollar, the bill amount
in <API_URL_EndPoint>/Crud/Create/Bill.json
is also in Canadian Dollar.
Note: You must set exchangeRate
while creating a bill for an international vendor even if the Bill.com foreign exchange rate changes at the time of bill payment with PayBills.
Request
<API_URL_EndPoint>/Crud/Create/Bill.json
data={
"obj" : {
"entity" : "Bill",
"isActive" : "1",
"vendorId" : "00901PUSPHXRWUMQ6su1",
"invoiceNumber" : "14800",
"exchangeRate" : 1.23943521,
"invoiceDate" : "2021-11-27",
"dueDate" : "2021-11-30",
"billLineItems" : [ {
"entity" : "BillLineItem",
"amount" : 15.00
} ]
}
}