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

# Get custom events aggregation binary counts

> Retrieves aggregated counts of boolean event values (true/false) produced by a selected prompt over a specified time window.

Scope & filters:
	•	promptUuid – The prompt to aggregate (required).

Time window & interval:
	•	A time range (startTimeMs → endTimeMs, epoch ms) is required and is used exactly as provided.
	•	If an interval is supplied (e.g., MINUTELY, QUARTERHOURLY, HOURLY), events are bucketed at that granularity.
	•	Aggregation is always performed in the device’s local timezone. Buckets are computed relative to each device’s timezone, then evaluated within the exact provided window.

Response:
	•	Per interval bucket, returns a BinaryAggregationValue with counts for true and false.
	•	Includes minValueTimestampMs and maxValueTimestampMs (if available) and the bucket timestamp from BaseReportValue.

Notes:
	•	Only binary/boolean prompt types are valid for this endpoint.




## OpenAPI

````yaml https://api2.rhombussystems.com/api/openapi/public.json post /api/report/getCustomEventsBinaryCounts
openapi: 3.0.1
info:
  contact:
    email: developer@rhombussystems.com
  description: >-
    This API is for use by Rhombus customers and partners.


    ## Authentication


    All requests require two headers:

    - `x-auth-scheme` — The authentication scheme identifier. Use `api-token`
    for standard API key auth, or `partner-api-token` for partner API auth.

    - `x-auth-apikey` — Your Rhombus API key.


    Example:

    ```

    POST /api/camera/getMinimalCameraStateList

    x-auth-scheme: api-token

    x-auth-apikey: YOUR_API_KEY

    Content-Type: application/json

    ```
  title: Rhombus API
  version: '1.0'
servers:
  - description: Production Server
    url: https://api2.rhombussystems.com
security:
  - ApiKeyAuth: []
paths:
  /api/report/getCustomEventsBinaryCounts:
    post:
      tags:
        - Report Webservice
      summary: Get custom events aggregation binary counts
      description: "Retrieves aggregated counts of boolean event values (true/false) produced by a selected prompt over a specified time window.\n\nScope & filters:\n\t•\tpromptUuid – The prompt to aggregate (required).\n\nTime window & interval:\n\t•\tA time range (startTimeMs → endTimeMs, epoch ms) is required and is used exactly as provided.\n\t•\tIf an interval is supplied (e.g., MINUTELY, QUARTERHOURLY, HOURLY), events are bucketed at that granularity.\n\t•\tAggregation is always performed in the device’s local timezone. Buckets are computed relative to each device’s timezone, then evaluated within the exact provided window.\n\nResponse:\n\t•\tPer interval bucket, returns a BinaryAggregationValue with counts for true and false.\n\t•\tIncludes minValueTimestampMs and maxValueTimestampMs (if available) and the bucket timestamp from BaseReportValue.\n\nNotes:\n\t•\tOnly binary/boolean prompt types are valid for this endpoint.\n"
      operationId: getCustomEventsBinaryCounts
      parameters:
        - description: >-
            Authentication scheme identifier. Use `api-token` for standard API
            key authentication, `partner-api-token` for partner API key
            authentication. Must be paired with the `x-auth-apikey` header
            containing your API key.
          example: api-token
          in: header
          name: x-auth-scheme
          required: true
          schema:
            type: string
            default: api-token
            enum:
              - api-token
              - api
              - partner-api-token
              - partner-api
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/Report_GetCustomLLMWSRequest'
      responses:
        '200':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Report_GetCustomLLMWBinaryWSResponse'
          description: OK
components:
  schemas:
    Report_GetCustomLLMWSRequest:
      type: object
      description: Request object for custom LLM reports.
      properties:
        endTimeMs:
          type: integer
          format: int64
          description: >-
            The end timestamp (in Unix epoch milliseconds) of the selected
            interval
          example: 1640998800000
          nullable: true
        interval:
          $ref: '#/components/schemas/ReportIntervalEnum'
        promptUuid:
          type: string
          format: RUUID
          description: base 64 (url-safe) uuid string
          example: AAAAAAAAAAAAAAAAAAAAAA
          nullable: true
        startTimeMs:
          type: integer
          format: int64
          description: >-
            The start timestamp (in Unix epoch milliseconds) of the selected
            interval
          example: 1640995200000
          nullable: true
    Report_GetCustomLLMWBinaryWSResponse:
      type: object
      description: Response object for custom LLM binary reports.
      properties:
        error:
          type: boolean
          nullable: true
        errorMsg:
          type: string
          nullable: true
        reports:
          type: object
          additionalProperties:
            type: array
            description: Map of binary count reports
            items:
              $ref: '#/components/schemas/BinaryAggregationValue'
            nullable: true
          description: Map of binary count reports
          nullable: true
        warningMsg:
          type: string
          nullable: true
    ReportIntervalEnum:
      type: string
      description: Report interval for filtering face events
      enum:
        - MINUTELY
        - QUARTERHOURLY
        - HOURLY
        - DAILY
        - WEEKLY
        - MONTHLY
    BinaryAggregationValue:
      type: object
      description: Map of binary count reports
      properties:
        eventCount:
          type: integer
          format: int64
          nullable: true
        'false':
          type: integer
          format: int64
          nullable: true
        localDate:
          type: string
          nullable: true
        maxValueTimestampMs:
          type: integer
          format: int64
          nullable: true
        minValueTimestampMs:
          type: integer
          format: int64
          nullable: true
        timestampMs:
          type: integer
          format: int64
          nullable: true
        'true':
          type: integer
          format: int64
          nullable: true
        utcDate:
          type: string
          nullable: true
  securitySchemes:
    ApiKeyAuth:
      description: >-
        Your Rhombus API key. Must be accompanied by the `x-auth-scheme` header
        set to `api-token` (or `partner-api-token` for partner endpoints).
      in: header
      name: x-auth-apikey
      type: apiKey

````