How AI is applied across API Evangelist and APIs.io. Read my AI disclosure →
API Evangelist API Evangelist
Discovery
Learnings
Guidance
Toolbox
Alignment
API Evangelist LLC

Onshape Document API

Create and manage documents.

Onshape Document API is one of 42 APIs that Onshape publishes on the APIs.io network, described by a machine-readable OpenAPI specification.

Tagged areas include Document. The published artifact set on APIs.io includes an OpenAPI specification and an API reference.

This API exposes 37 operations across 31 paths, and defines 79 schemas. It is described by OpenAPI 3.0.1, at version 1.218.84032-34acba44be17.

Requests are made against a single base URL, https://cad.onshape.com/api/v16.

37 operations 31 paths 79 schemas 4 DELETE15 GET18 POST

Metadata

The identity and technical contract details declared by the specification.

Specification
OpenAPI 3.0.1
API Version
1.218.84032-34acba44be17
Base URL
https://cad.onshape.com/api/v16
Authentication
OAuth 2.0, HTTP Basic
License
Terms of Service
Resource Areas
1

Authentication & Security 2

Onshape Document API declares 2 security schemes for authenticating requests. It supports OAuth 2.0 (OAuth2) using the authorizationCode flow, exposing 24 scopes. It accepts HTTP basic authentication (BasicAuth). By default, every request must be authenticated.

  • OAuth2 — Use OAuth 2.0 to authenticate requests.
  • BasicAuth — Use Basic Authentication with API Keys (key as username and secret as password) to authenticate requests.

Paths & Operations 37

Across 31 paths, the API surfaces 37 operations — 4 DELETE, 15 GET, 18 POST. Each is listed below with its method, path, parameters, and response codes.

Document 37

Create and manage documents.

