Skip to main content

Overview

Use the Payment Gateway API when you build your own checkout or backend.

1. Get your API key

Sign in to your PlasBit Merchant account and copy your API key. See Create an API Key.

2. Pick an environment

EnvironmentBase URL
Sandboxhttps://api-test.plasbit.com
Productionhttps://api.plasbit.com

Start in sandbox. See Environments for details.

3. Authenticate

Send the API key on every request:

Authorization: Bearer YOUR_API_KEY

Full details: Authentication.

4. Create a payment

POST /v1/payments

You receive a checkout URL for the customer. Details: Create Payment.

5. Handle the return and status

  1. Customer pays, then returns to your redirect URL.
  2. PlasBit notifies your callback URL (server-to-server).
  3. Optionally poll Payment Status with the payment ID.

See Callbacks and Webhooks.

6. Handle errors

Use standard HTTP status codes and the JSON error body. See Errors.

tip

Test the full loop in sandbox before switching your base URL to production.