Skip to content

Developers

Build on top of your MoonClerk account

MoonClerk handles the checkout, the recurring billing, and the failed-payment recovery. When you need that data in your own systems — or need a form to behave like part of your product — there is a REST API, webhooks, and a set of checkout hooks to reach for.

curl https://api.moonclerk.com/forms \
  -H "Authorization: Token token=YOUR_API_KEY" \
  -H "Accept: application/vnd.moonclerk+json;version=1"

Generate an API key at app.moonclerk.com/settings/api-key. Endpoints are /forms, /customers and /payments, each supporting a list and a single-record read.

What you can build

Every capability below is available on every MoonClerk plan — there is no developer tier and no per-call pricing.

Read the REST API

A read-only, REST-style API over your forms, customers, and payments. Authenticate with an API key passed as an authorization token, and request a version through the Accept header.

Receive webhooks

Subscribe to MoonClerk events and have them delivered to your own endpoint, so your systems react the moment a payment succeeds, fails, or a subscription changes.

Pre-fill checkouts

Pass an amount, name, email, or your own custom field values into a payment form from a URL, so payers arrive at a checkout that is already filled in.

Track payers through checkout

Hook into the checkout lifecycle to attribute conversions in your own analytics, rather than inferring them after the fact.

Restyle payment forms

Apply custom CSS to any form so an embedded MoonClerk checkout matches the site around it, down to the pixel.

Start from a template

Two open-source Gatsby starters — one for payments, one for donations — build a landing page that already accepts money.

Before you start

Three things worth knowing up front, so you do not design around a capability that is not there.

  • The API is read-only. Every operation is a GET over forms, customers, and payments. Creating and editing forms, plans, and pricing happens in the MoonClerk interface.
  • MoonClerk runs on Stripe. A Stripe account is required. Payouts, per-transaction fees, and the list of supported countries are Stripe's.
  • There are no official client libraries. Call the API directly over HTTP. Any MoonClerk package you find on a language registry is third-party and unmaintained.