POST api/Role/Create
Add Roles
Request Information
URI Parameters
None.
Body Parameters
Array of Roles And Information(Mandatory)
CreateRoleJSON| Name | Description | Type | Additional information | 
|---|---|---|---|
| role_info | role_data_dc | None. | |
| role_groups | Collection of role_group_mapping_dc | None. | |
| role_attribute_info | Collection of role_attribute_dc | None. | 
Request Formats
application/json, text/json
            Sample:
        
{
  "role_info": {
    "RoleId": 1,
    "RoleName": "sample string 1",
    "Roledesc": "sample string 2",
    "IsActive": true,
    "CustomRole": true,
    "SystemId": 3,
    "CreatedBy": 1,
    "LastModifiedBy": 1,
    "LastUpdatedDateTime": "2025-10-31T07:07:44.8252552+00:00",
    "IsDeleted": true,
    "RoleType": "sample string 4",
    "OrgCodes": "sample string 5"
  },
  "role_groups": [
    {
      "RoleGroupMappingId": 1,
      "RoleGroupId": 1,
      "RoleId": 2,
      "CreatedBy": 1,
      "LastModifiedBy": 1,
      "LastUpdatedDateTime": "2025-10-31T07:07:44.8252552+00:00",
      "IsDeleted": true,
      "Deleted": 1
    },
    {
      "RoleGroupMappingId": 1,
      "RoleGroupId": 1,
      "RoleId": 2,
      "CreatedBy": 1,
      "LastModifiedBy": 1,
      "LastUpdatedDateTime": "2025-10-31T07:07:44.8252552+00:00",
      "IsDeleted": true,
      "Deleted": 1
    }
  ],
  "role_attribute_info": [
    {
      "RoleAttributeId": 1,
      "RoleId": 1,
      "RoleModuleId": 2,
      "Deleted": 1,
      "CreatedBy": 1,
      "LastModifiedBy": 1,
      "LastUpdatedDateTime": "2025-10-31T07:07:44.8252552+00:00",
      "IsDeleted": true
    },
    {
      "RoleAttributeId": 1,
      "RoleId": 1,
      "RoleModuleId": 2,
      "Deleted": 1,
      "CreatedBy": 1,
      "LastModifiedBy": 1,
      "LastUpdatedDateTime": "2025-10-31T07:07:44.8252552+00:00",
      "IsDeleted": true
    }
  ]
}
        application/xml, text/xml
            Sample:
        
<CreateRoleJSON xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/WebApplicationITTF1.Controllers">
  <role_attribute_info>
    <role_attribute_dc>
      <CreatedBy>1</CreatedBy>
      <Deleted>1</Deleted>
      <IsDeleted>true</IsDeleted>
      <LastModifiedBy>1</LastModifiedBy>
      <LastUpdatedDateTime>2025-10-31T07:07:44.8252552+00:00</LastUpdatedDateTime>
      <RoleAttributeId>1</RoleAttributeId>
      <RoleId>1</RoleId>
      <RoleModuleId>2</RoleModuleId>
    </role_attribute_dc>
    <role_attribute_dc>
      <CreatedBy>1</CreatedBy>
      <Deleted>1</Deleted>
      <IsDeleted>true</IsDeleted>
      <LastModifiedBy>1</LastModifiedBy>
      <LastUpdatedDateTime>2025-10-31T07:07:44.8252552+00:00</LastUpdatedDateTime>
      <RoleAttributeId>1</RoleAttributeId>
      <RoleId>1</RoleId>
      <RoleModuleId>2</RoleModuleId>
    </role_attribute_dc>
  </role_attribute_info>
  <role_groups>
    <role_group_mapping_dc>
      <CreatedBy>1</CreatedBy>
      <Deleted>1</Deleted>
      <IsDeleted>true</IsDeleted>
      <LastModifiedBy>1</LastModifiedBy>
      <LastUpdatedDateTime>2025-10-31T07:07:44.8252552+00:00</LastUpdatedDateTime>
      <RoleGroupId>1</RoleGroupId>
      <RoleGroupMappingId>1</RoleGroupMappingId>
      <RoleId>2</RoleId>
    </role_group_mapping_dc>
    <role_group_mapping_dc>
      <CreatedBy>1</CreatedBy>
      <Deleted>1</Deleted>
      <IsDeleted>true</IsDeleted>
      <LastModifiedBy>1</LastModifiedBy>
      <LastUpdatedDateTime>2025-10-31T07:07:44.8252552+00:00</LastUpdatedDateTime>
      <RoleGroupId>1</RoleGroupId>
      <RoleGroupMappingId>1</RoleGroupMappingId>
      <RoleId>2</RoleId>
    </role_group_mapping_dc>
  </role_groups>
  <role_info>
    <CreatedBy>1</CreatedBy>
    <CustomRole>true</CustomRole>
    <IsActive>true</IsActive>
    <IsDeleted>true</IsDeleted>
    <LastModifiedBy>1</LastModifiedBy>
    <LastUpdatedDateTime>2025-10-31T07:07:44.8252552+00:00</LastUpdatedDateTime>
    <OrgCodes>sample string 5</OrgCodes>
    <RoleId>1</RoleId>
    <RoleName>sample string 1</RoleName>
    <RoleType>sample string 4</RoleType>
    <Roledesc>sample string 2</Roledesc>
    <SystemId>3</SystemId>
  </role_info>
</CreateRoleJSON>
        application/x-www-form-urlencoded
            Sample:
    
Sample not available.
Response Information
Resource Description
integerResponse Formats
application/json, text/json
            Sample:
        1
application/xml, text/xml
            Sample:
<int xmlns="http://schemas.microsoft.com/2003/10/Serialization/">1</int>