---
title: "Get app gateway metadata"
method: GET
path: "/api/v1/apps/{app_id}/gateway"
tags: ["Apps", "apps-gateway"]
---

# Get app gateway metadata

`GET /api/v1/apps/{app_id}/gateway`

## Request

- Base URL: `https://cloud-api.phala.com`
- URL: `https://cloud-api.phala.com/api/v1/apps/{app_id}/gateway`
- Auth: none declared
- TypeScript: <https://skmtc.dev/phala/apis/phala-cloud-api/docs/api/v1/apps/:app_id/gateway/get.ts> (a function with typed inputs; its response is checked against the schema)

Returns the gateway DNS suffix, tproxy port, union of public ports, and the CVM instance roster. URL composition happens on the client.

## Path parameters

- `app_id` string, required: Hex app identifier

## Response `200`

Gateway metadata and instance roster

- AppGatewayResponse: Shared gateway metadata plus instance roster for an app. The frontend composes subdomains as ``{id}[-{port}[s|g]].{suffix}`` where ``id`` is either ``app_id`` (load-balanced) or an ``instance_id`` from ``instances[]`` (pinned). When ``tproxy_port != 443`` the port suffix is appended (``:{tproxy_port}``) to the hostname.
  - `gateway_domain_suffix` string, nullable: DNS suffix under which app/instance subdomains resolve.
  - `tproxy_port` integer, nullable: Port the gateway terminates on; omitted from URLs when 443.
  - `public_ports` integer[]: Union of public ports declared across the app's instances.
  - `instances` AppGatewayInstanceResponse[]
    - `cvm_uuid` string, nullable
    - `instance_id` string, nullable
    - `name` string, required
    - `status` string, required

## Other responses

- `401`: Not authenticated
- `403`: No workspace access
- `404`: App not found
- `422`: Validation Error

## Changes

- **2026-11-07** `c71a8dc90391`: 1 info
  - endpoint added

[Operation history](https://skmtc.dev/phala/apis/phala-cloud-api/changes/api/v1/apps/:app_id/gateway/get.md)

---

[API](https://skmtc.dev/phala/apis/phala-cloud-api.md) - [All operations](https://skmtc.dev/phala/apis/phala-cloud-api/llms.txt) - [OpenAPI document](https://skmtc.dev/phala/apis/phala-cloud-api/revisions/c71a8dc90391?raw)
