API Documentation

Common API Patterns

APIResponse<T>

Standard response format for all API endpoints. We always return HTTP 200 for business logic responses, using error_code for business logic errors. HTTP error codes (4xx, 5xx) are only used for unexpected errors or server issues.

PropertyTypeDescriptionRequiredDefault
successbooleanWhether the operation was successfulYes-
dataT | nullResponse data of generic type TNo-
messagestringHuman-readable message for both success and error casesNo-
error_codeErrorCodeBusiness logic error code, only present for errorsNo-

ErrorCode

Enumeration of possible business logic error codes

PropertyTypeDescriptionRequiredDefault
SUCCESSstringOperation completed successfullyYes-
NOT_FOUNDstringRequested resource not foundYes-
USER_NOT_FOUNDstringUser not foundYes-
INVALID_INPUTstringInvalid input dataYes-
AUTHENTICATION_FAILEDstringAuthentication failedYes-
UNAUTHORIZED_ACCESSstringUser not authorized to access resourceYes-
FORBIDDEN_ACTIONstringAction not allowedYes-
VALIDATION_ERRORstringInput validation failedYes-
MISSING_REQUIRED_FIELDSstringRequired fields are missingYes-
RESOURCE_NOT_FOUNDstringRequested resource not foundYes-
RESOURCE_ALREADY_EXISTSstringResource already existsYes-
SUBSCRIPTION_EXPIREDstringUser subscription has expiredYes-
PAYMENT_FAILEDstringPayment operation failedYes-
INTEGRATION_ERRORstringError with external integrationYes-
SERVICE_UNAVAILABLEstringService is currently unavailableYes-
INTERNAL_SERVER_ERRORstringInternal server error occurredYes-
OPERATION_FAILEDstringOperation failed to completeYes-
INVALID_FILE_TYPEstringFile type not supportedYes-

Successful Response

{
    "success": true,
    "data": {
        "id": "01HQ2V...",
        "title": "Contact Form"
    },
    "message": "Form created successfully"
}

Error Response

{
    "success": false,
    "message": "Form not found",
    "error_code": "RESOURCE_NOT_FOUND"
}

Forms API

GET /forms

Get all forms for the current user

Parameters

NameTypeDescriptionRequired
exclude_archived_trashed_deletedbooleanFilter out archived/trashed/deleted formsYes
favorites_firstbooleanSort favorites firstYes
limitnumberLimit number of resultsNo

Returns

Array of FormAsQueryResult
GET /forms/{form_id}

Get a specific form by ID

Parameters

NameTypeDescriptionRequired
form_idstringForm IDYes

Returns

FormAsQueryResult
POST /forms

Create a new form

Parameters

NameTypeDescriptionRequired
formFormCreateForm creation dataYes

Returns

FormAsQueryResult
PUT /forms/{form_id}

Update an existing form

Parameters

NameTypeDescriptionRequired
form_idstringForm IDYes
formFormUpdateForm update dataYes

Returns

FormAsQueryResult
DELETE /forms/{form_id}

Delete a form

Parameters

NameTypeDescriptionRequired
form_idstringForm IDYes

Returns

APIResponse
POST /forms/{form_id}/submit

Submit form response

Parameters

NameTypeDescriptionRequired
form_idstringForm IDYes
filesList[UploadFile]Uploaded filesNo
form_datastringJSON encoded form dataYes
browser_timezonestringBrowser timezoneNo
browser_timestringBrowser timeNo

Returns

APIResponse with submission data
GET /forms/{form_id}/responses

Get all responses for a form

Parameters

NameTypeDescriptionRequired
form_idstringForm IDYes

Returns

Array of FormResponseModel
GET /forms/{form_id}/responses/{response_id}

Get a specific form response

Parameters

NameTypeDescriptionRequired
form_idstringForm IDYes
response_idstringResponse IDYes

Returns

FormResponseModel
GET /forms/{form_id}/responses/{response_id}/files/{filename}

Get file data from a form response

Parameters

NameTypeDescriptionRequired
form_idstringForm IDYes
response_idstringResponse IDYes
filenamestringName of the fileYes

Returns

Base64 encoded file data
GET /forms/{form_id}/responses/{response_id}/files-as-link/{filename}/{download_filename}

Get file as downloadable link or display in browser

Parameters

NameTypeDescriptionRequired
form_idstringForm IDYes
response_idstringResponse IDYes
filenamestringInternal filenameYes
download_filenamestringFilename for downloadYes
force_downloadbooleanForce download instead of displayNo

Returns

File stream response
GET /forms/{form_id}/export/csv

Export form responses as CSV

Parameters

