Seed Culture Sensitivity Antibiotics (v1)
Method & Path
POST /api/v1/workspace/:workspaceId/labs/culture-sensitivity-antibiotics/seed
Actual backend path: /v1/workspace/:workspaceId/labs/culture-sensitivity-antibiotics/seed
Description
Seed culture sensitivity antibiotics from the default JSON file. Upserts items by name for the workspace (adds missing, updates existing).
Authentication
Required: JWT token in Authorization header
Required Permissions:
labs.manage
Headers
| Header | Type | Required | Description |
|---|---|---|---|
Authorization | string | Yes | Bearer token: Bearer <token> |
Path Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
workspaceId | string | Yes | Workspace identifier (MongoDB ObjectId) |
Response 200 OK
{
"success": true,
"count": 32,
"message": "Successfully seeded 32 culture sensitivity antibiotics"
}
| Field | Type | Description |
|---|---|---|
success | boolean | Indicates if the operation was successful |
count | number | Number of items seeded |
message | string | Success message |
Common Errors
401 Unauthorized: Missing or invalid authentication token
403 Forbidden: Insufficient permissions (labs.manage required) or subscription expired
404 Not Found: Workspace not found
422 Validation Error: Invalid workspace ID format
500 Internal Server Error: Error during seeding (e.g. seed file not found)