| name | bkend-cookbook |
| classification | C |
| description | bkend.ai practical project tutorials and troubleshooting guide.
Covers 4 full-guide projects (blog, recipe-app, shopping-mall, social-network)
with step-by-step implementation patterns including schema design,
architecture patterns, and AI prompt collections.
Triggers: cookbook, tutorial, example project, todo app, blog app, shopping mall,
쿡북, 튜토리얼, 예제, 블로그, 쇼핑몰, 투두, 프로젝트 만들기,
クックブック, チュートリアル, 例題, ブログ, ショッピング,
食谱, 教程, 示例, 博客, 商城,
libro de cocina, tutorial, ejemplo, blog, tienda,
livre de recettes, tutoriel, exemple, blog, boutique,
Kochbuch, Tutorial, Beispiel, Blog, Shop,
ricettario, tutorial, esempio, blog, negozio
Do NOT use for: authentication details (use bkend-auth), database specifics (use bkend-data),
security policies (use bkend-security)
|
| user-invocable | true |
| argument-hint | |
| allowed-tools | ["read_file","write_file","replace","glob","grep_search","run_shell_command","web_fetch"] |
| imports | [] |
| agents | {"backend":"bkend-expert"} |
| context | session |
| memory | project |
| pdca-phase | all |
bkend-cookbook
bkend.ai practical project tutorials and troubleshooting guide
1. Projects Overview
| Project | Level | Tables | Frontend | Description |
|---|
| Blog | Beginner | 3 | Next.js | Personal blog with posts, comments, and user profiles |
| Recipe App | Intermediate | 5 | Next.js + Flutter | Cross-platform recipe sharing with categories and favorites |
| Shopping Mall | Intermediate | 4 | Next.js | E-commerce with products, orders, and state machine workflow |
| Social Network | Beginner | 5 | Flutter | Social feed with posts, comments, likes, and follow system |
Choosing a Project
- First time with bkend? Start with Blog -- minimal tables, straightforward CRUD.
- Want cross-platform? Pick Recipe App -- covers both web and mobile patterns.
- Need transactional logic? Go with Shopping Mall -- order state machine and payment flow.
- Building a mobile-first app? Try Social Network -- Flutter-native with feed algorithms.
2. Blog Project
Level: Beginner | Tables: 3 | Frontend: Next.js | Time: ~2 hours
2.1 Schema Design (3 Tables)
users
| Column | Type | Required | Description |
|---|
| name | string | Yes | Display name |
| email | string | Yes | Unique email address |
| avatar | string | No | Profile image URL |
posts
| Column | Type | Required | Description |
|---|
| title | string | Yes | Post title |
| content | string | Yes | Post body (Markdown supported) |
| authorId | string | Yes | Reference to users table |
| status | string | Yes | draft or published |
| tags | array | No | List of tag strings |
comments
| Column | Type | Required | Description |
|---|
| content | string | Yes | Comment body |
| postId | string | Yes | Reference to posts table |
| authorId | string | Yes | Reference to users table |
2.2 Quick Start (5 Minutes)
Step 1: Create the Project
Use the bkend Console or MCP tool to create a new project named my-blog.
> Create a new project called "my-blog"
Step 2: Create Tables
Create the three tables with the schemas defined above.
> Create a "users" table with columns: name (string, required), email (string, required), avatar (string)
> Create a "posts" table with columns: title (string, required), content (string, required), authorId (string, required), status (string, required), tags (array)
> Create a "comments" table with columns: content (string, required), postId (string, required), authorId (string, required)
Step 3: Test the API
curl -X POST https://api-client.bkend.ai/v1/data/users \
-H "Content-Type: application/json" \
-H "X-Project-Id: <your-project-id>" \
-H "X-Environment: dev" \
-H "X-API-Key: <your-api-key>" \
-d '{"name": "Alice", "email": "alice@example.com"}'
curl -X POST https://api-client.bkend.ai/v1/data/posts \
-H "Content-Type: application/json" \
-H "X-Project-Id: <your-project-id>" \
-H "X-Environment: dev" \
-H "X-API-Key: <your-api-key>" \
-d '{"title": "Hello World", "content": "My first post!", "authorId": "<user-id>", "status": "published", "tags": ["intro"]}'
curl "https://api-client.bkend.ai/v1/data/posts?filter=%7B%22status%22%3A%22published%22%7D" \
-H "X-Project-Id: <your-project-id>" \
-H "X-Environment: dev" \
-H "X-API-Key: <your-api-key>"
2.3 AI Prompt Collection
Use these prompts with Gemini CLI or Claude Code to accelerate development:
Schema & Data:
> Create a blog schema with users, posts, and comments tables
> Add 5 sample blog posts with different tags and statuses
> Query all published posts sorted by newest first
> Find posts tagged with "tutorial" by author Alice
Frontend:
> Generate a Next.js blog layout with header, sidebar, and post list
> Create a Markdown editor component for writing blog posts
> Build a comment section with nested replies
> Add tag filtering to the blog post list page
API Integration:
> Create a bkendFetch wrapper for the blog API
> Build TanStack Query hooks for posts CRUD operations
> Add optimistic update for the comment submission form
> Implement infinite scroll pagination for the post feed
3. Recipe App Project
Level: Intermediate | Tables: 5 | Frontend: Next.js + Flutter | Time: ~4 hours
3.1 Schema Design (5 Tables)
users
| Column | Type | Required | Description |
|---|
| name | string | Yes | Display name |
| email | string | Yes | Unique email address |
| avatar | string | No | Profile image URL |
| bio | string | No | Short biography |
recipes
| Column | Type | Required | Description |
|---|
| title | string | Yes | Recipe name |
| description | string | Yes | Short summary |
| instructions | string | Yes | Step-by-step cooking instructions |
| authorId | string | Yes | Reference to users table |
| categoryId | string | Yes | Reference to categories table |
| cookTime | int | No | Cooking time in minutes |
| servings | int | No | Number of servings |
| imageUrl | string | No | Main recipe image |
ingredients
| Column | Type | Required | Description |
|---|
| recipeId | string | Yes | Reference to recipes table |
| name | string | Yes | Ingredient name |
| quantity | string | Yes | Amount (e.g., "2 cups") |
| unit | string | No | Measurement unit |
| order | int | Yes | Display order |
categories
| Column | Type | Required | Description |
|---|
| name | string | Yes | Category name (e.g., "Italian", "Dessert") |
| slug | string | Yes | URL-friendly identifier |
| icon | string | No | Emoji or icon identifier |
favorites
| Column | Type | Required | Description |
|---|
| userId | string | Yes | Reference to users table |
| recipeId | string | Yes | Reference to recipes table |
3.2 Architecture
Web (Next.js):
Stack: Next.js App Router + TanStack Query + Zustand
- Next.js App Router -- file-based routing with server components
- TanStack Query -- server state management, caching, and background refetching
- Zustand -- lightweight client state (UI state, filters, modals)
Mobile (Flutter):
Stack: Flutter + Dio + Riverpod
- Flutter -- cross-platform UI framework
- Dio -- HTTP client with interceptor support
- Riverpod -- state management with dependency injection
3.3 AI Prompt Collection
> Create the recipe app schema with users, recipes, ingredients, categories, and favorites
> Build a recipe card grid component with image, title, and cook time
> Implement category-based filtering with a sidebar navigation
> Create a favorites toggle button with optimistic update
> Generate a Flutter recipe detail screen with ingredient checklist
4. Shopping Mall Project
Level: Intermediate | Tables: 4 | Frontend: Next.js | Time: ~5 hours
4.1 Schema Design (4 Tables)
users
| Column | Type | Required | Description |
|---|
| name | string | Yes | Display name |
| email | string | Yes | Unique email address |
| address | object | No | Shipping address object |
| phone | string | No | Contact phone number |
products
| Column | Type | Required | Description |
|---|
| name | string | Yes | Product name |
| description | string | Yes | Product description |
| price | int | Yes | Price in cents (to avoid floating point issues) |
| stock | int | Yes | Available inventory count |
| category | string | Yes | Product category |
| imageUrls | array | No | List of product image URLs |
| isActive | bool | Yes | Whether the product is listed |
orders
| Column | Type | Required | Description |
|---|
| userId | string | Yes | Reference to users table |
| status | string | Yes | Order status (see state machine below) |
| totalAmount | int | Yes | Total price in cents |
| shippingAddress | object | Yes | Snapshot of delivery address |
| paymentMethod | string | No | Payment method identifier |
| paidAt | date | No | Timestamp of payment confirmation |
| shippedAt | date | No | Timestamp of shipment |
| deliveredAt | date | No | Timestamp of delivery |
order_items
| Column | Type | Required | Description |
|---|
| orderId | string | Yes | Reference to orders table |
| productId | string | Yes | Reference to products table |
| quantity | int | Yes | Number of items |
| unitPrice | int | Yes | Price per item at time of order (snapshot) |
| subtotal | int | Yes | quantity * unitPrice |
4.2 Order State Machine
+--> cancelled
|
draft --> pending --> paid --> shipped --> delivered --> completed
| |
+--> cancelled +--> cancelled
State Transitions:
| From | To | Trigger | Side Effect |