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

# API Setup

> Set up API authentication and configuration for POS integration

## Environment Setup

### Base URL

All API requests use the same base URL for both Test and Live environments:

```
https://api.gameball.co/api/v4.0
```

<Info>
  Switch between Test and Live environments by using your Test or Live API Keys. The base URL remains the same for both environments.
</Info>

### API Credentials

Retrieve your API Key and Secret Key from the Gameball Dashboard:

**Dashboard Path**: Settings → Account Integration → API Keys

You'll need:

* **API Key**: Your Gameball API key
* **Secret Key**: Your Gameball API secret

### Authentication Method

All API requests must include authentication headers:

<RequestExample>
  ```bash cURL theme={null}
  curl -X GET 'https://api.gameball.co/api/v4.0/integrations/customers/{customerId}/balance' \
    -H 'APIKey: YOUR_API_KEY' \
    -H 'SecretKey: YOUR_SECRET_KEY'
  ```
</RequestExample>

## Security Best Practices

<Warning>
  Always use HTTPS for all API calls. Never send API credentials over unencrypted connections.
</Warning>

* Store API credentials securely in your POS system configuration
* Never expose API keys in client-side code or logs
* Rotate API keys periodically for enhanced security
* Use hash validation for QR code-based redemptions

## Next Steps

Once you have your API credentials configured, proceed to:

1. [Customer Management](/installation-guides/v3/pos/customer-management) - Learn how to register customers at checkout
2. [Customer Balance](/installation-guides/v3/pos/customer-balance) - Retrieve customer loyalty information
