---
title: "Create a resource group"
method: POST
path: "/restapi/json/v1/resourcegroup"
tags: ["Resource Groups"]
---

# Create a resource group

`POST /restapi/json/v1/resourcegroup`

## Request

- Base URL: `https://Hostname:Port`
- URL: `https://Hostname:Port/restapi/json/v1/resourcegroup`
- Auth: API key in header `AUTHTOKEN`
- TypeScript: <https://skmtc.dev/manageengine/apis/pam360-rest-api/docs/restapi/json/v1/resourcegroup/post.ts> (a function with typed inputs; its response is checked against the schema)

Create a static or dynamic resource group.
Set GROUPTYPE to "STATIC" or "DYNAMIC".
Dynamic groups require CRITERIAEXPRESSION and condition/operator/valuefield triplets.

## Headers

- `orgName` string

## Request body `application/x-www-form-urlencoded`

- CreateDynamicResourceGroupRequest
  - `INPUT_DATA` object, required
    - `operation` object
      - `Details` object
        - `GROUPNAME` string
        - `DESCRIPTION` string
        - `PARENTGROUPID` integer
        - `POLICY` string
        - `NoHelpDeskRetrieval` boolean
        - `GROUPTYPE` string
        - `CRITERIAEXPRESSION` string
        - `NoOfCriteria` integer
        - `condition_1` string: Field name for the criterion. Repeat with incrementing suffix (condition_1, condition_2, ... condition_N) for multiple criteria.
        - `operator_1` string: Operator for the criterion. Repeat as operator_1, operator_2, ... operator_N.
        - `valuefield_1` string: Value to match for the criterion. Repeat as valuefield_1, valuefield_2, ... valuefield_N.
        - `customType_1` 'resource' | 'account': Required when the condition uses a custom field. Specifies whether it is a resource or account custom field. Repeat as customType_1, customType_2, ... customType_N.

## Response `200`

Resource group created

- CreateResourceGroupResponse
  - `operation` object
    - `result` OperationResult
      - `message` string: Result message describing the operation outcome
      - `status` string: Operation status
    - `name` string

---

[API](https://skmtc.dev/manageengine/apis/pam360-rest-api.md) - [All operations](https://skmtc.dev/manageengine/apis/pam360-rest-api/llms.txt) - [OpenAPI document](https://skmtc.dev/manageengine/apis/pam360-rest-api/revisions/44a47abb4bdb?raw)
