Skip to content

Instantly share code, notes, and snippets.

View jevon's full-sized avatar

Jevon MacDonald jevon

View GitHub Profile
@jevon
jevon / pricing.json
Created March 29, 2023 09:32
Features with a single tier that has a base price of 0 will now be converted to metered+per_unit in Stripe.
{"plans": {"plan:pro@0": {"features": {"feature:seats": {
"tiers": [{"price": 500}]
}}}}}
// In service.js
// top-level methods all just work if process.env.TIER_API_KEY is set
// set TIER_API_KEY=STRIPE_API_KEY
import { subscribe, report, can } from 'tier'
await subscribe(`org:${id}`, 'plan:pro@123')

Keybase proof

I hereby claim:

  • I am jevon on github.
  • I am jevonm (https://keybase.io/jevonm) on keybase.
  • I have a public key ASBTxwuMjsm5BBQgcbg34uGWGecxuIK9MShD5AamlrtGmgo

To claim this, I am signing this object: