> This is Payabli documentation. For a complete page index, fetch https://docs.payabli.com/llms.txt — append .md to any page URL for lightweight markdown. For section-level indexes, query parameters, and other AI-optimized access methods, see https://docs.payabli.com/ai-agents.md

# List devices by organization

GET https://api-sandbox.payabli.com/api/Query/devices/org/{orgId}

Returns a list of cloud devices for a single organization. Use filters to limit results. Include the `exportFormat` query parameter to return the results as a file instead of a JSON response.

Reference: https://docs.payabli.com/developers/api-reference/get-list-of-devices-for-an-organization

## Authentication

- `Authorization` header (bearer token, required)
- `requestToken` header (required) — Long-lived API token sent in the `requestToken` header. See [API token authentication](/developers/api-tokens).

## Servers

- `https://api-sandbox.payabli.com/api` (Sandbox, default)
- `https://api.payabli.com/api` (Production)

## Request

### Path parameters

- `orgId` (integer, required) — The numeric identifier for organization, assigned by Payabli.

### Query parameters

- `exportFormat` (enum, optional) — Export format for file downloads. When specified, returns data as a file instead of JSON.
  - Allowed values: `csv`, `xlsx`
- `fromRecord` (integer, optional, default: 0) — The number of records to skip before starting to collect the result set.
- `limitRecord` (integer, optional, default: 20) — Max number of records to return for the query. Use `0` or negative value to return all records.
- `parameters` (map from string to string, optional) — Collection of field names, conditions, and values used to filter the query. **You must remove `parameters=` from the request before you send it, otherwise Payabli will ignore the filters.** Because of a technical limitation, you can't make a request that includes filters from the API console on this page. The response won't be filtered. Instead, copy the request, remove `parameters=` and run the request in a different client, for example: \--url [https://api-sandbox.payabli.com/api/Query/devices/org/236?parameters=status=1\&limitRecord=20](https://api-sandbox.payabli.com/api/Query/devices/org/236?parameters=status=1\&limitRecord=20) should become: \--url [https://api-sandbox.payabli.com/api/Query/devices/org/236?status=1\&limitRecord=20](https://api-sandbox.payabli.com/api/Query/devices/org/236?status=1\&limitRecord=20) See [Filters and Conditions Reference](/developers/developer-guides/pay-ops-reporting-engine-overview#filters-and-conditions-reference) for more information. **Accepted field names:** * `deviceId` (eq, ne, ct, nct) * `serialNumber` (eq, ne, ct, nct) * `friendlyName` (eq, ne, ct, nct) * `description` (eq, ne, ct, nct) * `model` (eq, ne, ct, nct) * `make` (eq, ne, ct, nct) * `macAddress` (eq, ne, ct, nct) * `registrationCode` (eq, ne, ct, nct) * `status` (eq, ne, in, nin) * `deviceType` (eq, ne, in, nin) * `deviceOs` (eq, ne, in, nin) * `activationAttempts` (eq, ne, gt, ge, lt, le) * `createdDate` (gt, ge, lt, le, eq, ne) * `updatedDate` (gt, ge, lt, le, eq, ne) * `lastHealthCheck` (gt, ge, lt, le, eq, ne) * `activationExpiry` (gt, ge, lt, le, eq, ne). This filter corresponds to the `activationCodeExpiry` response field. * `paypointId` (eq, ne) * `paypointDba` (eq, ne, ct, nct) * `paypointLegal` (eq, ne, ct, nct) * `paypointEntry` (eq, ne, ct, nct) * `externalPaypointId` (eq, ne, ct, nct) * `parentOrgId` (eq, ne) * `parentOrgName` (eq, ne, ct, nct) * `paypointLogo` (eq, ne, ct, nct) * `parentOrgLogo` (eq, ne, ct, nct) * `transactionCount` (eq, ne, gt, ge, lt, le) * `volumeProcessed` (eq, ne, gt, ge, lt, le) **Accepted comparison operators:** * `eq` or empty => equal * `gt` => greater than * `ge` => greater or equal * `lt` => less than * `le` => less or equal * `ne` => not equal * `ct` => contains * `nct` => not contains * `in` => inside array * `nin` => not inside array
- `sortBy` (string, optional) — The field name to use for sorting results. Use `desc(field_name)` to sort descending by `field_name`, and use `asc(field_name)` to sort ascending by `field_name`.

## Response

### 200

Success

- `Summary` (object, required)
  - `pageIdentifier` (string, optional) — Auxiliary validation used internally by payment pages and components.
  - `pageSize` (integer, optional) — Number of records on each response page.
  - `totalAmount` (double, optional) — Total amount for the records.
  - `totalNetAmount` (double, optional) — Total net amount for the records.
  - `totalPages` (integer, optional) — Total number of records in response.
  - `totalRecords` (integer, optional) — Total number of records in response.
- `Records` (list of object, required)
  - `deviceId` (string, required, nullable) — Unique identifier for the cloud device.
  - `idCloud` (integer, required, nullable) — Internal cloud device record ID.
  - `description` (string, required, nullable) — Description of the device.
  - `serialNumber` (string, required, nullable) — Serial number of the device.
  - `friendlyName` (string, required, nullable) — Human-readable name for the device.
  - `make` (string, required, nullable) — Manufacturer of the device.
  - `model` (string, required, nullable) — Model name of the device.
  - `deviceType` (integer, required, nullable) — Type of device.
  - `deviceStatus` (integer, required, nullable) — Current status of the device.
  - `deviceOs` (integer, required, nullable) — Operating system of the device.
  - `macAddress` (string, required, nullable) — MAC address of the device.
  - `lastHealthCheck` (string, required, nullable) — Timestamp of the last health check from the device.
  - `registrationCode` (string, required, nullable) — Registration code used to activate the device.
  - `activationAttempts` (integer, required, nullable) — Number of activation attempts for the device.
  - `activationCodeExpiry` (string, required, nullable) — Expiration timestamp for the device activation code.
  - `createdAt` (string, required, nullable) — Timestamp when the device record was created.
  - `updatedAt` (string, required, nullable) — Timestamp when the device record was last updated.
  - `paypointId` (integer, required, nullable) — Numeric identifier for the paypoint.
  - `paypointDba` (string, required, nullable) — DBA name for the paypoint.
  - `paypointLegal` (string, required, nullable) — Legal name for the paypoint.
  - `paypointEntry` (string, required, nullable) — Entry identifier for the paypoint.
  - `paypointLogo` (string, required, nullable) — URL of the paypoint's logo, when available.
  - `externalPaypointId` (string, required, nullable) — External identifier for the paypoint.
  - `parentOrgId` (integer, required, nullable) — Numeric identifier for the parent organization.
  - `parentOrgName` (string, required, nullable) — Name of the parent organization.
  - `parentOrgLogo` (string, required, nullable) — URL of the parent organization's logo, when available.
  - `transactionCount` (integer, required) — Total number of transactions processed by this device.
  - `volumeProcessed` (double, required) — Total volume processed by this device, as the sum of net transaction amounts.

## Examples

**Response**

```json
{
  "Summary": {
    "pageIdentifier": null,
    "pageSize": 20,
    "totalAmount": 0,
    "totalNetAmount": 0,
    "totalPages": 2,
    "totalRecords": 28
  },
  "Records": [
    {
      "deviceId": "499585-389fj484-3jcj8hj3",
      "idCloud": 142,
      "description": "Front Counter Terminal",
      "serialNumber": "SN-90210-XR",
      "friendlyName": "Front Counter",
      "make": null,
      "model": null,
      "deviceType": 1,
      "deviceStatus": 1,
      "deviceOs": null,
      "macAddress": "1A2B3C4D5E6F",
      "lastHealthCheck": "2026-04-09T14:49:42Z",
      "registrationCode": "REG-A1B2C3D4",
      "activationAttempts": 0,
      "activationCodeExpiry": "2026-04-09T14:49:42Z",
      "createdAt": "2026-04-09T01:14:37Z",
      "updatedAt": "2026-04-09T14:49:42Z",
      "paypointId": 3040,
      "paypointDba": "Gruzya Adventure Outfitters",
      "paypointLegal": "Gruzya Adventure Outfitters, LLC",
      "paypointEntry": "8cfec329267",
      "paypointLogo": "https://payabli-public-objects.s3.amazonaws.com/pe3040.png",
      "externalPaypointId": "GRUZYA-01",
      "parentOrgId": 100,
      "parentOrgName": "Mountain View Services",
      "transactionCount": 342,
      "volumeProcessed": 28650.75
    }
  ]
}
```

**SDK Code**

```typescript
import { PayabliClient } from "@payabli/sdk-node";

async function main() {
    const client = new PayabliClient();
    await client.query.listDevicesOrg(123, {
        fromRecord: 0,
        limitRecord: 20,
        sortBy: "desc(createdAt)",
    });
}
main();

```

```python
from payabli import payabli

client = payabli()

client.query.list_devices_org(
    org_id=123,
    from_record=0,
    limit_record=20,
    sort_by="desc(createdAt)",
)

```

```java
package com.example.usage;

import io.github.payabli.api.PayabliApiClient;
import io.github.payabli.api.resources.query.requests.ListDevicesOrgRequest;

public class Example {
    public static void main(String[] args) {
        PayabliApiClient client = PayabliApiClient
            .builder()
            .build();

        client.query().listDevicesOrg(
            123,
            ListDevicesOrgRequest
                .builder()
                .fromRecord(0)
                .limitRecord(20)
                .sortBy("desc(createdAt)")
                .build()
        );
    }
}
```

```csharp
using PayabliApi;
using System.Threading.Tasks;

public partial class Examples
{
    public async Task Example() {
        var client = new PayabliApiClient();

        await client.Query.ListDevicesOrgAsync(
            orgId: 123,
            request: new ListDevicesOrgRequest {
                FromRecord = 0,
                LimitRecord = 20,
                SortBy = "desc(createdAt)"
            }
        );
    }

}

```

```go
package example

import (
    context "context"

    payabli "github.com/payabli/sdk-go"
    client "github.com/payabli/sdk-go/client"
)

func do() {
    client := client.NewClient()
    request := &payabli.ListDevicesOrgRequest{
        FromRecord: payabli.Int(
            0,
        ),
        LimitRecord: payabli.Int(
            20,
        ),
        SortBy: payabli.String(
            "desc(createdAt)",
        ),
    }
    client.Query.ListDevicesOrg(
        context.TODO(),
        123,
        request,
    )
}

```

```php
<?php

namespace Example;

use Payabli\PayabliClient;
use Payabli\Query\Requests\ListDevicesOrgRequest;

$client = new PayabliClient();
$client->query->listDevicesOrg(
    123,
    new ListDevicesOrgRequest([
        'fromRecord' => 0,
        'limitRecord' => 20,
        'sortBy' => 'desc(createdAt)',
    ]),
);

```

```ruby
require 'uri'
require 'net/http'

url = URI("https://api-sandbox.payabli.com/api/Query/devices/org/123?fromRecord=0&limitRecord=20&sortBy=desc%28createdAt%29")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Bearer <token>'

response = http.request(request)
puts response.read_body
```

```swift
import Foundation

let headers = ["Authorization": "Bearer <token>"]

let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Query/devices/org/123?fromRecord=0&limitRecord=20&sortBy=desc%28createdAt%29")! as URL,
                                        cachePolicy: .useProtocolCachePolicy,
                                    timeoutInterval: 10.0)
request.httpMethod = "GET"
request.allHTTPHeaderFields = headers

let session = URLSession.shared
let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in
  if (error != nil) {
    print(error as Any)
  } else {
    let httpResponse = response as? HTTPURLResponse
    print(httpResponse)
  }
})

dataTask.resume()
```