Devices by Email API

Retrieve all registered devices for a user by their email address

Devices

Devices by Email API

Look up devices using a user's email address. Get the same comprehensive device information without needing the user ID.

Email Lookup

Search by email address.

Device List

All registered devices.

Convenient

No user ID required.


Endpoint Overview

QUERY/graphql

Retrieve all devices associated with a user by their email address, including connection status and device details.

Authentication:Bearer Token
Required scopes:adminreseller

Request Parameters

emailString!Required

The email address of the user to retrieve devices for.


GraphQL Query

query getDevicesByEmail($email: String!) {
  getDevicesByEmail(email: $email) {
    deviceAppType
    deviceOsType
    appVersion
    lastConnectionStartTime
    lastConnectionStopTime
    isConnected
    lastSessionId
    isDeactivated
    lastConnectedServerId
    lastConnectedServerCountry
    lastConnectedServerCity
  }
}

Variables:

{
  "email": "user@example.com"
}

HTTP Request:

curl -X POST https://api.orbnet.com/graphql \
  -H "Content-Type: application/json" \
  -H "Authorization: Bearer YOUR_TOKEN" \
  -d '{
    "query": "query getDevicesByEmail($email: String!) { getDevicesByEmail(email: $email) { deviceAppType deviceOsType appVersion isConnected lastConnectedServerCountry } }",
    "variables": {
      "email": "user@example.com"
    }
  }'

Response

200Devices Retrieved Successfully
{
  "data": {
    "getDevicesByEmail": [
      {
        "deviceAppType": "iOS",
        "deviceOsType": "iOS 17.2",
        "appVersion": "3.2.1",
        "lastConnectionStartTime": "2024-01-15T10:30:00Z",
        "lastConnectionStopTime": null,
        "isConnected": true,
        "lastSessionId": "sess_abc123",
        "isDeactivated": false,
        "lastConnectedServerId": "srv_001",
        "lastConnectedServerCountry": "Netherlands",
        "lastConnectedServerCity": "Amsterdam"
      },
      {
        "deviceAppType": "Windows",
        "deviceOsType": "Windows 11",
        "appVersion": "3.2.0",
        "lastConnectionStartTime": "2024-01-13T09:00:00Z",
        "lastConnectionStopTime": "2024-01-13T17:30:00Z",
        "isConnected": false,
        "lastSessionId": "sess_xyz789",
        "isDeactivated": false,
        "lastConnectedServerId": "srv_004",
        "lastConnectedServerCountry": "United Kingdom",
        "lastConnectedServerCity": "London"
      }
    ]
  }
}
404User Not Found
{
  "errors": [
    {
      "message": "No user found with this email address",
      "path": ["getDevicesByEmail"],
      "extensions": {
        "code": "USER_NOT_FOUND"
      }
    }
  ],
  "data": null
}

Response Fields

deviceAppTypeString!

Platform type (iOS, Android, macOS, Windows, Linux).

deviceOsTypeString!

Operating system version.

appVersionString!

Version of the VPN application installed.

isConnectedBoolean!

Whether the device is currently connected.

isDeactivatedBoolean!

Whether the device has been deactivated.

lastConnectionStartTimeDateTime

Most recent connection start time.

lastConnectionStopTimeDateTime

When the last connection ended.

lastSessionIdString

Session ID of the last connection.

lastConnectedServerIdString

ID of the last connected server.

lastConnectedServerCountryString

Country of the last server.

lastConnectedServerCityString

City of the last server.


Use Cases

Support Tickets

Look up devices when user provides email.

Quick Search

Find devices without user ID lookup.

User Verification

Confirm device ownership.

Troubleshooting

Diagnose connection issues by email.



Email Format

The email address is case-insensitive. Both "User@Example.com" and "user@example.com" will return the same results.

Need All Active Devices?

View all currently active devices across your entire platform.

Get Active Devices