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

# [Cloudflare] List the zones of the connected account

> List the zones the connection can see, read live from Cloudflare, with what this project can do with each (`link_state`) and whether it can be transferred to OnetSolutions (`transfer`). A zone already linked to, or whose name is used by, another project of the organization is `in_another_project`. Zones linked here but no longer visible in the account come last, as `missing`. The account's zone list is reused for 60 seconds, so paging and filtering do not list Cloudflare again; `link_state` is always current.



## OpenAPI

````yaml https://api.onetsolutions.net/schema get /v1/organizations/{organization_id}/projects/{project_id}/integrations/cloudflare/zones
openapi: 3.0.3
info:
  title: OnetSolutions API
  version: v1 (v1)
  description: >

    ## Overview


    The OnetSolutions API provides programmatic access to manage your cloud
    infrastructure, domains, and web hosting services.


    ## Authentication


    All API requests require authentication using one of the following methods:


    - **JWT Token**: Obtain a token via login endpoints and include it in the
    `Authorization: Bearer <token>` header

    - **API Key**: Generate an API key from your account settings and use it as
    `Authorization: Bearer sk-onetsolutions-...`


    ## Rate Limiting


    API requests are rate-limited to ensure fair usage:

    - **Anonymous**: 60 requests per minute, per client IP address

    - **Authenticated**: 5000 requests per hour, per user


    Some endpoints, such as login and sign-up, apply stricter limits of their
    own.

    A request over the limit gets a `429` response whose `Retry-After` header
    gives the wait in seconds.


    ## Pagination


    Most list endpoints return paginated results. Use the `page` and `page_size`
    query parameters

    (at most 100 results per page). The response carries `count`, `next`,
    `previous`, `page`, `page_size`,

    `total_pages` and the `results` themselves.


    ## Error Handling


    The API uses standard HTTP status codes:

    - `200` Success

    - `201` Created

    - `204` No Content

    - `400` Bad Request

    - `401` Unauthorized

    - `403` Forbidden

    - `404` Not Found

    - `409` Conflict

    - `429` Too Many Requests

    - `500` Internal Server Error

    - `503` Service Unavailable


    Error responses carry a JSON body with `detail`, a human-readable message,
    and `code`, a stable

    machine-readable error code. Some errors add `context` with structured
    details, and `error`

    repeats `detail` for older clients. A request whose fields fail validation
    gets a `400` whose body maps each

    invalid field to its list of messages. A few older endpoints still answer
    with `error` alone.
servers:
  - url: https://api.onetsolutions.net
    description: Production
security: []
tags:
  - name: Authentication
    description: >-
      Login, passwordless authentication, MFA, OAuth providers, and token
      management.
  - name: Organizations
    description: >-
      Organization management, members, roles, modules, audit logs, and
      notification settings.
  - name: Projects
    description: Project management, team members, and project-scoped resources.
  - name: Compute
    description: >-
      Cloud instances, volumes, snapshots, backups, VPCs, firewalls, SSH keys,
      uptime monitors, and instance tasks.
  - name: Billing
    description: >-
      Shopping cart, orders, invoices, payments, payment methods, gateways,
      promo codes, and balance management.
  - name: Domains
    description: >-
      Domain availability, registration, transfers, DNS zones, DNS records, and
      TLD information.
  - name: Web Hosting
    description: >-
      cPanel-based web hosting, emails, databases, subdomains, FTP accounts,
      addon domains, and SSL certificates.
