REST API
Create a subject
Fails on a name already in active use.
Required scopes: subjects:create
AuthorizationBearer <token>
In: header
Header Parameters
Idempotency-Key?string
A client-generated key (1 to 255 visible ASCII characters) that makes this POST safe to retry. A retry with the same key and body replays the original response; the same key with a different body returns 409 idempotency_conflict. Stored for 24 hours.
Match
^[\x21-\x7E]{1,255}$Length
1 <= length <= 255Request Body
application/json
TypeScript Definitions
Use the request body type in TypeScript.
Response Body
application/json
application/json
application/json
application/json
application/json
application/json
application/json
application/json
application/json
curl -X POST "https://example.com/subjects" \ -H "Content-Type: application/json" \ -d '{ "name": "string" }'{ "data": { "id": "5f0c1d2e-3a4b-4c5d-8e6f-7a8b9c0d1e2f", "name": "Chemistry", "teachers": [ "Dr. Curie" ], "period": "Year 12", "archived": false }}