---
title: Create a Service Request
slug: neurons-for-itsm/admin-user-help/enu/latest/create-a-service-request
createdAt: 2026-07-14T19:16:43.403Z
---

You can create Service Requests using Rest API.

**Base URL:**

https\://\{tenant url}/api/rest/ServiceRequest/new

:::ExpandableHeading{isOpen="true"}
## Create a Service Request - Example

Here is an example to create a Service Request.

| URL                                           | https\://\{tenant url}/api/rest/ServiceRequest/new                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                   |
| --------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
| <font color="#0C121D">Method</font>           | POST                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                 |
| Header Name                                   | Authorization: JWT Token/Session Key/REST API Key                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    |
|                                               | `{`<br />`"attachmentsToDelete": [],`<br />`"attachmentsToUpload": [],`<br />`"parameters": {},`<br />`"delayedFulfill": false,`<br />`"formName": "ServiceReq.ResponsiveAnalyst.DefaultLayout",`<br />`"saveReqState": false,`<br />`"serviceReqData": {`<br />`"Subject": "SR from RESTAPI",`<br />`"Symptom": "Test02"`<br />`},`<br />`"strCustomerLocation": "West",`<br />`"strUserId": "2F851094BFE5437C97D19871D1C539C7",`<br />`"subscriptionId": "0C1780F4EC814CB2B8E045325D8CFB66",`<br />`"localOffset": -330`<br />`}`<br />For details on how to fetch the values for these fields, see [Field Values](docId\:a_8GvJgmsxMP4LBywrZ04) and [Parameters](docId\:a_8GvJgmsxMP4LBywrZ04).<br />All the fields shown in this example are mandatory, the API will return an error if any of the field is missing. However, the value for *attachmentsToDelete*<br /> will be blank when executing Create Service Request API. |
| <font color="#0C121D">Status Code</font>      | 200                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  |
| <font color="#0C121D">Response Payload</font> | `{ "IsSuccess": true,`<br />`"ErrorText": "",`<br />`"ServiceRequests": [`<br />`{`<br />`"bNew": true,`<br />`"strSubscriptionRecId": "0C1780F4EC814CB2B8E045325D8CFB66",`<br />`"strRequestRecId": "6730C50F527A481A81FFE15D7D60725F",`<br />`"strIssueRecId": null,`<br />`"strRequestNum": "10288",`<br />`"strName": "MinimalSR",`<br />`"strStatus": null,`<br />`"strStatusId": null,`<br />`"strService": null,`<br />`"strServiceId": null,`<br />`"strDetails": null,`<br />`"parameterTemplateParameterIds": {},`<br />`"DateApproved": null,`<br />`"DateCancelled": null,`<br />`"DateCompleted": null`<br />`}`<br />`],`<br />`"InvalidServiceRequests": {}`<br />`}`                                                                                                                                                                                                                                                 |
:::

## Field Values

How to fetch the values of the fields used for executing the Create Service Request API is detailed below.

:::ExpandableHeading{isOpen="true"}
## strCustomerLocation and strUserId

To fetch the value for `strCustomerLocation` and `strUserId`, execute the API - https\://\{tenant URL}/api/odata/businessobject/Frs\_CompositeContract\_Contacts?$filter=NetworkUserName eq '\{your user name}'

From the response that you get - the value for `Employee Location` will be your `strCustomerLocation` value and the value for `RecID` will be your `strUserId` value.
:::

:::ExpandableHeading{isOpen="true"}
## subscriptionId

To fetch the value for `subscriptionId`, execute the API - https\://\{tenant URL}/api/rest/Template/\<User\_RecId>/\_All\_

This will give you all the published templates in Service Catalog. From the response that you get - the value for `strSubscriptionId` will be your `subscriptionId` value.
:::

:::ExpandableHeading{isOpen="true"}
## localOffset

The value for `localoffset` is the difference in minutes from the Coordinated Universal Time for a particular place. For example, if your location is India, your GMT/UTC is +5.30 hours which is 330 minutes, therefore, the `localoffset` value for your location is -330.
:::

:::ExpandableHeading{isOpen="true"}
## Field RecID

To fetch the `RecID` for a field, execute the API - `https://{tenant url}/api/rest/ServiceRequest/PackageData/subscriptionId/strCustomerLocation`.

From the response, look for `lstParamCategories/lstParameters` and expand it. All fields will have a `RecID`, expand the field to view it's `RecID`.

*Field RecID*

::Image[]{src="https://api.archbee.com/api/optimize/parib0MC3hVoUNdfQdnac/_BtG2qURxwATHA9gwMYy2_fieldrecid.png" position="flex-start" size="80" initialPath="../../Resources/Images/Configure/API/FieldRecID.png" githubPath="Content/Resources/Images/Configure/API/FieldRecID.png" showCaption="false" width="504" height="320" darkWidth="504" darkHeight="320"}
:::

## Parameters

The base structure of the Parameter is -

"parameters": `{`

`// {parameter name}`

`"par-{Parameter RecID}": "value",`

`}`

::::ExpandableHeading{isOpen="true"}
## Example

"parameters": `{`

`// Checkbox`

`"par-{Parameter RecID}": "true",`

`// Text Field`

`"par-{Parameter RecID}": "Text Field",`

`// Text Area`

`"par-{Parameter RecID}": "Text Area",`

`// Drop Down`

`"par-{Parameter RecID}": "Scheduled",`

`"par-{Parameter RecID}-recId": "{Field RecID of Scheduled}",`

