---
openapi: "3.0.0"
info:
  title: Connector Appliance API
  description: External APIs exposed by the Connector Appliance
  version: "1.5"
servers:
  - url: https://{connector-appliance-ip}
    description: Provide the IP address of your Connector Appliance
    variables:
      connector-appliance-ip:
        default: 203.0.113.254
        description: The IP address of your Connector Appliance
security:
  - bearerAuth: []
paths:
  /registrationConnectivityCheck:
    x-summary: Registration Connectivity Check
    get:
      tags:
        - connectivity
      operationId: Registration_Connectivity_Check_Search
      description: Registration connectivity check
      summary: Registration Connectivity Check
      security:
        - bearerAuth: []
      parameters:
        - name: deployment
          in: query
          description: Which deployment to attempt to contact if unregistered, when registered this will be ignored
          required: false
          schema:
            type: string
            enum:
              - production
              - staging
              - productionjp
              - stagingjp
          example: staging
        - name: Accept
          in: header
          description: Accepted content types
          required: true
          schema:
            type: string
          example: application/json
        - name: Authorization
          in: header
          description: The access token
          required: true
          schema:
            type: string
          example: Bearer abcde.12345.ABCDE
        - name: Citrix-TransactionId
          in: header
          description: Unique transaction ID of the call
          required: false
          schema:
            $ref: '#/components/schemas/TransactionId'
        - name: Citrix-Locale
          in: header
          description: Requested locale
          required: false
          schema:
            $ref: '#/components/schemas/RequestedLanguage'
        - name: Accept-Language
          in: header
          description: Browser language preferences
          required: false
          schema:
            $ref: '#/components/schemas/RequestedLanguage'
      responses:
        '200':
          description: Registration Connectivity Check Status
          content:
            application/json; charset=utf-8:
              schema:
                $ref: '#/components/schemas/RegistrationConnectivityResponse'
              examples:
                summary:
                  value: {
                    "status": "ok"
                  }
          headers:
            Content-Type:
              schema:
                type: string
            X-Content-Type-Options:
              schema:
                type: string
            Content-Security-Policy:
              schema:
                type: string
            X-Frame-Options:
              schema:
                type: string
            Cache-Control:
              schema:
                type: string
            Citrix-TransactionId:
              schema:
                $ref: '#/components/schemas/TransactionId'
        '400':
          description: Invalid or missing field in request.
          content:
            application/json; charset=utf-8:
              schema:
                $ref: '#/components/schemas/ErrorModel'
          x-error-response-example:
            type: https://errors-api.cloud.com/common/invalidString
            detail: 'Field "deployment" has an invalid value.'
            parameters:
              - name: property
                value: deployment
          headers:
            Content-Type:
              schema:
                type: string
            X-Content-Type-Options:
              schema:
                type: string
            Content-Security-Policy:
              schema:
                type: string
            X-Frame-Options:
              schema:
                type: string
            Cache-Control:
              schema:
                type: string
            Citrix-TransactionId:
              schema:
                $ref: '#/components/schemas/TransactionId'
        '401':
          $ref: '#/components/responses/AccessDenied'
        '406':
          $ref: '#/components/responses/NotAcceptable'
        # Leave '415' (UnsupportedMediaType): There doesn't tend to be request content for GET, HEAD and DELETE.

  /registration:
    x-summary: Registration Management
    get:
      tags:
        - register
      operationId: Registration_Search
      description: Get registration status
      summary: Get Registration Status
      security:
        - bearerAuth: []
      parameters:
        - name: Accept
          in: header
          description: Accepted content types
          required: true
          schema:
            type: string
          example: application/json
        - name: Authorization
          in: header
          description: The access token
          required: true
          schema:
            type: string
          example: Bearer abcde.12345.ABCDE
        - name: Citrix-TransactionId
          in: header
          description: Unique transaction ID of the call
          required: false
          schema:
            $ref: '#/components/schemas/TransactionId'
        - name: Citrix-Locale
          in: header
          description: Requested locale
          required: false
          schema:
            $ref: '#/components/schemas/RequestedLanguage'
        - name: Accept-Language
          in: header
          description: Browser language preferences
          required: false
          schema:
            $ref: '#/components/schemas/RequestedLanguage'
      responses:
        '200':
          description: Are we registered?
          content:
            application/json; charset=utf-8:
              schema:
                $ref: '#/components/schemas/RegistrationStatus'
              example:
                code: ""  # empty if code has expired
                pollingInterval: 30.0
                status: Unregistered
                verificationUrl: https://citrix.cloudburrito.com/
          headers:
            Content-Type:
              schema:
                type: string
            X-Content-Type-Options:
              schema:
                type: string
            Content-Security-Policy:
              schema:
                type: string
            X-Frame-Options:
              schema:
                type: string
            Cache-Control:
              schema:
                type: string
            Citrix-TransactionId:
              schema:
                $ref: '#/components/schemas/TransactionId'
        '401':
          $ref: '#/components/responses/AccessDenied'
        '406':
          $ref: '#/components/responses/NotAcceptable'
        # Leave '415' (UnsupportedMediaType): There doesn't tend to be request content for GET, HEAD and DELETE.
        '500':
          $ref: '#/components/responses/InternalServerError'
    post:
      tags:
        - register
      operationId: Registration_Post
      description: Initiate registration
      summary: Initiate Registration
      security:
        - bearerAuth: []
      parameters:
        - name: Accept
          in: header
          description: Accepted content types
          required: true
          schema:
            type: string
          example: application/json
        - name: Authorization
          in: header
          description: The access token
          required: true
          schema:
            type: string
          example: Bearer abcde.12345.ABCDE
        - name: Citrix-TransactionId
          in: header
          description: Unique transaction ID of the call
          required: false
          schema:
            $ref: '#/components/schemas/TransactionId'
        - name: Citrix-Locale
          in: header
          description: Requested locale
          required: false
          schema:
            $ref: '#/components/schemas/RequestedLanguage'
        - name: Accept-Language
          in: header
          description: Browser language preferences
          required: false
          schema:
            $ref: '#/components/schemas/RequestedLanguage'
      requestBody:
        description: "Registration details"
        content:
          application/json; charset=utf-8:
            schema:
              $ref: '#/components/schemas/KrsRegistrationRequest'
      responses:
        '201':
          description: Registration information
          content:
            application/json; charset=utf-8:
              schema:
                $ref: '#/components/schemas/RegistrationStatus'
              example:
                code: 62JD3AYL
                pollingInterval: 30
                status: Unregistered
                verificationUrl: https://citrix.cloud.com/identity/api-access/product-registrations
                expiryTimestamp: 1668085800
          headers:
            Content-Type:
              schema:
                type: string
            X-Content-Type-Options:
              schema:
                type: string
            Content-Security-Policy:
              schema:
                type: string
            X-Frame-Options:
              schema:
                type: string
            Cache-Control:
              schema:
                type: string
            Citrix-TransactionId:
              schema:
                $ref: '#/components/schemas/TransactionId'
        '400':
          $ref: '#/components/responses/InvalidJson'
        '401':
          $ref: '#/components/responses/AccessDenied'
        '406':
          $ref: '#/components/responses/NotAcceptable'
        '415':
          $ref: '#/components/responses/UnsupportedMediaType'
        '500':
          $ref: '#/components/responses/InternalServerError'

  /unattendedRegistration:
    x-summary: Registration Management
    get:
      tags:
        - register
      operationId: Unattended_Registration_Search
      description: Get registration status
      summary: Get Registration Status
      security:
        - bearerAuth: []
      parameters:
        - name: Accept
          in: header
          description: Accepted content types
          required: true
          schema:
            type: string
          example: application/json
        - name: Authorization
          in: header
          description: The access token
          required: true
          schema:
            type: string
          example: Bearer abcde.12345.ABCDE
        - name: Citrix-TransactionId
          in: header
          description: Unique transaction ID of the call
          required: false
          schema:
            $ref: '#/components/schemas/TransactionId'
        - name: Citrix-Locale
          in: header
          description: Requested locale
          required: false
          schema:
            $ref: '#/components/schemas/RequestedLanguage'
        - name: Accept-Language
          in: header
          description: Browser language preferences
          required: false
          schema:
            $ref: '#/components/schemas/RequestedLanguage'
      responses:
        '200':
          description: Are we registered?
          content:
            application/json; charset=utf-8:
              schema:
                $ref: '#/components/schemas/RegistrationStatus'
              example:
                status: Unregistered
          headers:
            Content-Type:
              schema:
                type: string
            X-Content-Type-Options:
              schema:
                type: string
            Content-Security-Policy:
              schema:
                type: string
            X-Frame-Options:
              schema:
                type: string
            Cache-Control:
              schema:
                type: string
            Citrix-TransactionId:
              schema:
                $ref: '#/components/schemas/TransactionId'
        '401':
          $ref: '#/components/responses/AccessDenied'
        '406':
          $ref: '#/components/responses/NotAcceptable'
        # Leave '415' (UnsupportedMediaType): There doesn't tend to be request content for GET, HEAD and DELETE.
        '500':
          $ref: '#/components/responses/InternalServerError'
    post:
      tags:
        - register
      operationId: Unattended_Registration_Post
      description: Register against given deployment
      summary: Register Against Given Deployment
      security:
        - bearerAuth: []
      parameters:
        - name: Accept
          in: header
          description: Accepted content types
          required: true
          schema:
            type: string
          example: application/json
        - name: Authorization
          in: header
          description: The access token
          required: true
          schema:
            type: string
          example: Bearer abcde.12345.ABCDE
        - name: Citrix-TransactionId
          in: header
          description: Unique transaction ID of the call
          required: false
          schema:
            $ref: '#/components/schemas/TransactionId'
        - name: Citrix-Locale
          in: header
          description: Requested locale
          required: false
          schema:
            $ref: '#/components/schemas/RequestedLanguage'
        - name: Accept-Language
          in: header
          description: Browser language preferences
          required: false
          schema:
            $ref: '#/components/schemas/RequestedLanguage'
      requestBody:
        description: "Registration details"
        content:
          application/json; charset=utf-8:
            schema:
              $ref: '#/components/schemas/UnattendedRegistrationRequest'
      responses:
        '200':
          description: Registration information
          content:
            application/json; charset=utf-8:
              schema:
                $ref: '#/components/schemas/RegistrationStatus'
              example:
                status: Registered
          headers:
            Content-Type:
              schema:
                type: string
            X-Content-Type-Options:
              schema:
                type: string
            Content-Security-Policy:
              schema:
                type: string
            X-Frame-Options:
              schema:
                type: string
            Cache-Control:
              schema:
                type: string
            Citrix-TransactionId:
              schema:
                $ref: '#/components/schemas/TransactionId'
        '400':
          description: Invalid or missing field in request.
          content:
            application/json; charset=utf-8:
              schema:
                $ref: '#/components/schemas/ErrorModel'
          x-error-response-example:
            type: https://errors-api.cloud.com/common/invalidString
            detail: 'Field "serviceAddressFormat" has an invalid value.'
            parameters:
              - name: property
                value: serviceAddressFormat
          headers:
            Content-Type:
              schema:
                type: string
            X-Content-Type-Options:
              schema:
                type: string
            Content-Security-Policy:
              schema:
                type: string
            X-Frame-Options:
              schema:
                type: string
            Cache-Control:
              schema:
                type: string
            Citrix-TransactionId:
              schema:
                $ref: '#/components/schemas/TransactionId'
        '401':
          $ref: '#/components/responses/AccessDenied'
        '406':
          $ref: '#/components/responses/NotAcceptable'
        '415':
          $ref: '#/components/responses/UnsupportedMediaType'
        '500':
          $ref: '#/components/responses/InternalServerError'

  /report:
    x-summary: Download Status Report
    get:
      tags:
        - diagnostic
      operationId: Report_Search
      description: Download status report
      summary: Download Status Report
      security:
        - bearerAuth: []
      parameters:
        - name: Accept
          in: header
          description: Accepted content types
          required: true
          schema:
            type: string
          example: application/zip
        - name: Authorization
          in: header
          description: The access token
          required: true
          schema:
            type: string
          example: Bearer abcde.12345.ABCDE
        - name: Citrix-TransactionId
          in: header
          description: Unique transaction ID of the call
          required: false
          schema:
            $ref: '#/components/schemas/TransactionId'
        - name: Citrix-Locale
          in: header
          description: Requested locale
          required: false
          schema:
            $ref: '#/components/schemas/RequestedLanguage'
        - name: Accept-Language
          in: header
          description: Browser language preferences
          required: false
          schema:
            $ref: '#/components/schemas/RequestedLanguage'
      responses:
        '200':
          description: Binary data containing the report
          headers:
            Content-Disposition:
              example: attachment; filename="status-report-xenrt10715783.xenrtcloud-2021-07-20T1230.zip"
              description: >
                An appropriate filename, see
                https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Content-Disposition
              schema:
                type: string
            Content-Type:
              schema:
                type: string
              examples:
                general:
                  value: application/octet-stream
                specific:
                  value: application/zip
            X-Content-Type-Options:
              schema:
                type: string
            Content-Security-Policy:
              schema:
                type: string
            X-Frame-Options:
              schema:
                type: string
            Cache-Control:
              schema:
                type: string
            Citrix-TransactionId:
              schema:
                $ref: '#/components/schemas/TransactionId'
          content:
            application/zip:
              schema:
                type: string
                format: binary
        '401':
          $ref: '#/components/responses/AccessDenied'
        '406':
          $ref: '#/components/responses/NotAcceptable'
        # Leave '415' (UnsupportedMediaType): There doesn't tend to be request content for GET, HEAD and DELETE.
        '500':
          $ref: '#/components/responses/InternalServerError'

  /proxies:
    x-summary: Proxy Management
    get:
      tags:
        - proxy
      operationId: Proxies_Search
      description: Fetch defined proxies
      summary: Fetch Defined Proxies
      security:
        - bearerAuth: []
      parameters:
        - name: Accept
          in: header
          description: Accepted content types
          required: true
          schema:
            type: string
          example: application/json
        - name: Authorization
          in: header
          description: The access token
          required: true
          schema:
            type: string
          example: Bearer abcde.12345.ABCDE
        - name: Citrix-TransactionId
          in: header
          description: Unique transaction ID of the call
          required: false
          schema:
            $ref: '#/components/schemas/TransactionId'
        - name: Citrix-Locale
          in: header
          description: Requested locale
          required: false
          schema:
            $ref: '#/components/schemas/RequestedLanguage'
        - name: Accept-Language
          in: header
          description: Browser language preferences
          required: false
          schema:
            $ref: '#/components/schemas/RequestedLanguage'
      responses:
        '200':
          description: List of proxies
          content:
            application/json; charset=utf-8:
              schema:
                $ref: '#/components/schemas/Proxies'
              example: {"items": [
                {"id": "924467d6-1663-4c95-ab8d-fc7e04b7be63", "location": "1.2.3.4:56", "status": "reachable"},
                {"id": "bb7bd743-3d12-4222-b1f5-556459d94c76", "location": "127.0.0.1:80", "status": "unreachable"}]}
          headers:
            Content-Type:
              schema:
                type: string
            X-Content-Type-Options:
              schema:
                type: string
            Content-Security-Policy:
              schema:
                type: string
            X-Frame-Options:
              schema:
                type: string
            Cache-Control:
              schema:
                type: string
            Citrix-TransactionId:
              schema:
                $ref: '#/components/schemas/TransactionId'
        '401':
          $ref: '#/components/responses/AccessDenied'
        '406':
          $ref: '#/components/responses/NotAcceptable'
        # Leave '415' (UnsupportedMediaType): There doesn't tend to be request content for GET, HEAD and DELETE.
        '500':
          $ref: '#/components/responses/InternalServerError'
    post:
      tags:
        - proxy
      operationId: Proxies_Post
      description: Add new proxy
      summary: Add New Proxy
      security:
        - bearerAuth: []
      parameters:
        - name: Accept
          in: header
          description: Accepted content types
          required: true
          schema:
            type: string
          example: application/json
        - name: Authorization
          in: header
          description: The access token
          required: true
          schema:
            type: string
          example: Bearer abcde.12345.ABCDE
        - name: Citrix-TransactionId
          in: header
          description: Unique transaction ID of the call
          required: false
          schema:
            $ref: '#/components/schemas/TransactionId'
        - name: Citrix-Locale
          in: header
          description: Requested locale
          required: false
          schema:
            $ref: '#/components/schemas/RequestedLanguage'
        - name: Accept-Language
          in: header
          description: Browser language preferences
          required: false
          schema:
            $ref: '#/components/schemas/RequestedLanguage'
      requestBody:
        description: New proxy to add
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/ProxyReq'
      responses:
        '201':
          description: New proxy has been added
          content:
            application/json; charset=utf-8:
              schema:
                $ref: '#/components/schemas/Proxy'
          headers:
            Location:
              description: Location path of this newly created proxy
              schema:
                type:
                  string
              example:
                /proxies/924467d6-1663-4c95-ab8d-fc7e04b7be63
            Content-Type:
              schema:
                type: string
            X-Content-Type-Options:
              schema:
                type: string
            Content-Security-Policy:
              schema:
                type: string
            X-Frame-Options:
              schema:
                type: string
            Cache-Control:
              schema:
                type: string
            Citrix-TransactionId:
              schema:
                $ref: '#/components/schemas/TransactionId'
        '400':
          description: Invalid or missing field in request.
          content:
            application/json; charset=utf-8:
              schema:
                $ref: '#/components/schemas/ErrorModel'
          x-error-response-example:
            type: https://errors-api.cloud.com/common/missing
            detail: 'Field "location" is missing.'
            parameters:
              - name: property
                value: location
          headers:
            Content-Type:
              schema:
                type: string
            X-Content-Type-Options:
              schema:
                type: string
            Content-Security-Policy:
              schema:
                type: string
            X-Frame-Options:
              schema:
                type: string
            Cache-Control:
              schema:
                type: string
            Citrix-TransactionId:
              schema:
                $ref: '#/components/schemas/TransactionId'
        '401':
          $ref: '#/components/responses/AccessDenied'
        '406':
          $ref: '#/components/responses/NotAcceptable'
        '409':
          description: Configuration file for this proxy already exists
          content:
            application/json; charset=utf-8:
              schema:
                $ref: '#/components/schemas/ErrorModel'
          x-error-response-example:
            type: https://errors-api.cloud.com/connapp/conflict
            detail: Configuration file for this proxy already exists
          headers:
            Content-Type:
              schema:
                type: string
            X-Content-Type-Options:
              schema:
                type: string
            Content-Security-Policy:
              schema:
                type: string
            X-Frame-Options:
              schema:
                type: string
            Cache-Control:
              schema:
                type: string
            Citrix-TransactionId:
              schema:
                $ref: '#/components/schemas/TransactionId'
        '415':
          $ref: '#/components/responses/UnsupportedMediaType'
        '500':
          $ref: '#/components/responses/InternalServerError'
  /proxies/{id}:
    x-summary: Remove Proxy
    delete:
      tags:
        - proxy
      operationId: Proxies_Delete
      description: Remove proxy
      summary: Remove Proxy
      security:
        - bearerAuth: []
      parameters:
        - name: id
          in: path
          description: Unique identifier of the proxy record
          required: true
          schema:
            type: string
            format: uuid
          example: 924467d6-1663-4c95-ab8d-fc7e04b7be63
        - name: Accept
          in: header
          description: Accepted content types
          required: true
          schema:
            type: string
          example: '*/*'
        - name: Authorization
          in: header
          description: The access token
          required: true
          schema:
            type: string
          example: Bearer abcde.12345.ABCDE
        - name: Citrix-TransactionId
          in: header
          description: Unique transaction ID of the call
          required: false
          schema:
            $ref: '#/components/schemas/TransactionId'
        - name: Citrix-Locale
          in: header
          description: Requested locale
          required: false
          schema:
            $ref: '#/components/schemas/RequestedLanguage'
        - name: Accept-Language
          in: header
          description: Browser language preferences
          required: false
          schema:
            $ref: '#/components/schemas/RequestedLanguage'
      responses:
        '204':
          description: Proxy has been deleted
          headers:
            X-Content-Type-Options:
              schema:
                type: string
            Content-Security-Policy:
              schema:
                type: string
            X-Frame-Options:
              schema:
                type: string
            Cache-Control:
              schema:
                type: string
            Citrix-TransactionId:
              schema:
                $ref: '#/components/schemas/TransactionId'
        '404':
          $ref: '#/components/responses/NotFound'
        '401':
          $ref: '#/components/responses/AccessDenied'
        '406':
          $ref: '#/components/responses/NotAcceptable'
        # Leave '415' (UnsupportedMediaType): There doesn't tend to be request content for GET, HEAD and DELETE.
        '500':
          $ref: '#/components/responses/InternalServerError'

  /settings:
    x-summary: Get Machine Details
    get:
      tags:
        - details
      operationId: Settings_Search
      description: Get machine details
      summary: Get Machine Details
      security:
        - bearerAuth: []
      parameters:
        - name: Accept
          in: header
          description: Accepted content types
          required: true
          schema:
            type: string
          example: application/json
        - name: Authorization
          in: header
          description: The access token
          required: true
          schema:
            type: string
          example: Bearer abcde.12345.ABCDE
        - name: Citrix-TransactionId
          in: header
          description: Unique transaction ID of the call
          required: false
          schema:
            $ref: '#/components/schemas/TransactionId'
        - name: Citrix-Locale
          in: header
          description: Requested locale
          required: false
          schema:
            $ref: '#/components/schemas/RequestedLanguage'
        - name: Accept-Language
          in: header
          description: Browser language preferences
          required: false
          schema:
            $ref: '#/components/schemas/RequestedLanguage'
      responses:
        '200':
          description: Machine details
          content:
            application/json; charset=utf-8:
              schema:
                $ref: '#/components/schemas/Settings'
              examples:
                summary:
                  value: {
                    "ip": "192.168.0.2",
                    "dns": "8.8.4.5",
                    "netmask": "255.255.255.6",
                    "name": "dhcp-192.local"
                  }
          headers:
            Content-Type:
              schema:
                type: string
            X-Content-Type-Options:
              schema:
                type: string
            Content-Security-Policy:
              schema:
                type: string
            X-Frame-Options:
              schema:
                type: string
            Cache-Control:
              schema:
                type: string
            Citrix-TransactionId:
              schema:
                $ref: '#/components/schemas/TransactionId'
        '401':
          $ref: '#/components/responses/AccessDenied'
        '406':
          $ref: '#/components/responses/NotAcceptable'
        # Leave '415' (UnsupportedMediaType): There doesn't tend to be request content for GET, HEAD and DELETE.
        '500':
          $ref: '#/components/responses/InternalServerError'

  /networking:
    x-summary: Machine Network Information
    get:
      tags:
        - details
      operationId: Networking_Search
      description: Obtain network information
      summary: Obtain Network Information
      security:
        - bearerAuth: []
      parameters:
        - name: Accept
          in: header
          description: Accepted content types
          required: true
          schema:
            type: string
          example: application/json
        - name: Authorization
          in: header
          description: The access token
          required: true
          schema:
            type: string
          example: Bearer abcde.12345.ABCDE
        - name: Citrix-TransactionId
          in: header
          description: Unique transaction ID of the call
          required: false
          schema:
            $ref: '#/components/schemas/TransactionId'
        - name: Citrix-Locale
          in: header
          description: Requested locale
          required: false
          schema:
            $ref: '#/components/schemas/RequestedLanguage'
        - name: Accept-Language
          in: header
          description: Browser language preferences
          required: false
          schema:
            $ref: '#/components/schemas/RequestedLanguage'
      responses:
        '200':
          description: Machine details
          content:
            application/json; charset=utf-8:
              schema:
                $ref: '#/components/schemas/NetworkInformation'
              examples:
                summary:
                  value: {
                    "mode": "static",
                    "hostname": "dhcp-192.local",
                    "ipv4": {
                      "ip": "192.168.0.42",
                      "netmask": "255.255.0.0",
                      "route": "192.168.0.1"
                    },
                    "dns": ["8.8.8.8", "8.8.4.4"],
                    "ntp": ["192.168.0.1", "192.168.0.2", "192.168.0.3"]
                  }
          headers:
            Content-Type:
              schema:
                type: string
            X-Content-Type-Options:
              schema:
                type: string
            Content-Security-Policy:
              schema:
                type: string
            X-Frame-Options:
              schema:
                type: string
            Cache-Control:
              schema:
                type: string
            Citrix-TransactionId:
              schema:
                $ref: '#/components/schemas/TransactionId'
        '401':
          $ref: '#/components/responses/AccessDenied'
        '406':
          $ref: '#/components/responses/NotAcceptable'
        # Leave '415' (UnsupportedMediaType): There doesn't tend to be request content for GET, HEAD and DELETE.
        '500':
          $ref: '#/components/responses/InternalServerError'
    post:
      tags:
        - details
      operationId: Networking_Post
      description: Set networking information
      summary: Set Networking Information
      security:
        - bearerAuth: []
      parameters:
        - name: Accept
          in: header
          description: Accepted content types
          required: true
          schema:
            type: string
          example: '*/*'
        - name: Authorization
          in: header
          description: The access token
          required: true
          schema:
            type: string
          example: Bearer abcde.12345.ABCDE
        - name: Citrix-TransactionId
          in: header
          description: Unique transaction ID of the call
          required: false
          schema:
            $ref: '#/components/schemas/TransactionId'
        - name: Citrix-Locale
          in: header
          description: Requested locale
          required: false
          schema:
            $ref: '#/components/schemas/RequestedLanguage'
        - name: Accept-Language
          in: header
          description: Browser language preferences
          required: false
          schema:
            $ref: '#/components/schemas/RequestedLanguage'
      requestBody:
        required: true
        content:
          application/json; charset=utf-8:
            schema:
              $ref: "#/components/schemas/NetworkInformation"
            examples:
              summary:
                value: {
                  "mode": "dhcp"
                }
      responses:
        '200':
          description: "Set network successfully"
          headers:
            Content-Type:
              schema:
                type: string
            X-Content-Type-Options:
              schema:
                type: string
            Content-Security-Policy:
              schema:
                type: string
            X-Frame-Options:
              schema:
                type: string
            Cache-Control:
              schema:
                type: string
            Citrix-TransactionId:
              schema:
                $ref: '#/components/schemas/TransactionId'
        '400':
          description: "Missing or invalid arguments"
          content:
            application/json; charset=utf-8:
              schema:
                $ref: '#/components/schemas/ErrorModel'
          x-error-response-example:
            type: https://errors-api.cloud.com/common/missing
            detail: 'Field "mode" is missing.'
            parameters:
              - name: property,
                value: mode
          headers:
            Content-Type:
              schema:
                type: string
            X-Content-Type-Options:
              schema:
                type: string
            Content-Security-Policy:
              schema:
                type: string
            X-Frame-Options:
              schema:
                type: string
            Cache-Control:
              schema:
                type: string
            Citrix-TransactionId:
              schema:
                $ref: '#/components/schemas/TransactionId'
        '401':
          $ref: '#/components/responses/AccessDenied'
        '406':
          $ref: '#/components/responses/NotAcceptable'
        '415':
          $ref: '#/components/responses/UnsupportedMediaType'
        '500':
          description: "Failed to set the network"
          $ref: '#/components/responses/InternalServerError'

  /$reboot:
    x-summary: Reboots The Connector Appliance
    post:
      tags:
        - diagnostic
      operationId: Reboot_Post
      description: Reboots the Connector Appliance
      summary: Reboots The Connector Appliance
      security:
        - bearerAuth: []
      parameters:
        - name: Accept
          in: header
          description: Accepted content types
          required: true
          schema:
            type: string
          example: '*/*'
        - name: Authorization
          in: header
          description: The access token
          required: true
          schema:
            type: string
          example: Bearer abcde.12345.ABCDE
        - name: Citrix-TransactionId
          in: header
          description: Unique transaction ID of the call
          required: false
          schema:
            $ref: '#/components/schemas/TransactionId'
        - name: Citrix-Locale
          in: header
          description: Requested locale
          required: false
          schema:
            $ref: '#/components/schemas/RequestedLanguage'
        - name: Accept-Language
          in: header
          description: Browser language preferences
          required: false
          schema:
            $ref: '#/components/schemas/RequestedLanguage'
      responses:
        '202':
          description: "Platform accepted reboot"
          headers:
            Content-Type:
              schema:
                type: string
            X-Content-Type-Options:
              schema:
                type: string
            Content-Security-Policy:
              schema:
                type: string
            X-Frame-Options:
              schema:
                type: string
            Cache-Control:
              schema:
                type: string
            Citrix-TransactionId:
              schema:
                $ref: '#/components/schemas/TransactionId'
          content:
            application/json; charset=utf-8:
              schema:
                $ref: '#/components/schemas/StatusInfo'
                example:
                  status: Accepted
        '401':
          $ref: '#/components/responses/AccessDenied'
        '406':
          $ref: '#/components/responses/NotAcceptable'
        '415':
          $ref: '#/components/responses/UnsupportedMediaType'
        '500':
          $ref: '#/components/responses/InternalServerError'

  /domains:
    x-summary: Domain Management
    get:
      tags:
        - domain
      operationId: Domains_Search
      description: List joined domains
      summary: List Joined Domains
      security:
        - bearerAuth: []
      parameters:
        - name: Accept
          in: header
          description: Accepted content types
          required: true
          schema:
            type: string
          example: application/json
        - name: Authorization
          in: header
          description: The access token
          required: true
          schema:
            type: string
          example: Bearer abcde.12345.ABCDE
        - name: Citrix-TransactionId
          in: header
          description: Unique transaction ID of the call
          required: false
          schema:
            $ref: '#/components/schemas/TransactionId'
        - name: Citrix-Locale
          in: header
          description: Requested locale
          required: false
          schema:
            $ref: '#/components/schemas/RequestedLanguage'
        - name: Accept-Language
          in: header
          description: Browser language preferences
          required: false
          schema:
            $ref: '#/components/schemas/RequestedLanguage'
      responses:
        '200':
          description: List joined domain successfully
          content:
            application/json; charset=utf-8:
              schema:
                $ref: '#/components/schemas/Domains'
          headers:
            Content-Type:
              schema:
                type: string
            X-Content-Type-Options:
              schema:
                type: string
            Content-Security-Policy:
              schema:
                type: string
            X-Frame-Options:
              schema:
                type: string
            Cache-Control:
              schema:
                type: string
            Citrix-TransactionId:
              schema:
                $ref: '#/components/schemas/TransactionId'
        '401':
          $ref: '#/components/responses/AccessDenied'
        '406':
          $ref: '#/components/responses/NotAcceptable'
        # Leave '415' (UnsupportedMediaType): There doesn't tend to be request content for GET, HEAD and DELETE.
        '500':
          $ref: '#/components/responses/InternalServerError'
    post:
      tags:
        - domain
      operationId: Domains_Post
      description: Join domain
      summary: Join Domain
      security:
        - bearerAuth: []
      parameters:
        - name: Accept
          in: header
          description: Accepted content types
          required: true
          schema:
            type: string
          example: application/json
        - name: Authorization
          in: header
          description: The access token
          required: true
          schema:
            type: string
          example: Bearer abcde.12345.ABCDE
        - name: Citrix-TransactionId
          in: header
          description: Unique transaction ID of the call
          required: false
          schema:
            $ref: '#/components/schemas/TransactionId'
        - name: Citrix-Locale
          in: header
          description: Requested locale
          required: false
          schema:
            $ref: '#/components/schemas/RequestedLanguage'
        - name: Accept-Language
          in: header
          description: Browser language preferences
          required: false
          schema:
            $ref: '#/components/schemas/RequestedLanguage'
      requestBody:
        description: The information needed to join a domain
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/DomainJoin'
      responses:
        '200':
          description: The domain has already been joined
          headers:
            X-Content-Type-Options:
              schema:
                type: string
            Content-Security-Policy:
              schema:
                type: string
            X-Frame-Options:
              schema:
                type: string
            Cache-Control:
              schema:
                type: string
            Citrix-TransactionId:
              schema:
                $ref: '#/components/schemas/TransactionId'
        '201':
          description: Join domain successfully
          headers:
            Location:
              description: New domain URL
              schema:
                type:
                  string
            X-Content-Type-Options:
              schema:
                type: string
            Content-Security-Policy:
              schema:
                type: string
            X-Frame-Options:
              schema:
                type: string
            Cache-Control:
              schema:
                type: string
            Citrix-TransactionId:
              schema:
                $ref: '#/components/schemas/TransactionId'
        '400':
          description: Invalid or missing field in request.
          content:
            application/json; charset=utf-8:
              schema:
                $ref: '#/components/schemas/ErrorModel'
          x-error-response-example:
            type: https://errors-api.cloud.com/common/missing
            detail: 'Field "domain_name" is missing.'
            parameters:
              - name: property
                value: domain_name
          headers:
            Content-Type:
              schema:
                type: string
            X-Content-Type-Options:
              schema:
                type: string
            Content-Security-Policy:
              schema:
                type: string
            X-Frame-Options:
              schema:
                type: string
            Cache-Control:
              schema:
                type: string
            Citrix-TransactionId:
              schema:
                $ref: '#/components/schemas/TransactionId'
        '401':
          $ref: '#/components/responses/AccessDenied'
        '406':
          $ref: '#/components/responses/NotAcceptable'
        '415':
          $ref: '#/components/responses/UnsupportedMediaType'
        '422':
          $ref: '#/components/responses/AdError'
        '500':
          $ref: '#/components/responses/InternalServerError'

  /domains/{domain}:
    x-summary: Manage Specific Domain
    delete:
      tags:
        - domain
      operationId: Domains_Delete
      description: Leave domain
      summary: Leave Domain
      security:
        - bearerAuth: []
      parameters:
        - in: path
          name: domain
          schema:
            type: string
          required: true
          description: The name of the domain to leave
        - name: Accept
          in: header
          description: Accepted content types
          required: true
          schema:
            type: string
          example: application/json
        - name: Authorization
          in: header
          description: The access token
          required: true
          schema:
            type: string
          example: Bearer abcde.12345.ABCDE
        - name: Citrix-TransactionId
          in: header
          description: Unique transaction ID of the call
          required: false
          schema:
            $ref: '#/components/schemas/TransactionId'
        - name: Citrix-Locale
          in: header
          description: Requested locale
          required: false
          schema:
            $ref: '#/components/schemas/RequestedLanguage'
        - name: Accept-Language
          in: header
          description: Browser language preferences
          required: false
          schema:
            $ref: '#/components/schemas/RequestedLanguage'
      responses:
        '204':
          description: Left domain successfully
          headers:
            Content-Type:
              schema:
                type: string
            X-Content-Type-Options:
              schema:
                type: string
            Content-Security-Policy:
              schema:
                type: string
            X-Frame-Options:
              schema:
                type: string
            Cache-Control:
              schema:
                type: string
            Citrix-TransactionId:
              schema:
                $ref: '#/components/schemas/TransactionId'
        '401':
          $ref: '#/components/responses/AccessDenied'
        '404':
          description: Domain not found
          $ref: '#/components/responses/NotFound'
          headers:
            Content-Type:
              schema:
                type: string
            X-Content-Type-Options:
              schema:
                type: string
            Content-Security-Policy:
              schema:
                type: string
            X-Frame-Options:
              schema:
                type: string
            Cache-Control:
              schema:
                type: string
            Citrix-TransactionId:
              schema:
                $ref: '#/components/schemas/TransactionId'
        '406':
          $ref: '#/components/responses/NotAcceptable'
        # Leave '415' (UnsupportedMediaType): There doesn't tend to be request content for GET, HEAD and DELETE.
        '422':
          $ref: '#/components/responses/AdError'
        '500':
          $ref: '#/components/responses/InternalServerError'
    head:
      tags:
        - domain
      operationId: Domains_Head
      description: Check whether domain exists
      summary: Check Whether Domain Exists
      security:
        - bearerAuth: []
      parameters:
        - in: path
          name: domain
          schema:
            type: string
          required: true
          description: The name of the domain to check whether exist
        - name: Accept
          in: header
          description: Accepted content types
          required: true
          schema:
            type: string
          example: application/json
        - name: Authorization
          in: header
          description: The access token
          required: true
          schema:
            type: string
          example: Bearer abcde.12345.ABCDE
        - name: Citrix-TransactionId
          in: header
          description: Unique transaction ID of the call
          required: false
          schema:
            $ref: '#/components/schemas/TransactionId'
        - name: Citrix-Locale
          in: header
          description: Requested locale
          required: false
          schema:
            $ref: '#/components/schemas/RequestedLanguage'
        - name: Accept-Language
          in: header
          description: Browser language preferences
          required: false
          schema:
            $ref: '#/components/schemas/RequestedLanguage'
      responses:
        '200':
          description: The domain exist
          headers:
            X-Content-Type-Options:
              schema:
                type: string
            Content-Security-Policy:
              schema:
                type: string
            X-Frame-Options:
              schema:
                type: string
            Cache-Control:
              schema:
                type: string
            Citrix-TransactionId:
              schema:
                $ref: '#/components/schemas/TransactionId'
        '401':
          $ref: '#/components/responses/AccessDenied'
        '404':
          $ref: '#/components/responses/NotFound'
        '406':
          $ref: '#/components/responses/NotAcceptable'
        # Leave '415' (UnsupportedMediaType): There doesn't tend to be request content for GET, HEAD and DELETE.
        '500':
          $ref: '#/components/responses/InternalServerError'
    get:
      tags:
        - domain
      operationId: Domains_Get
      description: Get domain details
      summary: Get Domain Details
      security:
        - bearerAuth: []
      parameters:
        - in: path
          name: domain
          description: The name of the domain to get the details
          schema:
            type: string
          required: true
        - name: Accept
          in: header
          description: Accepted content types
          required: true
          schema:
            type: string
          example: application/json
        - name: Authorization
          in: header
          description: The access token
          required: true
          schema:
            type: string
          example: Bearer abcde.12345.ABCDE
        - name: Citrix-TransactionId
          in: header
          description: Unique transaction ID of the call
          required: false
          schema:
            $ref: '#/components/schemas/TransactionId'
        - name: Citrix-Locale
          in: header
          description: Requested locale
          required: false
          schema:
            $ref: '#/components/schemas/RequestedLanguage'
        - name: Accept-Language
          in: header
          description: Browser language preferences
          required: false
          schema:
            $ref: '#/components/schemas/RequestedLanguage'
      responses:
        '200':
          description: Get domain details successfully
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/DomainDetail'
          headers:
            Content-Type:
              schema:
                type: string
            X-Content-Type-Options:
              schema:
                type: string
            Content-Security-Policy:
              schema:
                type: string
            X-Frame-Options:
              schema:
                type: string
            Cache-Control:
              schema:
                type: string
            Citrix-TransactionId:
              schema:
                $ref: '#/components/schemas/TransactionId'
        '401':
          $ref: '#/components/responses/AccessDenied'
        '404':
          $ref: '#/components/responses/NotFound'
        '406':
          $ref: '#/components/responses/NotAcceptable'
        # Leave '415' (UnsupportedMediaType): There doesn't tend to be request content for GET, HEAD and DELETE.
        '500':
          $ref: '#/components/responses/InternalServerError'

  /credentials:
    x-summary: User Credentials Management
    get:
      tags:
        - authorization
      operationId: Credentials_Search
      description: Find if credentials are already setup
      summary: Find If Credentials Are Already Setup
      security:
        - {}
      parameters:
        - name: Accept
          in: header
          description: Accepted content types
          required: true
          schema:
            type: string
          example: application/json
        # Authorization header not required.
        - name: Citrix-TransactionId
          in: header
          description: Unique transaction ID of the call
          required: false
          schema:
            $ref: '#/components/schemas/TransactionId'
        - name: Citrix-Locale
          in: header
          description: Requested locale
          required: false
          schema:
            $ref: '#/components/schemas/RequestedLanguage'
        - name: Accept-Language
          in: header
          description: Browser language preferences
          required: false
          schema:
            $ref: '#/components/schemas/RequestedLanguage'
      responses:
        '200':
          description: Successfully found result.
          content:
            application/json; charset=utf-8:
              schema:
                $ref: '#/components/schemas/CredentialSetupInfo'
          headers:
            Content-Type:
              schema:
                type: string
            X-Content-Type-Options:
              schema:
                type: string
            Content-Security-Policy:
              schema:
                type: string
            X-Frame-Options:
              schema:
                type: string
            Cache-Control:
              schema:
                type: string
            Citrix-TransactionId:
              schema:
                $ref: '#/components/schemas/TransactionId'
        '406':
          $ref: '#/components/responses/NotAcceptable'
        # Leave '415' (UnsupportedMediaType): There doesn't tend to be request content for GET, HEAD and DELETE.
        '500':
          $ref: '#/components/responses/InternalServerError'
    post:
      tags:
        - authorization
      operationId: Credentials_Post
      description: Create default user with given credentials
      summary: Create Default User With Given Credentials
      security:
        - {}
      parameters:
        - name: Accept
          in: header
          description: Accepted content types
          required: true
          schema:
            type: string
          example: application/json
        # Authorization header not required.
        - name: Citrix-TransactionId
          in: header
          description: Unique transaction ID of the call
          required: false
          schema:
            $ref: '#/components/schemas/TransactionId'
        - name: Citrix-Locale
          in: header
          description: Requested locale
          required: false
          schema:
            $ref: '#/components/schemas/RequestedLanguage'
        - name: Accept-Language
          in: header
          description: Browser language preferences
          required: false
          schema:
            $ref: '#/components/schemas/RequestedLanguage'
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/credentials'
      responses:
        '201':
          description: User credentials created.
          content:
            application/json; charset=utf-8:
              schema:
                $ref: '#/components/schemas/StatusInfo'
                example:
                  status: success
                  details: Credentials set
          headers:
            Content-Type:
              schema:
                type: string
            X-Content-Type-Options:
              schema:
                type: string
            Content-Security-Policy:
              schema:
                type: string
            X-Frame-Options:
              schema:
                type: string
            Cache-Control:
              schema:
                type: string
            Citrix-TransactionId:
              schema:
                $ref: '#/components/schemas/TransactionId'
        '400':
          description: Invalid or missing field in request.
          content:
            application/json; charset=utf-8:
              schema:
                $ref: '#/components/schemas/ErrorModel'
          x-error-response-example:
            type: https://errors-api.cloud.com/common/invalidString
            detail: 'Field "password" has an invalid value.'
            parameters:
              - name: property
                value: password
          headers:
            Content-Type:
              schema:
                type: string
            X-Content-Type-Options:
              schema:
                type: string
            Content-Security-Policy:
              schema:
                type: string
            X-Frame-Options:
              schema:
                type: string
            Cache-Control:
              schema:
                type: string
            Citrix-TransactionId:
              schema:
                $ref: '#/components/schemas/TransactionId'
        '406':
          $ref: '#/components/responses/NotAcceptable'
        '415':
          $ref: '#/components/responses/UnsupportedMediaType'
        '500':
          $ref: '#/components/responses/InternalServerError'

  /$login:
    x-summary: Produce Token From Given User Credentials
    post:
      tags:
        - authorization
      operationId: Login_Post
      description: Produce token from given user credentials
      summary: Produce Token From Given User Credentials
      security:
        - {}
      parameters:
        - name: Accept
          in: header
          description: Accepted content types
          required: true
          schema:
            type: string
          example: application/json
        # Authorization header not required.
        - name: Citrix-TransactionId
          in: header
          description: Unique transaction ID of the call
          required: false
          schema:
            $ref: '#/components/schemas/TransactionId'
        - name: Citrix-Locale
          in: header
          description: Requested locale
          required: false
          schema:
            $ref: '#/components/schemas/RequestedLanguage'
        - name: Accept-Language
          in: header
          description: Browser language preferences
          required: false
          schema:
            $ref: '#/components/schemas/RequestedLanguage'
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/credentials'
      responses:
        '200':
          description: Token created and returned.
          content:
            application/json; charset=utf-8:
              schema:
                $ref: '#/components/schemas/token'
          headers:
            Content-Type:
              schema:
                type: string
            X-Content-Type-Options:
              schema:
                type: string
            Content-Security-Policy:
              schema:
                type: string
            X-Frame-Options:
              schema:
                type: string
            Cache-Control:
              schema:
                type: string
            Citrix-TransactionId:
              schema:
                $ref: '#/components/schemas/TransactionId'
        '400':
          description: Invalid or missing field in request.
          content:
            application/json; charset=utf-8:
              schema:
                $ref: "#/components/schemas/ErrorModel"
          x-error-response-example:
            type: https://errors-api.cloud.com/common/missing
            detail: 'Field "username" is missing.'
            parameters:
              - name: property
                value: username
          headers:
            Content-Type:
              schema:
                type: string
            X-Content-Type-Options:
              schema:
                type: string
            Content-Security-Policy:
              schema:
                type: string
            X-Frame-Options:
              schema:
                type: string
            Cache-Control:
              schema:
                type: string
            Citrix-TransactionId:
              schema:
                $ref: '#/components/schemas/TransactionId'
        '401':
          $ref: '#/components/responses/AccessDenied'
        '403':
          description: Token could not be produced.
          content:
            application/json; charset=utf-8:
              schema:
                $ref: '#/components/schemas/ErrorModel'
          x-error-response-example:
            type: https://errors-api.cloud.com/common/authorization
            detail: Authorization error
          headers:
            Content-Type:
              schema:
                type: string
            X-Content-Type-Options:
              schema:
                type: string
            Content-Security-Policy:
              schema:
                type: string
            X-Frame-Options:
              schema:
                type: string
            Cache-Control:
              schema:
                type: string
            Citrix-TransactionId:
              schema:
                $ref: '#/components/schemas/TransactionId'
        '406':
          $ref: '#/components/responses/NotAcceptable'
        '415':
          $ref: '#/components/responses/UnsupportedMediaType'

  /$changePassword:
    x-summary: Change Credentials For An Existing User
    post:
      tags:
        - authorization
      operationId: ChangePassword_Post
      description: Change credentials for an existing user
      summary: Change Credentials For An Existing User
      security:
        - bearerAuth: []
      parameters:
        - name: Accept
          in: header
          description: Accepted content types
          required: true
          schema:
            type: string
          example: application/json
        - name: Authorization
          in: header
          description: The access token
          required: true
          schema:
            type: string
          example: Bearer abcde.12345.ABCDE
        - name: Citrix-TransactionId
          in: header
          description: Unique transaction ID of the call
          required: false
          schema:
            $ref: '#/components/schemas/TransactionId'
        - name: Citrix-Locale
          in: header
          description: Requested locale
          required: false
          schema:
            $ref: '#/components/schemas/RequestedLanguage'
        - name: Accept-Language
          in: header
          description: Browser language preferences
          required: false
          schema:
            $ref: '#/components/schemas/RequestedLanguage'
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/ChangePassword'
      responses:
        '204':
          description: Credential updated, new secret created.
          content:
            application/json; charset=utf-8:
              schema:
                $ref: '#/components/schemas/token'
          headers:
            Content-Type:
              schema:
                type: string
            X-Content-Type-Options:
              schema:
                type: string
            Content-Security-Policy:
              schema:
                type: string
            X-Frame-Options:
              schema:
                type: string
            Cache-Control:
              schema:
                type: string
            Citrix-TransactionId:
              schema:
                $ref: '#/components/schemas/TransactionId'
        '400':
          $ref: '#/components/responses/InvalidJson'
        '401':
          $ref: '#/components/responses/AccessDenied'
        '403':
          description: Existing credentials/token are not valid.
          content:
            application/json; charset=utf-8:
              schema:
                $ref: '#/components/schemas/ErrorModel'
          x-error-response-example:
            type: https://errors-api.cloud.com/common/authorization
            detail: Authorization error
          headers:
            Content-Type:
              schema:
                type: string
            X-Content-Type-Options:
              schema:
                type: string
            Content-Security-Policy:
              schema:
                type: string
            X-Frame-Options:
              schema:
                type: string
            Cache-Control:
              schema:
                type: string
            Citrix-TransactionId:
              schema:
                $ref: '#/components/schemas/TransactionId'
        '406':
          $ref: '#/components/responses/NotAcceptable'
        '415':
          $ref: '#/components/responses/UnsupportedMediaType'

  /ping:
    x-summary: Ping Connector Appliance
    get:
      tags:
        - diagnostic
      operationId: Ping_Search
      description: Ping Connector Appliance
      summary: Ping Connector Appliance
      security:
        - bearerAuth: []
      parameters:
        - name: Accept
          in: header
          description: Accepted content types
          required: true
          schema:
            type: string
          example: application/json
        - name: Authorization
          in: header
          description: The access token
          required: true
          schema:
            type: string
          example: Bearer abcde.12345.ABCDE
        - name: Citrix-TransactionId
          in: header
          description: Unique transaction ID of the call
          required: false
          schema:
            $ref: '#/components/schemas/TransactionId'
        - name: Citrix-Locale
          in: header
          description: Requested locale
          required: false
          schema:
            $ref: '#/components/schemas/RequestedLanguage'
        - name: Accept-Language
          in: header
          description: Browser language preferences
          required: false
          schema:
            $ref: '#/components/schemas/RequestedLanguage'
      responses:
        '200':
          description: Ping response
          content:
            application/json; charset=utf-8:
              schema:
                $ref: '#/components/schemas/pingResponse'
          headers:
            Content-Type:
              schema:
                type: string
            X-Content-Type-Options:
              schema:
                type: string
            Content-Security-Policy:
              schema:
                type: string
            X-Frame-Options:
              schema:
                type: string
            Cache-Control:
              schema:
                type: string
            Citrix-TransactionId:
              schema:
                $ref: '#/components/schemas/TransactionId'
        '401':
          $ref: '#/components/responses/AccessDenied'
        '406':
          $ref: '#/components/responses/NotAcceptable'
        # Leave '415' (UnsupportedMediaType): There doesn't tend to be request content for GET, HEAD and DELETE.

  /utctime:
    x-summary: Retrieve UTC Time Of Connector Appliance
    get:
      tags:
        - diagnostic
      operationId: Utctime_Search
      description: UTC Time Of Connector Appliance
      summary: UTC Time Of Connector Appliance
      security:
        - {}
      parameters:
        - name: Accept
          in: header
          description: Accepted content types
          required: true
          schema:
            type: string
          example: application/json
        # Authorization header not required.
        - name: Citrix-TransactionId
          in: header
          description: Unique transaction ID of the call
          required: false
          schema:
            $ref: '#/components/schemas/TransactionId'
        - name: Citrix-Locale
          in: header
          description: Requested locale
          required: false
          schema:
            $ref: '#/components/schemas/RequestedLanguage'
        - name: Accept-Language
          in: header
          description: Browser language preferences
          required: false
          schema:
            $ref: '#/components/schemas/RequestedLanguage'
      responses:
        '200':
          description: UTC time response
          content:
            application/json; charset=utf-8:
              schema:
                $ref: '#/components/schemas/utctimeResponse'
          headers:
            Content-Type:
              schema:
                type: string
            X-Content-Type-Options:
              schema:
                type: string
            Content-Security-Policy:
              schema:
                type: string
            X-Frame-Options:
              schema:
                type: string
            Cache-Control:
              schema:
                type: string
            Citrix-TransactionId:
              schema:
                $ref: '#/components/schemas/TransactionId'
        '406':
          $ref: '#/components/responses/NotAcceptable'
        # Leave '415' (UnsupportedMediaType): There doesn't tend to be request content for GET, HEAD and DELETE.

  /aggregateConnectivityCheck:
    x-summary: Aggregate Connectivity Check
    get:
      tags:
        - connectivity
      operationId: Aggregate_Connectivity_Check_Search
      description: Perform aggregate connectivity check
      summary: Perform Aggregate Connectivity Check
      security:
        - bearerAuth: []
      parameters:
        - name: deployment
          in: query
          description: Which deployment to attempt to contact if unregistered, when registered this will be ignored
          required: false
          schema:
            type: string
            enum:
              - production
              - staging
              - productionjp
              - stagingjp
          example: staging
        - name: Accept
          in: header
          description: Accepted content types
          required: true
          schema:
            type: string
          example: application/json
        - name: Authorization
          in: header
          description: The access token
          required: true
          schema:
            type: string
          example: Bearer abcde.12345.ABCDE
        - name: Citrix-TransactionId
          in: header
          description: Unique transaction ID of the call
          required: false
          schema:
            $ref: '#/components/schemas/TransactionId'
        - name: Citrix-Locale
          in: header
          description: Requested locale
          required: false
          schema:
            $ref: '#/components/schemas/RequestedLanguage'
        - name: Accept-Language
          in: header
          description: Browser language preferences
          required: false
          schema:
            $ref: '#/components/schemas/RequestedLanguage'
      responses:
        '200':
          description: Overall Connectivity Check Status
          content:
            application/json; charset=utf-8:
              schema:
                $ref: "#/components/schemas/ConnectivityCheckResponse"
          headers:
            Content-Type:
              schema:
                type: string
            X-Content-Type-Options:
              schema:
                type: string
            Content-Security-Policy:
              schema:
                type: string
            X-Frame-Options:
              schema:
                type: string
            Cache-Control:
              schema:
                type: string
            Citrix-TransactionId:
              schema:
                $ref: '#/components/schemas/TransactionId'
        '400':
          description: Invalid or missing field in request.
          content:
            application/json; charset=utf-8:
              schema:
                $ref: '#/components/schemas/ErrorModel'
          x-error-response-example:
            type: https://errors-api.cloud.com/common/invalidString
            detail: 'Field "deployment" has an invalid value.'
            parameters:
              - name: property
                value: deployment
          headers:
            Content-Type:
              schema:
                type: string
            X-Content-Type-Options:
              schema:
                type: string
            Content-Security-Policy:
              schema:
                type: string
            X-Frame-Options:
              schema:
                type: string
            Cache-Control:
              schema:
                type: string
            Citrix-TransactionId:
              schema:
                $ref: '#/components/schemas/TransactionId'
        '401':
          $ref: '#/components/responses/AccessDenied'
        '406':
          $ref: '#/components/responses/NotAcceptable'
        # Leave '415' (UnsupportedMediaType): There doesn't tend to be request content for GET, HEAD and DELETE.
        '500':
          $ref: '#/components/responses/InternalServerError'

  /networkTrace:
    x-summary: Manage The Collection Of Network Traces
    get:
      tags:
        - diagnostic
      operationId: Network_Trace_Search
      description: List network capture trace files
      summary: List Network Capture Trace Files
      security:
        - bearerAuth: []
      parameters:
        - name: Accept
          in: header
          description: Accepted content types
          required: true
          schema:
            type: string
          example: application/json
        - name: Authorization
          in: header
          description: The access token
          required: true
          schema:
            type: string
          example: Bearer abcde.12345.ABCDE
        - name: Citrix-TransactionId
          in: header
          description: Unique transaction ID of the call
          required: false
          schema:
            $ref: '#/components/schemas/TransactionId'
        - name: Citrix-Locale
          in: header
          description: Requested locale
          required: false
          schema:
            $ref: '#/components/schemas/RequestedLanguage'
        - name: Accept-Language
          in: header
          description: Browser language preferences
          required: false
          schema:
            $ref: '#/components/schemas/RequestedLanguage'
      responses:
        "200":
          description: "Listed network capture trace files"
          content:
            application/json; charset=utf-8:
              schema:
                $ref: "#/components/schemas/NetworkTraceResponse"
          headers:
            Content-Type:
              schema:
                type: string
            X-Content-Type-Options:
              schema:
                type: string
            Content-Security-Policy:
              schema:
                type: string
            X-Frame-Options:
              schema:
                type: string
            Cache-Control:
              schema:
                type: string
            Citrix-TransactionId:
              schema:
                $ref: '#/components/schemas/TransactionId'
        "401":
          $ref: '#/components/responses/AccessDenied'
        '406':
          $ref: '#/components/responses/NotAcceptable'
        # Leave '415' (UnsupportedMediaType): There doesn't tend to be request content for GET, HEAD and DELETE.
        "500":
          $ref: '#/components/responses/InternalServerError'

    post:
      tags:
        - diagnostic
      operationId: Network_Trace_Post
      description: Start a network trace
      summary: Start A Network Trace
      security:
        - bearerAuth: []
      parameters:
        - name: Accept
          in: header
          description: Accepted content types
          required: true
          schema:
            type: string
          example: application/json
        - name: Authorization
          in: header
          description: The access token
          required: true
          schema:
            type: string
          example: Bearer abcde.12345.ABCDE
        - name: Citrix-TransactionId
          in: header
          description: Unique transaction ID of the call
          required: false
          schema:
            $ref: '#/components/schemas/TransactionId'
        - name: Citrix-Locale
          in: header
          description: Requested locale
          required: false
          schema:
            $ref: '#/components/schemas/RequestedLanguage'
        - name: Accept-Language
          in: header
          description: Browser language preferences
          required: false
          schema:
            $ref: '#/components/schemas/RequestedLanguage'
      requestBody:
        description: The parameters to trigger a network trace
        content:
          application/json; charset=utf-8:
            schema:
              $ref: '#/components/schemas/NetworkTraceRequest'
      responses:
        "202":
          description: Accepted
          headers:
            Location:
              schema:
                type: string
              description: The URI to download and delete the capture file
              example: /networkTrace/eth0-2020-01-02-10-01-55-189000
            Content-Type:
              schema:
                type: string
            X-Content-Type-Options:
              schema:
                type: string
            Content-Security-Policy:
              schema:
                type: string
            X-Frame-Options:
              schema:
                type: string
            Cache-Control:
              schema:
                type: string
            Citrix-TransactionId:
              schema:
                $ref: '#/components/schemas/TransactionId'
          content:
            application/json; charset=utf-8:
              schema:
                $ref: "#/components/schemas/NetworkTraceItem"
        "400":
          description: Invalid parameters
          content:
            application/json; charset=utf-8:
              schema:
                $ref: "#/components/schemas/ErrorModel"
          x-error-response-example:
            type: https://errors-api.cloud.com/common/outOfRange
            detail: 'Field "hostPort" is out of range.'
            parameters:
              - name: property
                value: hostPort
          headers:
            Content-Type:
              schema:
                type: string
            X-Content-Type-Options:
              schema:
                type: string
            Content-Security-Policy:
              schema:
                type: string
            X-Frame-Options:
              schema:
                type: string
            Cache-Control:
              schema:
                type: string
            Citrix-TransactionId:
              schema:
                $ref: '#/components/schemas/TransactionId'
        "401":
          $ref: '#/components/responses/AccessDenied'
        '406':
          $ref: '#/components/responses/NotAcceptable'
        "409":
          description: Conflict. There is already a running capture
          content:
            application/json; charset=utf-8:
              schema:
                $ref: "#/components/schemas/ErrorModel"
          x-error-response-example:
            type: https://errors-api.cloud.com/common/optimisticConcurrency
            detail: A capture is already running
          headers:
            Content-Type:
              schema:
                type: string
            X-Content-Type-Options:
              schema:
                type: string
            Content-Security-Policy:
              schema:
                type: string
            X-Frame-Options:
              schema:
                type: string
            Cache-Control:
              schema:
                type: string
            Citrix-TransactionId:
              schema:
                $ref: '#/components/schemas/TransactionId'
        '415':
          $ref: '#/components/responses/UnsupportedMediaType'
        "500":
          $ref: '#/components/responses/InternalServerError'

  /networkTrace/{id}:
    x-summary: Manage Network Traces Individually
    get:
      tags:
        - diagnostic
      operationId: Network_Trace_Get
      description: Retrieve a network trace file
      summary: Retrieve A Network Trace File
      security:
        - bearerAuth: []
      parameters:
        - name: id
          in: path
          description: Unique identifier of the network trace record
          required: true
          schema:
            type: string
          example: eth0-2020-01-02-10-01-55-189000
        - name: Accept
          in: header
          description: Accepted content types
          required: true
          schema:
            type: string
          example: application/vnd.tcpdump.pcap
        - name: Accept-Encoding
          in: header
          description: Content encoding preferences
          required: false
          schema:
            type: string
          example: gzip
        - name: Authorization
          in: header
          description: The access token
          required: true
          schema:
            type: string
          example: Bearer abcde.12345.ABCDE
        - name: Citrix-TransactionId
          in: header
          description: Unique transaction ID of the call
          required: false
          schema:
            $ref: '#/components/schemas/TransactionId'
        - name: Citrix-Locale
          in: header
          description: Requested locale
          required: false
          schema:
            $ref: '#/components/schemas/RequestedLanguage'
        - name: Accept-Language
          in: header
          description: Browser language preferences
          required: false
          schema:
            $ref: '#/components/schemas/RequestedLanguage'
      responses:
        '200':
          description: Download a network trace
          content:
            application/vnd.tcpdump.pcap:
              schema:
                type: string
                format: binary
          headers:
            Content-Disposition:
              example: attachment; filename="eth0-2020-01-02-10-01-55-189000.pcap"
              description: >
                An appropriate filename, see
                https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Content-Disposition
              schema:
                type: string
            Content-Encoding:
              schema:
                type: string
              example: gzip
            Content-Type:
              schema:
                type: string
              examples:
                general:
                  value: application/octet-stream
                specific:
                  value: application/vnd.tcpdump.pcap
            X-Content-Type-Options:
              schema:
                type: string
            Content-Security-Policy:
              schema:
                type: string
            X-Frame-Options:
              schema:
                type: string
            Cache-Control:
              schema:
                type: string
            Citrix-TransactionId:
              schema:
                $ref: '#/components/schemas/TransactionId'
        '401':
          $ref: '#/components/responses/AccessDenied'
        '404':
          $ref: '#/components/responses/NotFound'
        '406':
          $ref: '#/components/responses/NotAcceptable'
        # Leave '415' (UnsupportedMediaType): There doesn't tend to be request content for GET, HEAD and DELETE.
        '500':
          $ref: '#/components/responses/InternalServerError'

    patch:
      tags:
        - diagnostic
      operationId: Network_Trace_Patch
      description: Stop a network trace
      summary: Stop A Network Trace
      security:
        - bearerAuth: []
      parameters:
        - name: id
          in: path
          description: Unique identifier of the network trace record
          required: true
          schema:
            type: string
          example: eth0-2020-01-02-10-01-55-189000
        - name: Accept
          in: header
          description: Accepted content types
          required: true
          schema:
            type: string
          example: '*/*'
        - name: Authorization
          in: header
          description: The access token
          required: true
          schema:
            type: string
          example: Bearer abcde.12345.ABCDE
        - name: Citrix-TransactionId
          in: header
          description: Unique transaction ID of the call
          required: false
          schema:
            $ref: '#/components/schemas/TransactionId'
        - name: Citrix-Locale
          in: header
          description: Requested locale
          required: false
          schema:
            $ref: '#/components/schemas/RequestedLanguage'
        - name: Accept-Language
          in: header
          description: Browser language preferences
          required: false
          schema:
            $ref: '#/components/schemas/RequestedLanguage'
      requestBody:
        description: The parameters to stop a network trace
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/NetworkTracePatchRequest'
      responses:
        '204':
          description: Network trace has been stopped
          headers:
            X-Content-Type-Options:
              schema:
                type: string
            Content-Security-Policy:
              schema:
                type: string
            X-Frame-Options:
              schema:
                type: string
            Cache-Control:
              schema:
                type: string
            Citrix-TransactionId:
              schema:
                $ref: '#/components/schemas/TransactionId'
        '400':
          description: Invalid parameters
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/ErrorModel"
          x-error-response-example:
            type: https://errors-api.cloud.com/common/invalidString
            detail: 'Field "hostAddress" has an invalid value.'
            parameters:
              - name: property
                value: hostAddress
          headers:
            Content-Type:
              schema:
                type: string
            X-Content-Type-Options:
              schema:
                type: string
            Content-Security-Policy:
              schema:
                type: string
            X-Frame-Options:
              schema:
                type: string
            Cache-Control:
              schema:
                type: string
            Citrix-TransactionId:
              schema:
                $ref: '#/components/schemas/TransactionId'
        '401':
          $ref: '#/components/responses/AccessDenied'
        '404':
          $ref: '#/components/responses/NotFound'
        '406':
          $ref: '#/components/responses/NotAcceptable'
        '415':
          $ref: '#/components/responses/UnsupportedMediaType'
        '500':
          $ref: '#/components/responses/InternalServerError'

    delete:
      tags:
        - diagnostic
      operationId: Network_Trace_Delete
      description: Remove trace file
      summary: Remove Trace File
      security:
        - bearerAuth: []
      parameters:
        - name: id
          in: path
          description: Unique identifier of the network trace record
          required: true
          schema:
            type: string
          example: eth0-2020-01-02-10-01-55-189000
        - name: Accept
          in: header
          description: Accepted content types
          required: true
          schema:
            type: string
          example: '*/*'
        - name: Authorization
          in: header
          description: The access token
          required: true
          schema:
            type: string
          example: Bearer abcde.12345.ABCDE
        - name: Citrix-TransactionId
          in: header
          description: Unique transaction ID of the call
          required: false
          schema:
            $ref: '#/components/schemas/TransactionId'
        - name: Citrix-Locale
          in: header
          description: Requested locale
          required: false
          schema:
            $ref: '#/components/schemas/RequestedLanguage'
        - name: Accept-Language
          in: header
          description: Browser language preferences
          required: false
          schema:
            $ref: '#/components/schemas/RequestedLanguage'
      responses:
        '204':
          description: Trace file has been deleted
          headers:
            X-Content-Type-Options:
              schema:
                type: string
            Content-Security-Policy:
              schema:
                type: string
            X-Frame-Options:
              schema:
                type: string
            Cache-Control:
              schema:
                type: string
            Citrix-TransactionId:
              schema:
                $ref: '#/components/schemas/TransactionId'
        '401':
          $ref: '#/components/responses/AccessDenied'
        '404':
          $ref: '#/components/responses/NotFound'
        '406':
          $ref: '#/components/responses/NotAcceptable'
        # Leave '415' (UnsupportedMediaType): There doesn't tend to be request content for GET, HEAD and DELETE.
        '500':
          $ref: '#/components/responses/InternalServerError'

  /$validateServiceTicket:
    x-summary: Make A Request To Check If A Service Ticket Can Be Retrieved To Check SSO
    post:
      tags:
        - domain
      operationId: Validate_Service_Ticket_Post
      description: Service ticket validation on behalf of the user
      summary: Service Ticket Validation On Behalf Of The User
      security:
        - bearerAuth: []
      parameters:
        - name: Accept
          in: header
          description: Accepted content types
          required: true
          schema:
            type: string
          example: application/json
        - name: Authorization
          in: header
          description: The access token
          required: true
          schema:
            type: string
          example: Bearer abcde.12345.ABCDE
        - name: Citrix-TransactionId
          in: header
          description: Unique transaction ID of the call
          required: false
          schema:
            $ref: '#/components/schemas/TransactionId'
        - name: Citrix-Locale
          in: header
          description: Requested locale
          required: false
          schema:
            $ref: '#/components/schemas/RequestedLanguage'
        - name: Accept-Language
          in: header
          description: Browser language preferences
          required: false
          schema:
            $ref: '#/components/schemas/RequestedLanguage'
      requestBody:
        description: The parameters to perform the service ticket validation
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/ServiceValidationRequest'
      responses:
        "200":
          description: Successfully validate the service ticket on behalf of the user
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/ValidationStatus"
          headers:
            Content-Type:
              schema:
                type: string
            X-Content-Type-Options:
              schema:
                type: string
            Content-Security-Policy:
              schema:
                type: string
            X-Frame-Options:
              schema:
                type: string
            Cache-Control:
              schema:
                type: string
            Citrix-TransactionId:
              schema:
                $ref: '#/components/schemas/TransactionId'
        "400":
          description: Invalid parameters
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/ErrorModel"
          x-error-response-example:
            type: https://errors-api.cloud.com/common/missing
            detail: 'Field "domain" is missing.'
            parameters:
              - name: property
                value: domain
          headers:
            Content-Type:
              schema:
                type: string
            X-Content-Type-Options:
              schema:
                type: string
            Content-Security-Policy:
              schema:
                type: string
            X-Frame-Options:
              schema:
                type: string
            Cache-Control:
              schema:
                type: string
            Citrix-TransactionId:
              schema:
                $ref: '#/components/schemas/TransactionId'
        "401":
          $ref: '#/components/responses/AccessDenied'
        "404":
          $ref: '#/components/responses/NotFound'
        '406':
          $ref: '#/components/responses/NotAcceptable'
        '415':
          $ref: '#/components/responses/UnsupportedMediaType'
        "500":
          $ref: '#/components/responses/InternalServerError'

  /$replaceSslCert:
    x-summary: Replace The Certificate For The Web Front End
    post:
      tags:
        - certificate
      operationId: Replace_Ssl_Cert_Post
      description: Provide a new certificate for the web front end
      summary: Provide A New Certificate For The Web Front End
      security:
        - bearerAuth: []
      parameters:
        - name: Accept
          in: header
          description: Accepted content types
          required: true
          schema:
            type: string
          example: application/json
        - name: Authorization
          in: header
          description: The access token
          required: true
          schema:
            type: string
          example: Bearer abcde.12345.ABCDE
        - name: Citrix-TransactionId
          in: header
          description: Unique transaction ID of the call
          required: false
          schema:
            $ref: '#/components/schemas/TransactionId'
        - name: Citrix-Locale
          in: header
          description: Requested locale
          required: false
          schema:
            $ref: '#/components/schemas/RequestedLanguage'
        - name: Accept-Language
          in: header
          description: Browser language preferences
          required: false
          schema:
            $ref: '#/components/schemas/RequestedLanguage'
      requestBody:
        description: The parameters to perform the SSL certificate replacement
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/ReplaceSslCertRequest'
      responses:
        "202":
          description: Successfully replaced the certificate
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/ReplaceSslCertResponse"
          headers:
            Content-Type:
              schema:
                type: string
            X-Content-Type-Options:
              schema:
                type: string
            Content-Security-Policy:
              schema:
                type: string
            X-Frame-Options:
              schema:
                type: string
            Cache-Control:
              schema:
                type: string
            Citrix-TransactionId:
              schema:
                $ref: '#/components/schemas/TransactionId'
        "400":
          description: Invalid parameters
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/ErrorModel"
          x-error-response-example:
            type: https://errors-api.cloud.com/common/missing
            detail: 'Field "certBytes" is missing.'
            parameters:
              - name: property
                value: certBytes
          headers:
            Content-Type:
              schema:
                type: string
            X-Content-Type-Options:
              schema:
                type: string
            Content-Security-Policy:
              schema:
                type: string
            X-Frame-Options:
              schema:
                type: string
            Cache-Control:
              schema:
                type: string
            Citrix-TransactionId:
              schema:
                $ref: '#/components/schemas/TransactionId'
        "401":
          $ref: '#/components/responses/AccessDenied'
        '406':
          $ref: '#/components/responses/NotAcceptable'
        '415':
          $ref: '#/components/responses/UnsupportedMediaType'
        "500":
          $ref: '#/components/responses/InternalServerError'

  /rootCA:
    x-summary: Manage The Collection Of RootCAs
    post:
      tags:
        - certificate
      operationId: RootCA_Post
      description: Add new rootCA
      summary: Add New RootCA
      security:
        - bearerAuth: []
      parameters:
        - name: Accept
          in: header
          description: Accepted content types
          required: true
          schema:
            type: string
          example: application/json
        - name: Authorization
          in: header
          description: The access token
          required: true
          schema:
            type: string
          example: Bearer abcde.12345.ABCDE
        - name: Citrix-TransactionId
          in: header
          description: Unique transaction ID of the call
          required: false
          schema:
            $ref: '#/components/schemas/TransactionId'
        - name: Citrix-Locale
          in: header
          description: Requested locale
          required: false
          schema:
            $ref: '#/components/schemas/RequestedLanguage'
        - name: Accept-Language
          in: header
          description: Browser language preferences
          required: false
          schema:
            $ref: '#/components/schemas/RequestedLanguage'
      requestBody:
        description: The parameters to add a new root CA
        content:
          application/json; charset=utf-8:
            schema:
              $ref: '#/components/schemas/RootCAAddRequest'
      responses:
        "201":
          description: OK
          headers:
            Location:
              schema:
                type: string
              description: The URI to view and delete the root CA
              example: /rootCA/01234567-89ab-cdef-0123-456789abcdef
            Content-Type:
              schema:
                type: string
            X-Content-Type-Options:
              schema:
                type: string
            Content-Security-Policy:
              schema:
                type: string
            X-Frame-Options:
              schema:
                type: string
            Cache-Control:
              schema:
                type: string
            Citrix-TransactionId:
              schema:
                $ref: '#/components/schemas/TransactionId'
          content:
            application/json; charset=utf-8:
              schema:
                $ref: "#/components/schemas/RootCAItemResponse"
        "400":
          description: Invalid parameters
          content:
            application/json; charset=utf-8:
              schema:
                $ref: "#/components/schemas/ErrorModel"
          x-error-response-example:
            type: https://errors-api.cloud.com/common/missing
            detail: 'Field "rootCA" is missing.'
            parameters:
              - name: property
                value: rootCA
          headers:
            Content-Type:
              schema:
                type: string
            X-Content-Type-Options:
              schema:
                type: string
            Content-Security-Policy:
              schema:
                type: string
            X-Frame-Options:
              schema:
                type: string
            Cache-Control:
              schema:
                type: string
            Citrix-TransactionId:
              schema:
                $ref: '#/components/schemas/TransactionId'
        "401":
          $ref: '#/components/responses/AccessDenied'
        '406':
          $ref: '#/components/responses/NotAcceptable'
        '409':
          description: Configuration file for this proxy already exists
          content:
            application/json; charset=utf-8:
              schema:
                $ref: '#/components/schemas/ErrorModel'
          x-error-response-example:
            type: https://errors-api.cloud.com/connapp/conflict
            detail: Configuration for this rootCA already exists
          headers:
            Content-Type:
              schema:
                type: string
            X-Content-Type-Options:
              schema:
                type: string
            Content-Security-Policy:
              schema:
                type: string
            X-Frame-Options:
              schema:
                type: string
            Cache-Control:
              schema:
                type: string
            Citrix-TransactionId:
              schema:
                $ref: '#/components/schemas/TransactionId'
        '415':
          $ref: '#/components/responses/UnsupportedMediaType'
        "500":
          $ref: '#/components/responses/InternalServerError'
    get:
      tags:
        - certificate
      operationId: RootCA_Search
      description: Fetch defined rootCAs
      summary: Fetch Defined RootCAs
      security:
        - bearerAuth: []
      parameters:
        - name: Accept
          in: header
          description: Accepted content types
          required: true
          schema:
            type: string
          example: application/json
        - name: Authorization
          in: header
          description: The access token
          required: true
          schema:
            type: string
          example: Bearer abcde.12345.ABCDE
        - name: Citrix-TransactionId
          in: header
          description: Unique transaction ID of the call
          required: false
          schema:
            $ref: '#/components/schemas/TransactionId'
        - name: Citrix-Locale
          in: header
          description: Requested locale
          required: false
          schema:
            $ref: '#/components/schemas/RequestedLanguage'
        - name: Accept-Language
          in: header
          description: Browser language preferences
          required: false
          schema:
            $ref: '#/components/schemas/RequestedLanguage'
      responses:
        '200':
          description: List of rootCAs
          content:
            application/json; charset=utf-8:
              schema:
                $ref: '#/components/schemas/RootCAItemsResponse'
          headers:
            Content-Type:
              schema:
                type: string
            X-Content-Type-Options:
              schema:
                type: string
            Content-Security-Policy:
              schema:
                type: string
            X-Frame-Options:
              schema:
                type: string
            Cache-Control:
              schema:
                type: string
            Citrix-TransactionId:
              schema:
                $ref: '#/components/schemas/TransactionId'
        '401':
          $ref: '#/components/responses/AccessDenied'
        '406':
          $ref: '#/components/responses/NotAcceptable'
        # Leave '415' (UnsupportedMediaType): There doesn't tend to be request content for GET, HEAD and DELETE.
        '500':
          $ref: '#/components/responses/InternalServerError'
  /rootCA/{id}:
    x-summary: Manage An Individual RootCA
    delete:
      tags:
        - certificate
      operationId: RootCA_Delete
      description: Remove RootCA
      summary: Remove RootCA
      security:
        - bearerAuth: []
      parameters:
        - name: id
          in: path
          description: Unique identifier of the rootCA record
          required: true
          schema:
            type: string
            format: uuid
          example: 01234567-89ab-cdef-0123-456789abcdef
        - name: Accept
          in: header
          description: Accepted content types
          required: true
          schema:
            type: string
          example: '*/*'
        - name: Authorization
          in: header
          description: The access token
          required: true
          schema:
            type: string
          example: Bearer abcde.12345.ABCDE
        - name: Citrix-TransactionId
          in: header
          description: Unique transaction ID of the call
          required: false
          schema:
            $ref: '#/components/schemas/TransactionId'
        - name: Citrix-Locale
          in: header
          description: Requested locale
          required: false
          schema:
            $ref: '#/components/schemas/RequestedLanguage'
        - name: Accept-Language
          in: header
          description: Browser language preferences
          required: false
          schema:
            $ref: '#/components/schemas/RequestedLanguage'
      responses:
        '204':
          description: RootCA has been deleted
          headers:
            X-Content-Type-Options:
              schema:
                type: string
            Content-Security-Policy:
              schema:
                type: string
            X-Frame-Options:
              schema:
                type: string
            Cache-Control:
              schema:
                type: string
            Citrix-TransactionId:
              schema:
                $ref: '#/components/schemas/TransactionId'
        '404':
          $ref: '#/components/responses/NotFound'
        '401':
          $ref: '#/components/responses/AccessDenied'
        '406':
          $ref: '#/components/responses/NotAcceptable'
        # Leave '415' (UnsupportedMediaType): There doesn't tend to be request content for GET, HEAD and DELETE.
        '500':
          $ref: '#/components/responses/InternalServerError'
    patch:
      tags:
        - certificate
      operationId: RootCA_Patch
      description: Modify RootCA
      summary: Modify RootCA
      security:
        - bearerAuth: []
      parameters:
        - name: id
          in: path
          description: Unique identifier of the rootCA record
          required: true
          schema:
            type: string
            format: uuid
          example: 01234567-89ab-cdef-0123-456789abcdef
        - name: Accept
          in: header
          description: Accepted content types
          required: true
          schema:
            type: string
          example: '*/*'
        - name: Authorization
          in: header
          description: The access token
          required: true
          schema:
            type: string
          example: Bearer abcde.12345.ABCDE
        - name: Citrix-TransactionId
          in: header
          description: Unique transaction ID of the call
          required: false
          schema:
            $ref: '#/components/schemas/TransactionId'
        - name: Citrix-Locale
          in: header
          description: Requested locale
          required: false
          schema:
            $ref: '#/components/schemas/RequestedLanguage'
        - name: Accept-Language
          in: header
          description: Browser language preferences
          required: false
          schema:
            $ref: '#/components/schemas/RequestedLanguage'
      requestBody:
        description: The parameter to enable or disable a Root CA
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/RootCAPatchRequest'
      responses:
        '204':
          description: RootCA has been modified
          headers:
            X-Content-Type-Options:
              schema:
                type: string
            Content-Security-Policy:
              schema:
                type: string
            X-Frame-Options:
              schema:
                type: string
            Cache-Control:
              schema:
                type: string
            Citrix-TransactionId:
              schema:
                $ref: '#/components/schemas/TransactionId'
        '400':
          description: Invalid or missing field in request.
          content:
            application/json; charset=utf-8:
              schema:
                $ref: '#/components/schemas/ErrorModel'
          x-error-response-example:
            type: https://errors-api.cloud.com/common/missing
            detail: 'Field "enabled" is missing.'
            parameters:
              - name: property
                value: enabled
          headers:
            Content-Type:
              schema:
                type: string
            X-Content-Type-Options:
              schema:
                type: string
            Content-Security-Policy:
              schema:
                type: string
            X-Frame-Options:
              schema:
                type: string
            Cache-Control:
              schema:
                type: string
            Citrix-TransactionId:
              schema:
                $ref: '#/components/schemas/TransactionId'
        '401':
          $ref: '#/components/responses/AccessDenied'
        '404':
          $ref: '#/components/responses/NotFound'
        '406':
          $ref: '#/components/responses/NotAcceptable'
        '415':
          $ref: '#/components/responses/UnsupportedMediaType'
        '500':
          $ref: '#/components/responses/InternalServerError'
    get:
      tags:
        - certificate
      operationId: RootCA_Get
      description: Get RootCA
      summary: Get RootCA
      security:
        - bearerAuth: []
      parameters:
        - name: id
          in: path
          description: Unique identifier of the rootCA record
          required: true
          schema:
            type: string
            format: uuid
          example: 01234567-89ab-cdef-0123-456789abcdef
        - name: Accept
          in: header
          description: Accepted content types
          required: true
          schema:
            type: string
          example: '*/*'
        - name: Authorization
          in: header
          description: The access token
          required: true
          schema:
            type: string
          example: Bearer abcde.12345.ABCDE
        - name: Citrix-TransactionId
          in: header
          description: Unique transaction ID of the call
          required: false
          schema:
            $ref: '#/components/schemas/TransactionId'
        - name: Citrix-Locale
          in: header
          description: Requested locale
          required: false
          schema:
            $ref: '#/components/schemas/RequestedLanguage'
        - name: Accept-Language
          in: header
          description: Browser language preferences
          required: false
          schema:
            $ref: '#/components/schemas/RequestedLanguage'
      responses:
        '200':
          description: Value of rootCA
          content:
            application/json; charset=utf-8:
              schema:
                $ref: '#/components/schemas/RootCAItemResponse'
          headers:
            Content-Type:
              schema:
                type: string
            X-Content-Type-Options:
              schema:
                type: string
            Content-Security-Policy:
              schema:
                type: string
            X-Frame-Options:
              schema:
                type: string
            Cache-Control:
              schema:
                type: string
            Citrix-TransactionId:
              schema:
                $ref: '#/components/schemas/TransactionId'
        '400':
          description: Invalid or missing field in request.
          content:
            application/json; charset=utf-8:
              schema:
                $ref: '#/components/schemas/ErrorModel'
          x-error-response-example:
            type: https://errors-api.cloud.com/common/invalidString
            detail: 'Field "id" has an invalid value.'
            parameters:
              - name: property
                value: id
          headers:
            Content-Type:
              schema:
                type: string
            X-Content-Type-Options:
              schema:
                type: string
            Content-Security-Policy:
              schema:
                type: string
            X-Frame-Options:
              schema:
                type: string
            Cache-Control:
              schema:
                type: string
            Citrix-TransactionId:
              schema:
                $ref: '#/components/schemas/TransactionId'
        '401':
          $ref: '#/components/responses/AccessDenied'
        '404':
          $ref: '#/components/responses/NotFound'
        '406':
          $ref: '#/components/responses/NotAcceptable'
        # Leave '415' (UnsupportedMediaType): There doesn't tend to be request content for GET, HEAD and DELETE.
        '500':
          $ref: '#/components/responses/InternalServerError'

  /serviceAccounts:
    x-summary: Management Service Accounts
    post:
      tags:
        - service account
      operationId: ServiceAccounts_Post
      description: Create a service account along with given password
      summary: Create A Service Account With Given Password
      security:
        - bearerAuth: []
      parameters:
        - name: Accept
          in: header
          description: Accepted content types
          required: true
          schema:
            type: string
          example: application/json
        - name: Authorization
          in: header
          description: The access token
          required: true
          schema:
            type: string
          example: Bearer abcde.12345.ABCDE
        - name: Citrix-TransactionId
          in: header
          description: Unique transaction ID of the call
          required: false
          schema:
            $ref: '#/components/schemas/TransactionId'
        - name: Citrix-Locale
          in: header
          description: Requested locale
          required: false
          schema:
            $ref: '#/components/schemas/RequestedLanguage'
        - name: Accept-Language
          in: header
          description: Browser language preferences
          required: false
          schema:
            $ref: '#/components/schemas/RequestedLanguage'
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/ServiceAccount'
      responses:
        '201':
          description: Service account created.
          content:
            application/json; charset=utf-8:
              schema:
                $ref: '#/components/schemas/ServiceAccountName'
                example:
                  accountName: svc_acct
          headers:
            Location:
              schema:
                type: string
              description: The URI to view and delete the service account
              example: /serviceAccounts/01234567-89ab-cdef-0123-456789abcdef
            Content-Type:
              schema:
                type: string
            X-Content-Type-Options:
              schema:
                type: string
            Content-Security-Policy:
              schema:
                type: string
            X-Frame-Options:
              schema:
                type: string
            Cache-Control:
              schema:
                type: string
            Citrix-TransactionId:
              schema:
                $ref: '#/components/schemas/TransactionId'
        '400':
          description: Invalid or missing field in request.
          content:
            application/json; charset=utf-8:
              schema:
                $ref: '#/components/schemas/ErrorModel'
          x-error-response-example:
            type: https://errors-api.cloud.com/common/invalidString
            detail: 'Field "password" has an invalid value.'
            parameters:
              - name: property
                value: password
          headers:
            Content-Type:
              schema:
                type: string
            X-Content-Type-Options:
              schema:
                type: string
            Content-Security-Policy:
              schema:
                type: string
            X-Frame-Options:
              schema:
                type: string
            Cache-Control:
              schema:
                type: string
            Citrix-TransactionId:
              schema:
                $ref: '#/components/schemas/TransactionId'
        "401":
          $ref: '#/components/responses/AccessDenied'
        '406':
          $ref: '#/components/responses/NotAcceptable'
        '409':
          description: The service account already exists or the domain already has a service account
          content:
            application/json; charset=utf-8:
              schema:
                $ref: '#/components/schemas/ErrorModel'
          x-error-response-example:
            type: https://errors-api.cloud.com/connapp/conflict
            detail: The service account already exists or the domain already has a service account
          headers:
            Content-Type:
              schema:
                type: string
            X-Content-Type-Options:
              schema:
                type: string
            Content-Security-Policy:
              schema:
                type: string
            X-Frame-Options:
              schema:
                type: string
            Cache-Control:
              schema:
                type: string
            Citrix-TransactionId:
              schema:
                $ref: '#/components/schemas/TransactionId'
        '415':
          $ref: '#/components/responses/UnsupportedMediaType'
        '500':
          $ref: '#/components/responses/InternalServerError'
    get:
      tags:
        - service account
      operationId: ServiceAccounts_Search
      description: Get all the service accounts
      summary: Get All Service Accounts
      security:
        - bearerAuth: []
      parameters:
        - name: Accept
          in: header
          description: Accepted content types
          required: true
          schema:
            type: string
          example: application/json
        - name: Authorization
          in: header
          description: The access token
          required: true
          schema:
            type: string
          example: Bearer abcde.12345.ABCDE
        - name: Citrix-TransactionId
          in: header
          description: Unique transaction ID of the call
          required: false
          schema:
            $ref: '#/components/schemas/TransactionId'
        - name: Citrix-Locale
          in: header
          description: Requested locale
          required: false
          schema:
            $ref: '#/components/schemas/RequestedLanguage'
        - name: Accept-Language
          in: header
          description: Browser language preferences
          required: false
          schema:
            $ref: '#/components/schemas/RequestedLanguage'
      responses:
        '200':
          description: List of Service Accounts
          content:
            application/json; charset=utf-8:
              schema:
                $ref: '#/components/schemas/AccountList'
          headers:
            Content-Type:
              schema:
                type: string
            X-Content-Type-Options:
              schema:
                type: string
            Content-Security-Policy:
              schema:
                type: string
            X-Frame-Options:
              schema:
                type: string
            Cache-Control:
              schema:
                type: string
            Citrix-TransactionId:
              schema:
                $ref: '#/components/schemas/TransactionId'
        '401':
          $ref: '#/components/responses/AccessDenied'
        '406':
          $ref: '#/components/responses/NotAcceptable'
        '500':
          $ref: '#/components/responses/InternalServerError'

  /serviceAccounts/{account_id}:
    x-summary: Manage An Service Account
    delete:
      tags:
        - service account
      operationId: ServiceAccount_Delete
      description: Remove ServiceAccount
      summary: Remove ServiceAccount
      security:
        - bearerAuth: []
      parameters:
        - name: account_id
          in: path
          description: uuid of the Service Account
          required: true
          schema:
            type: string
            format: uuid
          example: 01234567-89ab-cdef-0123-456789abcdef
        - name: Accept
          in: header
          description: Accepted content types
          required: true
          schema:
            type: string
          example: '*/*'
        - name: Authorization
          in: header
          description: The access token
          required: true
          schema:
            type: string
          example: Bearer abcde.12345.ABCDE
        - name: Citrix-TransactionId
          in: header
          description: Unique transaction ID of the call
          required: false
          schema:
            $ref: '#/components/schemas/TransactionId'
        - name: Citrix-Locale
          in: header
          description: Requested locale
          required: false
          schema:
            $ref: '#/components/schemas/RequestedLanguage'
        - name: Accept-Language
          in: header
          description: Browser language preferences
          required: false
          schema:
            $ref: '#/components/schemas/RequestedLanguage'
      responses:
        '204':
          description: ServiceAccount has been deleted
          headers:
            X-Content-Type-Options:
              schema:
                type: string
            Content-Security-Policy:
              schema:
                type: string
            X-Frame-Options:
              schema:
                type: string
            Cache-Control:
              schema:
                type: string
            Citrix-TransactionId:
              schema:
                $ref: '#/components/schemas/TransactionId'
        "400":
          description: Invalid account id
          content:
            application/json; charset=utf-8:
              schema:
                $ref: "#/components/schemas/ErrorModel"
          x-error-response-example:
            type: https://errors-api.cloud.com/common/invalidString
            detail: Field 'account_id' has an invalid value
            parameters:
              - name: property
                value: account_id
          headers:
            Content-Type:
              schema:
                type: string
            X-Content-Type-Options:
              schema:
                type: string
            Content-Security-Policy:
              schema:
                type: string
            X-Frame-Options:
              schema:
                type: string
            Cache-Control:
              schema:
                type: string
            Citrix-TransactionId:
              schema:
                $ref: '#/components/schemas/TransactionId'
        '401':
          $ref: '#/components/responses/AccessDenied'
        '404':
          $ref: '#/components/responses/NotFound'
        '500':
          $ref: '#/components/responses/InternalServerError'

