-
Notifications
You must be signed in to change notification settings - Fork 0
Pronouns Management API
M♢NTΛSIM edited this page Aug 17, 2024
·
1 revision
-
POST
/
- Summary: Creates a new set of pronouns, accessible only to users with admin permissions.
- Security: Bearer Authentication
-
Request Body:
-
Content-Type:
application/json
-
Schema:
{ "type": "object", "properties": { "name": { "type": "string", "description": "The name of the pronouns set." } } }
-
Content-Type:
-
Responses:
- 201 Created: Pronouns created successfully.
- 400 Bad Request: Bad request, e.g., missing name or pronouns already exist.
-
Tags:
- Pronouns Management
-
GET
/
- Summary: Retrieves a list of all pronouns, results can be cached.
-
Responses:
- 200 OK: A list of pronouns.
-
Tags:
- Pronouns Management
-
DELETE
/
- Summary: Deletes a list of pronouns based on their IDs, accessible only to admin users.
- Security: Bearer Authentication
-
Request Body:
-
Content-Type:
application/json
-
Schema:
{ "type": "array", "items": { "type": "string" }, "description": "Array of pronouns IDs to delete." }
-
Content-Type:
-
Responses:
- 200 OK: Pronouns deleted successfully.
- 400 Bad Request: Bad request, e.g., some IDs do not exist.
-
Tags:
- Pronouns Management
-
GET
/{id}
- Summary: Retrieves a single set of pronouns by ID, results can be cached.
-
Parameters:
-
Path Parameter:
-
Name:
id
- Description: The ID of the pronouns to retrieve.
-
Schema:
{ "type": "string" }
-
Name:
-
Path Parameter:
-
Responses:
- 200 OK: Pronouns retrieved successfully.
- 404 Not Found: Pronouns not found.
-
Tags:
- Pronouns Management
-
PUT
/{id}
- Summary: Updates an existing set of pronouns by ID, accessible only to admin users.
- Security: Bearer Authentication
-
Parameters:
-
Path Parameter:
-
Name:
id
- Description: The ID of the pronouns to update.
-
Schema:
{ "type": "string" }
-
Name:
-
Path Parameter:
-
Request Body:
-
Content-Type:
application/json
-
Schema:
{ "type": "object", "properties": { "name": { "type": "string", "description": "The new name for the pronouns set." } } }
-
Content-Type:
-
Responses:
- 200 OK: Pronouns updated successfully.
- 404 Not Found: Pronouns not found.
- 400 Bad Request: Bad request, e.g., duplicate name.
-
Tags:
- Pronouns Management
-
DELETE
/{id}
- Summary: Deletes a single set of pronouns by ID, accessible only to admin users.
- Security: Bearer Authentication
-
Parameters:
-
Path Parameter:
-
Name:
id
- Description: The ID of the pronouns to delete.
-
Schema:
{ "type": "string" }
-
Name:
-
Path Parameter:
-
Responses:
- 200 OK: Pronouns deleted successfully.
- 404 Not Found: Pronouns not found.
-
Tags:
- Pronouns Management
-
All Other Methods on
/
and/{id}
- Summary: Handles unsupported methods for the respective endpoints.
-
Responses:
- 405 Method Not Allowed: HTTP method not supported.
-
Tags:
- Pronouns Management