Early access: these pages are being written and reviewed. Facts in the header boxes come straight from the product.
Submit a public form
POST
/api/v1/forms/public/{token}/submit
const url = 'https://api.pitch2sale.com/api/v1/forms/public/example/submit';const options = { method: 'POST', headers: {'Content-Type': 'application/json'}, body: '{"data":{"additionalProperty":"example"},"recaptcha_token":"example"}'};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request POST \ --url https://api.pitch2sale.com/api/v1/forms/public/example/submit \ --header 'Content-Type: application/json' \ --data '{ "data": { "additionalProperty": "example" }, "recaptcha_token": "example" }'Unauthenticated. Creates or updates a lead and contact (deduplicated per the form’s settings), applies assignment rules and emits form.submitted. Verifies reCAPTCHA when enabled.
Parameters
Section titled “Parameters”Path Parameters
Section titled “Path Parameters”token
required
string
Request Bodyrequired
Section titled “Request Bodyrequired”Media typeapplication/json
object
data
required
object
key
additional properties
recaptcha_token
string
Examplegenerated
{ "data": { "additionalProperty": "example" }, "recaptcha_token": "example"}Responses
Section titled “Responses”The lead the submission landed on
Media typeapplication/json
object
lead_id
required
string
contact_id
required
string | null
message
required
string
key
additional properties
any
Examplegenerated
{ "lead_id": "example", "contact_id": "example", "message": "example"}Validation failed
Media typeapplication/json
object
error
required
string
code
string
message
string
details
Array<object>
object
field
required
string
message
required
string
code
required
string
Examplegenerated
{ "error": "example", "code": "example", "message": "example", "details": [ { "field": "example", "message": "example", "code": "example" } ]}Rate limit exceeded
Media typeapplication/json
object
error
required
string
code
string
message
string
details
Array<object>
object
field
required
string
message
required
string
code
required
string
Examplegenerated
{ "error": "example", "code": "example", "message": "example", "details": [ { "field": "example", "message": "example", "code": "example" } ]}