NameTypeDescriptionRequired
form_idstringForm IDYes

Returns

CSV file stream
GET /forms/{form_id}/export/xlsx

Export form responses as Excel file

Parameters

NameTypeDescriptionRequired
form_idstringForm IDYes

Returns

XLSX file stream
GET /forms/{form_id}/responses/{response_id}/pdf

Generate PDF for a specific form response

Parameters

NameTypeDescriptionRequired
form_idstringForm IDYes
response_idstringResponse IDYes

Returns

PDF file stream

Zapier Integration API

GET /generate_code

Generate OAuth code for Zapier integration

Parameters

NameTypeDescriptionRequired
client_idstringOAuth client IDYes
user_idstringUser IDYes

Returns

APIResponse with OAuth code
POST /verify_code

Verify OAuth code and return access token

Parameters

NameTypeDescriptionRequired
codestringOAuth codeYes
client_idstringOAuth client IDYes
client_secretstringOAuth client secretYes
grant_typestringOAuth grant typeYes
redirect_uristringOAuth redirect URIYes
providerstringOAuth providerYes

Returns

JSON response with access token and email
GET /test

Test Zapier OAuth authentication

Parameters

NameTypeDescriptionRequired
AuthorizationstringBearer tokenYes

Returns

Test success response
POST /webhook/subscription

Subscribe to form webhooks

Parameters

NameTypeDescriptionRequired
hookUrlstringWebhook URLYes
form_idstringForm IDYes

Returns

Webhook subscription details with ID
DELETE /webhook/subscription

Delete webhook subscription

Parameters

NameTypeDescriptionRequired
hookUrlstringWebhook URLYes
form_idstringForm ID (optional)No

Returns

Success response
GET /webhook/subscription

Get example data for form webhooks

Parameters

NameTypeDescriptionRequired
form_idstringForm IDYes

Returns

Array of example form submission data
GET /forms

Get all forms for the authenticated Zapier user

Parameters

NameTypeDescriptionRequired
AuthorizationstringBearer tokenYes

Returns

JSON response with array of form objects containing id and title

Workflow API

POST /workflows

Create a new workflow

Parameters

NameTypeDescriptionRequired
form_idstringForm IDYes
connection_idstringConnection IDYes
configdictWorkflow configurationNo

Returns

APIResponse with workflow details

Data Models

FormElement

Represents a form element/field

PropertyTypeDescriptionRequiredDefault
idstringUnique identifierYes-
typestringElement type (text, email, number, phone, etc.)Yes-
labelstringDisplay labelNo-
column_namestringDatabase column nameNo-
valueanyElement valueYes-
requiredbooleanWhether field is requiredYesfalse
displayWidthstringDisplay width of elementYes100%
hiddenbooleanWhether element is hiddenYesfalse

Page

Represents a single page in a form

PropertyTypeDescriptionRequiredDefault
idstringUnique identifier (ULID)Yes-
namestringPage nameYes-
typestringPage type (cover, form, ending)Yesform
elementsArray<FormElement>List of form elementsYes-
settingsobjectPage-specific settingsYes-

FormAsQueryResult

Form data with additional query information

PropertyTypeDescriptionRequiredDefault
idstringForm IDYes-
titlestringForm titleYes-
user_idstringOwner's user IDYes-
folder_idstringParent folder IDNo-
created_atdatetimeCreation timestampYes-
updated_atdatetimeLast update timestampNo-
deleted_atdatetimeDeletion timestampNo-
moved_atdatetimeLast move timestampNo-
pagesArray<Page>Form pagesYes-
settingsFormSettingsForm settingsYes-
stylesFormStylesForm stylesYes-
favoritebooleanWhether form is favoritedYesfalse
publishedbooleanWhether form is publishedYesfalse
response_countnumberNumber of form responsesNo-
form_connectionsstringConnected integrationsNo-

FormResponseModel

Form submission response data

PropertyTypeDescriptionRequiredDefault
idstringResponse IDYes-
form_idstringAssociated form IDYes-
response_dataArray<object>Form submission dataYes-
submitted_atstringSubmission timestampYes-

FormSettings

Functional settings for the form

PropertyTypeDescriptionRequiredDefault
submitButtonTextstringSubmit button textYesSubmit
previousButtonTextstringPrevious button textYesPrevious
nextButtonTextstringNext button textYesNext

FormStyles

Visual styles for the form

PropertyTypeDescriptionRequiredDefault
pageBackgroundColorstringPage background colorYes#ffffff
formBackgroundColorstringForm background colorYes#FFFAF0
defaultFontColorstringDefault text colorYes#625b5b
formMaxWidthnumberMaximum form width in pixelsYes720