Lark - Integrate billing into a convex app in minutes
I’m the founder of https://uselark.ai/ - we’re building a new billing platform to make billing integrations simple. Over the last few weeks I have talked to several convex users that complained about how setting up billing for their apps was still a frustrating experience for them. So I went ahead and created a fun little app https://larkbillingconvex.netlify.app/ and set up billing for it using Lark - just to show billing doesn’t have to be complicated.
The entire billing setup was done in this single PR by following this quickstart guide. At a high level we -
1. Create our rate cards in the Lark dashboard. In this case I created 3 rate cards
a. Free plan - every new users starts off on this with 5 credits to use
b. Starter plan - $20 per month that gives you 20 additional credits
c. Premium plan - $100 per month that gives you 100 additional credits and you’re charged $1 per additional usage if you go over
2. On user sign up, we create a lark customer and subscribe them to the free plan.
3. On every game attempt, we report usage for customer to lark (this ensures credits are consumed)
4. On frontend we fetch billing state using lark sdk to a) show how many credits are remaining and b) facilitate upgrades to other plans
5. Once a user runs out of credits they have to upgrade so they can continue to play. This is facilitated by simple API calls to Lark’s change subscription rate card API
6. We also let users cancel their subscription by using the Lark customer portal.
Just wanted to share this here in case it helps some of you with your billing setups! If there is interest we’d also be open to providing dedicated SDKs for convex users to make things even easier. If you have any feedback or would like to use Lark for your billing - feel free to book some time here or reach out at team@uselark.io




Sets up billing for https://larkbillingconvex.netlify.app/ by following the Lark quickstart guide.
There are 3 pricing plans -
Free - comes with 5 credits per month. Every new user is subsc...
