APIDefinition

Summary

An API definition.

Description

The API definition is a representation of a backend serivce. The name and basePath are required. If the API administrator creates the API definition, then organizationId is also required, otherwise it defaults to the Organization from which it is created.

Fields

Field Name Type Since Version Description
id String A unique identifier.
name String The name of the API.
summary String A summary of the API.
description String A detailed description of the API.
version String The API version.
basePath String The base path is where the API service is hosted.
resourcePath String The resource path is applied to basePath to provide the prefix for all API methods.
models {String, Object} The models/schema the that the API
consumes [String] The content types that the API consumes
produces [String] The content types that the API produces
integral Boolean Indicates that the API definition is integral to a frontend API; that the API was imported to define the frontend API.
createdOn Long Epoch/Unix time stamp when the organization was created.
createdBy String The identifier of the user that created the API.
organizationId String The Organization identifier.
serviceType String Indicates the type of service being imported. Possible values: rest, wsdl.
hasOriginalDefinition Boolean Indicates whether or not an original definition is available
importUrl String Specifies the URL used to import the backend API definition.
properties {String, String} A list of properties associated with this API.

Example JSON

{
  "id" : "6d81f576-bf40-4fbd-8625-63d8f206f649",
  "name" : "My API",
  "summary" : "This is a summary of my API",
  "description" : "This is my API",
  "version" : "1.0",
  "basePath" : "http://basepath.org",
  "resourcePath" : "/api",
  "models" : {
    "User" : {
      "type" : "object",
      "required" : [ "id", "name", "email" ],
      "properties" : {
        "id" : {
          "type" : "string"
        },
        "name" : {
          "type" : "string"
        },
        "email" : {
          "type" : "string"
        }
      }
    }
  },
  "consumes" : [ "\"application/json\"" ],
  "produces" : [ "\"application/json\"" ],
  "integral" : true,
  "createdOn" : 1364287486876,
  "createdBy" : "a1c70859-702b-4f3a-a1ad-a61067fdc4c7",
  "organizationId" : "7d82323230-4fbd-8625-63d8f206f649",
  "serviceType" : "wsdl",
  "hasOriginalDefinition" : true,
  "importUrl" : "http://petstore.swagger.io/v1/swagger.json",
  "properties" : {
    "ServiceName" : "Calculator",
    "Type" : "WSDL"
  }
}