Create One Invoice
curl --request POST \
--url https://api.upwell.com/api/rest/invoices \
--header 'Content-Type: application/json' \
--data '
{
"input": {
"approvedToSend": true,
"balance": "<unknown>",
"billOfLadingNumber": "<string>",
"billToCustomer": {},
"billToCustomerId": "<string>",
"carrierProNumber": "<string>",
"checkOrAchNumber": "<string>",
"companyDivision": "<string>",
"createdFromEmailMessageId": "<string>",
"customerId": "<string>",
"customerPoNumber": "<string>",
"customerReferenceNumber": "<string>",
"debitsUpdatedAt": "<unknown>",
"deliveryDate": "2023-12-25",
"documentExceptions": "<unknown>",
"dueDate": "2023-12-25",
"exceptions": {},
"externallyManaged": true,
"fileAssociations": {},
"fileAssociationsUpdatedAt": "<unknown>",
"finalCheckPassedAt": "2023-11-07T05:31:56Z",
"invoiceErrors": {},
"invoiceLineItems": {},
"invoicePriorityActions": {},
"invoiceSnooze": {},
"invoiceSnoozes": {},
"issueDate": "2023-12-25",
"lastUpdatedByEmailMessageId": "<string>",
"lineItemsLastUpdatedAt": "2023-11-07T05:31:56Z",
"listBillDeliveryInvoices": {},
"metadata": "<unknown>",
"number": "<string>",
"paidDate": "2023-11-07T05:31:56Z",
"paymentLineItems": {},
"portalException": "<string>",
"portalInvoiceStatuses": {},
"portalSlug": "<string>",
"receivedAt": "<unknown>",
"receivedFromPortalSlug": "<string>",
"referenceNumbers": "<unknown>",
"scacCode": "<string>",
"scheduledPaymentDate": "2023-12-25",
"sentAt": "<unknown>",
"sentToPortalSlug": "<string>",
"shipDate": "2023-12-25",
"sourceSystem": "<string>",
"sourceSystemId": "<string>",
"splitLineage": {},
"supportingDocPacketBuiltAgainstAt": "<unknown>",
"totalAmount": "<unknown>",
"totalTaxAmount": "<unknown>"
}
}
'import requests
url = "https://api.upwell.com/api/rest/invoices"
payload = { "input": {
"approvedToSend": True,
"balance": "<unknown>",
"billOfLadingNumber": "<string>",
"billToCustomer": {},
"billToCustomerId": "<string>",
"carrierProNumber": "<string>",
"checkOrAchNumber": "<string>",
"companyDivision": "<string>",
"createdFromEmailMessageId": "<string>",
"customerId": "<string>",
"customerPoNumber": "<string>",
"customerReferenceNumber": "<string>",
"debitsUpdatedAt": "<unknown>",
"deliveryDate": "2023-12-25",
"documentExceptions": "<unknown>",
"dueDate": "2023-12-25",
"exceptions": {},
"externallyManaged": True,
"fileAssociations": {},
"fileAssociationsUpdatedAt": "<unknown>",
"finalCheckPassedAt": "2023-11-07T05:31:56Z",
"invoiceErrors": {},
"invoiceLineItems": {},
"invoicePriorityActions": {},
"invoiceSnooze": {},
"invoiceSnoozes": {},
"issueDate": "2023-12-25",
"lastUpdatedByEmailMessageId": "<string>",
"lineItemsLastUpdatedAt": "2023-11-07T05:31:56Z",
"listBillDeliveryInvoices": {},
"metadata": "<unknown>",
"number": "<string>",
"paidDate": "2023-11-07T05:31:56Z",
"paymentLineItems": {},
"portalException": "<string>",
"portalInvoiceStatuses": {},
"portalSlug": "<string>",
"receivedAt": "<unknown>",
"receivedFromPortalSlug": "<string>",
"referenceNumbers": "<unknown>",
"scacCode": "<string>",
"scheduledPaymentDate": "2023-12-25",
"sentAt": "<unknown>",
"sentToPortalSlug": "<string>",
"shipDate": "2023-12-25",
"sourceSystem": "<string>",
"sourceSystemId": "<string>",
"splitLineage": {},
"supportingDocPacketBuiltAgainstAt": "<unknown>",
"totalAmount": "<unknown>",
"totalTaxAmount": "<unknown>"
} }
headers = {"Content-Type": "application/json"}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {'Content-Type': 'application/json'},
body: JSON.stringify({
input: {
approvedToSend: true,
balance: '<unknown>',
billOfLadingNumber: '<string>',
billToCustomer: {},
billToCustomerId: '<string>',
carrierProNumber: '<string>',
checkOrAchNumber: '<string>',
companyDivision: '<string>',
createdFromEmailMessageId: '<string>',
customerId: '<string>',
customerPoNumber: '<string>',
customerReferenceNumber: '<string>',
debitsUpdatedAt: '<unknown>',
deliveryDate: '2023-12-25',
documentExceptions: '<unknown>',
dueDate: '2023-12-25',
exceptions: {},
externallyManaged: true,
fileAssociations: {},
fileAssociationsUpdatedAt: '<unknown>',
finalCheckPassedAt: '2023-11-07T05:31:56Z',
invoiceErrors: {},
invoiceLineItems: {},
invoicePriorityActions: {},
invoiceSnooze: {},
invoiceSnoozes: {},
issueDate: '2023-12-25',
lastUpdatedByEmailMessageId: '<string>',
lineItemsLastUpdatedAt: '2023-11-07T05:31:56Z',
listBillDeliveryInvoices: {},
metadata: '<unknown>',
number: '<string>',
paidDate: '2023-11-07T05:31:56Z',
paymentLineItems: {},
portalException: '<string>',
portalInvoiceStatuses: {},
portalSlug: '<string>',
receivedAt: '<unknown>',
receivedFromPortalSlug: '<string>',
referenceNumbers: '<unknown>',
scacCode: '<string>',
scheduledPaymentDate: '2023-12-25',
sentAt: '<unknown>',
sentToPortalSlug: '<string>',
shipDate: '2023-12-25',
sourceSystem: '<string>',
sourceSystemId: '<string>',
splitLineage: {},
supportingDocPacketBuiltAgainstAt: '<unknown>',
totalAmount: '<unknown>',
totalTaxAmount: '<unknown>'
}
})
};
fetch('https://api.upwell.com/api/rest/invoices', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.upwell.com/api/rest/invoices",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'input' => [
'approvedToSend' => true,
'balance' => '<unknown>',
'billOfLadingNumber' => '<string>',
'billToCustomer' => [
],
'billToCustomerId' => '<string>',
'carrierProNumber' => '<string>',
'checkOrAchNumber' => '<string>',
'companyDivision' => '<string>',
'createdFromEmailMessageId' => '<string>',
'customerId' => '<string>',
'customerPoNumber' => '<string>',
'customerReferenceNumber' => '<string>',
'debitsUpdatedAt' => '<unknown>',
'deliveryDate' => '2023-12-25',
'documentExceptions' => '<unknown>',
'dueDate' => '2023-12-25',
'exceptions' => [
],
'externallyManaged' => true,
'fileAssociations' => [
],
'fileAssociationsUpdatedAt' => '<unknown>',
'finalCheckPassedAt' => '2023-11-07T05:31:56Z',
'invoiceErrors' => [
],
'invoiceLineItems' => [
],
'invoicePriorityActions' => [
],
'invoiceSnooze' => [
],
'invoiceSnoozes' => [
],
'issueDate' => '2023-12-25',
'lastUpdatedByEmailMessageId' => '<string>',
'lineItemsLastUpdatedAt' => '2023-11-07T05:31:56Z',
'listBillDeliveryInvoices' => [
],
'metadata' => '<unknown>',
'number' => '<string>',
'paidDate' => '2023-11-07T05:31:56Z',
'paymentLineItems' => [
],
'portalException' => '<string>',
'portalInvoiceStatuses' => [
],
'portalSlug' => '<string>',
'receivedAt' => '<unknown>',
'receivedFromPortalSlug' => '<string>',
'referenceNumbers' => '<unknown>',
'scacCode' => '<string>',
'scheduledPaymentDate' => '2023-12-25',
'sentAt' => '<unknown>',
'sentToPortalSlug' => '<string>',
'shipDate' => '2023-12-25',
'sourceSystem' => '<string>',
'sourceSystemId' => '<string>',
'splitLineage' => [
],
'supportingDocPacketBuiltAgainstAt' => '<unknown>',
'totalAmount' => '<unknown>',
'totalTaxAmount' => '<unknown>'
]
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.upwell.com/api/rest/invoices"
payload := strings.NewReader("{\n \"input\": {\n \"approvedToSend\": true,\n \"balance\": \"<unknown>\",\n \"billOfLadingNumber\": \"<string>\",\n \"billToCustomer\": {},\n \"billToCustomerId\": \"<string>\",\n \"carrierProNumber\": \"<string>\",\n \"checkOrAchNumber\": \"<string>\",\n \"companyDivision\": \"<string>\",\n \"createdFromEmailMessageId\": \"<string>\",\n \"customerId\": \"<string>\",\n \"customerPoNumber\": \"<string>\",\n \"customerReferenceNumber\": \"<string>\",\n \"debitsUpdatedAt\": \"<unknown>\",\n \"deliveryDate\": \"2023-12-25\",\n \"documentExceptions\": \"<unknown>\",\n \"dueDate\": \"2023-12-25\",\n \"exceptions\": {},\n \"externallyManaged\": true,\n \"fileAssociations\": {},\n \"fileAssociationsUpdatedAt\": \"<unknown>\",\n \"finalCheckPassedAt\": \"2023-11-07T05:31:56Z\",\n \"invoiceErrors\": {},\n \"invoiceLineItems\": {},\n \"invoicePriorityActions\": {},\n \"invoiceSnooze\": {},\n \"invoiceSnoozes\": {},\n \"issueDate\": \"2023-12-25\",\n \"lastUpdatedByEmailMessageId\": \"<string>\",\n \"lineItemsLastUpdatedAt\": \"2023-11-07T05:31:56Z\",\n \"listBillDeliveryInvoices\": {},\n \"metadata\": \"<unknown>\",\n \"number\": \"<string>\",\n \"paidDate\": \"2023-11-07T05:31:56Z\",\n \"paymentLineItems\": {},\n \"portalException\": \"<string>\",\n \"portalInvoiceStatuses\": {},\n \"portalSlug\": \"<string>\",\n \"receivedAt\": \"<unknown>\",\n \"receivedFromPortalSlug\": \"<string>\",\n \"referenceNumbers\": \"<unknown>\",\n \"scacCode\": \"<string>\",\n \"scheduledPaymentDate\": \"2023-12-25\",\n \"sentAt\": \"<unknown>\",\n \"sentToPortalSlug\": \"<string>\",\n \"shipDate\": \"2023-12-25\",\n \"sourceSystem\": \"<string>\",\n \"sourceSystemId\": \"<string>\",\n \"splitLineage\": {},\n \"supportingDocPacketBuiltAgainstAt\": \"<unknown>\",\n \"totalAmount\": \"<unknown>\",\n \"totalTaxAmount\": \"<unknown>\"\n }\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://api.upwell.com/api/rest/invoices")
.header("Content-Type", "application/json")
.body("{\n \"input\": {\n \"approvedToSend\": true,\n \"balance\": \"<unknown>\",\n \"billOfLadingNumber\": \"<string>\",\n \"billToCustomer\": {},\n \"billToCustomerId\": \"<string>\",\n \"carrierProNumber\": \"<string>\",\n \"checkOrAchNumber\": \"<string>\",\n \"companyDivision\": \"<string>\",\n \"createdFromEmailMessageId\": \"<string>\",\n \"customerId\": \"<string>\",\n \"customerPoNumber\": \"<string>\",\n \"customerReferenceNumber\": \"<string>\",\n \"debitsUpdatedAt\": \"<unknown>\",\n \"deliveryDate\": \"2023-12-25\",\n \"documentExceptions\": \"<unknown>\",\n \"dueDate\": \"2023-12-25\",\n \"exceptions\": {},\n \"externallyManaged\": true,\n \"fileAssociations\": {},\n \"fileAssociationsUpdatedAt\": \"<unknown>\",\n \"finalCheckPassedAt\": \"2023-11-07T05:31:56Z\",\n \"invoiceErrors\": {},\n \"invoiceLineItems\": {},\n \"invoicePriorityActions\": {},\n \"invoiceSnooze\": {},\n \"invoiceSnoozes\": {},\n \"issueDate\": \"2023-12-25\",\n \"lastUpdatedByEmailMessageId\": \"<string>\",\n \"lineItemsLastUpdatedAt\": \"2023-11-07T05:31:56Z\",\n \"listBillDeliveryInvoices\": {},\n \"metadata\": \"<unknown>\",\n \"number\": \"<string>\",\n \"paidDate\": \"2023-11-07T05:31:56Z\",\n \"paymentLineItems\": {},\n \"portalException\": \"<string>\",\n \"portalInvoiceStatuses\": {},\n \"portalSlug\": \"<string>\",\n \"receivedAt\": \"<unknown>\",\n \"receivedFromPortalSlug\": \"<string>\",\n \"referenceNumbers\": \"<unknown>\",\n \"scacCode\": \"<string>\",\n \"scheduledPaymentDate\": \"2023-12-25\",\n \"sentAt\": \"<unknown>\",\n \"sentToPortalSlug\": \"<string>\",\n \"shipDate\": \"2023-12-25\",\n \"sourceSystem\": \"<string>\",\n \"sourceSystemId\": \"<string>\",\n \"splitLineage\": {},\n \"supportingDocPacketBuiltAgainstAt\": \"<unknown>\",\n \"totalAmount\": \"<unknown>\",\n \"totalTaxAmount\": \"<unknown>\"\n }\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.upwell.com/api/rest/invoices")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Content-Type"] = 'application/json'
request.body = "{\n \"input\": {\n \"approvedToSend\": true,\n \"balance\": \"<unknown>\",\n \"billOfLadingNumber\": \"<string>\",\n \"billToCustomer\": {},\n \"billToCustomerId\": \"<string>\",\n \"carrierProNumber\": \"<string>\",\n \"checkOrAchNumber\": \"<string>\",\n \"companyDivision\": \"<string>\",\n \"createdFromEmailMessageId\": \"<string>\",\n \"customerId\": \"<string>\",\n \"customerPoNumber\": \"<string>\",\n \"customerReferenceNumber\": \"<string>\",\n \"debitsUpdatedAt\": \"<unknown>\",\n \"deliveryDate\": \"2023-12-25\",\n \"documentExceptions\": \"<unknown>\",\n \"dueDate\": \"2023-12-25\",\n \"exceptions\": {},\n \"externallyManaged\": true,\n \"fileAssociations\": {},\n \"fileAssociationsUpdatedAt\": \"<unknown>\",\n \"finalCheckPassedAt\": \"2023-11-07T05:31:56Z\",\n \"invoiceErrors\": {},\n \"invoiceLineItems\": {},\n \"invoicePriorityActions\": {},\n \"invoiceSnooze\": {},\n \"invoiceSnoozes\": {},\n \"issueDate\": \"2023-12-25\",\n \"lastUpdatedByEmailMessageId\": \"<string>\",\n \"lineItemsLastUpdatedAt\": \"2023-11-07T05:31:56Z\",\n \"listBillDeliveryInvoices\": {},\n \"metadata\": \"<unknown>\",\n \"number\": \"<string>\",\n \"paidDate\": \"2023-11-07T05:31:56Z\",\n \"paymentLineItems\": {},\n \"portalException\": \"<string>\",\n \"portalInvoiceStatuses\": {},\n \"portalSlug\": \"<string>\",\n \"receivedAt\": \"<unknown>\",\n \"receivedFromPortalSlug\": \"<string>\",\n \"referenceNumbers\": \"<unknown>\",\n \"scacCode\": \"<string>\",\n \"scheduledPaymentDate\": \"2023-12-25\",\n \"sentAt\": \"<unknown>\",\n \"sentToPortalSlug\": \"<string>\",\n \"shipDate\": \"2023-12-25\",\n \"sourceSystem\": \"<string>\",\n \"sourceSystemId\": \"<string>\",\n \"splitLineage\": {},\n \"supportingDocPacketBuiltAgainstAt\": \"<unknown>\",\n \"totalAmount\": \"<unknown>\",\n \"totalTaxAmount\": \"<unknown>\"\n }\n}"
response = http.request(request)
puts response.read_body{
"createInvoice": {
"balance": "<unknown>",
"companyDivision": "<string>",
"createdAt": "2023-11-07T05:31:56Z",
"customerId": "<string>",
"customerReferenceNumber": "<string>",
"dueDate": "2023-12-25",
"id": "<string>",
"invoiceLineItems": [
{
"createdAt": "2023-11-07T05:31:56Z",
"id": "<string>",
"item": "<string>",
"remoteId": "<string>",
"sourceSystem": "<string>",
"sourceSystemId": "<string>",
"totalAmount": 123,
"updatedAt": "2023-11-07T05:31:56Z"
}
],
"invoiceShipments": [
{
"shipment": {
"consigneeAddress": {
"city": "<string>",
"companyName": "<string>",
"id": "<string>",
"name": "<string>",
"phoneNumber": "<string>",
"stateOrProvince": "<string>",
"streetLine1": "<string>",
"streetLine2": "<string>",
"zipOrPostalCode": "<string>"
},
"createdAt": "2023-11-07T05:31:56Z",
"customerId": "<string>",
"deliveredAt": "<unknown>",
"id": "<string>",
"invoiceId": "<string>",
"loadDescription": "<string>",
"pickupAddress": {
"city": "<string>",
"companyName": "<string>",
"id": "<string>",
"name": "<string>",
"phoneNumber": "<string>",
"stateOrProvince": "<string>",
"streetLine1": "<string>",
"streetLine2": "<string>",
"zipOrPostalCode": "<string>"
},
"pickupAt": "<unknown>",
"shipmentId": "<string>",
"status": "<string>",
"stops": [
{
"address": {
"city": "<string>",
"companyName": "<string>",
"id": "<string>",
"name": "<string>",
"phoneNumber": "<string>",
"stateOrProvince": "<string>",
"streetLine1": "<string>",
"streetLine2": "<string>",
"zipOrPostalCode": "<string>"
},
"id": "<string>",
"metadata": "<string>",
"pieceCount": 123,
"sequenceNumber": 123,
"stopType": "<string>",
"weightAmount": "<unknown>",
"weightUnit": "<string>"
}
],
"trailerNumber": "<string>",
"updatedAt": "2023-11-07T05:31:56Z",
"volume": "<unknown>",
"volumeUnit": "<string>",
"weight": "<unknown>",
"weightUnit": "<string>"
}
}
],
"issueDate": "2023-12-25",
"metadata": "<unknown>",
"missingDocuments": "<string>",
"number": "<string>",
"portalSlug": "<string>",
"referenceNumbers": "<unknown>",
"sourceSystem": "<string>",
"sourceSystemId": "<string>",
"totalAmount": "<unknown>",
"totalTaxAmount": "<unknown>",
"updatedAt": "2023-11-07T05:31:56Z"
}
}Invoices
Create One Invoice
Create a new invoice.
Integration notes:
POSTerrors with400 Uniqueness violationon duplicate(sourceSystem, sourceSystemId). UsePUTfor updates.balanceisNOT NULLwith no server-side default — for a new invoice it should equaltotalAmount.totalAmount(and other monetary fields) are integer cents, not float dollars.- The invoice number field is
number(notinvoiceNumber) and the issue date isissueDate(notinvoiceDate).
See Integration patterns.
POST
/
api
/
rest
/
invoices
Create One Invoice
curl --request POST \
--url https://api.upwell.com/api/rest/invoices \
--header 'Content-Type: application/json' \
--data '
{
"input": {
"approvedToSend": true,
"balance": "<unknown>",
"billOfLadingNumber": "<string>",
"billToCustomer": {},
"billToCustomerId": "<string>",
"carrierProNumber": "<string>",
"checkOrAchNumber": "<string>",
"companyDivision": "<string>",
"createdFromEmailMessageId": "<string>",
"customerId": "<string>",
"customerPoNumber": "<string>",
"customerReferenceNumber": "<string>",
"debitsUpdatedAt": "<unknown>",
"deliveryDate": "2023-12-25",
"documentExceptions": "<unknown>",
"dueDate": "2023-12-25",
"exceptions": {},
"externallyManaged": true,
"fileAssociations": {},
"fileAssociationsUpdatedAt": "<unknown>",
"finalCheckPassedAt": "2023-11-07T05:31:56Z",
"invoiceErrors": {},
"invoiceLineItems": {},
"invoicePriorityActions": {},
"invoiceSnooze": {},
"invoiceSnoozes": {},
"issueDate": "2023-12-25",
"lastUpdatedByEmailMessageId": "<string>",
"lineItemsLastUpdatedAt": "2023-11-07T05:31:56Z",
"listBillDeliveryInvoices": {},
"metadata": "<unknown>",
"number": "<string>",
"paidDate": "2023-11-07T05:31:56Z",
"paymentLineItems": {},
"portalException": "<string>",
"portalInvoiceStatuses": {},
"portalSlug": "<string>",
"receivedAt": "<unknown>",
"receivedFromPortalSlug": "<string>",
"referenceNumbers": "<unknown>",
"scacCode": "<string>",
"scheduledPaymentDate": "2023-12-25",
"sentAt": "<unknown>",
"sentToPortalSlug": "<string>",
"shipDate": "2023-12-25",
"sourceSystem": "<string>",
"sourceSystemId": "<string>",
"splitLineage": {},
"supportingDocPacketBuiltAgainstAt": "<unknown>",
"totalAmount": "<unknown>",
"totalTaxAmount": "<unknown>"
}
}
'import requests
url = "https://api.upwell.com/api/rest/invoices"
payload = { "input": {
"approvedToSend": True,
"balance": "<unknown>",
"billOfLadingNumber": "<string>",
"billToCustomer": {},
"billToCustomerId": "<string>",
"carrierProNumber": "<string>",
"checkOrAchNumber": "<string>",
"companyDivision": "<string>",
"createdFromEmailMessageId": "<string>",
"customerId": "<string>",
"customerPoNumber": "<string>",
"customerReferenceNumber": "<string>",
"debitsUpdatedAt": "<unknown>",
"deliveryDate": "2023-12-25",
"documentExceptions": "<unknown>",
"dueDate": "2023-12-25",
"exceptions": {},
"externallyManaged": True,
"fileAssociations": {},
"fileAssociationsUpdatedAt": "<unknown>",
"finalCheckPassedAt": "2023-11-07T05:31:56Z",
"invoiceErrors": {},
"invoiceLineItems": {},
"invoicePriorityActions": {},
"invoiceSnooze": {},
"invoiceSnoozes": {},
"issueDate": "2023-12-25",
"lastUpdatedByEmailMessageId": "<string>",
"lineItemsLastUpdatedAt": "2023-11-07T05:31:56Z",
"listBillDeliveryInvoices": {},
"metadata": "<unknown>",
"number": "<string>",
"paidDate": "2023-11-07T05:31:56Z",
"paymentLineItems": {},
"portalException": "<string>",
"portalInvoiceStatuses": {},
"portalSlug": "<string>",
"receivedAt": "<unknown>",
"receivedFromPortalSlug": "<string>",
"referenceNumbers": "<unknown>",
"scacCode": "<string>",
"scheduledPaymentDate": "2023-12-25",
"sentAt": "<unknown>",
"sentToPortalSlug": "<string>",
"shipDate": "2023-12-25",
"sourceSystem": "<string>",
"sourceSystemId": "<string>",
"splitLineage": {},
"supportingDocPacketBuiltAgainstAt": "<unknown>",
"totalAmount": "<unknown>",
"totalTaxAmount": "<unknown>"
} }
headers = {"Content-Type": "application/json"}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {'Content-Type': 'application/json'},
body: JSON.stringify({
input: {
approvedToSend: true,
balance: '<unknown>',
billOfLadingNumber: '<string>',
billToCustomer: {},
billToCustomerId: '<string>',
carrierProNumber: '<string>',
checkOrAchNumber: '<string>',
companyDivision: '<string>',
createdFromEmailMessageId: '<string>',
customerId: '<string>',
customerPoNumber: '<string>',
customerReferenceNumber: '<string>',
debitsUpdatedAt: '<unknown>',
deliveryDate: '2023-12-25',
documentExceptions: '<unknown>',
dueDate: '2023-12-25',
exceptions: {},
externallyManaged: true,
fileAssociations: {},
fileAssociationsUpdatedAt: '<unknown>',
finalCheckPassedAt: '2023-11-07T05:31:56Z',
invoiceErrors: {},
invoiceLineItems: {},
invoicePriorityActions: {},
invoiceSnooze: {},
invoiceSnoozes: {},
issueDate: '2023-12-25',
lastUpdatedByEmailMessageId: '<string>',
lineItemsLastUpdatedAt: '2023-11-07T05:31:56Z',
listBillDeliveryInvoices: {},
metadata: '<unknown>',
number: '<string>',
paidDate: '2023-11-07T05:31:56Z',
paymentLineItems: {},
portalException: '<string>',
portalInvoiceStatuses: {},
portalSlug: '<string>',
receivedAt: '<unknown>',
receivedFromPortalSlug: '<string>',
referenceNumbers: '<unknown>',
scacCode: '<string>',
scheduledPaymentDate: '2023-12-25',
sentAt: '<unknown>',
sentToPortalSlug: '<string>',
shipDate: '2023-12-25',
sourceSystem: '<string>',
sourceSystemId: '<string>',
splitLineage: {},
supportingDocPacketBuiltAgainstAt: '<unknown>',
totalAmount: '<unknown>',
totalTaxAmount: '<unknown>'
}
})
};
fetch('https://api.upwell.com/api/rest/invoices', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.upwell.com/api/rest/invoices",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'input' => [
'approvedToSend' => true,
'balance' => '<unknown>',
'billOfLadingNumber' => '<string>',
'billToCustomer' => [
],
'billToCustomerId' => '<string>',
'carrierProNumber' => '<string>',
'checkOrAchNumber' => '<string>',
'companyDivision' => '<string>',
'createdFromEmailMessageId' => '<string>',
'customerId' => '<string>',
'customerPoNumber' => '<string>',
'customerReferenceNumber' => '<string>',
'debitsUpdatedAt' => '<unknown>',
'deliveryDate' => '2023-12-25',
'documentExceptions' => '<unknown>',
'dueDate' => '2023-12-25',
'exceptions' => [
],
'externallyManaged' => true,
'fileAssociations' => [
],
'fileAssociationsUpdatedAt' => '<unknown>',
'finalCheckPassedAt' => '2023-11-07T05:31:56Z',
'invoiceErrors' => [
],
'invoiceLineItems' => [
],
'invoicePriorityActions' => [
],
'invoiceSnooze' => [
],
'invoiceSnoozes' => [
],
'issueDate' => '2023-12-25',
'lastUpdatedByEmailMessageId' => '<string>',
'lineItemsLastUpdatedAt' => '2023-11-07T05:31:56Z',
'listBillDeliveryInvoices' => [
],
'metadata' => '<unknown>',
'number' => '<string>',
'paidDate' => '2023-11-07T05:31:56Z',
'paymentLineItems' => [
],
'portalException' => '<string>',
'portalInvoiceStatuses' => [
],
'portalSlug' => '<string>',
'receivedAt' => '<unknown>',
'receivedFromPortalSlug' => '<string>',
'referenceNumbers' => '<unknown>',
'scacCode' => '<string>',
'scheduledPaymentDate' => '2023-12-25',
'sentAt' => '<unknown>',
'sentToPortalSlug' => '<string>',
'shipDate' => '2023-12-25',
'sourceSystem' => '<string>',
'sourceSystemId' => '<string>',
'splitLineage' => [
],
'supportingDocPacketBuiltAgainstAt' => '<unknown>',
'totalAmount' => '<unknown>',
'totalTaxAmount' => '<unknown>'
]
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.upwell.com/api/rest/invoices"
payload := strings.NewReader("{\n \"input\": {\n \"approvedToSend\": true,\n \"balance\": \"<unknown>\",\n \"billOfLadingNumber\": \"<string>\",\n \"billToCustomer\": {},\n \"billToCustomerId\": \"<string>\",\n \"carrierProNumber\": \"<string>\",\n \"checkOrAchNumber\": \"<string>\",\n \"companyDivision\": \"<string>\",\n \"createdFromEmailMessageId\": \"<string>\",\n \"customerId\": \"<string>\",\n \"customerPoNumber\": \"<string>\",\n \"customerReferenceNumber\": \"<string>\",\n \"debitsUpdatedAt\": \"<unknown>\",\n \"deliveryDate\": \"2023-12-25\",\n \"documentExceptions\": \"<unknown>\",\n \"dueDate\": \"2023-12-25\",\n \"exceptions\": {},\n \"externallyManaged\": true,\n \"fileAssociations\": {},\n \"fileAssociationsUpdatedAt\": \"<unknown>\",\n \"finalCheckPassedAt\": \"2023-11-07T05:31:56Z\",\n \"invoiceErrors\": {},\n \"invoiceLineItems\": {},\n \"invoicePriorityActions\": {},\n \"invoiceSnooze\": {},\n \"invoiceSnoozes\": {},\n \"issueDate\": \"2023-12-25\",\n \"lastUpdatedByEmailMessageId\": \"<string>\",\n \"lineItemsLastUpdatedAt\": \"2023-11-07T05:31:56Z\",\n \"listBillDeliveryInvoices\": {},\n \"metadata\": \"<unknown>\",\n \"number\": \"<string>\",\n \"paidDate\": \"2023-11-07T05:31:56Z\",\n \"paymentLineItems\": {},\n \"portalException\": \"<string>\",\n \"portalInvoiceStatuses\": {},\n \"portalSlug\": \"<string>\",\n \"receivedAt\": \"<unknown>\",\n \"receivedFromPortalSlug\": \"<string>\",\n \"referenceNumbers\": \"<unknown>\",\n \"scacCode\": \"<string>\",\n \"scheduledPaymentDate\": \"2023-12-25\",\n \"sentAt\": \"<unknown>\",\n \"sentToPortalSlug\": \"<string>\",\n \"shipDate\": \"2023-12-25\",\n \"sourceSystem\": \"<string>\",\n \"sourceSystemId\": \"<string>\",\n \"splitLineage\": {},\n \"supportingDocPacketBuiltAgainstAt\": \"<unknown>\",\n \"totalAmount\": \"<unknown>\",\n \"totalTaxAmount\": \"<unknown>\"\n }\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://api.upwell.com/api/rest/invoices")
.header("Content-Type", "application/json")
.body("{\n \"input\": {\n \"approvedToSend\": true,\n \"balance\": \"<unknown>\",\n \"billOfLadingNumber\": \"<string>\",\n \"billToCustomer\": {},\n \"billToCustomerId\": \"<string>\",\n \"carrierProNumber\": \"<string>\",\n \"checkOrAchNumber\": \"<string>\",\n \"companyDivision\": \"<string>\",\n \"createdFromEmailMessageId\": \"<string>\",\n \"customerId\": \"<string>\",\n \"customerPoNumber\": \"<string>\",\n \"customerReferenceNumber\": \"<string>\",\n \"debitsUpdatedAt\": \"<unknown>\",\n \"deliveryDate\": \"2023-12-25\",\n \"documentExceptions\": \"<unknown>\",\n \"dueDate\": \"2023-12-25\",\n \"exceptions\": {},\n \"externallyManaged\": true,\n \"fileAssociations\": {},\n \"fileAssociationsUpdatedAt\": \"<unknown>\",\n \"finalCheckPassedAt\": \"2023-11-07T05:31:56Z\",\n \"invoiceErrors\": {},\n \"invoiceLineItems\": {},\n \"invoicePriorityActions\": {},\n \"invoiceSnooze\": {},\n \"invoiceSnoozes\": {},\n \"issueDate\": \"2023-12-25\",\n \"lastUpdatedByEmailMessageId\": \"<string>\",\n \"lineItemsLastUpdatedAt\": \"2023-11-07T05:31:56Z\",\n \"listBillDeliveryInvoices\": {},\n \"metadata\": \"<unknown>\",\n \"number\": \"<string>\",\n \"paidDate\": \"2023-11-07T05:31:56Z\",\n \"paymentLineItems\": {},\n \"portalException\": \"<string>\",\n \"portalInvoiceStatuses\": {},\n \"portalSlug\": \"<string>\",\n \"receivedAt\": \"<unknown>\",\n \"receivedFromPortalSlug\": \"<string>\",\n \"referenceNumbers\": \"<unknown>\",\n \"scacCode\": \"<string>\",\n \"scheduledPaymentDate\": \"2023-12-25\",\n \"sentAt\": \"<unknown>\",\n \"sentToPortalSlug\": \"<string>\",\n \"shipDate\": \"2023-12-25\",\n \"sourceSystem\": \"<string>\",\n \"sourceSystemId\": \"<string>\",\n \"splitLineage\": {},\n \"supportingDocPacketBuiltAgainstAt\": \"<unknown>\",\n \"totalAmount\": \"<unknown>\",\n \"totalTaxAmount\": \"<unknown>\"\n }\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.upwell.com/api/rest/invoices")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Content-Type"] = 'application/json'
request.body = "{\n \"input\": {\n \"approvedToSend\": true,\n \"balance\": \"<unknown>\",\n \"billOfLadingNumber\": \"<string>\",\n \"billToCustomer\": {},\n \"billToCustomerId\": \"<string>\",\n \"carrierProNumber\": \"<string>\",\n \"checkOrAchNumber\": \"<string>\",\n \"companyDivision\": \"<string>\",\n \"createdFromEmailMessageId\": \"<string>\",\n \"customerId\": \"<string>\",\n \"customerPoNumber\": \"<string>\",\n \"customerReferenceNumber\": \"<string>\",\n \"debitsUpdatedAt\": \"<unknown>\",\n \"deliveryDate\": \"2023-12-25\",\n \"documentExceptions\": \"<unknown>\",\n \"dueDate\": \"2023-12-25\",\n \"exceptions\": {},\n \"externallyManaged\": true,\n \"fileAssociations\": {},\n \"fileAssociationsUpdatedAt\": \"<unknown>\",\n \"finalCheckPassedAt\": \"2023-11-07T05:31:56Z\",\n \"invoiceErrors\": {},\n \"invoiceLineItems\": {},\n \"invoicePriorityActions\": {},\n \"invoiceSnooze\": {},\n \"invoiceSnoozes\": {},\n \"issueDate\": \"2023-12-25\",\n \"lastUpdatedByEmailMessageId\": \"<string>\",\n \"lineItemsLastUpdatedAt\": \"2023-11-07T05:31:56Z\",\n \"listBillDeliveryInvoices\": {},\n \"metadata\": \"<unknown>\",\n \"number\": \"<string>\",\n \"paidDate\": \"2023-11-07T05:31:56Z\",\n \"paymentLineItems\": {},\n \"portalException\": \"<string>\",\n \"portalInvoiceStatuses\": {},\n \"portalSlug\": \"<string>\",\n \"receivedAt\": \"<unknown>\",\n \"receivedFromPortalSlug\": \"<string>\",\n \"referenceNumbers\": \"<unknown>\",\n \"scacCode\": \"<string>\",\n \"scheduledPaymentDate\": \"2023-12-25\",\n \"sentAt\": \"<unknown>\",\n \"sentToPortalSlug\": \"<string>\",\n \"shipDate\": \"2023-12-25\",\n \"sourceSystem\": \"<string>\",\n \"sourceSystemId\": \"<string>\",\n \"splitLineage\": {},\n \"supportingDocPacketBuiltAgainstAt\": \"<unknown>\",\n \"totalAmount\": \"<unknown>\",\n \"totalTaxAmount\": \"<unknown>\"\n }\n}"
response = http.request(request)
puts response.read_body{
"createInvoice": {
"balance": "<unknown>",
"companyDivision": "<string>",
"createdAt": "2023-11-07T05:31:56Z",
"customerId": "<string>",
"customerReferenceNumber": "<string>",
"dueDate": "2023-12-25",
"id": "<string>",
"invoiceLineItems": [
{
"createdAt": "2023-11-07T05:31:56Z",
"id": "<string>",
"item": "<string>",
"remoteId": "<string>",
"sourceSystem": "<string>",
"sourceSystemId": "<string>",
"totalAmount": 123,
"updatedAt": "2023-11-07T05:31:56Z"
}
],
"invoiceShipments": [
{
"shipment": {
"consigneeAddress": {
"city": "<string>",
"companyName": "<string>",
"id": "<string>",
"name": "<string>",
"phoneNumber": "<string>",
"stateOrProvince": "<string>",
"streetLine1": "<string>",
"streetLine2": "<string>",
"zipOrPostalCode": "<string>"
},
"createdAt": "2023-11-07T05:31:56Z",
"customerId": "<string>",
"deliveredAt": "<unknown>",
"id": "<string>",
"invoiceId": "<string>",
"loadDescription": "<string>",
"pickupAddress": {
"city": "<string>",
"companyName": "<string>",
"id": "<string>",
"name": "<string>",
"phoneNumber": "<string>",
"stateOrProvince": "<string>",
"streetLine1": "<string>",
"streetLine2": "<string>",
"zipOrPostalCode": "<string>"
},
"pickupAt": "<unknown>",
"shipmentId": "<string>",
"status": "<string>",
"stops": [
{
"address": {
"city": "<string>",
"companyName": "<string>",
"id": "<string>",
"name": "<string>",
"phoneNumber": "<string>",
"stateOrProvince": "<string>",
"streetLine1": "<string>",
"streetLine2": "<string>",
"zipOrPostalCode": "<string>"
},
"id": "<string>",
"metadata": "<string>",
"pieceCount": 123,
"sequenceNumber": 123,
"stopType": "<string>",
"weightAmount": "<unknown>",
"weightUnit": "<string>"
}
],
"trailerNumber": "<string>",
"updatedAt": "2023-11-07T05:31:56Z",
"volume": "<unknown>",
"volumeUnit": "<string>",
"weight": "<unknown>",
"weightUnit": "<string>"
}
}
],
"issueDate": "2023-12-25",
"metadata": "<unknown>",
"missingDocuments": "<string>",
"number": "<string>",
"portalSlug": "<string>",
"referenceNumbers": "<unknown>",
"sourceSystem": "<string>",
"sourceSystemId": "<string>",
"totalAmount": "<unknown>",
"totalTaxAmount": "<unknown>",
"updatedAt": "2023-11-07T05:31:56Z"
}
}Headers
Your API key will be used for authentication of the request. Authorization: YOUR_API_KEY
Body
application/json
Query parameters can also be provided in the request body as a JSON object
input type for inserting data into table "invoices"
Show child attributes
Show child attributes
Response
200 - application/json
Responses for POST /api/rest/invoices
columns and relationships of "invoices"
Show child attributes
Show child attributes
⌘I

