Skip to main content
Glama
gpambrozio

onshape-mcp

by gpambrozio

Sign in to Onshape

onshape_login

Authenticate to Onshape by opening a browser for API key or OAuth login, verify credentials, and store them for secure access.

Instructions

Sign in to Onshape by opening a browser. method='api_key' (default) opens a local page that links to the Onshape developer key page and accepts the pasted key pair. method='oauth' runs the OAuth 2.0 authorization-code flow against an app you registered in the Onshape developer portal. The credential is verified against Onshape and stored in the OS keychain. Returns immediately with status 'pending' if the user has not finished yet — poll with onshape_login_status.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
portNoLoopback port for the callback (OAuth default 8471).
scopeNoSpace-separated OAuth scopes, when the app needs them stated.
storeNoWhere to keep the credential: auto (keychain, else file), keychain, or file.
methodNoLogin method (default api_key).
base_urlNoOnshape API base URL (default https://cad.onshape.com).
client_idNoOAuth client id; also read from ONSHAPE_OAUTH_CLIENT_ID.
oauth_urlNoOAuth server (default https://oauth.onshape.com).
wait_secondsNoSeconds to wait for the browser before returning (default 20).
client_secretNoOAuth client secret; also read from ONSHAPE_OAUTH_CLIENT_SECRET.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A4.6/5.0
Behavior5/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Beyond the openWorldHint annotation, the description discloses real behavioral traits: it opens a browser, supports two distinct credential flows, verifies against Onshape, stores credentials in the OS keychain, and returns early with 'pending'. This is substantial transparency for an interactive login tool.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Every sentence carries distinct information: the core action, each login method, credential handling, and the pending/poll behavior. No filler or redundant restatement of the schema is present.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness4/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

The description covers the login flow, return behavior, and sibling polling tool, which is strong given 9 optional parameters and no output schema. It stops short of describing the successful-return shape or how to handle already-authenticated users, but those are minor gaps for invoking the tool correctly.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

The input schema already covers all parameters with descriptions, so the baseline is solid. The description adds meaningful semantic detail by explaining what the method parameter's api_key and oauth values actually do, going beyond the schema's enum labels.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

States a specific verb and resource: 'Sign in to Onshape by opening a browser,' followed by concrete details of the two login methods. It clearly differentiates itself from onshape_login_status by pointing to that tool for polling pending status.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines4/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description tells the agent when to poll with onshape_login_status, which is a direct usage directive relative to a sibling. It does not explicitly explain when to choose api_key versus oauth, but the method semantics make the practical context clear.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Deploy Server

Other Tools