---
title: "WebSocket wire protocol proxy"
method: GET
path: "/v2"
tags: ["Gateway"]
---

# WebSocket wire protocol proxy

`GET /v2`

Upgrade to a WebSocket connection that proxies the PostgreSQL wire protocol.
The client sends and receives PostgreSQL protocol messages over binary WebSocket frames.

**Authentication:** the same branch connection string credential as the
HTTP SQL endpoint is used, but it is supplied via the PostgreSQL startup
message inside the wire protocol rather than an HTTP header. The
control-plane API key (Bearer token) is not accepted.

## Other responses

- `101` — Switching Protocols — WebSocket connection established
- `400` — Bad request — unable to upgrade connection

---

[API](https://skmtc.net/xata/apis/xata-api.md) · [All operations](https://skmtc.net/xata/apis/xata-api/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/xata/xata-api/revisions/7fd383f5918c/schema)
