iconik Swagger definitions

Using the API definition files in interesting ways

Swagger Definition List

The iconik API documentation for each API endpoint is powered by Swagger, you can access each of the spec files here.

acls/
Access Control List for Groups, Users, Shares and Objects
assets/
Assets, Collections, Delete Queue and associated sub-resources
auth/
Authentication, SAML, Apps and System Domain
files/
Automations
automations/
Files, Formats, Storage and Transcoders
jobs/
Jobs
metadata/
Metadata, Metadata Views and Metadata on Objects
ml/
Machine Learning, Face Recognition
notifications/
Webhook definitions
search/
Search, Discovery, Saved Searches and associated sub-resources
settings/
Settings
stats/
Already exists
transcode/
Create & Cancel Transcodes, AI and Keyframe Jobs
users/
Users, Groups and associated sub-resources
users-notifications/
User notifications and associated sub-resources

Importing into an API client

The Swagger definition file can be downloaded and imported into certain API clients such as Postman, so that you have all the APIs that we support imported automatically.

Simply use the above list to access the Swagger file.

Postman

Take a look at the documentation here on the Postman site on how to achieve this.

We would recommend setting up an environment in Postman with the authentication headers that are needed along with the server name to your iconik API. This makes it easier to consume the API as the swagger definition doesn't contain the needed header information.

Paw

Paw can also import the swagger definitions. Please read their documentation on how to import the Swagger definition

You can use environments to configure default values for that environment, such as the Host and headers. Read more in their documentation.

If you want to replace the basePath with a HOST variable you can use wget and sed to do a replacement. The following example will get the Stats spec, and replace base path with a HOST variable

wget -q -O - http://app.iconik.io/docs/stats/spec | sed 's/basePath\"\: \"\/API/basePath\"\: \"{{HOST}}\/API/' > stats.spec

Auto-generating API code

The Swagger project has a tool, Swagger Codegen to which you can import a definition file and it will generate code automatically to help in your development.

Swagger Codegen supports more than 40 different languages currently, so it's more than likely that a language you are using could have an SDK generated.