I Built a WeChat Mini-Program Without Knowing How to Code — Here’s the Full Breakdown
Every day, elderly people have to take multiple medications. Morning, afternoon, evening — before or after meals? When there are several pill boxes, even young people can get confused, let alone elderly parents with fading memory.
For a long time, I wanted to build a simple medication tracker for my parents. But the same thought always stopped me:
“I’ll learn programming when I have time.”
This time, I handed the idea to Codex — OpenAI’s AI coding assistant — and something unexpected happened:
In just three weeks, I went from zero coding knowledge to a fully functional WeChat mini-program that passed review and launched.
This isn’t an article about AI hype. I’m going to share everything: the actual method, every prompt you can copy and use, what each stage should look like, and the biggest pitfalls I encountered.
1. Codex Isn’t “Autocomplete for Code” — It’s a Development Partner
When most people first try an AI coding tool, they type something like:
“Build me a medication reminder app.”
Then they expect a complete, launch-ready product in one shot. This approach almost never works well.
The method that actually works: split your project into checkable phases and let Codex complete them one at a time.

Codex’s value isn’t just “writing code.” According to OpenAI’s official documentation, it can help developers understand codebases, write and modify code, debug issues, review changes, and run tests.
In other words, you don’t need to know how every line of code works from the start. But you DO need to know:
- What problem are you trying to solve?
- What should the current phase accomplish?
- How do you verify the result is correct?
2. Step One: Don’t Write Code Yet — Let Codex Help You Think Through the Requirements
The original idea was just one sentence:
“Build a WeChat mini-program that helps elderly users track medications and服药 schedules.”
That’s not a ready-to-develop specification. For example:

