Our Licensing APIs are designed to interact with the Members Account licensing system allowing you to get, activate, and transfer Iguana licenses programmatically, providing you have access and licenses available to do so.
...
The following steps provide an example license activation workflow calling the Iguana license APIs using curl commands:
Get the Iguana ID of your target Iguana instance
There are two methods which can be used to obtain the Iguana ID:
Expand | ||||
---|---|---|---|---|
| ||||
The Iguana ID can be obtained using the command line Windows:
Linux:
*optionally add the |
...
title | Option B: Use the IguanaX API to get license details, including the Iguana ID |
---|
Use your Iguana instance IP address and port: https://127.0.0.1:7654
Authenticate
GET /session/login
To call the IguanaX APIs you must first login and get a session cookie from the response header to authenticate your subsequent requests.
Parameters:
username: Your IguanaX instance username string
password: Your IguanaX instance password string
Response Header:
Code Block | ||
---|---|---|
| ||
Content-Length: 128
Set-Cookie: IguanaSession-jYQGeQWk97ylKuP8AmEiad=z7WR4Xwzk51hXMP2e3WeZa; path=/; HttpOnly; SameSite=Strict |
Example curl command calling the /session/login
API and parsing to retrieve Iguana session cookie the response header Set-Cookie to authenticate the next API call:
Should look similar to: IguanaSession-jYQGeQWk97ylKuP8AmEiad=z7WR4Xwzk51hXMP2e3WeZa
Code Block |
---|
IguanaCookie=`curl -i -k -X GET "http://127.0.0.1:7654/session/login?username=<user>&password=<pass>" | grep -i 'Set-Cookie: ' | awk '{print $2}' | sed 's/;$//'` |
Get License details
POST /license/get
This API method returns a JSON object containing the Iguana ID along with other license information. To authenticate, the obtained Cookie is provided in the header of the request.
Response:
Code Block | ||
---|---|---|
| ||
{
"data": {
"iguana_id": "THSWPRHMUXTT7MRR",
"license": {
"component_limit": 500,
"expiry": "0",
"license_status": "License ok",
"message_rate_limit": 0,
"search_limit": 365
},
"license_message": "To modify or extend your license, contact the iNTERFACEWARE Sales Office."
},
"success": true
} |
Example curl command calling the /license/get
API and parsing to retrieve the Iguana ID:
Code Block |
---|
IguanaID=`curl -k --header "Cookie: $IguanaCookie" -X POST "http://127.0.0.1:7654/license/get" | jq -r '.data.iguana_id'` |
Call the Members Account Licensing APIs to register your Iguana ID to generate a license code
Expand | ||||||||||
---|---|---|---|---|---|---|---|---|---|---|
| ||||||||||
Members Account Licensing API base URL: Get an Authentication Token This API method returns a JSON object containing a session token which will be used with the subsequent license API calls. Parameters:
Response:
Example curl command calling the API and parsing the Token from the response:
|
Expand | ||||||||||
---|---|---|---|---|---|---|---|---|---|---|
| ||||||||||
Members Account Licensing API base URL: Get a List of Entitlements This API method returns a JSON object containing a list of license types and select the ID for the type you want to activate. Parameters:
Response:
Example curl command calling the API and parsing the selected license entitlement id from the response:
|
...
title | 2 c) Register your Iguana ID to activate a license code |
---|
Members Account Licensing API base URL: https://my.interfaceware.com
...
This API method returns a JSON object containing the license description and activated license code.
Parameters:
product: The product you want licenses for -
IguanaX
stringtoken: Your authentication token string (from the first call)
method: The API method
license.activate
stringdescription: A description to pair with the license (test, prod, etc.) string
entitlementid: The ID of the license you want to activate string
instanceid: The Iguana ID of the instance that you want to apply the license to string
Response:
Code Block | ||
---|---|---|
| ||
{
"data": {
"description": "Test",
"code": "4492A1B5CDA25D79DFCC5DC3GHS4448B9D8A3CCC98",
"license_expiry": "2025-08-13",
"name": "IguanaX Test",
"instanceid": "THSWPRHMUXTT7MRR",
"log_search": 365,
"num_components": 50
},
"status": "ok" |
Example curl command calling the API and parsing the license code from the response:
Code Block | ||
---|---|---|
| ||
IguanaLicenseCode=`curl -k -X POST "https://my.interfaceware.com/api?method=license.activate&product=IguanaX&token=<IguanaToken>&description=IguanaLicense&entitlementid=<EntitlementID>&instanceid=<IguanaID>" | jq -r '.data.code'` |
Apply the license code to the target Iguana instance
There are two possible methods to apply the generated license code to the new Iguana instance:
Expand | ||||||||||
---|---|---|---|---|---|---|---|---|---|---|
| ||||||||||
Windows
Linux:
|
...
title | Option B: Use the IguanaX API to apply the license code to the target Iguana instance |
---|
Use your Iguana instance IP address and port: https://127.0.0.1:7654
Authenticate
GET /session/login
To call the IguanaX APIs you must first login and get a session cookie from the response header to authenticate your subsequent requests.
Parameters:
username: Your IguanaX instance username string
password: Your IguanaX instance password string
Response Header:
Code Block | ||
---|---|---|
| ||
Content-Length: 128
Set-Cookie: IguanaSession-jYQGeQWk97ylKuP8AmEiad=z7WR4Xwzk51hXMP2e3WeZa; path=/; HttpOnly; SameSite=Strict |
Example curl command calling the /session/login
API and parsing to retrieve Iguana session cookie the response header Set-Cookie to authenticate the next API call:
Should look similar to: IguanaSession-jYQGeQWk97ylKuP8AmEiad=z7WR4Xwzk51hXMP2e3WeZa
Code Block | ||
---|---|---|
| ||
IguanaCookie=`curl -i -k -X GET "http://127.0.0.1:7654/session/login?username=<user>&password=<pass>" | grep -i 'Set-Cookie: ' | awk '{print $2}' | sed 's/;$//'` |
Apply the license code
POST /license/set
This API method applies the registered license code to the Iguana instance and returns a JSON object containing the request success or failure. To authenticate, the obtained Cookie is provided in the header of the request.
Parameters:
license: the license code to be applied string
Response:
Code Block | ||
---|---|---|
| ||
{
"data": {},
"success": true
} |
Example curl command calling the /license/set
API to apply the license code and activate the Iguana instance:
Code Block | ||
---|---|---|
| ||
IguanaID=`curl -k --header "Cookie: $IguanaCookie" -X POST "http://127.0.0.1:7654/license/set?license=<LicenseCode>" |
License Transfer:
The license transfer procedure contains similar steps as to the activation procedure. The following steps provide an example license transfer workflow calling the Iguana license APIs using curl commands:
Get the Iguana IDs of the old and new Iguana instances
Expand | ||
---|---|---|
| ||
Refer to License Activation step 1 to review the options for how to obtain the Iguana ID.
|
Call the Members Account Licensing APIs to transfer a license from the old Iguana to the new Iguana instance
Expand | ||
---|---|---|
| ||
Refer to License Activation step 2 a) to review how to get the Members Account authentication Token to use in subsequent requests. |
Expand | ||
---|---|---|
| ||
Refer to License Activation step 2 b) to review how to get the license entitlements and capture the entitlement ID of the target license type. |
...
title | 2 c) Get the activation ID of the old Iguana instance |
---|
Members Account Licensing API base URL: https://my.interfaceware.com
Get List of Activated Iguana Licenses POST /api
This API method returns a JSON object containing all of the licenses activated under a particular entitlement ID (license type).
Parameters:
product: The product you want licenses for -
IguanaX
stringtoken: Your authentication token string
method: The API method
license.listActivations
stringentitlementid: The ID of the license type you want to activate string
Response:
Code Block | ||
---|---|---|
| ||
{
"data": [
{
"log_search": "60",
"num_components": "50",
"description": "Test",
"code": "SGJKLGDSLMHKEM93493DSFDS9349019A63B5A04A44290E42BBE452D508",
"license_type": "IguanaX Test",
"country": "",
"license_expiry": "2025-03-06 21:26:00",
"date_modified": "2024-03-06 21:26:00",
"state": "",
"site": "",
"city": "",
"date_issued": "2024-03-06 00:00:00",
"last_modified_by": "Admin",
"tracking_id": "",
"activation_id": "34",
"instance_id": "AJ5K8QPHHPNNSLLC"
},
{
"log_search": "60",
"num_components": "50",
"description": "Old Iguana Instance",
"code": "3D83F6E6753820DCC509A6F75849B488SFSKJG3086B2D7AAEBF5D0E67D",
"license_type": "IguanaX Test",
"country": "",
"license_expiry": "2025-08-13 16:04:10",
"date_modified": "2024-08-13 16:04:10",
"state": "",
"site": "",
"city": "",
"date_issued": "2024-08-13 16:04:10",
"last_modified_by": "Admin",
"tracking_id": "",
"activation_id": "210",
"instance_id": "RPQC9TYWFHPGEDGT"
}
],
"status": "ok"
} |
...
Code Block | ||
---|---|---|
| ||
OldIguanaActivationID=`curl -k -X POST "https://my.interfaceware.com/api?method=license.listActivations&product=IguanaX&token=<IguanaToken>&entitlementid=<EntitlementID>" | jq -r --arg instanceId "$OldIguanaID" '.data[] | select(.instance_id == $instanceId) | .activation_id'` |
Expand | ||||||||||
---|---|---|---|---|---|---|---|---|---|---|
| ||||||||||
Members Account Licensing API base URL: Transfer a License This API method returns a JSON object containing the license information about the Iguana you've transferred the license to. This in Parameters:
Response:
Example curl command calling the API and parsing the license code from the response:
|
Apply the license code to the new Iguana Instance
...
title | See License Activation Step 3 for how to apply a license code |
---|
...