Skip to main content

Account Setup

Before you write any code, collect two credentials from your AccruPay dashboard and connect at least one payment provider.

1. Get your credentials

Open the AccruPay dashboard and navigate to Settings → API Keys.

CredentialWhere it goesHeader / Prop
API SecretBackend only — never in browser codeaccrupay-api-secret
Merchant Public IDFrontend — safe to expose in client bundlesmerchantPublicId
danger

Never include the API Secret in frontend code, client bundles, or public repositories. It authenticates all backend operations on your behalf.

API Secret

Used by @accrupay/node and raw GraphQL calls from your server:

import AccruPay from '@accrupay/node';

const sdk = new AccruPay({
apiSecret: process.env.ACCRUPAY_API_SECRET, // never hardcode
});

Merchant Public ID

Used by @accrupay/react in your checkout frontend:

<AccruPay merchantPublicId="your-merchant-public-id" transactionSessionId={sessionId}>
{/* payment fields */}
</AccruPay>

2. Connect a payment provider

AccruPay routes payments through your own payment provider accounts — you keep your existing provider relationships and pricing.

To add a provider:

  1. Go to Settings → Payment Providers in the AccruPay dashboard.
  2. Select a supported provider.
  3. Enter the credentials from your provider account (API keys, merchant ID, etc.).
  4. Save. AccruPay validates the credentials and marks the provider as active.

For provider-specific credential requirements, see the Provider Integrations section in the sidebar.

tip

If you don't have a payment provider account yet, connect your sandbox credentials first. Most providers offer free sandbox environments — you can complete your full integration and testing before going live.

3. Sandbox vs. production

AccruPay uses the same API surface in both environments. Sandbox credentials (both your AccruPay API Secret and your provider sandbox keys) keep all transactions isolated from real money.

SandboxProduction
AccruPay API SecretSandbox key from dashboardProduction key from dashboard
Provider credentialsProvider sandbox / test keysProvider live keys
Real moneyNoYes
Node SDK environment'sandbox''production'
React SDK environment"sandbox""production"

Use sandbox throughout development and CI. Switch to production only when you are ready to go live — see the Go Live checklist.

Next steps