Matches in other apps
zpe-forms
mount /forms · base https://zpe.vc/forms · v7.0.2 · 12 operations · 5 write · 2 need no account · stable
the document this app serves now. Contract: https://zpe.vc/forms/_/api/v1/openapi.json · sha256 e0c4776763ee
POST
/_/api/v1/forms/{publicId}/submissions
Write one submission to the form that owns this public id
postFormsByIdSubmissions
no account
Write one submission to the form that owns this public id
Parameters
| name | in | required | type | notes |
|---|---|---|---|---|
publicId | path | yes | string | The form's public id, the one its `/f/<publicId>` link carries. |
Idempotency-Key | header | no | string | A value that names this attempt. Send the same one when retrying and the answer is the submission the first call wrote (`200`) instead of a second row; present and empty is refused. The form's own page cannot set a header, so it carries the same value in a body field of the same name. |
Request body application/json · required
| field | type | required | notes |
|---|---|---|---|
Idempotency-Key | string | no | The page's copy of the retry handle: the same value the `Idempotency-Key` header carries. Lifted out of the body before the questions are judged, never stored as an answer. |
Responses
| status | meaning | body |
|---|---|---|
200 | Nothing new was written: this `Idempotency-Key` already wrote a submission to this form, and this is the id of the row the first call wrote. | object |
201 | The submission was written to the account that owns this form. The body names its id. | object |
303 | The caller posted the page's own form rather than asking for JSON, so the answer is the page it came from (or `?redirect=`, or the form's page with `sent=1`). No body. | |
400 | The body is not JSON, or is not an object, or `Idempotency-Key` was sent empty or longer than 200 characters. | object |
401 | The credential is missing or does not open this account | object |
403 | This account may not do that | object |
404 | That public id names no form on this deployment. | object |
413 | The body is over this deployment's `MAX_SUBMISSION_BYTES`. | object |
415 | The body is not `application/json`, `application/x-www-form-urlencoded` or `multipart/form-data`. | object |
422 | A question the form declares was left unanswered, a value is too long or is not the shape its key asks for, nothing at all was filled in, or the body carries a key the form never declared. Nothing was written. | object |
429 | Too many requests | object |
Example
Write one submission to the form that owns this public id.
curl -X POST 'https://zpe.vc/forms/_/api/v1/forms/string/submissions' \
-H 'content-type: application/json' \
-d '{
"Idempotency-Key": "string"
}'{
"success": false,
"id": "string"
}The example is generated from the schema in the contract: the shape is the document's, the values are placeholders.
OPTIONS
/_/api/v1/forms/{publicId}/submissions
CORS preflight for the write path, answered before any credential
optionsFormsByIdSubmissions
no account
CORS preflight for the write path, answered before any credential
Parameters
| name | in | required | type | notes |
|---|---|---|---|---|
publicId | path | yes | string | The form's public id, the one its `/f/<publicId>` link carries. |
Request body
None: this operation takes its arguments in the path and the query.
Responses
| status | meaning | body |
|---|---|---|
204 | No content: the preflight's policy is in the headers (`access-control-allow-origin`, `-methods`, `-headers`, `-max-age`) and the answer carries no body. Answered before any credential is read. | |
500 | The deployment failed while answering. The wrapper answers this for any matched route whose handler throws, so it is published rather than left for a caller to discover. | object |
503 | The database schema could not be created, so the request was refused before it reached the handler. Nothing was read and nothing was written. | object |
Example
CORS preflight for the write path, answered before any credential.
curl -X OPTIONS 'https://zpe.vc/forms/_/api/v1/forms/string/submissions'
The example is generated from the schema in the contract: the shape is the document's, the values are placeholders.
GET
/_/api/v1/submissions
Read the 200 most recent submissions of every form this account owns
getSubmissions
Read the 200 most recent submissions of every form this account owns
Parameters
No parameters.
Request body
None: this operation takes its arguments in the path and the query.
Responses
| status | meaning | body |
|---|---|---|
200 | Every form this account owns, and its 200 most recent submissions, newest first, each named by the form it came from. | object |
401 | No key and no session: the caller is not signed in at the door, or the key it sent is unknown, revoked or expired. | object |
403 | This credential opens no account here, this key is not granted this app, or — on a write — the request came from another origin. | object |
429 | This key has spent its ceiling of 120 requests in the current minute; `retry-after` says when to try again. | object |
500 | This app failed while answering | object |
503 | The door did not answer, or this deployment could not create its schema, so nothing was read and nothing was written. | object |
Example
Read the 200 most recent submissions of every form this account owns, with a token from the door.
curl -X GET 'https://zpe.vc/forms/_/api/v1/submissions' \ -H 'Authorization: Bearer $ZPE_TOKEN'
{}The example is generated from the schema in the contract: the shape is the document's, the values are placeholders.
GET
/_/api/v1/console/me
Who the caller is, as the door names them
getConsoleMe
Who the caller is, as the door names them
Parameters
No parameters.
Request body
None: this operation takes its arguments in the path and the query.
Responses
| status | meaning | body |
|---|---|---|
200 | The account the door named for this caller, and the email the session carries (`null` for a key, which names no person). | object |
401 | No key and no session: the caller is not signed in at the door, or the key it sent is unknown, revoked or expired. | object |
403 | This credential opens no account here, this key is not granted this app, or — on a write — the request came from another origin. | object |
429 | This key has spent its ceiling of 120 requests in the current minute; `retry-after` says when to try again. | object |
500 | This app failed while answering | object |
503 | The door did not answer, or this deployment could not create its schema, so nothing was read and nothing was written. | object |
Example
Who the caller is, as the door names them, with a token from the door.
curl -X GET 'https://zpe.vc/forms/_/api/v1/console/me' \ -H 'Authorization: Bearer $ZPE_TOKEN'
{}The example is generated from the schema in the contract: the shape is the document's, the values are placeholders.
GET
/_/api/v1/console/forms
List this account's forms, oldest first, with a submission count and the last one's time
getConsoleForms
List this account's forms, oldest first, with a submission count and the last one's time
Parameters
No parameters.
Request body
None: this operation takes its arguments in the path and the query.
Responses
| status | meaning | body |
|---|---|---|
200 | This account's forms, oldest first, each with its submission count and the time of its last one. | object |
401 | No key and no session: the caller is not signed in at the door, or the key it sent is unknown, revoked or expired. | object |
403 | This credential opens no account here, this key is not granted this app, or — on a write — the request came from another origin. | object |
429 | This key has spent its ceiling of 120 requests in the current minute; `retry-after` says when to try again. | object |
500 | This app failed while answering | object |
503 | The door did not answer, or this deployment could not create its schema, so nothing was read and nothing was written. | object |
Example
List this account's forms, oldest first, with a submission count and the last one's time, with a token from the door.
curl -X GET 'https://zpe.vc/forms/_/api/v1/console/forms' \ -H 'Authorization: Bearer $ZPE_TOKEN'
{}The example is generated from the schema in the contract: the shape is the document's, the values are placeholders.
POST
/_/api/v1/console/forms
Create a form in this account; the slug comes from the name and the public id is minted here
postConsoleForms
Create a form in this account; the slug comes from the name and the public id is minted here
Parameters
| name | in | required | type | notes |
|---|---|---|---|---|
Idempotency-Key | header | no | string | A value that names this attempt. Send the same one when retrying and the answer is the form the first call wrote (`200`) instead of `a form named … already exists`; present and empty is refused. |
Request body application/json · required
| field | type | required | notes |
|---|---|---|---|
name | string | yes | The form's name. Its slug is derived once, here, and never moves. |
Responses
| status | meaning | body |
|---|---|---|
200 | Nothing new was written: this `Idempotency-Key` already created a form in this account, and this is the row the first call wrote. | object |
201 | The form was created in this account. Its slug comes from the name. | object |
400 | The body names no form, its name has no letter or digit, the name is one of this app's own addresses, a form with that name already exists in this account, or `Idempotency-Key` was sent empty or over 200 characters. | object |
401 | The credential is missing or does not open this account | object |
403 | This account may not do that | object |
404 | Nothing is here | object |
429 | Too many requests | object |
Example
Create a form in this account; the slug comes from the name and the public id is minted here, with a token from the door.
curl -X POST 'https://zpe.vc/forms/_/api/v1/console/forms' \
-H 'Authorization: Bearer $ZPE_TOKEN' \
-H 'content-type: application/json' \
-d '{
"name": "string"
}'{
"success": false,
"form": {
"id": "string",
"name": "string",
"public_id": "string",
"created_at": 0,
"updated_at": 0
}
}The example is generated from the schema in the contract: the shape is the document's, the values are placeholders.
GET
/_/api/v1/console/forms/{id}
One form of this account, with its submission stats and its last 30 days
getConsoleFormsById
One form of this account, with its submission stats and its last 30 days
Parameters
| name | in | required | type | notes |
|---|---|---|---|---|
id | path | yes | string | The form's slug, unique within this account. |
Request body
None: this operation takes its arguments in the path and the query.
Responses
| status | meaning | body |
|---|---|---|
200 | The form, its question set (`null` when it inherits the three defaults), its submission stats and its last 30 days. | object |
400 | The path carries a malformed percent escape, so the slug cannot be read and no form can be addressed. | object |
401 | No key and no session: the caller is not signed in at the door, or the key it sent is unknown, revoked or expired. | object |
403 | This credential opens no account here, this key is not granted this app, or — on a write — the request came from another origin. | object |
404 | No form in this account answers to that slug. | object |
429 | This key has spent its ceiling of 120 requests in the current minute; `retry-after` says when to try again. | object |
500 | This app failed while answering | object |
503 | The door did not answer, or this deployment could not create its schema, so nothing was read and nothing was written. | object |
Example
One form of this account, with its submission stats and its last 30 days, with a token from the door.
curl -X GET 'https://zpe.vc/forms/_/api/v1/console/forms/string' \ -H 'Authorization: Bearer $ZPE_TOKEN'
{}The example is generated from the schema in the contract: the shape is the document's, the values are placeholders.
PATCH
/_/api/v1/console/forms/{id}
Rename a form or replace its question set; the slug and the public id do not move
patchConsoleFormsById
Rename a form or replace its question set; the slug and the public id do not move
Parameters
| name | in | required | type | notes |
|---|---|---|---|---|
id | path | yes | string | The form's slug, unique within this account. |
Request body application/json · required
| field | type | required | notes |
|---|---|---|---|
name | string | no | The new name. A form's address is fixed at creation. |
fields | array | null of object | no | The form's own questions, in the order the page asks them, or null to inherit the three defaults. Replaces the whole set. |
Responses
| status | meaning | body |
|---|---|---|
200 | The form was renamed or its question set replaced; the row published is the one now stored. | object |
400 | The body is not JSON, is not an object, carries neither a name nor a field set, or names a field set this app will not store. | object |
401 | No key and no session: the caller is not signed in at the door, or the key it sent is unknown, revoked or expired. | object |
403 | This credential opens no account here, this key is not granted this app, or — on a write — the request came from another origin. | object |
404 | No form in this account answers to that slug, so nothing was changed. | object |
413 | The body is larger than this deployment's `MAX_SUBMISSION_BYTES`. | object |
415 | The body is neither `application/json` nor `application/x-www-form-urlencoded`. | object |
429 | This key has spent its ceiling of 120 requests in the current minute; `retry-after` says when to try again. | object |
500 | This app failed while answering | object |
503 | The door did not answer, or this deployment could not create its schema, so nothing was read and nothing was written. | object |
Example
Rename a form or replace its question set; the slug and the public id do not move, with a token from the door.
curl -X PATCH 'https://zpe.vc/forms/_/api/v1/console/forms/string' \
-H 'Authorization: Bearer $ZPE_TOKEN' \
-H 'content-type: application/json' \
-d '{
"name": "string",
"fields": null
}'{}The example is generated from the schema in the contract: the shape is the document's, the values are placeholders.
DELETE
/_/api/v1/console/forms/{id}
Delete a form and every submission it received
deleteConsoleFormsById
Delete a form and every submission it received
Parameters
| name | in | required | type | notes |
|---|---|---|---|---|
id | path | yes | string | The form's slug, unique within this account. |
Request body
None: this operation takes its arguments in the path and the query.
Responses
| status | meaning | body |
|---|---|---|
200 | The form and every submission it received were deleted; `deleted` counts the rows. | object |
400 | The path carries a malformed percent escape, so the slug cannot be read and no form can be addressed. | object |
401 | No key and no session: the caller is not signed in at the door, or the key it sent is unknown, revoked or expired. | object |
403 | This credential opens no account here, this key is not granted this app, or — on a write — the request came from another origin. | object |
404 | No form in this account answers to that slug, so nothing was deleted. | object |
429 | This key has spent its ceiling of 120 requests in the current minute; `retry-after` says when to try again. | object |
500 | This app failed while answering | object |
503 | The door did not answer, or this deployment could not create its schema, so nothing was read and nothing was written. | object |
Example
Delete a form and every submission it received, with a token from the door.
curl -X DELETE 'https://zpe.vc/forms/_/api/v1/console/forms/string' \ -H 'Authorization: Bearer $ZPE_TOKEN'
{}The example is generated from the schema in the contract: the shape is the document's, the values are placeholders.
GET
/_/api/v1/console/forms/{id}/submissions
This form's submissions, newest first
getConsoleFormsByIdSubmissions
This form's submissions, newest first
Parameters
| name | in | required | type | notes |
|---|---|---|---|---|
id | path | yes | string | The form's slug, unique within this account. |
limit | query | no | string | How many rows to return; the deployment caps it. |
Request body
None: this operation takes its arguments in the path and the query.
Responses
| status | meaning | body |
|---|---|---|
200 | This form's submissions, newest first, capped by `limit` and by this deployment's own ceiling. | object |
400 | The path carries a malformed percent escape, so the slug cannot be read and no form can be addressed. | object |
401 | No key and no session: the caller is not signed in at the door, or the key it sent is unknown, revoked or expired. | object |
403 | This credential opens no account here, this key is not granted this app, or — on a write — the request came from another origin. | object |
404 | No form in this account answers to that slug. | object |
429 | This key has spent its ceiling of 120 requests in the current minute; `retry-after` says when to try again. | object |
500 | This app failed while answering | object |
503 | The door did not answer, or this deployment could not create its schema, so nothing was read and nothing was written. | object |
Example
This form's submissions, newest first, with a token from the door.
curl -X GET 'https://zpe.vc/forms/_/api/v1/console/forms/string/submissions?limit=string' \ -H 'Authorization: Bearer $ZPE_TOKEN'
{}The example is generated from the schema in the contract: the shape is the document's, the values are placeholders.
DELETE
/_/api/v1/console/forms/{id}/submissions/{submissionId}
Delete one submission of this account's form
deleteConsoleFormsByIdSubmissionsById
Delete one submission of this account's form
Parameters
| name | in | required | type | notes |
|---|---|---|---|---|
id | path | yes | string | The form's slug, unique within this account. |
submissionId | path | yes | string | The submission's id. |
Request body
None: this operation takes its arguments in the path and the query.
Responses
| status | meaning | body |
|---|---|---|
200 | The submission was deleted; `deleted` counts the row. | object |
400 | A path segment carries a malformed percent escape, so the form or the submission cannot be addressed. | object |
401 | No key and no session: the caller is not signed in at the door, or the key it sent is unknown, revoked or expired. | object |
403 | This credential opens no account here, this key is not granted this app, or — on a write — the request came from another origin. | object |
404 | No submission in this account's form answers to that id, so nothing was deleted. | object |
429 | This key has spent its ceiling of 120 requests in the current minute; `retry-after` says when to try again. | object |
500 | This app failed while answering | object |
503 | The door did not answer, or this deployment could not create its schema, so nothing was read and nothing was written. | object |
Example
Delete one submission of this account's form, with a token from the door.
curl -X DELETE 'https://zpe.vc/forms/_/api/v1/console/forms/string/submissions/string' \ -H 'Authorization: Bearer $ZPE_TOKEN'
{}The example is generated from the schema in the contract: the shape is the document's, the values are placeholders.
GET
/_/api/v1/console/settings
What this deployment does about mail, which is not a setting a form can hold
getConsoleSettings
What this deployment does about mail, which is not a setting a form can hold
Parameters
No parameters.
Request body
None: this operation takes its arguments in the path and the query.
Responses
| status | meaning | body |
|---|---|---|
200 | What this deployment does about mail for submissions: nothing is sent, so `settings` is null and `managed` is the estate. | object |
401 | No key and no session: the caller is not signed in at the door, or the key it sent is unknown, revoked or expired. | object |
403 | This credential opens no account here, this key is not granted this app, or — on a write — the request came from another origin. | object |
429 | This key has spent its ceiling of 120 requests in the current minute; `retry-after` says when to try again. | object |
500 | This app failed while answering | object |
503 | The door did not answer, or this deployment could not create its schema, so nothing was read and nothing was written. | object |
Example
What this deployment does about mail, which is not a setting a form can hold, with a token from the door.
curl -X GET 'https://zpe.vc/forms/_/api/v1/console/settings' \ -H 'Authorization: Bearer $ZPE_TOKEN'
{}The example is generated from the schema in the contract: the shape is the document's, the values are placeholders.