Square Devices API

The Devices API from Square — 4 operation(s) for devices.

Operations 5

GET /v2/devices Square List Devices #
GET /v2/devices/codes Square List Device Codes #
POST /v2/devices/codes Square Create Device Code #
GET /v2/devices/codes/{id} Square Get Device Code #
GET /v2/devices/{device_id} Square Get Device #

Documentation

📖
Documentation
https://developer.squareup.com/docs/payments-overview
📖
APIReference
https://developer.squareup.com/reference/square/payments-api
📖
Documentation
https://developer.squareup.com/docs/orders-api/what-it-does
📖
APIReference
https://developer.squareup.com/reference/square/orders-api
📖
Documentation
https://developer.squareup.com/docs/catalog-api/what-it-does
📖
APIReference
https://developer.squareup.com/reference/square/catalog-api
📖
Documentation
https://developer.squareup.com/docs/inventory-api/what-it-does
📖
APIReference
https://developer.squareup.com/reference/square/inventory-api
📖
Documentation
https://developer.squareup.com/docs/customers
📖
APIReference
https://developer.squareup.com/reference/square/customers-api
📖
Documentation
https://developer.squareup.com/docs/locations-api
📖
APIReference
https://developer.squareup.com/reference/square/locations-api
📖
Documentation
https://developer.squareup.com/docs/team/overview
📖
APIReference
https://developer.squareup.com/reference/square/team-api
📖
Documentation
https://developer.squareup.com/docs/labor-api/what-it-does
📖
APIReference
https://developer.squareup.com/reference/square/labor-api
📖
Documentation
https://developer.squareup.com/docs/bookings-api/what-it-is
📖
APIReference
https://developer.squareup.com/reference/square/bookings-api
📖
Documentation
https://developer.squareup.com/docs/loyalty-api/overview
📖
APIReference
https://developer.squareup.com/reference/square/loyalty-api
📖
Documentation
https://developer.squareup.com/docs/gift-cards/using-gift-cards-api
📖
APIReference
https://developer.squareup.com/reference/square/gift-cards-api
📖
Documentation
https://developer.squareup.com/docs/invoices-api/overview
📖
APIReference
https://developer.squareup.com/reference/square/invoices-api
📖
Documentation
https://developer.squareup.com/docs/subscriptions-api/overview
📖
APIReference
https://developer.squareup.com/reference/square/subscriptions-api
📖
Documentation
https://developer.squareup.com/docs/checkout-api
📖
APIReference
https://developer.squareup.com/reference/square/checkout-api
📖
Documentation
https://developer.squareup.com/docs/terminal-api/overview
📖
APIReference
https://developer.squareup.com/reference/square/terminal-api
📖
Documentation
https://developer.squareup.com/docs/payments-refunds
📖
APIReference
https://developer.squareup.com/reference/square/refunds-api
📖
Documentation
https://developer.squareup.com/docs/disputes-api/overview
📖
APIReference
https://developer.squareup.com/reference/square/disputes-api
📖
Documentation
https://developer.squareup.com/docs/merchants-api
📖
APIReference
https://developer.squareup.com/reference/square/merchants-api
📖
Documentation
https://developer.squareup.com/docs/cards-api/overview
📖
APIReference
https://developer.squareup.com/reference/square/cards-api
📖
Documentation
https://developer.squareup.com/docs/vendors-api/manage-vendors-in-apps
📖
APIReference
https://developer.squareup.com/reference/square/vendors-api
📖
Documentation
https://developer.squareup.com/docs/cashdrawershift-api/reporting
📖
APIReference
https://developer.squareup.com/reference/square/cash-drawers-api
📖
Documentation
https://developer.squareup.com/docs/bank-accounts-api
📖
APIReference
https://developer.squareup.com/reference/square/bank-accounts-api
📖
Documentation
https://developer.squareup.com/docs/payouts-api/overview
📖
APIReference
https://developer.squareup.com/reference/square/payouts-api
📖
Documentation
https://developer.squareup.com/docs/web-payments/apple-pay
📖
APIReference
https://developer.squareup.com/reference/square/apple-pay-api
📖
Documentation
https://developer.squareup.com/docs/sites-api/overview
📖
APIReference
https://developer.squareup.com/reference/square/sites-api
📖
Documentation
https://developer.squareup.com/docs/snippets-api/overview
📖
APIReference
https://developer.squareup.com/reference/square/snippets-api
📖
Documentation
https://developer.squareup.com/docs/oauth-api/overview
📖
APIReference
https://developer.squareup.com/reference/square/oauth-api
📖
Documentation
https://developer.squareup.com/docs/webhooks/overview
📖
APIReference
https://developer.squareup.com/reference/square/webhook-subscriptions-api
📖
Documentation
https://developer.squareup.com/docs/events-api/overview
📖
APIReference
https://developer.squareup.com/reference/square/events-api
📖
Documentation
https://developer.squareup.com/docs/devices-api/overview
📖
APIReference
https://developer.squareup.com/reference/square/devices-api
📖
Documentation
https://developer.squareup.com/docs/customer-groups-api/what-it-does
📖
APIReference
https://developer.squareup.com/reference/square/customer-groups-api
📖
Documentation
https://developer.squareup.com/docs/customer-segments-api/what-it-does
📖
APIReference
https://developer.squareup.com/reference/square/customer-segments-api
📖
Documentation
https://developer.squareup.com/docs/gift-cards/using-gift-card-activities-api
📖
APIReference
https://developer.squareup.com/reference/square/gift-card-activities-api
📖
Documentation
https://developer.squareup.com/docs/customer-custom-attributes-api/overview
📖
APIReference
https://developer.squareup.com/reference/square/customer-custom-attributes-api

