PUT api/preset/{id}
Create new license preset.
Request Information
URI Parameters
| Name | Description | Type | Additional information |
|---|---|---|---|
| id | globally unique identifier |
Required |
Body Parameters
LicensePreSetRequest| Name | Description | Type | Additional information |
|---|---|---|---|
| Name | string |
None. |
|
| SystemName | string |
None. |
|
| Description | string |
None. |
|
| Buffer | integer |
None. |
|
| AccessType | integer |
None. |
|
| LicenseType | integer |
None. |
|
| CategoryId | globally unique identifier |
None. |
|
| Roles | Collection of globally unique identifier |
None. |
|
| Rules | Collection of PreSetRuleDto |
None. |
|
| LicenseDurationModifierDto | LicenseDurationModifierDto |
None. |
Request Formats
application/json, text/json
Sample:
{
"Name": "sample string 1",
"SystemName": "sample string 2",
"Description": "sample string 3",
"Buffer": 1,
"AccessType": 1,
"LicenseType": 1,
"CategoryId": "8a7b3bf2-2043-403e-a46f-bc3b1a829e32",
"Roles": [
"5f27a7f3-cbbe-4432-beab-45978e5b9f4e",
"68ad086f-b9a1-46df-b017-bc61863002a9"
],
"Rules": [
{
"Id": "900c65cd-1959-4916-b3fa-30a95c6391d0",
"PreSetRuleType": 2,
"PreSetRuleValue": "sample string 3"
},
{
"Id": "900c65cd-1959-4916-b3fa-30a95c6391d0",
"PreSetRuleType": 2,
"PreSetRuleValue": "sample string 3"
}
],
"LicenseDurationModifierDto": {
"Years": 1,
"Months": 2,
"Weeks": 3,
"Days": 4
}
}
application/xml, text/xml
Sample:
<LicensePreSetRequest xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/Alice.Dto.Requests">
<AccessType>1</AccessType>
<Buffer>1</Buffer>
<CategoryId>8a7b3bf2-2043-403e-a46f-bc3b1a829e32</CategoryId>
<Description>sample string 3</Description>
<LicenseDurationModifierDto xmlns:d2p1="http://schemas.datacontract.org/2004/07/Alice.Dto.Dtos">
<d2p1:Days>4</d2p1:Days>
<d2p1:Months>2</d2p1:Months>
<d2p1:Weeks>3</d2p1:Weeks>
<d2p1:Years>1</d2p1:Years>
</LicenseDurationModifierDto>
<LicenseType>1</LicenseType>
<Name>sample string 1</Name>
<Roles xmlns:d2p1="http://schemas.microsoft.com/2003/10/Serialization/Arrays">
<d2p1:guid>5f27a7f3-cbbe-4432-beab-45978e5b9f4e</d2p1:guid>
<d2p1:guid>68ad086f-b9a1-46df-b017-bc61863002a9</d2p1:guid>
</Roles>
<Rules xmlns:d2p1="http://schemas.datacontract.org/2004/07/Alice.Dto.Dtos">
<d2p1:PreSetRuleDto>
<d2p1:Id>900c65cd-1959-4916-b3fa-30a95c6391d0</d2p1:Id>
<d2p1:PreSetRuleType>2</d2p1:PreSetRuleType>
<d2p1:PreSetRuleValue>sample string 3</d2p1:PreSetRuleValue>
</d2p1:PreSetRuleDto>
<d2p1:PreSetRuleDto>
<d2p1:Id>900c65cd-1959-4916-b3fa-30a95c6391d0</d2p1:Id>
<d2p1:PreSetRuleType>2</d2p1:PreSetRuleType>
<d2p1:PreSetRuleValue>sample string 3</d2p1:PreSetRuleValue>
</d2p1:PreSetRuleDto>
</Rules>
<SystemName>sample string 2</SystemName>
</LicensePreSetRequest>
application/x-www-form-urlencoded
Sample:
Sample not available.
Response Information
Resource Description
ValidationResult| Name | Description | Type | Additional information |
|---|---|---|---|
| IsValid | boolean |
None. |
|
| Errors | Collection of ValidationFailure |
None. |
Response Formats
application/json, text/json
Sample:
{
"errors": []
}
application/xml, text/xml
Sample:
<ValidationResult xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/FluentValidation.Results"> <errors /> </ValidationResult>