APIs

This section gives you information about how to use the various parts of the DataConnect.io API and what they do. We have organized the DataConnect.io API into four logical parts:

API Purpose
app Used to establish connections between your application and the remote platform (and set it up according to your settings.)
native-api General-purpose proxy to access the platform native API for direct interaction if needed.

Base path

The base path for DataConnect.io is: https://api.dataconnect.io. You will use this when making your requests to any of our endpoints.

App

The app API provides provides a unified sign-up flow that lets you connect shops on supported platforms to your solution. It also provides some additional endpoints that provide information about the versions of different platforms that DataConnect.io supports, as well as which features are supported for each platform.

To use the app API you will need:

  • the DataConnect.io base path https://api.dataconnect.io
  • the name of the platform you wish to interact with. Currently only ebay and shopify are supported. DataConnect.io will inform you when new platforms come online.
  • your project id. If you don't have this to hand, you can get it at any time by logging into the DataConnect.io developer's portal.

NOTE All endpoints of the app API are publicly available and can be accessed without requiring additional authentication.

API URI HTTP operation Purpose
/v2/platforms/{platform-name}/apps/{project-id}/install GET The unified sign-up to let a user activate/install/authorize your application on the remote platform.

A common way for people to integrate the call to the endpoint for the unified sign-up flow is to simply:

  • Link to the endpoint using a "Connect with..." button on their website.
  • When the call is invoked the user will be redirected to the shopping platform in question, where they can grant access to your solution.
  • The shopping platform will then redirect them to your page, to continue the flow.

RESTHook

We use RESThooks to immediately POST and PUT an entity via HTTP(s) and JSON to your application.

  • A subscription to the hooks used is enabled every time you use a connector to connect a shop/account.
  • You will be shown how to configure the target resthookUrl when you set-up your connector in the DataConnect.io developer's portal.
  • Any new entities or updates are transmitted to this target url via HTTP(s) as JSON.

If normalization is enabled, the RESTHook will add path segments, e.g.

  • Results from connections without normalization will be written to the defined base URL.
  • Normalized order data will be written to baseURL + "/orders" path.
  • Normalized product data will be written to baseURL + "/products" path.
  • PUT operations will ADDITIONALLY add the entity's id to the path, i.E. baseURL + "/orders/" + orderId

For authentication of the incoming data and easier handling on the client-side (e.g. the QuickStart app or your custom solution), we add a set of headers.

Additional HTTP headers

We also append a couple of custom headers prefixed with "X-DC" to help you handle the hook data. Non-normalized data

X-DC-CONNECTION-ID: <uuid-of-the-connection>
X-DC-ENTITY-ID: <id-on-remote-platform>
X-DC-PIPELINE-ID: <a-uuid-for-this-hook>
Authoriziation: Bearer  <jwt-token>

Normalized data

X-DC-CONNECTION-ID: <uuid-of-the-connection>
X-DC-ENTITY-ID: <the-id-on-the-remote-platform>
X-DC-ENTITY-CHECKSUM: <a-hash-of-the-payload>
X-DC-PIPELINE-ID: <a-uuid-for-this-hook>
Authoriziation: Bearer <jwt-token>

X-DC-ENTITY-CHECKSUM is used to help handle updates and deletes on existing entities, as identified by X-DC-ENTITY-ID.

Native API

We provide a separate section for native API.