1
0
Fork 0
mirror of https://github.com/tldr-pages/tldr.git synced 2025-04-29 23:24:55 +02:00
tldr/pages/common/stripe.md

25 lines
602 B
Markdown
Raw Normal View History

2020-04-07 02:59:20 +08:00
# stripe
2020-04-16 04:19:45 +01:00
> Interact with a Stripe account.
> More information: <https://docs.stripe.com/stripe-cli>.
2020-04-07 02:59:20 +08:00
2020-04-16 04:19:45 +01:00
- Follow the logs of activity on the account:
2020-04-07 02:59:20 +08:00
`stripe logs tail`
- Listen for events, filtering on events with the name `charge.succeeded` and forwarding them to localhost:3000/events:
`stripe listen --events="{{charge.succeeded}}" --forward-to="{{localhost:3000/events}}"`
- Send a test webhook event:
`stripe trigger {{charge.succeeded}}`
- Create a customer:
`stripe customers create --email="{{test@example.com}}" --name="{{Jenny Rosen}}"`
2020-04-16 04:19:45 +01:00
- Print to JSON:
2020-04-07 02:59:20 +08:00
2020-04-16 04:19:45 +01:00
`stripe listen --print-json`