Without answering these questions upfront, you’ll end up revising constantly.
Prompt #1: Generate a Product Requirements Document
I want to develop a WeChat mini-program called "Silver Medicine Box" (银发药箱), primarily for elderly users and their family members. Core Goals: 1. Record current medications 2. Record: name, dosage, timing, notes 3. Display today's medication schedule 4. Write reminders to phone calendar 5. Generate and save medication schedule images 6. Large fonts, high contrast, big buttons 7. Simple operation flow 8. No diagnosis, prescription, or medical advice features Please do NOT write code yet. As a product manager and WeChat mini-program developer, output: - Target users and core pain points - MVP feature scope - Page structure - Key user flows - Medication data structure - Edge cases - Privacy permission requirements - Acceptance criteria - Features deferred to version 2 If any requirements seem unreasonable or risky for WeChat review, flag them explicitly.
After completing this step, you should have:
- A clear product requirements document
- A page checklist
- A medication data structure
- A “What’s in v1, what’s not” scope document
- A preliminary privacy permission list
3. Step Two: Have Codex Design the Pages First, Then Build the Project
The “Silver Medicine Box” targets elderly users, so the design principle isn’t “flashy” — it’s “readable, tappable, never lost.”
My interface principles:
- Body text no smaller than standard mini-program fonts
- Main buttons with obvious color distinction
- One primary action per page
- Destructive actions (delete) require double confirmation
- No icon-only buttons with unclear meaning
- Form fields include specific examples
- Empty states tell users exactly what to do next
Prompt #2: Generate the Page Design
Design the page scheme for the "Silver Medicine Box" WeChat mini-program. Target users are primarily elderly. Follow these principles: - Large fonts - High contrast - Large tap areas - Clear text buttons - Minimal page hierarchy - Avoid complex gestures - Important actions provide feedback - Delete actions require double confirmation Output: 1. Homepage wireframe 2. Medication list page wireframe 3. Add/Edit medication page wireframe 4. Today's medication page wireframe 5. Settings page wireframe 6. Button, empty state, and error copy for each page 7. Recommended colors, font sizes, and spacing guidelines Do NOT write business code yet.
Prompt #3: Create the Project Skeleton
Create a native WeChat mini-program project named "Silver Medicine Box" in the current directory. Requirements: 1. Use WeChat native WXML, WXSS, JavaScript, and JSON 2. Create directory structure based on the confirmed page scheme 3. Set up unified color, font size, and spacing variables 4. Create reusable components: medication card, empty state, confirmation dialog 5. Phase 1 only implements static pages and page navigation 6. No cloud development, no privacy APIs 7. Do not delete existing files 8. After completion, check directory structure and config files 9. Tell me how to import into WeChat DevTools for preview First list the implementation plan, then start creating files. Summarize all new and modified files after completion.
The “List the plan → Execute → Summarize” pattern is critical. You won’t end up with a pile of code you can’t place — you’ll be able to see exactly what Codex did.
At this stage, you should have:
- A project ready to import into WeChat DevTools
- Homepage, medication list, and edit pages as static pages
- Navigation working between pages
- Unified elderly-friendly visual standards
- Basic empty states and button feedback
4. Step Three: Only Build One Complete Feature Chain at a Time
Don’t ask Codex to build “medication management, reminders, images, calendar, and cloud sync” all at once.
My approach: Complete one independently verifiable feature chain at a time.
The first feature chain:
Add medication → Save → Display in list → View details → Edit → Delete
Prompt #4: Complete the Medication Management Loop
Implement the medication management feature for "Silver Medicine Box." Feature scope: 1. Add medication 2. Edit medication 3. View medication list 4. View medication details 5. Delete medication 6. Data stored locally for now Medication fields: - id, name,规格 (specification), dosage, unit, timing, before/after meals, start date, end date, notes, created at, updated at Interaction requirements: - Name, dosage, and timing are required fields - Form errors display near the relevant field - After successful save, return to list and show confirmation - Delete requires double confirmation - Empty list shows "No medications yet" + "Add your first medication" button - Large fonts and big buttons suitable for elderly users - No diagnosis, dosage recommendation, or medical conclusions After completion: 1. Check all new and modified files 2. List manual test steps 3. Check data consistency after add, edit, and delete 4. Fix any issues found during testing Why emphasize "no dosage recommendation"? "银发药箱" is a recording and reminder tool, not a medical diagnosis tool.
For health-related features, product copy must maintain boundaries:
“This mini-program is for recording and reminders only, and does not constitute diagnosis, prescription, or medication advice. Please follow your doctor’s instructions for actual medication.”
After this phase, the mini-program is no longer just a UI — it has its first truly usable business loop.
5. Step Four: Build the Core “Today’s Medication” Feature
Users don’t care how many database tables the system has. What they actually care about is:
“What medication do I take, when, and how much?”
Therefore, “Today’s Medication” should be the most prominent information on the homepage.
Prompt #5: Generate Today’s Medication Schedule
Implement the today's medication scheduling feature for "Silver Medicine Box." Requirements: 1. Generate today's schedule based on medication start date, end date, and timing 2. Sort by time 3. Each entry shows: name, dosage, timing, before/after meals 4. Support marking "taken" 5. Taken vs. not-taken states are visually distinct but not jarring 6. Prevent double-clicks causing state anomalies 7. Friendly empty state when no schedule exists for the day 8. Automatically show new day's schedule after date changes 9. Data continues to be stored locally 10. Do not change existing medication management features Please read the current project structure and data model before implementing. After completion, run checks and provide results for these test scenarios: - No medications - Only one timing - Same medication taken multiple times per day - Multiple medications at same time - Expired medications - Mark as taken, then re-enter the page - Status after crossing midnight The most valuable part of this prompt is the test scenarios at the end.
After this phase, “Silver Medicine Box” has two core capabilities:
- Manage my medications
- Tell me what I should take today
6. Step Five: Integrate Calendar and Image Saving
To avoid elderly users having to keep the mini-program open, I added “Add to System Calendar” functionality.
Users can also generate an image of their medication schedule and save it to their phone gallery to share with family or print out.
Both features involve system permissions, so you can’t just focus on “does it work” — you must also focus on privacy compliance.
Prompt #6: Integrate System Capabilities
Add the following features to "Silver Medicine Box": 一、Add to System Calendar - Only call calendar write API when user actively clicks "Add to Calendar" - Write user-confirmed medication reminder events - Do not read, modify, or delete existing calendar events - Clear feedback for success, failure, and user denying permission - Prevent duplicate entries of the same event 二、Save Medication Schedule Image - Generate a high-contrast, large-font image based on today's schedule - Image includes: date, medication name, dosage, timing, and a friendly reminder - Only apply photo album write permission when user actively clicks "Save Image" - Only write the generated image; do not read the photo album - Handle permission denial and save failure scenarios 三、Privacy Compliance - Check actual WeChat privacy APIs being used - Do not call permissions unrelated to the features - Complete necessary user notification and authorization before calling privacy APIs - Output the API names, purposes, and scenarios for the backend "User Privacy Protection Guide" - Do NOT use vague descriptions like "for improving service experience" After completion, list real-device testing steps. Do not rely on the simulator alone.
Ready-to-Use Privacy Descriptions
Photo Album (write only):
When the user actively clicks “Save Medication Schedule Image,” this mini-program will apply for photo album write-only permission to save the user-confirmed medication schedule or reminder image to the phone gallery. Only used after user actively operates; will not read or collect other photos or videos.
Calendar (write only):
When the user sets a medication schedule and actively clicks “Add to System Calendar,” this mini-program will apply for calendar write-only permission to create the user-confirmed medication reminder event in the phone system calendar. Will not read, modify, or delete existing calendar content.
A Real Review Lesson: Specificity Beats Length
“Silver Medicine Box” failed WeChat review on its first submission — not because the privacy guide was missing, but because the descriptions were too vague.
For example:
“Used to improve service experience.”
This doesn’t explain:
- Which page triggers it
- Why the permission is needed
- What specific information is processed
- Whether existing data is read
A more compliant version:
“When the user actively clicks ‘Add to Calendar’ on the medication schedule page, the user-confirmed medication timing is written to the phone system calendar to establish a medication reminder.”
The key takeaway:
Privacy descriptions aren’t better when longer — they must match real features, real pages, and real trigger actions one-to-one.
7. Step Six: Don’t Just Let Codex Write Code — Also Make It Act as a Tester
Just because a project opens doesn’t mean it’s complete.
Before launch, I had Codex check from four angles:

