POST licenseSession
Obtains authorization for a feature requested by an user, establishing a session between the licensed application and Cloud Connect.
Only an authorized customer can access features of the licensed application. This request is used to authorize the user's access to a feature. Once an authorization is obtained, this request establishes a session between the licensed application and the Cloud Connect.
For information on which license to retrieve if the same feature exists in multiple entitlements of a customer, refer to the section Priority Logic for Feature Consumption.
Type
POST
URI
<SCC_URL>/licenseSessions
The <SCC_URL> represents the Cloud Connect URL sent by Directory Service (also called, YPS) in response to the POST registration request.
Example URI
https://fra01-he02.trial.sentinelcloud.com/scc/licenseSessions
URI Parameter
None
Request Body
<?xml version="1.0" encoding="UTF-8"?>
<licenseSession>
<user>u1</user>
<customer>cloud</customer>
<featureNode>
<featureVersion>1.0</featureVersion>
<featureName>cloud</featureName>
</featureNode>
<vendorData>Runtime-1234-1</vendorData>
<unitsRequired>2</unitsRequired>
<usageCountMultiplier>36</usageCountMultiplier>
</licenseSession>
Elements in the Request XML
Parameter | Description |
---|---|
customer |
The unique customer ID (as provided in EMS). |
user |
Identifies the user. This parameter can be used in any manner as seen suitable by a software vendor. For example, in the case of named entitlements, it should be the same string which is given in the named entitlement. In other cases, the string can represent an entity, such as a machine or device serial number. |
featureName |
The feature name. |
featureVersion |
(Optional) The feature version. If a feature is created with version from EMS, it become mandatory to provide the feature version along with the feature name in the request. NOTE If tags are not provided or if blank tags are provided, the null value is considered in the request. |
vendorData |
(Optional) It is used for recording vendor-specific data along with the usage data of a licensed feature. EMS allows generating the Vendor Usage Data Report based on this attribute. This report provides information about entitlements that contain the specified vendor information, along with customer details. The report data is grouped by the value of this attribute. The size is limited to 255 characters and all special characters are allowed. You can type either 0-9 OR !@#$^&*(()+ OR characters, as these all are allowed. If the provided string is greater than 255 characters, it is trimmed and the trimmed value is shown in the report. NOTE If tags are not provided or if blank tags are provided, the null value is considered in the request. |
unitsRequired |
(Optional) It is used for setting the number of concurrent license units to be consumed in a license session. You can provide this attribute when concurrency is unlimited or limited (per login). Limited concurrency means that Concurrency Limit has been defined and unlimited concurrency means that the limit has not been defined. For unlimited concurrency, the valid range is 1 to 2147483647. For limited concurrency, valid range is 1 to 32752.. This attribute is used to calculate peak concurrency, which is retrieved by using the Peak Concurrency report (exposed as an EMS web service). To view the peak concurrency report, you must provide a value in the unitsRequired parameter. NOTE This parameter’s start and end tags should contain a valid value. If you provide blank tags or an invalid value, an error is returned. If you do not provide tags, the default value is used. |
usageCountMultiplier |
(Optional) This attribute is used to specify the number of usage count consumed in a license session. By default, a license session consumes one usage count and this count is acknowledged at the start of the session. At times, a vendor may want to specify a count more than one, either at the start of the session and/or at the time of session update. To consume more than one usage count for a given session, set the usage count multiplier at the start of a license session. It is recommended not to specify usage count multiplier at the license session update - for licenses where the usage limit is defined. This is because the final result could be a negative value, which indicates overuse. Its value can be any positive integer in the range of 1 to 2,147,483,647. The default value is: > 1 at the start of a license session API, and >0 at the update of a license session. The total usage count consumed in a particular session is calculated by adding the usage count multiplier values specified at the start and update of a license session. usage count consumed = usageCountMultiplier at the start + usageCountMultiplier at the update >If usageCountMultiplier is not provided at start and update, one (1+0) usage count is consumed. >If usageCountMultiplier is provided at the start but not at update, the usage count equals the value specified at the start. >If usageCountMultiplier is not provided at the start but at the update, the usage count equals one plus the value specified at the update. >If usageCountMultiplier is provided at both the start and update, the usage count is the sum of both the values. The usage count consumed by a license session is visible in all EMS usage reports. NOTE This parameter’s start and end tags should contain a valid value. If you provide blank tags or an invalid value, an error is returned. If you do not provide tags, the default value is used. |
Request Schema
<?xml version="1.0"?>
<xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema">
<xs:element name="licenseSession">
<xs:complexType>
<xs:sequence>
<xs:element type="xs:string" name="user" minOccurs='1' maxOccurs='1'/>
<xs:element type="xs:string" name="customer" minOccurs='1' maxOccurs='1'/>
<xs:element name="featureNode">
<xs:complexType>
<xs:sequence>
<xs:element type="xs:string" name="featureVersion" minOccurs='0' maxOccurs='1'/>
<xs:element type="xs:string" name="featureName" minOccurs='1' maxOccurs='1'/>
</xs:sequence>
</xs:complexType>
</xs:element>
<xs:element type="xs:string" name="vendorData" minOccurs='0' maxOccurs='1'/>
<xs:element type="xs:int" name="unitsRequired" minOccurs='0' maxOccurs='1'/>
<xs:element type="xs:int" name="usageCountMultiplier" minOccurs='0' maxOccurs='1'/>
</xs:sequence>
</xs:complexType>
</xs:element>
</xs:schema>
Response XML
In case of success:
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<licenseSession>
<licenseSessionId>
YJXgroC%2F7Ng5lYgo2eCrtFaPjv7Gz1X7V2dulSgLgeDXqrfgz7oUz%2B1zZIqt50%2FnS2UYatwdLoVB%0D%0A%2FVFd8hQRjn4O06TM0bf%2FZHm21hZBt2ad2d4M2TzPnXkredifNrFTvGdCP75MyuhOstuFD6492Crk%0D%0AJHzWa0PhOVFjnr7dVYRBC4OTYpC3sXCGAbU%2BE55uqxv3uLF85WV60n4Hr79BbU1ffy%2FeOHMFm1uR%0D%0AChH7yT6X3aBuLQcQ1wAATLUq5ht38v9Ow7MkkBI4Km9ltvHnZ2lhAeI%2BOkSJ
</licenseSessionId>
</licenseSession>
In case of error:
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<error>
<status>Fail</status>
<errorCode>error_code</errorCode>
<errorDescription>error_message</errorDescription>
</error>
Elements in the Response XML
Parameter | Description |
---|---|
licenseSessionId |
The unique ID representing the license session created after the successful license authorization. |
Response Schema
<?xml version="1.0"?>
<xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema">
<xs:element name="licenseSession">
<xs:complexType>
<xs:sequence>
<xs:element type="xs:string" name="licenseSessionId" minOccurs='1' maxOccurs='1'/>
</xs:sequence>
</xs:complexType>
</xs:element>
</xs:schema>
Error Codes
Error Code | Description | Status Code |
---|---|---|
2002 |
User is invalid |
400 Bad request |
2003 |
Customer is invalid |
400 Bad request |
2004 |
Units are not supported with limited concurrency - Per User. |
403 Forbidden |
2007 |
Invalid parameter: vendorId |
400 Bad request |
2008 |
Value of feature name passed in input parameter is invalid. |
400 Bad request |
2010 |
Invalid parameter: featureVersion |
400 Bad request |
2014 |
Value of usage count passed in input parameter is invalid. Valid range is 1 to 2147483647. |
400 Bad request |
2018 |
License is expired |
403 Forbidden |
2019 |
License is disabled |
403 Forbidden |
2021 |
Maximum concurrent user limit reached |
403 Forbidden |
2022 |
Maximum usage count reached |
403 Forbidden |
2047 | Requests timed out as too many requests are received from the same user. Retry after some time. | 429 Too Many Requests |
See Also: Common Error Codes