---
title: "500 Internal error"
description: "The import broke partway through. QuotaStack rolled the whole thing back."
---

# 500 Internal error

`https://api.quotastack.io/errors/internal-error`

The import broke partway through. QuotaStack rolled the whole thing back.

## Why it happened

- The import hit an error, and the reply carries the raw text.
- This slug comes only from the import call. The rest of QuotaStack sends `internal` instead.

## How to fix it

1. Read `detail`. The text is the real error, and it usually names the record at fault.
2. Run it again with `options.dry_run: true`, to see how far it gets.
3. Send the import again with the same `Idempotency-Key` once the cause is fixed.

### Example response 500

```json
{
  "type": "https://api.quotastack.io/errors/internal-error",
  "title": "Internal Server Error",
  "status": 500,
  "detail": "create purchase: context deadline exceeded"
}
```

## Which calls return this

- [`GET /v1/customers`](/docs/api/customers#listCustomers)
- [`POST /v1/customers`](/docs/api/customers#createCustomer)
- [`GET /v1/customers/{id}`](/docs/api/customers#getCustomer)
- [`PATCH /v1/customers/{id}`](/docs/api/customers#updateCustomer)
- [`DELETE /v1/customers/{id}`](/docs/api/customers#deleteCustomer)
- [`GET /v1/customer-by-external-id/{external_id}`](/docs/api/customers#getCustomerByExternalId)
- [`PATCH /v1/customer-by-external-id/{external_id}`](/docs/api/customers#updateCustomerByExternalId)
- [`DELETE /v1/customer-by-external-id/{external_id}`](/docs/api/customers#deleteCustomerByExternalId)
- [`GET /v1/customers/{customer_id}/credits`](/docs/api/credits#getCustomerCredits)
- [`POST /v1/customers/{customer_id}/credits/grant`](/docs/api/credits#grantCustomerCredits)
- [`POST /v1/customers/{customer_id}/credits/adjust`](/docs/api/credits#adjustCustomerCredits)
- [`GET /v1/customers/{customer_id}/credits/history`](/docs/api/credits#listCustomerCreditsHistory)
- [`GET /v1/customers/{customer_id}/overage`](/docs/api/credits#getCustomerOverage)
- [`GET /v1/customer-by-external-id/{external_id}/credits`](/docs/api/credits#getCustomerCreditsByExternalId)
- [`POST /v1/customer-by-external-id/{external_id}/credits/grant`](/docs/api/credits#grantCustomerCreditsByExternalId)
- [`POST /v1/customer-by-external-id/{external_id}/credits/adjust`](/docs/api/credits#adjustCustomerCreditsByExternalId)
- [`GET /v1/customer-by-external-id/{external_id}/credits/history`](/docs/api/credits#listCustomerCreditsHistoryByExternalId)
- [`GET /v1/customer-by-external-id/{external_id}/overage`](/docs/api/credits#getCustomerOverageByExternalId)
- [`GET /v1/entitlements/check`](/docs/api/entitlements#checkEntitlement)
- [`POST /v1/usage`](/docs/api/usage#recordUsage)
- [`POST /v1/usage/batch`](/docs/api/usage#recordUsageBatch)
- [`POST /v1/imports/customers`](/docs/api/imports#importCustomer)
- [`POST /v1/subscriptions`](/docs/api/subscriptions#createSubscription)
- [`GET /v1/audit-log`](/docs/api/audit-log#listAuditLog)

## See also

- [Imports](/docs/api/imports)
- [Internal server error](/docs/api/errors/internal)
