Business-to-Business Sample Mid-Market ERP Process
NOTE: Users of the Sandbox Environment should remove the /api/basic-auth prefix for all URL paths listed below.
This process shows a typical order process for a commonly used workflow in mid-market ERPs. In this instance, your organization will enter orders and invoices triggering an evaluate call to Global Tax Determination (GTD). When the invoice is ready to be posted, a commit call will save the transaction in GTD. At this point, the transaction can be leveraged by Filing and Reporting but cannot be changed.
Sample EVALUATE Request/Response A
Request
POST https://<S1 host>/api/basic-auth/simple-connect-ar/v1/transactions?state=EVALUATE
Body
{
"exemptionReasonCode": "RESELLER",
"invoiceDate": "2020-03-15",
"invoiceNumber": "986521347adsfsf",
"currencyCode": "USD",
"taxDirection": "FORWARD",
"customAttributes": {
"property1": "string",
"property2": "string"
},
"customerCode": "cu5689",
"billTo": {
"address": "200 Ballardvale ST",
"cityMunicipality": "WILMINGTON",
"country": "USA",
"county": "Middlesex",
"stateProvince": "MA",
"zipPostalCode": "01887",
"zipPostalCodeExtension": "1234"
},
"shipFrom": {
"address": "200 Ballardvale ST",
"cityMunicipality": "WILMINGTON",
"country": "USA",
"county": "Middlesex",
"stateProvince": "MA",
"zipPostalCode": "01887",
"zipPostalCodeExtension": "1234"
},
"shipTo": {
"address": "200 Ballardvale ST",
"cityMunicipality": "WILMINGTON",
"country": "USA",
"county": "Middlesex",
"stateProvince": "MA",
"zipPostalCode": "01887",
"zipPostalCodeExtension": "1234"
},
"lineItems": [
{
"billTo": {
"address": "200 Ballardvale ST",
"cityMunicipality": "WILMINGTON",
"country": "USA",
"county": "Middlesex",
"stateProvince": "MA",
"zipPostalCode": "01887",
"zipPostalCodeExtension": "1234"
},
"customerCode": "cu001",
"deliveryDate": "2019-06-21",
"description": "clothes",
"exemptionReasonCode": "string",
"goodServiceCode": "5986334",
"grossAmount": 200,
"quantity": 3,
"shipFrom": {
"address": "200 Ballardvale ST",
"cityMunicipality": "WILMINGTON",
"country": "USA",
"county": "Middlesex",
"stateProvince": "MA",
"zipPostalCode": "01887",
"zipPostalCodeExtension": "1234"
},
"shipTo": {
"address": "200 Ballardvale ST",
"cityMunicipality": "WILMINGTON",
"country": "USA",
"county": "Middlesex",
"stateProvince": "MA",
"zipPostalCode": "01887",
"zipPostalCodeExtension": "1234"
}
},
{
"exemptionReasonCode": "string",
"goodServiceCode": "5986334",
"grossAmount": 100,
"quantity": 3
}
]
}
Response
Body
{
"status": 200,
"message": "Successfully created new transaction with new state: EVALUATE",
"data": {
"currencyCode": "USD",
"totalTaxAmount": 18.75,
"billTo": {
"cityMunicipality": "WILMINGTON",
"stateProvince": "MA",
"country": "USA",
"county": "Middlesex",
"zipPostalCode": "01887",
"zipPostalCodeExtension": "1234",
"address": "200 Ballardvale ST"
},
"shipTo": {
"cityMunicipality": "WILMINGTON",
"stateProvince": "MA",
"country": "USA",
"county": "Middlesex",
"zipPostalCode": "01887",
"zipPostalCodeExtension": "1234",
"address": "200 Ballardvale ST"
},
"shipFrom": {
"cityMunicipality": "WILMINGTON",
"stateProvince": "MA",
"country": "USA",
"county": "Middlesex",
"zipPostalCode": "01887",
"zipPostalCodeExtension": "1234",
"address": "200 Ballardvale ST"
},
"lineItems": [
{
"identifier": "00000000",
"billTo": {
"cityMunicipality": "WILMINGTON",
"stateProvince": "MA",
"country": "USA",
"county": "Middlesex",
"zipPostalCode": "01887",
"zipPostalCodeExtension": "1234",
"address": "200 Ballardvale ST"
},
"shipTo": {
"cityMunicipality": "WILMINGTON",
"stateProvince": "MA",
"country": "USA",
"county": "Middlesex",
"zipPostalCode": "01887",
"zipPostalCodeExtension": "1234",
"address": "200 Ballardvale ST"
},
"shipFrom": {
"cityMunicipality": "WILMINGTON",
"stateProvince": "MA",
"country": "USA",
"county": "Middlesex",
"zipPostalCode": "01887",
"zipPostalCodeExtension": "1234",
"address": "200 Ballardvale ST"
},
"totalTaxAmount": 12.5,
"taxInfo": [
{
"type": "SALES_TAX",
"authorityName": "MA State Tax",
"stateOrProvince": "MASSACHUSETTS",
"country": "UNITED STATES",
"taxAmount": 12.5,
"taxRate": 0.0625,
"taxableAmount": 200.0,
"exemptAmount": 0.0,
"messages": [],
"jurisdictionType": "STATE"
}
]
},
{
"identifier": "00000001",
"totalTaxAmount": 6.25,
"taxInfo": [
{
"type": "SALES_TAX",
"authorityName": "MA State Tax",
"stateOrProvince": "MASSACHUSETTS",
"country": "UNITED STATES",
"taxAmount": 6.25,
"taxRate": 0.0625,
"taxableAmount": 100.0,
"exemptAmount": 0.0,
"messages": [],
"jurisdictionType": "STATE"
}
]
}
],
"invoiceDate": "2020-03-15",
"customerCode": "cu5689",
"invoiceNumber": "986521347adsfsf"
},
"success": true
}
Sample EVALUATE Request/Response B
Request
POST https://<S1 host>/api/basic-auth/simple-connect-ar/v1/transactions?state=EVALUATE
Body
{
"exemptionReasonCode": "RESELLER",
"invoiceDate": "2020-03-15",
"invoiceNumber": "986521347adsfsf",
"currencyCode": "USD",
"taxDirection": "FORWARD",
"customAttributes": {
"property1": "string",
"property2": "string"
},
"customerCode": "cu5689",
"billTo": {
"address": "200 Ballardvale ST",
"cityMunicipality": "WILMINGTON",
"country": "USA",
"county": "Middlesex",
"stateProvince": "MA",
"zipPostalCode": "01887",
"zipPostalCodeExtension": "1234"
},
"shipFrom": {
"address": "200 Ballardvale ST",
"cityMunicipality": "WILMINGTON",
"country": "USA",
"county": "Middlesex",
"stateProvince": "MA",
"zipPostalCode": "01887",
"zipPostalCodeExtension": "1234"
},
"shipTo": {
"address": "200 Ballardvale ST",
"cityMunicipality": "WILMINGTON",
"country": "USA",
"county": "Middlesex",
"stateProvince": "MA",
"zipPostalCode": "01887",
"zipPostalCodeExtension": "1234"
},
"lineItems": [
{
"billTo": {
"address": "200 Ballardvale ST",
"cityMunicipality": "WILMINGTON",
"country": "USA",
"county": "Middlesex",
"stateProvince": "MA",
"zipPostalCode": "01887",
"zipPostalCodeExtension": "1234"
},
"customerCode": "cu001",
"deliveryDate": "2019-06-21",
"description": "clothes",
"exemptionReasonCode": "string",
"goodServiceCode": "5986334",
"grossAmount": 200,
"quantity": 3,
"shipFrom": {
"address": "200 Ballardvale ST",
"cityMunicipality": "WILMINGTON",
"country": "USA",
"county": "Middlesex",
"stateProvince": "MA",
"zipPostalCode": "01887",
"zipPostalCodeExtension": "1234"
},
"shipTo": {
"address": "200 Ballardvale ST",
"cityMunicipality": "WILMINGTON",
"country": "USA",
"county": "Middlesex",
"stateProvince": "MA",
"zipPostalCode": "01887",
"zipPostalCodeExtension": "1234"
}
},
{
"exemptionReasonCode": "string",
"goodServiceCode": "5986334",
"grossAmount": 100,
"quantity": 3
}
]
}
Response
Body
{
"status": 200,
"message": "Successfully created new transaction with new state: EVALUATE",
"data": {
"currencyCode": "USD",
"totalTaxAmount": 18.75,
"billTo": {
"cityMunicipality": "WILMINGTON",
"stateProvince": "MA",
"country": "USA",
"county": "Middlesex",
"zipPostalCode": "01887",
"zipPostalCodeExtension": "1234",
"address": "200 Ballardvale ST"
},
"shipTo": {
"cityMunicipality": "WILMINGTON",
"stateProvince": "MA",
"country": "USA",
"county": "Middlesex",
"zipPostalCode": "01887",
"zipPostalCodeExtension": "1234",
"address": "200 Ballardvale ST"
},
"shipFrom": {
"cityMunicipality": "WILMINGTON",
"stateProvince": "MA",
"country": "USA",
"county": "Middlesex",
"zipPostalCode": "01887",
"zipPostalCodeExtension": "1234",
"address": "200 Ballardvale ST"
},
"lineItems": [
{
"identifier": "00000000",
"billTo": {
"cityMunicipality": "WILMINGTON",
"stateProvince": "MA",
"country": "USA",
"county": "Middlesex",
"zipPostalCode": "01887",
"zipPostalCodeExtension": "1234",
"address": "200 Ballardvale ST"
},
"shipTo": {
"cityMunicipality": "WILMINGTON",
"stateProvince": "MA",
"country": "USA",
"county": "Middlesex",
"zipPostalCode": "01887",
"zipPostalCodeExtension": "1234",
"address": "200 Ballardvale ST"
},
"shipFrom": {
"cityMunicipality": "WILMINGTON",
"stateProvince": "MA",
"country": "USA",
"county": "Middlesex",
"zipPostalCode": "01887",
"zipPostalCodeExtension": "1234",
"address": "200 Ballardvale ST"
},
"totalTaxAmount": 12.5,
"taxInfo": [
{
"type": "SALES_TAX",
"authorityName": "MA State Tax",
"stateOrProvince": "MASSACHUSETTS",
"country": "UNITED STATES",
"taxAmount": 12.5,
"taxRate": 0.0625,
"taxableAmount": 200.0,
"exemptAmount": 0.0,
"messages": [],
"jurisdictionType": "STATE"
}
]
},
{
"identifier": "00000001",
"totalTaxAmount": 6.25,
"taxInfo": [
{
"type": "SALES_TAX",
"authorityName": "MA State Tax",
"stateOrProvince": "MASSACHUSETTS",
"country": "UNITED STATES",
"taxAmount": 6.25,
"taxRate": 0.0625,
"taxableAmount": 100.0,
"exemptAmount": 0.0,
"messages": [],
"jurisdictionType": "STATE"
}
]
}
],
"invoiceDate": "2020-03-15",
"customerCode": "cu5689",
"invoiceNumber": "986521347adsfsf"
},
"success": true
}
Sample COMMIT Request/Response C
Request
POST https://<S1 host>/api/basic-auth/simple-connect-ar/v1/transactions/?state=COMMIT
Body
{
"exemptionReasonCode": "RESELLER",
"invoiceDate": "2020-03-10",
"invoiceNumber": "986521347sdf",
"currencyCode": "USD",
"taxDirection": "FORWARD",
"customAttributes": {
"property1": "string",
"property2": "string"
},
"customerCode": "cu56899",
"billTo": {
"address": "200 Chameleons ST",
"cityMunicipality": "WILMINGTON",
"country": "USA",
"county": "Middlesex",
"stateProvince": "MA",
"zipPostalCode": "01887",
"zipPostalCodeExtension": "1234"
},
"shipFrom": {
"address": "200 Chameleons ST",
"cityMunicipality": "WILMINGTON",
"country": "USA",
"county": "Middlesex",
"stateProvince": "MA",
"zipPostalCode": "01887",
"zipPostalCodeExtension": "1234"
},
"shipTo": {
"address": "200 Chameleons ST",
"cityMunicipality": "WILMINGTON",
"country": "USA",
"county": "Middlesex",
"stateProvince": "MA",
"zipPostalCode": "01887",
"zipPostalCodeExtension": "1234"
},
"lineItems": [
{
"billTo": {
"address": "200 Chameleons ST",
"cityMunicipality": "WILMINGTON",
"country": "USA",
"county": "Middlesex",
"stateProvince": "MA",
"zipPostalCode": "01887",
"zipPostalCodeExtension": "1234"
},
"customerCode": "cu001",
"deliveryDate": "2019-06-21",
"description": "clothes",
"exemptionReasonCode": "string",
"goodServiceCode": "5986334",
"grossAmount": 200,
"quantity": 3,
"shipFrom": {
"address": "200 Chameleons ST",
"cityMunicipality": "WILMINGTON",
"country": "USA",
"county": "Middlesex",
"stateProvince": "MA",
"zipPostalCode": "01887",
"zipPostalCodeExtension": "1234"
},
"shipTo": {
"address": "200 Chameleons ST",
"cityMunicipality": "WILMINGTON",
"country": "USA",
"county": "Middlesex",
"stateProvince": "MA",
"zipPostalCode": "01887",
"zipPostalCodeExtension": "1234"
}
},
{
"exemptionReasonCode": "string",
"goodServiceCode": "5986334",
"grossAmount": 1000,
"quantity": 3
}
]
}
Response
Body
{
"status": 200,
"message": "Successfully created new transaction with new state: COMMIT",
"data": {
"transactionId": "24fd6ddb-3938-4de3-b825-d245c8e85c62",
"currencyCode": "USD",
"totalTaxAmount": 75.0,
"billTo": {
"cityMunicipality": "WILMINGTON",
"stateProvince": "MA",
"country": "USA",
"county": "Middlesex",
"zipPostalCode": "01887",
"zipPostalCodeExtension": "1234",
"address": "200 Chameleons ST"
},
"shipTo": {
"cityMunicipality": "WILMINGTON",
"stateProvince": "MA",
"country": "USA",
"county": "Middlesex",
"zipPostalCode": "01887",
"zipPostalCodeExtension": "1234",
"address": "200 Chameleons ST"
},
"shipFrom": {
"cityMunicipality": "WILMINGTON",
"stateProvince": "MA",
"country": "USA",
"county": "Middlesex",
"zipPostalCode": "01887",
"zipPostalCodeExtension": "1234",
"address": "200 Chameleons ST"
},
"lineItems": [
{
"identifier": "00000000",
"billTo": {
"cityMunicipality": "WILMINGTON",
"stateProvince": "MA",
"country": "USA",
"county": "Middlesex",
"zipPostalCode": "01887",
"zipPostalCodeExtension": "1234",
"address": "200 Chameleons ST"
},
"shipTo": {
"cityMunicipality": "WILMINGTON",
"stateProvince": "MA",
"country": "USA",
"county": "Middlesex",
"zipPostalCode": "01887",
"zipPostalCodeExtension": "1234",
"address": "200 Chameleons ST"
},
"shipFrom": {
"cityMunicipality": "WILMINGTON",
"stateProvince": "MA",
"country": "USA",
"county": "Middlesex",
"zipPostalCode": "01887",
"zipPostalCodeExtension": "1234",
"address": "200 Chameleons ST"
},
"totalTaxAmount": 12.5,
"taxInfo": [
{
"type": "SALES_TAX",
"authorityName": "MA State Tax",
"stateOrProvince": "MASSACHUSETTS",
"country": "UNITED STATES",
"taxAmount": 12.5,
"taxRate": 0.0625,
"taxableAmount": 200.0,
"exemptAmount": 0.0,
"messages": [],
"jurisdictionType": "STATE"
}
]
},
{
"identifier": "00000001",
"totalTaxAmount": 62.5,
"taxInfo": [
{
"type": "SALES_TAX",
"authorityName": "MA State Tax",
"stateOrProvince": "MASSACHUSETTS",
"country": "UNITED STATES",
"taxAmount": 62.5,
"taxRate": 0.0625,
"taxableAmount": 1000.0,
"exemptAmount": 0.0,
"messages": [],
"jurisdictionType": "STATE"
}
]
}
],
"invoiceDate": "2020-03-10",
"customerCode": "cu56899",
"invoiceNumber": "986521347sdf"
},
"success": true
}