GET /api/fleet/uninstall_tokens/{uninstallTokenId}

Spaces method and path for this operation:

get /s/{space_id}/api/fleet/uninstall_tokens/{uninstallTokenId}

Refer to Spaces for more information.

Get one decrypted uninstall token by its ID.

[Required authorization] Route required privileges: fleet-agents-all.

Path parameters

  • uninstallTokenId string Required

    The ID of the uninstall token

Responses

  • 200 application/json

    Successful response

    Hide response attribute Show response attribute object
    • item object Required

      Additional properties are NOT allowed.

      Hide item attributes Show item attributes object
      • created_at string Required
      • id string Required
      • namespaces array[string]

        Not more than 100 elements.

      • policy_id string Required
      • policy_name string | null
      • token string Required
  • 400 application/json

    Bad Request

    Hide response attributes Show response attributes object
    • attributes Required
    • error string
    • errorType string
    • message string Required
    • statusCode number
  • 404 application/json

    Not Found

GET /api/fleet/uninstall_tokens/{uninstallTokenId}
curl \
 --request GET 'https://localhost:5601/api/fleet/uninstall_tokens/{uninstallTokenId}' \
 --header "Authorization: $API_KEY"
Response examples (200)
Decrypted uninstall token for an agent policy
{
  "item": {
    "created_at": "2024-01-01T00:00:00.000Z",
    "id": "token-id-1",
    "namespaces": [
      "default"
    ],
    "policy_id": "policy-id-1",
    "policy_name": "Default policy",
    "token": "CKHJsJcBqNwIRcRBNDaE"
  }
}
Response examples (400)
Example of a generic error response
{
  "error": "Bad Request",
  "message": "An error message describing what went wrong",
  "statusCode": 400
}
Response examples (404)
No uninstall token was found with the given ID
{
  "error": "Not Found",
  "message": "Uninstall Token not found with ID token-id-1",
  "statusCode": 404
}