- desktop/ → examples/django-react-desktop-app/ - e2e/ → examples/django-react-site/ - example/ → examples/django-react-site/backend/ - Update Dockerfile.test, Makefile, playwright config, and django.config.mjs path references Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2656 lines
64 KiB
JSON
2656 lines
64 KiB
JSON
{
|
|
"openapi": "3.1.0",
|
|
"info": {
|
|
"title": "mizan Server Functions",
|
|
"version": "1.0.0",
|
|
"description": "Auto-generated schema for mizan server functions"
|
|
},
|
|
"paths": {
|
|
"/mizan/echo": {
|
|
"post": {
|
|
"operationId": "echo",
|
|
"summary": "Call echo",
|
|
"parameters": [],
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/echoOutput"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"requestBody": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/echoInput"
|
|
}
|
|
}
|
|
},
|
|
"required": true
|
|
},
|
|
"x-mizan": {
|
|
"transport": "websocket",
|
|
"isContext": false
|
|
}
|
|
}
|
|
},
|
|
"/mizan/add": {
|
|
"post": {
|
|
"operationId": "add",
|
|
"summary": "Call add",
|
|
"parameters": [],
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/addOutput"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"requestBody": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/addInput"
|
|
}
|
|
}
|
|
},
|
|
"required": true
|
|
},
|
|
"x-mizan": {
|
|
"transport": "websocket",
|
|
"isContext": false
|
|
}
|
|
}
|
|
},
|
|
"/mizan/whoami": {
|
|
"post": {
|
|
"operationId": "whoami",
|
|
"summary": "Call whoami",
|
|
"parameters": [],
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/whoamiOutput"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"x-mizan": {
|
|
"transport": "http",
|
|
"isContext": false
|
|
}
|
|
}
|
|
},
|
|
"/mizan/http_only_echo": {
|
|
"post": {
|
|
"operationId": "httpOnlyEcho",
|
|
"summary": "Call http_only_echo",
|
|
"parameters": [],
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/httpOnlyEchoOutput"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"requestBody": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/httpOnlyEchoInput"
|
|
}
|
|
}
|
|
},
|
|
"required": true
|
|
},
|
|
"x-mizan": {
|
|
"transport": "http",
|
|
"isContext": false
|
|
}
|
|
}
|
|
},
|
|
"/mizan/login.schema": {
|
|
"post": {
|
|
"operationId": "loginSchema",
|
|
"summary": "Call login.schema",
|
|
"parameters": [],
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/loginSchemaOutput"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"x-mizan": {
|
|
"transport": "http",
|
|
"isContext": false
|
|
}
|
|
}
|
|
},
|
|
"/mizan/login.validate": {
|
|
"post": {
|
|
"operationId": "loginValidate",
|
|
"summary": "Call login.validate",
|
|
"parameters": [],
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/loginValidateOutput"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"requestBody": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/loginValidateInput"
|
|
}
|
|
}
|
|
},
|
|
"required": true
|
|
},
|
|
"x-mizan": {
|
|
"transport": "http",
|
|
"isContext": false
|
|
}
|
|
}
|
|
},
|
|
"/mizan/login.submit": {
|
|
"post": {
|
|
"operationId": "loginSubmit",
|
|
"summary": "Call login.submit",
|
|
"parameters": [],
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/loginSubmitOutput"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"requestBody": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/loginSubmitInput"
|
|
}
|
|
}
|
|
},
|
|
"required": true
|
|
},
|
|
"x-mizan": {
|
|
"transport": "http",
|
|
"isContext": false
|
|
}
|
|
}
|
|
},
|
|
"/mizan/signup.schema": {
|
|
"post": {
|
|
"operationId": "signupSchema",
|
|
"summary": "Call signup.schema",
|
|
"parameters": [],
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/signupSchemaOutput"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"x-mizan": {
|
|
"transport": "http",
|
|
"isContext": false
|
|
}
|
|
}
|
|
},
|
|
"/mizan/signup.validate": {
|
|
"post": {
|
|
"operationId": "signupValidate",
|
|
"summary": "Call signup.validate",
|
|
"parameters": [],
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/signupValidateOutput"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"requestBody": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/signupValidateInput"
|
|
}
|
|
}
|
|
},
|
|
"required": true
|
|
},
|
|
"x-mizan": {
|
|
"transport": "http",
|
|
"isContext": false
|
|
}
|
|
}
|
|
},
|
|
"/mizan/signup.submit": {
|
|
"post": {
|
|
"operationId": "signupSubmit",
|
|
"summary": "Call signup.submit",
|
|
"parameters": [],
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/signupSubmitOutput"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"requestBody": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/signupSubmitInput"
|
|
}
|
|
}
|
|
},
|
|
"required": true
|
|
},
|
|
"x-mizan": {
|
|
"transport": "http",
|
|
"isContext": false
|
|
}
|
|
}
|
|
},
|
|
"/mizan/add_email.schema": {
|
|
"post": {
|
|
"operationId": "addEmailSchema",
|
|
"summary": "Call add_email.schema",
|
|
"parameters": [],
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/addEmailSchemaOutput"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"x-mizan": {
|
|
"transport": "http",
|
|
"isContext": false
|
|
}
|
|
}
|
|
},
|
|
"/mizan/add_email.validate": {
|
|
"post": {
|
|
"operationId": "addEmailValidate",
|
|
"summary": "Call add_email.validate",
|
|
"parameters": [],
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/addEmailValidateOutput"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"requestBody": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/addEmailValidateInput"
|
|
}
|
|
}
|
|
},
|
|
"required": true
|
|
},
|
|
"x-mizan": {
|
|
"transport": "http",
|
|
"isContext": false
|
|
}
|
|
}
|
|
},
|
|
"/mizan/staff_only": {
|
|
"post": {
|
|
"operationId": "staffOnly",
|
|
"summary": "Call staff_only",
|
|
"parameters": [],
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/staffOnlyOutput"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"x-mizan": {
|
|
"transport": "http",
|
|
"isContext": false
|
|
}
|
|
}
|
|
},
|
|
"/mizan/superuser_only": {
|
|
"post": {
|
|
"operationId": "superuserOnly",
|
|
"summary": "Call superuser_only",
|
|
"parameters": [],
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/superuserOnlyOutput"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"x-mizan": {
|
|
"transport": "http",
|
|
"isContext": false
|
|
}
|
|
}
|
|
},
|
|
"/mizan/verified_only": {
|
|
"post": {
|
|
"operationId": "verifiedOnly",
|
|
"summary": "Call verified_only",
|
|
"parameters": [],
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/verifiedOnlyOutput"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"x-mizan": {
|
|
"transport": "http",
|
|
"isContext": false
|
|
}
|
|
}
|
|
},
|
|
"/mizan/current_user": {
|
|
"post": {
|
|
"operationId": "currentUser",
|
|
"summary": "Call current_user",
|
|
"parameters": [],
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/currentUserOutput"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"x-mizan": {
|
|
"transport": "http",
|
|
"isContext": "global"
|
|
}
|
|
}
|
|
},
|
|
"/mizan/greet": {
|
|
"post": {
|
|
"operationId": "greet",
|
|
"summary": "Call greet",
|
|
"parameters": [],
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/greetOutput"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"requestBody": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/greetInput"
|
|
}
|
|
}
|
|
},
|
|
"required": true
|
|
},
|
|
"x-mizan": {
|
|
"transport": "http",
|
|
"isContext": "local"
|
|
}
|
|
}
|
|
},
|
|
"/mizan/multiply": {
|
|
"post": {
|
|
"operationId": "multiply",
|
|
"summary": "Call multiply",
|
|
"parameters": [],
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/multiplyOutput"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"requestBody": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/multiplyInput"
|
|
}
|
|
}
|
|
},
|
|
"required": true
|
|
},
|
|
"x-mizan": {
|
|
"transport": "http",
|
|
"isContext": false
|
|
}
|
|
}
|
|
},
|
|
"/mizan/not_implemented_fn": {
|
|
"post": {
|
|
"operationId": "notImplementedFn",
|
|
"summary": "Call not_implemented_fn",
|
|
"parameters": [],
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/notImplementedFnOutput"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"x-mizan": {
|
|
"transport": "http",
|
|
"isContext": false
|
|
}
|
|
}
|
|
},
|
|
"/mizan/buggy_fn": {
|
|
"post": {
|
|
"operationId": "buggyFn",
|
|
"summary": "Call buggy_fn",
|
|
"parameters": [],
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/buggyFnOutput"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"x-mizan": {
|
|
"transport": "http",
|
|
"isContext": false
|
|
}
|
|
}
|
|
},
|
|
"/mizan/permission_check_fn": {
|
|
"post": {
|
|
"operationId": "permissionCheckFn",
|
|
"summary": "Call permission_check_fn",
|
|
"parameters": [],
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/permissionCheckFnOutput"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"requestBody": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/permissionCheckFnInput"
|
|
}
|
|
}
|
|
},
|
|
"required": true
|
|
},
|
|
"x-mizan": {
|
|
"transport": "http",
|
|
"isContext": false
|
|
}
|
|
}
|
|
},
|
|
"/mizan/ws_whoami": {
|
|
"post": {
|
|
"operationId": "wsWhoami",
|
|
"summary": "Call ws_whoami",
|
|
"parameters": [],
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/wsWhoamiOutput"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"x-mizan": {
|
|
"transport": "websocket",
|
|
"isContext": false
|
|
}
|
|
}
|
|
},
|
|
"/mizan/contact.schema": {
|
|
"post": {
|
|
"operationId": "contactSchema",
|
|
"summary": "Call contact.schema",
|
|
"parameters": [],
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/contactSchemaOutput"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"requestBody": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/contactSchemaInput"
|
|
}
|
|
}
|
|
},
|
|
"required": true
|
|
},
|
|
"x-mizan": {
|
|
"transport": "http",
|
|
"isContext": false
|
|
}
|
|
}
|
|
},
|
|
"/mizan/contact.validate": {
|
|
"post": {
|
|
"operationId": "contactValidate",
|
|
"summary": "Call contact.validate",
|
|
"parameters": [],
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/contactValidateOutput"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"requestBody": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/contactValidateInput"
|
|
}
|
|
}
|
|
},
|
|
"required": true
|
|
},
|
|
"x-mizan": {
|
|
"transport": "http",
|
|
"isContext": false
|
|
}
|
|
}
|
|
},
|
|
"/mizan/contact.submit": {
|
|
"post": {
|
|
"operationId": "contactSubmit",
|
|
"summary": "\nSubmit function handles both JSON and multipart/form-data.\n\nThe executor detects form functions and parses the request appropriately.\n",
|
|
"parameters": [],
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/contactSubmitOutput"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"x-mizan": {
|
|
"transport": "http",
|
|
"isContext": false
|
|
}
|
|
}
|
|
},
|
|
"/mizan/item.schema": {
|
|
"post": {
|
|
"operationId": "itemSchema",
|
|
"summary": "Call item.schema",
|
|
"parameters": [],
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/itemSchemaOutput"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"requestBody": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/itemSchemaInput"
|
|
}
|
|
}
|
|
},
|
|
"required": true
|
|
},
|
|
"x-mizan": {
|
|
"transport": "http",
|
|
"isContext": false
|
|
}
|
|
}
|
|
},
|
|
"/mizan/item.validate": {
|
|
"post": {
|
|
"operationId": "itemValidate",
|
|
"summary": "Call item.validate",
|
|
"parameters": [],
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/itemValidateOutput"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"requestBody": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/itemValidateInput"
|
|
}
|
|
}
|
|
},
|
|
"required": true
|
|
},
|
|
"x-mizan": {
|
|
"transport": "http",
|
|
"isContext": false
|
|
}
|
|
}
|
|
},
|
|
"/mizan/item.submit": {
|
|
"post": {
|
|
"operationId": "itemSubmit",
|
|
"summary": "\nSubmit function handles both JSON and multipart/form-data.\n\nThe executor detects form functions and parses the request appropriately.\n",
|
|
"parameters": [],
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/itemSubmitOutput"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"x-mizan": {
|
|
"transport": "http",
|
|
"isContext": false
|
|
}
|
|
}
|
|
},
|
|
"/mizan/item.formset.schema": {
|
|
"post": {
|
|
"operationId": "itemFormsetSchema",
|
|
"summary": "Call item.formset.schema",
|
|
"parameters": [],
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/itemFormsetSchemaOutput"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"requestBody": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/itemFormsetSchemaInput"
|
|
}
|
|
}
|
|
},
|
|
"required": true
|
|
},
|
|
"x-mizan": {
|
|
"transport": "http",
|
|
"isContext": false
|
|
}
|
|
}
|
|
},
|
|
"/mizan/item.formset.validate": {
|
|
"post": {
|
|
"operationId": "itemFormsetValidate",
|
|
"summary": "Call item.formset.validate",
|
|
"parameters": [],
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/itemFormsetValidateOutput"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"requestBody": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/itemFormsetValidateInput"
|
|
}
|
|
}
|
|
},
|
|
"required": true
|
|
},
|
|
"x-mizan": {
|
|
"transport": "http",
|
|
"isContext": false
|
|
}
|
|
}
|
|
},
|
|
"/mizan/item.formset.submit": {
|
|
"post": {
|
|
"operationId": "itemFormsetSubmit",
|
|
"summary": "Call item.formset.submit",
|
|
"parameters": [],
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/itemFormsetSubmitOutput"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"requestBody": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/itemFormsetSubmitInput"
|
|
}
|
|
}
|
|
},
|
|
"required": true
|
|
},
|
|
"x-mizan": {
|
|
"transport": "http",
|
|
"isContext": false
|
|
}
|
|
}
|
|
},
|
|
"/mizan/jwt_obtain": {
|
|
"post": {
|
|
"operationId": "jwtObtain",
|
|
"summary": "\nObtain JWT tokens from an authenticated session.\n\nRequires session authentication (cookie or WebSocket session).\nReturns access and refresh tokens that can be used for stateless auth.\n\nThe tokens include user claims (is_staff, is_superuser) so that\nsubsequent JWT-authenticated requests don't need a database query.\n\nUsage:\n const { access_token, refresh_token } = await call('jwt_obtain')\n // Use access_token in Authorization: Bearer header\n",
|
|
"parameters": [],
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/jwtObtainOutput"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"x-mizan": {
|
|
"transport": "http",
|
|
"isContext": false
|
|
}
|
|
}
|
|
},
|
|
"/mizan/jwt_refresh": {
|
|
"post": {
|
|
"operationId": "jwtRefresh",
|
|
"summary": "\nRefresh JWT tokens using a refresh token.\n\nDoes not require session authentication - the refresh token itself\ncontains the session reference and is validated against the session store.\n\nIf the original session has been destroyed (user logged out), this fails.\n\nUsage:\n const { access_token, refresh_token } = await call('jwt_refresh', { refresh_token })\n",
|
|
"parameters": [],
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/jwtRefreshOutput"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"requestBody": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/jwtRefreshInput"
|
|
}
|
|
}
|
|
},
|
|
"required": true
|
|
},
|
|
"x-mizan": {
|
|
"transport": "http",
|
|
"isContext": false
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"components": {
|
|
"schemas": {
|
|
"echoOutput": {
|
|
"properties": {
|
|
"message": {
|
|
"title": "Message",
|
|
"type": "string"
|
|
}
|
|
},
|
|
"required": [
|
|
"message"
|
|
],
|
|
"title": "echoOutput",
|
|
"type": "object"
|
|
},
|
|
"echoInput": {
|
|
"properties": {
|
|
"text": {
|
|
"title": "Text",
|
|
"type": "string"
|
|
}
|
|
},
|
|
"required": [
|
|
"text"
|
|
],
|
|
"title": "echoInput",
|
|
"type": "object"
|
|
},
|
|
"addOutput": {
|
|
"properties": {
|
|
"result": {
|
|
"title": "Result",
|
|
"type": "integer"
|
|
}
|
|
},
|
|
"required": [
|
|
"result"
|
|
],
|
|
"title": "addOutput",
|
|
"type": "object"
|
|
},
|
|
"addInput": {
|
|
"properties": {
|
|
"a": {
|
|
"title": "A",
|
|
"type": "integer"
|
|
},
|
|
"b": {
|
|
"title": "B",
|
|
"type": "integer"
|
|
}
|
|
},
|
|
"required": [
|
|
"a",
|
|
"b"
|
|
],
|
|
"title": "addInput",
|
|
"type": "object"
|
|
},
|
|
"whoamiOutput": {
|
|
"properties": {
|
|
"user_id": {
|
|
"anyOf": [
|
|
{
|
|
"type": "integer"
|
|
},
|
|
{
|
|
"type": "null"
|
|
}
|
|
],
|
|
"title": "User Id"
|
|
},
|
|
"email": {
|
|
"title": "Email",
|
|
"type": "string"
|
|
},
|
|
"is_staff": {
|
|
"title": "Is Staff",
|
|
"type": "boolean"
|
|
}
|
|
},
|
|
"required": [
|
|
"user_id",
|
|
"email",
|
|
"is_staff"
|
|
],
|
|
"title": "whoamiOutput",
|
|
"type": "object"
|
|
},
|
|
"httpOnlyEchoOutput": {
|
|
"properties": {
|
|
"message": {
|
|
"title": "Message",
|
|
"type": "string"
|
|
}
|
|
},
|
|
"required": [
|
|
"message"
|
|
],
|
|
"title": "httpOnlyEchoOutput",
|
|
"type": "object"
|
|
},
|
|
"httpOnlyEchoInput": {
|
|
"properties": {
|
|
"text": {
|
|
"title": "Text",
|
|
"type": "string"
|
|
}
|
|
},
|
|
"required": [
|
|
"text"
|
|
],
|
|
"title": "httpOnlyEchoInput",
|
|
"type": "object"
|
|
},
|
|
"FormSchemaField": {
|
|
"description": "Schema for a single form field.",
|
|
"properties": {
|
|
"name": {
|
|
"title": "Name",
|
|
"type": "string"
|
|
},
|
|
"type": {
|
|
"title": "Type",
|
|
"type": "string"
|
|
},
|
|
"required": {
|
|
"title": "Required",
|
|
"type": "boolean"
|
|
},
|
|
"label": {
|
|
"title": "Label",
|
|
"type": "string"
|
|
},
|
|
"help_text": {
|
|
"anyOf": [
|
|
{
|
|
"type": "string"
|
|
},
|
|
{
|
|
"type": "null"
|
|
}
|
|
],
|
|
"title": "Help Text"
|
|
},
|
|
"choices": {
|
|
"anyOf": [
|
|
{
|
|
"items": {
|
|
"maxItems": 2,
|
|
"minItems": 2,
|
|
"prefixItems": [
|
|
{
|
|
"type": "string"
|
|
},
|
|
{
|
|
"type": "string"
|
|
}
|
|
],
|
|
"type": "array"
|
|
},
|
|
"type": "array"
|
|
},
|
|
{
|
|
"type": "null"
|
|
}
|
|
],
|
|
"title": "Choices"
|
|
},
|
|
"initial": {
|
|
"title": "Initial"
|
|
}
|
|
},
|
|
"required": [
|
|
"name",
|
|
"type",
|
|
"required",
|
|
"label"
|
|
],
|
|
"title": "FormSchemaField",
|
|
"type": "object"
|
|
},
|
|
"loginSchemaOutput": {
|
|
"properties": {
|
|
"fields": {
|
|
"items": {
|
|
"$ref": "#/components/schemas/FormSchemaField"
|
|
},
|
|
"title": "Fields",
|
|
"type": "array"
|
|
}
|
|
},
|
|
"required": [
|
|
"fields"
|
|
],
|
|
"title": "loginSchemaOutput",
|
|
"type": "object"
|
|
},
|
|
"loginValidateOutput": {
|
|
"properties": {
|
|
"valid": {
|
|
"title": "Valid",
|
|
"type": "boolean"
|
|
},
|
|
"errors": {
|
|
"additionalProperties": {
|
|
"items": {
|
|
"type": "string"
|
|
},
|
|
"type": "array"
|
|
},
|
|
"title": "Errors",
|
|
"type": "object"
|
|
}
|
|
},
|
|
"required": [
|
|
"valid",
|
|
"errors"
|
|
],
|
|
"title": "loginValidateOutput",
|
|
"type": "object"
|
|
},
|
|
"loginValidateInput": {
|
|
"properties": {
|
|
"data": {
|
|
"additionalProperties": true,
|
|
"title": "Data",
|
|
"type": "object"
|
|
}
|
|
},
|
|
"required": [
|
|
"data"
|
|
],
|
|
"title": "loginValidateInput",
|
|
"type": "object"
|
|
},
|
|
"loginSubmitOutput": {
|
|
"properties": {},
|
|
"title": "loginSubmitOutput",
|
|
"type": "object"
|
|
},
|
|
"loginSubmitInput": {
|
|
"properties": {
|
|
"data": {
|
|
"additionalProperties": true,
|
|
"title": "Data",
|
|
"type": "object"
|
|
}
|
|
},
|
|
"required": [
|
|
"data"
|
|
],
|
|
"title": "loginSubmitInput",
|
|
"type": "object"
|
|
},
|
|
"signupSchemaOutput": {
|
|
"properties": {
|
|
"fields": {
|
|
"items": {
|
|
"$ref": "#/components/schemas/FormSchemaField"
|
|
},
|
|
"title": "Fields",
|
|
"type": "array"
|
|
}
|
|
},
|
|
"required": [
|
|
"fields"
|
|
],
|
|
"title": "signupSchemaOutput",
|
|
"type": "object"
|
|
},
|
|
"signupValidateOutput": {
|
|
"properties": {
|
|
"valid": {
|
|
"title": "Valid",
|
|
"type": "boolean"
|
|
},
|
|
"errors": {
|
|
"additionalProperties": {
|
|
"items": {
|
|
"type": "string"
|
|
},
|
|
"type": "array"
|
|
},
|
|
"title": "Errors",
|
|
"type": "object"
|
|
}
|
|
},
|
|
"required": [
|
|
"valid",
|
|
"errors"
|
|
],
|
|
"title": "signupValidateOutput",
|
|
"type": "object"
|
|
},
|
|
"signupValidateInput": {
|
|
"properties": {
|
|
"data": {
|
|
"additionalProperties": true,
|
|
"title": "Data",
|
|
"type": "object"
|
|
}
|
|
},
|
|
"required": [
|
|
"data"
|
|
],
|
|
"title": "signupValidateInput",
|
|
"type": "object"
|
|
},
|
|
"signupSubmitOutput": {
|
|
"properties": {},
|
|
"title": "signupSubmitOutput",
|
|
"type": "object"
|
|
},
|
|
"signupSubmitInput": {
|
|
"properties": {
|
|
"data": {
|
|
"additionalProperties": true,
|
|
"title": "Data",
|
|
"type": "object"
|
|
}
|
|
},
|
|
"required": [
|
|
"data"
|
|
],
|
|
"title": "signupSubmitInput",
|
|
"type": "object"
|
|
},
|
|
"addEmailSchemaOutput": {
|
|
"properties": {
|
|
"fields": {
|
|
"items": {
|
|
"$ref": "#/components/schemas/FormSchemaField"
|
|
},
|
|
"title": "Fields",
|
|
"type": "array"
|
|
}
|
|
},
|
|
"required": [
|
|
"fields"
|
|
],
|
|
"title": "addEmailSchemaOutput",
|
|
"type": "object"
|
|
},
|
|
"addEmailValidateOutput": {
|
|
"properties": {
|
|
"valid": {
|
|
"title": "Valid",
|
|
"type": "boolean"
|
|
},
|
|
"errors": {
|
|
"additionalProperties": {
|
|
"items": {
|
|
"type": "string"
|
|
},
|
|
"type": "array"
|
|
},
|
|
"title": "Errors",
|
|
"type": "object"
|
|
}
|
|
},
|
|
"required": [
|
|
"valid",
|
|
"errors"
|
|
],
|
|
"title": "addEmailValidateOutput",
|
|
"type": "object"
|
|
},
|
|
"addEmailValidateInput": {
|
|
"properties": {
|
|
"data": {
|
|
"additionalProperties": true,
|
|
"title": "Data",
|
|
"type": "object"
|
|
}
|
|
},
|
|
"required": [
|
|
"data"
|
|
],
|
|
"title": "addEmailValidateInput",
|
|
"type": "object"
|
|
},
|
|
"staffOnlyOutput": {
|
|
"properties": {
|
|
"message": {
|
|
"title": "Message",
|
|
"type": "string"
|
|
}
|
|
},
|
|
"required": [
|
|
"message"
|
|
],
|
|
"title": "staffOnlyOutput",
|
|
"type": "object"
|
|
},
|
|
"superuserOnlyOutput": {
|
|
"properties": {
|
|
"message": {
|
|
"title": "Message",
|
|
"type": "string"
|
|
}
|
|
},
|
|
"required": [
|
|
"message"
|
|
],
|
|
"title": "superuserOnlyOutput",
|
|
"type": "object"
|
|
},
|
|
"verifiedOnlyOutput": {
|
|
"properties": {
|
|
"message": {
|
|
"title": "Message",
|
|
"type": "string"
|
|
}
|
|
},
|
|
"required": [
|
|
"message"
|
|
],
|
|
"title": "verifiedOnlyOutput",
|
|
"type": "object"
|
|
},
|
|
"currentUserOutput": {
|
|
"properties": {
|
|
"authenticated": {
|
|
"title": "Authenticated",
|
|
"type": "boolean"
|
|
},
|
|
"email": {
|
|
"title": "Email",
|
|
"type": "string"
|
|
},
|
|
"is_staff": {
|
|
"title": "Is Staff",
|
|
"type": "boolean"
|
|
}
|
|
},
|
|
"required": [
|
|
"authenticated",
|
|
"email",
|
|
"is_staff"
|
|
],
|
|
"title": "currentUserOutput",
|
|
"type": "object"
|
|
},
|
|
"greetOutput": {
|
|
"properties": {
|
|
"greeting": {
|
|
"title": "Greeting",
|
|
"type": "string"
|
|
}
|
|
},
|
|
"required": [
|
|
"greeting"
|
|
],
|
|
"title": "greetOutput",
|
|
"type": "object"
|
|
},
|
|
"greetInput": {
|
|
"properties": {
|
|
"name": {
|
|
"title": "Name",
|
|
"type": "string"
|
|
}
|
|
},
|
|
"required": [
|
|
"name"
|
|
],
|
|
"title": "greetInput",
|
|
"type": "object"
|
|
},
|
|
"multiplyOutput": {
|
|
"properties": {
|
|
"product": {
|
|
"title": "Product",
|
|
"type": "integer"
|
|
}
|
|
},
|
|
"required": [
|
|
"product"
|
|
],
|
|
"title": "multiplyOutput",
|
|
"type": "object"
|
|
},
|
|
"multiplyInput": {
|
|
"properties": {
|
|
"x": {
|
|
"title": "X",
|
|
"type": "integer"
|
|
},
|
|
"y": {
|
|
"title": "Y",
|
|
"type": "integer"
|
|
}
|
|
},
|
|
"required": [
|
|
"x",
|
|
"y"
|
|
],
|
|
"title": "multiplyInput",
|
|
"type": "object"
|
|
},
|
|
"notImplementedFnOutput": {
|
|
"properties": {
|
|
"message": {
|
|
"title": "Message",
|
|
"type": "string"
|
|
}
|
|
},
|
|
"required": [
|
|
"message"
|
|
],
|
|
"title": "notImplementedFnOutput",
|
|
"type": "object"
|
|
},
|
|
"buggyFnOutput": {
|
|
"properties": {
|
|
"message": {
|
|
"title": "Message",
|
|
"type": "string"
|
|
}
|
|
},
|
|
"required": [
|
|
"message"
|
|
],
|
|
"title": "buggyFnOutput",
|
|
"type": "object"
|
|
},
|
|
"permissionCheckFnOutput": {
|
|
"properties": {
|
|
"message": {
|
|
"title": "Message",
|
|
"type": "string"
|
|
}
|
|
},
|
|
"required": [
|
|
"message"
|
|
],
|
|
"title": "permissionCheckFnOutput",
|
|
"type": "object"
|
|
},
|
|
"permissionCheckFnInput": {
|
|
"properties": {
|
|
"secret": {
|
|
"title": "Secret",
|
|
"type": "string"
|
|
}
|
|
},
|
|
"required": [
|
|
"secret"
|
|
],
|
|
"title": "permissionCheckFnInput",
|
|
"type": "object"
|
|
},
|
|
"wsWhoamiOutput": {
|
|
"properties": {
|
|
"user_id": {
|
|
"anyOf": [
|
|
{
|
|
"type": "integer"
|
|
},
|
|
{
|
|
"type": "null"
|
|
}
|
|
],
|
|
"title": "User Id"
|
|
},
|
|
"email": {
|
|
"title": "Email",
|
|
"type": "string"
|
|
},
|
|
"is_staff": {
|
|
"title": "Is Staff",
|
|
"type": "boolean"
|
|
}
|
|
},
|
|
"required": [
|
|
"user_id",
|
|
"email",
|
|
"is_staff"
|
|
],
|
|
"title": "wsWhoamiOutput",
|
|
"type": "object"
|
|
},
|
|
"FieldChoice": {
|
|
"properties": {
|
|
"value": {
|
|
"title": "Value",
|
|
"type": "string"
|
|
},
|
|
"label": {
|
|
"title": "Label",
|
|
"type": "string"
|
|
}
|
|
},
|
|
"required": [
|
|
"value",
|
|
"label"
|
|
],
|
|
"title": "FieldChoice",
|
|
"type": "object"
|
|
},
|
|
"FieldSchema": {
|
|
"properties": {
|
|
"name": {
|
|
"title": "Name",
|
|
"type": "string"
|
|
},
|
|
"label": {
|
|
"title": "Label",
|
|
"type": "string"
|
|
},
|
|
"type": {
|
|
"title": "Type",
|
|
"type": "string"
|
|
},
|
|
"widget": {
|
|
"title": "Widget",
|
|
"type": "string"
|
|
},
|
|
"required": {
|
|
"title": "Required",
|
|
"type": "boolean"
|
|
},
|
|
"disabled": {
|
|
"title": "Disabled",
|
|
"type": "boolean"
|
|
},
|
|
"help_text": {
|
|
"title": "Help Text",
|
|
"type": "string"
|
|
},
|
|
"initial": {
|
|
"title": "Initial"
|
|
},
|
|
"max_length": {
|
|
"anyOf": [
|
|
{
|
|
"type": "integer"
|
|
},
|
|
{
|
|
"type": "null"
|
|
}
|
|
],
|
|
"title": "Max Length"
|
|
},
|
|
"min_length": {
|
|
"anyOf": [
|
|
{
|
|
"type": "integer"
|
|
},
|
|
{
|
|
"type": "null"
|
|
}
|
|
],
|
|
"title": "Min Length"
|
|
},
|
|
"choices": {
|
|
"anyOf": [
|
|
{
|
|
"items": {
|
|
"$ref": "#/components/schemas/FieldChoice"
|
|
},
|
|
"type": "array"
|
|
},
|
|
{
|
|
"type": "null"
|
|
}
|
|
],
|
|
"title": "Choices"
|
|
}
|
|
},
|
|
"required": [
|
|
"name",
|
|
"label",
|
|
"type",
|
|
"widget",
|
|
"required",
|
|
"disabled",
|
|
"help_text",
|
|
"initial",
|
|
"max_length",
|
|
"min_length",
|
|
"choices"
|
|
],
|
|
"title": "FieldSchema",
|
|
"type": "object"
|
|
},
|
|
"FormMeta": {
|
|
"description": "Metadata controlling frontend form behavior.\n\nAttributes:\n refetch_schema_on_validate: If True, frontend should refetch schema on each\n validation (useful for dynamic choice fields). Default False.\n live_validation: If False, frontend should disable live validation entirely.\n Useful for sensitive forms like login. Default True.\n live_form_errors: If True, show form-level errors during live validation.\n Form errors are things like \"Invalid credentials\" vs field errors like\n \"This field is required\". Default False for security.",
|
|
"properties": {
|
|
"refetch_schema_on_validate": {
|
|
"default": false,
|
|
"title": "Refetch Schema On Validate",
|
|
"type": "boolean"
|
|
},
|
|
"live_validation": {
|
|
"default": true,
|
|
"title": "Live Validation",
|
|
"type": "boolean"
|
|
},
|
|
"live_form_errors": {
|
|
"default": false,
|
|
"title": "Live Form Errors",
|
|
"type": "boolean"
|
|
}
|
|
},
|
|
"title": "FormMeta",
|
|
"type": "object"
|
|
},
|
|
"contactSchemaOutput": {
|
|
"properties": {
|
|
"name": {
|
|
"title": "Name",
|
|
"type": "string"
|
|
},
|
|
"title": {
|
|
"title": "Title",
|
|
"type": "string"
|
|
},
|
|
"subtitle": {
|
|
"anyOf": [
|
|
{
|
|
"type": "string"
|
|
},
|
|
{
|
|
"type": "null"
|
|
}
|
|
],
|
|
"title": "Subtitle"
|
|
},
|
|
"submit_label": {
|
|
"title": "Submit Label",
|
|
"type": "string"
|
|
},
|
|
"fields": {
|
|
"items": {
|
|
"$ref": "#/components/schemas/FieldSchema"
|
|
},
|
|
"title": "Fields",
|
|
"type": "array"
|
|
},
|
|
"meta": {
|
|
"allOf": [
|
|
{
|
|
"$ref": "#/components/schemas/FormMeta"
|
|
}
|
|
],
|
|
"default": {
|
|
"refetch_schema_on_validate": false,
|
|
"live_validation": true,
|
|
"live_form_errors": false
|
|
}
|
|
}
|
|
},
|
|
"required": [
|
|
"name",
|
|
"title",
|
|
"subtitle",
|
|
"submit_label",
|
|
"fields"
|
|
],
|
|
"title": "contactSchemaOutput",
|
|
"type": "object"
|
|
},
|
|
"contactSchemaInput": {
|
|
"properties": {
|
|
"data": {
|
|
"additionalProperties": true,
|
|
"default": {},
|
|
"title": "Data",
|
|
"type": "object"
|
|
}
|
|
},
|
|
"title": "contactSchemaInput",
|
|
"type": "object"
|
|
},
|
|
"FieldError": {
|
|
"properties": {
|
|
"message": {
|
|
"title": "Message",
|
|
"type": "string"
|
|
},
|
|
"code": {
|
|
"anyOf": [
|
|
{
|
|
"type": "string"
|
|
},
|
|
{
|
|
"type": "null"
|
|
}
|
|
],
|
|
"title": "Code"
|
|
}
|
|
},
|
|
"required": [
|
|
"message",
|
|
"code"
|
|
],
|
|
"title": "FieldError",
|
|
"type": "object"
|
|
},
|
|
"FieldErrorList": {
|
|
"properties": {
|
|
"field": {
|
|
"title": "Field",
|
|
"type": "string"
|
|
},
|
|
"errors": {
|
|
"items": {
|
|
"$ref": "#/components/schemas/FieldError"
|
|
},
|
|
"title": "Errors",
|
|
"type": "array"
|
|
}
|
|
},
|
|
"required": [
|
|
"field",
|
|
"errors"
|
|
],
|
|
"title": "FieldErrorList",
|
|
"type": "object"
|
|
},
|
|
"contactValidateOutput": {
|
|
"properties": {
|
|
"errors": {
|
|
"items": {
|
|
"$ref": "#/components/schemas/FieldErrorList"
|
|
},
|
|
"title": "Errors",
|
|
"type": "array"
|
|
}
|
|
},
|
|
"required": [
|
|
"errors"
|
|
],
|
|
"title": "contactValidateOutput",
|
|
"type": "object"
|
|
},
|
|
"contactValidateInput": {
|
|
"properties": {
|
|
"data": {
|
|
"additionalProperties": true,
|
|
"title": "Data",
|
|
"type": "object"
|
|
}
|
|
},
|
|
"required": [
|
|
"data"
|
|
],
|
|
"title": "contactValidateInput",
|
|
"type": "object"
|
|
},
|
|
"contactSubmitOutput": {
|
|
"properties": {
|
|
"success": {
|
|
"title": "Success",
|
|
"type": "boolean"
|
|
},
|
|
"data": {
|
|
"anyOf": [
|
|
{
|
|
"additionalProperties": true,
|
|
"type": "object"
|
|
},
|
|
{
|
|
"type": "null"
|
|
}
|
|
],
|
|
"title": "Data"
|
|
}
|
|
},
|
|
"required": [
|
|
"success"
|
|
],
|
|
"title": "contactSubmitOutput",
|
|
"type": "object"
|
|
},
|
|
"itemSchemaOutput": {
|
|
"properties": {
|
|
"name": {
|
|
"title": "Name",
|
|
"type": "string"
|
|
},
|
|
"title": {
|
|
"title": "Title",
|
|
"type": "string"
|
|
},
|
|
"subtitle": {
|
|
"anyOf": [
|
|
{
|
|
"type": "string"
|
|
},
|
|
{
|
|
"type": "null"
|
|
}
|
|
],
|
|
"title": "Subtitle"
|
|
},
|
|
"submit_label": {
|
|
"title": "Submit Label",
|
|
"type": "string"
|
|
},
|
|
"fields": {
|
|
"items": {
|
|
"$ref": "#/components/schemas/FieldSchema"
|
|
},
|
|
"title": "Fields",
|
|
"type": "array"
|
|
},
|
|
"meta": {
|
|
"allOf": [
|
|
{
|
|
"$ref": "#/components/schemas/FormMeta"
|
|
}
|
|
],
|
|
"default": {
|
|
"refetch_schema_on_validate": false,
|
|
"live_validation": true,
|
|
"live_form_errors": false
|
|
}
|
|
}
|
|
},
|
|
"required": [
|
|
"name",
|
|
"title",
|
|
"subtitle",
|
|
"submit_label",
|
|
"fields"
|
|
],
|
|
"title": "itemSchemaOutput",
|
|
"type": "object"
|
|
},
|
|
"itemSchemaInput": {
|
|
"properties": {
|
|
"data": {
|
|
"additionalProperties": true,
|
|
"default": {},
|
|
"title": "Data",
|
|
"type": "object"
|
|
}
|
|
},
|
|
"title": "itemSchemaInput",
|
|
"type": "object"
|
|
},
|
|
"itemValidateOutput": {
|
|
"properties": {
|
|
"errors": {
|
|
"items": {
|
|
"$ref": "#/components/schemas/FieldErrorList"
|
|
},
|
|
"title": "Errors",
|
|
"type": "array"
|
|
}
|
|
},
|
|
"required": [
|
|
"errors"
|
|
],
|
|
"title": "itemValidateOutput",
|
|
"type": "object"
|
|
},
|
|
"itemValidateInput": {
|
|
"properties": {
|
|
"data": {
|
|
"additionalProperties": true,
|
|
"title": "Data",
|
|
"type": "object"
|
|
}
|
|
},
|
|
"required": [
|
|
"data"
|
|
],
|
|
"title": "itemValidateInput",
|
|
"type": "object"
|
|
},
|
|
"itemSubmitOutput": {
|
|
"properties": {
|
|
"success": {
|
|
"title": "Success",
|
|
"type": "boolean"
|
|
},
|
|
"data": {
|
|
"anyOf": [
|
|
{
|
|
"additionalProperties": true,
|
|
"type": "object"
|
|
},
|
|
{
|
|
"type": "null"
|
|
}
|
|
],
|
|
"title": "Data"
|
|
}
|
|
},
|
|
"required": [
|
|
"success"
|
|
],
|
|
"title": "itemSubmitOutput",
|
|
"type": "object"
|
|
},
|
|
"FormSchema": {
|
|
"description": "Schema returned by /schema endpoint with form metadata and fields.",
|
|
"properties": {
|
|
"name": {
|
|
"title": "Name",
|
|
"type": "string"
|
|
},
|
|
"title": {
|
|
"title": "Title",
|
|
"type": "string"
|
|
},
|
|
"subtitle": {
|
|
"anyOf": [
|
|
{
|
|
"type": "string"
|
|
},
|
|
{
|
|
"type": "null"
|
|
}
|
|
],
|
|
"title": "Subtitle"
|
|
},
|
|
"submit_label": {
|
|
"title": "Submit Label",
|
|
"type": "string"
|
|
},
|
|
"fields": {
|
|
"items": {
|
|
"$ref": "#/components/schemas/FieldSchema"
|
|
},
|
|
"title": "Fields",
|
|
"type": "array"
|
|
},
|
|
"meta": {
|
|
"allOf": [
|
|
{
|
|
"$ref": "#/components/schemas/FormMeta"
|
|
}
|
|
],
|
|
"default": {
|
|
"refetch_schema_on_validate": false,
|
|
"live_validation": true,
|
|
"live_form_errors": false
|
|
}
|
|
}
|
|
},
|
|
"required": [
|
|
"name",
|
|
"title",
|
|
"subtitle",
|
|
"submit_label",
|
|
"fields"
|
|
],
|
|
"title": "FormSchema",
|
|
"type": "object"
|
|
},
|
|
"itemFormsetSchemaOutput": {
|
|
"properties": {
|
|
"forms": {
|
|
"items": {
|
|
"$ref": "#/components/schemas/FormSchema"
|
|
},
|
|
"title": "Forms",
|
|
"type": "array"
|
|
},
|
|
"min_num": {
|
|
"title": "Min Num",
|
|
"type": "integer"
|
|
},
|
|
"max_num": {
|
|
"title": "Max Num",
|
|
"type": "integer"
|
|
},
|
|
"can_delete": {
|
|
"title": "Can Delete",
|
|
"type": "boolean"
|
|
},
|
|
"can_order": {
|
|
"title": "Can Order",
|
|
"type": "boolean"
|
|
}
|
|
},
|
|
"required": [
|
|
"forms",
|
|
"min_num",
|
|
"max_num",
|
|
"can_delete",
|
|
"can_order"
|
|
],
|
|
"title": "itemFormsetSchemaOutput",
|
|
"type": "object"
|
|
},
|
|
"itemFormsetSchemaInput": {
|
|
"properties": {
|
|
"forms": {
|
|
"default": [],
|
|
"items": {
|
|
"additionalProperties": true,
|
|
"type": "object"
|
|
},
|
|
"title": "Forms",
|
|
"type": "array"
|
|
}
|
|
},
|
|
"title": "itemFormsetSchemaInput",
|
|
"type": "object"
|
|
},
|
|
"FormValidation": {
|
|
"properties": {
|
|
"errors": {
|
|
"items": {
|
|
"$ref": "#/components/schemas/FieldErrorList"
|
|
},
|
|
"title": "Errors",
|
|
"type": "array"
|
|
}
|
|
},
|
|
"required": [
|
|
"errors"
|
|
],
|
|
"title": "FormValidation",
|
|
"type": "object"
|
|
},
|
|
"itemFormsetValidateOutput": {
|
|
"properties": {
|
|
"general": {
|
|
"items": {
|
|
"type": "string"
|
|
},
|
|
"title": "General",
|
|
"type": "array"
|
|
},
|
|
"per_form": {
|
|
"items": {
|
|
"$ref": "#/components/schemas/FormValidation"
|
|
},
|
|
"title": "Per Form",
|
|
"type": "array"
|
|
}
|
|
},
|
|
"required": [
|
|
"general",
|
|
"per_form"
|
|
],
|
|
"title": "itemFormsetValidateOutput",
|
|
"type": "object"
|
|
},
|
|
"itemFormsetValidateInput": {
|
|
"properties": {
|
|
"forms": {
|
|
"items": {
|
|
"additionalProperties": true,
|
|
"type": "object"
|
|
},
|
|
"title": "Forms",
|
|
"type": "array"
|
|
}
|
|
},
|
|
"required": [
|
|
"forms"
|
|
],
|
|
"title": "itemFormsetValidateInput",
|
|
"type": "object"
|
|
},
|
|
"itemFormsetSubmitOutput": {
|
|
"properties": {
|
|
"success": {
|
|
"title": "Success",
|
|
"type": "boolean"
|
|
}
|
|
},
|
|
"required": [
|
|
"success"
|
|
],
|
|
"title": "itemFormsetSubmitOutput",
|
|
"type": "object"
|
|
},
|
|
"itemFormsetSubmitInput": {
|
|
"properties": {
|
|
"forms": {
|
|
"items": {
|
|
"additionalProperties": true,
|
|
"type": "object"
|
|
},
|
|
"title": "Forms",
|
|
"type": "array"
|
|
}
|
|
},
|
|
"required": [
|
|
"forms"
|
|
],
|
|
"title": "itemFormsetSubmitInput",
|
|
"type": "object"
|
|
},
|
|
"jwtObtainOutput": {
|
|
"properties": {
|
|
"access_token": {
|
|
"title": "Access Token",
|
|
"type": "string"
|
|
},
|
|
"refresh_token": {
|
|
"title": "Refresh Token",
|
|
"type": "string"
|
|
},
|
|
"expires_in": {
|
|
"title": "Expires In",
|
|
"type": "integer"
|
|
}
|
|
},
|
|
"required": [
|
|
"access_token",
|
|
"refresh_token",
|
|
"expires_in"
|
|
],
|
|
"title": "jwtObtainOutput",
|
|
"type": "object"
|
|
},
|
|
"jwtRefreshOutput": {
|
|
"properties": {
|
|
"access_token": {
|
|
"title": "Access Token",
|
|
"type": "string"
|
|
},
|
|
"refresh_token": {
|
|
"title": "Refresh Token",
|
|
"type": "string"
|
|
},
|
|
"expires_in": {
|
|
"title": "Expires In",
|
|
"type": "integer"
|
|
}
|
|
},
|
|
"required": [
|
|
"access_token",
|
|
"refresh_token",
|
|
"expires_in"
|
|
],
|
|
"title": "jwtRefreshOutput",
|
|
"type": "object"
|
|
},
|
|
"jwtRefreshInput": {
|
|
"properties": {
|
|
"refresh_token": {
|
|
"title": "Refresh Token",
|
|
"type": "string"
|
|
}
|
|
},
|
|
"required": [
|
|
"refresh_token"
|
|
],
|
|
"title": "jwtRefreshInput",
|
|
"type": "object"
|
|
}
|
|
}
|
|
},
|
|
"servers": [],
|
|
"x-mizan-functions": [
|
|
{
|
|
"name": "echo",
|
|
"camelName": "echo",
|
|
"hasInput": true,
|
|
"inputType": "echoInput",
|
|
"outputType": "echoOutput",
|
|
"transport": "websocket",
|
|
"isContext": false,
|
|
"isForm": false,
|
|
"formName": null,
|
|
"formRole": null
|
|
},
|
|
{
|
|
"name": "add",
|
|
"camelName": "add",
|
|
"hasInput": true,
|
|
"inputType": "addInput",
|
|
"outputType": "addOutput",
|
|
"transport": "websocket",
|
|
"isContext": false,
|
|
"isForm": false,
|
|
"formName": null,
|
|
"formRole": null
|
|
},
|
|
{
|
|
"name": "whoami",
|
|
"camelName": "whoami",
|
|
"hasInput": false,
|
|
"inputType": null,
|
|
"outputType": "whoamiOutput",
|
|
"transport": "http",
|
|
"isContext": false,
|
|
"isForm": false,
|
|
"formName": null,
|
|
"formRole": null
|
|
},
|
|
{
|
|
"name": "http_only_echo",
|
|
"camelName": "httpOnlyEcho",
|
|
"hasInput": true,
|
|
"inputType": "httpOnlyEchoInput",
|
|
"outputType": "httpOnlyEchoOutput",
|
|
"transport": "http",
|
|
"isContext": false,
|
|
"isForm": false,
|
|
"formName": null,
|
|
"formRole": null
|
|
},
|
|
{
|
|
"name": "login.schema",
|
|
"camelName": "loginSchema",
|
|
"hasInput": false,
|
|
"inputType": null,
|
|
"outputType": "loginSchemaOutput",
|
|
"transport": "http",
|
|
"isContext": false,
|
|
"isForm": true,
|
|
"formName": "login",
|
|
"formRole": "schema"
|
|
},
|
|
{
|
|
"name": "login.validate",
|
|
"camelName": "loginValidate",
|
|
"hasInput": true,
|
|
"inputType": "loginValidateInput",
|
|
"outputType": "loginValidateOutput",
|
|
"transport": "http",
|
|
"isContext": false,
|
|
"isForm": true,
|
|
"formName": "login",
|
|
"formRole": "validate"
|
|
},
|
|
{
|
|
"name": "login.submit",
|
|
"camelName": "loginSubmit",
|
|
"hasInput": true,
|
|
"inputType": "loginSubmitInput",
|
|
"outputType": "loginSubmitOutput",
|
|
"transport": "http",
|
|
"isContext": false,
|
|
"isForm": true,
|
|
"formName": "login",
|
|
"formRole": "submit"
|
|
},
|
|
{
|
|
"name": "signup.schema",
|
|
"camelName": "signupSchema",
|
|
"hasInput": false,
|
|
"inputType": null,
|
|
"outputType": "signupSchemaOutput",
|
|
"transport": "http",
|
|
"isContext": false,
|
|
"isForm": true,
|
|
"formName": "signup",
|
|
"formRole": "schema"
|
|
},
|
|
{
|
|
"name": "signup.validate",
|
|
"camelName": "signupValidate",
|
|
"hasInput": true,
|
|
"inputType": "signupValidateInput",
|
|
"outputType": "signupValidateOutput",
|
|
"transport": "http",
|
|
"isContext": false,
|
|
"isForm": true,
|
|
"formName": "signup",
|
|
"formRole": "validate"
|
|
},
|
|
{
|
|
"name": "signup.submit",
|
|
"camelName": "signupSubmit",
|
|
"hasInput": true,
|
|
"inputType": "signupSubmitInput",
|
|
"outputType": "signupSubmitOutput",
|
|
"transport": "http",
|
|
"isContext": false,
|
|
"isForm": true,
|
|
"formName": "signup",
|
|
"formRole": "submit"
|
|
},
|
|
{
|
|
"name": "add_email.schema",
|
|
"camelName": "addEmailSchema",
|
|
"hasInput": false,
|
|
"inputType": null,
|
|
"outputType": "addEmailSchemaOutput",
|
|
"transport": "http",
|
|
"isContext": false,
|
|
"isForm": true,
|
|
"formName": "add_email",
|
|
"formRole": "schema"
|
|
},
|
|
{
|
|
"name": "add_email.validate",
|
|
"camelName": "addEmailValidate",
|
|
"hasInput": true,
|
|
"inputType": "addEmailValidateInput",
|
|
"outputType": "addEmailValidateOutput",
|
|
"transport": "http",
|
|
"isContext": false,
|
|
"isForm": true,
|
|
"formName": "add_email",
|
|
"formRole": "validate"
|
|
},
|
|
{
|
|
"name": "staff_only",
|
|
"camelName": "staffOnly",
|
|
"hasInput": false,
|
|
"inputType": null,
|
|
"outputType": "staffOnlyOutput",
|
|
"transport": "http",
|
|
"isContext": false,
|
|
"isForm": false,
|
|
"formName": null,
|
|
"formRole": null
|
|
},
|
|
{
|
|
"name": "superuser_only",
|
|
"camelName": "superuserOnly",
|
|
"hasInput": false,
|
|
"inputType": null,
|
|
"outputType": "superuserOnlyOutput",
|
|
"transport": "http",
|
|
"isContext": false,
|
|
"isForm": false,
|
|
"formName": null,
|
|
"formRole": null
|
|
},
|
|
{
|
|
"name": "verified_only",
|
|
"camelName": "verifiedOnly",
|
|
"hasInput": false,
|
|
"inputType": null,
|
|
"outputType": "verifiedOnlyOutput",
|
|
"transport": "http",
|
|
"isContext": false,
|
|
"isForm": false,
|
|
"formName": null,
|
|
"formRole": null
|
|
},
|
|
{
|
|
"name": "current_user",
|
|
"camelName": "currentUser",
|
|
"hasInput": false,
|
|
"inputType": null,
|
|
"outputType": "currentUserOutput",
|
|
"transport": "http",
|
|
"isContext": "global",
|
|
"isForm": false,
|
|
"formName": null,
|
|
"formRole": null
|
|
},
|
|
{
|
|
"name": "greet",
|
|
"camelName": "greet",
|
|
"hasInput": true,
|
|
"inputType": "greetInput",
|
|
"outputType": "greetOutput",
|
|
"transport": "http",
|
|
"isContext": "local",
|
|
"isForm": false,
|
|
"formName": null,
|
|
"formRole": null
|
|
},
|
|
{
|
|
"name": "multiply",
|
|
"camelName": "multiply",
|
|
"hasInput": true,
|
|
"inputType": "multiplyInput",
|
|
"outputType": "multiplyOutput",
|
|
"transport": "http",
|
|
"isContext": false,
|
|
"isForm": false,
|
|
"formName": null,
|
|
"formRole": null
|
|
},
|
|
{
|
|
"name": "not_implemented_fn",
|
|
"camelName": "notImplementedFn",
|
|
"hasInput": false,
|
|
"inputType": null,
|
|
"outputType": "notImplementedFnOutput",
|
|
"transport": "http",
|
|
"isContext": false,
|
|
"isForm": false,
|
|
"formName": null,
|
|
"formRole": null
|
|
},
|
|
{
|
|
"name": "buggy_fn",
|
|
"camelName": "buggyFn",
|
|
"hasInput": false,
|
|
"inputType": null,
|
|
"outputType": "buggyFnOutput",
|
|
"transport": "http",
|
|
"isContext": false,
|
|
"isForm": false,
|
|
"formName": null,
|
|
"formRole": null
|
|
},
|
|
{
|
|
"name": "permission_check_fn",
|
|
"camelName": "permissionCheckFn",
|
|
"hasInput": true,
|
|
"inputType": "permissionCheckFnInput",
|
|
"outputType": "permissionCheckFnOutput",
|
|
"transport": "http",
|
|
"isContext": false,
|
|
"isForm": false,
|
|
"formName": null,
|
|
"formRole": null
|
|
},
|
|
{
|
|
"name": "ws_whoami",
|
|
"camelName": "wsWhoami",
|
|
"hasInput": false,
|
|
"inputType": null,
|
|
"outputType": "wsWhoamiOutput",
|
|
"transport": "websocket",
|
|
"isContext": false,
|
|
"isForm": false,
|
|
"formName": null,
|
|
"formRole": null
|
|
},
|
|
{
|
|
"name": "contact.schema",
|
|
"camelName": "contactSchema",
|
|
"hasInput": true,
|
|
"inputType": "contactSchemaInput",
|
|
"outputType": "contactSchemaOutput",
|
|
"transport": "http",
|
|
"isContext": false,
|
|
"isForm": true,
|
|
"formName": "contact",
|
|
"formRole": "schema",
|
|
"formFields": [
|
|
{
|
|
"name": "name",
|
|
"required": true,
|
|
"constraints": {
|
|
"max": 100
|
|
},
|
|
"zodType": "string"
|
|
},
|
|
{
|
|
"name": "email",
|
|
"required": true,
|
|
"constraints": {
|
|
"max": 320,
|
|
"email": true
|
|
},
|
|
"zodType": "string"
|
|
},
|
|
{
|
|
"name": "message",
|
|
"required": true,
|
|
"constraints": {},
|
|
"zodType": "string"
|
|
}
|
|
]
|
|
},
|
|
{
|
|
"name": "contact.validate",
|
|
"camelName": "contactValidate",
|
|
"hasInput": true,
|
|
"inputType": "contactValidateInput",
|
|
"outputType": "contactValidateOutput",
|
|
"transport": "http",
|
|
"isContext": false,
|
|
"isForm": true,
|
|
"formName": "contact",
|
|
"formRole": "validate"
|
|
},
|
|
{
|
|
"name": "contact.submit",
|
|
"camelName": "contactSubmit",
|
|
"hasInput": false,
|
|
"inputType": null,
|
|
"outputType": "contactSubmitOutput",
|
|
"transport": "http",
|
|
"isContext": false,
|
|
"isForm": true,
|
|
"formName": "contact",
|
|
"formRole": "submit"
|
|
},
|
|
{
|
|
"name": "item.schema",
|
|
"camelName": "itemSchema",
|
|
"hasInput": true,
|
|
"inputType": "itemSchemaInput",
|
|
"outputType": "itemSchemaOutput",
|
|
"transport": "http",
|
|
"isContext": false,
|
|
"isForm": true,
|
|
"formName": "item",
|
|
"formRole": "schema",
|
|
"formFields": [
|
|
{
|
|
"name": "label",
|
|
"required": true,
|
|
"constraints": {
|
|
"max": 50
|
|
},
|
|
"zodType": "string"
|
|
},
|
|
{
|
|
"name": "quantity",
|
|
"required": true,
|
|
"constraints": {
|
|
"int": true,
|
|
"min": 1
|
|
},
|
|
"zodType": "number"
|
|
}
|
|
]
|
|
},
|
|
{
|
|
"name": "item.validate",
|
|
"camelName": "itemValidate",
|
|
"hasInput": true,
|
|
"inputType": "itemValidateInput",
|
|
"outputType": "itemValidateOutput",
|
|
"transport": "http",
|
|
"isContext": false,
|
|
"isForm": true,
|
|
"formName": "item",
|
|
"formRole": "validate"
|
|
},
|
|
{
|
|
"name": "item.submit",
|
|
"camelName": "itemSubmit",
|
|
"hasInput": false,
|
|
"inputType": null,
|
|
"outputType": "itemSubmitOutput",
|
|
"transport": "http",
|
|
"isContext": false,
|
|
"isForm": true,
|
|
"formName": "item",
|
|
"formRole": "submit"
|
|
},
|
|
{
|
|
"name": "item.formset.schema",
|
|
"camelName": "itemFormsetSchema",
|
|
"hasInput": true,
|
|
"inputType": "itemFormsetSchemaInput",
|
|
"outputType": "itemFormsetSchemaOutput",
|
|
"transport": "http",
|
|
"isContext": false,
|
|
"isForm": true,
|
|
"formName": "item",
|
|
"formRole": "formset_schema"
|
|
},
|
|
{
|
|
"name": "item.formset.validate",
|
|
"camelName": "itemFormsetValidate",
|
|
"hasInput": true,
|
|
"inputType": "itemFormsetValidateInput",
|
|
"outputType": "itemFormsetValidateOutput",
|
|
"transport": "http",
|
|
"isContext": false,
|
|
"isForm": true,
|
|
"formName": "item",
|
|
"formRole": "formset_validate"
|
|
},
|
|
{
|
|
"name": "item.formset.submit",
|
|
"camelName": "itemFormsetSubmit",
|
|
"hasInput": true,
|
|
"inputType": "itemFormsetSubmitInput",
|
|
"outputType": "itemFormsetSubmitOutput",
|
|
"transport": "http",
|
|
"isContext": false,
|
|
"isForm": true,
|
|
"formName": "item",
|
|
"formRole": "formset_submit"
|
|
},
|
|
{
|
|
"name": "jwt_obtain",
|
|
"camelName": "jwtObtain",
|
|
"hasInput": false,
|
|
"inputType": null,
|
|
"outputType": "jwtObtainOutput",
|
|
"transport": "http",
|
|
"isContext": false,
|
|
"isForm": false,
|
|
"formName": null,
|
|
"formRole": null
|
|
},
|
|
{
|
|
"name": "jwt_refresh",
|
|
"camelName": "jwtRefresh",
|
|
"hasInput": true,
|
|
"inputType": "jwtRefreshInput",
|
|
"outputType": "jwtRefreshOutput",
|
|
"transport": "http",
|
|
"isContext": false,
|
|
"isForm": false,
|
|
"formName": null,
|
|
"formRole": null
|
|
}
|
|
]
|
|
} |