Proxy

For instructions on how to authenticate to use this endpoint, see API overview.

List all proxy records

Required API key scopes

organization:read

Path parameters

  • organization_id
    string

Query parameters

  • limit
    integer

    Number of results to return per page.

  • offset
    integer

    The initial index from which to return the results.

Response


Request

GET /api/organizations/:organization_id/proxy_records
export POSTHOG_PERSONAL_API_KEY=[your personal api key]
curl \
-H "Authorization: Bearer $POSTHOG_PERSONAL_API_KEY" \
<ph_app_host>/api/organizations/:organization_id/proxy_records/

Response

Status 200
RESPONSE
{
"count": 123,
"next": "http://api.example.org/accounts/?offset=400&limit=100",
"previous": "http://api.example.org/accounts/?offset=200&limit=100",
"results": [
{
"id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
"domain": "string",
"target_cname": "string",
"status": "waiting",
"message": "string",
"created_at": "2019-08-24T14:15:22Z",
"updated_at": "2019-08-24T14:15:22Z",
"created_by": 0
}
]
}

Create proxy records

Required API key scopes

organization:write

Path parameters

  • organization_id
    string

Request parameters

  • domain
    string

Response


Request

POST /api/organizations/:organization_id/proxy_records
export POSTHOG_PERSONAL_API_KEY=[your personal api key]
curl
-H 'Content-Type: application/json'\
-H "Authorization: Bearer $POSTHOG_PERSONAL_API_KEY" \
<ph_app_host>/api/organizations/:organization_id/proxy_records/\
-d domain="string"

Response

Status 201
RESPONSE
{
"id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
"domain": "string",
"target_cname": "string",
"status": "waiting",
"message": "string",
"created_at": "2019-08-24T14:15:22Z",
"updated_at": "2019-08-24T14:15:22Z",
"created_by": 0
}

Retrieve proxy records

Required API key scopes

organization:read

Path parameters

  • id
    string
  • organization_id
    string

Response


Request

GET /api/organizations/:organization_id/proxy_records/:id
export POSTHOG_PERSONAL_API_KEY=[your personal api key]
curl \
-H "Authorization: Bearer $POSTHOG_PERSONAL_API_KEY" \
<ph_app_host>/api/organizations/:organization_id/proxy_records/:id/

Response

Status 200
RESPONSE
{
"id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
"domain": "string",
"target_cname": "string",
"status": "waiting",
"message": "string",
"created_at": "2019-08-24T14:15:22Z",
"updated_at": "2019-08-24T14:15:22Z",
"created_by": 0
}

Update proxy records

Required API key scopes

organization:write

Path parameters

  • id
    string
  • organization_id
    string

Request parameters

  • domain
    string

Response


Request

PATCH /api/organizations/:organization_id/proxy_records/:id
export POSTHOG_PERSONAL_API_KEY=[your personal api key]
curl -X PATCH \
-H "Authorization: Bearer $POSTHOG_PERSONAL_API_KEY" \
<ph_app_host>/api/organizations/:organization_id/proxy_records/:id/\
-d domain="string"

Response

Status 200
RESPONSE
{
"id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
"domain": "string",
"target_cname": "string",
"status": "waiting",
"message": "string",
"created_at": "2019-08-24T14:15:22Z",
"updated_at": "2019-08-24T14:15:22Z",
"created_by": 0
}

Delete proxy records

Required API key scopes

organization:write

Path parameters

  • id
    string
  • organization_id
    string

Request

DELETE /api/organizations/:organization_id/proxy_records/:id
export POSTHOG_PERSONAL_API_KEY=[your personal api key]
curl -X DELETE \
-H "Authorization: Bearer $POSTHOG_PERSONAL_API_KEY" \
<ph_app_host>/api/organizations/:organization_id/proxy_records/:id/

Response

Status 204 No response body

Community questions

Was this page useful?