{"openapi":"3.1.0","info":{"title":"Clarity Developer Sandbox API","version":"2026-08-12","description":"A bounded sandbox API for approved Clarity Developer Program members. Sandbox operations never expose another person's Clarity data or execute external tool code."},"servers":[{"url":"https://clarity.audecius.com/api/developer/v1","description":"Clarity sandbox"}],"security":[{"bearerAuth":[]}],"paths":{"/status":{"get":{"operationId":"getProjectStatus","summary":"Inspect the authenticated sandbox project","responses":{"200":{"description":"Project status"},"401":{"description":"Invalid, expired, or revoked key"},"429":{"description":"Rate limit exceeded"}}}},"/profile":{"get":{"operationId":"getDeveloperProfile","summary":"Inspect the authenticated Developer project boundary","responses":{"200":{"description":"Developer project profile and explicit data boundaries"},"401":{"description":"Invalid, expired, or revoked key"},"403":{"description":"profile.read scope required"}}}},"/sessions":{"get":{"operationId":"listDeveloperSessions","summary":"List Developer learning sessions","responses":{"200":{"description":"Developer learning catalogue; never private Clarity sessions"},"401":{"description":"Invalid, expired, or revoked key"},"403":{"description":"sessions.read scope required"}}}},"/tools/validate":{"post":{"operationId":"validateTool","summary":"Validate a clarity.tool/v1 manifest","requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ToolRequest"}}}},"responses":{"200":{"description":"Valid manifest"},"422":{"description":"Manifest validation errors"}}}},"/tools/preview":{"post":{"operationId":"previewTool","summary":"Build a non-executing review preview","requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ToolRequest"}}}},"responses":{"200":{"description":"Bounded preview"},"422":{"description":"Manifest validation errors"}}}},"/webhooks/test":{"post":{"operationId":"createWebhookTest","summary":"Generate a signed sandbox webhook specimen","requestBody":{"required":false,"content":{"application/json":{"schema":{"type":"object","properties":{"message":{"type":"string","maxLength":200}},"additionalProperties":false}}}},"responses":{"200":{"description":"Signed webhook specimen"}}}}},"components":{"securitySchemes":{"bearerAuth":{"type":"http","scheme":"bearer","bearerFormat":"clt_test_…","description":"A one-time-visible sandbox key. Keep it on your server."}},"schemas":{"ToolRequest":{"type":"object","required":["manifest"],"additionalProperties":false,"properties":{"manifest":{"type":"object","required":["schema","entry","permissions"],"properties":{"schema":{"const":"clarity.tool/v1"},"name":{"type":"string"},"version":{"type":"string"},"entry":{"type":"string"},"summary":{"type":"string"},"permissions":{"type":"array","items":{"type":"string","enum":["profile.read","sessions.read"]}},"consequenceClass":{"enum":["C0","C1","C2"]},"inputs":{"type":"object"},"outputs":{"type":"object"},"display":{"type":"object","description":"Optional native Clarity layout. No executable code.","required":["layout","icon","color","columns"],"additionalProperties":false,"properties":{"layout":{"enum":["table","routine","habit","counter","list","timer"]},"icon":{"type":"string","pattern":"^[a-z0-9.-]{2,80}$"},"color":{"enum":["red","orange","yellow","green","mint","teal","cyan","blue","indigo","purple","pink","brown"]},"primaryColumnIndex":{"type":"integer","minimum":0,"maximum":23},"columns":{"type":"array","minItems":1,"maxItems":24,"items":{"type":"object","required":["name","type"],"properties":{"name":{"type":"string","minLength":1,"maxLength":80},"type":{"enum":["text","number","toggle","date","rating","select","timer","photo","progress","currency","unit","multiSelect","link","color","location"]},"options":{"type":"array","items":{"type":"string"}},"section":{"type":"string"},"unit":{"type":"string"}}}}}}}}}}}}}