Skip to content

Dynamic Monetization APIs (1.0)

APIs to perform Dynamic Monetization activity.

Download OpenAPI description
Languages
Servers
Dynamic Monetization API URL

https://{siteID}.flexnetoperations.{domainExtension}/dynamicmonetization/api/

Dynamic Monetization API URL

https://{siteID}.flexnetoperations.{domainExtension}/dynamicmonetization/floating/api/

Authorization

APIs to manage authorization keys.

Operations

Instances

APIs to manage Dynamic Monetization instances, which host the line items belonging to customers.

Operations

Line Items

APIs to manage line items mapped to an instance.

Operations

Rules of Access

APIs to manage rules of access for Dynamic Monetization instances. Rules of access are used to control the way the counts of an elastic line item are used in an access request.

Operations

Rate Tables

APIs to manage rate tables. Rate tables are used to define the price of items (how many tokens are charged per item).

Operations

Sessions

APIs for elastic access within the context of a session.

Operations

Request

Creates a new session for elastic access.

Security
AdministrationAccess or ClientAccess
Headers
x-instance-idstring

UUID of the instance to create the session on. Required by requests that use a ClientAccess token.

Bodyapplication/jsonrequired

The information required in the request payload.

instanceIdstring(uuid)required

UUID of the instance, used while creating a new session.

curl -i -X POST \
  'https://{siteid}.flexnetoperations.{domainextension}/dynamicmonetization/floating/api/v1.0/sessions' \
  -H 'Authorization: Bearer <YOUR_JWT_HERE>' \
  -H 'Content-Type: application/json' \
  -H 'x-instance-id: string' \
  -d '{
    "instanceId": "64d2028c-ae87-4069-a624-66089d957ef9"
  }'

Responses

OK. The request succeeded in its entirety.

Bodyapplication/json
sessionIdstring(uuid)

UUID of the session created.

Response
application/json
{ "sessionId": "f6567dd8-e069-418e-8893-7d22fcf12459" }

Request

Returns up to 100 live sessions, sorted in descending order of creation time.

Security
AdministrationAccess or ClientAccess
Query
instanceIdstring(uuid)required

Filter sessions based on Instance UUID.

curl -i -X GET \
  'https://{siteid}.flexnetoperations.{domainextension}/dynamicmonetization/floating/api/v1.0/sessions?instanceId=497f6eca-6276-4993-bfeb-53cbbbba6f08' \
  -H 'Authorization: Bearer <YOUR_JWT_HERE>'

Responses

OK. The request succeeded.

Bodyapplication/jsonArray [
sessionIdstring(uuid)

UUID of the session.

instanceIdstring(uuid)

UUID of the instance that this session operates on.

statestring

Current state of this session.

Enum"IDLE""ACTIVE"
chargedUntilinteger

The timestamp for the last scheduled automatic charge, in milliseconds since the epoch.

lastHeartBeatinteger

The timestamp when the last heartbeat was received, in milliseconds since the epoch.

lastAccessRequestinteger

The timestamp when the last access request was received for the session, in milliseconds since the epoch.

]
Response
application/json
[ { "sessionId": "f6567dd8-e069-418e-8893-7d22fcf12459", "instanceId": "64d2028c-ae87-4069-a624-66089d957ef9", "state": "IDLE", "chargedUntil": 0, "lastHeartBeat": 0, "lastAccessRequest": 0 } ]

Request

Returns session details for the specified session ID.

Security
AdministrationAccess or ClientAccess
Path
sessionIdstring(uuid)required

UUID of the session to fetch.

Headers
x-instance-idstring

UUID of the instance the session is linked to. Required by requests that use a ClientAccess token.

curl -i -X GET \
  'https://{siteid}.flexnetoperations.{domainextension}/dynamicmonetization/floating/api/v1.0/sessions/{sessionId}' \
  -H 'Authorization: Bearer <YOUR_JWT_HERE>' \
  -H 'x-instance-id: string'

Responses

OK. The request succeeded.

Bodyapplication/json
sessionIdstring(uuid)

UUID of the session.

instanceIdstring(uuid)

UUID of the instance that linked to this session.

statestring

Current state of this session.

Enum"IDLE""ACTIVE""TERMINATED""FAILED"
itemsArray of objects(SessionItem)unique

The items in this session.

Response
application/json
{ "sessionId": "f6567dd8-e069-418e-8893-7d22fcf12459", "instanceId": "64d2028c-ae87-4069-a624-66089d957ef9", "state": "IDLE", "items": [ {} ] }

