The GET Closure Code Incident Master API retrieves Closure Code master data from the Incident Management (IM) module. The API response matches the Closure Code records displayed in the UI.
The API supports the following operations:
Retrieve List of Closure Code Master Records
This endpoint retrieves all Closure Code master records configured in the Incident Management module. Administrators, integrations, and automation tools can use the endpoint for configuration review, validation, reporting, and downstream processing.
Endpoint
GET /API/v1/Master/IM/ClosureCode
Component | Value | Description |
|---|---|---|
HTTP Method | GET | Retrieves data from the server. The operation only reads data and does not create, update, or delete records. |
API | API | Stands for Application Programming Interface. It provides a standard way for applications to communicate with the system and exchange data. |
Version | v1 | Indicates Version 1 of the API. Versioning helps maintain compatibility when developers introduce new API versions. |
Resource Group | Master | Refers to the Master Data module, which contains reusable reference data such as Closure Codes, Classifications, Categories, Priorities, Statuses, and Locations. |
Module | IM | Stands for Incident Management. It identifies that the requested master data belongs to the Incident Management module. |
Resource | ClosureCode | Specifies the Closure Code master data resource to retrieve. Closure Codes identify how users resolved or closed Incidents. |
Request Headers
{
"Accept": "application/json",
"X-Api-Key": "<API_KEY>"
}Header | Value | Required | Description |
|---|---|---|---|
Accept | application/json | Yes | Requests the API to return the response in JSON format. |
X-Api-Key |
| Yes | API key for authentication and authorization. |
Sample Request
The following cURL request sends an HTTP GET request to retrieve all Closure Code master records. The request includes the Accept header to specify JSON as the expected response format and the X-Api-Key header to authenticate the caller.
Replace <API_KEY> with a valid API key before sending the request. Replace {host} with the appropriate server address when calling the API from another environment.
curl --location '{host}/API/v1/Master/IM/ClosureCode' \
--request GET \
--header 'Accept: application/json' \
--header 'X-Api-Key: <API_KEY>'Sample Response
The following sample response returns an array of Closure Code master records. Each object represents one Closure Code configured in the Incident Management module. Value uniquely identifies the record, Text provides its display name, Active indicates whether available for use, and Is_Default identifies whether the system uses it as the default Closure Code.
[
{
"Value": 1001,
"Text": "Resolved Successfully",
"Active": true,
"Is_Default": true,
"Instance": 1,
"Instance_Text": "Production"
},
{
"Value": 1002,
"Text": "Duplicate Incident",
"Active": true,
"Is_Default": false,
"Instance": 1,
"Instance_Text": "Production"
}
]Response Fields
The Closure Code master list exposes the following fields:
Field | Type | Example Value | Description |
|---|---|---|---|
Value | Integer | 1001 | Unique value or identifier of the Closure Code record. |
Text | String |
| Display name of the Closure Code. |
Active | Boolean |
| Indicates whether the Closure Code record is active and available for use. |
Is_Default | Boolean |
| Indicates whether the system uses the Closure Code as the default value. |
Instance | Integer or String | 1 | Identifier of the instance associated with the Closure Code. |
Instance_Text | String |
| Display name of the instance associated with the Closure Code. |
Business Use Cases
Scenario | Resolution |
|---|---|
An integration needs valid Closure Code values before closing an Incident. | Call the GET Closure Code Incident Master API to retrieve the configured Closure Code records. Use the returned Closure Code identifier in the Incident closure request. |
An external system stores Closure Code mappings for Incident synchronization. | Call the API to retrieve the latest Closure Code master records and synchronize them with the external system's mapping table. |
An automated process receives a Closure Code name but requires its unique identifier. | Retrieve the Closure Code master list, locate the record with the matching name, and use its |
A scheduled integration must keep Closure Code reference data up to date. | Call the API at scheduled intervals and compare the response with the Closure Code records stored in the consuming system. Add, update, or deactivate mappings as required. |
An integration must verify a Closure Code before closing an Incident. | Call the API and confirm that the Closure Code exists and that its |
An automated process must determine the default Closure Code. | Check the |
You are migrating Incident data from another system. | Retrieve all valid Closure Code records and map the source-system closure values to the corresponding Closure Code identifiers before migrating the Incident records. |
An integration supports many application instances. | Use the |
Expected Result
Returns HTTP 200 OK.
Returns all available Closure Code master records configured for Incident Management.
Returns details for each Closure Code, including its identifier, display name, active status, default setting, and instance information.
Sample Expected Result
The API successfully retrieves the list of Closure Code master records configured for Incident Management.
[
{
"Value": 1001,
"Text": "Resolved Successfully",
"Active": true,
"Is_Default": true,
"Instance": 1,
"Instance_Text": "Production"
},
{
"Value": 1002,
"Text": "Duplicate Incident",
"Active": true,
"Is_Default": false,
"Instance": 1,
"Instance_Text": "Production"
}
]Retrieve Closure Code Master Record Details
This endpoint retrieves the details of a specific Closure Code master record by using its unique record ID.
Endpoint
GET /API/v1/Master/IM/ClosureCode/{recordId}
Component | Value | Description |
|---|---|---|
HTTP Method | GET | Retrieves data from the server. The operation reads data only and does not create, update, or delete records. |
API | API | Stands for Application Programming Interface. It provides a standard way for applications to communicate with the system and exchange data. |
Version | v1 | Indicates Version 1 of the API. Versioning helps maintain compatibility as new API versions emerge. |
Resource Group | Master | Refers to the Master Data module, which contains reusable reference data. |
Module | IM | Stands for Incident Management. It identifies that the requested master data belongs to the Incident Management module. |
Resource | ClosureCode | Specifies the Closure Code master data resource to retrieve. |
Record Identifier |
| The unique identifier of the Closure Code record to retrieve. Replace this placeholder with an actual record ID, such as |
Path Parameter
Parameter | Type | Required | Description |
|---|---|---|---|
recordId | Integer | Yes | Unique identifier of the Closure Code master record. |
Request Headers
{
"Accept": "application/json",
"X-Api-Key": "<API_KEY>"
}Header | Value | Required | Description |
|---|---|---|---|
Accept | application/json | Yes | Requests the API to return the response in JSON format. |
X-Api-Key |
| Yes | Provides the API key to authenticate the caller and grant access to the endpoint. |
Sample Request
The following request retrieves the Closure Code master record with the record ID 1001. Supply recordId as a path parameter to identify the specific record.
Replace 1001 with the record ID of the Closure Code that you want to retrieve. Replace <API_KEY> with a valid API key. Replace {host} with the appropriate server address when calling the API from another environment.
curl --location '{host}/API/v1/Master/IM/ClosureCode/1001' \
--request GET \
--header 'Accept: application/json' \
--header 'X-Api-Key: <API_KEY>'Sample Response
The response returns the Closure Code master record whose Value matches the record ID specified in the request URL.
{
"Value": 1001,
"Text": "Resolved Successfully",
"Active": true,
"Is_Default": true,
"Instance": 1,
"Instance_Text": "Production"
}
In this example, the API returns the Closure Code named Resolved Successfully with the following configuration:
Field | Value | Description |
|---|---|---|
Value | 1001 | Uniquely identifies the Closure Code record. |
Text | Resolved Successfully | Specifies the display name of the Closure Code. |
Active |
| Indicates that the Closure Code is active and available for use. |
Is_Default |
| Indicates that the system uses this record as the default Closure Code. |
Instance | 1 | Identifies the application instance associated with the Closure Code. |
Instance_Text | Production | Provides the display name of the associated application instance. |
An integration can use these values to verify the Closure Code configuration before using its identifier in an Incident closure request.
Note
The
Activefield shows whether the Closure Code is available for use. TheIs_Defaultfield shows whether the system uses it as the default Closure Code. TheInstanceandInstance_Textfields identify the associated application instance.
Business Use Cases
Scenario | Resolution |
|---|---|
An external system receives an Incident that contains a Closure Code record ID. | Retrieve the specific Closure Code record to get its name and configuration before processing or synchronizing the Incident. |
An integration must check a Closure Code before closing an Incident. | Retrieve the Closure Code by |
A synchronization process detects that one Closure Code record has changed. | Retrieve only the affected Closure Code record and update its mapping in the target system without retrieving the complete Closure Code master list. |
An Incident imported from another system contains an existing Closure Code mapping. | Retrieve the mapped Closure Code record to confirm that the stored record ID still corresponds to the expected Closure Code. |
An automated workflow must apply rules based on a Closure Code's configuration. | Retrieve the Closure Code record and check its active status, default setting, and instance information before continuing the workflow. |
A reporting system contains a Closure Code ID but not its descriptive name. | Retrieve the Closure Code record and use its |
An integration must determine whether a known Closure Code is the default. | Retrieve the Closure Code record and check whether |
A Closure Code mapping fails during Incident processing. | Retrieve the Closure Code using the mapped |
Expected Result
Returns HTTP 200 OK.
Returns the Closure Code master record that matches the specified
recordId.Returns the Closure Code identifier, display name, active status, default setting, and instance information.
Sample Expected Result
The API successfully retrieves the Closure Code record with the record ID 1001.
{
"Value": 1001,
"Text": "Resolved Successfully",
"Active": true,
"Is_Default": true,
"Instance": 1,
"Instance_Text": "Production"
}Error Responses
401 Unauthorized
Returned when the request does not include a valid API key or the caller does not have authenticated access.
The following request does not include the required X-Api-Key header:
curl --location '{host}/API/v1/Master/IM/ClosureCode' \
--request GET \
--header 'Accept: application/json'{
"message": "Unauthorized",
"errorCode": 401,
"details": "Valid API credentials are required."
}404 Not Found
Returned when the requested Closure Code record ID does not exist or the endpoint path is incorrect.
The following request attempts to retrieve a Closure Code record with the record ID 9999:
curl --location '{host}/API/v1/Master/IM/ClosureCode/9999' \
--request GET \
--header 'Accept: application/json' \
--header 'X-Api-Key: {API_KEY}'{
"message": "Record not found",
"errorCode": 404,
"details": "The requested Closure Code record was not found."
}