Endpoint Purchase Order

This endpoint creates a purchase order in ACP3.

https://devapiacp3.axosnet.io/api/v1/PurchaseOrder/Create

Method POST

Body:

				
					{
  "amountWithoutVat": null,
  "currencyCode": null,
  "description": null,
  "discountPercentage": null,
  "discountTerms": null,
  "id": null,
  "isTest": null,
  "isChangeOrder": null,
  "ledgerCode": null,
  "name": null,
  "neededByDate": null,
  "orderDate": null,
  "paymentTerms": null,
  "policyExternalID": null,
  "poVendorTaxId": null,
  "provincialTaxId": null,
  "purchaseOrderNumber": "PO12023",
  "purchaseRequestNumber": null,
  "receiptType": null,
  "requestedBy": null,
  "requestedDeliveryDate": null,
  "shipping": null,
  "shippingDescription": null,
  "shippingMethodKey": null,
  "shippingTermsKey": null,
  "status": null,
  "taxPurchaseOrder": null,
  "uri": null,
  "vatAmountOne": null,
  "vatAmountTwo": null,
  "vatRateOne": null,
  "vatRateTwo": null,
  "vendorAccountNumber": null,
  "vendorAddressCode": null,
  "vendorCode": null,
  "totalGrossValue": null,
  "lastChangeDate": null,
  "lastChangeTime": null,
  "isDeleted": false,
  "listItem": [
    {
      "accountCode": null,
      "amountWithoutVat": null,
      "createDate": null,
      "description": null,
      "expenseType": null,
      "externalID": null,
      "isReceiptRequired": null,
      "lineNumber": "01",
      "quantity": null,
      "purchaseOrderReceiptType": null,
      "requestedBy": null,
      "requestedDeliveryDate": null,
      "supplierPartID": null,
      "tax": null,
      "unitOfMeasureCode": null,
      "unitPrice": null,
      "vatAmount": null,
      "vatRate": null,
      "itemDeletionIndicator": null,
      "grossValueItem": null,
      "isDeleted": true,
      "allocation": [
        {
          "amount": null,
          "grossAmount": null,
          "percentage": null,
          "isDeleted": null
        }
      ]
    }
  ],
  "billToAddress": {
    "address1": null,
    "address2": null,
    "address3": null,
    "city": null,
    "countryCode": null,
    "externalID": null,
    "name": null,
    "postalCode": null,
    "stateProvince": null
  },
  "shipToAddress": {
    "address1": null,
    "address2": null,
    "address3": null,
    "city": null,
    "countryCode": null,
    "externalID": null,
    "name": null,
    "postalCode": null,
    "stateProvince": null
  },
  "sapeccSpecifics": {
    "logicalSystem": null,
    "clientNumber": null,
    "documentType": null,
    "companyCode": null,
    "purchasingOrgDesc": null,
    "purchasingGrpDesc": null
  }
}

				
			
Body

Results:

StatusCode

Message

200

Ok

400

Data Error

400

The Application is not subscribed

401

unauthorized

500

Exception Message

 

Notes:

  • In order to update a purchase order, the following mandatory fields are required:

PurchaseOrder:

  • purchaseOrderNumber

  Items:

  • LineNumber

If you need to delete a purchase order, the following fields are required:

    • “purchaseOrderNumber”: “PO98765”,
  • “isDeleted”: true

If you need to delete a item of the purchase order, the following fields are required:

“listItem”: [

    {      

      “lineNumber”: “001”,      

      “isDeleted”: true

    }

  • The data that is not going to be provided and that is not mandatory, set the value NULL
  • “paymentTerms”: null,
  • “policyExternalID”: null,
  • “poVendorTaxId”: null,
  • “provincialTaxId”: null,

 

Step to Step:

JSON
Notes

Get token with ClientId and Client Secret

Copy and paste token 

Set body

				
					{
  "amountWithoutVat": 1000.00,
  "currencyCode": "USD",
  "description": "Sample Purchase Order",
  "discountPercentage": 5.0,
  "discountTerms": "Net 30",
  "id": 101,
  "isTest": false,
  "isChangeOrder": false,
  "ledgerCode": "123ABC",
  "name": "Sample Supplier",
  "neededByDate": "2023-10-15T00:00:00",
  "orderDate": "2023-09-10T00:00:00",
  "paymentTerms": "Net 30",
  "policyExternalID": 501,
  "poVendorTaxId": 789,
  "provincialTaxId": 456,
  "purchaseOrderNumber": "PO98765",
  "purchaseRequestNumber": "PR45678",
  "receiptType": "Electronic",
  "requestedBy": "John Doe",
  "requestedDeliveryDate": "2023-10-20T00:00:00",
  "shipping": 50.00,
  "shippingDescription": "Express Shipping",
  "shippingMethodKey": "UPS",
  "shippingTermsKey": "Terms123",
  "status": true,
  "taxPurchaseOrder": null,
  "uri": "http://example.com/po12345",
  "vatAmountOne": null,
  "vatAmountTwo": null,
  "vatRateOne": null,
  "vatRateTwo": null,
  "vendorAccountNumber": "V123456",
  "vendorAddressCode": "AC7890",
  "vendorCode": "SupplierXYZ",
  "totalGrossValue": 950.00,
  "lastChangeDate": "2023-10-20T00:00:00",
  "lastChangeTime": "2023-10-20T00:00:00",
  "isDeleted": true,
  "listItem": [
    {
      "accountCode": "ACCT123",
      "amountWithoutVat": 450.00,
      "createDate": "2023-10-20T00:00:00",
      "description": "Sample Item",
      "expenseType": "Office Supplies",
      "externalID": "Item123",
      "isReceiptRequired": true,
      "lineNumber": "001",
      "quantity": 10.00,
      "purchaseOrderReceiptType": "Electronic",
      "requestedBy": "John Doe",
      "requestedDeliveryDate": "2023-09-15T00:00:00",
      "supplierPartID": "SUPP456",
      "tax": 50.00,
      "unitOfMeasureCode": "EA",
      "unitPrice": 50.00,
      "vatAmount": 10.00,
      "vatRate": 0.20,
      "itemDeletionIndicator": false,
      "grossValueItem":  550.00,
      "isDeleted": false,
      "allocation": [
        {
          "amount": 10,
          "grossAmount": 10,
          "percentage": 10,
          "isDeleted": false
        }
      ]
    },
    {
      "accountCode": "ACCT456",
      "amountWithoutVat": 675.00,
      "createDate": "2023-10-20T00:00:00",
      "description": "Office Chair",
      "expenseType": "Furniture",
      "externalID": "Chair456",
      "isReceiptRequired": true,
      "lineNumber": "002",
      "quantity": 5.00,
      "purchaseOrderReceiptType": "Physical",
      "requestedBy": "Jane Smith",
      "requestedDeliveryDate": "2023-09-20T00:00:00",
      "supplierPartID": "SUPP789",
      "tax": 75.00,
      "unitOfMeasureCode": "EA",
      "unitPrice": 150.00,
      "vatAmount": 15.00,
      "vatRate": 0.20,
      "itemDeletionIndicator": false,
      "grossValueItem":  825.00,
      "isDeleted": false,
      "allocation": [
        {
          "amount": 10,
          "grossAmount": 10,
          "percentage": 10,
          "isDeleted": false
        }
      ]
    }
  ],
  "billToAddress": {
    "address1": "123 Main St",
    "address2": null,
    "address3": null,
    "city": "Anytown",
    "countryCode": "US",
    "externalID": null,
    "name": null,
    "postalCode": null,
    "stateProvince": null
  },
  "shipToAddress": {
    "address1": "456 Elm St",
    "address2": null,
    "address3": null,
    "city": "Another Town",
    "countryCode": "US",
    "externalID": null,
    "name": null,
    "postalCode": null,
    "stateProvince": null
  },
  "sapeccSpecifics": {
    "logicalSystem": "SAP",
    "clientNumber": null,
    "documentType": null,
    "companyCode": null,
    "purchasingOrgDesc": null,
    "purchasingGrpDesc": null
  }
}
				
			
Example (Body) 

Result

Result:

StatusCode

Message

200

Ok

400

Data Error

400

The Application is not subscribed

401

unauthorized

500

Exception Message