feat(itineraries): partner itineraries API (#51) #156
No reviewers
Labels
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
primatekuntech/kws!156
Loading…
Reference in a new issue
No description provided.
Delete branch "feat/partner-itineraries-51"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
What
Partner itineraries, API half of #51 (the web pages are PR B, the ADR and notes are Task 7). A tour operator saves a draft plan (customers of its organization, parks with dates, extras), gets the exact server-side quote, then requests payment: one pending
tour_portalsale per park and currency, linked to the itinerary, which becomespending_payment. Paying, invoices, refunds and cancel are #52.itineraries,itinerary_customers,itinerary_parks,itinerary_extras,itinerary_sales,transaction_lines.holder_name(tickets carry each traveller's name).sales.ItinerarySales(Quote and Create share one pricing function, so the quote is the charge): whole stay priced day by day, KES if every day is natively priced else USD, extras per day times quantity, limited-seat products refused.internal/itineraries(service, pgstore, handler):/v1/orgs/{id}/itinerarieslist, create, get, update, delete,/quote,/request-payment(idempotent; purchase rate class).itinerary_pending_days(default 7)./v1/mereads, pay gate, QR and documents until #52 decides organization payment.Review
Dual pass: ponytail-review (1 finding fixed, 1 deferred) then a fresh Opus reviewer (3 Important fixed, minors deferred; see the ledger). Rulings and deferred items are
[verify]for the owner.Checks
make lint: 0 issues.make contract: green (every operation exercised). Coverage (make cover): 91.6% total (minimum 80%); itineraries 95.7%/86.0%.Owner questions: whole stay must be priced; extras charged per day times quantity; limited-seat products for operators; the KES-then-USD rule; itinerary status after its sales expire; payment method
walleton an immutable column.🤖 Generated with Claude Code
Routes under /v1/orgs/{id}/itineraries (list, create, get, update, delete, quote, request-payment), OpenAPI operations and schemas, live contract test, wiring, and the purchase rate class for request-payment. Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>