Prompt #7: Pre-Launch Comprehensive Check
Act as a WeChat mini-program senior developer, test engineer, and privacy compliance auditor to conduct a pre-launch check on the current "Silver Medicine Box" project. Check scope: 1. Any pages with no return, duplicate navigation, or blanks 2. Data consistency after add, edit, and delete 3. Today's medication schedule calculation accuracy 4. Cross-date, empty data, and exception handling 5. Whether local cache parsing failures cause page crashes 6. Whether calendar and album permission denials allow continued use of other features 7. Any unused or unnecessary privacy APIs 8. All buttons have clear feedback 9. Font size, color contrast, and tap areas suitable for elderly users 10. Any medical efficacy claims, diagnosis, or dosage recommendation copy 11. Any debug code, test data, or unnecessary logs 12. WeChat DevTools compilation warnings and errors Working method: - Check first, do not modify directly - List issues by severity - State file location and reproduction steps for each issue - Fix high and medium risk issues - Re-run checks after fixing - Output final pre-launch checklist and items still requiring manual real-device verification Phase deliverables: - An issue list ranked by severity - Fixed code - A real-device test checklist - A privacy API comparison table - A pre-submission review checklist
8. The Six-Part AI Coding Prompt Formula
After completing this project, I found that great prompts typically contain six parts:

For example, instead of:
“Help me optimize the page.”
Write this:
Act as a WeChat mini-program UI engineer to optimize the "Today's Medication" page of "Silver Medicine Box." Target users are elderly. This session only allows modifying layout and styles, not data structures or business logic. Requirements: - Clear and readable body text - Large enough tap area for main buttons - Untaken status stands out - Taken status is de-emphasized but still recognizable - Time, medication name, and dosage form a clear hierarchy - Keep existing brand colors - Do not introduce external component libraries After completion, check: small-screen phones, long medication names, empty data, and multi-entry scenarios. Summarize all modified files.
The more specific the task, the more controllable the output.
9. The 5 Most Common Mistakes When Using Codex
After building this project, I identified five mistakes that consistently hurt results:
- Vague requirements: “Build something useful” gets you something useless. Be specific about what “useful” means.
- Skipping design: Jumping straight to code without a page plan creates messy, inconsistent interfaces.
- Skipping real-device testing: The simulator lies. Real phones reveal issues simulators miss.
- Vague privacy descriptions: “For improving experience” fails WeChat review. Be specific about triggers, pages, and data.
- Not making Codex test its own work: Always ask it to verify output before moving to the next phase.
10. Can You Really Build a Mini-Program Without Knowing How to Code?
The answer: Yes, but not “describe it once and it magically launches.”

Codex lowers the barrier for writing, reading, and modifying code — but it won’t decide for you what problem a product should actually solve.
The most important thing about “Silver Medicine Box” isn’t how much technology it uses. It’s that it solves a very specific problem:
Helping parents track medications more clearly and making it easier for family members to organize medication schedules.
A valuable small product often doesn’t start with “I want to build a great platform” — it starts with “My family runs into this problem every single day.”
The Bottom Line
If you’ve been putting off building something because “I don’t know how to code,” here’s the truth:
You don’t need to be a programmer. You need to be a clear thinker who knows what problem to solve.
Codex handles the implementation. You handle the vision. And that division of labor is more powerful than most people realize.
If this article was helpful, feel free to share it with that friend who’s been saying “I have an idea for an app” but hasn’t started yet.
