Skip to content

Conversation

@emma-sg
Copy link
Member

@emma-sg emma-sg commented Oct 28, 2025

For context & flow diagram, see https://github.com/webrecorder/cashew/pull/59

@emma-sg emma-sg marked this pull request as draft October 28, 2025 22:45
@emma-sg emma-sg force-pushed the additional-minutes-addon-purchase branch from 2e3d18d to 8b226f8 Compare October 30, 2025 21:23
- add get_checkout_url method to create checkout session for additional
minutes - add /checkout/execution-minutes endpoint to handle addon
purchase requests (this will need to be updated in dev/prod playbooks) -
update CI workflows to remove portalUrl suffix from secret value - add
test endpoint in echo server to mock checkout response
convert to json before converting to output type

more debugging

fix model type

pass return url to checkout session request

fix fn ordering

correctly pass in headers

include content-type header

fix double encoding as json

properly dump model to dict in requests
try using `org_dep` directly in quotas endpoint

this should be safe, since there's still a check for if user is
superuser

allow shared secret in org dep
- adds separate "add-ons" section to display extra execution minutes and
gifted execution minutes when present - renames renderQuotas to
renderMonthlyQuotas for clarity
@emma-sg emma-sg force-pushed the additional-minutes-addon-purchase branch from 4ee2020 to 82a6295 Compare November 4, 2025 23:40
entire orgs router

- renames `shared_secret_or_active_user` to `shared_secret_or_superuser`
to better reflect that it only allows superuser, not all users - moves
the `quotas` endpoint to the app router to allow using
`org_superuser_or_shared_secret_dep` dependency specifically - removes
its user dependency & extra check for superuser, since user is required
to be superuser in `superuser_or_shared_secret_dep` (depended on by
`org_superuser_or_shared_secret_dep`) - adds a couple more types to
`init_subs` arguments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants