Quickstart
Deploy a store, sell a product with license keys, and check a key from your app.
-
Deploy your store
Click Deploy to Cloudflare. Cloudflare copies Plumtier into your GitHub and Cloudflare accounts and sets up the database and file storage. When asked, set
ENCRYPTION_KEYto a long random value (openssl rand -base64 32) and keep a copy.Open your store's address and go to
/adminto choose your dashboard password. -
Connect Stripe or PayPal
In Settings → Payments, paste a Stripe restricted key or a PayPal app's client ID and secret. Plumtier checks the credentials, encrypts them, and registers the webhook it needs to confirm payments.
TipStart with Stripe test keys (rk_test_…) and PayPal sandbox credentials. Test orders are labeled and left out of analytics. -
Add a product with license keys
In Products → New product, set a price, upload your download, and turn on License keys. Choose how many devices each key may activate. Add options like Personal (1 Mac) and Family (5 Macs) if you want different limits per price.
Set the status to On sale. Your product page is now at
https://shop.example.com/p/your-product. -
Make a test purchase
Open the product page and buy it with a Stripe test card. You land on a receipt page with your license key and download, and get the same by email once email is set up.
-
Activate the key from your app
On first launch, send the key and a name for the device:
curl https://shop.example.com/api/v1/licenses/activate \ -d license_key="7KQ2M-XW9PA-4TB8N-R2HDE" \ -d instance_name="Ada's MacBook Pro" \ -d product_id="your-product"const response = await fetch("https://shop.example.com/api/v1/licenses/activate", { method: "POST", headers: { "Content-Type": "application/json" }, body: JSON.stringify({ license_key: key, instance_name: "Ada's MacBook Pro", product_id: "your-product", }), }); const result = await response.json();var request = URLRequest(url: URL(string: "https://shop.example.com/api/v1/licenses/activate")!) request.httpMethod = "POST" request.setValue("application/json", forHTTPHeaderField: "Content-Type") request.httpBody = try JSONEncoder().encode([ "license_key": key, "instance_name": "Ada's MacBook Pro", "product_id": "your-product", ]) let (data, _) = try await URLSession.shared.data(for: request)import requests result = requests.post("https://shop.example.com/api/v1/licenses/activate", json={ "license_key": key, "instance_name": "Ada's MacBook Pro", "product_id": "your-product", }, timeout=10).json()Store
instance.idfrom the response. On later launches, call validate with the key and that id. The integration guide covers offline use and every state a key can be in.