Introduction

Hosts

The REST API lets you interact directly with EdiNation from anything that can send an HTTP request. All API access must use HTTPS. The primary host is:

api.edination.com

Enterprise plan users with dedicated hosts will have the host in the following format, where the id will be assigned individually:

api-{id}.edination.com

 

Versioning

When we make backward-incompatible changes to the API, we release new versions. The latest version is v2. The version number must be added as a postfix to the base URL to identify the correct endpoint for that version.

The endpoint for v2 is:

api.edination.com/v2

 

Format

The API uses the following formats:

  1. JSON encoded as UTF-8 for all resources and errors
  2. Content-Type form-data when uploading EDI files for translation
  3. Content-Type application/octet-stream when downloading generate EDI files or acknowledgments

 

Parameters

Unless otherwise stated, parameters must be passed in the URL's query string for all requests (GET, DELETE, and POST). Parameters must be properly URL-encoded, using the UTF-8 encoding for non-ASCII characters.

 

Authentication

Authentication is done via HTTP headers:

  Ocp-Apim-Subscription-Key

authenticates the endpoint (you need to pass the API key created in the developer portal)

For JavaScript usage, EdiNation supports Cross-Origin Resource Sharing (CORS), so that you can use these headers in conjunction with XMLHttpRequest.

 

Endpoints

Verb Operation Description
POST /x12/read Translate X12 file to X12 JSON
POST /edifact/read Translate EDIFACT file to EDIFACT JSON
POST /x12/write Translate X12 JSON to X12 file
POST /edifact/write Translate EDIFACT JSON to EDIFACT file
POST /x12/validate Validate X12 JSON
POST /edifact/validate Validate EDIFACT JSON
POST /x12/ack Generate X12 997, 999 and/or TA1
POST /edifact/ack Generate EDIFACT CONTRL

 

Models Casing

The API is case insensitive, and you can use your preferred casing convention, camel case or other, to consume the API.

Was this article helpful?
0 out of 0 found this helpful