Actions12
- File Actions
- Template Actions
- Job Actions
Overview
This node interacts with the Json2Doc API to create documents based on JSON configurations. Specifically, the 'Create Document' operation under the 'Job' resource allows users to submit a document configuration in JSON format to generate a document. Users can optionally wait for the job to complete and automatically download the resulting document as binary data. This is useful for automating document generation workflows, such as creating reports, contracts, or invoices from structured data.
Use Case Examples
- Generate a PDF report by providing a JSON configuration describing the report layout and content.
- Automatically create a contract document from JSON data and download the completed file for further processing or storage.
Properties
| Name | Meaning |
|---|---|
| Document Configuration | JSON configuration for the document, defining its structure and content according to Json2Doc API specifications. |
| Wait for Completion | Boolean flag to determine whether the node should wait for the document generation job to complete and then download the result automatically. |
| Download Binary Property | The name of the binary property where the downloaded document file will be stored if waiting for completion is enabled. |
Output
Binary
Contains the generated document file when 'Wait for Completion' is enabled, stored under the specified binary property name.
JSON
jobId- Identifier of the created job.status- Current status of the job (e.g., PENDING, COMPLETED, FAILED).outputFileId- Identifier of the generated document file (available when job is completed).errorMessage- Error message if the job failed or was cancelled.
Dependencies
- Requires an API key credential for Json2Doc API authentication.
Troubleshooting
- Job may fail or be cancelled; error messages from the API will be provided in the output to help diagnose issues.
- If 'Wait for Completion' is enabled, the node waits up to 20 seconds (10 attempts with 2-second intervals) for job completion. If the job does not complete in this time, a timeout error is thrown.
- Ensure the JSON document configuration is valid and correctly formatted to avoid validation or job creation errors.
Links
- Json2Doc API Documentation - Official API documentation for Json2Doc, including details on document configuration JSON format and job management endpoints.