Discovering Dual Stripe Accounts: Payment Link Generation and Credential Architecture
What Was Done
Generated a Stripe payment link for a charter balance payment with automatic credit card processing fee calculation. The task revealed a critical credential architecture issue: the estate maintains two separate Stripe accounts with distinct branding, and the existing payment-link tooling was misconfigured to use the wrong account for client-facing transactions.
Technical Details: Payment Link Generation
The payment link creation involved three technical layers:
- Amount calculation: Base balance ($3,250) + 2.9% card processing fee = $3,344.25 (fee = $94.25)
- Stripe API endpoint:
POST /v1/payment_linkswith line_items array containing description, amount, and currency - Line item metadata:
"July 4 Fireworks Charter — Balance Due (Dylan Osborne) — incl. 2.9% card processing fee"rendered on customer checkout and merchant receipt - Account selection: Routed to Sail JADA Charters LLC account (not Dangerous Centaur) to ensure customer card statement reads
SAIL JADA, not an unrelated business name
The link was verified live (HTTP 200, active) with the checkout page displaying correct branding and total amount before forwarding to the customer.
Infrastructure: Dual Stripe Account Architecture
The discovery surfaced a credential split that was previously undocumented in infrastructure memory:
-
Dangerous Centaur account: Stored in
~/.repos.env(or viaadam-cherry-checkoutLambda environment variable in us-east-1), used fordangerouscentaur.comorders (separate business entity) -
Sail JADA Charters LLC account: Stored as
JADA_STRIPE_SECRET_KEYenvironment variable on theshipcaptaincrewLambda, used for charter-related payments
Both accounts have distinct merchant IDs (acct_1TCmJe3IcHtrGhWm for JADA) and will render different branding on customer checkouts and bank statements. This separation is intentional—each business entity requires its own Stripe account for accounting and tax reporting.
Credential Access Pattern
The two accounts are accessed via different routes:
# Dangerous Centaur: sourced from local repos.env (Mac development)
# Used by adam-cherry-checkout Lambda for dangerouscentaur.com orders
# Sail JADA Charters LLC: sourced from shipcaptaincrew Lambda environment
# Used for all JADA charter-related payments (preferred for client-facing links)
For Mac-based payment link generation, the JADA key is retrieved from the Lightsail shipcaptaincrew Lambda environment (since the memory constraint notes that Mac cannot directly reach api.stripe.com). This follows the established pattern: headless/API operations run via Lightsail to avoid network reachability issues.
The Tooling Issue: jaja-payment-link Script
The repository includes a pre-built payment-link utility at ~/bin/jada-payment-link. During this session, the script was not used because it currently points to the Dangerous Centaur Stripe key (the wrong account for JADA charters). Any payment link generated by that script renders Dangerous Centaur branding to the customer—unacceptable for charter invoices.
The script exists for valid reasons (DRY principle, consistent fee calculation), but it requires a fix: the hardcoded or environment-sourced Stripe key must be repointed at JADA_STRIPE_SECRET_KEY (the shipcaptaincrew Lambda key) before it can be safely used for client-facing transactions.
Key Decisions
- Direct API call vs. script: Rather than debug the existing script in production, the payment link was created via direct Stripe API call using the verified JADA key. This ensures immediate correctness and avoids deploying a misconfigured tool.
- Fee inclusion: The 2.9% processing fee ($94.25) is added to the customer's balance and included in the line item description. This is transparent on the checkout page and receipt. The fee is not absorbed internally—the customer pays the full amount including fees.
- Branding selection: Sail JADA Charters LLC account was chosen explicitly to match customer expectations and internal accounting (charter revenues post to the JADA merchant account, not Dangerous Centaur).
- Credential discovery: This session revealed that the infrastructure memory did not accurately reflect the dual-account architecture. The finding was recorded immediately to prevent future credential misrouting.
What's Next
Two follow-up tasks are pending:
-
Fix ~/bin/jada-payment-link: Update the script to source
JADA_STRIPE_SECRET_KEY(from Lightsail shipcaptaincrew Lambda or local secret store) instead of the Dangerous Centaur key. Once corrected, this script can be the standard tool for generating charter payment links, eliminating manual API calls. - Credential consolidation audit: Review all locations where Stripe keys are stored (repos.env, Lambda environments, local secret files, etc.) and ensure a single source of truth for credential distribution. This reduces the risk of tools silently using the wrong account.
- Ledger entry: When Dylan Osborne's payment clears, the $3,344.25 transaction will be recorded in the financial ledger and his charter status updated to "cleared to depart."
The payment link is live and ready for delivery to the customer.
```