Revenue attribution
Gumroad
Connect Gumroad with a view_sales access token and a Ping URL so ProductLense records sales, memberships, refunds and Gumroad's fee.
ProductLense reads your Gumroad sales and memberships, with Gumroad's fee and the refund and chargeback flags on each sale. ProductLense only reads: it never writes to your Gumroad account, never refunds, cancels or changes anything.
What you need
| Field | Secret | Where to find it |
|---|---|---|
| Access token | Yes | An OAuth access token from an application with the view_sales scope (Settings → Advanced → Applications). |
Every plan includes one billing connection per site, Free too; Growth and Scale allow any number. See plans and limits.
Permissions
The token needs only the view_sales scope. ProductLense calls GET /v2/user (to check the token), /v2/sales, /v2/sales/{id} and /v2/subscribers/{id}.
Set up
- In Gumroad, open Settings → Advanced → Applications, create an application and generate an access token with
view_sales. - In ProductLense, open your site's Settings → Billing connections → Gumroad, paste the token and click Connect and import history.
- Copy the webhook URL from the connection card.
- In Gumroad, open Settings → Advanced and paste the URL into the Ping endpoint field. Save.
Webhook
URL (the Ping URL): https://api.productlense.app/api/webhooks/gumroad/<connection-id> (ProductLense shows the exact URL after you save).
ProductLense accepts Gumroad's sale pings and membership (subscriber) pings: sales, refunds, disputes and chargebacks, cancellations and subscription updates.
Verification: Gumroad pings are not signed. ProductLense therefore trusts nothing in the ping itself. It re-fetches the sale (or subscriber) from the Gumroad API with your token and checks that the email, price and product match before recording anything.
What ProductLense reads
- Customers: the buyer's email and purchaser id from each sale.
- Subscriptions: memberships, from sales and subscriber pings.
- Payments: sales.
- Refunds and chargebacks: the
refundedflag reverses the full price (Gumroad does not expose partial refund amounts); a chargedback or disputed sale is recorded as a chargeback. - History: the last 12 months on first connect, then a nightly reconcile at 03:00 UTC from the last sync minus 48 hours.
How fees are derived
The fee is gumroad_fee on each sale, Gumroad's whole cut including payment processing. It is reported by Gumroad, not estimated.
Match payments to visitors
ProductLense reads the user id from the sale's custom fields: pl_user_id, user_id, userId or uid. Add a custom field named pl_user_id to the product and fill it from your app, for example by prefilling the checkout link. A ProductLense visitor id in pl_visitor_id or visitor_id is also accepted. Without either, ProductLense falls back to the buyer email, matched to the email trait sent with identify, or to a user id that is that email.