Create an API token
create_tokenCreates an API token for a project or for the organization, with its permissions, its environments and its lifetime; it is returned only once. Not by an agent connected through OAuth: a person creates it in while.
Tool call template
This tool declares no required parameters. Add optional parameters from the input schema as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {},
"name": "create_token"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| days | No | Lifetime in days (30 by default, 0 without expiry). | |
| name | No | What it is for ("GitLab CI"). | |
| scope | No | A project, or the organization. | project |
| project | No | The project. | |
| permissions | No | deploy and read by default. | |
| environments | No | Where it can act (production, previews, or names); without a list, everywhere. | |
| organization | No | For an organization token: its name; optional with an organization token. |