Request

Closes a specified session for elastic access.

Security
AdministrationAccess or ClientAccess
Path
sessionIdstring(uuid)required

UUID of the session to be closed.

Headers
x-instance-idstring

UUID of the instance the session is linked to. Required by requests that use a ClientAccess token.

curl -i -X DELETE \
  'https://{siteid}.flexnetoperations.{domainextension}/dynamicmonetization/floating/api/v1.0/sessions/{sessionId}' \
  -H 'Authorization: Bearer <YOUR_JWT_HERE>' \
  -H 'x-instance-id: string'

Responses

OK. The request succeeded in its entirety.

Elastic access request in the context of a session

Request

Makes an elastic access request in the context of a session.

Security
AdministrationAccess or ClientAccess
Path
sessionIdstring(uuid)required

UUID of the session where the access request is being made.

Headers
x-instance-idstring

UUID of the instance the session is linked to. Required by requests that use a ClientAccess token.

Bodyapplication/jsonrequired

The information required in the request payload.

requesterobject(Requester)required

Requester details

requester.​typestringrequired

Type of the requester.

requester.​valuestringrequired

Unique identifier for the requester.

requester.​dictionaryobject

Dictionary of additional information about the requester. Will be used to evaluate actions defined on line items.

rollbackOnDenybooleanrequired

When true, if the request cannot be granted the session will revert to the combination of items it was charging for before the request was made. When false, if the request cannot be granted the session will refund all items it was charging for before the request was made, and the session state will be set to TERMINATED. The amount refunded will be calculated using the time of the denied request up until the end of the period that has been charged for.

requestedItemsArray of objects(RequestedItemRequest)required

A list of requested items. Provide an empty list to stop using all items.

requestedItems[].​itemstringrequired

The requested item.

requestedItems[].​versionstring

The version of the item requested. This field may only be omitted or left blank if the intention is to access an item in a rate table with an empty or unspecified version.

requestedItems[].​countnumber(double)required

Number of instances of the requested item required. The value can be fractional.

requestedItems[].​metaDataobject(metaData)

(Optional) For sending custom data with the request, which will be sent to the data warehouse with the usage information to assist with analyzing access activity. The meta data content must be a valid JSON object.

curl -i -X PUT \
  'https://{siteid}.flexnetoperations.{domainextension}/dynamicmonetization/floating/api/v1.0/sessions/{sessionId}' \
  -H 'Authorization: Bearer <YOUR_JWT_HERE>' \
  -H 'Content-Type: application/json' \
  -H 'x-instance-id: string' \
  -d '{
    "requester": {
      "type": "string",
      "value": "string"
    },
    "rollbackOnDeny": true,
    "requestedItems": [
      {
        "item": "string",
        "version": "string",
        "count": 0.1,
        "metaData": {}
      }
    ]
  }'

Responses

OK. The request succeeded in its entirety.

Bodyapplication/json
requestedItemsArray of objects(RequestedItem)

List of requested items.

requesterobject(Requester)

The details of the requester making the access request.

correlationIdstring

An ID for the request, generated by the service, which allows correlation of the request with usage information obtained from the data warehouse. The correlation ID cannot be set by the caller of the API.

Response
application/json
{ "requestedItems": [ {} ], "requester": { "type": "string", "value": "string" }, "correlationId": "string" }

Request

Sends a heartbeat for a session to keep it active.

Security
AdministrationAccess or ClientAccess
Path
sessionIdstring(uuid)required

UUID of the session to keep active.

Headers
x-instance-idstring

UUID of the instance the session is linked to. Required by requests that use a ClientAccess token.

curl -i -X GET \
  'https://{siteid}.flexnetoperations.{domainextension}/dynamicmonetization/floating/api/v1.0/sessions/{sessionId}/heartbeat' \
  -H 'Authorization: Bearer <YOUR_JWT_HERE>' \
  -H 'x-instance-id: string'

Responses

OK. The request succeeded.

Non-Session Access Request

APIs for elastic access without a session.

Operations

Configuration

APIs for managing configuration values that control how customers can access and consume line items.

Available values:

  • timezone.tolerant
    • Allows a line item to be used up to 12 hours before its start date (UTC) and up to 12 hours after its end date (UTC), therefore making it tolerant to all time zones.
    • Supported values: true (enabled) and false (disabled).
    • Default: false
Operations