Create Port Access Key
create_access_keyCreates an access key for a locked pod port so external programs can authenticate with a bearer token, requiring confirmation to issue the one-time secret.
Instructions
Create an access key for a locked port of a pod, only when the user asks for one. The key is a secret that lets a program outside the pod call the port: it is sent as Authorization: Bearer <key>, or as X-Meshive-Key: <key> when the app uses Authorization itself.
With confirm=false (default) it only returns a summary and creates nothing; call again with confirm=true and the summary's pod_name after the user agreed. The confirmed answer has the value in access_key, this once: it can't be read again. Give it to the user who asked and nothing else. Never use it yourself, and never put it in files, commits, commands or other tools. To call the app for your own work, use run_command inside the pod against http://localhost:, which needs no key.
name is a label of 1-64 characters. expires_in_days is 30, 90 (default) or 365, or 0 for a key that never expires. The port must be locked (port_not_locked), and only a workspace admin or billing member can create keys.
If a confirmed call times out or fails without a clear answer, don't call again: read access_keys first, because the key may exist, and a key whose value was lost can only be revoked.
The server keeps no operation record of this call, so operation_status can't look it up and a repeated confirmed call runs again.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"pod": "<pod>",
"port": "<port>",
"name": "<name>"
},
"name": "create_access_key"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| pod | Yes | The pod_name from the pods tool. Its display name also works, except on a confirmed call (confirm=true) that opens a port, changes a key or signs out browsers: use the `pod_name` the preview returned. | |
| name | Yes | ||
| port | Yes | The port number, from the pod's `endpoints` in the pods tool; it must be exposed over HTTPS (`access` locked or unlocked). | |
| confirm | No | ||
| workspace | No | ||
| operation_id | No | ||
| expires_in_days | No |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
No arguments | |||