POST api/PBI_role/role

Request Information

URI Parameters

None.

Body Parameters

PBI_RoleViewModel
NameDescriptionTypeAdditional information
active

boolean

None.

code

string

Required

customer_ID

globally unique identifier

None.

customerName

string

None.

id

globally unique identifier

None.

names

Dictionary of string [key] and string [value]

Required

permissions

Collection of PBI_PermissionsViewModel

Required

site_ID

globally unique identifier

Required

siteName

string

None.

Request Formats

application/json, text/json

Sample:
{
  "active": true,
  "code": "sample string 2",
  "customer_ID": "bbcd75e5-9b28-4430-a2d1-3a2bf5d4c142",
  "customerName": "sample string 4",
  "id": "9068b6c0-e985-4e50-bd2b-7aec32f77e9e",
  "names": {
    "sample string 1": "sample string 2",
    "sample string 3": "sample string 4"
  },
  "permissions": [
    {
      "id": "66b0ae24-c419-439d-a972-ab441c46e3d7",
      "active": true,
      "foreign_ID": "3586cdd2-c410-4a5d-9250-46ff67b44d07",
      "foreign_Label": "sample string 3",
      "type": 1
    },
    {
      "id": "66b0ae24-c419-439d-a972-ab441c46e3d7",
      "active": true,
      "foreign_ID": "3586cdd2-c410-4a5d-9250-46ff67b44d07",
      "foreign_Label": "sample string 3",
      "type": 1
    }
  ],
  "site_ID": "e6d26c51-ec83-4659-8c4e-653677633d10",
  "siteName": "sample string 8"
}

application/xml, text/xml

Sample:
<PBI_RoleViewModel xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/EntityModel">
  <active>true</active>
  <code>sample string 2</code>
  <customerName>sample string 4</customerName>
  <customer_ID>bbcd75e5-9b28-4430-a2d1-3a2bf5d4c142</customer_ID>
  <id>9068b6c0-e985-4e50-bd2b-7aec32f77e9e</id>
  <names xmlns:d2p1="http://schemas.microsoft.com/2003/10/Serialization/Arrays">
    <d2p1:KeyValueOfstringstring>
      <d2p1:Key>sample string 1</d2p1:Key>
      <d2p1:Value>sample string 2</d2p1:Value>
    </d2p1:KeyValueOfstringstring>
    <d2p1:KeyValueOfstringstring>
      <d2p1:Key>sample string 3</d2p1:Key>
      <d2p1:Value>sample string 4</d2p1:Value>
    </d2p1:KeyValueOfstringstring>
  </names>
  <permissions>
    <PBI_PermissionsViewModel>
      <Active>true</Active>
      <Foreign_ID>3586cdd2-c410-4a5d-9250-46ff67b44d07</Foreign_ID>
      <Foreign_Label>sample string 3</Foreign_Label>
      <ID>66b0ae24-c419-439d-a972-ab441c46e3d7</ID>
      <type>SiteCustomer</type>
    </PBI_PermissionsViewModel>
    <PBI_PermissionsViewModel>
      <Active>true</Active>
      <Foreign_ID>3586cdd2-c410-4a5d-9250-46ff67b44d07</Foreign_ID>
      <Foreign_Label>sample string 3</Foreign_Label>
      <ID>66b0ae24-c419-439d-a972-ab441c46e3d7</ID>
      <type>SiteCustomer</type>
    </PBI_PermissionsViewModel>
  </permissions>
  <siteName>sample string 8</siteName>
  <site_ID>e6d26c51-ec83-4659-8c4e-653677633d10</site_ID>
</PBI_RoleViewModel>

application/x-www-form-urlencoded

Sample:

Failed to generate the sample for media type 'application/x-www-form-urlencoded'. Cannot use formatter 'JQueryMvcFormUrlEncodedFormatter' to write type 'PBI_RoleViewModel'.

Response Information

Resource Description

globally unique identifier

Response Formats

application/json, text/json

Sample:
"4f5fa856-da75-4941-ab8c-a46454f5e47b"

application/xml, text/xml

Sample:
<guid xmlns="http://schemas.microsoft.com/2003/10/Serialization/">4f5fa856-da75-4941-ab8c-a46454f5e47b</guid>