Export profile

List all export profiles

Get the list of all export profiles that belong to the current user's group.

API Request

GET https://api.bespokify.com/v2/exportProfiles

Request parameters

Parameter Type Required Description
search string no The text used to search for export names
orderBy string no The field to order exports by. Possible values: updatedAt, name. Default: createdAt
sort string no The order to sort exports in. Possible values: asc, desc. Default: desc
fileType string no Used to filter exports by fileType. Default values: dxf, pdf, plt

Example response

[
  {
    "id": "10ba038e-48da-487b-96e8-8d3b99b6d18a",
    "name": "profile 1",
    "fileType": "pdf",
    "createdAt": "2018-10-17T09:52:05.399Z",
    "createdBy": "lorem",
    "updatedAt": "2018-10-17T09:52:05.399Z",
    "updatedBy": "lorem"
  }
]

Create export profile

API Request

POST https://api.bespokify.com/v2/exportProfiles

Request parameters

Parameter Type Required Description
name string yes The export profile's name
fileType string yes The export profile's fileType. Possible values: dxf, pdf, plt
config object no There will be advanced options for different fileTypes. See: Export config
nesting object no The nesting config. See: Nesting config

Example request

{
  "name": "profile 1",
  "fileType": "pdf"
}

Example response

{
  "id": "10ba038e-48da-487b-96e8-8d3b99b6d18a",
  "name": "profile 1",
  "fileType": "pdf",
  "createdAt": "2018-10-17T09:52:05.399Z",
  "createdBy": "lorem",
  "updatedAt": "2018-10-17T09:52:05.399Z",
  "updatedBy": "lorem",
  "config": {
    "singleInstance": false,
    "materialGroup": true,
    "singleFile": true,
    "width": 84.1,
    "height": 118.9,
    "leftMargin": 3,
    "topMargin": 3,
    "rightMargin": 3,
    "bottomMargin": 3,
    "glueMargin": false,
    "orientation": "Portrait"
  },
  "nesting": {
    "sheetWidth": 140,
    "preNestRotation": 0,
    "partRotation": null,
    "partMargin": 1,
    "sheetLength": 3000,
    "sheetEdgeMargin": 1
  }
}

Get single export profile

API Request

GET https://api.bespokify.com/v2/exportProfiles/{id}

Request parameters

Parameter Type Required Description
id string yes The ID of the export profile to retrieve.

Example response

{
  "id": "10ba038e-48da-487b-96e8-8d3b99b6d18a",
  "name": "profile 1",
  "fileType": "pdf",
  "createdAt": "2018-10-17T09:52:05.399Z",
  "createdBy": "lorem",
  "updatedAt": "2018-10-17T09:52:05.399Z",
  "updatedBy": "lorem",
  "config": {
    "singleInstance": false,
    "materialGroup": true,
    "singleFile": true,
    "width": 84.1,
    "height": 118.9,
    "leftMargin": 3,
    "topMargin": 3,
    "rightMargin": 3,
    "bottomMargin": 3,
    "glueMargin": false,
    "orientation": "Portrait"
  },
  "nesting": {
    "sheetWidth": 140,
    "preNestRotation": 0,
    "partRotation": null,
    "partMargin": 1,
    "sheetLength": 3000,
    "sheetEdgeMargin": 1
  }
}

Update export profile

API Request

PATCH https://api.bespokify.com/v2/exportProfiles/{id}

Request parameters

Parameter Type Required Description
name string no The export profile's new name
fileType string no The export profile's new fileType. Possible values: dxf, pdf, plt
config object no The export profile's new config. There will be advanced options for different fileTypes. See: Export config
nesting object no The export profile's new nesting config. Details: Nesting config

Example request

{
  "name": "profile 1",
  "fileType": "pdf",
  "config": {
    "singleInstance": true,
    "materialGroup": true,
    "singleFile": true,
    "width": 100,
    "height": 120
  },
  "nesting": {
    "sheetWidth": 150,
    "preNestRotation": 0,
    "partRotation": null,
    "partMargin": 1,
    "sheetLength": 3000,
    "sheetEdgeMargin": 1
  }
}

Example response

{
  "id": "10ba038e-48da-487b-96e8-8d3b99b6d18a",
  "name": "profile 1",
  "fileType": "pdf",
  "createdAt": "2018-10-17T09:52:05.399Z",
  "createdBy": "lorem",
  "updatedAt": "2018-10-17T09:52:05.399Z",
  "updatedBy": "lorem",
  "config": {
    "singleInstance": true,
    "materialGroup": true,
    "singleFile": true,
    "width": 100,
    "height": 120,
    "leftMargin": 3,
    "topMargin": 3,
    "rightMargin": 3,
    "bottomMargin": 3,
    "glueMargin": false,
    "orientation": "Portrait"
  },
  "nesting": {
    "sheetWidth": 150,
    "preNestRotation": 0,
    "partRotation": null,
    "partMargin": 1,
    "sheetLength": 3000,
    "sheetEdgeMargin": 1
  }
}

Delete export profile

API Request

DELETE https://api.bespokify.com/v2/exportProfiles/{id}

Request parameters

Parameter Type Required Description
id string yes The ID of the export profile to delete

Response status codes

Code Meaning
204 No Content The export profile was deleted successfully
404 Not Found An export profile with the provided ID could not be found