Content Libraries
Manage and schedule content delivery — daily tips, quotes, articles, and more.
Content libraries let you manage collections of content items (tips, quotes, affirmations, articles) and deliver them to users on a schedule. Great for apps that need daily content rotation.
How it works
- Create a content library (e.g., "Daily Motivation", "Workout Tips")
- Add content items to the library with text, media, categories, and tags
- Create a delivery schedule to control when and how items are delivered
- The client SDK fetches today's content or browses the full library
SDK usage
Get today's content
Browse a library
Get a single item
Create, update, and delete items from the client
The SDK exposes write endpoints for user-owned content. The server stamps owner_app_user_id from the current session — the caller cannot set it. updateItem and deleteItem return 404 when the target item isn't owned by the current user.
CreateContentItemInput:
UpdateContentItemInput:
Client API reference
| Method | Path | Description |
|---|---|---|
GET | /client/content/today | Today's scheduled content items. |
GET | /client/content/libraries/:id/items | List items in a library (query: category, limit, offset). |
GET | /client/content/items/:id | Fetch a single item. |
POST | /client/content/libraries/:id/items | Create an item owned by the current user. |
PATCH | /client/content/items/:id | Update an item owned by the current user. |
DELETE | /client/content/items/:id | Delete an item owned by the current user. |
Admin API reference
Libraries
| Method | Path | Description |
|---|---|---|
POST | /admin/content/libraries | Create library |
GET | /admin/content/libraries | List libraries with item counts |
Items
| Method | Path | Description |
|---|---|---|
POST | /admin/content/libraries/:id/items | Add items to library |
GET | /admin/content/libraries/:id/items | List items (paginated) |
PATCH | /admin/content/items/:id | Update an item |
DELETE | /admin/content/items/:id | Delete an item |
POST | /admin/content/libraries/:id/bulk | Bulk import items |
Schedules
| Method | Path | Description |
|---|---|---|
POST | /admin/content/schedules | Create delivery schedule |
GET | /admin/content/schedules | List schedules |
PATCH | /admin/content/schedules/:id | Update schedule |
POST /admin/content/libraries/:id/items
Body:
Schedule types
| Type | Description |
|---|---|
daily_rotation | Rotates through items one per day |
weekly | Delivers one item per week |
random | Picks a random item each delivery |
sequential | Delivers items in sort order |
MCP tools
| Tool | Description |
|---|---|
amba_create_content_library | Create a content library |
amba_add_content_items | Add items to a library |
amba_create_content_schedule | Set up a delivery schedule |
Example: Daily affirmations
Database tables
| Table | Purpose |
|---|---|
content_libraries | Library definitions with name and description |
content_items | Individual items with body, media, category, tags, premium flag |
content_schedules | Delivery schedules with type and config |
content_deliveries | Delivery log tracking which items were delivered when |