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

Request Information

URI Parameters

NameDescriptionTypeAdditional information
siteId

globally unique identifier

None.

Body Parameters

LockViewModel
NameDescriptionTypeAdditional information
id

globally unique identifier

None.

name

string

String length: inclusive between 0 and 100

direction

string

Required

String length: inclusive between 0 and 2

distribution_id

globally unique identifier

None.

guard_id

globally unique identifier

None.

active

boolean

None.

Request Formats

application/json, text/json

Sample:
{
  "id": "e9d821d1-bbef-4a97-8d3b-244e3ea3beac",
  "name": "sample string 2",
  "direction": "sample string 3",
  "distribution_id": "439aa65d-b6ef-4c10-97fe-efd0cf298580",
  "guard_id": "726e23e9-a678-4f1b-b524-d0177276b299",
  "active": true
}

application/xml, text/xml

Sample:
<lock xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/EntityModel">
  <active>true</active>
  <direction>sample string 3</direction>
  <distribution_id>439aa65d-b6ef-4c10-97fe-efd0cf298580</distribution_id>
  <guard_id>726e23e9-a678-4f1b-b524-d0177276b299</guard_id>
  <id>e9d821d1-bbef-4a97-8d3b-244e3ea3beac</id>
  <name>sample string 2</name>
</lock>

application/x-www-form-urlencoded

Sample:

Sample not available.

Response Information

Resource Description

globally unique identifier

Response Formats

application/json, text/json

Sample:
"4f3bccfb-f6d6-44b5-b465-1ed9dc342dea"

application/xml, text/xml

Sample:
<guid xmlns="http://schemas.microsoft.com/2003/10/Serialization/">4f3bccfb-f6d6-44b5-b465-1ed9dc342dea</guid>