---
updatedAt: 2026-03-01T18:57:15.000Z
agentTools:
  siteIndex: https://techdocs.akamai.com/llms.txt
  projectIndex: https://techdocs.akamai.com/edgekv/llms.txt
---

# Download an access token

Download a previously created EdgeKV access token. To get a token, you need to know the token `name`. Tokens created using the enhanced token workflow don't include the JWT value in the response. To learn more about access tokens, refer to the [EdgeKV guide](doc:generate-and-retrieve-edgekv-access-tokens).

# OpenAPI definition

```json
{
  "externalDocs": {
    "description": "See documentation for Akamai's EdgeKV API",
    "url": "https://techdocs.akamai.com/edgekv/reference"
  },
  "info": {
    "license": {
      "name": "Apache 2.0",
      "url": "https://www.apache.org/licenses/LICENSE-2.0.html"
    },
    "title": "Access tokens",
    "version": "v1"
  },
  "openapi": "3.0.0",
  "paths": {
    "/tokens/{tokenName}": {
      "get": {
        "description": "Download a previously created EdgeKV access token. To get a token, you need to know the token `name`. Tokens created using the enhanced token workflow don't include the JWT value in the response. To learn more about access tokens, refer to the [EdgeKV guide](https://techdocs.akamai.com/edgekv/docs/generate-and-retrieve-edgekv-access-tokens).",
        "externalDocs": {
          "description": "See documentation for this operation in Akamai's EdgeKV API",
          "url": "https://techdocs.akamai.com/edgekv/reference/get-token"
        },
        "operationId": "get-token",
        "parameters": [
          {
            "description": "For customers who manage more than one account, this [runs the operation from another account](https://techdocs.akamai.com/developer/docs/manage-many-accounts-with-one-api-client). The Identity and Access Management API provides a [list of available account switch keys](https://techdocs.akamai.com/iam-api/reference/get-client-account-switch-keys).",
            "in": "query",
            "name": "accountSwitchKey",
            "required": false,
            "schema": {
              "example": "1-5C0YLB:1-8BYUX",
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "example": {
                  "allowOnProduction": true,
                  "allowOnStaging": true,
                  "cpcode": "7654321",
                  "expiry": "9999-12-31",
                  "issueDate": "2022-01-30",
                  "latestRefreshDate": "2022-03-30",
                  "name": "token1",
                  "namespacePermissions": {
                    "default": [
                      "r",
                      "w",
                      "d"
                    ]
                  },
                  "nextScheduledRefreshDate": "2022-05-30",
                  "restrictToEdgeWorkerIds": [
                    "1234",
                    "5678"
                  ],
                  "tokenActivationStatus": "COMPLETE",
                  "uuid": "12886ccf-xxxx-xxxx-xxxx-766740ce227e"
                },
                "schema": {
                  "additionalProperties": false,
                  "description": "Lists properties related to EdgeKV access token.",
                  "properties": {
                    "allowOnProduction": {
                      "description": "Whether to allow this token access to the Akamai production network.",
                      "type": "boolean"
                    },
                    "allowOnStaging": {
                      "description": "Whether to allow this token access to the Akamai staging network.",
                      "type": "boolean"
                    },
                    "cpcode": {
                      "description": "__Read-only__ The EdgeKV CP code assigned to the customer account.",
                      "readOnly": true,
                      "type": "string"
                    },
                    "expiry": {
                      "description": "Tokens created using the enhanced token workflow have an expiry date, in ISO 8601 format, of `9999-12-31`. Any tokens created before the release of the enhanced workflow display an actual expiry date such as `2025-02-28`.",
                      "format": "date",
                      "readOnly": true,
                      "type": "string"
                    },
                    "issueDate": {
                      "description": "Initial token creation date in ISO 8601 format.",
                      "format": "date",
                      "readOnly": true,
                      "type": "string"
                    },
                    "latestRefreshDate": {
                      "description": "Most recent token refresh date in ISO 8601 format. A `null` value indicates the token has not yet been refreshed.",
                      "format": "date",
                      "nullable": true,
                      "readOnly": true,
                      "type": "string"
                    },
                    "name": {
                      "description": "Friendly name of the token. Used when retrieving tokens by name.",
                      "maxLength": 32,
                      "minLength": 1,
                      "type": "string"
                    },
                    "namespacePermissions": {
                      "additionalProperties": {
                        "description": "List of permissions a token should have on a namespace. This array's key is the name of the namespace that you want to grant permissions to. To list namespaces see, [List namespaces](https://techdocs.akamai.com/edgekv/reference/get-namespaces). You can specify `r` for read, `w` for write, or `d` for delete.",
                        "items": {
                          "enum": [
                            "r",
                            "w",
                            "d"
                          ],
                          "type": "string"
                        },
                        "maxItems": 3,
                        "minItems": 1,
                        "type": "array",
                        "uniqueItems": true,
                        "x-akamai": {
                          "file-path": "schemas/token-namespace.yaml"
                        }
                      },
                      "description": "Namespace identifiers the token should have access to, plus the associated read, write, and delete permissions. All specified namespaces need the same database data access policy. A namespace's data access policy comes from the value of the `restrictDataAccess`, set when creating a namespace.",
                      "maxProperties": 20,
                      "minProperties": 1,
                      "type": "object"
                    },
                    "nextScheduledRefreshDate": {
                      "description": "Next scheduled date of the token refresh in ISO 8601 format.",
                      "format": "date",
                      "readOnly": true,
                      "type": "string"
                    },
                    "restrictToEdgeWorkerIds": {
                      "description": "A set of EdgeWorker IDs authorized to access EdgeKV via the token. By default if you omit this array, the token authorizes access for all IDs.",
                      "items": {
                        "type": "string"
                      },
                      "type": "array"
                    },
                    "tokenActivationStatus": {
                      "description": "The `IN_PROGRESS` status indicates token activation is still in progress, and it's not yet possible to make successful EdgeKV requests from EdgeWorkers that use the token. Once activation completes, status is `COMPLETE`. Otherwise a value of `ERROR` indicates a problem that prevented activation.",
                      "enum": [
                        "IN_PROGRESS",
                        "COMPLETE",
                        "ERROR"
                      ],
                      "readOnly": true,
                      "type": "string"
                    },
                    "uuid": {
                      "description": "A generated unique identifier for the access token. This should be used in the `edgekv_tokens.js` file.",
                      "format": "uuid",
                      "readOnly": true,
                      "type": "string"
                    }
                  },
                  "required": [
                    "allowOnProduction",
                    "allowOnStaging",
                    "name",
                    "namespacePermissions"
                  ],
                  "type": "object",
                  "x-akamai": {
                    "file-path": "schemas/token.yaml"
                  }
                }
              }
            },
            "description": "Returns an EdgeKV access token."
          },
          "400": {
            "content": {
              "application/problem+json": {
                "example": {
                  "additionalDetail": {
                    "requestId": "e30761e0a7b6072b"
                  },
                  "detail": "Name contains invalid characters.",
                  "errorCode": "EKV_2000",
                  "instance": "/edgekv/error-instances/0959b9b3-8043-4f87-9510-0e752160d713",
                  "status": 400,
                  "title": "Bad Request",
                  "type": "/edgekv/error-types/edgekv-bad-request"
                },
                "schema": {
                  "additionalProperties": true,
                  "description": "Error messaging.",
                  "properties": {
                    "additionalDetail": {
                      "additionalProperties": false,
                      "description": "More details about the error.",
                      "properties": {
                        "requestId": {
                          "description": "Request identifier.",
                          "type": "string"
                        }
                      },
                      "type": "object"
                    },
                    "detail": {
                      "description": "A description of the error.",
                      "type": "string"
                    },
                    "errorCode": {
                      "description": "Internal error code used to assist with troubleshooting by Akamai employees.",
                      "type": "string"
                    },
                    "instance": {
                      "description": "Reference to unique instance of the error.",
                      "type": "string"
                    },
                    "status": {
                      "description": "The HTTP code for the error.",
                      "type": "integer"
                    },
                    "title": {
                      "description": "Text representation of the HTTP error code.",
                      "type": "string"
                    },
                    "type": {
                      "description": "Reference to additional documentation.",
                      "type": "string"
                    }
                  },
                  "type": "object",
                  "x-akamai": {
                    "file-path": "schemas/error.yaml"
                  }
                }
              }
            },
            "description": "[Bad request](https://techdocs.akamai.com/edgekv/reference/400). Invalid token name.",
            "x-akamai": {
              "file-path": "errors/400-token.yaml"
            }
          },
          "404": {
            "content": {
              "application/problem+json": {
                "example": {
                  "additionalDetail": {
                    "requestId": "b08961e0a5540233"
                  },
                  "detail": "Token with name token1 does not exist.",
                  "errorCode": "EKV_3000",
                  "instance": "/edgekv/error-instances/e77c8cc1-3698-412a-b574-64fc12c05741",
                  "status": 404,
                  "title": "Not Found",
                  "type": "/edgekv/error-types/edgekv-not-found"
                },
                "schema": {
                  "additionalProperties": true,
                  "description": "Error messaging.",
                  "properties": {
                    "additionalDetail": {
                      "additionalProperties": false,
                      "description": "More details about the error.",
                      "properties": {
                        "requestId": {
                          "description": "Request identifier.",
                          "type": "string"
                        }
                      },
                      "type": "object"
                    },
                    "detail": {
                      "description": "A description of the error.",
                      "type": "string"
                    },
                    "errorCode": {
                      "description": "Internal error code used to assist with troubleshooting by Akamai employees.",
                      "type": "string"
                    },
                    "instance": {
                      "description": "Reference to unique instance of the error.",
                      "type": "string"
                    },
                    "status": {
                      "description": "The HTTP code for the error.",
                      "type": "integer"
                    },
                    "title": {
                      "description": "Text representation of the HTTP error code.",
                      "type": "string"
                    },
                    "type": {
                      "description": "Reference to additional documentation.",
                      "type": "string"
                    }
                  },
                  "type": "object",
                  "x-akamai": {
                    "file-path": "schemas/error.yaml"
                  }
                }
              }
            },
            "description": "[Not found](https://techdocs.akamai.com/edgekv/reference/404). Token is not found.",
            "x-akamai": {
              "file-path": "errors/404-token.yaml"
            }
          },
          "410": {
            "content": {
              "application/problem+json": {
                "example": {
                  "additionalDetail": {
                    "requestId": "b08961e0a5540233"
                  },
                  "detail": "Token has expired.",
                  "errorCode": "EKV_3000",
                  "instance": "/edgekv/error-instances/e77c8cc1-3698-412a-b574-64fc12c05741",
                  "status": 410,
                  "title": "Not Found",
                  "type": "/edgekv/error-types/edgekv-not-found"
                },
                "schema": {
                  "additionalProperties": true,
                  "description": "Error messaging.",
                  "properties": {
                    "additionalDetail": {
                      "additionalProperties": false,
                      "description": "More details about the error.",
                      "properties": {
                        "requestId": {
                          "description": "Request identifier.",
                          "type": "string"
                        }
                      },
                      "type": "object"
                    },
                    "detail": {
                      "description": "A description of the error.",
                      "type": "string"
                    },
                    "errorCode": {
                      "description": "Internal error code used to assist with troubleshooting by Akamai employees.",
                      "type": "string"
                    },
                    "instance": {
                      "description": "Reference to unique instance of the error.",
                      "type": "string"
                    },
                    "status": {
                      "description": "The HTTP code for the error.",
                      "type": "integer"
                    },
                    "title": {
                      "description": "Text representation of the HTTP error code.",
                      "type": "string"
                    },
                    "type": {
                      "description": "Reference to additional documentation.",
                      "type": "string"
                    }
                  },
                  "type": "object",
                  "x-akamai": {
                    "file-path": "schemas/error.yaml"
                  }
                }
              }
            },
            "description": "[Gone](https://techdocs.akamai.com/edgekv/reference/410). Token has expired.",
            "x-akamai": {
              "file-path": "errors/410.yaml"
            }
          },
          "500": {
            "content": {
              "application/problem+json": {
                "example": {
                  "additionalDetail": {
                    "requestId": "cd9b61e08148009b"
                  },
                  "detail": "An internal error occurred.",
                  "errorCode": "EKV_0000",
                  "instance": "/edgekv/error-instances/cdb7767c-817e-4805-9f28-0816eefa0ba8",
                  "status": 500,
                  "title": "Internal Server Error",
                  "type": "/edgekv/error-types/edgekv-internal-server-error"
                },
                "schema": {
                  "additionalProperties": true,
                  "description": "Error messaging.",
                  "properties": {
                    "additionalDetail": {
                      "additionalProperties": false,
                      "description": "More details about the error.",
                      "properties": {
                        "requestId": {
                          "description": "Request identifier.",
                          "type": "string"
                        }
                      },
                      "type": "object"
                    },
                    "detail": {
                      "description": "A description of the error.",
                      "type": "string"
                    },
                    "errorCode": {
                      "description": "Internal error code used to assist with troubleshooting by Akamai employees.",
                      "type": "string"
                    },
                    "instance": {
                      "description": "Reference to unique instance of the error.",
                      "type": "string"
                    },
                    "status": {
                      "description": "The HTTP code for the error.",
                      "type": "integer"
                    },
                    "title": {
                      "description": "Text representation of the HTTP error code.",
                      "type": "string"
                    },
                    "type": {
                      "description": "Reference to additional documentation.",
                      "type": "string"
                    }
                  },
                  "type": "object",
                  "x-akamai": {
                    "file-path": "schemas/error.yaml"
                  }
                }
              }
            },
            "description": "[Internal server error](https://techdocs.akamai.com/edgekv/reference/500).",
            "x-akamai": {
              "file-path": "errors/500.yaml"
            }
          }
        },
        "summary": "Download an access token",
        "tags": [
          "Access tokens"
        ]
      },
      "parameters": [
        {
          "description": "Unique identifier for each namespace.",
          "in": "path",
          "name": "tokenName",
          "required": true,
          "schema": {
            "example": "my_token",
            "type": "string"
          },
          "x-akamai": {
            "file-path": "parameters/token-id-path.yaml"
          }
        }
      ],
      "x-akamai": {
        "file-path": "paths/token.yaml",
        "path-info": "/tokens/{tokenName}"
      }
    }
  },
  "servers": [
    {
      "url": "https://{hostname}/edgekv/v1"
    }
  ],
  "tags": [
    {
      "description": "Manage the access tokens used to authorize an EdgeWorker ID to access data in an EdgeKV namespace.",
      "name": "Access tokens"
    }
  ],
  "x-akamai": {
    "auth-type": "EDGE_GRID",
    "file-path": "02-tokens.yaml"
  },
  "x-readme": {
    "samples-languages": [
      "curl",
      "python",
      "node"
    ],
    "explorer-enabled": true,
    "proxy-enabled": true
  }
}
```

# Sibling pages

* [Create an access token](https://techdocs.akamai.com/edgekv/reference/post-tokens.md)
* [List access tokens](https://techdocs.akamai.com/edgekv/reference/get-tokens.md)
* [Revoke an access token](https://techdocs.akamai.com/edgekv/reference/delete-token.md)
* [Refresh an access token](https://techdocs.akamai.com/edgekv/reference/post-refresh-token.md)