Update an invoice
PUT
/api/v1/invoices/{invoice_id}
Invoices that haven't been paid are fully editable. Once an invoice is paid, it becomes uneditable.
Body
-
contractor string
ID of the contractor.
-
gross_pay integer
The gross pay that the contractor earned in the last pay period.
A positive integer representing the gross pay (e.g., 15000 cents to charge $150.00). The minimum amount is 1000 cents US. The maximum amount is 100000000 cents US ($1,000,000).
Minimum value is
1000
, maximum value is100000000
. -
id string
-
job string
ID of the job that the contractor was paid to do.
-
paycycle_enddate integer(int64)
Pay period end date. Measured in seconds since the Unix epoch.
-
paycycle_startdate integer(int64)
Pay period start date. Measured in seconds since the Unix epoch.
PUT /api/v1/invoices/{invoice_id}
curl \
-X PUT https://api.1099policy.com/api/v1/invoices/{invoice_id} \
-H "Content-Type: application/json" \
-d '{"contractor":"cn_Ehb3bYa","gross_pay":250000,"job":"jb_jsb9KEcTpc","paycycle_enddate":1678334737,"paycycle_startdate":1646818364}'
Request example
{
"contractor": "cn_Ehb3bYa",
"gross_pay": 250000,
"job": "jb_jsb9KEcTpc",
"paycycle_enddate": 1678334737,
"paycycle_startdate": 1646818364
}
Response examples (200)
{
"contractor": "cn_Ehb3bYa",
"created": 1646818364,
"gross_pay": 250000,
"id": "in_4RviYgc2Wt",
"job": "jb_jsb9KEcTpc",
"paycycle_enddate": 1678334737,
"paycycle_startdate": 1646818364,
"premium_due": 4325
}