Schema
This endpoint group provides functionality to dynamically retrieve Zod schemas defined within the AppBuilder application. This allows external clients to understand the expected data structures for various API calls or data models.
Endpoints
POST /api/rpc (Method: SchemaServer.getSchema)
Description: Retrieves a Zod schema by path.
Request Body:
{ "method": "SchemaServer.getSchema", "params": { "schemaPath": "string" } }Parameters:
Name Type Required Description schemaPathStringYes The relative path to the schema file within the common/schemasdirectory of the application (e.g.,user/UserSchema, without the.jsextension).Response:
{ "success": true, "data": { // A JSON representation of the requested Zod schema. // The structure will vary depending on the schema requested. } }Example (cURL):
curl -X POST https://api.example.com/api/rpc \ -H "Content-Type: application/json" \ -H "X-API-Key: YOUR_API_KEY" \ -d '{ "method": "SchemaServer.getSchema", "params": { "schemaPath": "user/UserSchema" } }'