POST /public/forms/{slug}/submit
Submit final do form (Fase 184a-async)
- Access: Public
- Service:
https://api-forms.axuz.net
Accepted authentication
No authentication (public route, or protected by link/signature).
Pipeline: 1. Rate-limit (10/min/IP), honeypot, validate schema — síncrono. 2. Redis stream backup forms:submissions:incoming — best-effort. 3. INSERT ou promote (__presubmit_id) em form_submissions com captcha_status='pending'|'skipped'. 4. 201 imediato (~5-20ms). 5. Goroutine bg: verify captcha → triggers (email/webhook/calendar/…).
Trade-off: spammer recebe 201 (bots não param em 4xx). is_spam marcado no DB; nenhum trigger é notificado; dashboard filtra.
Aceita application/json OU application/x-www-form-urlencoded (submit no-JS do /render). Fields especiais no body: recaptcha_token, turnstile_token, __presubmit_id, axuz_hp.
Parameters
| Name | In | Type | Required | Description |
|---|---|---|---|---|
slug | path | string | yes | Slug URL-safe do form ( |
Request body
application/json · Required
| Name | Type | Required | Description |
|---|---|---|---|
(corpo) | object | no | Chaves livres representam os |
{}Responses
201
Submission aceita
| Name | Type | Required | Description |
|---|---|---|---|
id | string<uuid> | yes | |
thank_you | string | no | |
redirect | string | null | no | |
created_at | string<date-time> | yes |
400
Parâmetro/body inválido
| Name | Type | Required | Description |
|---|---|---|---|
error | string | yes |
404
Recurso não encontrado
| Name | Type | Required | Description |
|---|---|---|---|
error | string | yes |
422
Falha de validação de schema
| Name | Type | Required | Description |
|---|---|---|---|
error | string | yes | |
fields | object | yes | Mapa |
429
Rate limit excedido (10/min/IP no /submit e /pre-submit)
| Name | Type | Required | Description |
|---|---|---|---|
error | string | yes |
500
Erro inesperado
| Name | Type | Required | Description |
|---|---|---|---|
error | string | yes |
Examples
"Try it" is turned off in this reference. Use the examples with your test credential.
curl
curl -sS -X POST 'https://api-forms.axuz.net/public/forms/SLUG/submit' \
-H "Content-Type: application/json" \
-d '{}'Node.js
const res = await fetch("https://api-forms.axuz.net/public/forms/SLUG/submit", {
method: 'POST',
headers: {
'Content-Type': 'application/json',
},
body: JSON.stringify({}),
});
if (!res.ok) throw new Error(`HTTP ${res.status}: ${await res.text()}`);
console.log(await res.json());Python
import os
import requests
res = requests.request(
"POST",
"https://api-forms.axuz.net/public/forms/SLUG/submit",
json={},
timeout=30,
)
res.raise_for_status()
print(res.json())