Documentation

Sample Workspace

Sample Workspace

PerfectPay provides a one-click sample workspace that provisions a complete sandbox environment with realistic test data. Instead of manually creating merchants, connectors, and payments, the sample workspace gives you a fully populated account to build and test against immediately.

What Gets Created

When you provision a sample workspace, PerfectPay generates:

Test Connectors (5 pre-configured)

ConnectorSimulatesPayment Methods
sample_stripe_testStripeCard (Credit, Debit)
sample_paypal_testPayPalCard, Bank Debit
sample_fednow_testFedNowReal-Time Payments (FPS)
+ 2 additionalVariousMixed rails

All connectors are pre-wired with test credentials and ready to process sandbox payments. No real money moves.

Sample Payments (100+ records)

The workspace generates 100 payment intents spread across a 6-week history with realistic distribution patterns:

Amount distribution:

TierRangeShare
Micro$5 – $5040%
Medium$50 – $50030%
Large$500 – $2,00020%
Enterprise$2,000 – $5,00010%

Currency mix: USD (70%), EUR (15%), GBP (10%), CAD (5%)

Payment method mix: Card (60%), Bank Debit (20%), Real-Time Payment (15%), Crypto (5%)

Status distribution: Succeeded (75%), Failed (10%), Refunded (8%), Disputed (5%), Processing (2%)

Authentication: 3DS (30%), No-3DS (70%)

Customer Profiles (50 diverse profiles)

The workspace includes 50 test customers across 25+ countries with realistic names, email addresses, and metadata. Each customer has payment history tied to the sample payments.

Agent Commerce Data (when enabled)

If your account has agent commerce enabled, the workspace also generates:

  • 25 products across 8 categories with GPC codes
  • 8 agent categories with real-world examples
  • Seller and buyer agent configurations
  • 47+ agent commerce transactions across multiple protocols (ACP, UCP)
  • 12 negotiation records with various outcomes
  • 8 approval workflows
  • 42 orders with realistic status progression
  • 7 days of analytics history

Provision a Sample Workspace

POST /sample_workspace

GET //sandbox.perfectpay.ai/sample_workspace
curl https://sandbox.perfectpay.ai/sample_workspace \
  -X POST \
  -H "api-key: YOUR_SECRET_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{}'

The workspace takes a few seconds to provision. Connectors, payments, customers, and analytics data are all created atomically.

Check Provisioning Status

GET /sample_workspace/status

GET //sandbox.perfectpay.ai/sample_workspace/status
curl https://sandbox.perfectpay.ai/sample_workspace/status \
  -H "api-key: YOUR_SECRET_API_KEY"

Generate Ongoing Activity

After the initial provisioning, use the trickle endpoint to generate a steady stream of new payments. This is useful for testing real-time analytics, webhook handlers, and dashboard displays.

POST /sample_workspace/trickle

GET //sandbox.perfectpay.ai/sample_workspace/trickle
curl https://sandbox.perfectpay.ai/sample_workspace/trickle \
  -X POST \
  -H "api-key: YOUR_SECRET_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{}'

Each trickle call generates a batch of new payments with the same realistic distribution as the initial workspace.

Reset the Sample Workspace

DELETE /sample_workspace

GET //sandbox.perfectpay.ai/sample_workspace
curl https://sandbox.perfectpay.ai/sample_workspace \
  -X DELETE \
  -H "api-key: YOUR_SECRET_API_KEY"

This removes all sample data (payments, customers, connectors) created by the workspace. Your real sandbox data is not affected — sample records use test_ prefixed IDs that are tracked separately.

How Sample Data Is Isolated

All sample workspace records use identifiable prefixes:

ResourceID Pattern
Paymentstest_pay_...
Refundstest_ref_...
Disputestest_dis_...
Customerstest_cust_1 through test_cust_50

This means you can mix sample data with your own test data in the same sandbox account. Deletion only affects test_ prefixed records.

Why Use a Sample Workspace

Use caseWithout sample workspaceWith sample workspace
Test analytics dashboardsManually create 100+ paymentsInstant — 6 weeks of data
Test webhook handlersWrite scripts to generate eventsTrickle generates real webhook events
Demo the platformSet up test accounts manuallyOne API call
Test routing configurationsConfigure connectors first5 connectors pre-wired
Build against realistic dataFlat test dataMulti-currency, multi-rail, 50 customers

Legacy Sample Data Endpoint

A simpler endpoint is also available for generating basic payment records:

POST /sample_data

GET //sandbox.perfectpay.ai/sample_data
curl https://sandbox.perfectpay.ai/sample_data \
  -X POST \
  -H "api-key: YOUR_SECRET_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "record": 50,
    "currency": ["USD", "EUR"],
    "min_amount": 10,
    "max_amount": 500
  }'

Options:

FieldTypeDefaultDescription
recordinteger10Number of records (10–100)
connectorstring[]allFilter to specific connectors
start_timestring30 days agoStart of date range
end_timestringnowEnd of date range
min_amountnumber1Minimum amount in dollars
max_amountnumber1000Maximum amount in dollars
currencystring[]["USD"]Currencies to use
auth_typestring[]mixedAuthentication types

Delete legacy sample data with:

DELETE /sample_data

GET //sandbox.perfectpay.ai/sample_data
curl https://sandbox.perfectpay.ai/sample_data \
  -X DELETE \
  -H "api-key: YOUR_SECRET_API_KEY"