API PUBLISHER - HOWTO

Prerequisite

Create a RAML file to describe your API. (Example RAML file)

RAML

Publish an API

You can publish an API from a RAML file with the following command:
curl -XPOST http://localhost:9019/publish -H "Content-Type: text/plain" --data-binary @ramlFile

Definition

An API is defined by its context and its version.
It contains a number of endpoints which can be either open, application-restricted or user-restricted.
The API context is determined by the prefix of the API request while the version is determined by the Accept header.

Versioning

There is one RAML file per API Version.
The API Gateway will select the version depending of the Accept Header sent in the request.
For example, Accept: application/vnd.scapig.1.0+json will route to version 1.0.

Lifecycle

The API lifecycle is defined by the status published in the RAML file which can have any of the following:
Status Description
Prototyped The API is available for developers to use.
However they will be warned on the developer hub that they are very likely to change and should expect breaking changes.
Published The API is in Production mode. Breaking changes are not allowed at this state.
Deprecated The version will soon reach end of life. Developers can not subscribe anymore to this version and existing applications are advised to migrate to a new version.
Retired The version is not available anymore on the platform and the gateway will reject requests using this version.