1. Customer API | The Customer API allows you to make changes to the customers in the database or to add new customer data. It also allows you to quickly view the data for each customer. This API also lets you edit the Billing and Shipping addresses as well as the customer's tax information. |
1.1. Customer Main | Customer Main API is used to add new customers or edit a customer's personal information. The get function can be used to view the information about the customers. |
1.1.1. Add |
Functions
Add API is used to add a new customer to the system
{Root URL}/API/Customer/Add/{API Key}
Parameters
Parameter |
Description |
Required |
Comment |
Custno |
Customer Number |
N |
Must be unique |
Custname |
Customer Name |
Y |
|
Status |
Account Status |
Y |
Can be: Active, Inactive, Quote (please note must be camel-cased) |
Phone |
Customer’s phone number |
N |
|
Fax |
Customer’s fax |
N |
|
Territory |
The customer’s territory |
N |
Can be: SOUTHERN CA, NORTHERN CA, EAST, WEST, MIDWEST, NEW ENGLAND, SOUTH, GREAT LAKES, MEXICO, CANADA, UNITED KINGDOM |
Terms |
The customer’s sales terms |
N |
Can be: NET 10, NET 15, NET 30, NET 30/2% 10, NET 45, COD, NONE |
Credlimit |
Credit Limit |
N |
This is the customer’s credit limit. Must be Greater than or equal to 0 |
Creditok |
Credit Status |
N |
Can be: OK, HOLD, REJECT |
Ar_highBal |
Accounts Receivable balance |
N |
Must be greater than or equal to 0 |
Acct_date |
Date the account was created |
N |
In MM/DD/YYYY format |
Saledsctid |
Sales Discount Id |
N |
|
Acctaxable |
Account Taxable |
N |
|
Example Strings
Add new customer
URL:?CustName=CustomerName&Status=Active'
JSON
{
"Custname": "CustomerName",
"Status": "Active"
}
A successful add should result in
{
"$id": "1",
"Code": 200,
"Message": "Customer added successfully.",
"SessionId": null,
"IsValidUser": true,
"ResponseObject": {
"$id": "2",
"CUSTNO": "0000000010",
"CUSTNAME": "CustomerName",
"PHONE": "",
"FAX": "",
"BLINKADD": "",
"SLINKADD": "",
"TERRITORY": "",
"TERMS": "",
"CREDLIMIT": 0,
"PROFILE": "",
"CUSTNOTE": "",
"ACCTSTATUS": "",
"DIVISION": "",
"SREPS": "",
"CREDITOK": "",
"RESL_NO": "",
"AR_CALDATE": null,
"AR_CALTIME": "",
"AR_CALBY": "",
"AR_CALNOTE": "",
"AR_HIGHBAL": 0,
"CREDITNOTE": "",
"ACCT_DATE": "2014-11-19T10:09:57.041868-05:00",
"SAVEINIT": "",
"OUT_MARGIN": 0,
"TL_MARGIN": 0,
"MAT_MARGIN": 0,
"LAB_MARGIN": 0,
"MIN_ORDAMT": 0,
"SCRAP_FACT": 0,
"COMMITEM": 0,
"CUSTSPEC": 0,
"LABOR": false,
"MATERIAL": false,
"SPLIT1": 0,
"SPLIT2": 0,
"SPLITAMT": 0,
"SPLITPERC": 0,
"TOOLING": false,
"SIC_CODE": "",
"SIC_DESC": "",
"DELIVTIME": "",
"STATUS": "Active",
"SERIFLAG": false,
"OVERHEAD": 0,
"IS_EDITED": "",
"SALEDSCTID": "",
"CUSTPFX": "",
"ACTTAXABLE": false,
"INACTDT": null,
"INACTINIT": "",
"modifiedDate": null,
"UserId": null,
"LinkAddList": null
}
}
Common Errors
URL Error
If there is an error with the entered URL the system will return a HTTP error.
{
"$id": "1",
"Message": "No HTTP resource was found that matches the request URI 'http://localhost/api/CustomerAdd/123456789'.",
"MessageDetail": "No type was found that matches the controller named 'CustomerAdd'."
}
Parameter Error
If a required parameter is missing, or the entered value is incorrect the system will return an object reference error message.
{
"$id": "1",
"Code": 403,
"Message": "Customer add failed.Object reference not set to an instance of an object.",
"SessionId": null,
"IsValidUser": true,
"ResponseObject": null
}
API Key Error
If there is a problem with the used API key the system will return an error describing it.
{
"$id": "1",
"Code": 403,
"Message": "Invalid API Key.",
"SessionId": null,
"IsValidUser": false,
"ResponseObject": null
}
|
1.1.2. Edit |
Functions
Customer edit API is used to modify existing customer information
{Root URL}/API/Customer/Edit/{API Key}
Parameters
Parameter |
Description |
Required |
Comment |
Custno |
Customer Number |
Y |
Must be unique and ten digits. |
Custname |
Customer Name |
N |
|
Phone |
Customer’s phone number |
N |
|
Fax |
Customer’s fax |
N |
|
Territory |
The customer’s territory |
N |
Can be: SOUTHERN CA, NORTHERN CA, EAST, WEST, MIDWEST, NEW ENGLAND, SOUTH, GREAT LAKES, MEXICO, CANADA, UNITED KINGDOM |
Terms |
The customer’s sales terms |
N |
Can be: NET 10, NET 15, NET 30, NET 30/2% 10, NET 45, COD, NONE |
Credlimit |
Credit Limit |
N |
This is the customer’s credit limit. Must be Greater than or equal to 0 |
Creditok |
Credit Status |
N |
Can be: OK, HOLD, REJECT |
Resl_no |
Reseller Number |
N |
|
Ar_highBal |
Accounts Receivable balance |
N |
Must be greater than or equal to 0 |
Acct_date |
Date the account was created |
N |
In MM/DD/YYYY format |
Status |
Account Status |
N |
Can be: ACTIVE, INACTIVE, QUOTE |
Saledsctid |
Sales Discount Id |
N |
|
Acctaxable |
Account Taxable |
N |
|
Inactdt |
Account inactive date |
N |
Must be in MM/DD/YYYY |
Inactinit |
Inactive initial |
N |
|
modifieddate |
Account Modified Date |
N |
Must be in MM/DD/YYYY format. |
Example Strings
Edit Customer Details
URL:?CUSTNO=0000000000&CUSTNAME=CustomerName&ACCT_DATE=YYYY-MM-DD00:00:00&STATUS=Active&territory=NEW ENGLAND'
{
'CUSTNO':'0000000000',
'CUSTNAME':'CustomerName',
'ACCT_DATE':'YYYY-MM-DD00:00:00',
'STATUS':'Active',
'territory':'NEW ENGLAND'
}
A successful edit should result in
{
"$id": "1",
"Code": 200,
"Message": "Customer edited successfully.",
"SessionId": null,
"IsValidUser": true,
"ResponseObject": null
}
Common Errors
API Key Error
If there is an error with the API Key the system will return an error message describing it.
{
"$id": "1",
"Code": 403,
"Message": "Invalid API Key.",
"SessionId": null,
"IsValidUser": false,
"ResponseObject": null
}
URL Error
If there is an error with the used URL the system will return a HTTP error.
{
"$id": "1",
"Message": "No HTTP resource was found that matches the request URI 'http://localhost/api/CustomerEdit/123456789'.",
"MessageDetail": "No type was found that matches the controller named 'CustomerEdit'."
}
Parameter Error
If there is an error with one of the used parameters the system will return an error message describing the error.
{
"$id": "1",
"Code": 403,
"Message": "Customer edit failed.Customer Number or Customer Name is Required",
"SessionId": null,
"IsValidUser": true,
"ResponseObject": null
}
|
1.1.3. Get |
Functions
Add
{Root URL}/API/Customer/Get/{API Key}
Parameters
Parameter |
Description |
Required |
Comment |
CustNumOrName |
Customer Number or Customer Name |
Y |
Use either the customer number or the customer name to get customer information. |
Example Strings
Get Customer Information
URL:?CustNumOrName=Customer
JSON
{
'CustNumOrName':'Customer'
}
A successful request should result in
{
"$id": "1",
"Code": 200,
"Message": "Customer details:",
"SessionId": null,
"IsValidUser": true,
-"ResponseObject": {
"$id": "2",
"LinkAddList": null,
"CUSTNO": "0000000010",
"CUSTNAME": "Customer ",
"PHONE": " ",
"FAX": " ",
"BLINKADD": " ",
"SLINKADD": " ",
"TERRITORY": "NEW ENGLAND ",
"TERMS": " ",
"CREDLIMIT": 0,
"PROFILE": "",
"CUSTNOTE": "",
"ACCTSTATUS": " ",
"DIVISION": " ",
"SREPS": " ",
"CREDITOK": " ",
"RESL_NO": " ",
"AR_CALDATE": null,
"AR_CALTIME": " ",
"AR_CALBY": " ",
"AR_CALNOTE": "",
"AR_HIGHBAL": 0,
"CREDITNOTE": "",
"ACCT_DATE": "2014-11-19T13:28:00",
"SAVEINIT": " ",
"OUT_MARGIN": 0,
"TL_MARGIN": 0,
"MAT_MARGIN": 0,
"LAB_MARGIN": 0,
"MIN_ORDAMT": 0,
"SCRAP_FACT": 0,
"COMMITEM": 0,
"CUSTSPEC": 0,
"LABOR": false,
"MATERIAL": false,
"SPLIT1": 0,
"SPLIT2": 0,
"SPLITAMT": 0,
"SPLITPERC": 0,
"TOOLING": false,
"SIC_CODE": " ",
"SIC_DESC": " ",
"DELIVTIME": " ",
"STATUS": "Active ",
"SERIFLAG": false,
"OVERHEAD": 0,
"IS_EDITED": " ",
"SALEDSCTID": " ",
"CUSTPFX": " ",
"ACTTAXABLE": false,
"INACTDT": null,
"INACTINIT": " ",
"modifiedDate": "2014-11-19T13:27:49.25",
"UserId": null
}
}
Common Errors
Incorrect URL
If there is a problem with the URL or the parameter entered the system will return a HTTP error message.
{
"$id": "1",
"Message": "No HTTP resource was found that matches the request URI 'http://localhost/api/Customer/Get/123456789?CustName=CustomerName'.",
"MessageDetail": "No action was found on the controller 'Customer' that matches the request."
}
Non-Existent Customer
If the entered customer does not exist the system will return a message describing it.
{
"$id": "1",
"Code": 403,
"Message": "Customer does not exists.",
"SessionId": null,
"IsValidUser": true,
"ResponseObject": null
}
|
1.2. Customer Address |
Customer Address API is used to add or modify shipping and billing addresses for customers. The Get function is used to view addresses for a customer. The delete function is used to remove addresses from a customer's information.
|
1.2.1. Add |
Customer Address add API is used to add Ship to Address and Bill to Address
URL:{Root URL}/Api/ShipBill/Add/{API Key}
Parameters
Parameter |
Description |
Required |
Comment
|
Linkadd |
|
N |
|
Custno |
Customer Number |
Y |
|
Shipto |
Ship to Name |
N |
The person you are shipping to |
Address1 |
First line of the address |
N |
|
Address2 |
Second Line of the address |
N |
|
City |
City |
N |
Ship to City |
State |
State |
N |
Ship to State |
Zip |
Zip Code |
N |
Ship to Zip code |
Country |
Country |
N |
Ship to country |
Phone |
Phone number |
N |
Ship to Phone Number |
Fax |
Fax |
N |
Ship to fax address |
Email |
Email |
N |
Ship to email address |
Attention |
Attention |
N |
Attention notice for the shipping |
recordtype |
The type of record |
N |
Can be C for Confirm to or R for Remit to |
Example Strings
Add Address
URL:?custno=0000000000&shipTo=Test&recordType=S
JSON
{
'custno':'0000000000',
'shipTo':'Test',
'recordType':'S'
}
A successful add should result in
{
"$id": "1",
"Code": 200,
"Message": "ShipBill added successfully.",
"SessionId": null,
"IsValidUser": true,
"ResponseObject": {
"$id": "2",
"LINKADD": "056RU7J15B",
"CUSTNO": "0000000010",
"SHIPTO": "Test",
"ADDRESS1": "",
"ADDRESS2": "",
"CITY": "",
"STATE": "",
"ZIP": "",
"COUNTRY": "",
"PHONE": "",
"FAX": "",
"E_MAIL": "",
"TRANSDAY": 0,
"FOB": "",
"SHIPCHARGE": "",
"SHIPVIA": "",
"ATTENTION": "",
"RECORDTYPE": "S",
"BILLACOUNT": "",
"SHIPTIME": "",
"SHIPNOTE": "",
"SHIP_DAYS": 0,
"RECV_DEFA": false,
"CONFIRM": "",
"PKFOOTNOTE": "",
"INFOOTNOTE": "",
"TAXEXEMPT": "",
"FOREIGNTAX": false,
"ModifiedDate": null
}
}
Common Errors
API Key Error
If there is an error with the entered API key the system will return an error message describing an API key error.
{
"$id": "1",
"Code": 403,
"Message": "Invalid API Key.",
"SessionId": null,
"IsValidUser": false,
"ResponseObject": null
}
URL Error
If there is an error with the URL the system will return a HTTP error message.
{
"$id": "1",
"Message": "No HTTP resource was found that matches the request URI 'http://localhost/api/ShipBillAdd/123456789'.",
"MessageDetail": "No type was found that matches the controller named 'ShipBillAdd'."
}
Parameter Value Error
If there is a problem with one of the entered parameter values or a required parameter is missing the system will return an error message describing the problem.
{
"$id": "1",
"Code": 403,
"Message": "ShipBill add failed.Customer does not exists.",
"SessionId": null,
"IsValidUser": true,
"ResponseObject": null
}
|
1.2.2. Edit |
Customer Address edit API is used to modify existing customer address information.
URL:{Root URL}/Api/ShipBill/Edit/{API Key}
Parameters
Parameter |
Description |
Required |
Comment
|
Linkadd |
|
Y |
|
Custno |
Customer Number |
Y |
|
ShipCharge |
Ship Charge |
Y |
Can be NO CHARGE, PREPAY/BILL CUS, SET RATE:UPS-BR, SET RATE:UPS-BL, SET RATE:UPS-RD, SET RATE:FEDX-1 |
ShipVia |
Ship Via |
Y |
Can be COMPANY TRUCK, CUST PICK UP, UPS-GRND TRACK, UPS-BLUE, UPS-RED, FEDX-1, FEDX-STD |
FOB |
FOB |
Y |
Can be ORIGIN-CUST P/U, ORIGIN-SHIP, DESTINATION |
Shipto |
Ship to Name |
N |
The person you are shipping to |
Address1 |
First line of the address |
N |
|
Address2 |
Second Line of the address |
N |
|
City |
City |
N |
Ship to City |
State |
State |
N |
Ship to State |
Zip |
Zip Code |
N |
Ship to Zip code |
Country |
Country |
N |
Ship to country |
Phone |
Phone number |
N |
Ship to Phone Number |
Fax |
Fax |
N |
Ship to fax address |
Email |
Email |
N |
Ship to email address |
Attention |
Attention |
N |
Attention notice for the shipping |
recordtype |
The type of record |
N |
Can be C for Confirm to or R for Remit to |
Example Strings
Address Edit
URL:?LinkAdd=LINKADD&Custno=0000000000&Shipto=TestShipping&RecordType=B&Foreightax=false&FOB=ORIGIN-CUST P/U&SHIPCHARGE=PREPAY/BILL CUS&SHIPVIA=COMPANY TRUCK
JSON
{
'LinkAdd':'LINKADD',
'Custno':'0000000000',
'Shipto':'TestShipping',
'RecordType':'B',
'Foreightax':'false',
'FOB':'ORIGIN-CUST P/U',
'SHIPCHARGE':'PREPAY/BILL CUS',
'SHIPVIA':'COMPANY TRUCK'
}
A successful edit should result in
{
"$id": "1",
"Code": 200,
"Message": "ShipBill edited successfully.",
"SessionId": null,
"IsValidUser": true,
"ResponseObject": null
}
Common Errors
API Key Error
If there is an error with the entered API key the system will return an error message describing an API key error.
{
"$id": "1",
"Code": 403,
"Message": "Invalid API Key.",
"SessionId": null,
"IsValidUser": false,
"ResponseObject": null
}
URL Error
If there is an error with the URL the system will return a HTTP error message.
{
"$id": "1",
"Message": "No HTTP resource was found that matches the request URI 'http://localhost/api/ShipBillEdit/123456789'.",
"MessageDetail": "No type was found that matches the controller named 'ShipBillEdit'."
}
Parameter Value Error
If there is a problem with one of the entered parameter values or a required parameter is missing the system will return an error message describing the problem.
{
"$id": "1",
"Code": 403,
"Message": "ShipBill edit failed.Link address does not exists.",
"SessionId": null,
"IsValidUser": true,
"ResponseObject": null
}
|
1.2.3. Delete |
Customer Address delete API is used to remove customer address information from the customer record.
URL:{Root URL}/Api/ShipBill/Delete/{API Key}
Parameters
Parameter |
Description |
Required |
Comment
|
Linkadd |
|
Y |
|
Custno |
Customer Number |
N |
|
Shipto |
Ship to Name |
N |
The person you are shipping to |
Address1 |
First line of the address |
N |
|
Address2 |
Second Line of the address |
N |
|
City |
City |
N |
Ship to City |
State |
State |
N |
Ship to State |
Zip |
Zip Code |
N |
Ship to Zip code |
Country |
Country |
N |
Ship to country |
Phone |
Phone number |
N |
Ship to Phone Number |
Fax |
Fax |
N |
Ship to fax address |
Email |
Email |
N |
Ship to email address |
Attention |
Attention |
N |
Attention notice for the shipping |
recordtype |
The type of record |
N |
Can be C for Confirm to or R for Remit to |
Example Strings
Delete Address
URL:?LinkAdd=LINKADD
JSON
A successful delete should result in
{
"$id": "1",
"Code": 200,
"Message": "ShipBill deleted successfully.",
"SessionId": null,
"IsValidUser": true,
"ResponseObject": null
}
Common Error
API Key Error
If there is a problem with the used API key the system will return an error describing it.
{
"$id": "1",
"Code": 403,
"Message": "Invalid API Key.",
"SessionId": null,
"IsValidUser": false,
"ResponseObject": null
}
URL Error
If there is an issue with the entered URL the system will return a HTTP error
{
"$id": "1",
"Message": "No HTTP resource was found that matches the request URI 'http://localhost/api/ShipBill/Delete/23456789'.",
"MessageDetail": "No action was found on the controller 'ShipBill' that matches the request."
}
Missing Required Parameter
If a required parameter is missing the system will return an error message specifying which parameter.
{
"$id": "1",
"Code": 403,
"Message": "Please provide LinkAddress",
"SessionId": null,
"IsValidUser": true,
"ResponseObject": null
}
|
1.2.4. Get |
Customer Address get API is used to find and view existing customer address information.
URL:{Root URL}/Api/ShipBill/Get/{API Key}
Parameters
Parameter |
Description |
Required |
Comment
|
Linkadd |
Customer Address Key |
Y |
|
Custno |
Customer Number |
N |
|
Shipto |
Ship to Name |
N |
The person you are shipping to |
Address1 |
First line of the address |
N |
|
Address2 |
Second Line of the address |
N |
|
City |
City |
N |
Ship to City |
State |
State |
N |
Ship to State |
Zip |
Zip Code |
N |
Ship to Zip code |
Country |
Country |
N |
Ship to country |
Phone |
Phone number |
N |
Ship to Phone Number |
Fax |
Fax |
N |
Ship to fax address |
Email |
Email |
N |
Ship to email address |
Attention |
Attention |
N |
Attention notice for the shipping |
recordtype |
The type of record |
N |
Can be C for Confirm to or R for Remit to |
Example Strings
Get Address
URL:?LinkAdd=LINKADD
A successful request should return
{
"$id": "1",
"Code": 200,
"Message": "ShipBill details:",
"SessionId": null,
"IsValidUser": true,
"ResponseObject": {
"$id": "2",
"LINKADD": "_4560WJU2L",
"CUSTNO": "0000000008",
"SHIPTO": "TestShipping ",
"ADDRESS1": "12 West St ",
"ADDRESS2": " ",
"CITY": "Swilton ",
"STATE": "NH ",
"ZIP": "02343 ",
"COUNTRY": "USA ",
"PHONE": "6035555555 ",
"FAX": " ",
"E_MAIL": "",
"TRANSDAY": 0,
"FOB": "ORIGIN-CUST P/U",
"SHIPCHARGE": "PREPAY/BILL CUS",
"SHIPVIA": "COMPANY TRUCK ",
"ATTENTION": " ",
"RECORDTYPE": "B",
"BILLACOUNT": " ",
"SHIPTIME": " ",
"SHIPNOTE": "",
"SHIP_DAYS": 0,
"RECV_DEFA": false,
"CONFIRM": " ",
"PKFOOTNOTE": "",
"INFOOTNOTE": "",
"TAXEXEMPT": " ",
"FOREIGNTAX": false,
"ModifiedDate": "2014-12-01T09:31:36.737"
}
}
Common Errors
API Key Error
If there is a problem with the used API key the system will return an error describing it.
{
"$id": "1",
"Code": 403,
"Message": "Invalid API Key.",
"SessionId": null,
"IsValidUser": false,
"ResponseObject": null
}
URL Error
If there is a problem with the entered URL the system will return an HTTP error
{
"$id": "1",
"Message": "No HTTP resource was found that matches the request URI 'http://localhost/api/ShipBill/Get/123456789'.",
"MessageDetail": "No action was found on the controller 'ShipBill' that matches the request."
}
Parameter Error
If the entered parameter does not link to an existing Ship Bill record the system will return a "ShipBill does not exist" error message.
{
"$id": "1",
"Code": 403,
"Message": "ShipBill does not exists.",
"SessionId": null,
"IsValidUser": true,
"ResponseObject": null
}
|
1.3. Customer Tax | Customer Tax API is used to add or edit Tax information for customers. The Get function for Tax API is used to view the tax information for a customer. The Delete function is used to remove tax information from a customer record. |
1.3.1. Add |
Functions
Customer Add Tax API is used to add tax information to a customer's information.
Parameters
Parameter |
Description |
Required |
Comment |
unqshiptax |
Primary Tax Key |
Y |
Must be Unique |
Linkadd |
Link to Ship Bill Table |
Y |
Links the tax info to the shipping info |
Custno |
Customer Number |
Y |
|
Taxdesc |
Tax Description |
Y |
|
tax_rate |
Tax Rate |
Y |
|
Tax_id |
Tax ID |
Y |
|
recordtype |
Record Type |
Y |
|
ptProd |
Primary Tax Product |
N |
|
ptFr |
Primary Tax Freigh |
N |
|
stProd |
Secondary Tax Product |
N |
|
stFrt |
Secondary Tax Freight |
N |
|
stTx |
Secondary Tax |
N |
|
modifiedDate |
Last Modified Date |
N |
|
Example Strings
Add new tax information
URL:?Linkadd=LINKADD&Custno=0000000011&Taxdesc=SANTA CLARA CNTY. USE TAX&Taxtype=S&Tax_Rate=8.2500&Tax_id=CA USE&Recordtype=S
JSON
{
'Linkadd':'LINKADD',
'Custno':'0000000011',
'Taxdesc':'SANTA CLARA CNTY. USE TAX',
'Taxtype':'S',
'Tax_Rate':'8.2500' ,
'Tax_id':'CA USE ',
'Recordtype':'S'
}
A successful add should result in
{
"$id": "1",
"Code": 200,
"Message": "ShipTax added successfully.",
"SessionId": null,
"IsValidUser": true,
"ResponseObject": null
}
Common Errors
API Key Error
If there is an error with the entered API key the system will return an error message describing an API key error.
{
"$id": "1",
"Code": 403,
"Message": "Invalid API Key.",
"SessionId": null,
"IsValidUser": false,
"ResponseObject": null
}
URL Error
If there is an error with the URL the system will return a HTTP error message.
{
"$id": "1",
"Message": "No HTTP resource was found that matches the request URI 'http://localhost/api/ShipTaxAdd/123456789'.",
"MessageDetail": "No type was found that matches the controller named 'ShipTaxAdd'."
}
Parameter Value Error
If there is a problem with one of the entered parameter values or a required parameter is missing the system will return an error message describing the problem.
{
"$id": "1",
"Code": 403,
"Message": "'ShipTax' Object is not initialized properly.",
"SessionId": null,
"IsValidUser": true,
"ResponseObject": null
}
|
1.3.2. Edit |
Functions
Customer Tax edit API is used to modify existing tax information.
URL:{Root URL}/API/ShipTax/Edit/{API Key}
Parameters
Parameter |
Description |
Required |
Comment |
unqshiptax |
Primary Tax Key |
Y |
Must be Unique |
Linkadd |
Link to Ship Bill Table |
Y |
Links the tax info to the shipping info |
Custno |
Customer Number |
Y |
|
Taxdesc |
Tax Description |
N |
|
tax_rate |
Tax Rate |
N |
|
Tax_id |
Tax ID |
N |
|
recordtype |
Record Type |
N |
|
ptProd |
Primary Tax Product |
N |
|
ptFr |
Primary Tax Freigh |
N |
|
stProd |
Secondary Tax Product |
N |
|
stFrt |
Secondary Tax Freight |
N |
|
stTx |
Secondary Tax |
N |
|
modifiedDate |
Last Modified Date |
N |
|
Example Strings
Edit Tax Details
URL:?UNQSHIPTAX=UniqShipTa&Custno=0000000011&Taxdesc=ORANGE COUNTY&Taxtype=S&Tax_Rate=7.5&Tax_id=CA USE&Recordtype=S
{
'UNQSHIPTAX':'USQNT0M26L',
'Custno':'0000000011',
'Taxdesc':'ORANGE COUNTY',
'Taxtype':'S',
'Tax_Rate':'7.5' ,
'Tax_id':'CA USE ',
'Recordtype':'S'
}
A successful edit should result in
{
"$id": "1",
"Code": 200,
"Message": "ShipTax edited successfully.",
"SessionId": null,
"IsValidUser": true,
"ResponseObject": null
}
Common Errors
API Key Error
If there is an error with the entered API key the system will return an error message describing an API key error.
{
"$id": "1",
"Code": 403,
"Message": "Invalid API Key.",
"SessionId": null,
"IsValidUser": false,
"ResponseObject": null
}
URL Error
If there is an error with the URL the system will return a HTTP error message.
{
"$id": "1",
"Message": "No HTTP resource was found that matches the request URI 'http://localhost/api/ShipTaxEdit/123456789'.",
"MessageDetail": "No type was found that matches the controller named 'ShipTaxEdit'."
}
Parameter Value Error
If there is a problem with one of the entered parameter values or a required parameter is missing the system will return an error message describing the problem.
{
"$id": "1",
"Code": 403,
"Message": "'ShipTax' Object is not initialized properly.",
"SessionId": null,
"IsValidUser": true,
"ResponseObject": null
}
|
1.3.3. Delete |
Functions
Customer Tax delete API is used to remove tax information from a customer's records
URL:{Root URL}/API/Customer/TaxDelete/{API Key}
Parameters
Parameter |
Description |
Required |
Comment |
Custno |
Customer Number |
Y |
|
Example Strings
Delete tax information
URL?CustNo=0000000011
JSON
{
'CustNo','0000000011'
}
A successful delete request should result in
{
"$id": "1",
"Code": 200,
"Message": "ShipTax deleted successfully.",
"SessionId": null,
"IsValidUser": true,
"ResponseObject": null
}
Common Error
API Key Error
If there is a problem with the used API key the system will return an error describing it.
{
"$id": "1",
"Code": 403,
"Message": "Invalid API Key.",
"SessionId": null,
"IsValidUser": false,
"ResponseObject": null
}
URL Error
If there is an issue with the entered URL the system will return a HTTP error
{
"$id": "1",
"Message": "No HTTP resource was found that matches the request URI 'http://localhost/api/ShipTax/Delete/23456789'.",
"MessageDetail": "No action was found on the controller 'ShipTax' that matches the request."
}
Missing Required Parameter
If a required parameter is missing the system will return an error message specifying which parameter.
{
"$id": "1",
"Code": 403,
"Message": "Customer number or customer name not provided.",
"SessionId": null,
"IsValidUser": true,
"ResponseObject": null
}
|
1.3.4. Get |
Functions
Customer Tax get API is used to find and view existing tax information
URL:{Root URL}/API/ShipTax/Get/{API Key}
Parameters
Parameter |
Description |
Required |
Comment |
Linkadd |
Link to Ship Bill Table |
Y |
Links the tax info to the shipping info |
Example Strings
Get Tax Information
URL:?LinkAdd=LINKADD
JSON
A successful get request should result in
{
"$id": "1",
"Code": 200,
"Message": "ShipTax details:",
"SessionId": null,
"IsValidUser": true,
-"ResponseObject": [
-{
"$id": "2",
"ShipBill": null,
"UNQSHIPTAX": "_41X0YBZJX",
"LINKADD": "_41X0YBRKE",
"CUSTNO": "0000000007",
"ADDRESS1": " ",
"TAXDESC": "SANTA CLARA CNTY. USE TAX",
"TAXTYPE": "S",
"TAX_RATE": 8.25,
"TAX_ID": "CA USE ",
"RECORDTYPE": "S",
"PTPROD": false,
"PTFRT": false,
"STPROD": false,
"STFRT": false,
"STTX": false,
"ModifiedDate": null
},
{
"$id": "3",
"ShipBill": null,
"UNQSHIPTAX": "_41X0YC231",
"LINKADD": "_41X0YBRKE",
"CUSTNO": "0000000007",
"ADDRESS1": " ",
"TAXDESC": "SANTA CLARA CNTY. USE TAX",
"TAXTYPE": "C",
"TAX_RATE": 8.25,
"TAX_ID": "CA USE ",
"RECORDTYPE": "S",
"PTPROD": false,
"PTFRT": false,
"STPROD": false,
"STFRT": false,
"STTX": false,
"ModifiedDate": null
}
]
}
Common Errors
URL Error
If there is an error with the entered URL the system will return a HTTP error.
{
"$id": "1",
"Message": "No HTTP resource was found that matches the request URI 'http://localhost/api/ShipTaxGet/123456789'.",
"MessageDetail": "No type was found that matches the controller named 'ShipTaxGet'."
}
API Key Error
If there is a problem with the used API key the system will return an error describing it.
{
"$id": "1",
"Code": 403,
"Message": "Invalid API Key.",
"SessionId": null,
"IsValidUser": false,
"ResponseObject": null
}
Parameter Error
If a required parameter is missing, or the entered value is incorrect the system will return an object reference error message.
{
"$id": "1",
"Code": 403,
"Message": "ShipTax does not exists.",
"SessionId": null,
"IsValidUser": true,
"ResponseObject": null
}
|
|