Printago API
PATCH /v1/custom-metadata/{entityType}

Merge custom field values into many records

The merge above across many records of one type in one call. Each item carries its own fields, so a table of edits lands in a single request rather than one per row; stamping one value across a selection is the same call with the same fields repeated on every item. The batch is all-or-nothing: it runs in one transaction, and an unknown id rejects the whole call with nothing written. Up to 200 items per call.

Requires: printer.editpart.editsku.editorder.editmaterial.editmaterial.instance.editjob.edit.allbuild.editprofile.editmaintenance.edit

Path Parameters

entityType required
any

Request Body

BatchCustomMetadataValuesRequest
itemsrequired
object[]
The records to write, each with its own custom fields. Up to 200 per call; an id may appear once. Every record must exist, or the whole call is rejected and nothing is written.
customMetadatarequired
Record<string, any>
The custom fields to write. Values are strings, numbers or booleans; a `null` clears the field.
entityIdrequired
string
The id of the record, of the type named in the path.

Example Request

application/json
{
  "items": [
    {
      "entityId": "string",
      "customMetadata": {}
    }
  ]
}

Response Schema

BatchCustomMetadataValuesResponse
entityTyperequired
any
moderequired
any
Which rule the write followed.
updatedrequired
object[]
Every record written, in the order submitted, each with its custom fields as they stand after the write.
customMetadatarequired
Record<string, any>
entityIdrequired
string

Example Response

200 OK — application/json
{
  "updated": [
    {
      "entityId": "string",
      "customMetadata": {}
    }
  ]
}