Skip to main content

Documentation Index

Fetch the complete documentation index at: https://dev.1st.app/llms.txt

Use this file to discover all available pages before exploring further.

HTTP status: 400

Message

This cursor was issued for a different device. Start a new pagination at the new device’s first page (drop ?cursor=...).

Common cause

The cursor returned by GET /v1/devices/{device_id}/assignments is bound to the specific device it came from. You can’t reuse it when listing assignments on a different device. This usually happens when:
  • Your code stored “the cursor” globally and reused it as it iterated over multiple devices.
  • You’re calling the assignments endpoint in a loop and forgot to clear the cursor between devices.

Fix

Start each device’s pagination from scratch — pass no cursor on the first call, then loop with the value from next_cursor until it comes back as null:
# First page for device A
curl -H "Authorization: Bearer $ST_API_KEY" \
  "https://api.1st.app/v1/devices/<device_a>/assignments"
# response includes "next_cursor": "eyJ0ZWFt..."

# Next page for device A — pass the cursor back
curl -H "Authorization: Bearer $ST_API_KEY" \
  "https://api.1st.app/v1/devices/<device_a>/assignments?cursor=eyJ0ZWFt..."

# When you move on to device B, drop the cursor
curl -H "Authorization: Bearer $ST_API_KEY" \
  "https://api.1st.app/v1/devices/<device_b>/assignments"
For a worked example, see Paging through long lists.