All Classes Pages
Introduction

Overview

The ECE REST API provides a simple and powerful way to interact with resources, such as Article, Case, Activity, or Customer in ECE Platform using the standard HTTP methods (GET, PUT, POST, and DELETE).
  • GET method allows retrieving a resource
  • POST method allows creating a new resource
  • PUT method allows updating a resource
  • DELETE method allows deleting or removing a resource
Since ECE REST API operates over HTTP(s), it makes it easy to use it with any programming language or framework. The API can be used for many purposes, including:
  • Building mobile apps and modern web applications.
  • Integrating ECE platform with other applications.

Getting Started With ECE REST API

Before you begin working with ECE API it is important to understand some of its key characteristics.

Stateless

ECE REST APIs are stateless. All the necessary information to process a request is contained in the request itself. No context information is stored on the server to process the request. Statelessness improves the API performance, and allows better scalability for the application.

Layered

The REST architecture of ECE APIs allows the existence of intermediaries such as gateways, proxies, or load balancers between the client and the server to facilitate improved scalability and to enforce security policies.

Support for XML and JSON

ECE REST API supports both XML and JSON as the data format for requests and responses. The default format is XML.
Use the HTTP header Accept:application/json to select JSON or Accept:application/xml to select XML.

     Date and Time format
Date and time information in requests and responses follows the ISO 8601 format.

Authentication

ECE REST API supports session based authentication. To learn more about authentication refer Understanding Authentication.

Compression

In order to improve performance, ECE API allows the use of compression on responses.

     Response Compression
You can request compression on the responses by using the HTTP header Accept-Encoding:gzip in a request. The response is compressed if a client specifies this header in the request, and the response includes HTTP header Content-Encoding:gzip to indicate response compression
     Request Compression
Compressing of requests is not supported at this time.

Optimized Responses

ECE API responses are optimized to minimize the network traffic. As a result, the response includes only a pre-defined set of attributes; the other parts of the resource are not included in the response unless explicitly requested. You can request additional attributes of a resource by using the $attribute query parameter.

Use the $attribute query parameter to specify a comma-separated list of additional attributes that you want in the response. For example, appending $attributes=keywords,summary to an Article URI's request will result in inclusion of keywords and summary for the requested article. You can also use $attributes=all, a special construct, to request all the attributes of a resource.

Support for CORS

ECE REST API supports Cross-origin resource sharing (CORS). CORS is a mechanism that allows resources (e.g. fonts, JavaScript, etc.) on a web page to be requested from another domain outside the domain from which the resource originated.
You can configure a whitelist of the origins for ECE REST API from the ECE Administration Console.

Scope of the API

The API currently covers the following areas:

Administration APIs:

Interaction:

Messaging APIs:

Common APIs: