Skip to content

Commit

Permalink
Update docs about /billing/modify
Browse files Browse the repository at this point in the history
  • Loading branch information
joshnuss committed May 13, 2024
1 parent 8ace6b3 commit 3d5b6ce
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions apps/docs/src/routes/endpoints/+page.md
Original file line number Diff line number Diff line change
Expand Up @@ -25,12 +25,12 @@ Just link to `/billing/portal`

### Create an upgrade button

When user clicks the button, `POST` to `/billing/modify` and pass `plan=pro` as a query param:
When a user clicks the button, `POST` to `/billing/modify` and pass `id` as a query param. The `id` can be either a price id, product id or lookup key.

```svelte
<script>
function upgrade() {
return fetch('/billing/modify?plan=pro', {
return fetch('/billing/modify?id=price_1234', {
method: 'POST'
})
}
Expand Down

0 comments on commit 3d5b6ce

Please sign in to comment.