sidebar_label | title | id | description | sidebar_custom_props | ||
---|---|---|---|---|---|---|
astro deployment token workspace-token |
astro deployment token workspace-token |
astro-deployment-token-workspace-token |
Scope a Workspace token to a specific Deployment. |
|
:::cliastroonly :::
Manage Workspace-level API tokens within a specific Deployment. See Assign an Organization or Workspace API token to a Deployment.
Add a Workspace API token to a Deployment and grant it Deployment-specific permissions.
astro deployment workspace-token add --deployment-id=<my-deployment-id> --role=DEPLOYMENT_ADMIN --workspace-token-name=<workspace-token-name>
Option | Description | Valid Values |
---|---|---|
--deployment-id |
The Deployment ID where you want to manage tokens. | Any Deployment ID. |
-r , --role |
The role the API token has in the Deployment. | DEPLOYMENT_ADMIN or a custom role name. |
-n , --workspace-token-name |
The Workspace API token name. | Any string. If the name contains a space, specify the entire name within quotes "" . |
--workspace-id |
The Workspace to which the Deployment belongs. | Any Workspace ID. |
astro deployment workspace-token add --deployment-id=clvduhrvd000008l842ohcpvb --role=DEPLOYMENT_ADMIN --workspace-token-name="My workspace token"
List all Workspace API tokens that are assigned to a specific Deployment.
astro deployment workspace-token list --deployment-id=<your-deployment-id> --workspace-id=<your-workspace-ic>
Option | Description | Valid Values |
---|---|---|
--deployment-id |
The ID of the Deployment to list API tokens for. | Any Deployment ID. |
--workspace-id |
The Workspace to which the Deployment belongs. | Any Workspace ID. |
Output | Description | Data Type |
---|---|---|
ID |
The API token ID. | String |
NAME |
The name of the API token. | String |
DESCRIPTION |
The API token description. | String |
SCOPE |
The original scope of the API token. | String |
DEPLOYMENT_ROLE |
The API token's role in the Deployment. | String |
CREATED |
How long ago the API token was created, in days. | String |
CREATED BY |
The name of the user who created the API token. | String |
astro deployment workspace-token list --deployment-id=clvduhrvd000008l842ohcpvb
Remove a Workspace API token from a Deployment.
astro deployment workspace-token remove --deployment-id=<my-deployment-id> --workspace-token-name=<workspace-token-name> --workspace-id=<my-workspace-id>
Option | Description | Valid Values |
---|---|---|
--deployment-id |
The Deployment ID you want to remove an API token from. | Any Deployment ID. |
-n , --workspace-token-name |
The name of the Workspace API token you want to remove from the Deployment. | Any string. |
--workspace-id |
The Workspace to which the Deployment belongs. | Any Workspace ID. |
astro deployment workspace-token remove --deployment-id=clvduhrvd000008l842ohcpvb --workspace-token-name="My workspace token" --workspace-id=clvdwt4z3000008l60ofb6347
Update the role a Workspace API token has within a Deployment.
astro deployment workspace-token update --workspace-token-name=<workspace-token-name> --deployment-id=<my-deployment-id> --role=DEPLOYMENT_ADMIN
Option | Description | Valid Values |
---|---|---|
--deployment-id |
The Deployment ID you want to scope a Workspace API token to. | Any Deployment ID. |
-r , --role |
The Deployment role that you want to assign to the token. | DEPLOYMENT_ADMIN or a custom role name. |
-n , --workspace-token-name |
The name of the Workspace API token you want to update. | Any string. |
--workspace-id |
The Workspace to which the Deployment belongs. | Any Workspace ID. |
astro deployment workspace-token update --deployment-id=clvduhrvd000008l842ohcpvb --role=DEPLOYMENT_ADMIN --workspace-token-name="My workspace token"