MCP drained my api in 2 Days
The mcp completely drained my api after only a few days.
This is very disappointing. I have been using gpt for coding features for a year. Copy paste repeat. From my point of view the MCP is saving me the trouble of clicking ctr+a/c/a/v —> commit over and over. It's great!
It was. So this tool seemed amazing. No more copy/pasta. Two days of testing: Done. Paywall.
No more fun.
I feel like the api wasnt ready for the amazing feature that onshape just gave the world.
Is this a problem across the board? something that is being addressed?
Comments
-
I feel your disappointment I too have been clicking ctr+a/c/a/v —> committing over and over, and I have numbers if they help.
One read-only session: listed the Feature Studios in nine documents, read seven of them. No writes, no tests, no iteration. That cost 53 API requests from about 20 tool calls, because one call fans out into several REST requests underneath.
I am on 2,500 a year, which is 11 requests per working day. An afternoon of looking at my own documents cost four and a half days of it.
The part I keep getting stuck on is that nobody did anything wrong. The MCP is not inefficient and Mark was not careless. Exploring is what an agent does! it lists things to find out what exists, then reads whatever those reference. A script you can budget. An agent you cannot. The API call limit allocation was built for scripts.
So Onshape shipped the best FeatureScript tool it has ever made and metered it as though we would use it twice a month!
What is the intended answer? Either the allocation moves, or traffic through Onshape's own MCP server gets the same exemption public App Store apps already have.
3 -
I burnt through 2500 in a few months when I was only using scripts that ChatGPT created to GET and PUT the FeatureScript into documents.
I was given an additional 2500 recently. I burned those and somehow went 25% over my limit in 3 small projects in a matter of hours of total use.
On the one hand the Onshape API tokens are ~$0.03 each, and I'm paying OpenAI a bunch each month for what works out to be unlimited tokens for my usage. I can (and likely will) pay for more Onshape API tokens, but I'd like them to be something I need to think about a lot less. It literally feels like we're being nickel and dimed here. I was more excited to start using the MCP server than any normal person should be, but I have to say burning through tokens instantly is a huge buzz kill.- My hello world - AKA make a box - test. Maybe 50 tokens?
- A version of End cap (End Cap Plus) for Frames which can automatically find all the open frame ends. The feature is mostly done and I was excited to publish it. Chat estimates this used ~190 tokens.
- I noticed that the Javawizard GitHub clone of the Standard Library was months out of date, so I asked ChatGPT for help to figure out a good way to create a current Repo, and keep it up to date. I told it to look at the changelog and only check the Std Lib doc once a week in a lightweight way. There are ~270 tabs of FS, there were 4 releases to backfill, it made a couple failed tests, and it wanted to do a SHA-256 verification of the synced code. This apparently took a few thousand tokens.
The whole point of having an up to date mirror like this is to avoid burning API tokens regularly for my LLM to learn from or use the standard library correctly.
The updated GitHub Mirror is in the link below, but I ran out of tokens so there may be issues. I also don't know if I can maintain this given the API token issues.
[edit: the repo below has been retired. use @Derek_Van_Allen_BD clone of the standard library here]
https://github.com/gatrall/onshape-std-library-mirror/tree/readme
Can Onshape PLEASE make and maintain an official GitHub mirror of the standard library so no one needs to waste tokens like this?
@GregBrown @Vajrang_Parvate😭
Simon Gatrall | Product Development, Engineering, Design, Onshape | Ex- IDEO, PCH, Unagi, Carbon | LinkedIn
2 -
Onshape MCP API Usage Investigation Report
Date: 2026-08-16Scope: Consolidated analysis and controlled benchmarks through the production test ending at API counter 254.
1. Executive Summary
The most important findings are:
- One MCP tool call is not equivalent to one Onshape API request.
- Several MCP tools fan out into multiple Onshape REST requests.
- The cost of an operation is driven much more by the remote workflow than by the amount of local reasoning or code transformation.
- A deliberately optimized FeatureScript workflow can perform substantial real development at a predictable 9-call floor:
get_featurescript= 6 callsput_featurescript= 3 calls
- A large derivative design task—converting a copied wheel FeatureScript into a new complementary tire generator—also cost exactly 9 calls, despite extensive local redesign.
- Expensive validation and convenience workflows, especially
test_featureandcreate_geometry, consume roughly 10–13 calls each. - Identity checks, usage checks, discovery, and other apparently minor helper operations can themselves cost multiple API calls.
- The most promising optimization strategy is not necessarily reducing design complexity. It is reducing the number and type of remote Onshape interactions per development cycle.
The investigation therefore supports a new operating model:
Perform as much reasoning, code transformation, design work, and batching locally as possible, then use the minimum number of Onshape MCP interactions required to read and persist the result.
2. Investigation Background
The original main Onshape account showed:
- Plan: Free
- Annual API limit: 2,500
- Usage observed: 2,513
- Usage percentage: 100.52%
- Tracking start date shown by Onshape: Feb. 19, 2026
The user reported:
- no manually created API key on the main account,
- only roughly two days of active Onshape MCP use when exhaustion was discovered,
- heavy MCP activity during those two days,
- advanced FeatureScript editing,
- repeated rebuilding and derived-feature creation,
- a complex feature with more than 50 geometry controls,
- autonomous creation of one house followed by roughly 30 additional related modules.
Before controlled testing, it was uncertain whether two days of MCP work could plausibly consume most or all of the annual allocation.
The benchmark results now make that explanation credible.
3. Important Architectural Distinction
The investigation established that two different quantities must be kept separate:
- Assistant-visible MCP tool calls
- Underlying Onshape REST API requests generated by the MCP server
Reducing the number of visible MCP tool calls helps, but it does not guarantee low Onshape API consumption.
The parallel investigation had already identified this distinction and noted that high-level MCP tools can perform multiple hidden operations internally. fileciteturn0file0L146-L186
Examples include:
test_featurecreate_geometry- identity/context checks
- source reads
- usage checks
- Feature Studio discovery
- workspace/branch management
- preview generation
This distinction became the central framework for all later testing.
4. Earlier Uncontrolled / Partially Controlled Evidence
Before the clean isolated benchmarks, several experiments suggested unexpectedly high API consumption.
Cube-related observations
A first cube-related session showed a 20-call delta, but that session included more than the final geometry operation. It also included usage checks, source reads, notes/documentation activity, testing, and a final write. Therefore, it should not be treated as a pure “cube creation = 20 calls” benchmark. fileciteturn0file0L107-L125
A separate later cube experiment showed:
- Start: 86
- End: 105
- Delta: 19
That result occurred even after API-conservation instructions had been introduced. fileciteturn0file0L127-L142
Other user-measured simple edits had previously shown:
- edit to double cube size: 11 calls
- edit to 2 × 2 × 3 in: 10 calls
Those earlier 10–11 call results became especially important after the isolated read/write costs were measured.
5. Controlled Benchmark Method
The controlled-test protocol was:
- The user manually records the Onshape API counter.
- The assistant performs exactly one targeted MCP operation, or one tightly defined workflow.
- No unrelated discovery, identity lookup, usage check, testing, documentation search, branching, or verification is performed unless that is the specific test.
- The user manually checks the counter again.
- The before/after delta becomes the measured API cost.
The manual dashboard was intentionally preferred over
get_api_usage, because the investigation later showed thatget_api_usageitself consumes quota and may be timing-sensitive.6. Isolated Primitive Benchmarks
6.1
get_featurescriptTwo identical reads were performed against the same Feature Studio.
Run 1
- Before: 132
- After: 138
- Delta: 6
Run 2
- Before: 141
- After: 147
- Delta: 6
Result
get_featurescript= stable at 6 API callsThis was one of the most important early discoveries. A simple source read is already expensive relative to the annual 2,500-call limit.
No caching benefit was observed on the immediate repeated read.
6.2
put_featurescriptThe exact same FeatureScript source was written back unchanged.
Run 1
- Before: 138
- After: 141
- Delta: 3
Run 2
- Before: 147
- After: 150
- Delta: 3
Result
put_featurescript= stable at 3 API callsThis established the minimal existing-Feature-Studio edit baseline:
get_featurescript6 +
put_featurescript3 =
9 API calls
6.3
test_featurescriptA trivial lambda was used:
function(context, id) { return "ok"; }Run 1
- Before: 150
- After: 154
- Delta: 4
Run 2
- Before: 154
- After: 158
- Delta: 4
Result
test_featurescript= stable at 4 API callsThis means a workflow using:
get_featurescript -> test_featurescript -> put_featurescripthas a measured component cost of approximately:
6 + 4 + 3 = 13 API calls
6.4
test_featureA minimal no-op feature was tested in a real Part Studio context.
Run 1
- Before: 158
- After: 171
- Delta: 13
Run 2
- Before: 171
- After: 181
- Delta: 10
Result
test_feature= variable, 10–13 API calls observedThis confirmed that
test_featureis one of the expensive MCP primitives.Its documented workflow already implies substantial fan-out because it writes into a real Feature Studio, inserts a temporary or “trojan” feature into a Part Studio, and evaluates through Onshape.
A read +
test_feature+ write development cycle therefore costs approximately:6 + 10–13 + 3 = 19–22 API calls
That cost is roughly double the optimized read/write-only path.
6.5
create_geometryA minimal cube-style feature was created using the normal branch-based workflow with cleanup enabled.
Run 1
- Before: 181
- After: 193
- Delta: 12
Run 2
- Before: 193
- After: 205
- Delta: 12
Result
create_geometry= stable at 12 API callsThe visible operation included:
- creating a new branch/workspace,
- deploying FeatureScript,
- adding a feature to a Part Studio,
- generating geometry,
- producing three preview images,
- cleanup behavior.
The parallel analysis had already noted that
create_geometryis not a direct edit of a supplied Feature Studio and is better understood as an isolated branch/testing workflow. fileciteturn0file0L33-L46This reinforced the rule:
Do not use
create_geometryfor normal editing of an existing Feature Studio.
6.6
create_feature_studio— emptyTwo empty Feature Studios were created in the same workspace.
Run 1
- Before: 205
- After: 210
- Delta: 5
Run 2
- Before: 210
- After: 212
- Delta: 2
Result
create_feature_studioempty = variable, 2–5 API calls observedThis suggested a possible cold/warm effect.
The first call may include setup, context resolution, or other one-time work that the immediate repeat did not need.
6.7
list_feature_studiosTwo identical discovery calls were made.
Run 1
- Before: 212
- After: 214
- Delta: 2
Run 2
- Before: 214
- After: 216
- Delta: 2
Result
list_feature_studios= stable at 2 API callsThis is relatively cheap, but still unnecessary when a direct Feature Studio URL already supplies the element ID.
Therefore:
If
did,
wid, and
eidare known from the URL, do not call
list_feature_studios.
6.8
get_api_usageTwo usage-check calls were tested.
Run 1
- Dashboard before: 216
- Tool reported: 216
- Dashboard after: 218
- Observed delta: 2
Run 2
- Dashboard before: 218
- Tool response reported: 220
- Dashboard after: 223
- Observed delta: 5
Result
get_api_usage= variable / timing-sensitive, 2–5 calls observedThe second run showed that the usage value returned by the tool may represent an intermediate state during the tool’s own execution.
This suggests:
- some requests may occur after the usage value is fetched,
- Onshape’s usage accounting may update asynchronously,
- the tool may perform additional calls after retrieving the counter,
- or the dashboard and API usage endpoint may update on slightly different schedules.
The practical conclusion is clear:
get_api_usageshould not be used as the primary benchmarking instrument.
Manual dashboard before/after checks are cleaner.
6.9
create_feature_studiowith initial sourceA new Feature Studio was created and populated with valid FeatureScript in the same MCP invocation.
Run 1
- Before: 223
- After: 226
- Delta: 3
Run 2
- Before: 226
- After: 229
- Delta: 3
Result
Prepopulated
create_feature_studio= stable at 3 API callsThis was a strong optimization result.
Compare:
- create empty Studio, warm result = 2
- then
put_featurescript= 3 - separate total = ~5
- create Studio with source already supplied = 3
Therefore, when creating a new Feature Studio whose complete source is already known:
Prefer
create_feature_studio(..., contents=completeSource)6.10
whoamiTwo identity checks were measured.
Run 1
- Before: 229
- After: 234
- Delta: 5
Run 2
- Before: 234
- After: 236
- Delta: 2
Result
whoami= variable, 2–5 API calls observedThis showed another cold/warm pattern.
Operational conclusion:
Do not call
whoamiroutinely when the account context is already known.
7. Production Workflow Test 1 — Real Menu Reorganization
A fully developed wheel FeatureScript was used for a production-style test.
The requested change was substantial at the UI level:
- reorganize menu structure,
- improve terminology,
- make groups more user-friendly,
- preserve geometry logic.
The controlled workflow was:
- one
get_featurescript - extensive local analysis and code reorganization
- one
put_featurescript - no remote testing
- no docs search
- no identity check
- no listing
- no usage check
- no verification read
Result
- Before: 236
- After: 245
- Delta: 9
This exactly matched the predicted 6 + 3 read/write floor.
Significance
This was the first strong demonstration that a meaningful real-world FeatureScript edit can stay at the theoretical minimum established by the primitive benchmarks.
The complexity of the local edit did not increase API usage.
8. Production Workflow Test 2 — Major Derivative Feature Creation
The next test was intentionally much more ambitious.
A copied wheel FeatureScript was supplied in a new Feature Studio. The task was:
Use the coordinate system of the wheel FeatureScript to create a complementary tire model, with controls for tire fit. Use the supplied tire specification document as guidance, but prioritize a working model and choose practical dimensions where necessary.
The supplied tire specification defined:
- tire-to-rim interface parameters,
- rim diameter and rim width,
- bead-seat planes,
- section width,
- aspect ratio,
- overall diameter,
- sidewall geometry,
- bead geometry,
- tread/crown geometry,
- fit/clearance concepts,
- the same Z-axis wheel rotational coordinate convention,
- and extensive higher-order carcass/tread/manufacturing options. fileciteturn1file0L3-L31 fileciteturn1file0L33-L55
The tire document explicitly defined:
- Z axis = wheel rotational axis
- XY plane = wheel radial plane
- origin = wheel center
- axial coordinate = Z fileciteturn1file0L590-L612
The tire model was designed locally to use that same coordinate convention and the wheel’s existing rim placement logic.
The first tire version prioritized:
- working tire envelope,
- rim fit,
- hollow cavity,
- bead bundles,
- sidewall shape,
- shoulder/tread geometry,
- useful fit controls,
- circumferential grooves,
- default dimensions compatible with the copied wheel.
The source specification included far more advanced options—carcass plies, belts, cap ply, internal liner, loaded geometry, tread blocks, sipes, lettering, and manufacturing features—but these were intentionally not required for the first working tire pass. fileciteturn1file0L509-L574
The controlled workflow was again:
- one
get_featurescript - complete local redesign
- one
put_featurescript - no remote testing
- no documentation search
- no listing
- no identity check
- no usage check
- no branch creation
- no verification read
Result
- Before: 245
- After: 254
- Delta: 9
Significance
This was the strongest production result in the investigation.
A large existing FeatureScript was:
- read,
- understood,
- structurally reinterpreted,
- combined with an external technical specification,
- transformed into a substantially different parametric model,
- and written back,
while consuming exactly the same 9 API calls as the menu reorganization.
This strongly supports the following conclusion:
Local task complexity does not materially increase Onshape API consumption when the remote interaction pattern remains one read and one write.
9. Current Evidence Table Through Counter 254
| Operation / workflow | Run 1 | Run 2 | Current interpretation |
|---|---:|---:|---|
|get_featurescript| 6 | 6 | Stable at 6 |
|put_featurescript| 3 | 3 | Stable at 3 |
|test_featurescript| 4 | 4 | Stable at 4 |
|test_feature| 13 | 10 | Variable: 10–13 |
|create_geometry| 12 | 12 | Stable at 12 |
|create_feature_studioempty | 5 | 2 | Variable: 2–5 |
|list_feature_studios| 2 | 2 | Stable at 2 |
|get_api_usage| 2 | 5 | Variable / timing-sensitive |
|create_feature_studiowith source | 3 | 3 | Stable at 3 |
|whoami| 5 | 2 | Variable: 2–5 |
| Real optimized menu edit | 9 | — | Matched predicted floor |
| Major derivative FeatureScript creation | 9 | — | Matched predicted floor |10. Cost Model Derived From the Tests
Minimal existing-Feature-Studio edit
get_featurescript + put_featurescript= 6 + 3
= 9 API calls
Existing edit with lightweight FeatureScript evaluation
get_featurescript + test_featurescript + put_featurescript= 6 + 4 + 3
= 13 API calls
Existing edit with full
test_featureget_featurescript + test_feature + put_featurescript= 6 + (10–13) + 3
= 19–22 API calls
New Feature Studio with known source
create_feature_studio(contents=completeSource)= 3 API calls
Branch-based geometry test
create_geometry= 12 API calls
11. Why the Earlier 10–11 Call Simple Edits Now Make Sense
Earlier simple edit tests had shown:
- 11 calls
- 10 calls
The isolated benchmarks now explain those numbers.
The basic edit path alone costs:
- 6 calls to read
- 3 calls to write
Total = 9
That leaves only 1–2 additional calls for any surrounding ancillary behavior.
Therefore the earlier 10–11 call edit measurements are consistent with the current primitive cost model.
12. Major Architectural Conclusions
12.1 FeatureScript complexity is not the primary cost driver
The 9-call menu-edit test and the 9-call wheel-to-tire derivative test demonstrate that:
- small local edit
- large local edit
- major code reorganization
- major derivative model creation
can all cost essentially the same amount if the Onshape interaction pattern stays unchanged.
The dominant cost is therefore not local reasoning or code volume.
It is remote interaction count and tool choice.
12.2
test_featureis expensiveAt 10–13 calls per invocation,
test_featureis one of the largest isolated costs measured.Repeatedly calling it during normal development can double or triple the cost of an otherwise efficient edit.
12.3
create_geometryshould remain special-purposecreate_geometryconsistently cost 12 calls and performs a branch-heavy workflow.It should be reserved for cases where:
- isolated geometry testing is explicitly desired,
- a temporary branch is useful,
- preview generation is useful,
- or the workflow specifically needs a persistent experimental workspace.
It should not be the default route for editing an existing Feature Studio.
12.4 Discovery and account checks should not be routine
Measured costs:
list_feature_studios= 2whoami= 2–5get_api_usage= 2–5 and timing-sensitive
These are meaningful costs under a 2,500-call annual allowance.
If the direct Feature Studio URL already gives:
- document ID
- workspace ID
- element ID
then those IDs should be parsed client-side and reused.
12.5 Usage measurement should ideally be internal to the MCP
The parallel investigation proposed returning an
apiCallsConsumedvalue from each MCP operation. fileciteturn0file0L284-L309The later
get_api_usagetests strengthened that recommendation because:- quota checks themselves consume quota,
- returned usage may not reflect the complete cost of the same invocation,
- manual dashboard checks are more reliable but cumbersome.
A future MCP should internally count outbound Onshape REST requests and return:
apiCallsConsumedwith each tool result.
13. Recommended Low-Cost Production Modes
Mode 1 — Existing Feature Studio, known safe change
Use:
get_featurescript -> local edit -> put_featurescriptExpected cost:
9 calls
This is now proven for both minor and major transformations.
Mode 2 — Existing Feature Studio, lightweight validation needed
Use:
get_featurescript -> local edit -> test_featurescript -> put_featurescriptExpected cost:
13 calls
Use only when the requested change requires evaluation but does not require a full real-feature environment.
Mode 3 — Existing Feature Studio, full real-feature validation needed
Use:
get_featurescript -> local edit -> test_feature -> put_featurescriptExpected cost:
19–22 calls
This should be used deliberately, not automatically.
Mode 4 — New Feature Studio with complete known source
Use:
create_feature_studio(..., contents=completeSource)Expected cost:
3 calls
This is currently the most efficient measured deployment path for a brand-new Studio.
14. Implications for Autonomous Development
The investigation does not show that autonomous development itself is inherently expensive.
It shows that autonomous development becomes expensive when each implementation step is coupled to repeated remote operations such as:
- read,
- test,
- verify,
- discover,
- branch,
- preview,
- read again,
- write again.
The two production tests demonstrate that a large bounded implementation packet can potentially cost only 9 calls if:
- the assistant reads once,
- performs extensive design and code work locally,
- writes once,
- and owner verification happens afterward.
This suggests a much more sustainable development pattern:
large implementation packet -> owner test/acceptance -> one corrective packet if needed
rather than:
many small remote edit/test/verify loops
For example:
- one optimized implementation packet = ~9 calls
- one owner-directed correction packet = another ~9 calls
- total for a two-pass owner-validation cycle = ~18 calls
By contrast, repeated
read -> test_feature -> writecycles can cost roughly 19–22 calls each.15. Annual Capacity Implications
At a 2,500-call annual limit:
If every meaningful edit costs 9 calls
2,500 / 9 ≈ 277 optimized edit cycles
If every edit uses
test_featurescript2,500 / 13 ≈ 192 cycles
If every edit uses
test_feature2,500 / 19–22 ≈ 113–131 cycles
If a workflow repeatedly uses 12-call
create_geometry2,500 / 12 ≈ 208 operations
These are still theoretical maxima because real usage also includes:
- setup,
- retries,
- mistakes,
- account checks,
- usage checks,
- failures,
- branch operations,
- document management,
- feature creation,
- and unrelated MCP activity.
The practical lesson is that 2,500 calls is a small annual budget for high-frequency CAD automation unless workflows are deliberately optimized.
16. Current Working Conclusions
Through API counter 254, the investigation supports the following conclusions:
- The Onshape MCP itself is strongly implicated in rapid API consumption.
- A visible MCP invocation can fan out into several underlying Onshape REST requests.
get_featurescriptis unexpectedly expensive at 6 calls.put_featurescriptis relatively efficient at 3 calls.test_featurescriptcosts 4 calls.test_featurecosts 10–13 calls and should be treated as expensive.create_geometrycosts 12 calls and should remain special-purpose.create_feature_studiowith complete source is highly efficient at 3 calls.list_feature_studios,whoami, andget_api_usageshould not be routine preflight calls.get_api_usageis unsuitable as a clean benchmark instrument because it consumes quota and appears timing-sensitive.- The minimal proven edit workflow is 9 calls.
- A substantial menu reorganization hit that 9-call floor exactly.
- A major wheel-to-tire derivative model also hit that same 9-call floor exactly.
- Local reasoning complexity does not materially affect API usage when the remote interaction pattern is held constant.
- The best immediate optimization is to batch more work locally and reduce remote validation/discovery calls.
- The investigation now has enough evidence to move from primitive benchmarking into higher-level autonomous workflow experiments.
0 -
I created a new account. Using it to analyze the api. I hammered it hard the first hard when the mcp arrived, not paying attention. I learned a lesson at least.
I am still very happy with the mcp. I just see i have to manage the api side.
The tool at its current state is a convenience to an experienced featurescript coder. I now have a budget plan for API. Too little, too late for this account!
My disappointment is that my main account is depleted of api and i now have to use alt-account to test and work with the mcp. Otherwise, i am still digging the mcp launch
1 -
I learned from your example about ripping stuff right out of a browser session and bypassing the API for featurescript updates. I've only used it to keep this repo up to date, but I've been steadily keeping it up to the latest version for the last few updates.1 -
I'm about to upgrade from Standard to Professional for a personal account just so I can continue to do more FS development with MCP. Part of the agreement now says that API overages are $0.06/token, just for reference.
So that my experience burning tokens to create a Standard Library mirror repo isn't in vain…
@GregBrown @Darren_A_Henry please take a look at this IR:
Simon Gatrall | Product Development, Engineering, Design, Onshape | Ex- IDEO, PCH, Unagi, Carbon | LinkedIn
4 -
Very interesting. Thanks for all this analysis.
Its made a bit more sense of the API limits. When there are (or were) relatively few of us building apps, I could not understand why Onshape implemented the limits; it had been an all you can eat buffet for years. I thought that surely any dev API calls were insignificant compared to the enormous cost of the 3 million (?) or so free onshape accounts?? But I guess now they new what was coming - not so much on the AI prompt feature script side, but on the upcoming text prompt modelling which will surely mature over the next few months and and years. It could rinse their servers, just as people experiment.
It makes you think about what the big AI services should really cost users, and what they will cost after we become fully dependent on them, and the investors ask for their return.
0 -
The inverse of that conversation is what value do these AI services provide the end users and businesses. I haven't yet ran the Onshape MCP through its paces (I'm being conservative with my API allowances until the right project comes along) but I've recently been leaning on AI more and more to target complex problems that we otherwise would never have scoped at the business or subcontracted out to other firms and we're starting to see the value come back 10 or 20 fold for some projects.
As an example, we've been in need of a CAM post processor for a particularly quirky piece of CNC equipment and had initially commissioned a company to develop said post for around ~$10,000 and after months of back and forth between us, them, and the machine manufacturer who wrote the non-standard proprietary file format this machine uses instead of normal G code or NC code we were no closer to having parts produced on the machine than when we started working with them. A day and a half with Claude on the $200 plan has produced a functional post where both the machine manufacturer and the post developer had told us there were fundamental limitations with the file format we needed to export to and that we would need to be changing our 15 year running workflow to accommodate these limitations that didn't in fact exist.
When used for this purpose it could have cost us another couple thousand dollars for the AI subscription or more token budget and the business case could still be made for the value it brings to the company after considering all alternatives. But we're also gatekeeping team access to this service to only the senior development team that truly knows what they're doing because if we were to have opened the doors to the entire rest of the team we'd be burning team budgets on memes or mundane questions that have answers that have been answered time and time again if you just read our docs.
That's a long winded way to say I think even in an API rate limited model with token costs being what they are at present day there will be use cases that make sense to spend that budget on, and other use cases that are just plain silly. Long term I'd hope things trend more towards accessibility and being cheaper, but I'll find the use for it one day either way.
2 -
yep @Derek_Van_Allen_BD , I agree. I did some Featurescript today on the simple plus tier of gpt. Nothing ground breaking, just an adaption to the stock sweep feature that adds optional overshoot tolerance on the path (so bendy ply can be cut down after fixing, because its never a such a precise process laminating up layers of plywood). This thread stopped me trying Onshape labs because of the api limits.
Gpt got it absolutely right first time. It hasn't been right first time for me before now.
I'm just thinking that all these tools will go up one day. But I agree its likely to be less than staff time, or an external consultant.
0 -
@mark_cawley thanks for doing this, it's very well done.
Now I'm very cautious about what to ask for and will track my api usage.
I'm thinking of forcing it to use a featurescript tab I created by adding this prompt.
and trying to stop it from doing simple stuff I can do easily with the user interface.
0 -
So here's a really basic issue: apparently asking through the MCP how many API tokens you have left consumes at least a token. I can do the same thing by having my agent go to https://cad.onshape.com/user/developer and scrape the number. Surely that takes more resources from the Onshape servers to serve up that dynamic webpage than a simple API call?
get_api_usageconsumes one or more Onshape API requestsCan someone from Onshape please explain this logic? To me this makes zero sense.
Simon Gatrall | Product Development, Engineering, Design, Onshape | Ex- IDEO, PCH, Unagi, Carbon | LinkedIn
0 -
When the api started, in the beginning, Onshape was going to take a cut from each api store sale. How much are you going to take? No answers. This was in the early days when Joe was in charge of the app store. I know Joe well and he had no answers.
They're listening and they want us to be successful, they just don't know the answers, but they're going to support us. Don't give up, just keep going…
0 -
@mark_cawley how did you run your tests? are you snooping packets outbound from OS?
I just checked the official API library and test_feature isn't an endpoint. Maybe the MCP is adding new endpoints not found in the standard api documentation?
0 -
I ran the test by running the mcp through gpt on a new account and feeding gpt the numbers back from the developer api usage page. So the end_point call is an early marker from gpt. I have no idea. What the test did for me was allow me to see that it didn't matter if i made a 1in cube, or I had the mcp revise a complex feature, the cost was relatively the same for the API Usage. My failure was probably the quantity of calls that I made the first few days. A couple hundred, easy.
One update: Onshape sent me four emails that I did not see which me know about the API usage. The emails went to my spam though. However, to give Onshape their credit, they sent me emails every 25% until it was gone.
I haven't really used the api much. Codex can perform all the tasks of the mcp without api usage or a developer key. It uses rest calls. Mine is set up on its own cdp with Playwright. (429 was my only real hurdle at the beginning. 15 hour retry-after. Really Onshape?) Its fast, but not as fast as the mcp.
Point is that I am no expert at API. This drain took me by suprise. My other accounts are not having any trouble, so I learned my lesson.0 -
I've used the api a lot. Many times you make a call to get a list and then make many calls based on the number of items in that list. If you change anything, then you modify and put the list back which takes more api calls. But this has nothing to do with a feature script. The api controls assemblies and other system level stuff. I'm confused about the api usage and AI, what's it really doing?
The api is just controlling the reading and writing of the feature script tabs but it also has to know the compile errors and runtime errors. The published api doesn't support feature script errors so how does AI know this stuff?
My little block was 70 tokens for a worthless feature and I'm with S1mon that isn't going to be enough. I'm struggling trying to figure out how to be more efficient with my prompts so I don't run out.
My favorite prompt for the day is to tell AI "if you don't know that's ok, don't quess just tell me you don't know"
0 -
From a Temporary GPT session about MCP instructions: The List used by the MCP, what each is used for, and its API usage level. Note this is conjecture, but maybe it can help the cause.
———————————-whoami
Identifies the Onshape user currently authenticated through the MCP, including company information when available. It also reports which account’s API allocation is currently being consumed.
API usage: Low. Likely one or a small number of account/session REST API calls.logout
Signs the current user out of the MCP’s Onshape session. The next Onshape MCP action would require authentication again.
API usage: Low. Primarily authentication/session handling rather than CAD-document activity.set_api_allocation
Lets the user view or change which eligible account’s Onshape API allocation is charged for MCP activity, such as personal versus company allocation.
API usage: Low. Account/company allocation lookup or configuration calls.get_api_usage
Reports API usage for the current allocation period, including calls used, remaining allowance, limits, cycle dates, and overage information when applicable.
API usage: Low. Reads account/API-allocation information; no CAD modeling operations.test_featurescript
Executes a FeatureScript lambda against an Onshape Part Studio context. This is the lighter-weight tool used to test and debug FeatureScript behavior without installing a complete custom feature.
API usage: Moderate. Uses Onshape’s FeatureScript-evaluation/Part Studio API. Each new test attempt creates another API interaction.search_featurescript_documentation
Searches the available FeatureScript documentation for functions, operations, types, queries, examples, and other language/API information relevant to writing or debugging FeatureScript.
API usage: Low or possibly mixed MCP-side/API activity. The MCP states that its tool calls consume Onshape API calls, but the exact underlying endpoint used for documentation search is not exposed.edit_featurescript_notes
Updates the MCP’s saved FeatureScript knowledge notes. It is intended for recording useful discoveries, fixes, workarounds, and non-obvious FeatureScript behavior learned during development.
API usage: Unclear/likely minimal. The notes appear to be MCP-side storage, although the server generally states that tool calls consume Onshape API activity.read_featurescript_notes
Reads the MCP’s accumulated FeatureScript notes. These notes help avoid repeating previously discovered mistakes and allow successful patterns to be reused.
API usage: Unclear/likely minimal. Primarily MCP-side knowledge access rather than document or geometry access.list_feature_studios
Lists the Feature Studio elements that exist in a specified Onshape document workspace, including the information needed to identify which studio to read or modify.
API usage: Low. Document/element metadata REST calls.create_feature_studio
Creates a new Feature Studio element inside a specified Onshape document workspace. It can optionally be initialized with FeatureScript source code.
API usage: Low to moderate. Performs document/element creation and possibly Feature Studio content-writing calls.create_geometry
Creates actual CAD geometry by making a new branched workspace, writing a FeatureScript custom feature, adding that feature to a Part Studio, and executing it.
API usage: High. Likely involves several REST calls across documents/workspaces, elements, Feature Studios, Part Studio features, regeneration/evaluation, and potentially cleanup.test_feature
Tests a complete FeatureScript custom feature in a real Feature Studio and Part Studio environment. Unliketest_featurescript, it validates the full installed-feature path.
API usage: High. The MCP creates/writes temporary Feature Studio state, adds a temporary feature to a Part Studio, and evaluates the feature, so one invocation can fan out into multiple API calls.get_featurescript
Reads the complete current FeatureScript source from a specified Feature Studio. It is typically used before modifying an existing studio so the current code is not accidentally overwritten.
API usage: Low. Feature Studio/document read operation.put_featurescript
Writes the complete finalized FeatureScript source back into an existing Feature Studio. It replaces the studio’s contents, so it is intended for use after testing and debugging are complete.
API usage: Low to moderate. Feature Studio write/update API call(s), potentially followed by validation/error reporting.
The biggest API consumers are therefore generally
create_geometryandtest_feature, followed by repeatedtest_featurescriptcalls. The lightest operations are account lookups, Feature Studio reads/listing, and probably documentation/notes operations. The exact number of allocation-counted REST requests behind each MCP instruction is not exposed by the MCP.0 -
Check out this latest post and technique for reducing your API calls: https://forum.onshape.com/discussion/31663/onshape-mcp-how-ai-can-ask-30-questions-for-the-price-of-1-api-call#latest
0
Categories
- All Categories
- 10.2K Community Support
- 4.6K General
- 194 Account and subscriptions
- 353 Data management
- 1.6K Product Feedback
- 215 New in Onshape
- 14 Onshape Labs
- 75 CAM Studio
- 35 PCB Studio
- 107 Simulation
- 209 Onshape Mobile
- 315 App Store & Partners Apps
- 8.2K Using Onshape
- 1.8K Drawings
- 2.3K FeatureScript
- 324 Learning Center
- 253 Education Community





