Skip to content

upsertSalesInvoiceLine

WRITE

Upsert sales invoice line.

POST /api/v1/invoicing/upsertSalesInvoiceLine
curl -X POST '<your-host>/api/v1/invoicing/upsertSalesInvoiceLine' \
  -H 'Authorization: Bearer <api-key>' \
  -H 'Content-Type: application/json' \
  -d '{
    "invoiceId": "string",
    "invoiceLineType": "Part"
  }'
Response
{
  "id": "string"
}

Parameters

ParameterType
min length 1
"Part""Material""Tool""Consumable""Service""Fixture""Fixed Asset"
"Purchase to Order""Pull from Inventory""Make to Order"

Input schema

schema
{
  "type": "object",
  "properties": {
    "invoiceId": {
      "type": "string",
      "minLength": 1
    },
    "invoiceLineType": {
      "type": "string",
      "enum": [
        "Part",
        "Material",
        "Tool",
        "Consumable",
        "Service",
        "Fixture",
        "Fixed Asset"
      ]
    },
    "methodType": {
      "type": "string",
      "enum": [
        "Purchase to Order",
        "Pull from Inventory",
        "Make to Order"
      ]
    },
    "purchaseOrderId": {
      "type": "string"
    },
    "purchaseOrderLineId": {
      "type": "string"
    },
    "itemId": {
      "type": "string"
    },
    "accountId": {
      "type": "string"
    },
    "assetId": {
      "type": "string"
    },
    "addOnCost": {
      "default": 0,
      "type": "number"
    },
    "nonTaxableAddOnCost": {
      "default": 0,
      "type": "number"
    },
    "description": {
      "type": "string"
    },
    "quantity": {
      "type": "number"
    },
    "unitOfMeasureCode": {
      "default": "EA",
      "type": "string"
    },
    "unitPrice": {
      "type": "number"
    },
    "shippingCost": {
      "default": 0,
      "type": "number"
    },
    "taxPercent": {
      "default": 0,
      "type": "number"
    },
    "locationId": {
      "type": "string"
    },
    "storageUnitId": {
      "type": "string"
    },
    "exchangeRate": {
      "type": "number"
    },
    "customFields": {},
    "id": {
      "type": "string"
    }
  },
  "required": [
    "invoiceId",
    "invoiceLineType"
  ]
}