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

# List domains with pagination

> Retrieve paginated domains ordered by creation date. Filter by search. Set withQrCodeTemplate=true to include QR template options.



## OpenAPI

````yaml https://api.h0p.co/doc get /domain/list
openapi: 3.0.0
info:
  version: 0.0.3
  title: h0p API
  description: >-
    # h0p URL Shortener API


    A modern, feature-rich URL shortener API with advanced analytics, custom
    domains, QR codes, and comprehensive link management capabilities.


    ## Features


    - 🔗 **Short Link Management**: Create, update, and delete short links with
    custom slugs

    - 🌐 **Custom Domains**: Use your own domains with DNS verification and deep
    linking support

    - 📊 **Analytics**: Detailed click tracking with geolocation, device, and
    referrer data

    - 🎨 **QR Codes**: Generate customizable QR codes with branding options

    - 🏷️ **Organization**: Folders and tags for better link organization

    - 🔐 **Security**: Password protection, expiration dates, and click limits

    - 🎯 **Smart Rules**: Geographic, language, and device-based routing

    - 🪝 **Webhooks**: Real-time notifications for link events

    - 🔑 **API Keys**: Programmatic access with granular permissions

    - ⚡ **Rate Limiting**: Built-in protection against abuse


    ## Authentication


    This API supports two authentication methods:


    1. **Session Authentication**: Cookie-based authentication for web
    applications

    2. **API Key Authentication**: Header-based authentication for programmatic
    access


    See the security schemes section below for implementation details.


    ## Rate Limits


    - Free plan: 10 short links, 1 custom domain, 3 tags

    - Premium plan: unlimited short links, 100 custom domains, 100 tags, 100
    folders, advanced features


    ## Support


    For questions, feature requests, or bug reports, please contact
    support@h0p.co
  termsOfService: https://h0p.co/terms
  contact:
    name: h0p Support
    email: contact@h0p.co
servers:
  - url: https://api.h0p.co
    description: Production API server
security: []
tags:
  - name: Domain
    description: >-
      Custom domain management with DNS verification, QR templates, and deep
      linking support
  - name: Short Link
    description: >-
      Create and manage short links with advanced features like smart routing,
      password protection, and custom QR codes
  - name: Folder
    description: >-
      Organize short links into folders for better management and statistics
      tracking
  - name: Tag
    description: Categorize and filter short links using customizable tags
  - name: Files
    description: Upload images for QR codes, meta tags, and organization branding
  - name: Statistics
    description: >-
      Access detailed analytics grouped by geographic, device, and traffic
      dimensions
