Commit graph

3 commits

Author SHA1 Message Date
9f557d7e7a chore(scripts): rename contributionTier → contributionAmount in seed + legacy migration 2026-04-19 19:10:37 +01:00
549a849bc0 fix(scripts): helcim plan-create payload shape + empty-GET handling
Verified against the live Helcim v2 API during the deploy migration:
- POST /payment-plans requires { paymentPlans: [plan] } wrapper (mirrors
  the POST /subscriptions shape), and response is { data: [plan] }.
- taxType 'customer' rejects as ERR_VALIDATION_FAILED; must be 'no_tax'
  with taxCalculation 'country_province'.
- termLength:1 rejects when termType:'forever' — drop the field.
- GET /subscriptions returns an empty body (not JSON) when no subs exist;
  tolerate that instead of failing with 'Unexpected end of JSON input'.

Plans created in the Helcim account: Monthly=50302, Annual=50303.
2026-04-18 20:58:17 +01:00
daea8b65be feat(scripts): helcim plan consolidation migration (dry-run default) 2026-04-18 18:12:43 +01:00