Optima REST API icon

Optima REST API

Interact with Comarch Optima ERP via REST API

Print → Print Document

AI-generated

Summary

Sends a print request to Optima and returns the generated PDF as binary data. Choose the required print format, and optionally filter the documents and pass named values to the print template.

Inputs

  • Format ID (required) — Optima print format ID; defaults to 1.
  • SQL Filter — Optional SQL expression used to select documents, such as TrN_TrNID = 123.
  • Dynamic Parameters — Optional list of name/value pairs passed to the print template. Repeated names overwrite earlier values.

Output shape

One item containing PDF binary data and JSON metadata.

The binary property is data, with MIME type application/pdf and a generated filename such as document_<timestamp>.pdf. JSON includes success: true and fileName. The request is made once per input item; errors are thrown unless Continue On Fail is enabled.

Links

Discussion