What you need: A Tooling Metrics account with access to at least one organization.
The Tooling Metrics API is a JSON REST API over HTTPS. Every request requires a Bearer token.
Step 1: Generate an API token
Section titled “Step 1: Generate an API token”- In Tooling Metrics, click your avatar at the bottom of the sidebar → Setting → API Tokens tab.
- Click New API Token.
- Enter a name for this token (e.g.,
erp-integration,cam-plugin). - Click Create — the token is shown once. Copy it immediately; it will not be shown again.
Step 2: Find your organization ID
Section titled “Step 2: Find your organization ID”Most API endpoints require an organization_id path parameter. Retrieve yours:
curl https://api.toolingmetrics.com/v1/organizations \ -H "Authorization: Bearer YOUR_TOKEN"Response — a map of organization name to numeric ID:
{ "Acme Manufacturing": 12, "Acme Tooling": 15}Use the numeric ID in all subsequent requests.
Step 3: Make your first request
Section titled “Step 3: Make your first request”List machines in your organization:
curl https://api.toolingmetrics.com/v1/organizations/12/machines \ -H "Authorization: Bearer YOUR_TOKEN"A 200 OK with a JSON array means authentication and scoping are working correctly.
Step 4: Handle errors
Section titled “Step 4: Handle errors”All API errors return JSON. Most use an errors array:
{ "errors": ["Description of what went wrong"] }| Status | Cause | Action |
|---|---|---|
401 |
Token missing/invalid, or token valid but not authorized for this resource, or for an organization_id that doesn’t exist |
Check the message: a missing token asks you to authenticate; an authorization failure says “You are not authorized to perform this action” |
404 |
Record not found or belongs to a different organization | Verify the ID, and that the record belongs to the organization_id in the URL; an organization_id that doesn’t exist answers 401. Note: this error’s body uses a singular error key, not errors |
422 |
Validation failed | Read the errors array in the response |
429 |
Rate limit exceeded | Wait Retry-After seconds and retry |
There is no 403 status in this API — both missing/invalid tokens and valid-but-unauthorized tokens return 401, distinguished only by the error message. See Errors for the full picture, including the error/errors key inconsistency.
See Errors for the complete reference.