GET
/documents
Get a list of documents that meet the criteria you specify.
getDocuments 11 params → 200
POST
/documents
Create and upload a document.
createDocument body → default
GET
/documents/d/{did}/externaldata/{fid}
Download external data file(s) associated with the document.
downloadExternalData 3 params → 200
GET
/documents/d/{did}/versions
Retrieve versions by document ID.
getDocumentVersions 3 params → default
POST
/documents/d/{did}/versions
Create version by document ID.
createVersion 1 param body → default
GET
/documents/d/{did}/versions/{vid}
Retrieve version by document ID and version ID.
getVersion 4 params → 200
POST
/documents/d/{did}/w/{wid}/e/{eid}/latestdocumentreferences
Update external references to latest by document ID, workspace ID, and tab ID.
updateExternalReferencesToLatestDocuments 3 params body → 200
POST
/documents/d/{did}/w/{wid}/moveelement
Move tab by document ID and workspace ID.
moveElementsToDocument 2 params body → default
POST
/documents/d/{did}/w/{wid}/revertunchangedtorevisions
revertUnchangedToRevisions 2 params body → default
POST
/documents/d/{did}/w/{wid}/syncAppElements
syncAppElements 2 params body → default
GET
/documents/d/{did}/workspaces
Retrieve workspaces by document ID.
getDocumentWorkspaces 1 param → default
POST
/documents/d/{did}/workspaces
Create workspace by document ID.
createWorkspace 1 param body → default
DELETE
/documents/d/{did}/workspaces/{wid}
Delete workspace by document ID and workspace ID.
deleteWorkspace 2 params → default
GET
/documents/d/{did}/{wm}/{wmid}/documenthistory
Retrieve document history by document ID and workspace or microversion ID.
getDocumentHistory 3 params → default
GET
/documents/d/{did}/{wvm}/{wvmid}/contents
Retrieve tabs and folders by document ID and workspace or version or microversion ID.
getDocumentContents 7 params → default
GET
/documents/d/{did}/{wvm}/{wvmid}/elements
Retrieve tabs by document ID and workspace or version or microversion ID.
getElementsInDocument 8 params → 200
GET
/documents/d/{did}/{wvm}/{wvmid}/unitinfo
Get the selected units and precision by document ID and workspace or version or microversion ID.
getUnitInfo 4 params → default
GET
/documents/d/{did}/{wv}/{wvid}/currentmicroversion
Retrieve current microversion by document ID and workspace or version ID.
getCurrentMicroversion 3 params → default
POST
/documents/d/{did}/{wv}/{wvid}/e/{eid}/export
Export document by document ID, workspace or version ID, and tab ID.
export2Json 5 params body → default
GET
/documents/d/{did}/{wv}/{wvid}/insertables
Retrieve insertables by document ID and workspace or version ID.
getInsertables 30 params → default
POST
/documents/search
Search document.
search body → default
GET
/documents/{did}
Retrieve document by document ID.
getDocument 1 param → 200
POST
/documents/{did}
Update document attributes by document ID.
updateDocumentAttributes 1 param body → default
DELETE
/documents/{did}
Delete document by document ID.
deleteDocument 2 params → default
GET
/documents/{did}/acl
Retrieve access control list by document ID.
getDocumentAcl 1 param → default
POST
/documents/{did}/acl/anonymousAccess
Allow or deny anonymous access to a document or publication.
updateAnonymousAccess 1 param body → default
POST
/documents/{did}/acl/public
Make a document public or private.
updatePublicAccess 1 param body → default
POST
/documents/{did}/notes
Update document notes by document ID.
updateDocumentNotes 1 param body → default
GET
/documents/{did}/permissionset
Retrieve Document permissions by document ID.
getDocumentPermissionSet 1 param → 200
POST
/documents/{did}/share
Share document by document ID.
shareDocument 1 param body → default
DELETE
/documents/{did}/share/{eid}
Remove document View permissions from a user or other entity.
unShareDocument 3 params → default
POST
/documents/{did}/shareWithSupport
Share document by document ID with Onshape support.
shareWithSupport 1 param → default
DELETE
/documents/{did}/shareWithSupport
Unshare document with support.
unshareFromSupport 1 param → default
GET
/documents/{did}/w/{wid}/mergePreview
Merge preview of changes that will occur based on document ID, workspace ID and source workspace/version ID
mergePreview 5 params → default
POST
/documents/{did}/w/{wid}/restore/{vm}/{vmid}
Restore version or microversion to workspace by document ID, workspace ID, and version or microversion ID.
restoreFromHistory 5 params body → default
POST
/documents/{did}/workspaces/{wid}/copy
Copy workspace by document ID and workspace ID.
copyWorkspace 2 params body → 200
POST
/documents/{did}/workspaces/{wid}/merge
Merge into workspace by document ID and workspace ID.
mergeIntoWorkspace 2 params body → default

Schemas 79

The contract defines 79 schemas that model the data the API accepts and returns. The most detailed are BTBExportModelParams (58 properties), BTInsertableInfo (40 properties), BTRevisionInfo (39 properties), BTDocumentElementInfo (31 properties). Each schema is shown below with its type and property counts.

