Build a Video Course Platform
A training company sells courses on one application with one database, and a launch day took payments, video and certificates down together. You will build the replacement, from an instructor's upload and a published course through cohort seats, payment, playback rights, progress, quizzes, certificates, refunds and instructor payouts, and prove it with a launch day where the video host, the payment provider and parts of your own platform fail.
The brief
The client
I run operations at a Dutch company that sells developer-training courses. We have 40 courses and 30 instructors, 22 of them contractors we pay a share of every sale, and about 15,000 people enrol each month. Most courses are self-paced, and the biggest also run as cohorts with a start date and 30 to 300 seats. Everything sits in one application with one database, with a video host behind it that we pay for by the minute.
On the launch day of our biggest new course we had 20 times our normal traffic. The payment processor's confirmations arrived up to 40 minutes late, so 310 people who had paid saw "payment required" and wrote to support. A cohort of 180 was due to start on a Monday, and the last lesson of module 1 said "processing" all weekend with nobody able to tell us why. The same month an editor raised a quiz's passing score from 70 to 80 and the system failed 112 learners who had already passed, and six people received a certificate before their final quiz was graded.
A music publisher then sent a takedown notice over one track in a lesson. We pulled the lesson 15 hours after the notice, refunded the 37 students who had bought the class, and had already paid the instructor for those sales. I need to say, for any learner, why they can or cannot watch a lesson and what they have completed. I need the video host to be able to fail without our shop failing, and finance to be able to trace every cent.
The problem
The current system answers "may this person watch?" and "have they finished?" with one yes or no each, and every part of the business changes them. A payment confirmation sets access, a refund clears it, a support agent sets it by hand, and the video page checks it once, at login, so a refunded learner keeps watching until the login expires. Nobody can tell which change came last or why it happened.
Completion is a percentage worked out against the course as it is today, so an instructor who adds a lesson changes the progress of everyone enrolled, and a passing score applies backwards to results already recorded. The video host's notifications arrive late and sometimes twice, so a lesson flips between "ready" and "processing" and nobody can say whether a failed encode or a late notification caused it. Two buyers can both be sold the last seat. A learner who skips to the end of every video reaches 100 percent and gets a certificate, and a phone that reports progress hours late overwrites what the laptop already saved.
Checkout, progress, payouts and the video player slow down together, so a launch-day spike in checkout stalls lesson playback. Finance computes instructor payouts from a monthly export of gross sales, before tax and the processor's fee, and corrects refunds by hand. The EU VAT return is built from the same export, and the customer's country is not stored on the order. The instructor contracts now say payouts must be explainable line by line, and the client's lawyer has asked for a record that each EU buyer agreed to immediate access and acknowledged losing the 14-day withdrawal right.
The client's name and figures are invented for this brief; the rules and the failures are ones that real businesses of this kind work with.
The spec
Requirements
- Let an instructor author a course of sections and lessons (text, video, download, quiz), submit it for review, and let an editor publish it as a version that never changes afterwards.
- Let an instructor upload a lesson video and show a plain reason when it cannot be used. Publish a version only when every video and its captions are ready, and replace a published lesson's video without a gap.
- Let a learner buy a course with an optional coupon, charged the tax of their own country, and open the course within 5 seconds of the payment confirming (95 percent of the time).
- Let a learner sign up for a cohort with a fixed start date, a seat limit, a 15-minute seat hold and an access window, and let a manager cancel or defer it. Never sell more seats than a cohort has, and never leave a paid buyer without a seat or a refund.
- Decide at the moment of playback whether a learner may watch, and stop a refunded, disputed, expired or taken-down lesson from starting a new playback.
- Record what each learner watched from several devices, late and sometimes twice, and count a lesson as complete only from time actually watched.
- Run graded quizzes with an attempt limit, a passing score and a time limit, judged on the platform's clock. Issue a certificate with a public verification code when, and only when, the learner has really completed the course, let the company revoke it, and show a revoked one as revoked.
- Refund a purchase under a published rule, and handle a bank dispute without moving money twice.
- Pay each instructor a monthly share of sales net of tax, refunds and fees, with a statement that traces every cent and a negative balance carried forward.
- Give support one timeline per learner and finance a quarterly EU VAT report by customer country. Keep the rest of the platform working when the video host, the payment provider or any one capability of the platform is stopped, and hold the launch-day peak of 120 orders a minute for 30 minutes.
Deliverables
- Your repository starts the whole product with one command, with your own stand-ins for the video host, the payment provider, the email provider and the bank, plus a simulator that plays instructors, learners and devices, moves the clock faster than real time, and causes each outside failure this brief names.
- A README that takes a reviewer from a fresh clone to a learner who bought a course, watched it, passed its quiz and holds a verifiable certificate in 20 minutes, and lists the command for each test the brief asks for.
- API documentation for authoring and publishing, checkout, requesting a viewing address, reporting watched time, and verifying a certificate.
- A test suite, plus the results of the launch day from the final Phase committed to your repository.
- An operations note stating what an operator can do and how: follow one purchase from payment to playback, answer "I paid and cannot get in", retry what keeps failing once it is fixed, recover payment confirmations the provider sent while the platform was down, and stop one capability without the others noticing.
Out of scope
- Corporate seat licences and employer reports. They are a different business model with their own roles and reporting, and the client sells to individuals.
- SCORM, xAPI and LTI. They solve packaging, tracking and launching courses in other systems, which is not this client's problem.
- Copy protection, watermarking and screen-recording defences. A playback link that expires is the realistic boundary, and the rest is vendor work that cannot be checked by running or reading something.
- Real video transcoding. The video host is a stand-in you build, because the client's problem is what the platform does when the host answers late, twice or wrongly.
- A video player front end. An HTTP client and the simulator stand in for the browser and the phone.
- Live sessions, Q and A, workbooks, ratings and reviews. Scheduling and calls belong to other products.
- Waitlists for full cohorts. A full cohort answers "full", and a buyer whose payment confirms late is refunded.
- Collecting card data. Card numbers are entered at the payment provider and never reach the platform.
- Filing the VAT return. Reporting ends at the generated report, and the tax table is the client's, not legal advice.
- Learners under 16. Their consent rules need legal input, so the platform asks for an adult confirmation at sign-up and stops there.
- Moving real money to instructors. A payout run records the transfer to a stand-in bank.
- Fraud scoring, dispute fees, processor reserves, instructor advances and royalty recoupment. Each needs figures and signals this client has not given us.
- Kubernetes or cloud deployment. Everything runs on one machine.
Architectural constraints
- Amounts are exact to the cent. Prices include tax, a coupon cuts the shown price first, and tax is then taken out of the discounted total and rounded half up to the cent, at the rate for the buyer's country in the client's table (Netherlands 21, Germany 19, France 20, Ireland 23, Spain 21 percent). A country outside the table is refused at checkout.
- No card number is ever stored or handled by the platform.
- A published course version never changes, and an enrolled learner stays on the version they bought until they ask to move.
- A change to the pass mark, the refund window or the revenue share applies only to what happens after the change. Nothing already recorded is judged again under the new rule.
- A refunded, disputed, expired or taken-down lesson cannot start a new playback. A playback already running may continue for up to 30 minutes.
- A cohort never sells more seats than its limit, and a paid buyer is never left without a seat or a refund.
- A refund returns the full amount paid. The platform absorbs the processor's fee, and the instructor's share is reversed on the amount net of tax and fee. A refund and a bank dispute on one order never return more than the amount paid.
- A quiz deadline is judged on the platform's clock, never the device's, and no learner is ever shown the correct answers.
- A certificate is issued once per enrolment and only after the last required quiz has been graded as passed. Its code is 12 random characters that avoid 0, O, 1, I and L and say nothing about the learner, the course or the date.
- Personal fields (name, email, country) are erased on request, while ledger, tax and traceability records stay, identified by ID. A certificate stays verifiable after its owner is erased, without their name.
- Whatever is stopped may delay the rest of the platform and never makes it fail. The one exception is cohort checkout, which answers "try again" while seat booking is stopped.
- Durations are whole seconds and scores are whole percent, rounded down. Progress is whole percent rounded to the nearest, so 10 of 11 lessons shows 91.
Prerequisites
You have finished an intermediate project or have equivalent experience: an application with a database that real people used, and some time spent keeping one running. Any language and stack. You do not need to know how an online course company sells and runs its courses; the first Phase explains the business and the words the brief uses. Each Checkpoint explains the problem it exists to catch, so the brief stands alone. Having once refunded someone twice, or watched a flag and the facts behind it disagree, will make most of it feel familiar.
Free to start. An account is what keeps track of the checkpoints you finish.
Set up the platform
Produces a worked example of one sale from purchase to payout, and a way to start the product and a simulator with one command from your repository. Leaves all behaviour for later: the product only reports the time it believes it is.
Acceptance criteria
You split one sale by hand, from the buyer's charge to the instructor's payout, with the client's numbers, and keep the amounts in a document in your repository so that every total balances to the cent. A course lists at 4,900 cents and a 20 percent coupon brings the charge to 3,920. For a buyer in Germany it shows tax of 626, a processor fee of 84, net of 3,210, an instructor share of 2,247 at 70 percent and 2,889 when the sale came through the instructor's own referral at 90 percent.
The same sale is worked as a full refund: 3,920 goes back to the buyer with its 626 of tax, the platform absorbs the 84 fee, and the share of 2,247 is reversed against net. The document adds one worked line for each of the other four countries in the tax table (Netherlands 21, France 20, Ireland 23, Spain 21 percent) using the same rounding, half up.
It states the date the share becomes payable (14 days after payment) and the month's statement it lands on, using a payment date the document picks. It follows one learner through a day: the purchase, a confirmation that arrives 40 minutes late, a first lesson watched, and a refund on day 10, showing what the learner and the client see at each moment. A figure that is not the result of a stated formula is not done.
Architectural guidance
A tax or share figure that is a cent off in one order is a cent off in thousands, and the client cannot explain it to a tax office or to an instructor who checks the statement. Rounding is where two honest people reach different answers from the same table. A sale worked by hand gives every later check a figure to compare against, so a wrong number is found at the first order and not in the first statement.
Acceptance criteria
From a fresh clone, one documented command starts the whole product and a simulator. The README shows how a reviewer reads the time the product believes it is. In normal mode that is the system time. In simulation mode the simulator moves the clock forward by one day in under a minute, and the product then reports a time one day later without waiting.
Running the command a second time on existing data changes nothing and starts nothing twice. The README lists the command for each test the brief asks for and gains a line with each Phase you finish. In later Phases the same command also starts your stand-ins for the video host, the payment provider, the email provider and the bank.
Architectural guidance
A seat hold of 15 minutes, a refund window of 14 days and a statement closed on the 1st of the month cannot be tested by waiting. If the clock cannot be moved, the first time anyone sees these rules fail is in front of customers. A product that starts differently on each machine, or doubles its work when started again, makes every later failure test unrepeatable.
Architectural walkthrough
How an online course company sells and runs its courses
The company sells developer-training courses: 40 courses taught by 30 instructors, 22 of them contractors who are paid a share of every sale. About 15,000 people enrol each month. Most courses are self-paced, and the biggest also run as cohorts with a start date and 30 to 300 seats. An instructor writes a course from sections and lessons (text, video, downloads and quizzes), an editor reviews it, and the editor publishes it.
Lesson videos are stored and converted by a video host, which the company pays for by the minute. A learner buys a course, optionally with a coupon, and pays tax at the rate of their own country. The payment processor tells the platform when the payment went through. The learner then watches lessons, possibly from a laptop and a phone, takes graded quizzes, and gets a certificate when the course is complete.
Each month the company pays its instructors their share of sales. It refunds purchases under a published rule, answers bank disputes, and removes a lesson when a rights holder demands it. Every quarter it reports EU VAT by customer country.
The words this brief uses:
Course version: a published state of a course. It never changes afterwards, and a learner stays on the version they bought.
Cohort: a run of a course with a fixed start date, a seat limit and an access window.
Seat hold: a seat kept for a buyer for 15 minutes while they pay.
Viewing address: the short-lived link that plays one lesson.
Watched time: the seconds a learner actually watched, which is what counts toward completing a lesson.
Pass mark: the lowest quiz score that passes, in whole percent.
Certificate: proof of completion that anyone can check with a public verification code. The company can revoke it.
Revenue share: the part of sales, net of tax, refunds and fees, that goes to a contractor instructor.
Takedown notice: a rights holder's demand to remove content, such as the music publisher's notice about one track.
Withdrawal right: an EU buyer's right to cancel within 14 days. The company records that the buyer agreed to immediate access and so gave it up.
Why money and time come first
Money is wrong by a cent here and a euro there, and the first time anyone checks is the launch day. A tax figure that cannot be reproduced from the client's table is a figure the client cannot defend to a tax office, and a share that is a cent off for one contractor is a cent off for all 22 of them.
A 15-minute seat hold, a 14-day refund window and a monthly statement cannot be tested by waiting. If the only way to see a rule fail is the real day, the client sees it fail first. The persona's failures all came from rules nobody had ever watched break: 310 paid learners shown "payment required", a pass mark raised from 70 to 80 that failed 112 learners who had passed, six certificates issued before the final quiz was graded.
A product that starts differently on each machine, or twice on a second run, leaves a reviewer unable to repeat any later check. Every Phase after this one asks you to cause a failure and read the result, so the means to cause it has to exist before the first rule does.
Publish a course
Produces authoring, review and publishing of course versions that never change afterwards, and takedowns with a stated reason. Leaves video readiness for the next Phase and everything that reacts to a takedown for later Phases.
Acceptance criteria
An instructor submits a draft for review. An editor can request changes or approve and publish. A published course is a numbered version, starting at 1 for each course and contiguous after that, and it never changes afterwards.
A version shows its price in cents (tax-inclusive, EUR), its delivery (self-paced or cohort), and each lesson with its kind, whether it is required, its position, its duration in whole seconds and, for self-paced courses, its drip offset in days. It also shows the completion policy that travels with it: pass mark 70, 3 attempts, a 30-minute time limit, highest score counts, and every quiz with its multiple-choice questions and one correct answer each.
Editing a published course starts a new draft. A request to change a published version is refused, and reading version 1 after version 2 exists returns exactly what it returned before.
Architectural guidance
An edit to a live course changes what every enrolled learner was sold. Progress counted against 20 lessons is wrong against 21, a pass mark moved from 70 to 80 fails people who passed, and a completion already earned can disappear. The learner paid for one specific course and expects to finish that one.
Acceptance criteria
An editor or the instructor can take a whole course, or named lessons, off sale for a stated reason: author request, instructor removed, or rights claim. Both the moment the notice was recorded and the moment the course came down are shown, and they can differ.
An author request or an instructor removal stops new sales and leaves access in place for learners already entitled. A rights claim stops new sales at once. What a rights claim does to playback, to buyers and to instructor shares arrives in later Phases. An instructor who leaves or is banned has every one of their courses taken down as instructor removed.
A taken-down course cannot be bought. A request to take a course down without a reason is refused.
Architectural guidance
A takedown whose reason and timing nobody recorded cannot be defended to a rights holder. The three reasons promise different things to learners who already paid, and treating them alike either strands paying customers or leaves disputed content live. The 15 hours the client waited on a notice is measured from the moment the notice was recorded, so that moment has to exist next to the moment of action.
Acceptance criteria
A named test, with its command in the README, shows three things. After a course is published, editing, reordering and deleting lessons in its draft leaves the published version identical when read back. Publishing version 1, editing, and publishing version 2 leaves version 1 as it was. A process killed during a publish leaves the course either unpublished or published exactly once, with contiguous version numbers.
The test repeats the kill at several different moments of the publish. At no moment does a buyer find the course on sale without a version to watch, and at no moment does a second version number appear.
Architectural guidance
A process that dies halfway through publishing leaves a course half live, and the client finds out when a buyer writes in. The crash happens at an unlucky moment by definition, so a check that never kills the process proves nothing about it. This check exists to show that the worst moment to die is survivable.
Architectural walkthrough
An instructor adds a lesson to a live course and the progress of everyone enrolled changes. A learner who had finished 19 of 20 lessons is suddenly at 19 of 21 and no longer complete. The learner bought a specific course, and an edit made afterwards changes what they were sold.
A process dies halfway through publishing and the course ends up half live: on sale with nothing to watch, or published twice under two version numbers. The client learns about it from a buyer, after the sale.
A takedown notice sits for 15 hours because nobody can say what was taken down, by whom, or why. The three reasons (author request, instructor removed, rights claim) promise different things to learners who already bought, and a notice handled as one undifferentiated removal either strands paying learners or leaves disputed content on sale. The cost is learners who lose progress, a course that sells when it should not, and a client who cannot show a rights holder when it knew.
Process lesson video
Produces the video host stand-in, uploads with plain states and reasons, a gate on video readiness, and replacement of a published lesson's video. Leaves issuing playback links for the Phase on who may watch.
Acceptance criteria
Your video host stand-in can be made to cause each of these on demand and one at a time: a processing failure, an unreadable file, a file longer than 60 minutes, delayed reports, doubled reports, reordered reports, a report about a video nobody uploaded, a captions failure, and an outage. With none of them switched on, it processes a video normally.
It acknowledges a report from the platform within 5 seconds, and it retries a report the platform did not acknowledge for 24 hours. The README names the switch for each behaviour and gives one command that demonstrates it. Switching one behaviour on leaves every other behaviour as it was.
Architectural guidance
The real host fails at the client's worst moments, such as the start of a cohort, and it fails in ways that are hard to reproduce on purpose. A failure that cannot be caused on demand is met for the first time in production. A reviewer who cannot cause a captions failure cannot tell whether the product handles one.
Acceptance criteria
An instructor uploads a lesson video and sees one plain state at any time: waiting, being processed, ready, or cannot be used. Ready means encoded and captioned. Cannot be used always carries a plain reason: unreadable file, longer than 60 minutes, processing failed, or captions failed.
A 61-minute file is refused with its reason. No word from the host appears anywhere an instructor reads. A late report about an earlier stage never moves a ready lesson back to being processed.
Architectural guidance
A lesson that says "processing" for a whole weekend cannot be told apart from one that failed, so the instructor cannot tell whether to wait or upload again. The host calls a video done when encoding ends, and the client needs done to mean captioned too. If the two meanings are mixed, a late report and a failed encode look the same on the screen.
Acceptance criteria
Publishing a course version is refused while any video or caption in it is not ready, and the refusal names each lesson that is not ready. When every video and caption is ready, publishing succeeds. A video that fails changes nothing in any course that is already live.
With the video host stopped, publishing a version whose videos and captions are already ready still succeeds.
Architectural guidance
A cohort published with one lesson still processing opens on Monday with a hole in week one, and 180 learners find it before the client does. A failed video that reaches into a live course takes away something people already paid for. The check exists so that the person who clicks publish learns about the problem and the learners do not.
Acceptance criteria
An instructor can replace the video of a published lesson. While the replacement is processing, learners keep watching the old video. The replacement reaches learners only through a new course version published after the new video and its captions are ready.
If the replacement fails, nothing changes for any learner. A learner who is on an older version keeps the old video until they ask to move to the newer version.
Architectural guidance
A replacement swapped in while it is still processing leaves learners with a blank player in the middle of a lesson. A replacement that fails and takes the old video with it breaks a course people are partway through. The client's best course is where this happens first, and the cost shows up as a support backlog.
Acceptance criteria
A named test, with its command in the README, uses your stand-in to send the host's reports doubled, reordered and late. It also sends a failure for a video that had already become ready, and a report for a video nobody uploaded. Then it stops the host for a stated time.
Every lesson ends in one right state. The report for a video nobody uploaded changes nothing anyone can see. While the host is stopped, buying, watching lessons that are already ready, and publishing a version whose videos are ready all keep working, and uploads show that the host is unavailable.
Architectural guidance
Outside systems repeat themselves, arrive late and sometimes talk about things that never happened. A lesson that ends up in a different state depending on the order of the messages makes the weekend of "processing" happen again. A host outage that stops buying or watching turns a problem for instructors into a problem for paying customers.
Architectural walkthrough
The video host reports late, twice, out of order, and about videos nobody uploaded. A lesson says "processing" all weekend and nobody can tell a failed encode from a late report, while 180 learners are due to start on Monday. The cohort opens with a missing lesson and the instructor has no word to describe what is wrong.
The host's idea of done is not the client's. A video that is encoded but has no captions is not ready for a learner who needs them, and a report that arrives late must not undo a lesson that has since become ready.
A replaced video that breaks a live course turns the client's best-selling course into a support backlog. Learners are in the middle of it, and the fix has to reach them without taking away what they are watching. The cost is a cohort that starts with a hole in it, instructors who cannot tell whether to wait or re-upload, and a launch-week support load that comes from one confusing word on a screen.
Take payment
Produces the payment provider stand-in, priced orders with the tax of the buyer's country, the buyer's recorded agreement to immediate access, and purchases that show waiting for payment, paid or failed. Leaves cohort checkout for the next Phase and refunds and disputes for later.
Acceptance criteria
You work out, with the client's numbers, what the payment provider can do to a purchase and what the buyer and the client see in each case, and keep the result in a document in your repository. It covers a confirmation up to 40 minutes late, a confirmation sent twice, a confirmed payment reported failed up to 5 days later, a dispute opened up to 120 days after payment with evidence due 7 days after it opens, and an outage of 3 hours after which the provider retries for up to 3 days and a manual resend reaches back 15 days.
The document holds a table of at least six situations. For each it gives what the buyer sees and what the purchase must end as in plain words: waiting for payment, paid, failed, refunded or in dispute. It includes one situation where a failure arrives before the payment it cancels.
Architectural guidance
The provider decides when and how often it speaks, and a product built on the assumption of one prompt confirmation fails on the first slow day. The 310 people who saw "payment required" were all in a situation nobody had written down. Working out the situations first means each later check has a stated answer to compare against.
Acceptance criteria
Your payment provider stand-in has a hosted checkout where the card is entered. After a run of 100 purchases, no card number appears in anything the platform stores, logs or returns.
The stand-in can be made to cause each of these on demand: a confirmation delayed up to 40 minutes, a confirmation sent twice, messages arriving out of order, a confirmed payment reported failed up to 5 days later, a dispute, and an outage of 3 hours. Its messages are signed so the platform can check they came from it. The platform refuses a forged message and one older than 5 minutes, and a refused message changes no purchase.
The stand-in retries undelivered messages for up to 3 days. It lets an operator list what it sent since a chosen time, back to 15 days, so the operator can ask for a resend. It reports its fee on each charge: 1.5 percent plus 25 cents, rounded half up, the price of a card issued in the European Economic Area. The README names the switch for each behaviour.
Architectural guidance
A message that anyone can forge lets a stranger mark a purchase paid. A message that is valid forever lets someone replay an old confirmation. Card numbers that touch the platform make the client responsible for them, and a leak of them ends the business. Without a way to cause each provider behaviour, the platform meets them for the first time on launch day.
Acceptance criteria
A buyer is shown the price, the tax and the total before paying, and is charged exactly the total shown. A coupon (a percentage off, with an expiry date) cuts the shown price first, and tax is then taken out of the discounted total at the rate of the country the buyer declares: Netherlands 21, Germany 19, France 20, Ireland 23, Spain 21 percent, rounded half up.
The worked example holds: a course listed at 4,900 cents with a 20 percent coupon is charged 3,920, with tax 626 in Germany, fee 84 and net 3,210. An expired coupon is refused. A country outside the table is refused. A purchase made through an instructor's referral shows the referring instructor on the order where support can read it. A taken-down or unpublished course cannot be bought. This Phase prices self-paced courses only.
Architectural guidance
Prices are tax-inclusive and the discount comes first, so taking tax out of the original price gives a different figure for every discounted order. An amount that differs by a cent between the page and the charge leads to a tax return that does not match the bank. The client cannot explain a wrong figure to an auditor after the fact, so the figure has to be right at the first order.
Acceptance criteria
A buyer cannot place an order that starts access at once without ticking that they want access to start now and accept losing the right of withdrawal. Without the tick there is no order. The agreement is stored with the order with its date and time, and support can read it.
The checkout request carries an Idempotency-Key header. Sending the same request twice with the same key within 24 hours, including twice at the same moment, creates one order and one charge, and the second answer repeats the first. A different key creates a different order. The header is described in the API documentation. A taken-down or unpublished course is refused.
Architectural guidance
A buyer who double-clicks, or whose phone retries on a bad connection, can be charged twice for the same course. The refund and the support call cost more than the sale. The client also has to show what the buyer agreed to, and an agreement with no date and time cannot be shown to anyone.
Acceptance criteria
Each purchase shows waiting for payment, paid or failed in plain words, taken from what the provider reports. A confirmation that arrives 40 minutes after checkout moves a purchase from waiting for payment to paid without the buyer doing anything. A payment reported failed after it was confirmed shows failed together with that reason. A failure that arrives before the payment it cancels ends as failed, and the confirmation that arrives afterwards does not turn it back.
A forged message, an expired message or a message for a purchase that does not exist changes nothing a buyer or support can see. A message that arrives twice has the effect of one.
Architectural guidance
The client lost 310 learners' trust to a screen that said "payment required" for people who had paid. A purchase shown as paid on a message that arrived in the wrong order grants access to someone whose payment was cancelled. The provider speaks in its own words, and the screen has to say what the buyer needs to know.
Acceptance criteria
A named test, with its command in the README, runs against your provider stand-in. It sends 5 percent of confirmations twice, late and reordered messages, a failure before its payment, a failure 5 days after access, and a 3-hour outage after which the missed confirmations are fetched. It also kills the process at random moments across 1,000 purchases, and sends the same checkout request twice at the same moment.
Every purchase ends with one right state and one charge. After the outage, the purchases whose confirmations were missed end as paid. No purchase is lost and no purchase is counted twice.
Architectural guidance
Payment is where the client's worst day happened: confirmations late, paid learners turned away, and money that did not match the bank. A product that is correct only when messages are prompt, single and in order is correct only on quiet days. This check exists because the crash and the race happen at the moments nobody planned for.
Architectural walkthrough
Payment confirmations arrived up to 40 minutes late, so 310 people who had paid saw "payment required". They paid again, wrote to support, or left. The provider's confirmation is the only fact the platform has about a payment, and it arrives when the provider decides.
The same message can arrive twice, and a payment that was confirmed can be reported failed up to 5 days later, after the learner has been watching for days. A failure can even arrive before the payment it cancels. A buyer who double-clicks the pay button can be charged twice. A forged message, or an old one replayed by someone who saved it, can say anything.
The client also has to show what the buyer agreed to. When access starts at once, the buyer gives up the right of withdrawal, and a lawyer will ask for the date and time of that agreement. If nobody recorded it, the legal 14-day withdrawal right still applies, so the refund has to be honoured for every buyer.
The cost is support load and lost trust on the launch day, money and tax figures that do not match the bank, and a buyer who has paid and has nothing to show for it.
Grant access and sell seats
Produces learner registration, access that follows the payment, cohorts and seat booking with a 15-minute hold. Leaves ending access for refunds and disputes for a later Phase, and who may start a lesson for the next.
Acceptance criteria
A learner registers with a name, an email and a country, and must confirm they are an adult. Registration without the confirmation is refused and no account exists afterwards. A registered learner gets an ID that stays the same for as long as the account exists.
Instructors have accounts with a name and an email too. Learners under 16 are not supported, and the registration does not ask for a birth date.
Architectural guidance
A learner's name, email and country show up wherever the product needs them, and each place is one more to find when the learner asks to be erased. A place missed is a broken promise to that learner, and the client finds out from a regulator. The later the client starts counting those places, the more of them it has missed.
Acceptance criteria
Once a payment is confirmed, the course appears among the learner's courses within 5 seconds, 95 percent of the time, measured over at least 200 purchases. A self-paced course has no end date. A failed payment gives no access. A payment confirmed twice gives access once, and the learner's list shows the course once.
The measurement is committed to your repository with the command that produced it. Cohort seats arrive in a later Checkpoint, so this one covers self-paced courses only.
Architectural guidance
A learner who has paid and sees an empty list writes to support or pays again. The 310 learners shown "payment required" cost the client money twice, once in refunds and once in trust. The stated target of 5 seconds for 95 percent of learners turns a feeling of slowness into a number a reviewer can check.
Acceptance criteria
A manager schedules a cohort with a course, a start date, between 30 and 300 seats, 6 weeks, six weekly modules that open at 09:00 local on Mondays in the cohort's time zone, and an access window that ends 90 days after the cohort ends. A cohort with fewer than 30 or more than 300 seats is refused.
A cohort in Europe/Berlin starting Monday 22 Mar 2027 at 09:00 local opens module 2 on Monday 29 Mar 2027 at 09:00 local, which is an hour earlier in UTC because the clocks changed in between. A manager can cancel a cohort, defer it so that every date moves and nobody is refunded, and open a module early. Up to 10 cohorts are open at once.
The refunds a cancellation causes arrive in a later Phase. In this one a cancelled cohort stops selling seats.
Architectural guidance
A start time stored as a fixed number of hours from UTC drifts by an hour when the clocks change, so 300 learners find the first Monday of spring opens late. A deferral that refunds people who did not ask for it costs money, and one that does not move every date leaves a cohort with a module open before the course starts. Managers need the dates they typed to be the dates people see.
Acceptance criteria
A buyer of a cohort seat has the seat held for 15 minutes before paying, and the seat shows as held. The hold is released if the payment fails or if 15 minutes pass on the simulator's clock. A seat is never sold beyond the limit: 300 buyers at the same moment for the last 10 seats of a cohort yield exactly 10 seats.
A payment that confirms after its hold expired still gets a seat if one is free. If none is free, the buyer is told no seat can be given. The refund for that buyer arrives in a later Phase. Cohort checkout is added to the order flow here, with the same agreement and pricing rules as before, and the agreement is not asked for a cohort that has not started.
Architectural guidance
Payments can arrive up to 40 minutes late while a hold lasts 15, so a buyer can pay for a seat that has gone to someone else. Two buyers reaching for the last seat in the same instant is the ordinary case on a launch day, and a cohort sold above its limit is a promise of a seat that does not exist. The cost is a paid buyer with no seat and an instructor with 301 people in a room for 300.
Acceptance criteria
A named test, with its command in the README, shows three outcomes. Two buyers for the last seat yield one seat. A payment that confirms after its hold expired and its seat was taken gets no seat and is told so. With seat booking stopped, cohort checkout answers "try again" while every self-paced purchase still works, and no cohort buyer is charged without a seat held.
The test checks the count of seats sold against the limit after each case. It ends with seat booking started again, and cohort checkout works without any manual repair.
Architectural guidance
The last seat is where the race, the late payment and the outage meet. A cohort checkout that fails by taking payment without a seat costs a refund and a complaint. A seat-booking outage that stops self-paced sales as well turns a problem for one cohort into a problem for the whole catalogue.
Acceptance criteria
A named test, with its command in the README, shows four outcomes. A payment confirmed twice gives access once. A failure that arrives before its payment leaves the learner with no access. A payment reported failed 5 days after access ends the access at once and keeps the learner's progress recorded. A process killed between a payment being recorded and access being given ends with access exactly once.
The test kills the process at several different moments between the payment and the access. After each run the learner has either never had access or has it exactly once.
Architectural guidance
A process that dies between taking a payment and giving access leaves a paid learner with nothing, and nobody finds out until the learner phones. A restart that gives access a second time can duplicate a seat or an enrolment. A failure reported 5 days later must take access away without destroying the progress the learner earned.
Architectural walkthrough
A payment can confirm 40 minutes after checkout while a seat hold lasts 15, so a learner can pay and come back to find the seat gone. The money has been taken and the course has not been delivered. Two buyers can reach for the last seat at the same moment, and a cohort sold over its limit means a promise of a seat to someone with no seat.
A cohort that starts at 09:00 Berlin time must still start at 09:00 Berlin time after the clocks change, or the first Monday of the spring starts an hour late for 300 people.
Access that follows the payment has its own failures. A process that dies between recording a payment and giving access leaves a paid learner with nothing, and a confirmation that arrives twice must not give access twice. A payment reported failed days later must end the access, and a support agent who cannot say why someone cannot get in cannot help them.
The cost is a buyer who paid and has no seat, a cohort over its limit, a Monday start an hour late, and a support desk that guesses.
Decide who may watch
Produces the decision to let a learner start a lesson, and the playback link that expires after 30 minutes. Leaves the refunds and disputes that end access for a later Phase; ending access is caused here by a payment reported failed after access or by a takedown.
Acceptance criteria
An entitled learner asks to start a lesson and receives a playback link that is valid for 30 minutes. While access holds, a new link is issued when the old one nears its end. A link altered to reach another lesson is refused, and so is a link older than 30 minutes. A learner without access gets a plain refusal.
The link's format is yours. Its 30-minute life and its refusal when altered are fixed. The decision to issue a link is made when the learner asks, not when they bought.
Architectural guidance
A link that never expires cannot be taken back from a learner who has been refunded. A link that can be edited to point at another lesson hands out the whole catalogue for the price of one. The decision to allow playback has to be made at the moment of asking, since access can change between the purchase and the first click.
Acceptance criteria
A playback request that must be refused is answered with exactly one plain reason: no entitlement, access window closed, not yet released, taken down, or suspended. Access window closed means the cohort's end plus 90 days has passed. Not yet released means a cohort lesson before its module opens in the cohort's time zone, or a self-paced lesson before its drip offset in days times 24 hours after access began.
Each reason is demonstrated with the simulator's clock moved to the right moment: one minute before and one minute after a module opens in Europe/Berlin, and at the end of the access window. Suspended is shown in a later Phase, when disputes exist.
Architectural guidance
A learner turned away with no reason writes to support, and the support agent has nothing to look at. A lesson that opens an hour early or late after a clock change breaks a promise made to a whole cohort. The reasons differ in what the client should do next, so one word for all refusals costs time on every call.
Acceptance criteria
When a learner's access ends, no new playback starts for them. A request to renew a link they hold is refused, and a new request is refused with no entitlement. A payment reported failed after access is the cause demonstrated here.
When a lesson is taken down for a rights claim, no new playback of the named lessons starts for any learner, or of the whole course when the notice names the course. This takes effect within 1 hour of the moment the notice was recorded. A takedown for an author request or an instructor removal leaves learners who are already entitled watching. A playback already running may finish within its 30 minutes.
Architectural guidance
A refunded learner who keeps watching, or a rights-claim lesson that stays playable, is the client breaking its own promise or the law. The 15 hours the client took on the last notice is the number to beat, and the target is 1 hour from the moment the notice was recorded. A link already handed out cannot be recalled, so the 30 minutes is the price of using one.
Acceptance criteria
With each of buying, sign-up, publishing, progress tracking and the video host stopped in turn, an entitled learner still starts a lesson, and a learner without access still gets a refusal with its reason.
If playback links cannot be issued at all, new playback requests answer "try again", and links already issued keep playing for their 30 minutes. The README lists the command that stops each capability and the command that starts it again.
Architectural guidance
Watching is what the learner paid for, so it has to survive trouble anywhere else in the product. A reviewer can only believe it if each other capability is stopped, one at a time, while a lesson is started.
Acceptance criteria
A named test, with its command in the README, shows four outcomes. A learner whose access ends cannot get a new link, and a link they already hold stops working within 30 minutes. An end of access that arrives before the start it cancels leaves the learner with no access. At the start of a 300-seat cohort, 250 viewers each start a lesson. A rights-claim takedown stops new playbacks within 1 hour of the notice being recorded, while purchases and publishing are stopped.
Each outcome is reported with the time measured on the simulator's clock.
Architectural guidance
Access changes between the purchase and the click, and messages about it can arrive in the wrong order. A product that remembers a yes from last week lets a refunded learner in, and one that is slow under load turns away the 250 people who arrive together at nine o'clock on a cohort's first day. This check exists to show the answer is right at the moment someone asks, including the busiest moment.
Architectural walkthrough
On the last launch day the spike in checkout stalled lesson playback, so people who had paid could not start a lesson. The people most worth keeping happy were turned away at the moment the client was busiest selling.
The opposite failure is as costly. A refunded learner kept watching until a session expired, and the content the client had refunded was still being watched. A music publisher's notice took 15 hours to act on, which left a rights holder with a dated notice and no action.
A playback link that works forever cannot be taken back, so how long a link lives is a number the client has to choose. The client chose 30 minutes, and a revoked learner can keep watching up to that long. The same decision has to give one plain reason when it says no, because a support agent who hears only "denied" cannot help.
The cost is paying customers turned away at the worst moment, refunded content still being watched, and a takedown that is slower than the 1 hour the client set itself.
Teach, track and assess
Produces enrolment on the course version the learner bought, watched time from several devices, and quiz attempts judged under the pass mark in force. Leaves course completion and certificates for the next Phase.
Acceptance criteria
A learner who gets access sees the lessons of the course version they bought, each with its required flag and duration. A cohort learner sees them from the moment the seat is assigned. Publishing a newer version afterwards changes nothing in that learner's list or progress: reading the same learner before and after the publish shows the same lessons and the same percentage.
A learner who finished all ten lessons of version 1 is still at 100 percent when version 2 adds an eleventh required lesson. A payment confirmed twice, or access granted again after a dispute is won, leaves the learner on one enrolment, on the same version. No response a learner can reach shows a quiz answer: fetching a quiz returns the questions and their choices only.
Architectural guidance
An instructor edits a live course every week. If a learner's list of lessons follows whatever version is current, adding one required lesson to a ten-lesson course drops everyone enrolled from 100 percent to 91 percent overnight, and the old system did exactly that. Learners who had finished see their course reopen, and the client has to explain why.
Acceptance criteria
A device reports watched time every 15 seconds as learner, lesson, course version, from-second, to-second, when it happened and device. A report spanning more than 30 seconds is refused with a plain reason and counts for nothing. Watched time for a lesson is the seconds covered by any report, counted once, in whole seconds: a 480-second lesson watched twice from second 0 to second 240 shows 240 seconds.
A lesson is complete when 90 percent of its duration is watched on the learner's version, which is 432 of 480 seconds. A learner who jumps to the last seconds of a video and reports only those seconds leaves the lesson incomplete. The learner's resume position is saved and the next playback starts there. Reports up to 6 hours old are accepted, and the same report sent twice, or from two devices at once, changes nothing the second time.
Architectural guidance
Learners watch on a laptop and a phone, and a phone that was offline sends what it saw hours after the laptop sent the same minutes. If every report adds time, an hour of watching counts as two, lessons complete without being watched, and the client issues certificates for courses nobody finished. If a learner can drag the slider to the end and be counted, a course completes in a minute.
Acceptance criteria
A learner starts a quiz attempt and submits it. A quiz allows 3 attempts, and a fourth start is refused with a plain reason. The platform notes when each attempt started and refuses a submission arriving more than 30 minutes later, by the platform's clock whatever the learner's device says. A refused late attempt closes with no score and still counts as one of the 3.
Submitting the same attempt twice, even at the same moment, returns the first result and changes nothing. The score is correct answers over total questions in whole percent rounded down: 7 correct out of 9 gives 77. The highest score counts. The learner is never shown which answers were correct, in a result or in the response to a refused or closed attempt.
Architectural guidance
A quiz deadline checked against the learner's own clock can be beaten by changing that clock, and the learner then takes as long as they like. Answers shown in a result get shared, and the quiz stops measuring anything.
Acceptance criteria
Each attempt is judged against the pass mark in force when the attempt started. With a pass mark of 70, an attempt scoring 72 passes. After the pass mark is raised to 80, an attempt started earlier and submitted later with 72 still passes, and an attempt started after the change with 72 fails.
A quiz lesson is complete when the learner's highest score meets the pass mark that attempt started under. Raising the pass mark changes the result of no attempt made before the change, and a learner who passed at 70 stays passed.
Architectural guidance
A pass mark raised from 70 to 80 failed 112 learners who had already passed under 70. They held a passing result and were told they had failed, and support spent days sorting out who was right. A learner halfway through an attempt when the change lands should not be graded by a rule they never saw.
Acceptance criteria
A named test, with its command in the README, sends one learner's watched time and prints a single progress figure each time. The same ranges sent from two devices at once give the figure of one device. A phone upload 6 hours late covering seconds the laptop already reported adds nothing, and covering new seconds adds exactly those seconds. A whole batch of reports sent twice gives the figure of sending it once.
A learner who jumps to the final seconds of a 480-second lesson and reports only those seconds ends with the lesson incomplete. The test prints the figures it compared and fails if any differ.
Architectural guidance
Devices repeat themselves, arrive late and overlap, and each of these inflates watched time when counted naively. Inflated time completes lessons nobody watched and leads to certificates nobody earned. The check exists to show that the same hour of watching counts as the same hour, however it arrives.
Acceptance criteria
A named test, with its command in the README, raises the pass mark from 70 to 80 in the middle of a run, with 112 learners who had already passed at 70. Afterwards all 112 still show passed, and no result recorded before the change differs from what it showed before. An attempt started before the change and submitted after is judged under 70. An attempt started after the change is judged under 80.
The test prints each learner's result before and after the change and fails on any difference in a result that existed before it.
Architectural guidance
This is the failure behind the 112 learners: a rule changed and the past changed with it. The bug only shows when a change lands while attempts are in progress, so a test that changes the rule between runs never reproduces it.
Architectural walkthrough
A passing score was raised from 70 to 80, and 112 learners who had already passed were told they had failed. They wrote to support, some asked for refunds, and the client could not say which result was right. The same thing happens when an instructor adds a required lesson to a live course: everyone enrolled in a ten-lesson course drops from 100 percent to 91 percent overnight (10 of 11 lessons is 90.9, rounded to the nearest whole percent). In both cases a rule changed and old results were judged by the new rule.
Progress arrives badly. A phone that was offline reports what it watched six hours after the laptop reported the same minutes. A device sends a batch again because it never saw the answer. A learner drags the slider to the end of a video and the course says finished. Counted naively, the same minute is worth two minutes, a late upload overwrites a better figure, and a skipped video earns a certificate.
Quizzes add a clock the client cannot trust. A deadline judged by the learner's device is beaten by changing the device's clock, and a double click on submit can score an attempt twice or use up two of the three attempts. Each of these ends with a learner holding a result they do not believe, and a client who cannot show which result was right.
Complete and certify
Produces course completion, certificates with a public verify page, revocation and erasure. Leaves refund and dispute revocation for the next Phase; until then revocation is caused by a payment reported failed after access or by a company decision.
Acceptance criteria
A learner's course is complete when every lesson marked required, quizzes included, is complete on the version they are enrolled on. A course of 10 lessons where 9 are required is complete with those 9 done and the tenth untouched, and not complete with 8 done. A lesson required in a newer version but absent from the learner's version does not hold them back.
The learner sees one completion with its date. Reaching completion twice, for example by sending the last watched range again, leaves one completion.
Architectural guidance
Completion judged against the course as it is today reopens finished courses every time an editor adds a lesson. Completion that can fire twice sends the learner two congratulations and the client two certificates. The cost is a learner who finished and is told they have not, or is told twice.
Acceptance criteria
A learner can ask to move to a newer course version. After the move they see which lessons carried over as complete and which must be done again. Lessons whose video and quiz are unchanged carry over as complete. Lessons whose video or quiz changed, and new required lessons, must be done again. Earlier attempt results are never rewritten.
A completion already reached stands, and so does its certificate: a learner who completed version 1 and moves to version 2 stays complete with a valid certificate. Nothing moves a learner without their asking, so publishing version 2 leaves every enrolled learner on the version they bought.
Architectural guidance
A client that fixes a typo in a video wants learners to benefit without losing credit. If the move wipes progress, the most engaged learners lose weeks of work, and if it happens silently they find a finished course half empty. A learner holding a certificate must not find it questioned because the course was improved.
Acceptance criteria
A certificate is issued once per enrolment, and only after the last required quiz has been graded as passed: a learner whose final quiz is submitted but not yet graded has no certificate. Its code is 12 random characters from the letters and digits without 0, O, 1, I and L, and says nothing about the learner, the course or the date.
A public page, reached by the code without signing in, shows the code, the course title, the issue date, the status (valid or revoked) and the learner's name. A code that does not exist gets a plain not found. The page serves 50 requests per second for 60 seconds with p95 under 200 ms and zero errors on a laptop, and the committed script and its output show it.
Architectural guidance
Employers open the verify page to check certificates. A code that can be guessed lets anyone read other people's certificates, and a code that carries the date or course leaks who studied what. The page is public, so a crowd or a script hitting it must not slow down people who are buying and watching.
Acceptance criteria
A certificate is revoked on a company decision, or when the learner's access ends because their payment was reported failed after access was granted. Refunds and lost disputes revoke it too once the next Phase adds them. A revoked certificate stays on the verify page and shows revoked, with the same code, course title and issue date.
An open dispute only suspends access and leaves the certificate valid. Revoking a certificate twice changes nothing.
Architectural guidance
A certificate that stays valid after the money has gone back tells an employer something the client knows is false. A page that deletes the certificate instead leaves the employer with "not found" and no way to tell why. The client needs the public page to say this one was valid and no longer is.
Acceptance criteria
On request, a learner's name, email and country are erased wherever the platform kept them, and the learner's ID stays. After the request, searching every page and export the platform has for the erased name and email finds nothing. The learner's certificates still verify and show code, course title, issue date and status, without the name.
Orders keep the customer's country, and ledger, tax and traceability records stay, identified by ID. A support lookup of an erased learner shows the ID only. Erasing the same learner twice changes nothing.
Architectural guidance
A person who asks to be erased and still appears by name on a public page makes the client liable for a request it cannot honour. Personal details that have spread across the product get found one at a time, usually by the person who asked. The client also needs its money and tax records to stay, because the tax return must still be reproducible.
Acceptance criteria
A named test, with its command in the README, runs over at least 100 learners, including 6 whose final quiz is graded after all their other work is done, and prints counts. A learner whose last required quiz is submitted but not yet graded has no certificate, and gets exactly one when the grade is a pass.
A completion reported twice, and a process killed between the final grade and the certificate and then restarted, each end with exactly one certificate for the enrolment. A revoked certificate shows revoked on the verify page, and one never revoked shows valid. The test fails on any certificate that exists before its grade.
Architectural guidance
A certificate cannot be quietly taken back once an employer has seen it. A learner who passed and never gets a certificate writes in, because nothing tells the client it is missing.
Architectural walkthrough
Six people received a certificate before their final quiz was graded. Some of them had not yet passed. A certificate for a refunded course keeps showing valid on a public page, so an employer who checks it is told something the client knows is false. A learner who asks to be erased still appears by name on that page, and the client cannot honour the request without breaking verification for the people who look certificates up.
Completion has its own traps. A learner who finished version 1 sees version 2 published with a new required lesson and is told they are no longer complete. A course completed twice sends two certificates. A process that dies between the last grade and the certificate leaves a learner who passed with nothing to show for it, and nobody notices until they write in. Each case costs the client a certificate it cannot stand behind, or a support ticket about one that never came.
Refund and dispute
Produces the refund rule and its versions, the dispute lifecycle, and refunds for cancelled cohorts, refused seats and rights-claim takedowns. Leaves reversing instructor shares for the Phase on payouts.
Acceptance criteria
Your repository holds a document that states the refund rule and lists at least 12 cases you worked out, each with the order, the day of the request and the answer a learner is given. It covers a request just inside and just outside the 14-day window counted from payment confirmation. With no waiver recorded, the legal 14-day withdrawal right applies and the refund is granted. With a waiver recorded, that right has lapsed, and the refund is the company's own guarantee: it is granted only when no more than 20 percent of the order's required lessons are complete, so 20 percent is granted and 21 percent is refused.
It shows the reason given for each grant, withdrawal right or within the guarantee. It covers a rights-claim takedown, a cancelled cohort and a refused seat, which ignore the window and the cut-off, and a refund asked while a dispute is open, which is refused. It states that the rule version in force at payment stays with the order, so a later 30-day guarantee never applies to an order paid under the 14-day one.
Architectural guidance
A refund rule nobody wrote down gets applied by whoever answers the email, and two learners in the same position get different answers. Working the cases first shows where the rule is ambiguous, such as day 13 at 80 percent complete, before the product has to decide it at 15,000 enrolments a month.
Acceptance criteria
A refund request is decided under the rule version and the waiver recorded when the order was paid, whatever the rule says today. A granted refund returns the whole amount with its tax: for the worked order, 3,920 cents back, 626 of it tax, with the 84-cent processor fee absorbed by the platform. The learner's access and playback end, any certificate shows revoked, and the instructor's share of 2,247 cents is reversed on net.
A refused request tells the learner why in plain words. A refund request sent twice refunds once. A refund is refused while a bank dispute is open on the order. Moving the company's guarantee to 30 days leaves a request on an order paid under the 14-day guarantee decided under 14 days.
Architectural guidance
Terms change. If an old order is judged by today's rule, a buyer who paid under 14 days is promised 30 or denied what they were promised, and either way the client breaks its own terms. A refund that returns the money without ending access leaves the buyer with both. A refund that returns only part of the charge turns into a complaint to the card issuer.
Acceptance criteria
The bank opens a dispute on an order up to 120 days after payment, and evidence is due 7 days after it opens. Finance can see, for each open dispute, when it opened and when its evidence is due. While it is open, the learner's new playbacks are refused as suspended, their certificate stays valid, the instructor's share of the order is held, and a refund request on the order is refused.
A dispute won restores playback and releases the share. A dispute lost ends access for good, revokes the certificate and reverses the share. A dispute notice sent twice opens one dispute, and one for an order that does not exist changes nothing.
Architectural guidance
A dispute is the bank taking the money back unless the client answers in time. If the learner keeps watching while it is open, the client loses both the money and the course. If access ends too early and the dispute is won, the client has locked out a paying customer, and missing the evidence date loses the case outright.
Acceptance criteria
When a manager cancels a cohort with 180 paid buyers, all 180 are refunded the whole amount and their access ends, whatever the window and however much they have watched. When a paid buyer is refused a seat, because the cohort is full or the hold expired and the seat was taken, that buyer is refunded and told in plain words that no seat can be given.
Deferring a cohort refunds nobody and moves its dates. A cancellation sent twice refunds each buyer once.
Architectural guidance
A cancelled cohort leaves hundreds of people who paid for something that will not happen, and refunding them by hand takes days and misses some. A buyer who paid for the last seat after the hold expired and hears nothing holds a receipt for a seat that does not exist. The refund window and the lessons-completed cut-off must not decide these, because the client failed to deliver.
Acceptance criteria
As the company's policy, a rights-claim takedown of a course refunds every buyer of that course, whatever the window and however much they watched, even when the notice names only some of its lessons. For a course with 37 buyers, all 37 are refunded the whole amount, their access ends, their new playbacks stop within 1 hour of the notice being recorded, and their instructor shares are reversed. Each refund names the takedown as its reason.
A notice recorded twice refunds each buyer once. A learner cannot buy the course after the notice, because it is off sale.
Architectural guidance
A music publisher's notice sat for 15 hours before anyone acted, and 37 students were then refunded by hand after the instructor had been paid. Every hour a taken-down course keeps playing is an hour the client publishes content it has been told it has no right to. Refunding only the buyers of the named lessons leaves the others holding a course the client cannot defend.
Acceptance criteria
A named test, with its command in the README, shows money leaving once. A refund and a bank dispute for the same order arriving at the same moment move money out once and never return more than the 3,920-cent gross. A refund request sent twice, a dispute closing before it opened, and a refund and a dispute notice arriving in either order each end with one correct outflow.
A process killed after a refund is decided and before the money moves, then restarted, ends with the money moved exactly once. The test prints, for each order, the amount charged, the amount returned and what the buyer sees, and fails if any order returns more than it was charged.
Architectural guidance
A refund and a dispute are two roads to the same money, and when they meet both the client and the bank can pay out. The client cannot recover that from the learner. A crash between deciding and paying leaves a buyer told they were refunded with nothing in their account, or paid twice after a retry.
Architectural walkthrough
A learner asks for a refund on day 13 after watching 80 percent of the course, and nobody can say whether the answer is yes. The company's own guarantee, extended from 14 to 30 days, starts applying to people who paid under the old one, and the client cannot explain why the terms changed after they bought. A bank dispute and a refund arrive for the same order, and the money leaves twice with no way to get either back. After a takedown for a rights claim, 37 students were refunded by hand while the instructor had already been paid.
Cohorts add their own cases. A cohort is cancelled with 180 buyers paid up, and each of them has to be found and refunded. A buyer pays after the 15-minute hold expired and the last seat has gone, and holds a receipt for a seat that does not exist. Each of these costs the client money out twice or not at all, a rule that depends on who answered the email, and refunds nobody can show were decided by the same terms.
Pay instructors
Produces the revenue share, each sale's share, adjustments for refunds and disputes, monthly statements, and a payout run. Leaves nothing to later Phases except the reconciliation in the last Phase.
Acceptance criteria
On the 1st of each month, on the platform's clock, a statement closes for the previous month. It lists the shares that became payable in that month, the adjustments recorded in that month, and the balance carried from the previous statement. A negative total is carried forward and nothing is paid. A positive total below 2,500 cents is carried forward and nothing is paid.
Every line shows the sale it came from, the rate and the amount, and the lines add up to the total. A statement already issued does not change when a later refund, rate change or dispute arrives. The instructor can open it.
Architectural guidance
Contracts say instructors must be able to explain every payout line by line. A statement that does not add up, or whose lines cannot be traced to a sale, becomes a dispute with a contractor. A negative balance that is forgotten means the client pays out money it is owed, month after month.
Acceptance criteria
A payout run pays each issued statement once. Running it twice in a row, or twice at the same moment, pays each statement once. Killing it midway and running it again pays the statements it had not yet paid and none that it had. Each payment arrives at the bank stand-in as one transfer per statement for the statement's total.
The run reports how many statements it paid and how many it skipped as already paid. Statements carried forward are not paid.
Architectural guidance
An operator who sees a payout run die at 14 of 22 contractors will run it again. If the second run pays everyone, 14 instructors are paid twice, and getting that money back from contractors is slow and costs goodwill. If it pays nobody, 8 instructors are paid late.
Acceptance criteria
A named test, with its command in the README, runs the statement and payout run three ways and prints the result of each. Repeated, it pays each statement once. With payouts stopped for 1 hour during the run, every statement is issued once and paid once after payouts come back, and the rest of the platform works meanwhile.
Across at least 200 orders it plays the awkward sequences: a refund arriving before the payment it reverses is confirmed, a dispute closing before it opened, and a refund after payout. For every sequence the statements reconcile to the orders with zero unexplained cents.
Architectural guidance
Money problems appear in combinations, such as a refund landing after payout while a dispute closes and the run is repeated. Each case passes alone in a demo. The cost is cents nobody can account for, and the client's accountant asks about them.
Architectural walkthrough
Finance computed payouts from gross sales, before tax and the processor fee, and corrected refunds by hand. Instructors kept shares of sales that were later refunded, including 37 after a takedown, and the client could not get the money back. A statement that changes after it was sent cannot be trusted, and a contractor who cannot check it line by line has grounds to dispute the contract. A negative balance gets forgotten, so an instructor who owes the client is paid anyway the next month.
The monthly run is the dangerous part. Run twice by mistake, it pays everyone twice. Killed halfway, it leaves some instructors paid and nobody knowing which. A rate change that rewrites old statements makes last quarter's figures differ from what was sent. With 22 outside contractors on a share of sales, each of these costs the client money it cannot easily recover, or their trust.
Notify and report
Produces receipts and other messages, a support timeline per learner, and the quarterly VAT report by customer country. Leaves tracing and recovery of failures for the last Phase.
Acceptance criteria
A learner gets one message when a payment is confirmed (a receipt), one when they complete a course and one when a certificate is issued. An instructor gets one message when a statement is issued. A payment confirmation or completion reported twice sends nothing more. A message is never sent with a missing name or email: when the learner's details cannot be read, the message waits and goes once they can.
Your email provider stand-in can be made to fail, to delay and to accept a message twice. With it failing, delayed or accepting twice, each message reaches the person once, and buying, watching and learning carry on.
Architectural guidance
If sending mail can hold up checkout, an email outage at launch stops sales. A mail provider that fails after accepting a message leaves the client unsure whether to send again, and either answer annoys someone.
Acceptance criteria
Support finds a learner and sees one timeline across registration, order, payment (including a late confirmation), seat hold, access, watching, quizzes, certificate, refund and dispute, in time order with dates. The timeline says in a sentence why the learner can or cannot watch right now, such as payment confirmed but access not yet granted, or the 15-minute hold had expired before the payment arrived.
For a learner whose payment confirmed 40 minutes late, the timeline shows the order, the hold expiring and the confirmation, in that order. An erased learner is shown by ID only. A learner who never bought anything shows an empty timeline and the sentence that they cannot watch because nothing was bought.
Architectural guidance
A learner who paid and cannot get in writes at the worst moment, and support has to open six systems to answer. The answer is often a delay the client cannot see, such as a payment that confirmed 40 minutes late. Every minute of that is paid for by support and by a customer deciding whether to ask for a refund.
Acceptance criteria
Finance gets a quarterly VAT report by customer country for the Netherlands, Germany, France, Ireland and Spain, in a file or page it can open. For each country and quarter it shows tax collected less tax refunded, in cents, and a refund counts in the quarter it is made in, not the quarter of the sale. For the worked order, 626 cents of German tax collected in one quarter and returned by a refund in the next shows 626 collected in the first quarter and 626 refunded in the second.
The report can be generated on request for any past quarter. A failed purchase adds nothing to any figure. Filing the return is out of scope.
Architectural guidance
A refund counted in the wrong quarter changes what is owed to a tax office. The report has to give the same figures whenever it is run.
Acceptance criteria
A named test, with its command in the README, loads at least 500 orders across the five countries, with refunds in later quarters, and shows that every country's figure for every quarter equals the tax on its orders less the tax on its refunds, with zero unexplained cents. A refund made in a later quarter appears in that quarter and leaves the earlier quarter's figure unchanged.
After a learner is erased, generating the report again for a past quarter gives the same figures as before the erasure. The test prints the figures it compared and fails on any difference.
Architectural guidance
A tax figure that changes when someone is erased, or when a refund is made in the next quarter, cannot be filed. The client has to answer a tax office about a quarter that closed long ago. The check exists because the first report could not be reproduced and nobody knew until the accountant tried.
Architectural walkthrough
A learner writes "I paid and cannot get in" and support has to open six systems to find out why, while the learner waits. A receipt that goes out twice, or goes out with a blank name, looks like fraud to the person receiving it. An email provider that is slow or down must not stop people buying or watching, and when it comes back it must not send a week of messages twice. The quarterly VAT return was built from a monthly export that did not hold the customer's country, so the accountant could not reproduce it.
The cost is support hours on every ticket, mail to the wrong person, learners who stop trusting receipts, and a tax return the client cannot defend.
Operate the platform
Produces recovery of anything that failed or was missed, an update to one capability while the others serve, a stop-one-at-a-time proof, the launch-day peak, and the full simulated day. Leaves nothing.
Acceptance criteria
An order, message or report that still fails after 5 attempts stops being retried and shows up for an operator, and everything else carries on. The operator sees what failed, for which learner or order and why, and can retry it once the cause is fixed. The retry takes effect once.
With the payment provider's delivery down for 3 hours, the confirmations it sent meanwhile are recovered afterwards by the operator asking for what was sent since a time. The provider retries for up to 3 days, and a manual resend reaches back 15 days. Every purchase ends as if its confirmation had arrived on time, with none granted twice and none missed. Asking for the same period twice changes nothing.
Architectural guidance
One purchase that fails on bad data, if it holds up the thousands behind it, turns one problem into an outage. Confirmations missed during an outage leave people who paid with no access until someone notices. Retrying blindly after a fix can grant access twice or refund twice, so the operator needs to see what failed and retry it exactly once.
Acceptance criteria
The platform starts recording the payment method of every new purchase, card or bank debit, as reported by the payment provider stand-in. It is shown on the receipt and in the purchase's record, while learners keep buying and watching. Purchases made before the change show no payment method and are otherwise unchanged.
The update runs with the simulator buying at 120 orders a minute and 250 viewers watching. No purchase is lost or doubled during it, no entitled learner is refused a lesson, and every receipt sent during the update is correct.
Architectural guidance
A change to what a purchase records, made while people are buying, can lose or double a sale, or print a wrong receipt. The client cannot pick a quiet hour, because courses launch on the instructor's schedule. A stop for an update is a stop in sales.
Acceptance criteria
A named test, with its command in the README, stops each of these in turn and prints what still worked and what the user saw: publishing; the video host; buying; seat booking; issuing playback links; progress, quizzes and certificates; refunds and disputes; payouts; messages; reports and the support timeline; the payment provider.
With publishing stopped, buying, watching, progress, certificate verification, refunds and payouts work, and authors are told to try again. With the video host stopped, buying, watching ready lessons, progress and publishing a version whose videos are ready work, and uploads show the host unavailable. With buying stopped, watching, progress, quizzes, certificates and payouts for earlier sales work, and checkout answers "try again". With seat booking stopped, self-paced buying, watching, progress and certificates work, and cohort checkout answers "try again".
With playback links not issuable, buying, progress from players already running, quizzes and certificate verification work, new playbacks answer "try again", and links already issued keep playing for 30 minutes. With progress, quizzes and certificates stopped, buying and watching work, and watched time sent meanwhile counts once when they are back, with no certificate lost or doubled. With refunds and disputes stopped, buying, watching and learning work, and a refund asked meanwhile is decided once when they are back. With payouts stopped, everything else works, and statements wait and are issued once.
With messages stopped, everything else works and messages go out once when they are back. With reports and the support timeline stopped, everything else works and reports catch up. With the payment provider stopped, watching, progress, quizzes and certificates work, checkout answers "try again", and the missed confirmations are recovered afterwards.
Architectural guidance
A platform where any one stopped part takes the rest down fails more often than its parts do. The client chose the pairs in this check, such as cohort checkout failing politely while self-paced buying carries on, because they protect revenue and paying learners.
Acceptance criteria
A named script, with its command in the README, runs the peak on the simulator's clock and prints the figures: 3,600 orders in one peak of 120 a minute for 30 minutes, 250 viewers starting a lesson as a 300-seat cohort opens, and the certificate verify page at 50 requests per second for 60 seconds with p95 under 200 ms and zero errors, measured on a laptop.
Throughout, at least 95 percent of learners open the course within 5 seconds of their payment confirming, and no order is lost or doubled. The output is committed to your repository.
Architectural guidance
The launch day brought 20 times normal traffic. Checkout slowed playback, and learners who had paid sat waiting for access. A platform that holds at 500 enrolments a day and fails at 10,000 fails on the day the client has paid for the audience. The numbers in this check come from the day that went wrong.
Acceptance criteria
A named script, with its command in the README, runs the launch day on the simulator's clock: 10,000 enrolments, a peak of 3,600 orders, and 250 viewers at the start of a 300-seat cohort. In the same run it causes these failures: 10 percent of payment confirmations up to 40 minutes late; 5 percent of payment messages twice; the payment provider's delivery down for 3 hours with the missed confirmations recovered afterwards; the video host down for 2 hours; seat booking stopped for 30 minutes while cohort checkouts keep coming; each capability stopped once; a rights-claim takedown recorded mid-day for a course with 37 buyers; a pass mark raised from 70 to 80 mid-day; the last seats of a cohort bought at once; and, after the clock passes the end of the month, payouts stopped for 1 hour during the statement and payout run.
It writes its results to a file committed to your repository, prints counts and differences, and exits with status 0 only if all of these hold. Every order's gross, tax, fee, refunds, shares, statements and the VAT report reconcile with zero unexplained cents. For every refunded, dispute-lost and payment-failed order, the learner has no access and a new playback is refused. No certificate exists without a completion or twice, and every certificate for a refunded or dispute-lost enrolment shows revoked. Each message went out once. 95 percent of learners opened the course within 5 seconds of their payment confirming. No cohort was sold above its limit. Cohort checkout answered "try again" while seat booking was stopped, and self-paced checkout failed nowhere. All 37 buyers were refunded and their shares reversed, and the pass-mark change rewrote no earlier result.
Architectural guidance
The failures of the launch day arrived together, and a platform tested against one failure at a time proves little about that. A mismatch shows up afterwards as a refunded learner still watching, a certificate for money returned, or cents the accountant cannot explain. This run checks money, rights and certificates against each other, because that is where the client found the damage.
Architectural walkthrough
The launch day showed that nobody knew what had failed, in what order, or whether anything was lost. One bad item held up everything behind it. At 20 times normal traffic, with payment confirmations late, the video host down and a cohort starting, the failures arrived together and the client had to find out afterwards what had gone wrong.
A change to what a purchase records, made while people are buying, can lose or double a sale. One stopped part of the platform that takes the rest down is the original problem back: playback stalled because checkout was busy, and people who had paid could not start a lesson. The cost is a launch day that becomes a news item, money and rights that disagree afterwards, and an operator who cannot say what happened or whether it is safe to retry.
Architectural walkthrough
Two questions the old system answered with a guess
The old system answered "may this person watch?" and "have they finished?" with one yes or no each, and a payment confirmation, a refund, a support agent and a nightly clean-up all changed them. Nobody could say which change came last. 310 paying learners saw "payment required" because the flag had not been set yet. A refunded learner kept watching until a session cookie expired.
For any learner, your build has to say why they can or cannot watch and what they have completed, and two people asking at different moments must get the same answer. Check it by picking a learner after a bad day and asking both questions.
Rules change while learners are mid-course
An editor raised a quiz's passing score from 70 to 80 and 112 learners who had already passed were failed. An instructor who adds a lesson changes the progress of everyone enrolled. A refund request is judged by today's rule and not the one in force on the day the learner paid. A change to the revenue share rewrites a statement that finance already sent.
Each of these hurts for the same reason: something recorded in the past was judged again under a rule that did not exist yet. A learner moves to a newer version of a course when they ask to, and never because the platform moved them. Check each change by making it mid-run and confirming that nothing recorded before it reads differently afterwards.
The right to watch has a deadline
The launch-day spike in checkout stalled lesson playback, so people who had paid and were entitled to watch could not start a lesson. Starting a lesson must not wait on anything that can be busy or stopped.
The opposite failure costs money. A refunded learner who can still start lessons is watching content the client has handed back the price of. The client accepts a bounded delay: a video already playing may finish, and a new playback link lasts 30 minutes. Check that an entitled learner can still start a lesson while buying, publishing and sign-up are stopped, and that a refunded learner cannot renew once the link they hold has run out.
The video host's words are not the company's
The video host reports late, twice, out of order, and sometimes about a video nobody uploaded. For the host, "ready" means the encode finished. For the company, it means encoded and captioned. During the weekend that lesson said "processing", nobody could separate a failed encode from a late notification, and 180 learners were due to start on Monday.
Check that every lesson shows one plain state, that a video which cannot be used shows a plain reason, and that no host word appears in anything an instructor, a learner or an operator reads.
One refund changes four things
A refund ends the learner's access, ends their right to start a lesson, revokes their certificate, and reverses the instructor's share. Each of the four can be missed or can happen late. When one is missed, the client pays for it: 37 buyers were refunded after a takedown while the instructor had already been paid for those sales, and six people held a certificate for a course they had not passed.
Check by refunding an order and then looking at all four. After the dust settles, none of them may still stand.
Where it shows if you cut a corner
A cut corner shows up as a number that does not match: a refunded learner who can still start a lesson an hour later, a certificate for an enrolment that was never graded, a statement that no longer adds up after a refund, a seat count above a cohort's limit, or a purchase that shows "waiting for payment" for good because one confirmation was lost. The launch day compares money, rights and certificates against what the simulator did, so a mismatch has nowhere to hide.
Related Links
- GDPR Article 17, right to erasurename, email and country are erased on request while ledger, tax and traceability records stay.
- GDPR in the Netherlands: age of digital consentlearners under 16 need legal input, so sign-up asks for an adult confirmation.
- Your Europe: returns and withdrawala refund decision uses the withdrawal waiver recorded when the order was paid.
- Stripe Netherlands pricingthe stand-in reports a fee of 1.5 percent plus 25 cents on a card issued in the European Economic Area.
- Stripe: webhooksan operator can list what the provider sent since a chosen time, back to 15 days, and ask for a resend.
- 17 U.S.C. 512(c), takedown of infringing materiala lesson named in a rights-claim notice must be removed expeditiously, and its buyers are refunded.