components:
  responses:
    AccessDenied:
      description: Access denied.
      content:
        application/json; charset=utf-8:
          schema:
            $ref: '#/components/schemas/ErrorModel'
      x-error-response-example:
        type: https://errors-api.cloud.com/common/authentication
        detail: Missing authentication details
        parameters:
          - name: reason
            value: missing
      headers:
        Content-Type:
          schema:
            type: string
        X-Content-Type-Options:
          schema:
            type: string
        Content-Security-Policy:
          schema:
            type: string
        X-Frame-Options:
          schema:
            type: string
        Cache-Control:
          schema:
            type: string
        Citrix-TransactionId:
          schema:
            $ref: '#/components/schemas/TransactionId'
    InvalidJson:
      description: Request is not valid JSON
      content:
        application/json; charset=utf-8:
          schema:
            $ref: '#/components/schemas/ErrorModel'
      x-error-response-example:
        type: https://errors-api.cloud.com/common/invalidJson
        detail: Failed to decode request body as JSON
      headers:
        Content-Type:
          schema:
            type: string
          example: application/json; charset=utf-8
        X-Content-Type-Options:
          schema:
            type: string
        Content-Security-Policy:
          schema:
            type: string
        X-Frame-Options:
          schema:
            type: string
        Cache-Control:
          schema:
            type: string
        Citrix-TransactionId:
          schema:
            $ref: '#/components/schemas/TransactionId'
    InternalServerError:
      description: >
        Could not contact a shared service or an error happened
        while processing the request.
      content:
        application/json; charset=utf-8:
          schema:
            $ref: '#/components/schemas/ErrorModel'
      x-error-response-example:
        type: https://errors-api.cloud.com/connapp/error
        detail: An error has occurred.
      headers:
        Content-Type:
          schema:
            type: string
          example: application/json; charset=utf-8
        X-Content-Type-Options:
          schema:
            type: string
        Content-Security-Policy:
          schema:
            type: string
        X-Frame-Options:
          schema:
            type: string
        Cache-Control:
          schema:
            type: string
        Citrix-TransactionId:
          schema:
            $ref: '#/components/schemas/TransactionId'
    NotFound:
      description: The referenced entity does not exist.
      content:
        application/json; charset=utf-8:
          schema:
            $ref: '#/components/schemas/ErrorModel'
      x-error-response-example:
        type: https://errors-api.cloud.com/common/notFound
        detail: Not found
        parameters:
          - name: entityType
            value: https://identifiers-api.cloud.com/connapp/proxy
          - name: id
            value: '5435435435243'
      headers:
        Content-Type:
          schema:
            type: string
          example: application/json; charset=utf-8
        X-Content-Type-Options:
          schema:
            type: string
        Content-Security-Policy:
          schema:
            type: string
        X-Frame-Options:
          schema:
            type: string
        Cache-Control:
          schema:
            type: string
        Citrix-TransactionId:
          schema:
            $ref: '#/components/schemas/TransactionId'

    NotAcceptable:
      description:
        Indicates that the caller passed a value in the Accept header which indicates an unsupported media type.
      content:
        application/json; charset=utf-8:
          schema:
            $ref: '#/components/schemas/ErrorModel'
      x-error-response-example:
        type: https://errors-api.cloud.com/common/notAcceptable
        detail: Must accept "application/json; charset=utf-8" media type.
        parameters:
          - name: contentType
            value: application/json; charset=utf-8
      headers:
        Content-Type:
          schema:
            type: string
          example: application/json; charset=utf-8
        X-Content-Type-Options:
          schema:
            type: string
        Content-Security-Policy:
          schema:
            type: string
        X-Frame-Options:
          schema:
            type: string
        Cache-Control:
          schema:
            type: string
        Citrix-TransactionId:
          schema:
            $ref: '#/components/schemas/TransactionId'

    UnsupportedMediaType:
      description:
        The caller attempted to use an unsupported media type or charset for the HTTP request content.
      content:
        application/json; charset=utf-8:
          schema:
            $ref: '#/components/schemas/ErrorModel'
      x-error-response-example:
        type: https://errors-api.cloud.com/common/unsupportedMediaType
        detail: 'Must use "application/json; charset=utf-8" media type.'
        parameters:
          - name: mediaType
            value: application/json; charset=utf-8
      headers:
        Content-Type:
          schema:
            type: string
          example: application/json; charset=utf-8
        X-Content-Type-Options:
          schema:
            type: string
        Content-Security-Policy:
          schema:
            type: string
        X-Frame-Options:
          schema:
            type: string
        Cache-Control:
          schema:
            type: string
        Citrix-TransactionId:
          schema:
            $ref: '#/components/schemas/TransactionId'

    AdError:
      description: >
        Could not perform the requested operation becuse the
        active directory service returned an error.
      content:
        application/json; charset=utf-8:
          schema:
            $ref: '#/components/schemas/ErrorModel'
      x-error-response-example:
        type: https://errors-api.cloud.com/common/missing
        detail: 'Field "machine_account" is missing.'
        parameters:
          - name: property,
            value: machine_account
      headers:
        Content-Type:
          schema:
            type: string
          example: application/json; charset=utf-8
        X-Content-Type-Options:
          schema:
            type: string
        Content-Security-Policy:
          schema:
            type: string
        X-Frame-Options:
          schema:
            type: string
        Cache-Control:
          schema:
            type: string
        Citrix-TransactionId:
          schema:
            $ref: '#/components/schemas/TransactionId'

  schemas:
    TransactionId:
      description: Transaction ID that will be used to track this request. If not provided, a new GUID will be generated and returned.
      type: string
      format: uuid
      example: 01234567-89ab-cdef-0123-456789abcdef

    RequestedLanguage:
      type: string
      pattern: /^([a-z]{2})-([a-z]{2})$/
      example: en-US

    RegistrationConnectivityResponse:
      type: object
      required:
        - status
      properties:
        status:
          type: string
          enum: ['ok', 'failed']
          description: >
            The value "ok" means the registration connectivity check
            succeeded, "failed" means failed to connect to the cloud,
            or an internal error happened while running the
            registration connectivity check.
        details:
          type: string
          description: >
            Details of the error in case of the registration connectivity
            check did not succeeded
        connectivityCheckResults:
          type: array
          items:
            $ref: '#/components/schemas/ConnectivityCheckResult'
      example:
        status: ok

    KrsRegistrationRequest:
      type: object
      required:
        - name
      properties:
        name:
          type: string
        deployment:
          type: string
          enum:
            - production
            - staging
            - productionjp
          example: staging
        resource_location_id:
          type: string
          format: uuid

    UnattendedRegistrationRequest:
      type: object
      required:
        - applianceName
        - clientId
        - clientSecret
      properties:
        applianceName:
          type: string
          format: hostname
        clientId:
          type: string
          format: uuid
        clientSecret:
          type: string
          format: base64url
        deployment:
          type: string
          enum:
            - production
            - staging
            - productionjp
            - stagingjp
            - custom
          example: custom
        resourceLocationId:
          type: string
          format: uuid
        serviceAddressFormat:
          type: string
          format: uri
          example: https://service-eastus-asgard-a.ctxwsdev.net

    RegistrationStatus:
      type: object
      required:
        - status
      properties:
        status:
          type: string
          enum: [Registered, Unregistered]
          description: Whether or not the connector is currently registered
        id:
          type: string
        message:
          type: string
        code:
          type: string
        verificationUrl:
          type: string
        pollingInterval:
          type: number
        expiryTimestamp:
          type: integer

    ProxyReq:
      type: object
      required:
        - location
      properties:
        location:
          type: string
        username:
          type: string
        password:
          type: string
          format: password

    Proxies:
      type: object
      required:
        - items
      properties:
        items:
          type: array
          items:
            $ref: '#/components/schemas/Proxy'
    Proxy:
      type: object
      required:
        - location
      properties:
        id:
          type: string
        location:
          type: string
        status:
          type: string
        errorcode:
          type: string
        errormsg:
          type: string
    Settings:
      type: object
      required:
        - ip
        - dns
        - netmask
        - name
      properties:
        ip:
          type: string
        dns:
          type: array
          items:
            type: string
        netmask:
          type: string
        name:
          type: string
        customer_id:
          type: string
        resource_location_id:
          type: string
        connector_id:
          type: string
        service_profile_name:
          type: string
        customer_display_name:
          type: string
        deployment:
          type: string
          example: staging
        geo:
          type: string

    NetworkTraceRequest:
      type: object
      properties:
        hostAddress:
          type: string
        hostPort:
          type: integer
        captureFull:
          type: boolean
          description: Capture the packet content or not
        traceDurationSecs:
          type: integer
          description: The max time length (in seconds) of the trace
      required:
        - captureFull
        - traceDurationSecs
      example:
        hostAddress: 10.71.57.10
        hostPort: 80
        captureFull: false
        traceDurationSecs: 100

    NetworkTraceResponse:
      type: object
      required:
        - items
      properties:
        items:
          type: array
          items:
            $ref: "#/components/schemas/NetworkTraceItem"

    NetworkTraceItem:
      type: object
      required:
        - id
        - status
      example:
        id: eth0-2021-05-27-01-02-03-100100
        status: complete
      properties:
        id:
          type: string
        status:
          type: string
          enum: ["complete", "running"]
          description: The current running state of the given network trace

    NetworkTracePatchRequest:
      type: object
      required:
        - status
      properties:
        status:
          type: string
          enum: ["stop"]
          example: stop
          description: The desired state of for given network trace

    NetworkInformation:
      type: object
      required:
        - mode
        - hostname
        - ipv4
        - dns
        - ntp
      properties:
        mode:
          type: string
          enum:
            - dhcp
            - static
          example: dhcp
          description: Network mode
        hostname:
          type: string
        ipv4:
          $ref: "#/components/schemas/ipv4"
        dns:
          type: array
          items:
            type: string
        ntp:
          type: array
          items:
            type: string

    ipv4:
      type: object
      required:
        - ip
        - netmask
        - route
      properties:
        ip:
          type: string
        netmask:
          type: string
        route:
          type: string

    DomainJoin:
      type: object
      example:
        domain_name: acme.net
        user_name: user_name
        password: password
        machine_account: ConnApp-abcdefg
        ou_path: OU=testOU,DC=acme,DC=net
      properties:
        domain_name:
          type: string
        user_name:
          type: string
        password:
          type: string
          format: password
        machine_account:
          type: string
        ou_path:
          type: string
      required:
        - domain_name
        - user_name
        - password
        - machine_account

    Domains:
      type: object
      required:
        - items
      properties:
        items:
          type: array
          items:
            $ref: "#/components/schemas/Domain"
    Domain:
      type: object
      required:
        - domain_name
      properties:
        domain_name:
          type: string
        machine_account:
          type: string
      example:
        domain_name: acme.net
        machine_account: ConnApp-abcdefg

    DomainDetail:
      type: object
      required:
        - forest
        - domain_name
        - machine_account
        - worker_state
        - domains_in_forest
        - lastRotationDate
      properties:
        forest:
          type: string
        domain_name:
          type: string
        machine_account:
          type: string
        worker_state:
          type: string
        domains_in_forest:
          type: array
          items:
            type: string
        lastRotationDate:
          type: string
          format: date-time
      example:
        forest: rootacme.net
        domain_name: acme.net
        machine_account: ConnApp-abcdefg
        worker_state: registered
        domains_in_forest: ['acme.net', 'test1.acme.net']
        lastRotationDate: '2023-11-28T09:07:40Z'

    StatusInfo:
      type: object
      required:
        - status
      properties:
        status:
          type: string
        details:
          type: string
      example:
        status: failure
        details: Incorrect credentials

    credentials:
      type: object
      required:
        - username
      properties:
        username:
          type: string
        password:
          type: string
          format: password
      example:
        username: admin
        password: secret

    ServiceAccount:
      type: object
      required:
        - accountName
        - password
        - domain
      properties:
        accountName:
          type: string
        password:
          type: string
          format: password
        domain:
          type: string
      example:
        accountName: svc_acct
        password: secret
        domain: ucc.local

    ServiceAccountName:
      type: object
      required:
        - accountName
      properties:
        accountName:
          type: string
      example:
        accountName: svc_acct

    ChangePassword:
      type: object
      required:
        - username
        - currentPassword
        - newPassword
      properties:
        username:
          type: string
        currentPassword:
          type: string
          format: password
        newPassword:
          type: string
          format: password
      example:
        username: admin
        currentPassword: secret
        newPassword: newsecret

    token:
      type: object
      required:
        - token
      properties:
        token:
          type: string
      example:
        token: Bearer abcde.12345.ABCDE

    CredentialSetupInfo:
      type: object
      required:
        - credentialsAreSetup
      properties:
        credentialsAreSetup:
          type: boolean
      example:
        credentialsAreSetup:
          true

    pingResponse:
      type: object
      required:
        - response
      properties:
        response:
          type: boolean
      example:
        response: true

    utctimeResponse:
      type: string
      example: "\"2022-06-09T14:50:14.3485404Z\""

    ConnectivityCheckResponse:
      type: object
      required:
        - status
      properties:
        status:
          type: string
          enum: ['ok', 'failed']
          example: ok
          description: Whether or not all of the connectivity checks passed
        connectivityCheckResults:
          type: array
          items:
            $ref: '#/components/schemas/ConnectivityCheckResult'
      example:
        status:
          ok

    ConnectivityCheckResult:
      type: object
      required:
        - testName
        - status
      properties:
        testName:
          type: string
        status:
          type: string
          enum:
            - ok
            - failed
          example: ok
          description: Whether or not this connectivity check passed
        errors:
          type: array
          items:
            $ref: '#/components/schemas/ErrorModel'

    ServiceValidationRequest:
      type: object
      properties:
        domain:
          type: string
        user:
          type: string
        password:
          type: string
          description: Not required for KCD mode
        serviceName:
          type: string
          description: service principal name or service FQDN
      required:
        - domain
        - user
        - serviceName
      example:
        domain: acme.net
        user: alice
        password: password
        serviceName: http/acomputer.acme.net or acomputer.acme.net

    ValidationStatus:
      type: object
      example:
        status: ok
      properties:
        status:
          type: string
      required:
        - status

    ReplaceSslCertRequest:
      type: object
      properties:
        key:
          type: string
          description: The base64 encoded key optionally PEM wrapped.
        certBytes:
          type: string
          description: The base64 encoded certificate optionally PEM wrapped to allow certificate chains.
        passphrase:
          type: string
          description: Used to decrypt key files that are encrypted at the PEM block level.
      required:
        - key
        - certBytes

    ReplaceSslCertResponse:
      type: object
      example:
        status: accepted
      properties:
        status:
          type: string
      required:
        - status

    RootCAAddRequest:
      type: object
      properties:
        rootCA:
          type: string
          description: The new trusted root certificate
          example: >
            -----BEGIN CERTIFICATE-----
            MIIEWTCCA0GgAwIBAgIUSmas7Or+0Mc1DbbheaP31obAvHUwDQYJKoZIhvcNAQEL
            BQAwgbsxCzAJBgNVBAYTAlVLMRcwFQYDVQQIDA5DYW1icmlkZ2VzaGlyZTESMBAG
            A1UEBwwJQ2FtYnJpZGdlMRQwEgYDVQQKDAtIZWN0b3IgTHRkLjEUMBIGA1UECwwL
            RW5naW5lZXJpbmcxHzAdBgNVBAMMFnd3dy5oZWN0b3IuZXhhbXBsZS5jb20xMjAw
            BgkqhkiG9w0BCQEWI2hlY3Rvci5jb25uZWN0b3JAaGVjdG9yLmV4YW1wbGUuY29t
            MB4XDTIzMDIxNTE2MjAzNFoXDTMzMDIxMjE2MjAzNFowgbsxCzAJBgNVBAYTAlVL
            MRcwFQYDVQQIDA5DYW1icmlkZ2VzaGlyZTESMBAGA1UEBwwJQ2FtYnJpZGdlMRQw
            EgYDVQQKDAtIZWN0b3IgTHRkLjEUMBIGA1UECwwLRW5naW5lZXJpbmcxHzAdBgNV
            BAMMFnd3dy5oZWN0b3IuZXhhbXBsZS5jb20xMjAwBgkqhkiG9w0BCQEWI2hlY3Rv
            ci5jb25uZWN0b3JAaGVjdG9yLmV4YW1wbGUuY29tMIIBIjANBgkqhkiG9w0BAQEF
            AAOCAQ8AMIIBCgKCAQEAm2Rdo5TrcjJnlnLTWb4tORCUF4grmn/sEpNIuU2XhXd5
            nQcCe5DyfxSGYkjd0n2tBM/2ulg8/ZNSfIZ4ipKL41SRo3e9b51h1Q/F6DbZxBwJ
            KdJayfqy7tKCMyL2zSIQSTJ0r1mTnuhrJflzuuXPZtsU2irYPmj0FzrIyPi9xG9j
            4DhRFyrMYrCtzYwEcl3H8qEhQn0+/zKhOWSB6mCET5IkVuV9L8ynTNXbDlzXSJ6Z
            Ea94GDakJwu5PZcTYP/XxTJxHzKDlwKSJ1J8xoMHhpGglL6SU7AIjxn2cTWHyqRb
            vwyCqI4xF4ZGSbP8yxGTzybRk/6ZblnCA4ZCRPT4cQIDAQABo1MwUTAdBgNVHQ4E
            FgQUhbO/t2sySufP1178lkeNDRJH+1IwHwYDVR0jBBgwFoAUhbO/t2sySufP1178
            lkeNDRJH+1IwDwYDVR0TAQH/BAUwAwEB/zANBgkqhkiG9w0BAQsFAAOCAQEAXCNh
            RugFaqEwdG24FCYTq0WCmR2n2KarorgiJRDx8mJvXYcVxLA/Gh3/cQaNS1eD8vN1
            QYHVyms5/9+zgx2L2S9xuFvqpFEHc58ee0tmg+2kJ68Ai2CTLp0h/PHyCq0qj4pB
            r7OWRLv15VvOuiJD2af5bz5rngnh3wKjGdZbPf0O9Rfugt37lXRXW6d/BAqoADAA
            QyNPCNC64bUgc2n6kbTs0WKhKFLvccxvp6jnPfRmnqVQgPDc/NcLSWNZ2MZRIhxP
            9U9eOjN4WnP0Kb2GU/1GchzcDpW8JSEEXZckd/n5QeR6M4peYVNuGPdYJOxhuwcc
            BJAHXICvVsMHq6msEw==
            -----END CERTIFICATE-----
      required:
        - rootCA

    RootCAItemResponse:
      type: object
      properties:
        id:
          type: string
          format: uuid
          pattern: '/^[0-9A-F]{8}-[0-9A-F]{4}-4[0-9A-F]{3}-[89AB][0-9A-F]{3}-[0-9A-F]{12}$/i'
          maxLength: 36
          description: auto generated when created
          example: 01234567-89ab-cdef-0123-456789abcdef
        subject:
          type: string
          description: aka Common Name (CN)
          example: Baltimore CyberTrust Root
        issuer:
          type: string
          example: DigiCert
        expiry:
          type: string
          format: date
          example: "2024-01-02"
        fingerprint:
          type: string
          description: The SHA1 hash of the certificate's raw bytes (of the decoded DER)
          example: 42DC8A3186EDB531D1CF872196CD8AE7A73299FE
        rootCADetails:
          type: string
          description: The new trusted root certificate's human readable summary
          example: >
            # Common Name or Certificate Name: Baltimore CyberTrust Root
            # Owner: DigiCert
            # Certificate Issuer Organization: Baltimore
            # Certificate Issuer Organizational Unit: CyberTrust
            # Certificate Serial Number: 020000B9
            # SHA-256 Fingerprint: 16AF57A9F676B0AB126095AA5EBADEF22AB31119D644AC95CD4B93DBF3F26AEB
            # Subject + SPKI SHA256: 973A321CE7AB6CD2A8681EF8BD4F17968EE8390840C2AF7B529545C5B2A28D7D
            # Valid From [GMT]: 2000.05.12
            # Valid To [GMT]: 2025.05.12
            # Public Key Algorithm: RSA 2048 bits
            # Signature Hash Algorithm: SHA1WithRSA
            # Trust Bits: Websites;Email
            # EV Policy OID(s): Not EV
            # Approval Bug: https://bugzilla.mozilla.org/show_bug.cgi?id=430698
            # NSS Release When First Included:
            # Firefox Release When First Included: Firefox 1
            # Test Website - Valid: https://baltimore-cybertrust-root.chain-demos.digicert.com/
            # Test Website - Expired: https://baltimore-cybertrust-root-expired.chain-demos.digicert.com/
            # Test Website - Revoked: https://baltimore-cybertrust-root-revoked.chain-demos.digicert.com/
            # Mozilla Applied Constraints:
            # Company Website: https://www.digicert.com/
            # Geographic Focus: USA, Global
            ...
        enabled:
          type: boolean
          default: true
          description: Include the root certificate in the bundle
      required:
        - id
        - subject
        - issuer
        - expiry
        - fingerprint
        - rootCADetails
        - enabled

    RootCAItemsResponse:
      type: object
      properties:
        items:
          type: array
          items:
            $ref: "#/components/schemas/RootCAItemResponse"
        unappliedChanges:
          type: boolean
          example: true
      required:
        - items
        - unappliedChanges

    RootCAPatchRequest:
      type: object
      properties:
        enabled:
          type: boolean
      required:
        - enabled
      example:
        enabled: false

    AccountList:
      type: object
      properties:
        items:
          type: array
          items:
            $ref: "#/components/schemas/AccountInfo"
      required:
        - items

    AccountInfo:
      type: object
      properties:
        domainName:
          type: string
        accountName:
          type: string
        id:
          type: string
          format: uuid
          pattern: '/^[0-9A-F]{8}-[0-9A-F]{4}-4[0-9A-F]{3}-[89AB][0-9A-F]{3}-[0-9A-F]{12}$/i'
          maxLength: 36
          example: 01234567-89ab-cdef-0123-456789abcdef
      required:
        - domainName
        - accountName
        - id

    ErrorModel:
      type: object
      required:
        - type
        - detail
      properties:
        type:
          type: string
        detail:
          type: string
        parameters:
          type: array
          items:
            $ref: "#/components/schemas/ErrorParameters"
    ErrorParameters:
      type: object
      required:
        - name
        - value
      properties:
        name:
          type: string
        value:
          type: string

  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      bearerFormat: JWT
