---
title: "Get a shared chat"
method: GET
path: "/shared_chats/{shared_chat_id}"
tags: ["Shared Chats"]
---

# Get a shared chat

`GET /shared_chats/{shared_chat_id}`

## Request

- Base URL: `https://h2ogpte.genai.h2o.ai/api/v1`
- URL: `https://h2ogpte.genai.h2o.ai/api/v1/shared_chats/{shared_chat_id}`
- Auth: HTTP bearer
- TypeScript: <https://skmtc.dev/h2o/apis/h2ogpte-rest-api/docs/shared_chats/:shared_chat_id/get.ts> (a function with typed inputs; its response is checked against the schema)

Get a shared chat by its ID. Public shared chats are accessible without authentication. Private shared chats require authentication.

## Path parameters

- `shared_chat_id` string, required

## Response `200`

Successful operation

- SharedChatDetail
  - `name` string: Name of the shared chat.
  - `shared_at` string: When the chat was shared.
  - `shared_by` string: Username of the person who shared the chat.
  - `is_frozen` boolean, required: Whether the shared chat is a frozen snapshot.
  - `is_private` boolean, required: Whether the shared chat requires authentication.
  - `includes_artifacts` boolean, required: Whether file artifacts are included.
  - `messages` object[], required: Chat messages in the shared chat.

## Other responses

- `400`: Bad request
- `401`: Unauthorized - Invalid or missing API key
- `404`: Not found
- `default`: Unexpected error

---

[API](https://skmtc.dev/h2o/apis/h2ogpte-rest-api.md) - [All operations](https://skmtc.dev/h2o/apis/h2ogpte-rest-api/llms.txt) - [OpenAPI document](https://skmtc.dev/h2o/apis/h2ogpte-rest-api/revisions/a82a117320f4?raw)
