from samplehc import SampleHealthcare
client = SampleHealthcare(
api_key="My API Key",
)
response = client.v2.documents.templates.generate_document_async(
slug="slug",
type="document",
)
print(response.async_result_id)
{
"asyncResultId": "<string>"
}
Initiates an asynchronous process to generate a document from a template slug and relevant data (documentBody for document, variables for PDF). Returns an ID for tracking.
from samplehc import SampleHealthcare
client = SampleHealthcare(
api_key="My API Key",
)
response = client.v2.documents.templates.generate_document_async(
slug="slug",
type="document",
)
print(response.async_result_id)
{
"asyncResultId": "<string>"
}
The request body, discriminated by the 'type' field ('document' or 'pdf').
Default Response
The response is of type object
.