Creating REST Services

Create and manage REST services in InterSystems IRIS from OpenAPI 2.0 specifications.

Updated Feb 2, 2026
One-click install
npx skills add https://github.com/sorodriguezz/skills-objectscript --skill creating-rest-services
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: Creating REST Services
Source: https://github.com/sorodriguezz/skills-objectscript/tree/main/skills/creating-rest-services
Command: npx skills add https://github.com/sorodriguezz/skills-objectscript --skill creating-rest-services

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) components.

What problem does it solve?

This Skill simplifies the process of creating, deploying, and managing RESTful web services within the InterSystems IRIS data platform, enabling seamless integration with external applications and services.

Core Features & Use Cases

  • REST Service Creation: Generate REST service classes from OpenAPI 2.0 specifications using API management tools or command-line routines.
  • Specification-First Development: Define your API contract using OpenAPI and let InterSystems IRIS generate the necessary code.
  • Manual Coding Option: Create REST services by manually coding dispatch classes for older InterSystems IRIS versions.
  • API Management Tools: Utilize the /api/mgmnt/ service, ^%REST routine, or %REST.API class for streamlined service lifecycle management.
  • Use Case: A developer needs to expose existing InterSystems IRIS data and business logic as a REST API for a new web front-end. This Skill guides them through defining the API contract, generating the service, and implementing the business logic.

Quick Start

Use the creating-rest-services skill to generate REST service classes from an OpenAPI 2.0 specification file named 'api-spec.json'.

Frequently Asked Questions about Creating REST Services

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I create REST web services in InterSystems IRIS from an OpenAPI specification?

To create REST web services in InterSystems IRIS, you can use specification-first development by providing an OpenAPI 2.0 file. The platform automatically generates the necessary REST service classes using API management tools like the /api/mgmnt/ service.

What is the best way to manage the lifecycle of a REST API in InterSystems IRIS?

The best way to manage a REST API lifecycle in InterSystems IRIS is using built-in tools like the /api/mgmnt/ service, the ^%REST routine, or the %REST.API class. These tools handle service creation, updates, and deployment seamlessly.

Can I manually code REST services in InterSystems IRIS without an OpenAPI spec?

Yes, you can manually code REST services in InterSystems IRIS by creating custom dispatch classes. This approach is often used for older InterSystems IRIS versions or when a specification-first development workflow is not required.

How does specification-first development work for REST APIs in InterSystems IRIS?

Specification-first development in InterSystems IRIS works by defining your API contract using OpenAPI 2.0. The system then reads this specification and automatically generates the corresponding REST service classes and boilerplate code for you.

Do I need OpenAPI 2.0 to generate REST service classes in InterSystems IRIS?

No, you do not need OpenAPI 2.0 to generate REST services. While OpenAPI 2.0 enables automatic specification-first generation, you can alternatively write manual dispatch classes to build your RESTful web services.

What are the limitations of using the ^%REST routine for API creation?

The ^%REST routine is specifically tailored for OpenAPI 2.0 specifications. A key limitation is that if you need to support older InterSystems IRIS versions or custom routing outside standard specifications, you must bypass it and manually code dispatch classes.