Skip to main content
POST
/
v2
/
workspace
/
authtokens
/
get
Get Auth Tokens
curl --request POST \
  --url https://api.velt.dev/v2/workspace/authtokens/get \
  --header 'Content-Type: application/json' \
  --header 'x-velt-auth-token: <x-velt-auth-token>' \
  --header 'x-velt-workspace-id: <x-velt-workspace-id>' \
  --data '
{
  "data": {
    "apiKey": "<string>"
  }
}
'
{
  "result": {
    "status": "success",
    "message": "Auth tokens retrieved successfully.",
    "data": {
      "apiKey": "velt_api_key_1",
      "authTokens": [
        {
          "token": "eyJhbGciOiJSUzI1NiIs...",
          "name": "Default Auth Token",
          "domains": []
        }
      ]
    }
  }
}
Use this API to retrieve all auth tokens associated with a specific API key.
This endpoint uses workspace-level auth: pass x-velt-workspace-id and x-velt-auth-token (from the Create Workspace response) as headers.

Endpoint

POST https://api.velt.dev/v2/workspace/authtokens/get

Headers

x-velt-workspace-id
string
required
Your Workspace ID.
x-velt-auth-token
string
required

Body

Params

data
object
required

Example Request

{
  "data": {
    "apiKey": "velt_api_key_1"
  }
}

Example Response

Success Response

{
  "result": {
    "status": "success",
    "message": "Auth tokens retrieved successfully.",
    "data": {
      "apiKey": "velt_api_key_1",
      "authTokens": [
        {
          "token": "eyJhbGciOiJSUzI1NiIs...",
          "name": "Default Auth Token",
          "domains": []
        }
      ]
    }
  }
}

Failure Response

{
  "error": {
    "status": "NOT_FOUND",
    "message": "API key not found."
  }
}
{
  "result": {
    "status": "success",
    "message": "Auth tokens retrieved successfully.",
    "data": {
      "apiKey": "velt_api_key_1",
      "authTokens": [
        {
          "token": "eyJhbGciOiJSUzI1NiIs...",
          "name": "Default Auth Token",
          "domains": []
        }
      ]
    }
  }
}