> ## Documentation Index
> Fetch the complete documentation index at: https://docs.thiqwave.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Environments & Console

> Manage staging and production environments from the Thiqwave Console.

import { CardGroup, Steps, Note, Tip, Warning } from 'mintlify/components';

## Overview

Thiqwave provides separate staging and production environments for development and live operations. The Thiqwave Console at console.thiqwave.com is your control center for managing both environments, handling onboarding, monitoring transactions, and generating API keys.

## Thiqwave Console

Access the Console at **console.thiqwave.com** to:

* **Onboarding** — Complete KYB verification and get approved for live transactions
* **KYB Verification** — Submit and track compliance status for your business
* **API Keys** — Generate and manage API keys for staging and production
* **Webhooks** — Configure webhook endpoints and view delivery logs
* **Transaction Monitoring** — View all transactions, settlements, payouts, and on-chain operations
* **Reports** — Export transaction history and compliance reports
* **Team Management** — Manage team members and permissions

## Staging Environment

Use staging to test integrations without moving real money.

**Base URL:** `https://staging.api.thiqwave.com`

**Characteristics:**

* Test data only — no real funds involved
* Simulated payment rails — instant settlements and refunds
* Full API feature parity with production
* API keys scoped to staging environment only
* Test scenarios for different outcomes (success, failure, pending, compliance holds)

### Test data

The staging environment comes with pre-seeded data to help you get started immediately:

* **Test business profiles** — Pre-created partner accounts with completed KYB verification, so you can skip onboarding and start testing transactions right away
* **Test accounts** — Pre-configured fiat settlement accounts and stablecoin wallets with test balances across supported corridors

<Warning>
  Never use real customer data in the staging environment. All staging data is periodically reset.
</Warning>

### Getting started in staging

1. Sign in to the Console at **console.thiqwave.com**
2. Navigate to **Environments → Staging**
3. Generate a staging API key
4. Use the base URL `https://staging.api.thiqwave.com` in your API calls
5. Test your integration with sample data

## Production Environment

Use production for live transactions with real funds and real customers.

**Base URL:** `https://api.thiqwave.com`

**Characteristics:**

* Real funds and real payment rails
* Real customer data and compliance
* Production-grade reliability and monitoring
* API keys scoped to production environment only
* Rate limits and compliance rules enforced

### Going live

Before moving to production:

1. Complete KYB verification in the Console
2. Wait for approval (typically 1-2 business days)
3. Generate production API keys in the Console
4. Update your application base URL to `https://api.thiqwave.com`
5. Use production credentials and deploy

<Warning>
  Production API keys are sensitive. Never commit them to version control. Use environment variables and secure vaults to manage credentials.
</Warning>

## API Keys

API keys are environment-scoped. Staging keys only work with the staging environment, and production keys only work with production.

### Creating API keys

In the Console:

1. Go to **Settings → API Keys**
2. Select the environment (Staging or Production)
3. Click **Generate New Key**
4. Copy the key immediately (you won't be able to see it again)
5. Store it securely

### Using API keys

Include your API key in the `X-API-Key` header for all requests:

```bash theme={null}
curl -X GET "https://api.thiqwave.com/v1/accounts" \
  -H "X-API-Key: your-api-key"
```

### Key rotation

Rotate API keys periodically for security:

1. Generate a new key in the Console
2. Update your application to use the new key
3. Verify all requests succeed with the new key
4. Delete the old key from the Console

## Test scenarios (Staging only)

In staging, you can simulate different transaction outcomes by passing a `test_scenario` parameter. This allows you to test error handling and edge cases.

### Available test scenarios

| Scenario          | Behavior                                     |
| ----------------- | -------------------------------------------- |
| `completed`       | Transaction completes successfully (default) |
| `failed`          | Transaction fails with a generic error       |
| `pending`         | Transaction stays in pending state           |
| `compliance_hold` | Transaction is held for compliance review    |

### Using test scenarios

Pass `test_scenario` in your request body:

```bash theme={null}
curl -X POST "https://staging.api.thiqwave.com/v1/payouts" \
  -H "X-API-Key: your-staging-key" \
  -H "Content-Type: application/json" \
  -d '{
    "quote_id": "quote_xyz789",
    "recipient": {
      "name": "Test User",
      "account_number": "123456789012",
      "bank_code": "050",
      "country": "AE"
    },
    "test_scenario": "failed"
  }'
```

<Tip>
  Use test scenarios to verify your webhook handling, error UI, and retry logic before going live.
</Tip>

## Switching environments in the Console

In the Console header, you'll see an environment selector:

1. Click the environment dropdown (shows "Staging" or "Production")
2. Select the desired environment
3. The Console switches to show data for that environment
4. Your current API key, transactions, and settings are environment-specific

## Monitoring and debugging

### Viewing transactions

In the Console:

1. Go to **Transactions**
2. Filter by type (payouts, settlements, on-ramps, etc.)
3. Click a transaction to see full details, status, and logs

### Checking webhook delivery

In the Console:

1. Go to **Settings → Webhooks**
2. Click **View Deliveries** for your endpoint
3. See delivery status, timestamps, and response codes
4. Retry failed deliveries manually

### API error logs

Check the Console's **Logs** section to debug API issues:

1. Go to **Logs**
2. Filter by error type, timestamp, or request ID
3. View the full request and response

## Base URLs summary

| Environment    | Base URL                           |
| -------------- | ---------------------------------- |
| **Staging**    | `https://staging.api.thiqwave.com` |
| **Production** | `https://api.thiqwave.com`         |

All endpoints follow the pattern: `{BASE_URL}/v1/{endpoint}`

Example staging request:

```bash theme={null}
https://staging.api.thiqwave.com/v1/quotes
```

Example production request:

```bash theme={null}
https://api.thiqwave.com/v1/quotes
```

## Best practices

* **Keep staging updated** — Test new features in staging before deploying to production
* **Use test scenarios** — Simulate edge cases and errors in staging
* **Rotate keys regularly** — Refresh API keys every 90 days
* **Monitor webhooks** — Check webhook delivery logs for failures
* **Test both environments** — Verify integrations work in both staging and production
* **Use environment variables** — Never hardcode API keys or base URLs
* **Tag transactions** — Use metadata to track test vs. real transactions

## Troubleshooting

| Issue               | Cause                                    | Resolution                                                           |
| ------------------- | ---------------------------------------- | -------------------------------------------------------------------- |
| 401 Unauthorized    | Invalid or expired API key               | Verify API key is correct and for the current environment            |
| 403 Forbidden       | API key belongs to different environment | Use the correct API key for the environment (staging vs. production) |
| API key not working | Key was regenerated or revoked           | Generate a new key in the Console                                    |
| Webhook not firing  | Endpoint unreachable or misconfigured    | Check webhook URL and retry delivery in Console                      |

## Next steps

* [Receiving Payments](/guides/receiving-payments) — Start accepting deposits
* [KYB Verification](/guides/kyb-verification) — Complete compliance for production
* [Webhooks](/guides/webhooks) — Set up event notifications
