> ## Documentation Index
> Fetch the complete documentation index at: https://docs.neuronsearchlab.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Retrieve event

> Retrieve a single ingested event.

## Request

```http theme={null}
GET /v1/events/12345
```

## Response

```json theme={null}
{
  "id": "12345",
  "object": "event",
  "user_id": "user-abc123",
  "item_id": "7f3a2c9e",
  "type": "click",
  "click": {},
  "session_id": "4a93",
  "request_id": "c7f0d2bb-56b1-4ca7-8f09-84d8e4ed02b4",
  "context_id": "101",
  "placement": "home_feed",
  "metadata": {
    "context_id": "101",
    "click": {}
  },
  "occurred_at": 1777478400,
  "created": 1777478405
}
```

`session_id`, `request_id`, and `placement` are `null` when not provided at ingest time.

## Errors

| Status | Scenario                                          |
| ------ | ------------------------------------------------- |
| `400`  | Malformed event ID                                |
| `404`  | Event does not exist for the authenticated tenant |


## OpenAPI

````yaml GET /v1/events/{event_id}
openapi: 3.0.3
info:
  title: NeuronSearchLab Core API
  version: 1.0.0
  description: >-
    Versioned data-plane API for OAuth token exchange, catalog item ingestion,
    user event ingestion, and recommendation serving.
  license:
    name: Proprietary
    url: https://neuronsearchlab.com
servers:
  - url: https://api.neuronsearchlab.com
    description: Core API Gateway custom domain
security:
  - oauth2: []
tags:
  - name: Authentication
    description: OAuth 2.0 client credentials token exchange.
  - name: Items
    description: Catalog item ingestion, lookup, update, deletion, and pagination.
  - name: Events
    description: User interaction event ingestion, lookup, and pagination.
  - name: Recommendations
    description: >-
      Personalized recommendation serving, request-scoped filtering, and
      auto-section generation.
  - name: Search
    description: Query-driven search serving through the Core API data plane.
  - name: CORS
    description: Browser preflight routes generated by API Gateway.
paths:
  /v1/events/{event_id}:
    get:
      tags:
        - Events
      summary: Retrieve event
      description: Retrieve one ingested event by its event ID.
      operationId: retrieveEvent
      parameters:
        - $ref: '#/components/parameters/EventId'
      responses:
        '200':
          description: Event
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Event'
              examples:
                event:
                  $ref: '#/components/examples/Event'
        '400':
          $ref: '#/components/responses/Error400'
        '401':
          $ref: '#/components/responses/Error401'
        '403':
          $ref: '#/components/responses/Error403'
        '404':
          $ref: '#/components/responses/Error404'
        '500':
          $ref: '#/components/responses/Error500'
      security:
        - oauth2:
            - neuronsearchlab-api/read
components:
  parameters:
    EventId:
      name: event_id
      in: path
      required: true
      description: Public event ID.
      schema:
        type: string
        pattern: ^[1-9][0-9]*$
      example: '12345'
  schemas:
    Event:
      type: object
      required:
        - id
        - object
        - user_id
        - item_id
        - type
        - metadata
        - occurred_at
        - created
      properties:
        id:
          type: string
          pattern: ^[1-9][0-9]*$
          example: '12345'
        object:
          type: string
          enum:
            - event
        user_id:
          type: string
          example: user-abc123
        item_id:
          type: string
          example: 7f3a2c9e
        type:
          type: string
          example: purchase
        session_id:
          type: string
          nullable: true
        request_id:
          type: string
          format: uuid
          nullable: true
        context_id:
          type: string
          nullable: true
          example: '101'
        placement:
          type: string
          nullable: true
          example: home_feed
        metadata:
          $ref: '#/components/schemas/Metadata'
        occurred_at:
          type: integer
          format: int64
          nullable: true
          example: 1777478400
        created:
          type: integer
          format: int64
          nullable: true
          example: 1777478405
      additionalProperties: true
    Metadata:
      type: object
      description: Arbitrary JSON object used for filtering, ranking, and debugging.
      additionalProperties: true
      example:
        category: electronics
        brand: Acme
        price: 10999
        currency: usd
    ErrorResponse:
      type: object
      required:
        - error
      properties:
        error:
          type: object
          required:
            - type
            - code
            - message
          properties:
            type:
              type: string
              enum:
                - invalid_request_error
                - authentication_error
                - permission_error
                - not_found_error
                - conflict_error
                - rate_limit_error
                - api_error
            code:
              type: string
            message:
              type: string
            details: {}
            request_id:
              type: string
              format: uuid
          additionalProperties: true
  examples:
    Event:
      summary: Event
      value:
        id: '12345'
        object: event
        user_id: user-abc123
        item_id: 7f3a2c9e
        type: purchase
        purchase:
          amount: 4999
          currency: usd
        session_id: 4a93
        request_id: c7f0d2bb-56b1-4ca7-8f09-84d8e4ed02b4
        context_id: '101'
        placement: home_feed
        metadata:
          context_id: '101'
          purchase:
            amount: 4999
            currency: usd
        occurred_at: 1777478400
        created: 1777478405
    ErrorValidation:
      summary: Validation error
      value:
        error:
          type: invalid_request_error
          code: validation_error
          message: Validation error
          details:
            fieldErrors:
              name:
                - Required
    ErrorUnauthorized:
      summary: Unauthorized
      value:
        error:
          type: authentication_error
          code: unauthorized_no_client_id_in_jwt
          message: 'Unauthorized: No client ID in JWT'
    ErrorNotFound:
      summary: Not found
      value:
        error:
          type: not_found_error
          code: item_not_found
          message: Item not found
  responses:
    Error400:
      description: Invalid request
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ErrorResponse'
          examples:
            validation:
              $ref: '#/components/examples/ErrorValidation'
    Error401:
      description: Unauthenticated
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ErrorResponse'
          examples:
            unauthorized:
              $ref: '#/components/examples/ErrorUnauthorized'
    Error403:
      description: Forbidden
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ErrorResponse'
    Error404:
      description: Not found
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ErrorResponse'
          examples:
            notFound:
              $ref: '#/components/examples/ErrorNotFound'
    Error500:
      description: Server error
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ErrorResponse'
  securitySchemes:
    oauth2:
      type: oauth2
      flows:
        clientCredentials:
          tokenUrl: https://auth.neuronsearchlab.com/oauth2/token
          scopes:
            neuronsearchlab-api/read: Read recommendations, items, and events.
            neuronsearchlab-api/write: Create, update, and delete items; submit events.

````