Sign in (complete)
log10x_signin_completeComplete Log10x sign-in: finalize the browser device flow or validate a pasted API key, then save credentials for the MCP server.
Instructions
Step 2 of the Log10x sign-in chain. Two mutually-exclusive paths controlled by which arg you pass. (a) { device_code: "<...>" }: finishes the browser flow that log10x_signin_start began. The model should call this AUTOMATICALLY right after log10x_signin_start returns, passing back the opaque device_code from that response unchanged. Polls Auth0's /oauth/token until the user confirms the device authorization in their browser, then exchanges the Auth0 access token for a long-lived Log10x API key. (b) { api_key: "<key>" }: pasted-key path, no browser. Validates the key against /api/v1/user and saves it. Pass exactly one of device_code or api_key; both or neither is rejected with a clear error. Either path writes the resolved API key to ~/.log10x/credentials (mode 0600), hot-reloads the MCP's env list in-process, and (if LOG10X_API_KEY is set in the host config and would override the new file) clears that env var in-process and tells the user to remove it from their host config to make the change permanent.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| api_key | No | Log10x API key to sign in with directly (no browser). Validated against /api/v1/user before saving. Use this when the user already has a key from console.log10x.com → Profile → API Settings, or when issued out-of-band by a workspace admin. Mutually exclusive with `device_code`. | |
| device_code | No | The opaque device_code returned by `log10x_signin_start`. Pass it back unchanged. The tool polls Auth0 for the access token, then exchanges it for a long-lived Log10x API key. Mutually exclusive with `api_key`. | |
| wait_seconds | No | Max seconds to poll for browser confirmation (only used when device_code is passed). Default 600. |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| data | No | ||
| tool | Yes | ||
| view | No | summary | |
| images | No | ||
| actions | No | ||
| summary | Yes | ||
| warnings | No | ||
| truncated | No | ||
| next_cursor | No | ||
| render_hint | No | ||
| generated_at | Yes | ||
| schema_epoch | Yes | ||
| schema_version | Yes |