> For the complete documentation index, see [llms.txt](https://docs.huddlers.dev/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.huddlers.dev/event.md).

# /Event

## Overview

The `/event` endpoint retrieves a single Nostr event by its ID, along with the profiles of relevant authors.

## Endpoint Details

* **URL**: `/event`
* **Method**: GET
* **Auth Required**: No
* **Permissions Required**: None

## Request Parameters

| Parameter | Description                      | Required |
| --------- | -------------------------------- | -------- |
| `id`      | The ID of the event to retrieve. | Yes      |

## Response Schema

The response is a JSON object with the following structure:

```json
{
  "event": {
    "id": "event_id",
    "pubkey": "author_pubkey",
    "created_at": 1234567890,
    "kind": 1,
    "tags": [],
    "content": "Event content",
    "sig": "event_signature"
  },
  "profiles": {
    "author_pubkey": {
      "id": "profile_event_id",
      "pubkey": "author_pubkey",
      "created_at": 1234567890,
      "kind": 0,
      "tags": [],
      "content": "Profile content",
      "sig": "profile_signature"
    }
  }
}
```

* `event`: The requested Nostr event.
* `profiles`: A map of author profiles, keyed by pubkey. This includes the profile of the event author and any other relevant profiles (e.g., mentioned users).

## Example Call

```bash
curl -X GET "https://huddlers-ovduv.ondigitalocean.app/event?id=5c3e529bb75f165d822b468114e3bc928288ae5679e38849452e0389124a333b"
```

## Notes

* The profiles map also includes profiles of other authors mentioned in the event.

## Error Responses

* **400 Bad Request**: If the event ID is missing or invalid.
* **404 Not Found**: If the requested event cannot be found.
* **500 Internal Server Error**: If there's an issue processing the request or retrieving profiles.


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://docs.huddlers.dev/event.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
