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

# Get dataset statistics

> Count rows and optionally profile one column.



## OpenAPI

````yaml https://api.soriaanalytics.com/v1/openapi.json GET /datasets/{dataset}/stats
openapi: 3.1.0
info:
  title: Soria Data API
  description: >-
    Governed data query API. `GET /catalog` is the canonical dataset
    documentation: its schemas, grain, methodology, refresh cadence, and source
    provenance are generated from dbt on every relevant change. `POST
    /search/documents` searches the public source-document corpus behind those
    datasets. For larger result sets, create a private CSV (default) or Parquet
    export, poll its status URL, and use the short-lived download URL once it is
    ready.
  version: 1.0.0
servers:
  - url: /v1
security: []
paths:
  /datasets/{dataset}/stats:
    get:
      tags:
        - data
      summary: Dataset Stats
      description: >-
        Return row count and optional min/max/null/distinct statistics for one
        column.
      operationId: dataset_stats_datasets__dataset__stats_get
      parameters:
        - name: dataset
          in: path
          required: true
          schema:
            type: string
            title: Dataset
        - name: column
          in: query
          required: false
          schema:
            anyOf:
              - type: string
              - type: 'null'
            title: Column
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/DatasetStats'
        '422':
          description: Validation Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HTTPValidationError'
      security:
        - HTTPBearer: []
components:
  schemas:
    DatasetStats:
      properties:
        dataset:
          type: string
          title: Dataset
          description: Dataset identifier.
        row_count:
          type: integer
          title: Row Count
          description: Total rows in the dataset.
        column:
          anyOf:
            - type: string
            - type: 'null'
          title: Column
          description: Profiled column, when requested.
        null_count:
          anyOf:
            - type: integer
            - type: 'null'
          title: Null Count
          description: Null values in the profiled column.
        distinct_count:
          anyOf:
            - type: integer
            - type: 'null'
          title: Distinct Count
          description: Distinct non-null values in the profiled column.
        min:
          anyOf:
            - {}
            - type: 'null'
          title: Min
          description: Minimum value, when supported by the column type.
        max:
          anyOf:
            - {}
            - type: 'null'
          title: Max
          description: Maximum value, when supported by the column type.
      type: object
      required:
        - dataset
        - row_count
      title: DatasetStats
    HTTPValidationError:
      properties:
        detail:
          items:
            $ref: '#/components/schemas/ValidationError'
          type: array
          title: Detail
      type: object
      title: HTTPValidationError
    ValidationError:
      properties:
        loc:
          items:
            anyOf:
              - type: string
              - type: integer
          type: array
          title: Location
        msg:
          type: string
          title: Message
        type:
          type: string
          title: Error Type
      type: object
      required:
        - loc
        - msg
        - type
      title: ValidationError
  securitySchemes:
    HTTPBearer:
      type: http
      scheme: bearer

````