License API
The License API provides methods for your application to query properties of the installed license.
License API EndpointThe License API is part of the Integration API. To discover the Integration API base endpoint, query the
REPLICATED_INTEGRATIONAPI
environment variable from inside your container.
All methods return result as JSON. If Accept
header is included in the request, it must contain */*
or application/json
. If neither of these values is present, the request will fail with status 400.
/license/v1/license
Returns current license information.
Name | Type | Description |
---|---|---|
license_id | String | License ID of this installation. Multiple installations can use the same license. |
installation_id | String | Unique ID of this installation. |
release_channel | String | Release channel name. Available in Replicated API 1.3.5 and later |
fields | Array | Always returned. This is the array of field names and their values. |
expiration_time | String (optional) | License expiration time in |
billing_frequency | String (optional) | Optional billing frequency as defined in vendor portal. |
billing_begin | String (optional) | Billing start time in |
billing_end | String (optional) | Billing end time in |
Example request:
curl -k $REPLICATED_INTEGRATIONAPI/license/v1/license
Example response:
HTTP/1.1 200 OK
Content-Type: application/json; charset=utf-8
Date: Tue, 16 Jun 2015 18:05:35 GMT
Content-Length: 214
{
"license_id": "f49b290abf39b945c6f519ee6ca1c4ad",
"installation_id": "44e8188e6fec84ac425829cde0eeee8e",
"release_channel": "Unstable",
"fields": [
{
"field": "max_hosts",
"title": "Maximum Number of Hosts",
"type": "Integer",
"value": 1,
"hide_from_customer": false
},
{
"field": "min_hosts",
"title": "Minimum Number of Hosts",
"type": "Integer",
"value": 1,
"hide_from_customer": false
},
{
"field": "account",
"title": "Account Name",
"type": "String",
"value": "Replicated, Inc",
"hide_from_customer": false
}
],
"expiration_time": "2016-01-01T00:00:00Z"
}
/license/v1/field/<field_name>
Returns license field.
Example request:
curl -k $REPLICATED_INTEGRATIONAPI/license/v1/field/max_queues
Example response:
HTTP/1.1 200 OK
Content-Type: application/json; charset=utf-8
Date: Tue, 16 Jun 2015 18:14:23 GMT
Content-Length: 36
{
"field": "max_queues",
"value": "99"
}
Updated 3 months ago