diff --git a/api-reference/forms/create-a-new-form.mdx b/api-reference/forms/create-a-new-form.mdx
new file mode 100644
index 0000000..5aa9a8a
--- /dev/null
+++ b/api-reference/forms/create-a-new-form.mdx
@@ -0,0 +1,3 @@
+---
+openapi: post /forms
+---
\ No newline at end of file
diff --git a/api-reference/forms/create-multiple-forms.mdx b/api-reference/forms/create-multiple-forms.mdx
new file mode 100644
index 0000000..ad326a9
--- /dev/null
+++ b/api-reference/forms/create-multiple-forms.mdx
@@ -0,0 +1,3 @@
+---
+openapi: post /forms/bulk
+---
\ No newline at end of file
diff --git a/api-reference/forms/delete-a-form.mdx b/api-reference/forms/delete-a-form.mdx
new file mode 100644
index 0000000..51b2279
--- /dev/null
+++ b/api-reference/forms/delete-a-form.mdx
@@ -0,0 +1,3 @@
+---
+openapi: delete /forms/{formId}
+---
\ No newline at end of file
diff --git a/api-reference/forms/delete-multiple-forms.mdx b/api-reference/forms/delete-multiple-forms.mdx
new file mode 100644
index 0000000..0456c13
--- /dev/null
+++ b/api-reference/forms/delete-multiple-forms.mdx
@@ -0,0 +1,3 @@
+---
+openapi: delete /forms/bulk
+---
\ No newline at end of file
diff --git a/api-reference/forms/duplicate-a-form.mdx b/api-reference/forms/duplicate-a-form.mdx
new file mode 100644
index 0000000..5653dfc
--- /dev/null
+++ b/api-reference/forms/duplicate-a-form.mdx
@@ -0,0 +1,3 @@
+---
+openapi: post /forms/{formId}/duplicate
+---
\ No newline at end of file
diff --git a/api-reference/forms/get-a-single-form.mdx b/api-reference/forms/get-a-single-form.mdx
new file mode 100644
index 0000000..75cb2c0
--- /dev/null
+++ b/api-reference/forms/get-a-single-form.mdx
@@ -0,0 +1,3 @@
+---
+openapi: get /forms/{formId}
+---
\ No newline at end of file
diff --git a/api-reference/forms/list-all-forms.mdx b/api-reference/forms/list-all-forms.mdx
new file mode 100644
index 0000000..555d9e3
--- /dev/null
+++ b/api-reference/forms/list-all-forms.mdx
@@ -0,0 +1,3 @@
+---
+openapi: get /forms
+---
\ No newline at end of file
diff --git a/api-reference/forms/update-a-form.mdx b/api-reference/forms/update-a-form.mdx
new file mode 100644
index 0000000..a3d35af
--- /dev/null
+++ b/api-reference/forms/update-a-form.mdx
@@ -0,0 +1,3 @@
+---
+openapi: patch /forms/{formId}
+---
\ No newline at end of file
diff --git a/api-reference/forms/update-multiple-forms.mdx b/api-reference/forms/update-multiple-forms.mdx
new file mode 100644
index 0000000..f11671e
--- /dev/null
+++ b/api-reference/forms/update-multiple-forms.mdx
@@ -0,0 +1,3 @@
+---
+openapi: patch /forms/bulk
+---
\ No newline at end of file
diff --git a/api-reference/overview.mdx b/api-reference/overview.mdx
new file mode 100644
index 0000000..e81fc74
--- /dev/null
+++ b/api-reference/overview.mdx
@@ -0,0 +1,114 @@
+---
+title: "API Overview"
+description: "Access your forms and submissions programmatically with the Formbase REST API"
+---
+
+## Introduction
+
+The Formbase API provides programmatic access to your forms and submissions. Use it to build custom integrations, automate workflows, or manage your forms from external applications.
+
+## Base URL
+
+All API requests should be made to:
+
+```
+https://formbase.dev/api/v1
+```
+
+## Authentication
+
+The API uses Bearer token authentication with API keys. Include your API key in the `Authorization` header:
+
+```bash
+curl -X GET "https://formbase.dev/api/v1/forms" \
+ -H "Authorization: Bearer YOUR_API_KEY"
+```
+
+
+ Keep your API keys secure. Don't share them in public repositories or expose them in client-side code.
+
+
+### Creating API Keys
+
+1. Go to your [Dashboard Settings](https://formbase.dev/dashboard/settings/api-keys)
+2. Click "Create Key"
+3. Give your key a descriptive name
+4. Optionally set an expiration date
+5. Copy the key immediately - it won't be shown again
+
+
+
+
+
+
+
+
+
+## Rate Limits
+
+API requests are rate limited to **100 requests per minute** per API key.
+
+Rate limit information is included in the response headers:
+
+| Header | Description |
+| --- | --- |
+| `X-RateLimit-Remaining` | Number of requests remaining in the current window |
+| `X-RateLimit-Reset` | Unix timestamp when the rate limit resets |
+
+When you exceed the rate limit, the API returns a `429 Too Many Requests` response with a `Retry-After` header indicating how many seconds to wait.
+
+## Error Responses
+
+All errors follow a consistent format:
+
+```json
+{
+ "error": {
+ "code": "NOT_FOUND",
+ "message": "Form not found"
+ }
+}
+```
+
+### Common Error Codes
+
+| HTTP Status | Code | Description |
+| --- | --- | --- |
+| 400 | `BAD_REQUEST` | Invalid request parameters |
+| 401 | `UNAUTHORIZED` | Missing or invalid API key |
+| 404 | `NOT_FOUND` | Resource not found |
+| 429 | `TOO_MANY_REQUESTS` | Rate limit exceeded |
+| 500 | `INTERNAL_SERVER_ERROR` | Server error |
+
+## Pagination
+
+List endpoints return paginated results with the following structure:
+
+```json
+{
+ "forms": [...],
+ "pagination": {
+ "page": 1,
+ "perPage": 20,
+ "total": 45,
+ "totalPages": 3
+ }
+}
+```
+
+### Query Parameters
+
+| Parameter | Default | Max | Description |
+| --- | --- | --- | --- |
+| `page` | 1 | - | Page number |
+| `perPage` | 20 | 100 | Items per page |
+
+## OpenAPI Specification
+
+The complete OpenAPI specification is available at:
+
+```
+https://formbase.dev/api/v1/openapi.json
+```
+
+You can use this specification with tools like Postman, Insomnia, or code generators.
diff --git a/api-reference/submissions/delete-a-submission.mdx b/api-reference/submissions/delete-a-submission.mdx
new file mode 100644
index 0000000..df80d1c
--- /dev/null
+++ b/api-reference/submissions/delete-a-submission.mdx
@@ -0,0 +1,3 @@
+---
+openapi: delete /forms/{formId}/submissions/{submissionId}
+---
\ No newline at end of file
diff --git a/api-reference/submissions/delete-multiple-submissions.mdx b/api-reference/submissions/delete-multiple-submissions.mdx
new file mode 100644
index 0000000..fcd3032
--- /dev/null
+++ b/api-reference/submissions/delete-multiple-submissions.mdx
@@ -0,0 +1,3 @@
+---
+openapi: delete /forms/{formId}/submissions/bulk
+---
\ No newline at end of file
diff --git a/api-reference/submissions/get-a-single-submission.mdx b/api-reference/submissions/get-a-single-submission.mdx
new file mode 100644
index 0000000..d47bf29
--- /dev/null
+++ b/api-reference/submissions/get-a-single-submission.mdx
@@ -0,0 +1,3 @@
+---
+openapi: get /forms/{formId}/submissions/{submissionId}
+---
\ No newline at end of file
diff --git a/api-reference/submissions/list-submissions-for-a-form.mdx b/api-reference/submissions/list-submissions-for-a-form.mdx
new file mode 100644
index 0000000..d294d10
--- /dev/null
+++ b/api-reference/submissions/list-submissions-for-a-form.mdx
@@ -0,0 +1,3 @@
+---
+openapi: get /forms/{formId}/submissions
+---
\ No newline at end of file
diff --git a/docs.json b/docs.json
index d82ae6d..d291baa 100644
--- a/docs.json
+++ b/docs.json
@@ -2,6 +2,7 @@
"$schema": "https://mintlify.com/docs.json",
"theme": "mint",
"name": "Formbase",
+ "openapi": "/openapi.json",
"colors": {
"primary": "#171717",
"light": "#FAFAFA",
@@ -123,6 +124,41 @@
"pages": ["faq/common-questions"]
}
]
+ },
+ {
+ "tab": "API Reference",
+ "groups": [
+ {
+ "group": "Overview",
+ "icon": "book",
+ "pages": ["api-reference/overview"]
+ },
+ {
+ "group": "Forms",
+ "icon": "rectangle-list",
+ "pages": [
+ "api-reference/forms/list-all-forms",
+ "api-reference/forms/get-a-single-form",
+ "api-reference/forms/create-a-new-form",
+ "api-reference/forms/duplicate-a-form",
+ "api-reference/forms/create-multiple-forms",
+ "api-reference/forms/update-a-form",
+ "api-reference/forms/update-multiple-forms",
+ "api-reference/forms/delete-a-form",
+ "api-reference/forms/delete-multiple-forms"
+ ]
+ },
+ {
+ "group": "Submissions",
+ "icon": "inbox",
+ "pages": [
+ "api-reference/submissions/list-submissions-for-a-form",
+ "api-reference/submissions/get-a-single-submission",
+ "api-reference/submissions/delete-a-submission",
+ "api-reference/submissions/delete-multiple-submissions"
+ ]
+ }
+ ]
}
],
"global": {
diff --git a/file-uploads/basic-file-upload.mdx b/file-uploads/basic-file-upload.mdx
index 07b8c91..0029b94 100644
--- a/file-uploads/basic-file-upload.mdx
+++ b/file-uploads/basic-file-upload.mdx
@@ -29,6 +29,10 @@ If you are self-hosting, make sure storage credentials are configured before ena
In the dashboard, the uploaded file appears as a clickable URL under `file` or `image`.
+
+
+
+
diff --git a/getting-started/creating-your-first-form.mdx b/getting-started/creating-your-first-form.mdx
index 5adce66..3f43717 100644
--- a/getting-started/creating-your-first-form.mdx
+++ b/getting-started/creating-your-first-form.mdx
@@ -11,9 +11,17 @@ You can also define a return URL. After a browser submission, Formbase shows a s
Sign in to Formbase and click "New Form" in your dashboard.
+
+
+
+
Add a title and optional description to make it easy to find later. These fields appear only in your dashboard.
+
+
+
+
If you want a button on the success page that sends visitors back to your site, add a return URL now or update it later in settings.
@@ -26,6 +34,10 @@ You can also define a return URL. After a browser submission, Formbase shows a s
```
Use this endpoint as the `action` in an HTML form or as the URL in your fetch request.
+
+
+
+
diff --git a/getting-started/introduction.mdx b/getting-started/introduction.mdx
index 5a8e98b..6ad8cf0 100644
--- a/getting-started/introduction.mdx
+++ b/getting-started/introduction.mdx
@@ -19,6 +19,10 @@ The workflow is simple: create a form in the dashboard, post to its endpoint, an
Submissions appear in the dashboard. Enable email notifications if you want alerts for new entries.
+
+
+
+
diff --git a/getting-started/receiving-your-first-submission.mdx b/getting-started/receiving-your-first-submission.mdx
index 0bdbaf6..bdc49a3 100644
--- a/getting-started/receiving-your-first-submission.mdx
+++ b/getting-started/receiving-your-first-submission.mdx
@@ -46,6 +46,10 @@ Use the method that best matches how you plan to collect submissions in producti
Open your form in the dashboard and confirm the submission appears in the table. New field names will show up as columns automatically.
+
+
+
+
If email notifications are enabled, you should receive a message with the submission data. Make sure your SMTP or Resend configuration is set up if you are self-hosting.
diff --git a/images/api-keys-page.png b/images/api-keys-page.png
new file mode 100644
index 0000000..b0b0c9b
Binary files /dev/null and b/images/api-keys-page.png differ
diff --git a/images/create-api-key-dialog.png b/images/create-api-key-dialog.png
new file mode 100644
index 0000000..eaf3806
Binary files /dev/null and b/images/create-api-key-dialog.png differ
diff --git a/images/dashboard-overview.png b/images/dashboard-overview.png
new file mode 100644
index 0000000..2bebe80
Binary files /dev/null and b/images/dashboard-overview.png differ
diff --git a/images/dashboard-with-form.png b/images/dashboard-with-form.png
new file mode 100644
index 0000000..f7927c6
Binary files /dev/null and b/images/dashboard-with-form.png differ
diff --git a/images/dashboard-with-forms.png b/images/dashboard-with-forms.png
new file mode 100644
index 0000000..0e9af19
Binary files /dev/null and b/images/dashboard-with-forms.png differ
diff --git a/images/export-dropdown.png b/images/export-dropdown.png
new file mode 100644
index 0000000..16278fd
Binary files /dev/null and b/images/export-dropdown.png differ
diff --git a/images/form-endpoint-display.png b/images/form-endpoint-display.png
new file mode 100644
index 0000000..112c423
Binary files /dev/null and b/images/form-endpoint-display.png differ
diff --git a/images/form-settings-full.png b/images/form-settings-full.png
new file mode 100644
index 0000000..39b16b9
Binary files /dev/null and b/images/form-settings-full.png differ
diff --git a/images/form-settings-notifications.png b/images/form-settings-notifications.png
new file mode 100644
index 0000000..2e6f99e
Binary files /dev/null and b/images/form-settings-notifications.png differ
diff --git a/images/new-form-dialog.png b/images/new-form-dialog.png
new file mode 100644
index 0000000..1bc5dbe
Binary files /dev/null and b/images/new-form-dialog.png differ
diff --git a/images/submission-row-actions.png b/images/submission-row-actions.png
new file mode 100644
index 0000000..ca83f5d
Binary files /dev/null and b/images/submission-row-actions.png differ
diff --git a/images/submissions-table.png b/images/submissions-table.png
new file mode 100644
index 0000000..f1c6096
Binary files /dev/null and b/images/submissions-table.png differ
diff --git a/images/success-page.png b/images/success-page.png
new file mode 100644
index 0000000..db68f84
Binary files /dev/null and b/images/success-page.png differ
diff --git a/index.mdx b/index.mdx
index 34f2a8b..dca76ce 100644
--- a/index.mdx
+++ b/index.mdx
@@ -7,6 +7,10 @@ Formbase is an open-source form backend that receives submissions from any front
Every form gets a unique endpoint like `https://formbase.dev/s/your-form-id` (or `https://your-domain.com/s/your-form-id` when self-hosted). Browser posts land on a built-in success page, and server submissions return JSON.
+
+
+
+
Set up a form in the dashboard and get your endpoint.
diff --git a/openapi.json b/openapi.json
new file mode 100644
index 0000000..894ac9d
--- /dev/null
+++ b/openapi.json
@@ -0,0 +1 @@
+{"openapi":"3.0.3","info":{"title":"Formbase API","description":"Public REST API for managing forms and submissions.","version":"1.0.0"},"servers":[{"url":"https://formbase.dev/api/v1"}],"paths":{"/forms":{"get":{"operationId":"forms-list","summary":"List all forms","description":"Returns a paginated list of forms owned by the authenticated user.","tags":["Forms"],"security":[{"bearerAuth":[]}],"parameters":[{"in":"query","name":"page","schema":{"type":"integer","minimum":1,"default":1}},{"in":"query","name":"perPage","schema":{"type":"integer","minimum":1,"maximum":100,"default":20}}],"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"type":"object","properties":{"forms":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string"},"title":{"type":"string"},"description":{"type":"string","nullable":true},"returnUrl":{"type":"string","nullable":true},"keys":{"type":"array","items":{"type":"string"}},"submissionCount":{"type":"number"},"createdAt":{"type":"string"},"updatedAt":{"type":"string","nullable":true}},"required":["id","title","description","returnUrl","keys","submissionCount","createdAt","updatedAt"]}},"pagination":{"type":"object","properties":{"page":{"type":"number"},"perPage":{"type":"number"},"total":{"type":"number"},"totalPages":{"type":"number"}},"required":["page","perPage","total","totalPages"]}},"required":["forms","pagination"]}}}},"400":{"description":"Invalid input data","content":{"application/json":{"schema":{"$ref":"#/components/schemas/error.BAD_REQUEST"}}}},"401":{"description":"Authorization not provided","content":{"application/json":{"schema":{"$ref":"#/components/schemas/error.UNAUTHORIZED"}}}},"403":{"description":"Insufficient access","content":{"application/json":{"schema":{"$ref":"#/components/schemas/error.FORBIDDEN"}}}},"404":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/error.NOT_FOUND"}}}},"500":{"description":"Internal server error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/error.INTERNAL_SERVER_ERROR"}}}}}},"post":{"operationId":"forms-create","summary":"Create a new form","tags":["Forms"],"security":[{"bearerAuth":[]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"title":{"type":"string","minLength":1,"maxLength":255},"description":{"type":"string","maxLength":1000},"returnUrl":{"type":"string","format":"uri"}},"required":["title"]}}}},"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"string"}},"required":["id"]}}}},"400":{"description":"Invalid input data","content":{"application/json":{"schema":{"$ref":"#/components/schemas/error.BAD_REQUEST"}}}},"401":{"description":"Authorization not provided","content":{"application/json":{"schema":{"$ref":"#/components/schemas/error.UNAUTHORIZED"}}}},"403":{"description":"Insufficient access","content":{"application/json":{"schema":{"$ref":"#/components/schemas/error.FORBIDDEN"}}}},"500":{"description":"Internal server error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/error.INTERNAL_SERVER_ERROR"}}}}}}},"/forms/{formId}":{"get":{"operationId":"forms-get","summary":"Get a single form","tags":["Forms"],"security":[{"bearerAuth":[]}],"parameters":[{"in":"path","name":"formId","schema":{"type":"string"},"required":true}],"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"string"},"title":{"type":"string"},"description":{"type":"string","nullable":true},"returnUrl":{"type":"string","nullable":true},"keys":{"type":"array","items":{"type":"string"}},"submissionCount":{"type":"number"},"createdAt":{"type":"string"},"updatedAt":{"type":"string","nullable":true}},"required":["id","title","description","returnUrl","keys","submissionCount","createdAt","updatedAt"]}}}},"400":{"description":"Invalid input data","content":{"application/json":{"schema":{"$ref":"#/components/schemas/error.BAD_REQUEST"}}}},"401":{"description":"Authorization not provided","content":{"application/json":{"schema":{"$ref":"#/components/schemas/error.UNAUTHORIZED"}}}},"403":{"description":"Insufficient access","content":{"application/json":{"schema":{"$ref":"#/components/schemas/error.FORBIDDEN"}}}},"404":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/error.NOT_FOUND"}}}},"500":{"description":"Internal server error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/error.INTERNAL_SERVER_ERROR"}}}}}},"patch":{"operationId":"forms-update","summary":"Update a form","tags":["Forms"],"security":[{"bearerAuth":[]}],"parameters":[{"in":"path","name":"formId","schema":{"type":"string"},"required":true}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"title":{"type":"string","minLength":1,"maxLength":255},"description":{"type":"string","maxLength":1000},"returnUrl":{"type":"string","format":"uri"}}}}}},"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"type":"object","properties":{"success":{"type":"boolean"}},"required":["success"]}}}},"400":{"description":"Invalid input data","content":{"application/json":{"schema":{"$ref":"#/components/schemas/error.BAD_REQUEST"}}}},"401":{"description":"Authorization not provided","content":{"application/json":{"schema":{"$ref":"#/components/schemas/error.UNAUTHORIZED"}}}},"403":{"description":"Insufficient access","content":{"application/json":{"schema":{"$ref":"#/components/schemas/error.FORBIDDEN"}}}},"404":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/error.NOT_FOUND"}}}},"500":{"description":"Internal server error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/error.INTERNAL_SERVER_ERROR"}}}}}},"delete":{"operationId":"forms-delete","summary":"Delete a form","description":"Permanently deletes a form and all its submissions.","tags":["Forms"],"security":[{"bearerAuth":[]}],"parameters":[{"in":"path","name":"formId","schema":{"type":"string"},"required":true}],"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"type":"object","properties":{"success":{"type":"boolean"}},"required":["success"]}}}},"400":{"description":"Invalid input data","content":{"application/json":{"schema":{"$ref":"#/components/schemas/error.BAD_REQUEST"}}}},"401":{"description":"Authorization not provided","content":{"application/json":{"schema":{"$ref":"#/components/schemas/error.UNAUTHORIZED"}}}},"403":{"description":"Insufficient access","content":{"application/json":{"schema":{"$ref":"#/components/schemas/error.FORBIDDEN"}}}},"404":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/error.NOT_FOUND"}}}},"500":{"description":"Internal server error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/error.INTERNAL_SERVER_ERROR"}}}}}}},"/forms/{formId}/duplicate":{"post":{"operationId":"forms-duplicate","summary":"Duplicate a form","description":"Creates a copy of a form with its configuration.","tags":["Forms"],"security":[{"bearerAuth":[]}],"parameters":[{"in":"path","name":"formId","schema":{"type":"string"},"required":true}],"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"string"}},"required":["id"]}}}},"400":{"description":"Invalid input data","content":{"application/json":{"schema":{"$ref":"#/components/schemas/error.BAD_REQUEST"}}}},"401":{"description":"Authorization not provided","content":{"application/json":{"schema":{"$ref":"#/components/schemas/error.UNAUTHORIZED"}}}},"403":{"description":"Insufficient access","content":{"application/json":{"schema":{"$ref":"#/components/schemas/error.FORBIDDEN"}}}},"500":{"description":"Internal server error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/error.INTERNAL_SERVER_ERROR"}}}}}}},"/forms/bulk":{"post":{"operationId":"forms-bulkCreate","summary":"Create multiple forms","tags":["Forms"],"security":[{"bearerAuth":[]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"forms":{"type":"array","items":{"type":"object","properties":{"title":{"type":"string","minLength":1,"maxLength":255},"description":{"type":"string","maxLength":1000},"returnUrl":{"type":"string","format":"uri"}},"required":["title"]}}},"required":["forms"]}}}},"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"type":"object","properties":{"ids":{"type":"array","items":{"type":"string"}}},"required":["ids"]}}}},"400":{"description":"Invalid input data","content":{"application/json":{"schema":{"$ref":"#/components/schemas/error.BAD_REQUEST"}}}},"401":{"description":"Authorization not provided","content":{"application/json":{"schema":{"$ref":"#/components/schemas/error.UNAUTHORIZED"}}}},"403":{"description":"Insufficient access","content":{"application/json":{"schema":{"$ref":"#/components/schemas/error.FORBIDDEN"}}}},"500":{"description":"Internal server error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/error.INTERNAL_SERVER_ERROR"}}}}}},"patch":{"operationId":"forms-bulkUpdate","summary":"Update multiple forms","tags":["Forms"],"security":[{"bearerAuth":[]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"forms":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string"},"title":{"type":"string","minLength":1,"maxLength":255},"description":{"type":"string","maxLength":1000},"returnUrl":{"type":"string","format":"uri"}},"required":["id"]}}},"required":["forms"]}}}},"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"type":"object","properties":{"success":{"type":"boolean"}},"required":["success"]}}}},"400":{"description":"Invalid input data","content":{"application/json":{"schema":{"$ref":"#/components/schemas/error.BAD_REQUEST"}}}},"401":{"description":"Authorization not provided","content":{"application/json":{"schema":{"$ref":"#/components/schemas/error.UNAUTHORIZED"}}}},"403":{"description":"Insufficient access","content":{"application/json":{"schema":{"$ref":"#/components/schemas/error.FORBIDDEN"}}}},"404":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/error.NOT_FOUND"}}}},"500":{"description":"Internal server error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/error.INTERNAL_SERVER_ERROR"}}}}}},"delete":{"operationId":"forms-bulkDelete","summary":"Delete multiple forms","tags":["Forms"],"security":[{"bearerAuth":[]}],"parameters":[{"in":"query","name":"ids","schema":{"type":"array","items":{"type":"string"}},"required":true}],"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"type":"object","properties":{"success":{"type":"boolean"}},"required":["success"]}}}},"400":{"description":"Invalid input data","content":{"application/json":{"schema":{"$ref":"#/components/schemas/error.BAD_REQUEST"}}}},"401":{"description":"Authorization not provided","content":{"application/json":{"schema":{"$ref":"#/components/schemas/error.UNAUTHORIZED"}}}},"403":{"description":"Insufficient access","content":{"application/json":{"schema":{"$ref":"#/components/schemas/error.FORBIDDEN"}}}},"404":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/error.NOT_FOUND"}}}},"500":{"description":"Internal server error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/error.INTERNAL_SERVER_ERROR"}}}}}}},"/forms/{formId}/submissions":{"get":{"operationId":"submissions-list","summary":"List submissions for a form","description":"Returns a paginated list of submissions with optional date filtering.","tags":["Submissions"],"security":[{"bearerAuth":[]}],"parameters":[{"in":"path","name":"formId","schema":{"type":"string"},"required":true},{"in":"query","name":"page","schema":{"type":"integer","minimum":1,"default":1}},{"in":"query","name":"perPage","schema":{"type":"integer","minimum":1,"maximum":100,"default":20}},{"in":"query","name":"startDate","schema":{"type":"string"}},{"in":"query","name":"endDate","schema":{"type":"string"}}],"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"type":"object","properties":{"submissions":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string"},"formId":{"type":"string"},"data":{"type":"object","additionalProperties":{}},"createdAt":{"type":"string"}},"required":["id","formId","data","createdAt"]}},"pagination":{"type":"object","properties":{"page":{"type":"number"},"perPage":{"type":"number"},"total":{"type":"number"},"totalPages":{"type":"number"}},"required":["page","perPage","total","totalPages"]}},"required":["submissions","pagination"]}}}},"400":{"description":"Invalid input data","content":{"application/json":{"schema":{"$ref":"#/components/schemas/error.BAD_REQUEST"}}}},"401":{"description":"Authorization not provided","content":{"application/json":{"schema":{"$ref":"#/components/schemas/error.UNAUTHORIZED"}}}},"403":{"description":"Insufficient access","content":{"application/json":{"schema":{"$ref":"#/components/schemas/error.FORBIDDEN"}}}},"404":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/error.NOT_FOUND"}}}},"500":{"description":"Internal server error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/error.INTERNAL_SERVER_ERROR"}}}}}}},"/forms/{formId}/submissions/{submissionId}":{"get":{"operationId":"submissions-get","summary":"Get a single submission","tags":["Submissions"],"security":[{"bearerAuth":[]}],"parameters":[{"in":"path","name":"formId","schema":{"type":"string"},"required":true},{"in":"path","name":"submissionId","schema":{"type":"string"},"required":true}],"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"string"},"formId":{"type":"string"},"data":{"type":"object","additionalProperties":{}},"createdAt":{"type":"string"}},"required":["id","formId","data","createdAt"]}}}},"400":{"description":"Invalid input data","content":{"application/json":{"schema":{"$ref":"#/components/schemas/error.BAD_REQUEST"}}}},"401":{"description":"Authorization not provided","content":{"application/json":{"schema":{"$ref":"#/components/schemas/error.UNAUTHORIZED"}}}},"403":{"description":"Insufficient access","content":{"application/json":{"schema":{"$ref":"#/components/schemas/error.FORBIDDEN"}}}},"404":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/error.NOT_FOUND"}}}},"500":{"description":"Internal server error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/error.INTERNAL_SERVER_ERROR"}}}}}},"delete":{"operationId":"submissions-delete","summary":"Delete a submission","tags":["Submissions"],"security":[{"bearerAuth":[]}],"parameters":[{"in":"path","name":"formId","schema":{"type":"string"},"required":true},{"in":"path","name":"submissionId","schema":{"type":"string"},"required":true}],"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"type":"object","properties":{"success":{"type":"boolean"}},"required":["success"]}}}},"400":{"description":"Invalid input data","content":{"application/json":{"schema":{"$ref":"#/components/schemas/error.BAD_REQUEST"}}}},"401":{"description":"Authorization not provided","content":{"application/json":{"schema":{"$ref":"#/components/schemas/error.UNAUTHORIZED"}}}},"403":{"description":"Insufficient access","content":{"application/json":{"schema":{"$ref":"#/components/schemas/error.FORBIDDEN"}}}},"404":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/error.NOT_FOUND"}}}},"500":{"description":"Internal server error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/error.INTERNAL_SERVER_ERROR"}}}}}}},"/forms/{formId}/submissions/bulk":{"delete":{"operationId":"submissions-bulkDelete","summary":"Delete multiple submissions","tags":["Submissions"],"security":[{"bearerAuth":[]}],"parameters":[{"in":"path","name":"formId","schema":{"type":"string"},"required":true},{"in":"query","name":"ids","schema":{"type":"array","items":{"type":"string"}},"required":true}],"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"type":"object","properties":{"success":{"type":"boolean"}},"required":["success"]}}}},"400":{"description":"Invalid input data","content":{"application/json":{"schema":{"$ref":"#/components/schemas/error.BAD_REQUEST"}}}},"401":{"description":"Authorization not provided","content":{"application/json":{"schema":{"$ref":"#/components/schemas/error.UNAUTHORIZED"}}}},"403":{"description":"Insufficient access","content":{"application/json":{"schema":{"$ref":"#/components/schemas/error.FORBIDDEN"}}}},"404":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/error.NOT_FOUND"}}}},"500":{"description":"Internal server error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/error.INTERNAL_SERVER_ERROR"}}}}}}}},"components":{"securitySchemes":{"bearerAuth":{"type":"http","scheme":"bearer","description":"API key in format: Bearer api_xxxxxxxxxxxxx"}},"schemas":{"error.BAD_REQUEST":{"type":"object","properties":{"message":{"type":"string","description":"The error message","example":"Invalid input data"},"code":{"type":"string","description":"The error code","example":"BAD_REQUEST"},"issues":{"type":"array","items":{"type":"object","properties":{"message":{"type":"string"}},"required":["message"]},"description":"An array of issues that were responsible for the error","example":[]}},"required":["message","code"],"title":"Invalid input data error (400)","description":"The error information","example":{"code":"BAD_REQUEST","message":"Invalid input data","issues":[]}},"error.UNAUTHORIZED":{"type":"object","properties":{"message":{"type":"string","description":"The error message","example":"Authorization not provided"},"code":{"type":"string","description":"The error code","example":"UNAUTHORIZED"},"issues":{"type":"array","items":{"type":"object","properties":{"message":{"type":"string"}},"required":["message"]},"description":"An array of issues that were responsible for the error","example":[]}},"required":["message","code"],"title":"Authorization not provided error (401)","description":"The error information","example":{"code":"UNAUTHORIZED","message":"Authorization not provided","issues":[]}},"error.FORBIDDEN":{"type":"object","properties":{"message":{"type":"string","description":"The error message","example":"Insufficient access"},"code":{"type":"string","description":"The error code","example":"FORBIDDEN"},"issues":{"type":"array","items":{"type":"object","properties":{"message":{"type":"string"}},"required":["message"]},"description":"An array of issues that were responsible for the error","example":[]}},"required":["message","code"],"title":"Insufficient access error (403)","description":"The error information","example":{"code":"FORBIDDEN","message":"Insufficient access","issues":[]}},"error.NOT_FOUND":{"type":"object","properties":{"message":{"type":"string","description":"The error message","example":"Not found"},"code":{"type":"string","description":"The error code","example":"NOT_FOUND"},"issues":{"type":"array","items":{"type":"object","properties":{"message":{"type":"string"}},"required":["message"]},"description":"An array of issues that were responsible for the error","example":[]}},"required":["message","code"],"title":"Not found error (404)","description":"The error information","example":{"code":"NOT_FOUND","message":"Not found","issues":[]}},"error.INTERNAL_SERVER_ERROR":{"type":"object","properties":{"message":{"type":"string","description":"The error message","example":"Internal server error"},"code":{"type":"string","description":"The error code","example":"INTERNAL_SERVER_ERROR"},"issues":{"type":"array","items":{"type":"object","properties":{"message":{"type":"string"}},"required":["message"]},"description":"An array of issues that were responsible for the error","example":[]}},"required":["message","code"],"title":"Internal server error error (500)","description":"The error information","example":{"code":"INTERNAL_SERVER_ERROR","message":"Internal server error","issues":[]}}}}}
\ No newline at end of file
diff --git a/package.json b/package.json
new file mode 100644
index 0000000..23b7049
--- /dev/null
+++ b/package.json
@@ -0,0 +1,8 @@
+{
+ "name": "formbase-docs",
+ "private": true,
+ "scripts": {
+ "dev": "bunx mint dev",
+ "update-api": "curl -s https://formbase.dev/api/v1/openapi.json > openapi.json && bunx @mintlify/scraping@latest openapi-file openapi.json -o api-reference"
+ }
+}
diff --git a/quickstart.mdx b/quickstart.mdx
index 2d55775..a377fb7 100644
--- a/quickstart.mdx
+++ b/quickstart.mdx
@@ -10,6 +10,10 @@ This quickstart uses a plain HTML form and a JavaScript fetch example so you can
Open the Formbase dashboard, create a new form, and copy the endpoint URL.
+
+
+
+
Use a standard HTML form for the simplest setup, or submit with fetch when you need full UI control.
diff --git a/redirects/basic-redirect-setup.mdx b/redirects/basic-redirect-setup.mdx
index 667d402..8423ad3 100644
--- a/redirects/basic-redirect-setup.mdx
+++ b/redirects/basic-redirect-setup.mdx
@@ -10,6 +10,14 @@ Choose the approach that fits your UX.
In the form settings, set a return URL. After submission, Formbase displays a success page with a "Return" button pointing to that URL.
+
+
+
+
+
+
+
+
Intercept the submission with JavaScript and send users to your own thank-you page.
diff --git a/settings/default-recipient-email.mdx b/settings/default-recipient-email.mdx
index 437ad75..743051a 100644
--- a/settings/default-recipient-email.mdx
+++ b/settings/default-recipient-email.mdx
@@ -13,6 +13,10 @@ Use this when multiple teammates manage different forms or when you want alerts
Enter the email address you want to receive notifications and click "Save".
+
+
+
+
diff --git a/settings/email-notifications.mdx b/settings/email-notifications.mdx
index 9e74638..4825df8 100644
--- a/settings/email-notifications.mdx
+++ b/settings/email-notifications.mdx
@@ -10,6 +10,10 @@ Notifications are enabled per form and are delivered using your configured email
Open your form, go to the "Settings" tab, and toggle "Enable Form Submission Notifications".
+
+
+
+
If you are self-hosting, set up SMTP or Resend in your environment. See [Email setup](/self-hosting/email-setup).
diff --git a/settings/enable-disable-submissions.mdx b/settings/enable-disable-submissions.mdx
index 59ceb6c..c1fa89e 100644
--- a/settings/enable-disable-submissions.mdx
+++ b/settings/enable-disable-submissions.mdx
@@ -13,6 +13,10 @@ The toggle is stored with the form and reflected in the dashboard.
Switch "Enable Form Submissions" on or off.
+
+
+
+
diff --git a/submissions/deleting-submissions.mdx b/submissions/deleting-submissions.mdx
index bdd34f4..3d8ef24 100644
--- a/submissions/deleting-submissions.mdx
+++ b/submissions/deleting-submissions.mdx
@@ -13,6 +13,10 @@ If you need to delete all submissions for a form, delete the form itself.
Use the row action menu (three dots) and select "Delete". The submission is removed immediately.
+
+
+
+
diff --git a/submissions/exporting-to-csv.mdx b/submissions/exporting-to-csv.mdx
index 916c1be..3a93ae5 100644
--- a/submissions/exporting-to-csv.mdx
+++ b/submissions/exporting-to-csv.mdx
@@ -13,6 +13,10 @@ Use CSV when your data is mostly flat (text, email, single-value fields).
Click the "Export" button and choose "Export as CSV". The file downloads immediately.
+
+
+
+
diff --git a/submissions/exporting-to-json.mdx b/submissions/exporting-to-json.mdx
index 1d2a8cb..95cd66c 100644
--- a/submissions/exporting-to-json.mdx
+++ b/submissions/exporting-to-json.mdx
@@ -11,6 +11,10 @@ JSON exports are best when you want to process submissions programmatically or p
Click the "Export" button and choose "Export as JSON". The file downloads immediately.
+
+
+
+
diff --git a/submissions/viewing-submissions.mdx b/submissions/viewing-submissions.mdx
index 7a043fa..34ef811 100644
--- a/submissions/viewing-submissions.mdx
+++ b/submissions/viewing-submissions.mdx
@@ -13,6 +13,10 @@ Use this page to review data, download files, and delete entries when needed.
Each row is a submission. Columns are created from submitted field names, plus a "Created At" timestamp.
+
+
+
+
If a submission includes a `file` or `image` URL, the table shows a downloadable link. Images include a quick preview dialog.