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

# Overview

> Technical overview of the Get Proxy endpoint

# GET /api/domain/get-proxy/{org_id}

Returns CloudFront proxy information for an organization, including distribution details and SSL validation records needed for DNS configuration via Entri.

## Purpose

This endpoint retrieves the current proxy configuration for an organization's AI site, providing all the information needed to:

* Display proxy status in the dashboard
* Configure DNS records via Entri
* Show SSL validation requirements

## Architecture

```mermaid theme={null}
flowchart TD
    A[Frontend Request] --> B[Get Proxy Endpoint]
    B --> C{Has Entity?}
    C -->|No| D[Return has_proxy: false]
    C -->|Yes| E[Query ai_sites table]
    E --> F{Has CloudFront?}
    F -->|No| D
    F -->|Yes| G[Build Response]
    G --> H[Return ProxyInfoResponse]
```

## Response Fields

| Field                  | Type    | Description                                                                                   |
| ---------------------- | ------- | --------------------------------------------------------------------------------------------- |
| `has_proxy`            | boolean | Whether proxy is configured                                                                   |
| `proxy_status`         | string  | Current status (PENDING\_VALIDATION, SSL\_VALIDATING, SSL\_VALIDATED, DEPLOYED, DISCONNECTED) |
| `cloudfront_domain`    | string  | CloudFront distribution domain                                                                |
| `distribution_id`      | string  | CloudFront distribution ID                                                                    |
| `certificate_arn`      | string  | ACM certificate ARN                                                                           |
| `custom_domain`        | string  | User's custom domain                                                                          |
| `ssl_validation_name`  | string  | CNAME record name for SSL validation                                                          |
| `ssl_validation_value` | string  | CNAME record value for SSL validation                                                         |
| `domain_type`          | string  | "apex" or "subdomain"                                                                         |
| `apex_gateway_ips`     | array   | IP addresses for apex domain A records                                                        |

## Code Location

```
src/app/apis/domain/get_proxy/routes.py
```
