# Flag CDN endpoints (System (public))

> 1 FeatherPanel System (public) endpoint from system/flagcdn.php: methods, paths, auth, permissions, rate limits, parameters and responses.

Source: https://featherpanel.com/docs/api/reference/system/flagcdn/

Defined in [`backend/app/routes/system/flagcdn.php`](https://github.com/MythicalLTD/FeatherPanel/blob/15b94e9fc9df233123706b47c42728b81e48cb3d/backend/app/routes/system/flagcdn.php). Authentication used here: **Public**. Read [Authentication](https://featherpanel.com/docs/api/authentication/) for how to send credentials and [Rate limits and errors](https://featherpanel.com/docs/api/rate-limits-and-errors/) for the response envelope.

Paths, methods, permissions and rate limits come from the route file. Summaries, parameters and response codes come from the OpenAPI annotations on the controllers; endpoints without annotations show only what the route file declares.

## Endpoints

### GET `/api/system/country-codes`

- Auth: Public
- Route name: `flagcdn-country-codes`
- Controller: [`FlagCDNController::getCountryCodes`](https://github.com/MythicalLTD/FeatherPanel/blob/15b94e9fc9df233123706b47c42728b81e48cb3d/backend/app/Controllers/System/FlagCDNController.php)
- [route source](https://github.com/MythicalLTD/FeatherPanel/blob/15b94e9fc9df233123706b47c42728b81e48cb3d/backend/app/routes/system/flagcdn.php#L24)

**Get all country codes** Retrieve all available country codes and names from FlagCDN. This endpoint is cached for 24 hours.

| Response `data` field | Type | Description |
| --- | --- | --- |
| `country_codes` | object | Object mapping country codes to country names |

```bash
curl -X GET "$PANEL_URL/api/system/country-codes" \
  -H "Accept: application/json"
```

Responses: `200` Country codes retrieved successfully · `500` Internal server error - Failed to fetch country codes
