POST api/BookingTypes/{bookingTypeIdentity}/Rules
Request Information
URI Parameters
Name | Description | Type | Additional information |
---|---|---|---|
bookingTypeIdentity | string |
Required |
Body Parameters
BookingRuleName | Description | Type | Additional information |
---|---|---|---|
Identity | globally unique identifier |
None. |
|
RuleType | BookingRuleType |
None. |
|
Properties | Collection of BookingRuleDatum |
None. |
|
AppliesTo | Collection of NamedObject |
None. |
|
RunOnCreate | boolean |
None. |
|
RunOnUpdate | boolean |
None. |
|
RunOnDelete | boolean |
None. |
|
FailureMessage | string |
None. |
|
AdminsExempt | boolean |
None. |
|
BookingManagersExempt | boolean |
None. |
|
ApproversExempt | boolean |
None. |
|
PermissionGroupsExempt | boolean |
None. |
|
ExemptPermissionGroups | Collection of NamedObject |
None. |
Request Formats
application/json, text/json
Sample:
{ "Identity": "f2be5637-9ac9-4ff3-b1c7-14b97f3c9667", "RuleType": { "Properties": [ { "Name": "sample string 1", "ValueType": "sample string 2", "ValueChoices": [ "sample string 1", "sample string 2" ], "Identity": "61c6aa90-cac5-4595-8fbe-bb4208e13f86", "StartRange": true, "EndRange": true }, { "Name": "sample string 1", "ValueType": "sample string 2", "ValueChoices": [ "sample string 1", "sample string 2" ], "Identity": "61c6aa90-cac5-4595-8fbe-bb4208e13f86", "StartRange": true, "EndRange": true } ], "RunOnUpdateAsCreate": true, "RunOnCreateType": 0, "RunOnUpdateType": 0, "RunOnDeleteType": 0, "RuleGroupRequiresOneValidOnly": true, "Identity": "b805848a-e908-4509-91a6-fa34686fc71b", "Name": "sample string 4" }, "Properties": [ { "Value": {}, "ValueType": "sample string 2", "ValueChoices": [ "sample string 1", "sample string 2" ], "StartRange": true, "EndRange": true, "IsObsolete": true, "Identity": "9d060170-87b2-4c60-963f-1e4a159ecd35", "Name": "sample string 7" }, { "Value": {}, "ValueType": "sample string 2", "ValueChoices": [ "sample string 1", "sample string 2" ], "StartRange": true, "EndRange": true, "IsObsolete": true, "Identity": "9d060170-87b2-4c60-963f-1e4a159ecd35", "Name": "sample string 7" } ], "AppliesTo": [ { "Identity": "7c02398b-bafc-4f41-8e44-5aec3b523038", "Name": "sample string 2" }, { "Identity": "7c02398b-bafc-4f41-8e44-5aec3b523038", "Name": "sample string 2" } ], "RunOnCreate": true, "RunOnUpdate": true, "RunOnDelete": true, "FailureMessage": "sample string 5", "AdminsExempt": true, "BookingManagersExempt": true, "ApproversExempt": true, "PermissionGroupsExempt": true, "ExemptPermissionGroups": [ { "Identity": "7c02398b-bafc-4f41-8e44-5aec3b523038", "Name": "sample string 2" }, { "Identity": "7c02398b-bafc-4f41-8e44-5aec3b523038", "Name": "sample string 2" } ] }
application/xml, text/xml
Sample:
<BookingRule xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/Scientia.Platform.API.Model"> <AdminsExempt>true</AdminsExempt> <AppliesTo xmlns:d2p1="http://schemas.datacontract.org/2004/07/Scientia.Platform.Library.Security"> <d2p1:NamedObject> <d2p1:Identity>7c02398b-bafc-4f41-8e44-5aec3b523038</d2p1:Identity> <d2p1:Name>sample string 2</d2p1:Name> </d2p1:NamedObject> <d2p1:NamedObject> <d2p1:Identity>7c02398b-bafc-4f41-8e44-5aec3b523038</d2p1:Identity> <d2p1:Name>sample string 2</d2p1:Name> </d2p1:NamedObject> </AppliesTo> <ApproversExempt>true</ApproversExempt> <BookingManagersExempt>true</BookingManagersExempt> <ExemptPermissionGroups xmlns:d2p1="http://schemas.datacontract.org/2004/07/Scientia.Platform.Library.Security"> <d2p1:NamedObject> <d2p1:Identity>7c02398b-bafc-4f41-8e44-5aec3b523038</d2p1:Identity> <d2p1:Name>sample string 2</d2p1:Name> </d2p1:NamedObject> <d2p1:NamedObject> <d2p1:Identity>7c02398b-bafc-4f41-8e44-5aec3b523038</d2p1:Identity> <d2p1:Name>sample string 2</d2p1:Name> </d2p1:NamedObject> </ExemptPermissionGroups> <FailureMessage>sample string 5</FailureMessage> <Identity>f2be5637-9ac9-4ff3-b1c7-14b97f3c9667</Identity> <PermissionGroupsExempt>true</PermissionGroupsExempt> <Properties> <BookingRuleDatum> <Identity xmlns="http://schemas.datacontract.org/2004/07/Scientia.Platform.Library.Security">9d060170-87b2-4c60-963f-1e4a159ecd35</Identity> <Name xmlns="http://schemas.datacontract.org/2004/07/Scientia.Platform.Library.Security">sample string 7</Name> <EndRange>true</EndRange> <IsObsolete>true</IsObsolete> <StartRange>true</StartRange> <Value /> <ValueChoices xmlns:d4p1="http://schemas.microsoft.com/2003/10/Serialization/Arrays"> <d4p1:string>sample string 1</d4p1:string> <d4p1:string>sample string 2</d4p1:string> </ValueChoices> <ValueType>sample string 2</ValueType> </BookingRuleDatum> <BookingRuleDatum> <Identity xmlns="http://schemas.datacontract.org/2004/07/Scientia.Platform.Library.Security">9d060170-87b2-4c60-963f-1e4a159ecd35</Identity> <Name xmlns="http://schemas.datacontract.org/2004/07/Scientia.Platform.Library.Security">sample string 7</Name> <EndRange>true</EndRange> <IsObsolete>true</IsObsolete> <StartRange>true</StartRange> <Value /> <ValueChoices xmlns:d4p1="http://schemas.microsoft.com/2003/10/Serialization/Arrays"> <d4p1:string>sample string 1</d4p1:string> <d4p1:string>sample string 2</d4p1:string> </ValueChoices> <ValueType>sample string 2</ValueType> </BookingRuleDatum> </Properties> <RuleType> <Identity xmlns="http://schemas.datacontract.org/2004/07/Scientia.Platform.Library.Security">b805848a-e908-4509-91a6-fa34686fc71b</Identity> <Name xmlns="http://schemas.datacontract.org/2004/07/Scientia.Platform.Library.Security">sample string 4</Name> <Properties> <BookingRuleTypeProperty> <EndRange>true</EndRange> <Identity>61c6aa90-cac5-4595-8fbe-bb4208e13f86</Identity> <Name>sample string 1</Name> <StartRange>true</StartRange> <ValueChoices xmlns:d5p1="http://schemas.microsoft.com/2003/10/Serialization/Arrays"> <d5p1:string>sample string 1</d5p1:string> <d5p1:string>sample string 2</d5p1:string> </ValueChoices> <ValueType>sample string 2</ValueType> </BookingRuleTypeProperty> <BookingRuleTypeProperty> <EndRange>true</EndRange> <Identity>61c6aa90-cac5-4595-8fbe-bb4208e13f86</Identity> <Name>sample string 1</Name> <StartRange>true</StartRange> <ValueChoices xmlns:d5p1="http://schemas.microsoft.com/2003/10/Serialization/Arrays"> <d5p1:string>sample string 1</d5p1:string> <d5p1:string>sample string 2</d5p1:string> </ValueChoices> <ValueType>sample string 2</ValueType> </BookingRuleTypeProperty> </Properties> <RuleGroupRequiresOneValidOnly>true</RuleGroupRequiresOneValidOnly> <RunOnCreateType>Never</RunOnCreateType> <RunOnDeleteType>Never</RunOnDeleteType> <RunOnUpdateAsCreate>true</RunOnUpdateAsCreate> <RunOnUpdateType>Never</RunOnUpdateType> </RuleType> <RunOnCreate>true</RunOnCreate> <RunOnDelete>true</RunOnDelete> <RunOnUpdate>true</RunOnUpdate> </BookingRule>
application/x-www-form-urlencoded
Sample:
Sample not available.
Response Information
Resource Description
BookingRuleName | Description | Type | Additional information |
---|---|---|---|
Identity | globally unique identifier |
None. |
|
RuleType | BookingRuleType |
None. |
|
Properties | Collection of BookingRuleDatum |
None. |
|
AppliesTo | Collection of NamedObject |
None. |
|
RunOnCreate | boolean |
None. |
|
RunOnUpdate | boolean |
None. |
|
RunOnDelete | boolean |
None. |
|
FailureMessage | string |
None. |
|
AdminsExempt | boolean |
None. |
|
BookingManagersExempt | boolean |
None. |
|
ApproversExempt | boolean |
None. |
|
PermissionGroupsExempt | boolean |
None. |
|
ExemptPermissionGroups | Collection of NamedObject |
None. |
Response Formats
application/json, text/json
Sample:
{ "Identity": "1b77329e-e372-42c8-9262-46017d014412", "RuleType": { "Properties": [ { "Name": "sample string 1", "ValueType": "sample string 2", "ValueChoices": [ "sample string 1", "sample string 2" ], "Identity": "89153740-2d8c-4946-91c2-ae5b55c7c706", "StartRange": true, "EndRange": true }, { "Name": "sample string 1", "ValueType": "sample string 2", "ValueChoices": [ "sample string 1", "sample string 2" ], "Identity": "89153740-2d8c-4946-91c2-ae5b55c7c706", "StartRange": true, "EndRange": true } ], "RunOnUpdateAsCreate": true, "RunOnCreateType": 0, "RunOnUpdateType": 0, "RunOnDeleteType": 0, "RuleGroupRequiresOneValidOnly": true, "Identity": "24aa7240-16db-4267-8777-523c25ef98f7", "Name": "sample string 4" }, "Properties": [ { "Value": {}, "ValueType": "sample string 2", "ValueChoices": [ "sample string 1", "sample string 2" ], "StartRange": true, "EndRange": true, "IsObsolete": true, "Identity": "5b63366f-b4b2-42b3-843d-4988f72f5870", "Name": "sample string 7" }, { "Value": {}, "ValueType": "sample string 2", "ValueChoices": [ "sample string 1", "sample string 2" ], "StartRange": true, "EndRange": true, "IsObsolete": true, "Identity": "5b63366f-b4b2-42b3-843d-4988f72f5870", "Name": "sample string 7" } ], "AppliesTo": [ { "Identity": "f1a0190c-5638-4963-a5d4-d40bb92e05f7", "Name": "sample string 2" }, { "Identity": "f1a0190c-5638-4963-a5d4-d40bb92e05f7", "Name": "sample string 2" } ], "RunOnCreate": true, "RunOnUpdate": true, "RunOnDelete": true, "FailureMessage": "sample string 5", "AdminsExempt": true, "BookingManagersExempt": true, "ApproversExempt": true, "PermissionGroupsExempt": true, "ExemptPermissionGroups": [ { "Identity": "f1a0190c-5638-4963-a5d4-d40bb92e05f7", "Name": "sample string 2" }, { "Identity": "f1a0190c-5638-4963-a5d4-d40bb92e05f7", "Name": "sample string 2" } ] }
application/xml, text/xml
Sample:
<BookingRule xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/Scientia.Platform.API.Model"> <AdminsExempt>true</AdminsExempt> <AppliesTo xmlns:d2p1="http://schemas.datacontract.org/2004/07/Scientia.Platform.Library.Security"> <d2p1:NamedObject> <d2p1:Identity>f1a0190c-5638-4963-a5d4-d40bb92e05f7</d2p1:Identity> <d2p1:Name>sample string 2</d2p1:Name> </d2p1:NamedObject> <d2p1:NamedObject> <d2p1:Identity>f1a0190c-5638-4963-a5d4-d40bb92e05f7</d2p1:Identity> <d2p1:Name>sample string 2</d2p1:Name> </d2p1:NamedObject> </AppliesTo> <ApproversExempt>true</ApproversExempt> <BookingManagersExempt>true</BookingManagersExempt> <ExemptPermissionGroups xmlns:d2p1="http://schemas.datacontract.org/2004/07/Scientia.Platform.Library.Security"> <d2p1:NamedObject> <d2p1:Identity>f1a0190c-5638-4963-a5d4-d40bb92e05f7</d2p1:Identity> <d2p1:Name>sample string 2</d2p1:Name> </d2p1:NamedObject> <d2p1:NamedObject> <d2p1:Identity>f1a0190c-5638-4963-a5d4-d40bb92e05f7</d2p1:Identity> <d2p1:Name>sample string 2</d2p1:Name> </d2p1:NamedObject> </ExemptPermissionGroups> <FailureMessage>sample string 5</FailureMessage> <Identity>1b77329e-e372-42c8-9262-46017d014412</Identity> <PermissionGroupsExempt>true</PermissionGroupsExempt> <Properties> <BookingRuleDatum> <Identity xmlns="http://schemas.datacontract.org/2004/07/Scientia.Platform.Library.Security">5b63366f-b4b2-42b3-843d-4988f72f5870</Identity> <Name xmlns="http://schemas.datacontract.org/2004/07/Scientia.Platform.Library.Security">sample string 7</Name> <EndRange>true</EndRange> <IsObsolete>true</IsObsolete> <StartRange>true</StartRange> <Value /> <ValueChoices xmlns:d4p1="http://schemas.microsoft.com/2003/10/Serialization/Arrays"> <d4p1:string>sample string 1</d4p1:string> <d4p1:string>sample string 2</d4p1:string> </ValueChoices> <ValueType>sample string 2</ValueType> </BookingRuleDatum> <BookingRuleDatum> <Identity xmlns="http://schemas.datacontract.org/2004/07/Scientia.Platform.Library.Security">5b63366f-b4b2-42b3-843d-4988f72f5870</Identity> <Name xmlns="http://schemas.datacontract.org/2004/07/Scientia.Platform.Library.Security">sample string 7</Name> <EndRange>true</EndRange> <IsObsolete>true</IsObsolete> <StartRange>true</StartRange> <Value /> <ValueChoices xmlns:d4p1="http://schemas.microsoft.com/2003/10/Serialization/Arrays"> <d4p1:string>sample string 1</d4p1:string> <d4p1:string>sample string 2</d4p1:string> </ValueChoices> <ValueType>sample string 2</ValueType> </BookingRuleDatum> </Properties> <RuleType> <Identity xmlns="http://schemas.datacontract.org/2004/07/Scientia.Platform.Library.Security">24aa7240-16db-4267-8777-523c25ef98f7</Identity> <Name xmlns="http://schemas.datacontract.org/2004/07/Scientia.Platform.Library.Security">sample string 4</Name> <Properties> <BookingRuleTypeProperty> <EndRange>true</EndRange> <Identity>89153740-2d8c-4946-91c2-ae5b55c7c706</Identity> <Name>sample string 1</Name> <StartRange>true</StartRange> <ValueChoices xmlns:d5p1="http://schemas.microsoft.com/2003/10/Serialization/Arrays"> <d5p1:string>sample string 1</d5p1:string> <d5p1:string>sample string 2</d5p1:string> </ValueChoices> <ValueType>sample string 2</ValueType> </BookingRuleTypeProperty> <BookingRuleTypeProperty> <EndRange>true</EndRange> <Identity>89153740-2d8c-4946-91c2-ae5b55c7c706</Identity> <Name>sample string 1</Name> <StartRange>true</StartRange> <ValueChoices xmlns:d5p1="http://schemas.microsoft.com/2003/10/Serialization/Arrays"> <d5p1:string>sample string 1</d5p1:string> <d5p1:string>sample string 2</d5p1:string> </ValueChoices> <ValueType>sample string 2</ValueType> </BookingRuleTypeProperty> </Properties> <RuleGroupRequiresOneValidOnly>true</RuleGroupRequiresOneValidOnly> <RunOnCreateType>Never</RunOnCreateType> <RunOnDeleteType>Never</RunOnDeleteType> <RunOnUpdateAsCreate>true</RunOnUpdateAsCreate> <RunOnUpdateType>Never</RunOnUpdateType> </RuleType> <RunOnCreate>true</RunOnCreate> <RunOnDelete>true</RunOnDelete> <RunOnUpdate>true</RunOnUpdate> </BookingRule>