V1 / Shaders / Index

Create a shader

Submit a GLSL fragment body plus a typed input manifest. The shader is vetted before anything is stored: byte caps, a static policy scan, loop normalisation to constant bounds, a cost model, then a real compile and fuzz render inside a sandboxed child process. A rejected submission returns 422 with the stage-by-stage report and is not saved.

POST/api/v1/shaders/index

Responses

200

JSON { doc, report } — the stored shader and its vetting report

401

Not logged in

422

Rejected by vetting; data.report explains which stage refused

Request
curl -X POST "http://localhost:3000/api/v1/shaders/index" \
  -H "Content-Type: application/json" \
  -H "Authorization: Bearer YOUR_API_TOKEN" \
  -d '{}'
Response
// JSON { doc, report } — the stored shader and its vetting report
{
  "success": true,
  "data": { ... }
}

Scale your creative process