POST api/pcapi/add?siteId={siteId}

Request Information

URI Parameters

NameDescriptionTypeAdditional information
siteId

globally unique identifier

None.

Body Parameters

PCViewModel
NameDescriptionTypeAdditional information
active

boolean

Required

cleanroom_id

globally unique identifier

None.

db_login

string

String length: inclusive between 0 and 50

db_name

string

String length: inclusive between 0 and 50

db_password

string

String length: inclusive between 0 and 50

db_source

string

String length: inclusive between 0 and 50

id

globally unique identifier

None.

local_ip

string

String length: inclusive between 0 and 15

lock_id

globally unique identifier

None.

mac_address

string

Required

String length: inclusive between 0 and 30

name

string

String length: inclusive between 0 and 100

pc_type_id

globally unique identifier

None.

rights

Collection of ShortRightViewModel

None.

site_id

globally unique identifier

None.

zone_id

globally unique identifier

None.

Request Formats

application/json, text/json

Sample:
{
  "active": true,
  "cleanroom_id": "8dfd0f8c-775f-4a2e-8844-f7eb817bdb2c",
  "db_login": "sample string 2",
  "db_name": "sample string 3",
  "db_password": "sample string 4",
  "db_source": "sample string 5",
  "id": "29fc8b07-9473-4b2b-80d8-98cda5e04fc8",
  "local_ip": "sample string 7",
  "lock_id": "57f4636d-dc08-4e2e-8b4a-595008622bab",
  "mac_address": "sample string 8",
  "name": "sample string 9",
  "pc_type_id": "f694e34a-0d06-4fff-a954-6ea4b4db1637",
  "rights": [
    {
      "code": "sample string 1",
      "id": "be226a1f-a95c-49c0-a3fa-bb0a37817868"
    },
    {
      "code": "sample string 1",
      "id": "be226a1f-a95c-49c0-a3fa-bb0a37817868"
    }
  ],
  "site_id": "2acf1ddc-1750-496e-8a5e-6a00d34b08d6",
  "zone_id": "7abcdb01-93d8-4153-880f-035c1ae53987"
}

application/xml, text/xml

Sample:
<pc xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/EntityModel">
  <active>true</active>
  <cleanroom_id>8dfd0f8c-775f-4a2e-8844-f7eb817bdb2c</cleanroom_id>
  <db_login>sample string 2</db_login>
  <db_name>sample string 3</db_name>
  <db_password>sample string 4</db_password>
  <db_source>sample string 5</db_source>
  <id>29fc8b07-9473-4b2b-80d8-98cda5e04fc8</id>
  <local_ip>sample string 7</local_ip>
  <lock_id>57f4636d-dc08-4e2e-8b4a-595008622bab</lock_id>
  <mac_address>sample string 8</mac_address>
  <name>sample string 9</name>
  <pc_type_id>f694e34a-0d06-4fff-a954-6ea4b4db1637</pc_type_id>
  <rights>
    <right>
      <ID>be226a1f-a95c-49c0-a3fa-bb0a37817868</ID>
      <code>sample string 1</code>
    </right>
    <right>
      <ID>be226a1f-a95c-49c0-a3fa-bb0a37817868</ID>
      <code>sample string 1</code>
    </right>
  </rights>
  <site_id>2acf1ddc-1750-496e-8a5e-6a00d34b08d6</site_id>
  <zone_id>7abcdb01-93d8-4153-880f-035c1ae53987</zone_id>
</pc>

application/x-www-form-urlencoded

Sample:

Sample not available.

Response Information

Resource Description

globally unique identifier

Response Formats

application/json, text/json

Sample:
"977739d1-02f8-4634-9597-11dea5652132"

application/xml, text/xml

Sample:
<guid xmlns="http://schemas.microsoft.com/2003/10/Serialization/">977739d1-02f8-4634-9597-11dea5652132</guid>