All URIs are relative to http://localhost
Method | HTTP request | Description |
---|---|---|
add_document_generate | POST /documents/{documentId}/generate | Add Document Generate |
AddDocumentGenerateResponse add_document_generate(document_id, add_document_generate_request, site_id=site_id)
Add Document Generate
Generates a new document using a specified template file and data sources. This operation allows users to merge data from multiple documents into a template to create a new document in the desired output format (e.g., DOCX). By Default data source must include a data
object, which contains key-value pairs that will be merged into the template. The value can be any valid JSON object. { "data":{}}. The data path can be adjusted via the "dataRoot" field. ; available as an Add-On Module
import formkiq_client
from formkiq_client.models.add_document_generate_request import AddDocumentGenerateRequest
from formkiq_client.models.add_document_generate_response import AddDocumentGenerateResponse
from formkiq_client.rest import ApiException
from pprint import pprint
# Defining the host is optional and defaults to http://localhost
# See configuration.py for a list of all supported configuration parameters.
configuration = formkiq_client.Configuration(
host = "http://localhost"
)
# The client must configure the authentication and authorization parameters
# in accordance with the API server security policy.
# Examples for each auth method are provided below, use the example that
# satisfies your auth use case.
# Enter a context with an instance of the API client
with formkiq_client.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = formkiq_client.DocumentGenerationApi(api_client)
document_id = 'document_id_example' # str | Document Identifier
add_document_generate_request = formkiq_client.AddDocumentGenerateRequest() # AddDocumentGenerateRequest |
site_id = 'site_id_example' # str | Site Identifier (optional)
try:
# Add Document Generate
api_response = api_instance.add_document_generate(document_id, add_document_generate_request, site_id=site_id)
print("The response of DocumentGenerationApi->add_document_generate:\n")
pprint(api_response)
except Exception as e:
print("Exception when calling DocumentGenerationApi->add_document_generate: %s\n" % e)
Name | Type | Description | Notes |
---|---|---|---|
document_id | str | Document Identifier | |
add_document_generate_request | AddDocumentGenerateRequest | ||
site_id | str | Site Identifier | [optional] |
No authorization required
- Content-Type: application/json
- Accept: application/json
Status code | Description | Response headers |
---|---|---|
201 | 201 CREATED | * Access-Control-Allow-Origin - * Access-Control-Allow-Methods - * Access-Control-Allow-Headers - |
400 | 400 OK | - |
[Back to top] [Back to API list] [Back to Model list] [Back to README]