BTElementGroup-1458
object
4 properties
BTCompanySummaryInfo
object
15 properties
BTFSValue-1888
object
2 properties 1 required
BTAclInfo
object
13 properties
BTRestoreStrategy
string
BTMergeUpgradeType
string
BTMoveElementParams
object
29 properties
BTMergePreviewInfo
object
8 properties
BTWorkspaceInfo
object
20 properties
BTDocumentSearchParams
object
11 properties
BTDefaultUnitsInfo
object
2 properties
BTVersionOrWorkspaceParams
object
13 properties
GBTElementType
string
BTOldPermission
string
BTAclEntryInfo
object
21 properties
BTUserBasicSummaryInfo
object
1 property 1 required
GBTMeshState
string
BTRestoreFromHistoryInfo
object
1 property
BTESResultsFilter
string
Search result when
BTGroupOrElementReference-2205
object
List of folders or elements in this group (folder).
2 properties
BTRevisionApproverInfo
object
The users who approved the release package that created this revision.
3 properties
BTWorkspaceProtectionRuleOptions
string
BTUserState
string
BTDocumentContentsInfo
object
2 properties
BTCopyDocumentParams
object
Options for the new copied document.
7 properties
BTDocumentElementCreationDescriptor
object
List of element IDs to include in the document.
2 properties
BTPendingUpgradeInfo
object
2 properties
BTInsertableInfo
object
Array of items in the current page.
40 properties
BTAclParams
object
7 properties
BTUserDetailSummaryInfo
object
BTInheritedAclInfo
object
12 properties
BTInsertablesListResponse
object
10 properties
BTElementLocationParams
object
The location at which the new element should be inserted.
2 properties
BTESVersionWorkspaceChoice
string
Search result found in
BTGlobalTreeNodeListResponse
object
4 properties
BTBExportModelParams
object
Onshape document export schema
58 properties 2 required
BTLinkToLatestDocumentParams
object
1 property
BTDefaultUnitInfo
object
Specifies which unit should be used for each supported quantity type.
2 properties
BTDocumentHistoryInfo
object
8 properties
BTThumbnailInfo
object
4 properties
BTCopyDocumentInfo
object
6 properties
BTSyncAppElementParams
object
2 properties
BTGlobalTreeNodeInfo
object
23 properties 1 required
BTDocumentParams
object
Parameters for creating and updating documents.
16 properties
BTShareEntryParams
object
7 properties
BTShareParams
object
11 properties
BTThumbnailSizeInfo
object
7 properties
BTDocumentInfo
object
BTMergeUpgradeInfo
object
4 properties
BTZipFileInfo
object
1 property
BTUnitInfo
object
2 properties
BTVersionInfo
object
17 properties
BTVersionOrWorkspaceMergeInfo
object
4 properties
BTApplicationTargetInfo
object
4 properties
BTUserSummaryInfo
object
BTUnchangedElementInfo
object
3 properties
BTRevertUnchangedElementParams
object
3 properties
BTAppElementChangeParams
object
3 properties 1 required
BTDocumentMergeInfo
object
5 properties
GlobalPermissionInfo
object
23 properties
BTDocumentElementInfo
object
31 properties
BTGlobalTreeNodeSummaryInfo
object
BTRevertUnchangedParams
object
4 properties
BTElementMergeInfo
object
22 properties
GBTElementBranchStatus
string
BTDocumentLabelInfo
object
BTUnchangedReferenceInfo
object
3 properties
BTMoveElementInfo
object
7 properties
BTRevisionInfo
object
Revision details.
39 properties
GBTBodyType
string
BTObjectState
string
BTMicroversionInfo
object
1 property
BTDocumentNotesParams
object
Parameters for updating document notes.
2 properties
BTBaseInfo
object
4 properties
BTLinkToLatestDocumentInfo
object
1 property
BTMergeStrategy
string
BTOwnerInfo
object
7 properties
BTRestoreInfo
object
2 properties
BTAppElementParams
object
6 properties 1 required

Specification

The full machine-readable OpenAPI contract behind this narrative.

Source

onshape-document-api-openapi.yml Raw ↑

Other APIs Onshape publishes across the network.

Onshape Account API
Onshape Alias API
Onshape APIApplication API
Onshape AppAssociativeData API
Onshape AppElement API
Onshape Assembly API
Onshape Billing API
Onshape BlobElement API
Onshape Comment API
Onshape Company API
Onshape Drawing API
Onshape Element API
Where this information came from

This is an independent, third-party profile of Onshape Document API, published by API Evangelist. We do not operate, host, resell, or support these APIs, and we are not affiliated with or endorsed by the company unless stated above. Everything here is built from publicly available information — the company's own site, developer portal, documentation, public repositories, and the specifications it publishes for public use. Nothing is obtained by breaching a system, defeating an access control, or using credentials.

The Kin Score and Agent Readiness rating are independently calculated assessments of a company's public API artifacts, scored against a published rubric. They are not certifications, endorsements, security assessments, or audits.

Corrections, re-scores, and removal are free — no partnership or purchase required, and you do not need to justify the request. A removed company is recorded as unrated, never scored zero for having asked. Acknowledgement within one business day; removal within two.

info@apievangelist.com · Read the full data-sourcing policy →
On a security or compliance team? Put security in the subject line and you will get a person, not a form — we will tell you exactly which public URLs this profile was built from.