Announcement
· Apr 13, 2020

REST API Contest details: Application types and bonuses

Hi Developers!

Today we launched the second programming contest on InterSystems IRIS, the landing.

The topic is the REST API.

And we introduced a few technology bonuses.

Here I want to provide details on what application eligible, what are the technology bonuses and how to collect all of them.

Here we go!

REST API requirement

As stated in the rules, your application should use REST API or web-sockets on the side of InterSystems IRIS. IRIS Documentation on REST API.

When cloned or downloaded the application should be runnable with:

$ docker-compose up -d

Or installed as a ZPM module, like:

zpm:USER>install module-name

Once installed, the application REST API or Web Sockets application should be available at localhost:anyport/your/application.

What applications you can submit?

You can build the REST API by yourself. Examples:

You can use in your application any REST API libraries, published in Open Exchange.

Or use any IRIS out-of-the-box REST API which you can check on  http://yourserver:port/api/mgmnt/ or http://localhost:52773/api/mgmnt/.

Among them are:

Examples of applications that use internal REST-API: objectscript-openapi-definition, iris explorer and more.

Your application can be only REST API (case 1), or can also have a UI built around the REST API (case 1, 2, 3).

Technology Bonuses

With Technology Bonuses we give you the option to earn additional "technology votes" for your application in Experts Nomination. Each technology bonus gives one vote.

➡️ ZPM Package

To get this bonus you should publish your solution as a ZPM package. This will let anyone install your application as:

zpm:USER>install application

Example application for REST-API. 

Learn more in "How to publish a package on Open Exchange" article and check the  ZPM documentation.

➡️ Open API (Swagger) Spec

You'll get this bonus if your application exposes /_spec endpoint (and /info), which provides the specification of the REST API using Open API 2.0 or Open API 3.0

The REST Contest template could be a good example of how to generate /_spec for your REST API.

➡️ Spec-first development approach

You can collect this point if you will start to develop your application from describing the Open API specification first. And then generate REST API upon it using IRIS services and even more with this helpful application.

Example 1, Example 2, Example 3. Documentation.

Notice, if you follow a spec-first approach, you get two bonuses: Spec-first and Open API Spec because with the spec-first approach you get /_spec endpoint generated automatically.

Sample application

Here is the sample template application objectscript-docker-rest-template

It gets one technology bonus point because it could be also installed as ZPM module with the command:

zpm:USER>install rest-template

And it gets another technology bonus because it exposes swagger spec on localhost:port/crud/_spec.

REST API Documentation could be published by Postman or can be viewed by any swaggerUI service. E.g. with addons as iris-expolrer, or swagger-ui package.

You can use this application as a template.

Good luck and happy coding!

Discussion (7)2
Log in or sign up to continue

Updated the post regarding the list of internal REST API:

Or use any IRIS out-of-the-box REST API which you can check on  http://yourserver:port/api/mgmnt/

http://localhost:52773/api/mgmnt/

Amongst them are:

Atelier API: /api/atelier

IRIS BI API: /api/deepsee

DocDB API :/api/docdb

IRIS NLP(iknow) API: /api/iknow

Monitoring API: /api/monitor

Swagger Management API: /api/mgmnt

UIMA API: /api/uima

Added the information about Sample application:

Sample application

Here is the sample template application objectscript-docker-rest-template

It gets one technology bonus point because it could be also installed as ZPM module with the command:

zpm:USER>install rest-template

And it gets another technology bonus because it exposes swagger spec on localhost:port/crud/_spec.

REST API Documentation could be published by Postman or can be viewed by any swaggerUI service. E.g. with addons as iris-expolrer, or swagger-ui package.

You can use this application as a template.