Specifications

Other Resources

Work with this as data

Every API here is available over the APIs.io API and to AI agents over MCP.

MCP server

One button, every client — Claude, Cursor, VS Code and the rest.

https://apis.io/mcp

Tools for apis

7 MCP tools reach this
  • find_apisBrowse and filter every API in the catalog.
  • get_api_artifactsOne API's artifacts, grouped by type.
  • get_openapiThe primary OpenAPI for this API.
  • find_similar_apisAPIs that look like this one.
  • apis_io_searchSTART HERE — APIs, providers and tags for one query, each with its total.
  • resolveTurn a domain, URL or GitHub org into the provider it belongs to.
  • find_cohortsEvery scored population of providers in the catalog.
All 92 tools →

Call it yourself

curl for this page
This API
curl "https://apis.io/api/v1/apis/square-devices-api"
All apis
curl "https://apis.io/api/v1/apis?limit=25"

Discovery needs no key. Ratings and market analysis are Pro.

Get an API key

Free tier, no form to fill in. Signing in shares your email address with us — we store it to create your key and to recognise you if you sign in with another provider. See our Privacy Policy and Terms.

A second provider on the same verified email joins the account you already have.

OpenAPI Specification

square-devices-api-openapi.yml Raw ↑
openapi: 3.2.0
info:
  version: '2.0'
  title: Square ApplePay Devices API
  description: 'Supercharge Square for sellers of every size. Our entire connected commerce platform  from elegant hardware to a rich suite of Square APIs  is yours to build with. Whether youre developing an app or composing a bespoke solution, this is the place to make it happen. '
  termsOfService: https://connect.squareup.com/tos
  contact:
    name: Square Developer Platform
    email: developers@squareup.com
    url: https://squareup.com/developers
  license:
    name: Apache 2.0
    url: http://www.apache.org/licenses/LICENSE-2.0.html
  externalDocs:
    description: 'Read the official documentation here:'
    url: https://docs.connect.squareup.com/
  x-server-configuration:
    default-environment: production
    default-server: default
    environments:
    - name: production
      servers:
      - name: default
        url: https://connect.squareup.com
    - name: sandbox
      servers:
      - name: default
        url: https://connect.squareupsandbox.com
    - name: custom
      servers:
      - name: default
        url: '{custom_url}'
    parameters:
    - name: custom_url
      description: Sets the base URL requests are made to. Defaults to `https://connect.squareup.com`
      type: string
      example: https://connect.squareup.com
  x-square-generic-error-codes:
  - ACCESS_TOKEN_EXPIRED
  - ACCESS_TOKEN_REVOKED
  - API_VERSION_INCOMPATIBLE
  - APPLICATION_DISABLED
  - ARRAY_EMPTY
  - ARRAY_LENGTH_TOO_LONG
  - ARRAY_LENGTH_TOO_SHORT
  - BAD_CERTIFICATE
  - BAD_GATEWAY
  - BAD_REQUEST
  - CONFLICT
  - CONFLICTING_PARAMETERS
  - CURRENCY_MISMATCH
  - EXPECTED_ARRAY
  - EXPECTED_BASE64_ENCODED_BYTE_ARRAY
  - EXPECTED_BOOLEAN
  - EXPECTED_FLOAT
  - EXPECTED_INTEGER
  - EXPECTED_JSON_BODY
  - EXPECTED_MAP
  - EXPECTED_OBJECT
  - EXPECTED_STRING
  - FORBIDDEN
  - GATEWAY_TIMEOUT
  - GONE
  - IDEMPOTENCY_KEY_REUSED
  - INCORRECT_TYPE
  - INSUFFICIENT_SCOPES
  - INTERNAL_SERVER_ERROR
  - INVALID_ARRAY_VALUE
  - INVALID_CONTENT_TYPE
  - INVALID_CURSOR
  - INVALID_ENUM_VALUE
  - INVALID_FORM_VALUE
  - INVALID_SORT_ORDER
  - INVALID_SQUARE_VERSION_FORMAT
  - INVALID_TIME
  - INVALID_TIME_RANGE
  - INVALID_VALUE
  - LOCATION_MISMATCH
  - MAP_KEY_LENGTH_TOO_LONG
  - MAP_KEY_LENGTH_TOO_SHORT
  - MERCHANT_SUBSCRIPTION_NOT_FOUND
  - METHOD_NOT_ALLOWED
  - MISSING_REQUIRED_PARAMETER
  - NOT_ACCEPTABLE
  - NOT_FOUND
  - NOT_IMPLEMENTED
  - NO_FIELDS_SET
  - RATE_LIMITED
  - REQUEST_ENTITY_TOO_LARGE
  - REQUEST_TIMEOUT
  - SANDBOX_NOT_SUPPORTED
  - SERVICE_UNAVAILABLE
  - TOO_MANY_MAP_ENTRIES
  - UNAUTHORIZED
  - UNEXPECTED_VALUE
  - UNKNOWN_BODY_PARAMETER
  - UNKNOWN_QUERY_PARAMETER
  - UNPROCESSABLE_ENTITY
  - UNSUPPORTED_MEDIA_TYPE
  - V1_ACCESS_TOKEN
  - V1_APPLICATION
  - VALUE_EMPTY
  - VALUE_REGEX_MISMATCH
  - VALUE_TOO_HIGH
  - VALUE_TOO_LONG
  - VALUE_TOO_LOW
  - VALUE_TOO_SHORT