paths:
  /v1/organizations/{organization_id}/projects/{project_id}/integrations/cloudflare/zones:
    get:
      tags:
        - Domains
      summary: '[Cloudflare] List the zones of the connected account'
      description: >-
        List the zones the connection can see, read live from Cloudflare, with
        what this project can do with each (`link_state`) and whether it can be
        transferred to OnetSolutions (`transfer`). A zone already linked to, or
        whose name is used by, another project of the organization is
        `in_another_project`. Zones linked here but no longer visible in the
        account come last, as `missing`. The account's zone list is reused for
        60 seconds, so paging and filtering do not list Cloudflare again;
        `link_state` is always current.
      operationId: list_cloudflare_account_zones
      parameters:
        - in: query
          name: link_state
          schema:
            type: string
            enum:
              - importable
              - in_another_project
              - linked
              - linked_elsewhere
              - managed_by_onetsolutions
              - missing
              - owned_elsewhere
          description: Only the zones in this state.
        - in: path
          name: organization_id
          schema:
            type: string
            format: uuid
          required: true
        - in: query
          name: page
          schema:
            type: integer
          description: A page number within the paginated result set.
        - in: query
          name: page_size
          schema:
            type: integer
          description: Number of results to return per page (at most 100).
        - in: path
          name: project_id
          schema:
            type: string
            format: uuid
          required: true
      responses:
        '200':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/PaginatedCloudflareAccountZoneList'
          description: ''
        '401':
          description: Authentication credentials were not provided or are invalid
        '403':
          description: You do not have permission to perform this action
        '404':
          description: >-
            Organization or project not found (code: project_not_found), or no
            Cloudflare account is connected to this project (code:
            cloudflare_not_connected)
        '409':
          description: >-
            The connection must be renewed (code:
            cloudflare_reauthorization_required) or the customer did not grant a
            permission the action needs (code: cloudflare_permission_missing)
        '429':
          description: Too many listings for this project
        '503':
          description: >-
            The Cloudflare integration is not offered (code:
            cloudflare_integration_disabled), or is temporarily unavailable
            (code: cloudflare_integration_unavailable)
      security:
        - BearerAuth: []
components:
  schemas:
    PaginatedCloudflareAccountZoneList:
      type: object
      required:
        - count
        - results
      properties:
        count:
          type: integer
          example: 123
        next:
          type: string
          nullable: true
          format: uri
          example: http://api.example.org/accounts/?page=4
        previous:
          type: string
          nullable: true
          format: uri
          example: http://api.example.org/accounts/?page=2
        page:
          type: integer
          example: 3
        page_size:
          type: integer
          example: 20
        total_pages:
          type: integer
          example: 7
        results:
          type: array
          items:
            $ref: '#/components/schemas/CloudflareAccountZone'
    CloudflareAccountZone:
      type: object
      properties:
        cloudflare_zone_id:
          type: string
        name:
          type: string
        status:
          type: string
          nullable: true
        account:
          allOf:
            - $ref: '#/components/schemas/CloudflareAccount'
          nullable: true
        name_servers:
          type: array
          items:
            type: string
        link_state:
          enum:
            - linked
            - linked_elsewhere
            - owned_elsewhere
            - in_another_project
            - managed_by_onetsolutions
            - importable
            - missing
          type: string
          description: |-
            * `linked` - linked
            * `linked_elsewhere` - linked elsewhere
            * `owned_elsewhere` - owned elsewhere
            * `in_another_project` - in another project
            * `managed_by_onetsolutions` - managed by onetsolutions
            * `importable` - importable
            * `missing` - missing
          x-spec-enum-id: 1b6b9b191deebd20
        dns_zone_id:
          type: string
          format: uuid
          nullable: true
        domain:
          allOf:
            - $ref: '#/components/schemas/CloudflareZoneDomain'
          nullable: true
        transfer:
          allOf:
            - $ref: '#/components/schemas/CloudflareZoneTransfer'
          nullable: true
      required:
        - account
        - cloudflare_zone_id
        - dns_zone_id
        - domain
        - link_state
        - name
        - name_servers
        - status
        - transfer
    CloudflareAccount:
      type: object
      properties:
        id:
          type: string
        name:
          type: string
      required:
        - id
        - name
    CloudflareZoneDomain:
      type: object
      properties:
        id:
          type: string
          format: uuid
        name:
          type: string
      required:
        - id
        - name
    CloudflareZoneTransfer:
      type: object
      properties:
        eligible:
          type: boolean
        reason:
          enum:
            - tld_not_supported
            - transfer_unavailable
            - subdomain_zone
            - already_with_onetsolutions
            - null
          type: string
          description: |-
            * `tld_not_supported` - tld not supported
            * `transfer_unavailable` - transfer unavailable
            * `subdomain_zone` - subdomain zone
            * `already_with_onetsolutions` - already with onetsolutions
          x-spec-enum-id: 98e83abfd28bdab8
          nullable: true
        tld_id:
          type: string
          format: uuid
          nullable: true
        tld:
          type: string
          nullable: true
        price:
          type: string
          pattern: ^-?\d{0,8}(?:\.\d{0,2})?$
          nullable: true
        years:
          type: integer
      required:
        - eligible
        - price
        - reason
        - tld
        - tld_id
        - years
  securitySchemes:
    BearerAuth:
      type: http
      scheme: bearer
      bearerFormat: JWT or API Key
      description: >-
        Use `Authorization: Bearer <token>` header. Token can be a JWT token or
        an API key (format: `sk-onetsolutions-...`).

````

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