Person Directory - Create Dynamic Person Group
Creates a new dynamic person group with specified dynamicPersonGroupId, name, and user-provided userData. A dynamic person group is a container that references persons. After creation, use "DynamicPersonGroup - Update" to add/remove persons into the search space. DynamicPersonGroup and UserData will be stored on server until DynamicPersonGroup Delete is called.
PUT {Endpoint}/face/v1.0-preview/dynamicpersongroups/{dynamicPersonGroupId}
URI Parameters
Name | In | Required | Type | Description |
---|---|---|---|---|
dynamic
|
path | True |
string |
User provided dynamic person group Id. Valid format should be a string composed by numbers, English letters in lower case, '-', '_', and no longer than 64 characters. |
Endpoint
|
path | True |
string |
Supported Cognitive Services endpoints (protocol and hostname, for example: https://westus.api.cognitive.microsoft.com). |
Request Header
Name | Required | Type | Description |
---|---|---|---|
Ocp-Apim-Subscription-Key | True |
string |
Request Body
Name | Type | Description |
---|---|---|
addPersonIds |
string[] (uuid) |
Person ids to add to the dynamic person group. |
name |
string |
User defined name, maximum length is 128. |
userData |
string |
User specified data. Length should not exceed 16KB. |
Responses
Name | Type | Description |
---|---|---|
200 OK |
Success |
|
202 Accepted |
Success Headers Operation-Location: string |
|
Other Status Codes |
Response entity accompanying non-successful responses containing additional details about the error. |
Security
Ocp-Apim-Subscription-Key
Type:
apiKey
In:
header
Examples
Create dynamic person group example
Sample request
PUT {Endpoint}/face/v1.0-preview/dynamicpersongroups/abc
{
"name": "group1",
"userData": "user-provided data attached to the person group."
}
Sample response
Definitions
Name | Description |
---|---|
Dynamic |
|
Error |
Error body. |
DynamicPersonGroupCreateRequest
Name | Type | Description |
---|---|---|
addPersonIds |
string[] (uuid) |
Person ids to add to the dynamic person group. |
name |
string |
User defined name, maximum length is 128. |
userData |
string |
User specified data. Length should not exceed 16KB. |
Error
Error body.
Name | Type | Description |
---|---|---|
code |
string |
|
message |
string |