# Common Issues

## Connection issues

<details>

<summary>"Internal error encountered" when running the data flow</summary>

This is usually caused by an invalid API key, incorrect site name, or a permission mismatch. Double-check the following:

* Your API key is copied in full with no extra spaces
* Your Chargebee site name matches the subdomain exactly (e.g., `yoursite` not `yoursite.chargebee.com`)
* The API key has read access to the entities you're trying to export

If everything looks correct, try regenerating a new API key in Chargebee under **Settings > Configure Chargebee > API Keys** and reconnecting.

</details>

<details>

<summary>Authentication fails after previously working</summary>

Chargebee API keys can be manually revoked or rotated. Check your Chargebee dashboard to confirm the key is still active. If it was deleted, generate a new one and update your data flow's source credentials.

</details>

## Missing data

<details>

<summary>No data returned even though records exist in Chargebee</summary>

Check the **start date** you set in the data flow. If the start date is set too recently, records created before that date won't be included. Try setting an earlier start date to pull historical data.

</details>

<details>

<summary>Subscriptions or invoices are missing from the export</summary>

Some entities have dependencies. For example, invoices linked to deleted customers may not export cleanly. Also confirm the entity you selected matches the Chargebee Product Catalog version you're using — if you're on Product Catalog v2, use **Items** and **Item prices** rather than **Plans** and **Addons**.

</details>

## Permission errors

<details>

<summary>"Access denied" or 403 error for specific entities</summary>

Not all API keys have access to all endpoints. In Chargebee, API keys can be scoped to read-only or restricted to specific resources. Go to **Settings > Configure Chargebee > API Keys** and verify the key has full read access, or create a new key with the required permissions.

</details>

## Data discrepancies

<details>

<summary>Monetary values look incorrect (e.g., $4999 instead of $49.99)</summary>

Chargebee stores all monetary amounts in the smallest currency unit (cents for USD). You'll need to divide by 100 in your destination to get standard decimal values. In Google Sheets, you can add a calculated column; in BigQuery, apply the conversion in a view.

</details>

<details>

<summary>Timestamps look like large numbers instead of dates</summary>

Chargebee returns timestamps as Unix epoch integers (seconds since January 1, 1970). Use your destination's date conversion function to transform them — for example, in Google Sheets use `=(A1/86400)+DATE(1970,1,1)`, and in BigQuery use `TIMESTAMP_SECONDS()`.

</details>

## Rate limits

<details>

<summary>Data flow times out or slows down on large exports</summary>

Chargebee enforces API rate limits that vary by plan. If you're exporting high-volume entities like **Events** or **Transactions** without a start date filter, you may hit these limits. Set a specific start date to limit the data volume, especially for the first run.

</details>
