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

# Get the record count

> Returns the total no of records based on query



## OpenAPI

````yaml post /v1/hosts/count
openapi: 3.0.1
info:
  title: Odin
  description: >-
    ODIN APIs to search across IP Services, CVEs, Exposed Files/Buckets, Domains
    and more
  contact: {}
  license:
    name: Apache 2.0
    url: http://www.apache.org/licenses/LICENSE-2.0.html
  version: '1.0'
servers:
  - url: https://api.odin.io/
security: []
paths:
  /v1/hosts/count:
    post:
      tags:
        - Hosts
      summary: Get the record count
      description: Returns the total no of records based on query
      requestBody:
        description: Count Query
        content:
          '*/*':
            schema:
              $ref: '#/components/schemas/CountRequest'
        required: true
      responses:
        '200':
          description: OK
          content:
            application/json:
              schema:
                allOf:
                  - $ref: '#/components/schemas/APIResponse'
                  - type: object
                    properties:
                      ' meta':
                        $ref: '#/components/schemas/PaginationStruct'
                      data:
                        $ref: '#/components/schemas/CertCount'
        '400':
          description: Bad Request
          content:
            application/json:
              schema:
                allOf:
                  - $ref: '#/components/schemas/ErrorResponse'
                  - type: object
                    properties:
                      ' error':
                        type: string
                      success:
                        type: boolean
        '402':
          description: Payment Required
          content:
            application/json:
              schema:
                allOf:
                  - $ref: '#/components/schemas/ErrorResponse'
                  - type: object
                    properties:
                      ' error':
                        type: string
                      success:
                        type: boolean
        '408':
          description: Request Timeout
          content:
            application/json:
              schema:
                allOf:
                  - $ref: '#/components/schemas/ErrorResponse'
                  - type: object
                    properties:
                      ' error':
                        type: string
                      success:
                        type: boolean
        '500':
          description: Internal Server Error
          content:
            application/json:
              schema:
                allOf:
                  - $ref: '#/components/schemas/ErrorResponse'
                  - type: object
                    properties:
                      ' error':
                        type: string
                      success:
                        type: boolean
      security:
        - ApiKeyAuth: []
components:
  schemas:
    CountRequest:
      type: object
      properties:
        query:
          type: string
    APIResponse:
      type: object
      properties:
        data:
          type: object
        message:
          type: string
        pagination:
          type: object
        success:
          type: boolean
    PaginationStruct:
      type: object
      properties:
        current:
          type: string
        total:
          type: integer
    CertCount:
      type: object
      properties:
        count:
          type: integer
    ErrorResponse:
      type: object
      properties:
        message:
          type: string
        success:
          type: boolean
  securitySchemes:
    ApiKeyAuth:
      type: apiKey
      name: X-API-Key
      in: header

````