servers:
- url: https://connect.squareup.com
  variables: {}
tags:
- name: Devices
paths:
  /v2/devices:
    get:
      tags:
      - Devices
      summary: Square List Devices
      operationId: ListDevices
      x-microcks-operation:
        delay: 0
        dispatcher: FALLBACK
      description: 'List devices associated with the merchant. Currently, only Terminal API

        devices are supported.'
      x-release-status: BETA
      security:
      - oauth2:
        - DEVICES_READ
      parameters:
      - name: cursor
        description: 'A pagination cursor returned by a previous call to this endpoint.

          Provide this cursor to retrieve the next set of results for the original query.

          See [Pagination](https://developer.squareup.com/docs/build-basics/common-api-patterns/pagination) for more information.'
        schema:
          type: string
        in: query
        required: false
      - name: sort_order
        description: 'The order in which results are listed.

          - `ASC` - Oldest to newest.

          - `DESC` - Newest to oldest (default).'
        schema:
          $ref: '#/components/schemas/SortOrder'
        in: query
        required: false
      - name: limit
        description: The number of results to return in a single page.
        schema:
          type: integer
        in: query
        required: false
      - name: location_id
        description: If present, only returns devices at the target location.
        schema:
          type: string
        in: query
        required: false
      responses:
        '200':
          description: Success
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ListDevicesResponse'
      x-endpoint-errors:
      - error-code: BAD_REQUEST
  /v2/devices/codes:
    get:
      tags:
      - Devices
      summary: Square List Device Codes
      operationId: ListDeviceCodes
      x-microcks-operation:
        delay: 0
        dispatcher: FALLBACK
      description: Lists all DeviceCodes associated with the merchant.
      x-release-status: PUBLIC
      security:
      - oauth2:
        - DEVICE_CREDENTIAL_MANAGEMENT
      parameters:
      - name: cursor
        description: 'A pagination cursor returned by a previous call to this endpoint.

          Provide this to retrieve the next set of results for your original query.


          See [Paginating results](https://developer.squareup.com/docs/working-with-apis/pagination) for more information.'
        schema:
          type: string
        in: query
        required: false
      - name: location_id
        description: 'If specified, only returns DeviceCodes of the specified location.

          Returns DeviceCodes of all locations if empty.'
        schema:
          type: string
        in: query
        required: false
      - name: product_type
        description: 'If specified, only returns DeviceCodes targeting the specified product type.

          Returns DeviceCodes of all product types if empty.'
        schema:
          $ref: '#/components/schemas/ProductType'
        in: query
        required: false
      - name: status
        description: 'If specified, returns DeviceCodes with the specified statuses.

          Returns DeviceCodes of status `PAIRED` and `UNPAIRED` if empty.'
        schema:
          $ref: '#/components/schemas/DeviceCodeStatus'
        in: query
        required: false
      responses:
        '200':
          description: Success
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ListDeviceCodesResponse'
      x-endpoint-errors:
      - error-code: INVALID_CURSOR
      - error-code: BAD_REQUEST
    post:
      tags:
      - Devices
      summary: Square Create Device Code
      operationId: CreateDeviceCode
      x-microcks-operation:
        delay: 0
        dispatcher: FALLBACK
      description: 'Creates a DeviceCode that can be used to login to a Square Terminal device to enter the connected

        terminal mode.'
      x-release-status: PUBLIC
      security:
      - oauth2:
        - DEVICE_CREDENTIAL_MANAGEMENT
      parameters: []
      requestBody:
        required: true
        description: 'An object containing the fields to POST for the request.


          See the corresponding object definition for field details.'
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/CreateDeviceCodeRequest'
      responses:
        '200':
          description: Success
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/CreateDeviceCodeResponse'
      x-endpoint-errors:
      - error-code: BAD_REQUEST
      - error-code: IDEMPOTENCY_KEY_REUSED
      - error-code: INVALID_VALUE
      - error-code: UNAUTHORIZED
  /v2/devices/codes/{id}:
    get:
      tags:
      - Devices
      summary: Square Get Device Code
      operationId: GetDeviceCode
      x-microcks-operation:
        delay: 0
        dispatcher: FALLBACK
      description: Retrieves DeviceCode with the associated ID.
      x-release-status: PUBLIC
      security:
      - oauth2:
        - DEVICE_CREDENTIAL_MANAGEMENT
      parameters:
      - name: id
        description: The unique identifier for the device code.
        schema:
          type: string
        in: path
        required: true
      responses:
        '200':
          description: Success
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/GetDeviceCodeResponse'
      x-endpoint-errors:
      - error-code: BAD_REQUEST
      - error-code: NOT_FOUND
      - error-code: UNAUTHORIZED
  /v2/devices/{device_id}:
    get:
      tags:
      - Devices
      summary: Square Get Device
      operationId: GetDevice
      x-microcks-operation:
        delay: 0
        dispatcher: FALLBACK
      description: Retrieves Device with the associated `device_id`.
      x-release-status: BETA
      security:
      - oauth2:
        - DEVICES_READ
      parameters:
      - name: device_id
        description: The unique ID for the desired `Device`.
        schema:
          type: string
        in: path
        required: true
      responses:
        '200':
          description: Success
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/GetDeviceResponse'
      x-endpoint-errors:
      - error-code: BAD_REQUEST
      - error-code: NOT_FOUND
components:
  schemas:
    DeviceComponentDetailsBatteryDetails:
      type: object
      x-release-status: BETA
      properties:
        visible_percent:
          type:
          - integer
          - 'null'
          description: The battery charge percentage as displayed on the device.
        external_power:
          $ref: '#/components/schemas/DeviceComponentDetailsExternalPower'
          description: 'The status of external_power.

            See [ExternalPower](#type-externalpower) for possible values'
    DeviceCode:
      type: object
      x-release-status: PUBLIC
      required:
      - product_type
      properties:
        id:
          type: string
          description: The unique id for this device code.
          readOnly: true
        name:
          type:
          - string
          - 'null'
          description: An optional user-defined name for the device code.
          maxLength: 128
        code:
          type: string
          description: The unique code that can be used to login.
          readOnly: true
        device_id:
          type: string
          description: The unique id of the device that used this code. Populated when the device is paired up.
          readOnly: true
        product_type:
          $ref: '#/components/schemas/ProductType'
          description: The targeting product type of the device code.
        location_id:
          type:
          - string
          - 'null'
          description: The location assigned to this code.
          maxLength: 50
        status:
          $ref: '#/components/schemas/DeviceCodeStatus'
          description: 'The pairing status of the device code.

            See [DeviceCodeStatus](#type-devicecodestatus) for possible values'
          readOnly: true
        pair_by:
          type: string
          description: When this DeviceCode will expire and no longer login. Timestamp in RFC 3339 format.
          readOnly: true
        created_at:
          type: string
          description: When this DeviceCode was created. Timestamp in RFC 3339 format.
          readOnly: true
        status_changed_at:
          type: string
          description: When this DeviceCode's status was last changed. Timestamp in RFC 3339 format.
          readOnly: true
        paired_at:
          type: string
          description: When this DeviceCode was paired. Timestamp in RFC 3339 format.
          readOnly: true
    ComponentComponentType:
      type: string
      enum:
      - APPLICATION
      - CARD_READER
      - BATTERY
      - WIFI
      - ETHERNET
      - PRINTER
      x-enum-elements:
      - name: APPLICATION
        description: ''
      - name: CARD_READER
        description: ''
      - name: BATTERY
        description: ''
      - name: WIFI
        description: ''
      - name: ETHERNET
        description: ''
      - name: PRINTER
        description: ''
      description: An enum for ComponentType.
      x-release-status: BETA
    DeviceAttributes:
      type: object
      x-release-status: BETA
      required:
      - type
      - manufacturer
      properties:
        type:
          $ref: '#/components/schemas/DeviceAttributesDeviceType'
          description: 'The device type.

            See [DeviceType](#type-devicetype) for possible values'
        manufacturer:
          type: string
          description: The maker of the device.
        model:
          type:
          - string
          - 'null'
          description: The specific model of the device.
        name:
          type:
          - string
          - 'null'
          description: A seller-specified name for the device.
        manufacturers_id:
          type:
          - string
          - 'null'
          description: 'The manufacturer-supplied identifier for the device (where available). In many cases,

            this identifier will be a serial number.'
        updated_at:
          type: string
          description: 'The RFC 3339-formatted value of the most recent update to the device information.

            (Could represent any field update on the device.)'
        version:
          type: string
          description: The current version of software installed on the device.
        merchant_token:
          type:
          - string
          - 'null'
          description: The merchant_token identifying the merchant controlling the device.
    GetDeviceResponse:
      type: object
      x-release-status: BETA
      properties:
        errors:
          type: array
          items:
            $ref: '#/components/schemas/Error'
          description: Information about errors encountered during the request.
        device:
          $ref: '#/components/schemas/Device'
          description: The requested `Device`.
      example:
        device:
          attributes:
            manufacturer: Square
            manufacturers_id: 995CS397A6475287
            merchant_token: MLCHXZCBWFGDW
            model: T2
            name: Square Terminal 995
            type: TERMINAL
            updated_at: '2023-09-29T13:12:22.365049321Z'
            version: 5.41.0085
          components:
          - application_details:
              application_type: TERMINAL_API
              session_location: LMN2K7S3RTOU3
              version: '6.25'
            type: APPLICATION
          - card_reader_details:
              version: 3.53.70
            type: CARD_READER
          - battery_details:
              external_power: AVAILABLE_CHARGING
              visible_percent: 5
            type: BATTERY
          - type: WIFI
            wifi_details:
              active: true
              ip_address_v4: 10.0.0.7
              secure_connection: WPA/WPA2 PSK
              signal_strength:
                value: 2
              ssid: Staff Network
          - ethernet_details:
              active: false
            type: ETHERNET
          id: device:995CS397A6475287
          status:
            category: AVAILABLE
    CreateDeviceCodeResponse:
      type: object
      x-release-status: PUBLIC
      properties:
        errors:
          type: array
          items:
            $ref: '#/components/schemas/Error'
          description: Any errors that occurred during the request.
        device_code:
          $ref: '#/components/schemas/DeviceCode'
          description: The created DeviceCode object containing the device code string.
      example:
        device_code:
          code: EBCARJ
          created_at: '2020-02-06T18:44:33.000Z'
          id: B3Z6NAMYQSMTM
          location_id: B5E4484SHHNYH
          name: Counter 1
          pair_by: '2020-02-06T18:49:33.000Z'
          product_type: TERMINAL_API
          status: UNPAIRED
          status_changed_at: '2020-02-06T18:44:33.000Z'
    DeviceStatusCategory:
      type: string
      enum:
      - AVAILABLE
      - NEEDS_ATTENTION
      - OFFLINE
      x-enum-elements:
      - name: AVAILABLE
        description: ''
      - name: NEEDS_ATTENTION
        description: ''
      - name: OFFLINE
        description: ''
      x-release-status: BETA
    Component:
      type: object
      description: The wrapper object for the component entries of a given component type.
      x-release-status: BETA
      required:
      - type
      properties:
        type:
          $ref: '#/components/schemas/ComponentComponentType'
          description: 'The type of this component. Each component type has expected properties expressed

            in a structured format within its corresponding `*_details` field.

            See [ComponentType](#type-componenttype) for possible values'
        application_details:
          $ref: '#/components/schemas/DeviceComponentDetailsApplicationDetails'
          description: Structured data for an `Application`, set for Components of type `APPLICATION`.
        card_reader_details:
          $ref: '#/components/schemas/DeviceComponentDetailsCardReaderDetails'
          description: Structured data for a `CardReader`, set for Components of type `CARD_READER`.
        battery_details:
          $ref: '#/components/schemas/DeviceComponentDetailsBatteryDetails'
          description: Structured data for a `Battery`, set for Components of type `BATTERY`.
        wifi_details:
          $ref: '#/components/schemas/DeviceComponentDetailsWiFiDetails'
          description: Structured data for a `WiFi` interface, set for Components of type `WIFI`.
        ethernet_details:
          $ref: '#/components/schemas/DeviceComponentDetailsEthernetDetails'
          description: Structured data for an `Ethernet` interface, set for Components of type `ETHERNET`.
    ListDevicesResponse:
      type: object
      x-release-status: BETA
      properties:
        errors:
          type: array
          items:
            $ref: '#/components/schemas/Error'
          description: Information about errors that occurred during the request.
        devices:
          type: array
          items:
            $ref: '#/components/schemas/Device'
          description: The requested list of `Device` objects.
        cursor:
          type: string
          description: 'The pagination cursor to be used in a subsequent request. If empty,

            this is the final response.

            See [Pagination](https://developer.squareup.com/docs/build-basics/common-api-patterns/pagination) for more information.'
      example:
        cursor: GcXjlV2iaizH7R0fMT6wUDbw6l4otigjzx8XOOspUKHo9EPLRByM
        devices:
        - attributes:
            manufacturer: Square
            manufacturers_id: 995CS397A6475287
            merchant_token: MLCHNZCBWFDZB
            model: T2
            name: Square Terminal 995
            type: TERMINAL
            updated_at: '2023-09-29T13:04:56.335762883Z'
            version: 5.41.0085
          components:
          - application_details:
              application_type: TERMINAL_API
              session_location: LMN2K7S3RTOU3
              version: '6.25'
            type: APPLICATION
          - card_reader_details:
              version: 3.53.70
            type: CARD_READER
          - battery_details:
              external_power: AVAILABLE_CHARGING
              visible_percent: 5
            type: BATTERY
          - type: WIFI
            wifi_details:
              active: true
              ip_address_v4: 10.0.0.7
              secure_connection: WPA/WPA2 PSK
              signal_strength:
                value: 2
              ssid: Staff Network
          - ethernet_details:
              active: false
            type: ETHERNET
          id: device:995CS397A6475287
          status:
            category: AVAILABLE
        - attributes:
            manufacturer: Square
            manufacturers_id: 995CS234B5493559
            merchant_token: MLCHXZCBWFGDW
            model: T2
            name: Square Terminal 995
            type: TERMINAL
            updated_at: '2023-09-29T12:39:56.335742073Z'
            version: 5.41.0085
          components:
          - application_details:
              application_type: TERMINAL_API
              session_location: LMN2K7S3RTOU3
              version: '6.25'
            type: APPLICATION
          - card_reader_details:
              version: 3.53.70
            type: CARD_READER
          - battery_details:
              external_power: AVAILABLE_CHARGING
              visible_percent: 24
            type: BATTERY
          - type: WIFI
            wifi_details:
              active: true
              ip_address_v4: 10.0.0.7
              secure_connection: WPA/WPA2 PSK
              signal_strength:
                value: 2
              ssid: Staff Network
          - ethernet_details:
              active: false
            type: ETHERNET
          id: device:995CS234B5493559
          status:
            category: NEEDS_ATTENTION
    DeviceComponentDetailsExternalPower:
      type: string
      enum:
      - AVAILABLE_CHARGING
      - AVAILABLE_NOT_IN_USE
      - UNAVAILABLE
      - AVAILABLE_INSUFFICIENT
      x-enum-elements:
      - name: AVAILABLE_CHARGING
        description: Plugged in and charging.
      - name: AVAILABLE_NOT_IN_USE
        description: Fully charged.
      - name: UNAVAILABLE
        description: On battery power.
      - name: AVAILABLE_INSUFFICIENT
        description: Not providing enough power for the device.
      description: An enum for ExternalPower.
      x-release-status: BETA
    DeviceStatus:
      type: object
      x-release-status: BETA
      properties:
        category:
          $ref: '#/components/schemas/DeviceStatusCategory'
          description: '

            See [Category](#type-category) for possible values'
    DeviceCodeStatus:
      type: string
      enum:
      - UNKNOWN
      - UNPAIRED
      - PAIRED
      - EXPIRED
      x-enum-elements:
      - name: UNKNOWN
        description: The status cannot be determined or does not exist.
      - name: UNPAIRED
        description: The device code is just created and unpaired.
      - name: PAIRED
        description: The device code has been signed in and paired to a device.
      - name: EXPIRED
        description: The device code was unpaired and expired before it was paired.
      description: DeviceCode.Status enum.
      x-release-status: PUBLIC
    ProductType:
      type: string
      enum:
      - TERMINAL_API
      x-enum-elements:
      - name: TERMINAL_API
        description: ''
      x-release-status: PUBLIC
    ErrorCategory:
      type: string
      enum:
      - API_ERROR
      - AUTHENTICATION_ERROR
      - INVALID_REQUEST_ERROR
      - RATE_LIMIT_ERROR
      - PAYMENT_METHOD_ERROR
      - REFUND_ERROR
      - MERCHANT_SUBSCRIPTION_ERROR
      - EXTERNAL_VENDOR_ERROR
      x-enum-elements:
      - name: API_ERROR
        description: An error occurred with the Connect API itself.
      - name: AUTHENTICATION_ERROR
        description: 'An authentication error occurred. Most commonly, the request had

          a missing, malformed, or otherwise invalid `Authorization` header.'
      - name: INVALID_REQUEST_ERROR
        description: 'The request was invalid. Most commonly, a required parameter was

          missing, or a provided parameter had an invalid value.'
      - name: RATE_LIMIT_ERROR
        description: 'Your application reached the Square API rate limit. You might receive this error if your application sends a high number of requests

          to Square APIs in a short period of time.


          Your application should monitor responses for `429 RATE_LIMITED` errors and use a retry mechanism with an [exponential backoff](https://en.wikipedia.org/wiki/Exponential_backoff)

          schedule to resend the requests at an increasingly slower rate. It is also a good practice to use a randomized delay (jitter) in your retry schedule.'
      - name: PAYMENT_METHOD_ERROR
        description: 'An error occurred while processing a payment method. Most commonly,

          the details of the payment method were invalid (such as a card''s CVV

          or expiration date).'
      - name: REFUND_ERROR
        description: An error occurred while attempting to process a refund.
      - name: MERCHANT_SUBSCRIPTION_ERROR
        description: An error occurred when checking a merchant subscription status
      - name: EXTERNAL_VENDOR_ERROR
        description: An error that is returned from an external vendor's API
      description: 'Indicates which high-level category of error has occurred during a

        request to the Connect API.'
      x-release-status: PUBLIC
    DeviceComponentDetailsApplicationDetails:
      type: object
      x-release-status: BETA
      properties:
        application_type:
          $ref: '#/components/schemas/ApplicationType'
          description: 'The type of application.

            See [ApplicationType](#type-applicationtype) for possible values'
        version:
          type: string
          description: The version of the application.
        session_location:
          type:
          - string
          - 'null'
          description: The location_id of the session for the application.
        device_code_id:
          type:
          - string
          - 'null'
          description: The id of the device code that was used to log in to the device.
    SortOrder:
      type: string
      enum:
      - DESC
      - ASC
      x-enum-elements:
      - name: DESC
        description: The results are returned in descending (e.g., newest-first or Z-A) order.
      - name: ASC
        description: The results are returned in ascending (e.g., oldest-first or A-Z) order.
      description: The order (e.g., chronological or alphabetical) in which results from a request are returned.
      x-release-status: PUBLIC
    DeviceComponentDetailsWiFiDetails:
      type: object
      x-release-status: BETA
      properties:
        active:
          type:
          - boolean
          - 'null'
          description: A boolean to represent whether the WiFI interface is currently active.
        ssid:
          type:
          - string
          - 'null'
          description: The name of the connected WIFI network.
        ip_address_v4:
          type:
          - string
          - 'null'
          description: The string representation of the device’s IPv4 address.
        secure_connection:
          type:
          - string
          - 'null'
          description: 'The security protocol for a secure connection (e.g. WPA2). None provided if the connection

            is unsecured.'
        signal_strength:
          $ref: '#/components/schemas/DeviceComponentDetailsMeasurement'
          description: A representation of signal strength of the WIFI network connection.
    GetDeviceCodeResponse:
      type: object
      x-release-status: PUBLIC
      properties:
        errors:
          type: array
          items:
            $ref: '#/components/schemas/Error'
          description: Any errors that occurred during the request.
        device_code:
          $ref: '#/components/schemas/DeviceCode'
          description: The queried DeviceCode.
      example:
        device_code:
          code: EBCARJ
          created_at: '2020-02-06T18:44:33.000Z'
          device_id: 907CS13101300122
          id: B3Z6NAMYQSMTM
          location_id: B5E4484SHHNYH
          name: Counter 1
          pair_by: '2020-02-06T18:49:33.000Z'
          product_type: TERMINAL_API
          status: PAIRED
          status_changed_at: '2020-02-06T18:47:28.000Z'
    CreateDeviceCodeRequest:
      type: object
      x-release-status: PUBLIC
      required:
      - idempotency_key
      - device_code
      properties:
        idempotency_key:
          type: string
          description: 'A unique string that identifies this CreateDeviceCode request. Keys can

            be any valid string but must be unique for every CreateDeviceCode request.


            See [Idempotency keys](https://developer.squareup.com/docs/build-basics/common-api-patterns/idempotency) for more information.'
          minLength: 1
          maxLength: 128
        device_code:
          $ref: '#/components/schemas/DeviceCode'
          description: The device code to create.
      example:
        device_code:
          location_id: B5E4484SHHNYH
          name: Counter 1
          product_type: TERMINAL_API
        idempotency_key: 01bb00a6-0c86-4770-94ed-f5fca973cd56
    Error:
      type: object
      description: 'Represents an error encountered during a request to the Connect API.


        See [Handling errors](https://developer.squareup.com/docs/build-basics/handling-errors) for more information.'
      x-release-status: PUBLIC
      required:
      - category
      - code
      properties:
        category:
          $ref: '#/components/schemas/ErrorCategory'
          description: 'The high-level category for the error.

            See [ErrorCategory](#type-errorcategory) for possible values'
        code:
          $ref: '#/components/schemas/ErrorCode'
          description: 'The specific code of the error.

            See [ErrorCode](#type-errorcode) for possible values'
        detail:
          type: string
          description: A human-readable description of the error for debugging purposes.
        field:
          type: string
          description: 'The name of the field provided in the original request (if any) that

            the error pertains to.'
    ErrorCode:
      type: string
      enum:
      - INTERNAL_SERVER_ERROR
      - UNAUTHORIZED
      - ACCESS_TOKEN_EXPIRED
      - ACCESS_TOKEN_REVOKED
      - CLIENT_DISABLED
      - FORBIDDEN
      - INSUFFICIENT_SCOPES
      - APPLICATION_DISABLED
      - V1_APPLICATION
      - V1_ACCESS_TOKEN
      - CARD_PROCESSING_NOT_ENABLED
      - MERCHANT_SUBSCRIPTION_NOT_FOUND
      - BAD_REQUEST
      - MISSING_REQUIRED_PARAMETER
      - INCORRECT_TYPE
      - INVALID_TIME
      - INVALID_TIME_RANGE
      - INVALID_VALUE
      - INVALID_CURSOR
      - UNKNOWN_QUERY_PARAMETER
      - CONFLICTING_PARAMETERS
      - EXPECTED_JSON_BODY
      - INVALID_SORT_ORDER
      - VALUE_REGEX_MISMATCH
      - VALUE_TOO_SHORT
      - VALUE_TOO_LONG
      - VALUE_TOO_LOW
      - VALUE_TOO_HIGH
      - VALUE_EMPTY
      - ARRAY_LENGTH_TOO_LONG
      - ARRAY_LENGTH_TOO_SHORT
      - ARRAY_EMPTY
      - EXPECTED_BOOLEAN
      - EXPECTED_INTEGER
      - EXPECTED_FLOAT
      - EXPECTED_STRING
      - EXPECTED_OBJECT
      - EXPECTED_ARRAY
      - EXPECTED_MAP
      - EXPECTED_BASE64_ENCODED_BYTE_ARRAY
      - INVALID_ARRAY_VALUE
      - INVALID_ENUM_VALUE
      - INVALID_CONTENT_TYPE
      - INVALID_FORM_VALUE
      - CUSTOMER_NOT_FOUND
      - ONE_INSTRUMENT_EXPECTED
      - NO_FIELDS_SET
      - TOO_MANY_MAP_ENTRIES
      - MAP_KEY_LENGTH_TOO_SHORT
      - MAP_KEY_LENGTH_TOO_LONG
      - CUSTOMER_MISSING_NAME
      - CUSTOMER_MISSING_EMAIL
      - INVALID_PAUSE_LENGTH
      - INVALID_DATE
      - UNSUPPORTED_COUNTRY
      - UNSUPPORTED_CURRENCY
      - APPLE_TTP_PIN_TOKEN
      - CARD_EXPIRED
      - INVALID_EXPIRATION
      - INVALID_EXPIRATION_YEAR
      - INVALID_EXPIRATION_DATE
      - UNSUPPORTED_CARD_BRAND
      - UNSUPPORTED_ENTRY_METHOD
      - INVALID_ENCRYPTED_CARD
      - INVALID_CARD
      - PAYMENT_AMOUNT_MISMATCH
      - GENERIC_DECLINE
      - CVV_FAILURE
      - ADDRESS_VERIFICATION_FAILURE
      - INVALID_ACCOUNT
      - CURRENCY_MISMATCH
      - INSUFFICIENT_FUNDS
      - INSUFFICIENT_PERMISSIONS
      - CARDHOLDER_INSUFFICIENT_PERMISSIONS
      - INVALID_LOCATION
      - TRANSACTION_LIMIT
      - VOICE_FAILURE
      - PAN_FAILURE
      - EXPIRATION_FAILURE
      - CARD_NOT_SUPPORTED
      - INVALID_PIN
      - MISSING_PIN
      - MISSING_ACCOUNT_TYPE
      - INVALID_POSTAL_CODE
      - INVALID_FEES
      - MANUALLY_ENTERED_PAYMENT_NOT_SUPPORTED
      - PAYMENT_LIMIT_EXCEEDED
      - GIFT_CARD_AVAILABLE_AMOUNT
      - ACCOUNT_UNUSABLE
      - BUYER_REFUSED_PAYMENT
      - DELAYED_TRANSACTION_EXPIRED
      - DELAYED_TRANSACTION_CANCELED
      - DELAYED_TRANSACTION_CAPTURED
      - DELAYED_TRANSACTION_FAILED
      - CARD_TOKEN_EXPIRED
      - CARD_TOKEN_USED
      - AMOUNT_TOO_HIGH
      - UNSUPPORTED_INSTRUMENT_TYPE
      - REFUND_AM

# --- truncated at 32 KB (75 KB total) ---
# Full source: https://raw.githubusercontent.com/api-evangelist/square/refs/heads/main/openapi/square-devices-api-openapi.yml