Queries
drawing
Retrieves an object representing a drawing.
Drawings contain 2D projected views of designs.
Template for Query:
query GetDrawing($drawingId: ID!) {
drawing(drawingId: $drawingId) {
# Drawing Fields
}
}
Template for Query Variables:
{
"drawingId" : "<SOME-ID-TYPE-SCALAR-VALUE>"
}
Arguments
drawingId* ID! non-null | The ID of the drawing to fetch. |
* Required
Possible Returns
Value Type | Description |
---|---|
Drawing | Represents a 2D drawing that contains projected views of a design. |
Examples
Example 1
Retrieves a drawing along with its latest version and corresponding component version and drawing item version
Query:
query GetDrawing($drawingId: ID!) {
drawing(drawingId: $drawingId) {
id
name
tipVersion {
id
name
componentVersion {
id
name
}
drawingItemVersion {
id
name
}
}
}
}
Show More
Query Variables:
{
"drawingId": "ZHJhd35WQVZNUW1sYmxrZDBtaXJwU0NYMHJ0X0wyQ344SkNrWE1nMDkxNDV2bXpvdWRXRmF2X2FnYQ"
}
Response:
{
"data": {
"drawing": {
"id": "ZHJhd35WQVZNUW1sYmxrZDBtaXJwU0NYMHJ0X0wyQ344SkNrWE1nMDkxNDV2bXpvdWRXRmF2X2FnYQ",
"name": "3D_Arm_Scan Drawing",
"tipVersion": {
"id": "ZHJhd35WQVZNUW1sYmxrZDBtaXJwU0NYMHJ0X0wyQ344SkNrWE1nMDkxNDV2bXpvdWRXRmF2X2FnYX44a2JrNE5pcTY2bGZ6UXRwUk9aTjlw",
"name": "3D_Arm_Scan Drawing",
"componentVersion": {
"id": "Y29tcH5WQVZNUW1sYmxrZDBtaXJwU0NYMHJ0X0wyQ34zMlBTQ2daMXJLY2V3SHlCN1dkbEZyX2FnYX53RnlaU1BGSmNQY2l3NDdFeTBIemJX",
"name": "3D_Arm_Scan"
},
"drawingItemVersion": {
"id": "urn:adsk.wipstg:fs.file:vf.xg_7JjcHRvqHQuSuCBiykQ?version=1",
"name": "3D_Arm_Scan Drawing"
}
}
}
}
}
Show More
Example 2
Retrieves a drawing along with the lifecycle, revision, itemNumber, itemURN and itemURL.
Query:
query GetManageExtensionDetails($drawingId: ID!) {
drawing(drawingId: $drawingId) {
id
name
manage {
itemNumber
itemURL
itemURN
lifeCycle
revision
}
}
}
Show More
Query Variables:
{
"drawingId": "ZHJhd35WQVZNUW1sYmxrZDBtaXJwU0NYMHJ0X0wyQ344SkNrWE1nMDkxNDV2bXpvdWRXRmF2X2FnYQ"
}
Response:
{
"data": {
"drawing": {
"id": "ZHJhd35WQVZNUW1sYmxrZDBtaXJwU0NYMHJ0X0wyQ344SkNrWE1nMDkxNDV2bXpvdWRXRmF2X2FnYQ",
"name": "3D_Arm_Scan Drawing",
"manage": {
"itemNumber": null,
"itemURL": null,
"itemURN": null,
"lifeCycle": null,
"revision": "w"
}
}
}
}
Show More
Example 3
Retrieves Properties associated with the Drawing.
Query:
query GetDrawingProperties($drawingId: ID!) {
drawing(drawingId: $drawingId) {
id
name
customProperties {
results {
value
displayValue
definition {
id
name
specification
isHidden
isReadOnly
isArchived
description
propertyBehavior
units {
id
name
}
}
}
}
}
}
Show More
Query Variables:
{
"drawingId": "ZHJhd35WQVZNUW1sYmxrZDBtaXJwU0NYMHJ0X0wyQ35UZm85djhzUmtib1IyaGpKemhpVHlqX2FnYQ"
}
Response:
{
"data": {
"drawing": {
"id": "ZHJhd35WQVZNUW1sYmxrZDBtaXJwU0NYMHJ0X0wyQ35UZm85djhzUmtib1IyaGpKemhpVHlqX2FnYQ",
"name": "Connector Joint Drawing",
"customProperties": {
"results": [
{
"value": "10D123E001",
"displayValue": "10D123E001",
"definition": {
"id": "cHJvcGRlZn5DZlhvYUM0SzUzU1R3YjZUbklyWFhaVEFJRWRkRzlBcn5DZlhvYUM0SzUzU1R3YjZUbklyWFhaVEFJRWRkRzlBcn5wcm9wX2RlZl9jb2xfMTcwNzM3NjE0MTM1N35wYXJhbWV0ZXJzLkNmWG9hQzRLNTNTVHdiNlRuSXJYWFpUQUlFZGRHOUFyOmJiN2JlZDVkOTFhMTQxY2I5YmY0Nzc4OTA0MTMwYWVmLTEuMC4w",
"name": "ERP ID",
"specification": "STRING",
"isHidden": false,
"isReadOnly": false,
"isArchived": false,
"description": "description",
"propertyBehavior": "TIMELESS",
"units": null
}
}
]
}
}
}
}
Show More