# Platform API

> Read your platform’s public configuration and branding.

Source: https://dashboard.adquest.batriders.ir/docs/api/platform · Audience: Developers · Section: API reference

## Get platform config

### `GET /platform/config`

Returns the published branding and configuration for the platform that owns the API key.

**Authentication:** Public API key (X-AdQuest-Platform-Key).

```bash
curl "https://api.adquest.batriders.ir/api/v1/platform/config" \
  -H "X-AdQuest-Platform-Key: YOUR_PUBLIC_API_KEY"
```

**Response 200.** The platform’s name and published theme.

```json
{
  "status": true,
  "code": "OK",
  "message": "Platform config",
  "data": {
    "name": "Subway Sample",
    "theme": {
      "colors": {
        "primary": "#FB6514"
      }
    },
    "public_id": "63e1528f-0214-439e-b233-a9b99c54fb77"
  }
}
```

## Get public config

### `GET /platform/public-config/{publicId}`

Returns the same configuration by the platform’s public ID. The hosted embed uses it to load your branding. No credentials are needed.

**Authentication:** None.

| Parameter | In | Type | Required | Description |
| --- | --- | --- | --- | --- |
| publicId | path | string | yes | The platform’s UUID, from your Embed URL. |

```bash
curl "https://api.adquest.batriders.ir/api/v1/platform/public-config/63e1528f-0214-439e-b233-a9b99c54fb77"
```

**Response 200.** The platform’s name and published theme. The response is never cached.

**Response 404.** The ID is not a UUID, or no accepted and active platform has it.

```json
{
  "status": false,
  "message": "Platform not found",
  "data": null
}
```

## Next steps

- [Keys and environments](https://dashboard.adquest.batriders.ir/docs/environments): Which API URL and keys to use.
- [Rewards API](https://dashboard.adquest.batriders.ir/docs/api/rewards): Balance, lotteries and claims.
- [Server routes](https://dashboard.adquest.batriders.ir/docs/api/server-routes): Winner contact, fulfillments and streak callbacks.
