New to Corsair? See API access, authentication, and error handling.
Account
getInfo
account.getInfo
Read the account name, credit usage and template count against their limits
Risk: read
Editor
createSession
editor.createSession
Create a signed URL that lets its bearer edit a template in the embedded designer; the URL is a credential
Risk: write
The returned URL is a signed token that lets its bearer edit the template, so treat it as a credential and deactivate it when done.
Output
deactivateSession
editor.deactivateSession
Revoke an editor session so its URL stops working
Risk: write
Output
addText
pdf.addText
Draw text such as page numbers or headers on chosen pages of a PDF and return a new file
Risk: write
textSettings full type
textSettings full type
anchors full type
anchors full type
addWatermark
pdf.addWatermark
Stamp a text watermark on every page of a PDF and return a new file
Risk: write
Output
anchors full type
anchors full type
create
pdf.create
Generate a PDF from a template and JSON data, synchronously; consumes one credit per PDF
Risk: write
A synchronous call can take up to 100 seconds, so the plugin waits 120 seconds before timing out. Each call spends one credit.
Output
anchors full type
anchors full type
createAsync
pdf.createAsync
Queue a PDF generation and return at once with a transaction reference, delivering the file to a webhook URL; consumes one credit per PDF
Risk: write
CraftMyPDF calls
webhook_url with a GET once the file is ready, appending file (the PDF URL), transaction_ref, status, message and details as query parameters. The webhook is the only place the file URL arrives. transactions.list shows the job and its status, but no file URL, so pass webhook_url if you need the file.
Output
createImage
pdf.createImage
Render a template to a JPEG or PNG image instead of a PDF; consumes one credit per image
Risk: write
Output
anchors full type
anchors full type
createMerge
pdf.createMerge
Render several templates, each with its own data, into one combined PDF; consumes one credit per template
Risk: write
templates full type
templates full type
anchors full type
anchors full type
createParallel
pdf.createParallel
Generate a batch of PDFs in one request, each from its own template data, optionally merging them into a single file; consumes one credit per PDF
Risk: write
Each request entry carries its own template data. Set
merge to also receive one combined PDF.
requests full type
requests full type
results full type
results full type
merge_result full type
merge_result full type
getInfo
pdf.getInfo
Read the page count and document properties of a PDF at a URL
Risk: read
Output
merge
pdf.merge
Merge several PDFs fetched by URL into one file
Risk: write
Output
anchors full type
anchors full type
updateFields
pdf.updateFields
Fill the form fields of a PDF and optionally make them read-only, returning a new file
Risk: write
CraftMyPDF answers
success even when a field does not exist in the document and reports the failure only in field_statuses. The plugin also returns the failures as failed_fields, so check it is empty before treating the form as filled.
fields full type
fields full type
field_statuses full type
field_statuses full type
failed_fields full type
failed_fields full type
Templates
createFrom
templates.createFrom
Create a new template by copying an existing one
Risk: write
Output
delete
templates.delete
Permanently delete a template
Risk: destructive · Irreversible
Output
get
templates.get
Read one template, including its body and sample JSON data
Risk: read
Output
list
templates.list
List the templates on the account with the ids generation calls need
Risk: read
CraftMyPDF reports no total, so
next_offset is present only when the page came back full. Pass it as offset to read the next page.
Output
templates full type
templates full type
listVersions
templates.listVersions
List the saved versions of a template
Risk: read
Output
versions full type
versions full type
queryUsage
templates.queryUsage
Report how many PDFs and credits the given templates used in a date range
Risk: read
Output
results full type
results full type
retainVersions
templates.retainVersions
Mark template versions to protect from automatic cleanup, or release the ones already kept; a released version can be cleaned up later
Risk: write
Output
versions full type
versions full type
transfer
templates.transfer
Move a template to another team, after which this account no longer owns it
Risk: write
Output
update
templates.update
Change a template’s name, sample JSON data or body; the body is what the template renders
Risk: write
Output
Transactions
list
transactions.list
List past generations with their status, credit cost and file size
Risk: read
next_offset is present only when the page came back full.
Output
transactions full type
transactions full type