API7 Docs

Import or update the API7 Enterprise license

PUT /api/license

PUT /api/license

Interactive request editor loads with JavaScript.

Authorization

X-API-KEY<token>

In: header

Query Parameters

dry-run?"all"

When specified, run the operation in dry-run mode.

Value in

  • "all"

Request Body

application/json

Response Body

application/json

application/json

curl -X PUT "$API_BASE_URL/api/license" \  -H "Content-Type: application/json" \  -d '{    "data": "“xxxx1N-tNaTpttX-NjOdXjyg\\""  }'

License imported successfully.

{
  "value": {
    "customer": "API7",
    "effective_at": 1654012800,
    "expired_at": 1717171200,
    "max_dp_cores": 100,
    "max_non_production_dp_cores": 20,
    "feature_list": [
      "API7 Gateway"
    ],
    "deployment_id": "d1e1ea2b-2cff-4c38-b57e-408e1dffec52",
    "free_trial": true,
    "is_test_env": true,
    "issuance_date": 1625769798,
    "ai_gateway": {
      "status": "not_authorized",
      "effective_at": 1654012800,
      "expired_at": 1717171200
    }
  }
}
Complete operation details and schema variants

PUT /api/license

Import or update the API7 Enterprise license

Import a new license payload or update the existing enterprise license for the organization. You can optionally use dry-run mode to validate license content before applying it.

Required IAM Permission: Action iam:UpdateLicense, Resource arn:api7:iam:organization/*

Parameters

  • dry-run (query, string, optional): When specified, run the operation in dry-run mode.

Request body

Content type: application/json

  • data (string, required): Encoded license data.

Responses

  • 200: License imported successfully.

  • allOf variant 1

  • value (object, optional): The specific resource.

  • allOf variant 2

  • value (object, optional): The license object.

  • value.customer (string, optional): The customer name.

  • value.effective_at (integer, optional): The timestamp when the license becomes effective.

  • value.expired_at (integer, optional): The timestamp when the license expires.

  • value.max_dp_cores (integer, optional): The maximum number of DP cores available to production gateway groups.

  • value.max_non_production_dp_cores (integer, optional): The maximum number of DP cores available to non-production gateway groups. Licenses issued before the production / non-production split carry no such allowance, so this reads as 0 and any gateway group flagged non-production is immediately over its limit.

  • value.feature_list (array, optional): An array of licensed features.

  • value.deployment_id (string, optional): A unique identifier that is automatically generated with each deployment of API7 Enterprise.

  • value.free_trial (boolean, optional): If true, the license is for free trial only.

  • value.is_test_env (boolean, optional): If true, license is for test environment.

  • value.issuance_date (integer, optional): The license issuance timestamp.

  • value.ai_gateway (object, optional): AI Gateway authorization status.

  • value.ai_gateway.status (string, optional): The AI Gateway authorization status:

  • not_authorized: AI Gateway is not included in the license.

  • not_effective: AI Gateway license has not yet taken effect.

  • normal: AI Gateway is authorized and active.

  • expired: AI Gateway license has expired. Existing configurations remain active, but modifications are not allowed.

  • value.ai_gateway.effective_at (integer, optional): The timestamp when the AI Gateway license becomes effective.

  • value.ai_gateway.expired_at (integer, optional): The timestamp when the AI Gateway license expires.

  • 400: Bad Request — The request was malformed or contained invalid parameters. Check the error_msg field for details.

  • value (object, optional): The specific resource.

  • error_msg (string, optional): The error message.

cURL

curl -X PUT '$API_BASE_URL/api/license'