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

# Get graph stats



## OpenAPI

````yaml https://api.crosmos.dev/openapi.json get /api/v1/graph/stats
openapi: 3.1.0
info:
  title: Crosmos API
  version: 0.1.0
servers:
  - url: /
security: []
paths:
  /api/v1/graph/stats:
    get:
      tags:
        - graph
      summary: Get graph stats
      parameters:
        - schema:
            type: string
            format: uuid
          required: false
          name: space_uuid
          in: query
        - schema:
            type: string
            format: uuid
          required: false
          name: space_id
          in: query
      responses:
        '200':
          description: Graph stats
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/GraphStatsResponse'
        '404':
          description: Space not found
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
      security:
        - bearerAuth: []
components:
  schemas:
    GraphStatsResponse:
      type: object
      properties:
        total_entities:
          type: integer
          minimum: 0
        total_edges:
          type: integer
          minimum: 0
        entity_types:
          type: object
          additionalProperties:
            type: integer
        top_relations:
          type: array
          items:
            type: object
            properties:
              relation:
                type: string
              count:
                type: integer
            required:
              - relation
              - count
      required:
        - total_entities
        - total_edges
        - entity_types
        - top_relations
    ErrorResponse:
      type: object
      properties:
        detail:
          type: string
        code:
          type: string
        request_id:
          type: string
        fields:
          nullable: true
      required:
        - detail
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      description: JWT access token or API key (csk_...)

````

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