`// Time Field`

`"par-{Parameter RecID}": "{system generated time}",`

`// DateTime Field`

`"par-{Parameter RecID}": "{system generated time}",`

`// Pick List`

`"par-{Parameter RecID}": "Active",`

`"par-{Parameter RecID}-recId": "{Field RecID of Active}"`

`}`

*Sample Service Request with Parameters*

::Image[]{src="https://api.archbee.com/api/optimize/parib0MC3hVoUNdfQdnac/-tPRTpldmRaKJMwq67mWh_parameters.png" position="flex-start" size="40" initialPath="../../Resources/Images/Configure/API/Parameters.png" githubPath="Content/Resources/Images/Configure/API/Parameters.png" showCaption="false" width="316" height="468" darkWidth="316" darkHeight="468"}

:::hint{type="note"}
Drop-down lists/pick-lists and Attachments work differently from other parameters. For details, see Drop-down and Pick-list and Attachments.
:::
::::

::::ExpandableHeading{isOpen="true"}
## Drop-down and Pick-list

In case of drop-down and pick-list you will need the value's RecID, to fetch it execute the following API:

`GET: {tenanur_url}/api/rest/ServiceRequest/{Parameter_RecID}/ValidationList`

Use Postman or a similar app instead of browser and set the **Content-Type** as **application/json**.

**Example:**

1. Execute - GET: &#x7B;tenanur\_url}/api/rest/ServiceRequest/ 6B5A00312E00430AAF8769D1A27326C6/ValidationList

:::Paragraph{indent="1"}
The response contains the Rec IDs of all values. For example, the RecID of the value Alex is "026221D7927F4104810ABF14672FCC3".
:::

2. Use it for the parameter XYZ as given below:

:::Paragraph{indent="1"}
`"parameters": {`
:::

:::Paragraph{indent="1"}
`"par-A72D69AF2A9B420F874BA8A5A293EF17": "Alex",`
:::

:::Paragraph{indent="1"}
`"par-A72D69AF2A9B420F874BA8A5A293EF17-recId": "026221D7927F4104810ABF14672FCC3"`
:::

:::Paragraph{indent="1"}
`}`
:::
::::

::::ExpandableHeading{isOpen="true"}
## Attachments

To upload attachments in Service Request, you will need the attachment's token.

**To fetch the token execute the following API:**

1. POST: api/rest/Attachment/newSR

:::Paragraph{indent="1"}
Use Postman or a similar app instead of browser and set the Request Body as **Form-data**.
:::

2. Copy the token from the response.

:::Paragraph{indent="1"}
*Sample response containing token*
:::

::Image[]{src="https://api.archbee.com/api/optimize/parib0MC3hVoUNdfQdnac/g7-LRGTXbg-BqQoNcprS2_tokens.png" position="flex-start" size="80" initialPath="../../Resources/Images/Configure/API/tokens.png" githubPath="Content/Resources/Images/Configure/API/tokens.png" showCaption="false" width="833" height="204" darkWidth="833" darkHeight="204" indent="1"}

**Using the token in the Service Request:**

`attachmentsToUpload: [["{token ID}", "<attachment file name"]]`
::::

## Unsuccessful Responses

:::ExpandableHeading{isOpen="true"}
## Empty Request Body

Scenario: Trying to create a Service Request with empty request body.

Header Name:

**Authorization: Sessionkey**

| <font color="#0C121D">Code</font>             | ISM\_4000                                               |
| --------------------------------------------- | ------------------------------------------------------- |
| Description                                   | Invalid Request Payload                                 |
| `Message`                                     | `{  `<br />`"Message body cannot be empty."  `<br />`}` |
| <font color="#0C121D">HTTP STATUS CODE</font> | **400**                                                 |
:::

:::ExpandableHeading{isOpen="true"}
## Invalid Request Body

Scenario: Trying to create a Service Request with invalid request body.

Header Name:

**Authorization: Sessionkey**

| <font color="#0C121D">Code</font>             | ISM\_4000                                           |
| --------------------------------------------- | --------------------------------------------------- |
| Description                                   | Invalid Request Payload                             |
| Message                                       | `[  `<br />`"Invalid Business Object."  `<br />`],` |
| <font color="#0C121D">HTTP STATUS CODE</font> | **400**                                             |
:::

:::ExpandableHeading{isOpen="true"}
## Missing Required Fields

Scenario: Trying to create a Service Request with missing mandatory fields.

Header Name:

**Authorization: Sessionkey**

| <font color="#0C121D">Code</font>             | ISM\_4000                                                      |
| --------------------------------------------- | -------------------------------------------------------------- |
| Description                                   | Invalid Request Payload                                        |
| Message                                       | `[  `<br />`"Required field parameters is missing"  `<br />`]` |
| <font color="#0C121D">HTTP STATUS CODE</font> | **400**                                                        |
:::

:::ExpandableHeading{isOpen="true"}
## Invalid Response

Scenario: When the application fails to save when trying to create a Service Request.

Header Name:

**Authorization: Sessionkey**

| <font color="#0C121D">Code</font>             | ISM\_5000                                                                                      |
| --------------------------------------------- | ---------------------------------------------------------------------------------------------- |
| Description                                   | Internal server error                                                                          |
| Message                                       | `[  `<br />`"The server encountered an internal error. Please retry the request."  `<br />`],` |
| <font color="#0C121D">HTTP STATUS CODE</font> | **500**                                                                                        |
:::