paths:
  /domain/list:
    get:
      tags:
        - Domain
      summary: List domains with pagination
      description: >-
        Retrieve paginated domains ordered by creation date. Filter by search.
        Set withQrCodeTemplate=true to include QR template options.
      parameters:
        - schema:
            type: boolean
            nullable: true
            default: false
            example: false
            description: Include QR code template data in response
          required: false
          description: Include QR code template data in response
          name: withQrCodeTemplate
          in: query
        - schema:
            type: number
            nullable: true
            minimum: 0
            maximum: 50
            default: 25
            example: 25
            description: Maximum number of items to return per page
          required: false
          description: Maximum number of items to return per page
          name: limit
          in: query
        - schema:
            type: number
            nullable: true
            minimum: 0
            default: 0
            example: 0
            description: Page number for pagination (zero-indexed)
          required: false
          description: Page number for pagination (zero-indexed)
          name: page
          in: query
        - schema:
            type: string
            example: example
            description: Search query string to filter results
          required: false
          description: Search query string to filter results
          name: search
          in: query
      responses:
        '200':
          description: Paginated list of domains retrieved successfully
          content:
            application/json:
              schema:
                type: object
                properties:
                  count:
                    type: number
                    minimum: 0
                    example: 42
                    description: Total number of items matching the query
                  data:
                    type: array
                    items:
                      type: object
                      properties:
                        qrCode:
                          type: object
                          nullable: true
                          properties:
                            options:
                              type: object
                              properties:
                                type:
                                  type: string
                                  enum:
                                    - svg
                                    - canvas
                                  example: svg
                                  description: Output format for QR code generation
                                width:
                                  type: number
                                  minimum: 100
                                  exclusiveMinimum: true
                                  example: 300
                                  description: QR code width in pixels
                                  maximum: 2000
                                height:
                                  type: number
                                  minimum: 100
                                  exclusiveMinimum: true
                                  example: 300
                                  description: QR code height in pixels
                                  maximum: 2000
                                margin:
                                  type: number
                                  minimum: 0
                                  example: 4
                                  description: >-
                                    Quiet zone margin around QR code (in
                                    modules)
                                data:
                                  type: string
                                  example: https://example.com/abc123
                                  description: Data to encode in QR code
                                image:
                                  type: string
                                  format: uri
                                  example: https://example.com/logo.png
                                  description: Logo/image URL to embed in QR code center
                                imageOptions:
                                  type: object
                                  properties:
                                    hideBackgroundDots:
                                      type: boolean
                                      example: true
                                      description: Hide QR dots behind the logo image
                                    imageSize:
                                      type: number
                                      minimum: 0
                                      maximum: 1
                                      example: 0.4
                                      description: Logo size relative to QR code (0-1)
                                    crossOrigin:
                                      type: string
                                      example: anonymous
                                      description: CORS setting for loading external images
                                    margin:
                                      type: number
                                      minimum: 0
                                      example: 10
                                      description: Padding around logo in pixels
                                  description: Logo image customization options
                                dotsOptions:
                                  type: object
                                  properties:
                                    type:
                                      type: string
                                      enum:
                                        - dots
                                        - rounded
                                        - classy
                                        - classy-rounded
                                        - square
                                        - extra-rounded
                                      description: Visual style for QR code data dots
                                      example: rounded
                                    color:
                                      type: string
                                      pattern: ^#[0-9A-Fa-f]{6}$
                                      example: '#000000'
                                      description: Hex color for QR code dots
                                    gradient:
                                      type: object
                                      properties:
                                        type:
                                          type: string
                                          enum:
                                            - radial
                                            - linear
                                          description: Gradient type
                                          example: linear
                                        rotation:
                                          type: number
                                          example: 45
                                          description: Gradient rotation angle in degrees
                                          minimum: 0
                                          maximum: 360
                                        colorStops:
                                          type: array
                                          items:
                                            type: object
                                            properties:
                                              offset:
                                                type: number
                                                minimum: 0
                                                maximum: 1
                                                example: 0.5
                                                description: Position of color stop (0-1)
                                              color:
                                                type: string
                                                pattern: ^#[0-9A-Fa-f]{6}$
                                                example: '#3B82F6'
                                                description: Hex color code for this stop
                                            required:
                                              - offset
                                              - color
                                            description: Color stop definition for gradient
                                          minItems: 2
                                          description: >-
                                            Array of color stops defining the
                                            gradient
                                          example:
                                            - offset: 0
                                              color: '#3B82F6'
                                            - offset: 1
                                              color: '#8B5CF6'
                                      required:
                                        - type
                                        - colorStops
                                      description: Gradient configuration for dots
                                    roundSize:
                                      type: boolean
                                      example: true
                                      description: Apply rounding size algorithm
                                  description: Customization options for QR code data dots
                                cornersSquareOptions:
                                  type: object
                                  properties:
                                    type:
                                      type: string
                                      enum:
                                        - dot
                                        - square
                                        - extra-rounded
                                        - dots
                                        - rounded
                                        - classy
                                        - classy-rounded
                                      description: >-
                                        Visual style for corner squares (outer
                                        ring)
                                      example: square
                                    color:
                                      type: string
                                      pattern: ^#[0-9A-Fa-f]{6}$
                                      example: '#3B82F6'
                                      description: Hex color for corner squares
                                    gradient:
                                      type: object
                                      properties:
                                        type:
                                          type: string
                                          enum:
                                            - radial
                                            - linear
                                          description: Gradient type
                                          example: linear
                                        rotation:
                                          type: number
                                          example: 45
                                          description: Gradient rotation angle in degrees
                                          minimum: 0
                                          maximum: 360
                                        colorStops:
                                          type: array
                                          items:
                                            type: object
                                            properties:
                                              offset:
                                                type: number
                                                minimum: 0
                                                maximum: 1
                                                example: 0.5
                                                description: Position of color stop (0-1)
                                              color:
                                                type: string
                                                pattern: ^#[0-9A-Fa-f]{6}$
                                                example: '#3B82F6'
                                                description: Hex color code for this stop
                                            required:
                                              - offset
                                              - color
                                            description: Color stop definition for gradient
                                          minItems: 2
                                          description: >-
                                            Array of color stops defining the
                                            gradient
                                          example:
                                            - offset: 0
                                              color: '#3B82F6'
                                            - offset: 1
                                              color: '#8B5CF6'
                                      required:
                                        - type
                                        - colorStops
                                      description: Gradient for corner squares
                                  description: >-
                                    Customization for corner position detection
                                    squares
                                cornersDotOptions:
                                  type: object
                                  properties:
                                    type:
                                      type: string
                                      enum:
                                        - dot
                                        - square
                                        - dots
                                        - rounded
                                        - classy
                                        - classy-rounded
                                        - extra-rounded
                                      description: Visual style for corner dots (inner dot)
                                      example: dot
                                    color:
                                      type: string
                                      pattern: ^#[0-9A-Fa-f]{6}$
                                      example: '#8B5CF6'
                                      description: Hex color for corner dots
                                    gradient:
                                      type: object
                                      properties:
                                        type:
                                          type: string
                                          enum:
                                            - radial
                                            - linear
                                          description: Gradient type
                                          example: linear
                                        rotation:
                                          type: number
                                          example: 45
                                          description: Gradient rotation angle in degrees
                                          minimum: 0
                                          maximum: 360
                                        colorStops:
                                          type: array
                                          items:
                                            type: object
                                            properties:
                                              offset:
                                                type: number
                                                minimum: 0
                                                maximum: 1
                                                example: 0.5
                                                description: Position of color stop (0-1)
                                              color:
                                                type: string
                                                pattern: ^#[0-9A-Fa-f]{6}$
                                                example: '#3B82F6'
                                                description: Hex color code for this stop
                                            required:
                                              - offset
                                              - color
                                            description: Color stop definition for gradient
                                          minItems: 2
                                          description: >-
                                            Array of color stops defining the
                                            gradient
                                          example:
                                            - offset: 0
                                              color: '#3B82F6'
                                            - offset: 1
                                              color: '#8B5CF6'
                                      required:
                                        - type
                                        - colorStops
                                      description: Gradient for corner dots
                                  description: >-
                                    Customization for corner position detection
                                    dots
                                backgroundOptions:
                                  type: object
                                  properties:
                                    round:
                                      type: number
                                      minimum: 0
                                      maximum: 1
                                      example: 0.1
                                      description: Background corner rounding (0-1)
                                    color:
                                      type: string
                                      pattern: ^#[0-9A-Fa-f]{6}$
                                      example: '#FFFFFF'
                                      description: Hex color for QR code background
                                  description: Background customization options
                              required:
                                - data
                              description: QR code generation and styling options
                            imageId:
                              type: string
                              nullable: true
                              format: uuid
                              example: 01933eb8-541f-7000-a9f4-e4eee80ff04e
                              description: UUID of uploaded logo image file
                          required:
                            - options
                          description: Default QR code template for this domain
                        id:
                          type: string
                          format: uuid
                          example: 01933eb8-541f-7000-a9f4-e4eee80ff04e
                          description: Domain UUID
                        domain:
                          type: string
                          example: links.example.com
                          description: Domain name
                        isPrimary:
                          type: boolean
                          example: true
                          description: >-
                            Whether this is the primary domain for the
                            organization
                        isVerified:
                          type: boolean
                          example: true
                          description: Whether domain DNS is fully verified and active
                        createdAt:
                          type: string
                          nullable: true
                          format: date-time
                          example: '2024-01-15T10:30:00Z'
                          description: Domain creation timestamp
                      required:
                        - qrCode
                        - id
                        - domain
                        - isPrimary
                        - isVerified
                        - createdAt
                      description: Domain object with QR code template
                required:
                  - count
                  - data
        '403':
          description: >-
            Forbidden - Missing required permission. Check your API key
            permissions or organization role.
          content:
            application/json:
              schema:
                type: object
                properties:
                  code:
                    type: string
                    enum:
                      - ACTION_NOT_ALLOWED
                    description: Error code for permission denied
                  message:
                    type: string
                    example: You do not have permission to delete domains
                    description: Detailed explanation of the permission issue
                  resource:
                    type: string
                    example: domains
                    description: The resource type that was accessed
                  action:
                    type: string
                    example: delete
                    description: The action that was attempted
                required:
                  - code
                  - message
              example:
                code: ACTION_NOT_ALLOWED
                message: You do not have permission to delete domains
                resource: domains
                action: delete
      security:
        - ApiKey: []
components:
  securitySchemes:
    ApiKey:
      type: apiKey
      in: header
      name: x-api-key
      description: >-
        API Key authentication for programmatic access.


        **How to use:**

        1. Create an API key from your dashboard settings

        2. Include the key in the `x-api-key` header with each request

        3. API keys have granular permissions (domains, shortLinks, files,
        stats, apiKeys)


        **Example:**

        ```

        curl -H "x-api-key: your-api-key-here"
        https://api.h0p.co/short-link/list

        ```


        **Types of API keys:**

        - **User keys**: Linked to your user account (one per organization)

        - **Bot keys**: Autonomous machine users (one per organization)


        **Security notes:**

        - Keep your API keys secure and never commit them to version control

        - API keys cannot access authentication endpoints (/auth/*)

        - Keys can be revoked at any time from the dashboard

````