iPaaS Integration Guide
How to successfully integrate a sales channel.
With a channel, you will create Orders and read fulfillments and inventory.
Background
You'll need a few things to successfully interact with our API and these values will be unique for each ChannelApe customer.
- Business ID
- Channel ID
- API Token
Please reach out to support@channelape.com if you need help with account access for a specific customer.
Our APIs are rate limited so keep an eye out for 429 errors and exponentially backoff.
Notes
- Additional Fields are custom data in the form of "key:value" pairs that exist on order level, line item level, fulfillment level, and refund level. You can use them to pass in any custom metadata not supported as named fields.
Setup
How to find your Business ID
- Login at https://app.channelape.io/
- Once logged in, in the main URL you'll see a path like this:
https://app.channelape.io/xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx/orders - The UUID in the URL is your businessId
How to generate an API Account/Token
- Login at https://app.channelape.io/
- Generate an API account (and token) for the business you are going to test with.
- You can find this in the left sidebar nav, under Business.
If you don't see Business in the left sidebar, email support@channelape.com and ask them to make your email address a Business Admin.
- You can find this in the left sidebar nav, under Business.
How to generate a Channel ID
- In the left sidebar nav, under Integrations, click Available tab and install a "Webhook Channel".
- Give it a name ie. "Shopify", use 300 for "Health Check Interval" and for the purpose of this guide put in any URL (ie. "https://www.google.com") for "Payload URL". This won't matter for this guide and is intended for another purpose.
- Click install once, and wait for page to refresh.
- Once installed, go to Integrations again in the sidebar and under installed, you'll see your new webhook channel. If you right click the icon and copy link address, you'll see the UUID ID in the URL: "https://app.channelape.com/channel/webhook/xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx/update". This is the ChannelId you'll need to test with the whole time.
Orders
Create
- You'll want to create orders (POST Create order) in ChannelApe with an "OPEN" status.
- We'll then pick up the order and process and if successfully processed for fulfillment, status will change to IN_PROGRESS.
- We'll then pick up the order and process and if successfully processed for fulfillment, status will change to IN_PROGRESS.
Close orders
- Please change the order status to CLOSED when Sales Channel closes the order.
- PATCH on the order status will work here.
Cancel / Refund
- If Sales Channel cancels or refunds the order, please change the order status to CANCELED.
{
"channelId": "1ebdea44-9709-46cc-a5d1-78a782de1dd0",
"channelOrderId": "e741ec6f-538f-4820-9cc2-c8ec1da36811",
"status": "OPEN",
"alphabeticCurrencyCode": "USD",
"totalPrice": "30.80",
"subtotalPrice": "30.80",
"totalTax": "1.97",
"totalShippingPrice": "3.00",
"totalShippingTax": "0.18",
"totalGrams": "226.796",
"purchasedAt": "2015-09-11T20:52:15.000Z",
"customer": {
"name": "Dan Nino",
"firstName": "Dan",
"lastName": "Nino",
"email": "iomalte14@yopmail.com",
"phone": "(570)555-1234",
"shippingAddress": {
"name": "Dan Nino",
"firstName": "Dan",
"lastName": "Nino",
"company": "ChannelApe",
"address1": "224 Wyoming Avenue",
"address2": "Rear of 1st Floor",
"city": "Scranton",
"province": "Pennsylvania",
"provinceCode": "PA",
"country": "United States",
"countryCode": "US",
"postalCode": "18503",
"phone": "(555)555-5555",
"additionalFields": [
{
"name": "shipping_address_id",
"value": "3425252"
},
{
"name": "note",
"value": "Leave with dog."
}
]
},
"billingAddress": {
"name": "Dan Nino",
"firstName": "Dan",
"lastName": "Nino",
"company": "ChannelApe",
"address1": "224 Wyoming Avenue",
"address2": "Rear of 1st Floor",
"city": "Scranton",
"province": "Pennsylvania",
"provinceCode": "PA",
"country": "United States",
"countryCode": "US",
"postalCode": "18503",
"phone": "(555)555-5555",
"additionalFields": [
{
"name": "billing_address_id",
"value": "897987466"
},
{
"name": "note",
"value": "Paid with PayPal"
}
]
},
"additionalFields": [
{
"name": "FirstTimeCustomer",
"value": "false"
},
{
"name": "InternationalCustomer",
"value": "false"
}
]
},
"lineItems": [
{
"id": "52365397597450",
"sku": "0Z-DAPL-Y6NE",
"upc": "442806190",
"price": "30.80",
"shippingPrice": "3.00",
"shippingTax": "0.18",
"shippingMethod": "2nd Day Air",
"quantity": 1,
"title": "Metagenics Multigenics Intensive Care without Iron 180T",
"vendor": "Metagenics",
"grams": "226.796"
}
],
"additionalFields": [
{
"name": "EarliestShipDate",
"value": "2015-09-14T07:15:36Z"
}
]
}
Fulfillments
Check for fulfillments
- You'll need to enumerate orders (GET Query orders by channel) to check for fulfillments but we have a few query parameters to make this easier/reduce load:
- status: set this to IN_PROGRESS
- updatedAtStartDate: set this to the last timestamp you queried in ISO 8601 format
- A fulfillment with a status of PENDING, NEW, BACKORDERED, or CANCELED is not fulfilled; you'll want to make sure the status is OPEN and there is at least a trackingNumber on it
Acknowledge Fulfillment
- Please change the fulfillment status to SUCCESS after you successfully post it to the sales channel.
- You should PATCH to update the entire fulfillments list on the order level as there is no fulfillments subresource at this time. You cannot just PATCH status and must resend the entire list.
{
"fulfillments": [
{
"id": "94938",
"status": "SUCCESS",
"shippingCompany": "UPS",
"shippingMethod": "SecondDay",
"trackingNumber": "AF335244",
"shippedAt": "2015-09-11T21:52:15.000Z",
"lineItems": [
{
"id": "52365397597450",
"sku": "0Z-DAPL-Y6NE",
"upc": "442806190",
"price": "30.80",
"shippingPrice": "3.00",
"shippingTax": "0.18",
"shippingMethod": "2nd Day Air",
"quantity": 1,
"title": "Metagenics Multigenics Intensive Care without Iron 180T",
"vendor": "Metagenics",
"grams": "226.796",
"additionalFields": [
{
"name": "QuantityShipped",
"value": "1"
}
]
}
],
"additionalFields": [
{
"name": "WarehouseID",
"value": "CA-34"
}
]
}
]
}
Inventory
Get current inventory by location, status and SKU
- You'll need access to a business within the ChannelApe webapp that has administrator access to both settings and business intelligence.
- Once logged in, go to Inventory > List in the left sidebar.
- Once the list loads, go to the three dot menu for "Inventory List" and go to "Explore from here"
- Once the "Explore from here" loads, customize the output the way you'd like with fields and columns or to use as is, go to the cog menu and click Save and Schedule.
- Give the report a title and save it.
- Once saved, you'll now see the report. Click the gear icon in the top right to schedule to S3, FTP, or other location and pick the schedule of when you'd like this updated.
- The status that should be used for almost all Sales Channels is "Available to Promise" ie. ATP
- ATP accounts for all committed inventory, inbounds, reserves and on holds automatically.
- The location that should normally be used is the "Virtual Sales Channel". ChannelApe maintains a Virtual Sales Channel for most customers with multiple warehouse locations making it easier for you as the integrator to only have to use that location for ATP inventory.