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

# MinIO bucket notification webhook (internal)

> Internal callback, not a client API. MinIO's `notify_webhook` target posts an S3-style bucket event here when an object lands; Datris enqueues the event for the file notifier, which starts ingestion, and writes one collapsed `ingest-trigger` audit record per bucket per minute. The path is outside `/api/**`, so the API-key, capability and session interceptors do not apply; instead the request must carry `Authorization: Bearer <MINIO_WEBHOOK_TOKEN>` (compared in constant time). When `MINIO_WEBHOOK_TOKEN` is unset the endpoint still accepts events but logs a warning on every call — set the token (and MinIO's matching `auth_token`) in any reachable deployment. Under `AUDIT_LOG_STRICT`, while the audit log is not accepting entries the event is refused with 503 + `Retry-After: 5` so MinIO redelivers it.



## OpenAPI

````yaml /openapi.yaml post /minio-events
openapi: 3.0.3
info:
  title: Datris API
  description: >
    REST API for the Datris AI Data Platform. Ingest, validate, transform,
    store, and retrieve data.


    For AI agent integration, use the [MCP
    Server](https://docs.datris.ai/mcp-server) instead.
  version: 1.57.1
  contact:
    name: Datris
    url: https://datris.ai
  license:
    name: Apache 2.0
servers:
  - url: http://localhost:8080
    description: Local development
security:
  - ApiKeyAuth: []
paths:
  /minio-events:
    post:
      tags:
        - Internal callbacks
      summary: MinIO bucket notification webhook (internal)
      description: >-
        Internal callback, not a client API. MinIO's `notify_webhook` target
        posts an S3-style bucket event here when an object lands; Datris
        enqueues the event for the file notifier, which starts ingestion, and
        writes one collapsed `ingest-trigger` audit record per bucket per
        minute. The path is outside `/api/**`, so the API-key, capability and
        session interceptors do not apply; instead the request must carry
        `Authorization: Bearer <MINIO_WEBHOOK_TOKEN>` (compared in constant
        time). When `MINIO_WEBHOOK_TOKEN` is unset the endpoint still accepts
        events but logs a warning on every call — set the token (and MinIO's
        matching `auth_token`) in any reachable deployment. Under
        `AUDIT_LOG_STRICT`, while the audit log is not accepting entries the
        event is refused with 503 + `Retry-After: 5` so MinIO redelivers it.
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              description: >-
                S3 bucket notification event as MinIO emits it; only
                `Records[0].s3.bucket.name` is read for the audit record, the
                whole payload is passed to the file notifier
              properties:
                EventName:
                  type: string
                  example: s3:ObjectCreated:Put
                Key:
                  type: string
                  example: datris/incoming/stock-prices.csv
                Records:
                  type: array
                  items:
                    type: object
                    properties:
                      eventName:
                        type: string
                      s3:
                        type: object
                        properties:
                          bucket:
                            type: object
                            properties:
                              name:
                                type: string
                          object:
                            type: object
                            properties:
                              key:
                                type: string
                              size:
                                type: integer
      responses:
        '200':
          description: Event queued (`OK`, text/plain)
          content:
            text/plain:
              schema:
                type: string
                example: OK
        '401':
          description: >-
            `MINIO_WEBHOOK_TOKEN` is set and the bearer token is missing or
            wrong (`Unauthorized`, text/plain)
        '503':
          description: >-
            Audit log not accepting entries under `AUDIT_LOG_STRICT`;
            `Retry-After: 5` is set and MinIO retries the delivery
      security:
        - MinioWebhookToken: []
components:
  securitySchemes:
    ApiKeyAuth:
      type: apiKey
      in: header
      name: x-api-key
      description: Optional API key for authentication (enabled via application.yaml)
    MinioWebhookToken:
      type: http
      scheme: bearer
      description: >-
        Shared secret for the `POST /minio-events` callback only — the value of
        `MINIO_WEBHOOK_TOKEN`, which MinIO sends as its notify_webhook
        `auth_token`. Not an API key.

````

This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.