POST /api/collections/
Create a new collection.
Expects JSON with ``name`` (required) and optional ``type`` (manual|smart)
and ``filter_rule``.
Creates a new collection resource using the provided name, type, and optional filtering rules.
Endpoint
POST /api/collections/
Request Body
| Field | Type | Description |
|---|---|---|
| name | string | The required display name for the new collection. |
| type | string | The collection type, which can be 'manual' for user-curated lists or 'smart' for rule-based lists. |
| filter_rule | string | The logic or criteria used to automatically populate the collection if the type is set to 'smart'. |
Response
| Status | Description |
|---|---|
| 201 | The collection was successfully created. Returns object. |
| 400 | The request was invalid or the collection could not be created due to a business logic error. Returns object. |