Skip to content

REST API reference

Base URL: https://pocketshare.io. Authenticate with an API key: Authorization: Bearer psk_… (create one with pocketshare login or on the website). Money is integer micro-dollars (1 USD = 1,000,000) and times are ISO 8601. Errors are {"error": "<code>"} with a stable snake_case code. The machine-readable OpenAPI 3.1 document is generated from the same schemas the API validates with (packages/contracts/openapi/v2.json in the repository).

Search rentable phones.

Visible listings, filtered by brand, minimum API level and hourly price.

Authentication: none (public).

Parameter In Type Required Notes
brand query string at most 60 characters
minApiLevel query integer ≥ 21; ≤ 100
maxHourlyRateMicros query integer ≥ 0

Response 200:

Field Type Required Notes
phones array of object yes
Response JSON Schema
{
"type": "object",
"properties": {
"phones": {
"type": "array",
"items": {
"type": "object",
"properties": {
"id": {
"type": "string",
"format": "uuid"
},
"hubId": {
"type": "string",
"format": "uuid"
},
"brand": {
"type": "string"
},
"manufacturer": {
"type": "string"
},
"model": {
"type": "string"
},
"device": {
"type": [
"string",
"null"
]
},
"buildFingerprint": {
"type": "string"
},
"androidVersion": {
"type": "string"
},
"apiLevel": {
"type": "integer",
"minimum": -9007199254740991,
"maximum": 9007199254740991
},
"abi": {
"type": "string"
},
"state": {
"type": "string",
"enum": [
"pending_review",
"available",
"rented",
"cleaning",
"quarantined",
"paused",
"offline",
"removed"
]
},
"stateReason": {
"type": [
"string",
"null"
]
},
"hasBaseline": {
"type": "boolean"
},
"online": {
"type": "boolean"
},
"listing": {
"anyOf": [
{
"type": "object",
"properties": {
"hourlyRateMicros": {
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
"downloadRateMicrosPerGb": {
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
"uploadRateMicrosPerGb": {
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
"visible": {
"type": "boolean"
}
},
"required": [
"hourlyRateMicros",
"downloadRateMicrosPerGb",
"uploadRateMicrosPerGb",
"visible"
],
"additionalProperties": false
},
{
"type": "null"
}
]
}
},
"required": [
"id",
"hubId",
"brand",
"manufacturer",
"model",
"device",
"buildFingerprint",
"androidVersion",
"apiLevel",
"abi",
"state",
"stateReason",
"hasBaseline",
"online",
"listing"
],
"additionalProperties": false
}
}
},
"required": [
"phones"
],
"additionalProperties": false
}

One phone.

Authentication: none (public).

Parameter In Type Required Notes
id path string (uuid) yes

Response 200:

Field Type Required Notes
id string (uuid) yes
hubId string (uuid) yes
brand string yes
manufacturer string yes
model string yes
device string or null yes
buildFingerprint string yes
androidVersion string yes
apiLevel integer yes ≥ -9007199254740991
abi string yes
state "pending_review", "available", "rented", "cleaning", "quarantined", "paused", "offline", "removed" yes
stateReason string or null yes
hasBaseline boolean yes
online boolean yes
listing object or null yes
Response JSON Schema
{
"type": "object",
"properties": {
"id": {
"type": "string",
"format": "uuid"
},
"hubId": {
"type": "string",
"format": "uuid"
},
"brand": {
"type": "string"
},
"manufacturer": {
"type": "string"
},
"model": {
"type": "string"
},
"device": {
"type": [
"string",
"null"
]
},
"buildFingerprint": {
"type": "string"
},
"androidVersion": {
"type": "string"
},
"apiLevel": {
"type": "integer",
"minimum": -9007199254740991,
"maximum": 9007199254740991
},
"abi": {
"type": "string"
},
"state": {
"type": "string",
"enum": [
"pending_review",
"available",
"rented",
"cleaning",
"quarantined",
"paused",
"offline",
"removed"
]
},
"stateReason": {
"type": [
"string",
"null"
]
},
"hasBaseline": {
"type": "boolean"
},
"online": {
"type": "boolean"
},
"listing": {
"anyOf": [
{
"type": "object",
"properties": {
"hourlyRateMicros": {
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
"downloadRateMicrosPerGb": {
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
"uploadRateMicrosPerGb": {
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
"visible": {
"type": "boolean"
}
},
"required": [
"hourlyRateMicros",
"downloadRateMicrosPerGb",
"uploadRateMicrosPerGb",
"visible"
],
"additionalProperties": false
},
{
"type": "null"
}
]
}
},
"required": [
"id",
"hubId",
"brand",
"manufacturer",
"model",
"device",
"buildFingerprint",
"androidVersion",
"apiLevel",
"abi",
"state",
"stateReason",
"hasBaseline",
"online",
"listing"
],
"additionalProperties": false
}

Marketplace search with availability and reliability.

Authentication: none (public).

Parameter In Type Required Notes
q query string at most 100 characters
brand query string at most 60 characters
minApiLevel query integer ≥ 21; ≤ 100
maxHourlyRateMicros query integer ≥ 0; ≤ 1000000000
availableNow query "true", "false"
minReliability query number ≥ 0; ≤ 1
sort query "price", "reliability", "newest"

Response 200:

Field Type Required Notes
phones array of object yes
facets object yes
pricing object yes
Response JSON Schema
{
"type": "object",
"properties": {
"phones": {
"type": "array",
"items": {
"type": "object",
"properties": {
"id": {
"type": "string",
"format": "uuid"
},
"brand": {
"type": "string"
},
"manufacturer": {
"type": "string"
},
"model": {
"type": "string"
},
"device": {
"type": [
"string",
"null"
]
},
"androidVersion": {
"type": "string"
},
"apiLevel": {
"type": "integer",
"minimum": -9007199254740991,
"maximum": 9007199254740991
},
"abi": {
"type": "string"
},
"buildFingerprint": {
"type": "string"
},
"hourlyRateMicros": {
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
"downloadRateMicrosPerGb": {
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
"uploadRateMicrosPerGb": {
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
"online": {
"type": "boolean"
},
"availability": {
"type": "string",
"enum": [
"available",
"in_use",
"unavailable"
]
},
"reliability": {
"type": "object",
"properties": {
"score": {
"anyOf": [
{
"type": "number",
"minimum": 0,
"maximum": 1
},
{
"type": "null"
}
]
},
"startedRentals": {
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
"interruptedRentals": {
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
"failedStarts": {
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
"windowDays": {
"type": "number",
"const": 90
}
},
"required": [
"score",
"startedRentals",
"interruptedRentals",
"failedStarts",
"windowDays"
],
"additionalProperties": false
},
"listedAt": {
"type": "string",
"format": "date-time"
}
},
"required": [
"id",
"brand",
"manufacturer",
"model",
"device",
"androidVersion",
"apiLevel",
"abi",
"buildFingerprint",
"hourlyRateMicros",
"downloadRateMicrosPerGb",
"uploadRateMicrosPerGb",
"online",
"availability",
"reliability",
"listedAt"
],
"additionalProperties": false
}
},
"facets": {
"type": "object",
"properties": {
"brands": {
"type": "array",
"items": {
"type": "string"
}
},
"androidVersions": {
"type": "array",
"items": {
"type": "object",
"properties": {
"androidVersion": {
"type": "string"
},
"apiLevel": {
"type": "integer",
"minimum": -9007199254740991,
"maximum": 9007199254740991
}
},
"required": [
"androidVersion",
"apiLevel"
],
"additionalProperties": false
}
}
},
"required": [
"brands",
"androidVersions"
],
"additionalProperties": false
},
"pricing": {
"type": "object",
"properties": {
"bandwidthRateMicrosPerGb": {
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
"minHourlyRateMicros": {
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
"maxHourlyRateMicros": {
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
}
},
"required": [
"bandwidthRateMicrosPerGb",
"minHourlyRateMicros",
"maxHourlyRateMicros"
],
"additionalProperties": false
}
},
"required": [
"phones",
"facets",
"pricing"
],
"additionalProperties": false
}

Marketplace phone detail with recent outcomes.

Authentication: none (public).

Parameter In Type Required Notes
id path string (uuid) yes

Response 200:

Field Type Required Notes
phone object yes
history array of object yes
pricing object yes
Response JSON Schema
{
"type": "object",
"properties": {
"phone": {
"type": "object",
"properties": {
"id": {
"type": "string",
"format": "uuid"
},
"brand": {
"type": "string"
},
"manufacturer": {
"type": "string"
},
"model": {
"type": "string"
},
"device": {
"type": [
"string",
"null"
]
},
"androidVersion": {
"type": "string"
},
"apiLevel": {
"type": "integer",
"minimum": -9007199254740991,
"maximum": 9007199254740991
},
"abi": {
"type": "string"
},
"buildFingerprint": {
"type": "string"
},
"hourlyRateMicros": {
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
"downloadRateMicrosPerGb": {
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
"uploadRateMicrosPerGb": {
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
"online": {
"type": "boolean"
},
"availability": {
"type": "string",
"enum": [
"available",
"in_use",
"unavailable"
]
},
"reliability": {
"type": "object",
"properties": {
"score": {
"anyOf": [
{
"type": "number",
"minimum": 0,
"maximum": 1
},
{
"type": "null"
}
]
},
"startedRentals": {
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
"interruptedRentals": {
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
"failedStarts": {
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
"windowDays": {
"type": "number",
"const": 90
}
},
"required": [
"score",
"startedRentals",
"interruptedRentals",
"failedStarts",
"windowDays"
],
"additionalProperties": false
},
"listedAt": {
"type": "string",
"format": "date-time"
}
},
"required": [
"id",
"brand",
"manufacturer",
"model",
"device",
"androidVersion",
"apiLevel",
"abi",
"buildFingerprint",
"hourlyRateMicros",
"downloadRateMicrosPerGb",
"uploadRateMicrosPerGb",
"online",
"availability",
"reliability",
"listedAt"
],
"additionalProperties": false
},
"history": {
"type": "array",
"items": {
"type": "object",
"properties": {
"day": {
"type": "string",
"format": "date",
"pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))$"
},
"outcome": {
"type": "string",
"enum": [
"completed",
"interrupted",
"failed_start"
]
},
"minutes": {
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
}
},
"required": [
"day",
"outcome",
"minutes"
],
"additionalProperties": false
}
},
"pricing": {
"type": "object",
"properties": {
"bandwidthRateMicrosPerGb": {
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
"minHourlyRateMicros": {
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
"maxHourlyRateMicros": {
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
}
},
"required": [
"bandwidthRateMicrosPerGb",
"minHourlyRateMicros",
"maxHourlyRateMicros"
],
"additionalProperties": false
}
},
"required": [
"phone",
"history",
"pricing"
],
"additionalProperties": false
}

Rent a phone.

Reserves the phone with a required spending cap and snapshots its rates. The rental becomes active when the host has prepared the phone (poll GET /v2/rentals/{id}); billing starts then. agent: true (or an agent API key) makes it an agent rental, limited by the daily agent limit and ended after its idle timeout. Send an Idempotency-Key so a retry never rents twice; a replay answers 200 with replayed: true.

Authentication: API key with rentals:write.

Parameter In Type Required Notes
Idempotency-Key header string Retries with the same key return the first result (kept 24 hours).

Request body:

Field Type Required Notes
phoneId string (uuid) yes
spendingCapMicros integer yes > 0
agent boolean

Response 201:

Field Type Required Notes
rental object yes
replayed boolean yes
Request JSON Schema
{
"type": "object",
"properties": {
"phoneId": {
"type": "string",
"format": "uuid"
},
"spendingCapMicros": {
"type": "integer",
"exclusiveMinimum": 0,
"maximum": 1000000000000
},
"agent": {
"type": "boolean"
}
},
"required": [
"phoneId",
"spendingCapMicros"
],
"additionalProperties": false
}
Response JSON Schema
{
"type": "object",
"properties": {
"rental": {
"type": "object",
"properties": {
"id": {
"type": "string",
"format": "uuid"
},
"phoneId": {
"type": "string",
"format": "uuid"
},
"state": {
"type": "string",
"enum": [
"reserved",
"preparing",
"active",
"ending",
"cleaning",
"closed",
"failed"
]
},
"endReason": {
"anyOf": [
{
"type": "string",
"enum": [
"renter",
"spending_cap",
"balance",
"max_duration",
"host_pause",
"lease_lost",
"reservation_expired",
"prepare_failed",
"operator",
"phone_removed",
"idle_timeout",
"account_suspended",
"spending_limit"
]
},
{
"type": "null"
}
]
},
"hourlyRateMicros": {
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
"bandwidthRateMicrosPerGb": {
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
"downloadRateMicrosPerGb": {
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
"uploadRateMicrosPerGb": {
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
"spendingCapMicros": {
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
"maxMinutes": {
"type": "integer",
"minimum": -9007199254740991,
"maximum": 9007199254740991
},
"reservationExpiresAt": {
"type": "string",
"format": "date-time"
},
"startedAt": {
"anyOf": [
{
"type": "string",
"format": "date-time"
},
{
"type": "null"
}
]
},
"billingEndedAt": {
"anyOf": [
{
"type": "string",
"format": "date-time"
},
{
"type": "null"
}
]
},
"endedAt": {
"anyOf": [
{
"type": "string",
"format": "date-time"
},
{
"type": "null"
}
]
},
"billedMinutes": {
"type": "integer",
"minimum": -9007199254740991,
"maximum": 9007199254740991
},
"billedBytes": {
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
"billedDownloadBytes": {
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
"bytesSoFar": {
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
"chargedMicros": {
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
"createdAt": {
"type": "string",
"format": "date-time"
},
"agent": {
"type": "boolean"
},
"idleTimeoutSeconds": {
"anyOf": [
{
"type": "integer",
"minimum": -9007199254740991,
"maximum": 9007199254740991
},
{
"type": "null"
}
]
},
"lastActivityAt": {
"anyOf": [
{
"type": "string",
"format": "date-time"
},
{
"type": "null"
}
]
},
"limitCapMicros": {
"anyOf": [
{
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
{
"type": "null"
}
]
},
"cutoffWarning": {
"anyOf": [
{
"type": "object",
"properties": {
"at": {
"type": "string",
"format": "date-time"
},
"reason": {
"type": "string",
"enum": [
"spending_cap",
"spending_limit",
"balance",
"max_duration"
]
}
},
"required": [
"at",
"reason"
],
"additionalProperties": false
},
{
"type": "null"
}
]
},
"ownerRental": {
"type": "boolean"
},
"pausedAt": {
"anyOf": [
{
"type": "string",
"format": "date-time"
},
{
"type": "null"
}
]
}
},
"required": [
"id",
"phoneId",
"state",
"endReason",
"hourlyRateMicros",
"bandwidthRateMicrosPerGb",
"downloadRateMicrosPerGb",
"uploadRateMicrosPerGb",
"spendingCapMicros",
"maxMinutes",
"reservationExpiresAt",
"startedAt",
"billingEndedAt",
"endedAt",
"billedMinutes",
"billedBytes",
"billedDownloadBytes",
"chargedMicros",
"createdAt",
"agent",
"idleTimeoutSeconds",
"lastActivityAt",
"limitCapMicros",
"cutoffWarning"
],
"additionalProperties": false
},
"replayed": {
"type": "boolean"
}
},
"required": [
"rental",
"replayed"
],
"additionalProperties": false
}

Error codes: phone_unavailable, insufficient_credit, spending_cap_below_first_minute, spending_cap_above_limit, too_many_open_rentals, agent_daily_limit_exceeded, spending_limit_exceeded, idempotency_key_reused.

Your recent rentals.

Authentication: API key with rentals:read.

Response 200:

Field Type Required Notes
rentals array of object yes
Response JSON Schema
{
"type": "object",
"properties": {
"rentals": {
"type": "array",
"items": {
"type": "object",
"properties": {
"id": {
"type": "string",
"format": "uuid"
},
"phoneId": {
"type": "string",
"format": "uuid"
},
"state": {
"type": "string",
"enum": [
"reserved",
"preparing",
"active",
"ending",
"cleaning",
"closed",
"failed"
]
},
"endReason": {
"anyOf": [
{
"type": "string",
"enum": [
"renter",
"spending_cap",
"balance",
"max_duration",
"host_pause",
"lease_lost",
"reservation_expired",
"prepare_failed",
"operator",
"phone_removed",
"idle_timeout",
"account_suspended",
"spending_limit"
]
},
{
"type": "null"
}
]
},
"hourlyRateMicros": {
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
"bandwidthRateMicrosPerGb": {
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
"downloadRateMicrosPerGb": {
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
"uploadRateMicrosPerGb": {
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
"spendingCapMicros": {
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
"maxMinutes": {
"type": "integer",
"minimum": -9007199254740991,
"maximum": 9007199254740991
},
"reservationExpiresAt": {
"type": "string",
"format": "date-time"
},
"startedAt": {
"anyOf": [
{
"type": "string",
"format": "date-time"
},
{
"type": "null"
}
]
},
"billingEndedAt": {
"anyOf": [
{
"type": "string",
"format": "date-time"
},
{
"type": "null"
}
]
},
"endedAt": {
"anyOf": [
{
"type": "string",
"format": "date-time"
},
{
"type": "null"
}
]
},
"billedMinutes": {
"type": "integer",
"minimum": -9007199254740991,
"maximum": 9007199254740991
},
"billedBytes": {
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
"billedDownloadBytes": {
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
"bytesSoFar": {
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
"chargedMicros": {
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
"createdAt": {
"type": "string",
"format": "date-time"
},
"agent": {
"type": "boolean"
},
"idleTimeoutSeconds": {
"anyOf": [
{
"type": "integer",
"minimum": -9007199254740991,
"maximum": 9007199254740991
},
{
"type": "null"
}
]
},
"lastActivityAt": {
"anyOf": [
{
"type": "string",
"format": "date-time"
},
{
"type": "null"
}
]
},
"limitCapMicros": {
"anyOf": [
{
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
{
"type": "null"
}
]
},
"cutoffWarning": {
"anyOf": [
{
"type": "object",
"properties": {
"at": {
"type": "string",
"format": "date-time"
},
"reason": {
"type": "string",
"enum": [
"spending_cap",
"spending_limit",
"balance",
"max_duration"
]
}
},
"required": [
"at",
"reason"
],
"additionalProperties": false
},
{
"type": "null"
}
]
},
"ownerRental": {
"type": "boolean"
},
"pausedAt": {
"anyOf": [
{
"type": "string",
"format": "date-time"
},
{
"type": "null"
}
]
}
},
"required": [
"id",
"phoneId",
"state",
"endReason",
"hourlyRateMicros",
"bandwidthRateMicrosPerGb",
"downloadRateMicrosPerGb",
"uploadRateMicrosPerGb",
"spendingCapMicros",
"maxMinutes",
"reservationExpiresAt",
"startedAt",
"billingEndedAt",
"endedAt",
"billedMinutes",
"billedBytes",
"billedDownloadBytes",
"chargedMicros",
"createdAt",
"agent",
"idleTimeoutSeconds",
"lastActivityAt",
"limitCapMicros",
"cutoffWarning"
],
"additionalProperties": false
}
}
},
"required": [
"rentals"
],
"additionalProperties": false
}

One rental.

Authentication: API key with rentals:read.

Parameter In Type Required Notes
id path string (uuid) yes

Response 200:

Field Type Required Notes
id string (uuid) yes
phoneId string (uuid) yes
state "reserved", "preparing", "active", "ending", "cleaning", "closed", "failed" yes
endReason "renter", "spending_cap", "balance", "max_duration", "host_pause", "lease_lost", "reservation_expired", "prepare_failed", "operator", "phone_removed", "idle_timeout", "account_suspended", "spending_limit" or null yes
hourlyRateMicros integer yes ≥ 0
bandwidthRateMicrosPerGb integer yes ≥ 0
downloadRateMicrosPerGb integer yes ≥ 0
uploadRateMicrosPerGb integer yes ≥ 0
spendingCapMicros integer yes ≥ 0
maxMinutes integer yes ≥ -9007199254740991
reservationExpiresAt string (date-time) yes
startedAt string (date-time) or null yes
billingEndedAt string (date-time) or null yes
endedAt string (date-time) or null yes
billedMinutes integer yes ≥ -9007199254740991
billedBytes integer yes ≥ 0
billedDownloadBytes integer yes ≥ 0
bytesSoFar integer ≥ 0
chargedMicros integer yes ≥ 0
createdAt string (date-time) yes
agent boolean yes
idleTimeoutSeconds integer or null yes
lastActivityAt string (date-time) or null yes
limitCapMicros integer or null yes
cutoffWarning object or null yes
ownerRental boolean
pausedAt string (date-time) or null
Response JSON Schema
{
"type": "object",
"properties": {
"id": {
"type": "string",
"format": "uuid"
},
"phoneId": {
"type": "string",
"format": "uuid"
},
"state": {
"type": "string",
"enum": [
"reserved",
"preparing",
"active",
"ending",
"cleaning",
"closed",
"failed"
]
},
"endReason": {
"anyOf": [
{
"type": "string",
"enum": [
"renter",
"spending_cap",
"balance",
"max_duration",
"host_pause",
"lease_lost",
"reservation_expired",
"prepare_failed",
"operator",
"phone_removed",
"idle_timeout",
"account_suspended",
"spending_limit"
]
},
{
"type": "null"
}
]
},
"hourlyRateMicros": {
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
"bandwidthRateMicrosPerGb": {
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
"downloadRateMicrosPerGb": {
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
"uploadRateMicrosPerGb": {
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
"spendingCapMicros": {
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
"maxMinutes": {
"type": "integer",
"minimum": -9007199254740991,
"maximum": 9007199254740991
},
"reservationExpiresAt": {
"type": "string",
"format": "date-time"
},
"startedAt": {
"anyOf": [
{
"type": "string",
"format": "date-time"
},
{
"type": "null"
}
]
},
"billingEndedAt": {
"anyOf": [
{
"type": "string",
"format": "date-time"
},
{
"type": "null"
}
]
},
"endedAt": {
"anyOf": [
{
"type": "string",
"format": "date-time"
},
{
"type": "null"
}
]
},
"billedMinutes": {
"type": "integer",
"minimum": -9007199254740991,
"maximum": 9007199254740991
},
"billedBytes": {
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
"billedDownloadBytes": {
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
"bytesSoFar": {
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
"chargedMicros": {
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
"createdAt": {
"type": "string",
"format": "date-time"
},
"agent": {
"type": "boolean"
},
"idleTimeoutSeconds": {
"anyOf": [
{
"type": "integer",
"minimum": -9007199254740991,
"maximum": 9007199254740991
},
{
"type": "null"
}
]
},
"lastActivityAt": {
"anyOf": [
{
"type": "string",
"format": "date-time"
},
{
"type": "null"
}
]
},
"limitCapMicros": {
"anyOf": [
{
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
{
"type": "null"
}
]
},
"cutoffWarning": {
"anyOf": [
{
"type": "object",
"properties": {
"at": {
"type": "string",
"format": "date-time"
},
"reason": {
"type": "string",
"enum": [
"spending_cap",
"spending_limit",
"balance",
"max_duration"
]
}
},
"required": [
"at",
"reason"
],
"additionalProperties": false
},
{
"type": "null"
}
]
},
"ownerRental": {
"type": "boolean"
},
"pausedAt": {
"anyOf": [
{
"type": "string",
"format": "date-time"
},
{
"type": "null"
}
]
}
},
"required": [
"id",
"phoneId",
"state",
"endReason",
"hourlyRateMicros",
"bandwidthRateMicrosPerGb",
"downloadRateMicrosPerGb",
"uploadRateMicrosPerGb",
"spendingCapMicros",
"maxMinutes",
"reservationExpiresAt",
"startedAt",
"billingEndedAt",
"endedAt",
"billedMinutes",
"billedBytes",
"billedDownloadBytes",
"chargedMicros",
"createdAt",
"agent",
"idleTimeoutSeconds",
"lastActivityAt",
"limitCapMicros",
"cutoffWarning"
],
"additionalProperties": false
}

End a rental.

Billing stops now (minutes already started are charged), access is cut within seconds and the phone is wiped and verified.

Authentication: API key with rentals:write.

Parameter In Type Required Notes
id path string (uuid) yes
Idempotency-Key header string Retries with the same key return the first result (kept 24 hours).

Response 200:

Field Type Required Notes
id string (uuid) yes
phoneId string (uuid) yes
state "reserved", "preparing", "active", "ending", "cleaning", "closed", "failed" yes
endReason "renter", "spending_cap", "balance", "max_duration", "host_pause", "lease_lost", "reservation_expired", "prepare_failed", "operator", "phone_removed", "idle_timeout", "account_suspended", "spending_limit" or null yes
hourlyRateMicros integer yes ≥ 0
bandwidthRateMicrosPerGb integer yes ≥ 0
downloadRateMicrosPerGb integer yes ≥ 0
uploadRateMicrosPerGb integer yes ≥ 0
spendingCapMicros integer yes ≥ 0
maxMinutes integer yes ≥ -9007199254740991
reservationExpiresAt string (date-time) yes
startedAt string (date-time) or null yes
billingEndedAt string (date-time) or null yes
endedAt string (date-time) or null yes
billedMinutes integer yes ≥ -9007199254740991
billedBytes integer yes ≥ 0
billedDownloadBytes integer yes ≥ 0
bytesSoFar integer ≥ 0
chargedMicros integer yes ≥ 0
createdAt string (date-time) yes
agent boolean yes
idleTimeoutSeconds integer or null yes
lastActivityAt string (date-time) or null yes
limitCapMicros integer or null yes
cutoffWarning object or null yes
ownerRental boolean
pausedAt string (date-time) or null
Response JSON Schema
{
"type": "object",
"properties": {
"id": {
"type": "string",
"format": "uuid"
},
"phoneId": {
"type": "string",
"format": "uuid"
},
"state": {
"type": "string",
"enum": [
"reserved",
"preparing",
"active",
"ending",
"cleaning",
"closed",
"failed"
]
},
"endReason": {
"anyOf": [
{
"type": "string",
"enum": [
"renter",
"spending_cap",
"balance",
"max_duration",
"host_pause",
"lease_lost",
"reservation_expired",
"prepare_failed",
"operator",
"phone_removed",
"idle_timeout",
"account_suspended",
"spending_limit"
]
},
{
"type": "null"
}
]
},
"hourlyRateMicros": {
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
"bandwidthRateMicrosPerGb": {
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
"downloadRateMicrosPerGb": {
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
"uploadRateMicrosPerGb": {
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
"spendingCapMicros": {
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
"maxMinutes": {
"type": "integer",
"minimum": -9007199254740991,
"maximum": 9007199254740991
},
"reservationExpiresAt": {
"type": "string",
"format": "date-time"
},
"startedAt": {
"anyOf": [
{
"type": "string",
"format": "date-time"
},
{
"type": "null"
}
]
},
"billingEndedAt": {
"anyOf": [
{
"type": "string",
"format": "date-time"
},
{
"type": "null"
}
]
},
"endedAt": {
"anyOf": [
{
"type": "string",
"format": "date-time"
},
{
"type": "null"
}
]
},
"billedMinutes": {
"type": "integer",
"minimum": -9007199254740991,
"maximum": 9007199254740991
},
"billedBytes": {
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
"billedDownloadBytes": {
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
"bytesSoFar": {
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
"chargedMicros": {
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
"createdAt": {
"type": "string",
"format": "date-time"
},
"agent": {
"type": "boolean"
},
"idleTimeoutSeconds": {
"anyOf": [
{
"type": "integer",
"minimum": -9007199254740991,
"maximum": 9007199254740991
},
{
"type": "null"
}
]
},
"lastActivityAt": {
"anyOf": [
{
"type": "string",
"format": "date-time"
},
{
"type": "null"
}
]
},
"limitCapMicros": {
"anyOf": [
{
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
{
"type": "null"
}
]
},
"cutoffWarning": {
"anyOf": [
{
"type": "object",
"properties": {
"at": {
"type": "string",
"format": "date-time"
},
"reason": {
"type": "string",
"enum": [
"spending_cap",
"spending_limit",
"balance",
"max_duration"
]
}
},
"required": [
"at",
"reason"
],
"additionalProperties": false
},
{
"type": "null"
}
]
},
"ownerRental": {
"type": "boolean"
},
"pausedAt": {
"anyOf": [
{
"type": "string",
"format": "date-time"
},
{
"type": "null"
}
]
}
},
"required": [
"id",
"phoneId",
"state",
"endReason",
"hourlyRateMicros",
"bandwidthRateMicrosPerGb",
"downloadRateMicrosPerGb",
"uploadRateMicrosPerGb",
"spendingCapMicros",
"maxMinutes",
"reservationExpiresAt",
"startedAt",
"billingEndedAt",
"endedAt",
"billedMinutes",
"billedBytes",
"billedDownloadBytes",
"chargedMicros",
"createdAt",
"agent",
"idleTimeoutSeconds",
"lastActivityAt",
"limitCapMicros",
"cutoffWarning"
],
"additionalProperties": false
}

A relay session token for an active rental.

What pocketshare connect and the MCP server use to attach to the phone through the relay (protocol 2). The token admits new relay connections for 15 minutes; issuing another revokes it.

Authentication: API key with rentals:write.

Parameter In Type Required Notes
id path string (uuid) yes

Response 200:

Field Type Required Notes
rentalId string (uuid) yes
phoneId string (uuid) yes
token string yes
expiresAt string (date-time) yes
relayUrl string yes
phone object yes
Response JSON Schema
{
"type": "object",
"properties": {
"rentalId": {
"type": "string",
"format": "uuid"
},
"phoneId": {
"type": "string",
"format": "uuid"
},
"token": {
"type": "string"
},
"expiresAt": {
"type": "string",
"format": "date-time"
},
"relayUrl": {
"type": "string"
},
"phone": {
"type": "object",
"properties": {
"brand": {
"type": "string"
},
"model": {
"type": "string"
},
"androidVersion": {
"type": "string"
},
"apiLevel": {
"type": "integer",
"minimum": -9007199254740991,
"maximum": 9007199254740991
}
},
"required": [
"brand",
"model",
"androidVersion",
"apiLevel"
],
"additionalProperties": false
}
},
"required": [
"rentalId",
"phoneId",
"token",
"expiresAt",
"relayUrl",
"phone"
],
"additionalProperties": false
}

Error codes: rental_not_active.

Your rentals with phone, relay usage and connect command.

Authentication: API key with rentals:read.

Response 200:

Field Type Required Notes
rentals array of object yes
Response JSON Schema
{
"type": "object",
"properties": {
"rentals": {
"type": "array",
"items": {
"type": "object",
"properties": {
"id": {
"type": "string",
"format": "uuid"
},
"phoneId": {
"type": "string",
"format": "uuid"
},
"state": {
"type": "string",
"enum": [
"reserved",
"preparing",
"active",
"ending",
"cleaning",
"closed",
"failed"
]
},
"endReason": {
"anyOf": [
{
"type": "string",
"enum": [
"renter",
"spending_cap",
"balance",
"max_duration",
"host_pause",
"lease_lost",
"reservation_expired",
"prepare_failed",
"operator",
"phone_removed",
"idle_timeout",
"account_suspended",
"spending_limit"
]
},
{
"type": "null"
}
]
},
"hourlyRateMicros": {
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
"bandwidthRateMicrosPerGb": {
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
"downloadRateMicrosPerGb": {
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
"uploadRateMicrosPerGb": {
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
"spendingCapMicros": {
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
"maxMinutes": {
"type": "integer",
"minimum": -9007199254740991,
"maximum": 9007199254740991
},
"reservationExpiresAt": {
"type": "string",
"format": "date-time"
},
"startedAt": {
"anyOf": [
{
"type": "string",
"format": "date-time"
},
{
"type": "null"
}
]
},
"billingEndedAt": {
"anyOf": [
{
"type": "string",
"format": "date-time"
},
{
"type": "null"
}
]
},
"endedAt": {
"anyOf": [
{
"type": "string",
"format": "date-time"
},
{
"type": "null"
}
]
},
"billedMinutes": {
"type": "integer",
"minimum": -9007199254740991,
"maximum": 9007199254740991
},
"billedBytes": {
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
"billedDownloadBytes": {
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
"bytesSoFar": {
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
"chargedMicros": {
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
"createdAt": {
"type": "string",
"format": "date-time"
},
"agent": {
"type": "boolean"
},
"idleTimeoutSeconds": {
"anyOf": [
{
"type": "integer",
"minimum": -9007199254740991,
"maximum": 9007199254740991
},
{
"type": "null"
}
]
},
"lastActivityAt": {
"anyOf": [
{
"type": "string",
"format": "date-time"
},
{
"type": "null"
}
]
},
"limitCapMicros": {
"anyOf": [
{
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
{
"type": "null"
}
]
},
"cutoffWarning": {
"anyOf": [
{
"type": "object",
"properties": {
"at": {
"type": "string",
"format": "date-time"
},
"reason": {
"type": "string",
"enum": [
"spending_cap",
"spending_limit",
"balance",
"max_duration"
]
}
},
"required": [
"at",
"reason"
],
"additionalProperties": false
},
{
"type": "null"
}
]
},
"ownerRental": {
"type": "boolean"
},
"pausedAt": {
"anyOf": [
{
"type": "string",
"format": "date-time"
},
{
"type": "null"
}
]
},
"phone": {
"type": "object",
"properties": {
"id": {
"type": "string",
"format": "uuid"
},
"brand": {
"type": "string"
},
"model": {
"type": "string"
},
"androidVersion": {
"type": "string"
},
"apiLevel": {
"type": "integer",
"minimum": -9007199254740991,
"maximum": 9007199254740991
}
},
"required": [
"id",
"brand",
"model",
"androidVersion",
"apiLevel"
],
"additionalProperties": false
},
"usage": {
"type": "object",
"properties": {
"bytesIn": {
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
"bytesOut": {
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
}
},
"required": [
"bytesIn",
"bytesOut"
],
"additionalProperties": false
},
"connectCommand": {
"type": "string"
}
},
"required": [
"id",
"phoneId",
"state",
"endReason",
"hourlyRateMicros",
"bandwidthRateMicrosPerGb",
"downloadRateMicrosPerGb",
"uploadRateMicrosPerGb",
"spendingCapMicros",
"maxMinutes",
"reservationExpiresAt",
"startedAt",
"billingEndedAt",
"endedAt",
"billedMinutes",
"billedBytes",
"billedDownloadBytes",
"chargedMicros",
"createdAt",
"agent",
"idleTimeoutSeconds",
"lastActivityAt",
"limitCapMicros",
"cutoffWarning",
"phone",
"usage",
"connectCommand"
],
"additionalProperties": false
}
}
},
"required": [
"rentals"
],
"additionalProperties": false
}

One rental with phone and relay usage.

Authentication: API key with rentals:read.

Parameter In Type Required Notes
id path string (uuid) yes

Response 200:

Field Type Required Notes
id string (uuid) yes
phoneId string (uuid) yes
state "reserved", "preparing", "active", "ending", "cleaning", "closed", "failed" yes
endReason "renter", "spending_cap", "balance", "max_duration", "host_pause", "lease_lost", "reservation_expired", "prepare_failed", "operator", "phone_removed", "idle_timeout", "account_suspended", "spending_limit" or null yes
hourlyRateMicros integer yes ≥ 0
bandwidthRateMicrosPerGb integer yes ≥ 0
downloadRateMicrosPerGb integer yes ≥ 0
uploadRateMicrosPerGb integer yes ≥ 0
spendingCapMicros integer yes ≥ 0
maxMinutes integer yes ≥ -9007199254740991
reservationExpiresAt string (date-time) yes
startedAt string (date-time) or null yes
billingEndedAt string (date-time) or null yes
endedAt string (date-time) or null yes
billedMinutes integer yes ≥ -9007199254740991
billedBytes integer yes ≥ 0
billedDownloadBytes integer yes ≥ 0
bytesSoFar integer ≥ 0
chargedMicros integer yes ≥ 0
createdAt string (date-time) yes
agent boolean yes
idleTimeoutSeconds integer or null yes
lastActivityAt string (date-time) or null yes
limitCapMicros integer or null yes
cutoffWarning object or null yes
ownerRental boolean
pausedAt string (date-time) or null
phone object yes
usage object yes
connectCommand string yes
Response JSON Schema
{
"type": "object",
"properties": {
"id": {
"type": "string",
"format": "uuid"
},
"phoneId": {
"type": "string",
"format": "uuid"
},
"state": {
"type": "string",
"enum": [
"reserved",
"preparing",
"active",
"ending",
"cleaning",
"closed",
"failed"
]
},
"endReason": {
"anyOf": [
{
"type": "string",
"enum": [
"renter",
"spending_cap",
"balance",
"max_duration",
"host_pause",
"lease_lost",
"reservation_expired",
"prepare_failed",
"operator",
"phone_removed",
"idle_timeout",
"account_suspended",
"spending_limit"
]
},
{
"type": "null"
}
]
},
"hourlyRateMicros": {
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
"bandwidthRateMicrosPerGb": {
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
"downloadRateMicrosPerGb": {
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
"uploadRateMicrosPerGb": {
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
"spendingCapMicros": {
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
"maxMinutes": {
"type": "integer",
"minimum": -9007199254740991,
"maximum": 9007199254740991
},
"reservationExpiresAt": {
"type": "string",
"format": "date-time"
},
"startedAt": {
"anyOf": [
{
"type": "string",
"format": "date-time"
},
{
"type": "null"
}
]
},
"billingEndedAt": {
"anyOf": [
{
"type": "string",
"format": "date-time"
},
{
"type": "null"
}
]
},
"endedAt": {
"anyOf": [
{
"type": "string",
"format": "date-time"
},
{
"type": "null"
}
]
},
"billedMinutes": {
"type": "integer",
"minimum": -9007199254740991,
"maximum": 9007199254740991
},
"billedBytes": {
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
"billedDownloadBytes": {
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
"bytesSoFar": {
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
"chargedMicros": {
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
"createdAt": {
"type": "string",
"format": "date-time"
},
"agent": {
"type": "boolean"
},
"idleTimeoutSeconds": {
"anyOf": [
{
"type": "integer",
"minimum": -9007199254740991,
"maximum": 9007199254740991
},
{
"type": "null"
}
]
},
"lastActivityAt": {
"anyOf": [
{
"type": "string",
"format": "date-time"
},
{
"type": "null"
}
]
},
"limitCapMicros": {
"anyOf": [
{
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
{
"type": "null"
}
]
},
"cutoffWarning": {
"anyOf": [
{
"type": "object",
"properties": {
"at": {
"type": "string",
"format": "date-time"
},
"reason": {
"type": "string",
"enum": [
"spending_cap",
"spending_limit",
"balance",
"max_duration"
]
}
},
"required": [
"at",
"reason"
],
"additionalProperties": false
},
{
"type": "null"
}
]
},
"ownerRental": {
"type": "boolean"
},
"pausedAt": {
"anyOf": [
{
"type": "string",
"format": "date-time"
},
{
"type": "null"
}
]
},
"phone": {
"type": "object",
"properties": {
"id": {
"type": "string",
"format": "uuid"
},
"brand": {
"type": "string"
},
"model": {
"type": "string"
},
"androidVersion": {
"type": "string"
},
"apiLevel": {
"type": "integer",
"minimum": -9007199254740991,
"maximum": 9007199254740991
}
},
"required": [
"id",
"brand",
"model",
"androidVersion",
"apiLevel"
],
"additionalProperties": false
},
"usage": {
"type": "object",
"properties": {
"bytesIn": {
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
"bytesOut": {
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
}
},
"required": [
"bytesIn",
"bytesOut"
],
"additionalProperties": false
},
"connectCommand": {
"type": "string"
}
},
"required": [
"id",
"phoneId",
"state",
"endReason",
"hourlyRateMicros",
"bandwidthRateMicrosPerGb",
"downloadRateMicrosPerGb",
"uploadRateMicrosPerGb",
"spendingCapMicros",
"maxMinutes",
"reservationExpiresAt",
"startedAt",
"billingEndedAt",
"endedAt",
"billedMinutes",
"billedBytes",
"billedDownloadBytes",
"chargedMicros",
"createdAt",
"agent",
"idleTimeoutSeconds",
"lastActivityAt",
"limitCapMicros",
"cutoffWarning",
"phone",
"usage",
"connectCommand"
],
"additionalProperties": false
}

Spending limits for AI agents (MCP).

Report activity on an agent rental.

Resets an agent rental’s idle timer and returns the rental. The MCP server calls it on every tool call; for other rentals it only returns the rental.

Authentication: API key with rentals:write.

Parameter In Type Required Notes
id path string (uuid) yes

Response 200:

Field Type Required Notes
id string (uuid) yes
phoneId string (uuid) yes
state "reserved", "preparing", "active", "ending", "cleaning", "closed", "failed" yes
endReason "renter", "spending_cap", "balance", "max_duration", "host_pause", "lease_lost", "reservation_expired", "prepare_failed", "operator", "phone_removed", "idle_timeout", "account_suspended", "spending_limit" or null yes
hourlyRateMicros integer yes ≥ 0
bandwidthRateMicrosPerGb integer yes ≥ 0
downloadRateMicrosPerGb integer yes ≥ 0
uploadRateMicrosPerGb integer yes ≥ 0
spendingCapMicros integer yes ≥ 0
maxMinutes integer yes ≥ -9007199254740991
reservationExpiresAt string (date-time) yes
startedAt string (date-time) or null yes
billingEndedAt string (date-time) or null yes
endedAt string (date-time) or null yes
billedMinutes integer yes ≥ -9007199254740991
billedBytes integer yes ≥ 0
billedDownloadBytes integer yes ≥ 0
bytesSoFar integer ≥ 0
chargedMicros integer yes ≥ 0
createdAt string (date-time) yes
agent boolean yes
idleTimeoutSeconds integer or null yes
lastActivityAt string (date-time) or null yes
limitCapMicros integer or null yes
cutoffWarning object or null yes
ownerRental boolean
pausedAt string (date-time) or null
Response JSON Schema
{
"type": "object",
"properties": {
"id": {
"type": "string",
"format": "uuid"
},
"phoneId": {
"type": "string",
"format": "uuid"
},
"state": {
"type": "string",
"enum": [
"reserved",
"preparing",
"active",
"ending",
"cleaning",
"closed",
"failed"
]
},
"endReason": {
"anyOf": [
{
"type": "string",
"enum": [
"renter",
"spending_cap",
"balance",
"max_duration",
"host_pause",
"lease_lost",
"reservation_expired",
"prepare_failed",
"operator",
"phone_removed",
"idle_timeout",
"account_suspended",
"spending_limit"
]
},
{
"type": "null"
}
]
},
"hourlyRateMicros": {
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
"bandwidthRateMicrosPerGb": {
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
"downloadRateMicrosPerGb": {
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
"uploadRateMicrosPerGb": {
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
"spendingCapMicros": {
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
"maxMinutes": {
"type": "integer",
"minimum": -9007199254740991,
"maximum": 9007199254740991
},
"reservationExpiresAt": {
"type": "string",
"format": "date-time"
},
"startedAt": {
"anyOf": [
{
"type": "string",
"format": "date-time"
},
{
"type": "null"
}
]
},
"billingEndedAt": {
"anyOf": [
{
"type": "string",
"format": "date-time"
},
{
"type": "null"
}
]
},
"endedAt": {
"anyOf": [
{
"type": "string",
"format": "date-time"
},
{
"type": "null"
}
]
},
"billedMinutes": {
"type": "integer",
"minimum": -9007199254740991,
"maximum": 9007199254740991
},
"billedBytes": {
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
"billedDownloadBytes": {
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
"bytesSoFar": {
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
"chargedMicros": {
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
"createdAt": {
"type": "string",
"format": "date-time"
},
"agent": {
"type": "boolean"
},
"idleTimeoutSeconds": {
"anyOf": [
{
"type": "integer",
"minimum": -9007199254740991,
"maximum": 9007199254740991
},
{
"type": "null"
}
]
},
"lastActivityAt": {
"anyOf": [
{
"type": "string",
"format": "date-time"
},
{
"type": "null"
}
]
},
"limitCapMicros": {
"anyOf": [
{
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
{
"type": "null"
}
]
},
"cutoffWarning": {
"anyOf": [
{
"type": "object",
"properties": {
"at": {
"type": "string",
"format": "date-time"
},
"reason": {
"type": "string",
"enum": [
"spending_cap",
"spending_limit",
"balance",
"max_duration"
]
}
},
"required": [
"at",
"reason"
],
"additionalProperties": false
},
{
"type": "null"
}
]
},
"ownerRental": {
"type": "boolean"
},
"pausedAt": {
"anyOf": [
{
"type": "string",
"format": "date-time"
},
{
"type": "null"
}
]
}
},
"required": [
"id",
"phoneId",
"state",
"endReason",
"hourlyRateMicros",
"bandwidthRateMicrosPerGb",
"downloadRateMicrosPerGb",
"uploadRateMicrosPerGb",
"spendingCapMicros",
"maxMinutes",
"reservationExpiresAt",
"startedAt",
"billingEndedAt",
"endedAt",
"billedMinutes",
"billedBytes",
"billedDownloadBytes",
"chargedMicros",
"createdAt",
"agent",
"idleTimeoutSeconds",
"lastActivityAt",
"limitCapMicros",
"cutoffWarning"
],
"additionalProperties": false
}

Limits for agent rentals.

The daily limit (rolling 24 hours: open agent rentals count at their caps, ended ones at what they cost), what is used and left, and the idle timeout.

Authentication: API key with rentals:read.

Response 200:

Field Type Required Notes
dailyLimitMicros integer yes ≥ 0
idleTimeoutSeconds integer yes ≥ -9007199254740991
maxDailyLimitMicros integer yes ≥ 0
usedMicros integer yes ≥ 0
remainingMicros integer yes ≥ 0
windowHours 24 yes
isDefault boolean yes
Response JSON Schema
{
"type": "object",
"properties": {
"dailyLimitMicros": {
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
"idleTimeoutSeconds": {
"type": "integer",
"minimum": -9007199254740991,
"maximum": 9007199254740991
},
"maxDailyLimitMicros": {
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
"usedMicros": {
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
"remainingMicros": {
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
"windowHours": {
"type": "number",
"const": 24
},
"isDefault": {
"type": "boolean"
}
},
"required": [
"dailyLimitMicros",
"idleTimeoutSeconds",
"maxDailyLimitMicros",
"usedMicros",
"remainingMicros",
"windowHours",
"isDefault"
],
"additionalProperties": false
}

Change the limits for agent rentals.

Any key may lower them; raising needs a non-agent key (or the website). The daily limit can’t exceed maxDailyLimitMicros.

Authentication: API key with rentals:write.

Request body:

Field Type Required Notes
dailyLimitMicros integer ≥ 0; ≤ 1000000000
idleTimeoutSeconds integer ≥ 60; ≤ 1800

Response 200:

Field Type Required Notes
dailyLimitMicros integer yes ≥ 0
idleTimeoutSeconds integer yes ≥ -9007199254740991
maxDailyLimitMicros integer yes ≥ 0
usedMicros integer yes ≥ 0
remainingMicros integer yes ≥ 0
windowHours 24 yes
isDefault boolean yes
Request JSON Schema
{
"type": "object",
"properties": {
"dailyLimitMicros": {
"type": "integer",
"minimum": 0,
"maximum": 1000000000
},
"idleTimeoutSeconds": {
"type": "integer",
"minimum": 60,
"maximum": 1800
}
},
"additionalProperties": false
}
Response JSON Schema
{
"type": "object",
"properties": {
"dailyLimitMicros": {
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
"idleTimeoutSeconds": {
"type": "integer",
"minimum": -9007199254740991,
"maximum": 9007199254740991
},
"maxDailyLimitMicros": {
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
"usedMicros": {
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
"remainingMicros": {
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
"windowHours": {
"type": "number",
"const": 24
},
"isDefault": {
"type": "boolean"
}
},
"required": [
"dailyLimitMicros",
"idleTimeoutSeconds",
"maxDailyLimitMicros",
"usedMicros",
"remainingMicros",
"windowHours",
"isDefault"
],
"additionalProperties": false
}

Error codes: agent_key_cannot_raise_limits, agent_limit_above_maximum.

The account the key belongs to.

Authentication: any API key.

Response 200:

Field Type Required Notes
user object yes
Response JSON Schema
{
"type": "object",
"properties": {
"user": {
"type": "object",
"properties": {
"id": {
"type": "string",
"format": "uuid"
},
"email": {
"type": "string"
},
"roles": {
"type": "array",
"items": {
"type": "string",
"enum": [
"renter",
"host",
"operator"
]
}
},
"trustTier": {
"type": "string",
"enum": [
"new",
"standard",
"verified"
]
}
},
"required": [
"id",
"email",
"roles",
"trustTier"
],
"additionalProperties": false
}
},
"required": [
"user"
],
"additionalProperties": false
}

Account spending limits.

Optional daily and monthly limits on what rentals cost (UTC calendar day and month; a rental counts toward the day and month it started in, open ones at their caps). Off unless set. A rent whose cap doesn’t fit what is left answers spending_limit_exceeded.

Authentication: API key with rentals:read.

Response 200:

Field Type Required Notes
dailyLimitMicros integer or null yes
monthlyLimitMicros integer or null yes
day object yes
month object yes
maxDailyLimitMicros integer yes ≥ 0
maxMonthlyLimitMicros integer yes ≥ 0
isDefault boolean yes
Response JSON Schema
{
"type": "object",
"properties": {
"dailyLimitMicros": {
"anyOf": [
{
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
{
"type": "null"
}
]
},
"monthlyLimitMicros": {
"anyOf": [
{
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
{
"type": "null"
}
]
},
"day": {
"type": "object",
"properties": {
"start": {
"type": "string",
"format": "date-time"
},
"end": {
"type": "string",
"format": "date-time"
},
"limitMicros": {
"anyOf": [
{
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
{
"type": "null"
}
]
},
"usedMicros": {
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
"remainingMicros": {
"anyOf": [
{
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
{
"type": "null"
}
]
}
},
"required": [
"start",
"end",
"limitMicros",
"usedMicros",
"remainingMicros"
],
"additionalProperties": false
},
"month": {
"type": "object",
"properties": {
"start": {
"type": "string",
"format": "date-time"
},
"end": {
"type": "string",
"format": "date-time"
},
"limitMicros": {
"anyOf": [
{
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
{
"type": "null"
}
]
},
"usedMicros": {
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
"remainingMicros": {
"anyOf": [
{
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
{
"type": "null"
}
]
}
},
"required": [
"start",
"end",
"limitMicros",
"usedMicros",
"remainingMicros"
],
"additionalProperties": false
},
"maxDailyLimitMicros": {
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
"maxMonthlyLimitMicros": {
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
"isDefault": {
"type": "boolean"
}
},
"required": [
"dailyLimitMicros",
"monthlyLimitMicros",
"day",
"month",
"maxDailyLimitMicros",
"maxMonthlyLimitMicros",
"isDefault"
],
"additionalProperties": false
}

Set or change the account spending limits.

A field left out keeps its value; null removes the limit. Any key may lower or set a limit; raising or removing one needs a non-agent key (or the website). A limit lowered while rentals run caps them at what is left (end reason spending_limit).

Authentication: API key with rentals:write.

Request body:

Field Type Required Notes
dailyLimitMicros integer or null
monthlyLimitMicros integer or null

Response 200:

Field Type Required Notes
dailyLimitMicros integer or null yes
monthlyLimitMicros integer or null yes
day object yes
month object yes
maxDailyLimitMicros integer yes ≥ 0
maxMonthlyLimitMicros integer yes ≥ 0
isDefault boolean yes
Request JSON Schema
{
"type": "object",
"properties": {
"dailyLimitMicros": {
"anyOf": [
{
"type": "integer",
"minimum": 0,
"maximum": 10000000000
},
{
"type": "null"
}
]
},
"monthlyLimitMicros": {
"anyOf": [
{
"type": "integer",
"minimum": 0,
"maximum": 100000000000
},
{
"type": "null"
}
]
}
},
"additionalProperties": false
}
Response JSON Schema
{
"type": "object",
"properties": {
"dailyLimitMicros": {
"anyOf": [
{
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
{
"type": "null"
}
]
},
"monthlyLimitMicros": {
"anyOf": [
{
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
{
"type": "null"
}
]
},
"day": {
"type": "object",
"properties": {
"start": {
"type": "string",
"format": "date-time"
},
"end": {
"type": "string",
"format": "date-time"
},
"limitMicros": {
"anyOf": [
{
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
{
"type": "null"
}
]
},
"usedMicros": {
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
"remainingMicros": {
"anyOf": [
{
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
{
"type": "null"
}
]
}
},
"required": [
"start",
"end",
"limitMicros",
"usedMicros",
"remainingMicros"
],
"additionalProperties": false
},
"month": {
"type": "object",
"properties": {
"start": {
"type": "string",
"format": "date-time"
},
"end": {
"type": "string",
"format": "date-time"
},
"limitMicros": {
"anyOf": [
{
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
{
"type": "null"
}
]
},
"usedMicros": {
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
"remainingMicros": {
"anyOf": [
{
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
{
"type": "null"
}
]
}
},
"required": [
"start",
"end",
"limitMicros",
"usedMicros",
"remainingMicros"
],
"additionalProperties": false
},
"maxDailyLimitMicros": {
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
"maxMonthlyLimitMicros": {
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
"isDefault": {
"type": "boolean"
}
},
"required": [
"dailyLimitMicros",
"monthlyLimitMicros",
"day",
"month",
"maxDailyLimitMicros",
"maxMonthlyLimitMicros",
"isDefault"
],
"additionalProperties": false
}

Error codes: agent_key_cannot_raise_limits.

Credit balance.

Authentication: API key with billing:read.

Response 200:

Field Type Required Notes
creditMicros integer yes ≥ -9007199254740991
Response JSON Schema
{
"type": "object",
"properties": {
"creditMicros": {
"type": "integer",
"minimum": -9007199254740991,
"maximum": 9007199254740991
}
},
"required": [
"creditMicros"
],
"additionalProperties": false
}

Credit activity: top-ups and charges.

Authentication: API key with billing:read.

Response 200:

Field Type Required Notes
creditMicros integer yes ≥ -9007199254740991
activity array of object yes
topUpAvailable boolean yes
Response JSON Schema
{
"type": "object",
"properties": {
"creditMicros": {
"type": "integer",
"minimum": -9007199254740991,
"maximum": 9007199254740991
},
"activity": {
"type": "array",
"items": {
"type": "object",
"properties": {
"id": {
"type": "string",
"format": "uuid"
},
"kind": {
"type": "string",
"enum": [
"topup",
"usage",
"refund",
"adjustment",
"payout",
"chargeback"
]
},
"amountMicros": {
"type": "integer",
"minimum": -9007199254740991,
"maximum": 9007199254740991
},
"at": {
"type": "string",
"format": "date-time"
},
"rentalId": {
"anyOf": [
{
"type": "string",
"format": "uuid"
},
{
"type": "null"
}
]
},
"phone": {
"anyOf": [
{
"type": "object",
"properties": {
"brand": {
"type": "string"
},
"model": {
"type": "string"
}
},
"required": [
"brand",
"model"
],
"additionalProperties": false
},
{
"type": "null"
}
]
},
"postings": {
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
"note": {
"type": [
"string",
"null"
]
}
},
"required": [
"id",
"kind",
"amountMicros",
"at",
"rentalId",
"phone",
"postings",
"note"
],
"additionalProperties": false
}
},
"topUpAvailable": {
"type": "boolean"
}
},
"required": [
"creditMicros",
"activity",
"topUpAvailable"
],
"additionalProperties": false
}

Top-up amounts and limits.

Credit is bought on the website (Stripe Checkout); pocketshare topup links there.

Authentication: none (public).

Response 200:

Field Type Required Notes
available boolean yes
packs array of integer yes
currency "USD" yes
automaticTax boolean yes
testMode boolean yes
Response JSON Schema
{
"type": "object",
"properties": {
"available": {
"type": "boolean"
},
"packs": {
"type": "array",
"items": {
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
}
},
"currency": {
"type": "string",
"const": "USD"
},
"automaticTax": {
"type": "boolean"
},
"testMode": {
"type": "boolean"
}
},
"required": [
"available",
"packs",
"currency",
"automaticTax",
"testMode"
],
"additionalProperties": false
}

One top-up and its state.

Authentication: API key with billing:read.

Parameter In Type Required Notes
id path string (uuid) yes

Response 200:

Field Type Required Notes
id string (uuid) yes
status "pending", "succeeded", "failed", "expired" yes
amountMicros integer yes ≥ 0
receiptNumber string or null yes
creditMicros integer yes ≥ -9007199254740991
Response JSON Schema
{
"type": "object",
"properties": {
"id": {
"type": "string",
"format": "uuid"
},
"status": {
"type": "string",
"enum": [
"pending",
"succeeded",
"failed",
"expired"
]
},
"amountMicros": {
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
"receiptNumber": {
"type": [
"string",
"null"
]
},
"creditMicros": {
"type": "integer",
"minimum": -9007199254740991,
"maximum": 9007199254740991
}
},
"required": [
"id",
"status",
"amountMicros",
"receiptNumber",
"creditMicros"
],
"additionalProperties": false
}

Your receipts.

Authentication: API key with billing:read.

Response 200:

Field Type Required Notes
receipts array of object yes
Response JSON Schema
{
"type": "object",
"properties": {
"receipts": {
"type": "array",
"items": {
"type": "object",
"properties": {
"id": {
"type": "string",
"format": "uuid"
},
"number": {
"type": "string"
},
"issuedAt": {
"type": "string",
"format": "date-time"
},
"creditMicros": {
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
"taxMicros": {
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
"totalMicros": {
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
"refundedMicros": {
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
"disputedMicros": {
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
}
},
"required": [
"id",
"number",
"issuedAt",
"creditMicros",
"taxMicros",
"totalMicros",
"refundedMicros",
"disputedMicros"
],
"additionalProperties": false
}
}
},
"required": [
"receipts"
],
"additionalProperties": false
}

One receipt.

Authentication: API key with billing:read.

Parameter In Type Required Notes
id path string (uuid) yes

Response 200:

Field Type Required Notes
id string (uuid) yes
number string yes
issuedAt string (date-time) yes
currency "USD" yes
seller object yes
buyer object yes
lines array of object yes
subtotalMicros integer yes ≥ 0
taxMicros integer yes ≥ 0
totalMicros integer yes ≥ 0
payment object yes
refunds array of object yes
testMode boolean yes
Response JSON Schema
{
"type": "object",
"properties": {
"id": {
"type": "string",
"format": "uuid"
},
"number": {
"type": "string"
},
"issuedAt": {
"type": "string",
"format": "date-time"
},
"currency": {
"type": "string",
"const": "USD"
},
"seller": {
"type": "object",
"properties": {
"name": {
"type": "string"
},
"website": {
"type": "string",
"format": "uri"
}
},
"required": [
"name",
"website"
],
"additionalProperties": false
},
"buyer": {
"type": "object",
"properties": {
"businessName": {
"type": [
"string",
"null"
]
},
"taxId": {
"type": [
"string",
"null"
]
},
"addressLine1": {
"type": [
"string",
"null"
]
},
"addressLine2": {
"type": [
"string",
"null"
]
},
"city": {
"type": [
"string",
"null"
]
},
"region": {
"type": [
"string",
"null"
]
},
"postalCode": {
"type": [
"string",
"null"
]
},
"country": {
"type": [
"string",
"null"
]
},
"email": {
"type": "string"
}
},
"required": [
"businessName",
"taxId",
"addressLine1",
"addressLine2",
"city",
"region",
"postalCode",
"country",
"email"
],
"additionalProperties": false
},
"lines": {
"type": "array",
"items": {
"type": "object",
"properties": {
"description": {
"type": "string"
},
"amountMicros": {
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
}
},
"required": [
"description",
"amountMicros"
],
"additionalProperties": false
}
},
"subtotalMicros": {
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
"taxMicros": {
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
"totalMicros": {
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
"payment": {
"type": "object",
"properties": {
"provider": {
"type": "string",
"const": "stripe"
},
"reference": {
"type": [
"string",
"null"
]
}
},
"required": [
"provider",
"reference"
],
"additionalProperties": false
},
"refunds": {
"type": "array",
"items": {
"type": "object",
"properties": {
"id": {
"type": "string",
"format": "uuid"
},
"creditMicros": {
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
"amountMicros": {
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
"status": {
"type": "string",
"enum": [
"pending",
"succeeded",
"failed"
]
},
"at": {
"type": "string",
"format": "date-time"
}
},
"required": [
"id",
"creditMicros",
"amountMicros",
"status",
"at"
],
"additionalProperties": false
}
},
"testMode": {
"type": "boolean"
}
},
"required": [
"id",
"number",
"issuedAt",
"currency",
"seller",
"buyer",
"lines",
"subtotalMicros",
"taxMicros",
"totalMicros",
"payment",
"refunds",
"testMode"
],
"additionalProperties": false
}

Months with a credit statement.

Authentication: API key with billing:read.

Response 200:

Field Type Required Notes
months array of string yes
Response JSON Schema
{
"type": "object",
"properties": {
"months": {
"type": "array",
"items": {
"type": "string",
"pattern": "^20\\d{2}-(0[1-9]|1[0-2])$"
}
}
},
"required": [
"months"
],
"additionalProperties": false
}

Monthly credit statement.

Opening balance, every top-up, refund and adjustment, one line per rental for usage, and the closing balance of a UTC month (YYYY-MM), from the ledger. format=csv returns the same as a CSV download.

Authentication: API key with billing:read.

Parameter In Type Required Notes
month path string yes
format query "json", "csv"

Response 200:

Field Type Required Notes
account "renter_credit" yes
month string yes
start string (date-time) yes
end string (date-time) yes
generatedAt string (date-time) yes
openingBalanceMicros integer yes ≥ -9007199254740991
closingBalanceMicros integer yes ≥ -9007199254740991
totals object yes
lines array of object yes
Response JSON Schema
{
"type": "object",
"properties": {
"account": {
"type": "string",
"const": "renter_credit"
},
"month": {
"type": "string",
"pattern": "^20\\d{2}-(0[1-9]|1[0-2])$"
},
"start": {
"type": "string",
"format": "date-time"
},
"end": {
"type": "string",
"format": "date-time"
},
"generatedAt": {
"type": "string",
"format": "date-time"
},
"openingBalanceMicros": {
"type": "integer",
"minimum": -9007199254740991,
"maximum": 9007199254740991
},
"closingBalanceMicros": {
"type": "integer",
"minimum": -9007199254740991,
"maximum": 9007199254740991
},
"totals": {
"type": "object",
"propertyNames": {
"type": "string",
"enum": [
"topup",
"credit_grant",
"usage",
"rental_refund",
"goodwill",
"card_refund",
"card_refund_reversed",
"chargeback",
"adjustment"
]
},
"additionalProperties": {
"type": "integer",
"minimum": -9007199254740991,
"maximum": 9007199254740991
}
},
"lines": {
"type": "array",
"items": {
"type": "object",
"properties": {
"at": {
"type": "string",
"format": "date-time"
},
"category": {
"type": "string",
"enum": [
"topup",
"credit_grant",
"usage",
"rental_refund",
"goodwill",
"card_refund",
"card_refund_reversed",
"chargeback",
"adjustment"
]
},
"description": {
"type": "string"
},
"transactionId": {
"anyOf": [
{
"type": "string",
"format": "uuid"
},
{
"type": "null"
}
]
},
"rentalId": {
"anyOf": [
{
"type": "string",
"format": "uuid"
},
{
"type": "null"
}
]
},
"topupId": {
"anyOf": [
{
"type": "string",
"format": "uuid"
},
{
"type": "null"
}
]
},
"amountMicros": {
"type": "integer",
"minimum": -9007199254740991,
"maximum": 9007199254740991
},
"balanceMicros": {
"type": "integer",
"minimum": -9007199254740991,
"maximum": 9007199254740991
}
},
"required": [
"at",
"category",
"description",
"transactionId",
"rentalId",
"topupId",
"amountMicros",
"balanceMicros"
],
"additionalProperties": false
}
}
},
"required": [
"account",
"month",
"start",
"end",
"generatedAt",
"openingBalanceMicros",
"closingBalanceMicros",
"totals",
"lines"
],
"additionalProperties": false
}

Device sign-in for the CLI.

Start a device sign-in (CLI login).

Returns a user code to approve at verificationUri while signed in on the website; poll /v2/auth/device/token every interval seconds.

Authentication: none (public).

Request body:

Field Type Required Notes
clientName string yes at most 80 characters

Response 201:

Field Type Required Notes
deviceCode string yes
userCode string yes
verificationUri string yes
expiresIn integer yes ≥ -9007199254740991
interval integer yes ≥ -9007199254740991
Request JSON Schema
{
"type": "object",
"properties": {
"clientName": {
"type": "string",
"minLength": 1,
"maxLength": 80,
"pattern": "^[^\\p{Cc}]*$"
}
},
"required": [
"clientName"
],
"additionalProperties": false
}
Response JSON Schema
{
"type": "object",
"properties": {
"deviceCode": {
"type": "string"
},
"userCode": {
"type": "string"
},
"verificationUri": {
"type": "string"
},
"expiresIn": {
"type": "integer",
"minimum": -9007199254740991,
"maximum": 9007199254740991
},
"interval": {
"type": "integer",
"minimum": -9007199254740991,
"maximum": 9007199254740991
}
},
"required": [
"deviceCode",
"userCode",
"verificationUri",
"expiresIn",
"interval"
],
"additionalProperties": false
}

Poll a device sign-in.

Answers authorization_pending (400) until approved, slow_down when polled too often, then once with a new API key.

Authentication: none (public).

Request body:

Field Type Required Notes
deviceCode string yes at most 64 characters

Response 200:

Field Type Required Notes
apiKey string yes
prefix string yes
scopes array of "phones:read", "rentals:read", "rentals:write", "hubs:read", "hubs:write", "listings:write", "billing:read" yes
user object yes
Request JSON Schema
{
"type": "object",
"properties": {
"deviceCode": {
"type": "string",
"maxLength": 64
}
},
"required": [
"deviceCode"
],
"additionalProperties": false
}
Response JSON Schema
{
"type": "object",
"properties": {
"apiKey": {
"type": "string"
},
"prefix": {
"type": "string"
},
"scopes": {
"type": "array",
"items": {
"type": "string",
"enum": [
"phones:read",
"rentals:read",
"rentals:write",
"hubs:read",
"hubs:write",
"listings:write",
"billing:read"
]
}
},
"user": {
"type": "object",
"properties": {
"id": {
"type": "string",
"format": "uuid"
},
"email": {
"type": "string"
}
},
"required": [
"id",
"email"
],
"additionalProperties": false
}
},
"required": [
"apiKey",
"prefix",
"scopes",
"user"
],
"additionalProperties": false
}

Error codes: authorization_pending, slow_down, access_denied, expired_token.

Your hubs (hosts).

Authentication: API key with hubs:read.

Response 200:

Field Type Required Notes
hubs array of object yes
Response JSON Schema
{
"type": "object",
"properties": {
"hubs": {
"type": "array",
"items": {
"type": "object",
"properties": {
"id": {
"type": "string",
"format": "uuid"
},
"name": {
"type": "string"
},
"platform": {
"type": "string",
"enum": [
"linux-x64",
"linux-arm64",
"windows-x64"
]
},
"version": {
"type": "string"
},
"status": {
"type": "string",
"enum": [
"active",
"paused",
"revoked"
]
},
"online": {
"type": "boolean"
},
"lastSeenAt": {
"anyOf": [
{
"type": "string",
"format": "date-time"
},
{
"type": "null"
}
]
},
"phoneCount": {
"type": "integer",
"minimum": -9007199254740991,
"maximum": 9007199254740991
},
"createdAt": {
"type": "string",
"format": "date-time"
}
},
"required": [
"id",
"name",
"platform",
"version",
"status",
"online",
"lastSeenAt",
"phoneCount",
"createdAt"
],
"additionalProperties": false
}
}
},
"required": [
"hubs"
],
"additionalProperties": false
}

A single-use hub enrollment token (hosts).

Authentication: API key with hubs:write.

Request body:

Field Type Required Notes
kind "code", "file"

Response 201:

Field Type Required Notes
id string (uuid) yes
token string yes
expiresAt string (date-time) yes
file object
Request JSON Schema
{
"type": "object",
"properties": {
"kind": {
"type": "string",
"enum": [
"code",
"file"
]
}
},
"additionalProperties": false
}
Response JSON Schema
{
"type": "object",
"properties": {
"id": {
"type": "string",
"format": "uuid"
},
"token": {
"type": "string"
},
"expiresAt": {
"type": "string",
"format": "date-time"
},
"file": {
"type": "object",
"properties": {
"schema": {
"type": "string",
"const": "pocketshare-enroll/v1"
},
"token": {
"type": "string",
"maxLength": 64
},
"api": {
"type": "string",
"maxLength": 200,
"format": "uri"
},
"name": {
"type": "string",
"minLength": 1,
"maxLength": 100,
"pattern": "^[^\\p{Cc}]*$"
},
"expiresAt": {
"type": "string",
"format": "date-time"
}
},
"required": [
"schema",
"token",
"api"
],
"additionalProperties": false
}
},
"required": [
"id",
"token",
"expiresAt"
],
"additionalProperties": false
}

Your phones with health and checks (hosts).

Authentication: API key with hubs:read.

Response 200:

Field Type Required Notes
phones array of object yes
Response JSON Schema
{
"type": "object",
"properties": {
"phones": {
"type": "array",
"items": {
"type": "object",
"properties": {
"id": {
"type": "string",
"format": "uuid"
},
"hubId": {
"type": "string",
"format": "uuid"
},
"brand": {
"type": "string"
},
"manufacturer": {
"type": "string"
},
"model": {
"type": "string"
},
"device": {
"type": [
"string",
"null"
]
},
"buildFingerprint": {
"type": "string"
},
"androidVersion": {
"type": "string"
},
"apiLevel": {
"type": "integer",
"minimum": -9007199254740991,
"maximum": 9007199254740991
},
"abi": {
"type": "string"
},
"state": {
"type": "string",
"enum": [
"pending_review",
"available",
"rented",
"cleaning",
"quarantined",
"paused",
"offline",
"removed"
]
},
"stateReason": {
"type": [
"string",
"null"
]
},
"hasBaseline": {
"type": "boolean"
},
"online": {
"type": "boolean"
},
"listing": {
"anyOf": [
{
"type": "object",
"properties": {
"hourlyRateMicros": {
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
"downloadRateMicrosPerGb": {
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
"uploadRateMicrosPerGb": {
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
"visible": {
"type": "boolean"
}
},
"required": [
"hourlyRateMicros",
"downloadRateMicrosPerGb",
"uploadRateMicrosPerGb",
"visible"
],
"additionalProperties": false
},
{
"type": "null"
}
]
},
"securityPatch": {
"anyOf": [
{
"type": "string",
"format": "date",
"pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))$"
},
{
"type": "null"
}
]
},
"prerequisites": {
"anyOf": [
{
"type": "object",
"properties": {
"passed": {
"type": "boolean"
},
"checkedAt": {
"type": "string",
"format": "date-time"
},
"checks": {
"type": "array",
"items": {
"type": "object",
"properties": {
"name": {
"type": "string",
"pattern": "^[a-z][a-z0-9_]{1,63}$"
},
"passed": {
"type": "boolean"
},
"reason": {
"type": "string",
"pattern": "^[a-z][a-z0-9_]{1,63}$"
},
"detail": {
"type": "object",
"propertyNames": {
"type": "string",
"pattern": "^[a-zA-Z][a-zA-Z0-9_]{0,39}$"
},
"additionalProperties": {
"anyOf": [
{
"type": "string",
"maxLength": 200
},
{
"type": "number"
},
{
"type": "boolean"
}
]
}
}
},
"required": [
"name",
"passed"
],
"additionalProperties": false
}
}
},
"required": [
"passed",
"checkedAt",
"checks"
],
"additionalProperties": false
},
{
"type": "null"
}
]
},
"safetyHold": {
"anyOf": [
{
"type": "object",
"properties": {
"reason": {
"type": "string"
},
"since": {
"type": "string",
"format": "date-time"
}
},
"required": [
"reason",
"since"
],
"additionalProperties": false
},
{
"type": "null"
}
]
},
"health": {
"anyOf": [
{
"type": "object",
"properties": {
"reportedAt": {
"type": "string",
"format": "date-time"
},
"report": {
"type": "object",
"properties": {
"connection": {
"type": "string",
"enum": [
"device",
"unauthorized",
"offline",
"absent"
]
},
"battery": {
"anyOf": [
{
"type": "object",
"properties": {
"levelPercent": {
"anyOf": [
{
"type": "integer",
"minimum": 0,
"maximum": 100
},
{
"type": "null"
}
]
},
"health": {
"type": "string",
"enum": [
"good",
"overheat",
"dead",
"over_voltage",
"failure",
"cold",
"unknown"
]
},
"temperatureC": {
"anyOf": [
{
"type": "number",
"minimum": -50,
"maximum": 150
},
{
"type": "null"
}
]
},
"charging": {
"type": "boolean"
},
"powerSources": {
"maxItems": 4,
"type": "array",
"items": {
"type": "string",
"enum": [
"ac",
"usb",
"wireless",
"dock"
]
}
}
},
"required": [
"levelPercent",
"health",
"temperatureC",
"charging",
"powerSources"
],
"additionalProperties": false
},
{
"type": "null"
}
]
},
"storage": {
"anyOf": [
{
"type": "object",
"properties": {
"freeBytes": {
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
"totalBytes": {
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
}
},
"required": [
"freeBytes",
"totalBytes"
],
"additionalProperties": false
},
{
"type": "null"
}
]
},
"connectivity": {
"anyOf": [
{
"type": "object",
"properties": {
"transport": {
"type": "string",
"enum": [
"wifi",
"cellular",
"ethernet",
"vpn",
"bluetooth",
"none",
"unknown"
]
},
"validated": {
"type": [
"boolean",
"null"
]
},
"airplaneMode": {
"type": [
"boolean",
"null"
]
}
},
"required": [
"transport",
"validated",
"airplaneMode"
],
"additionalProperties": false
},
{
"type": "null"
}
]
},
"uptimeSeconds": {
"anyOf": [
{
"type": "integer",
"minimum": 0,
"maximum": 315360000
},
{
"type": "null"
}
]
},
"safety": {
"type": "object",
"properties": {
"hold": {
"type": "boolean"
},
"reasons": {
"maxItems": 7,
"type": "array",
"items": {
"type": "string",
"enum": [
"battery_temperature_high",
"battery_overheat",
"battery_dead",
"battery_over_voltage",
"battery_failure",
"battery_cold",
"host_stop"
]
}
}
},
"required": [
"hold",
"reasons"
],
"additionalProperties": false
},
"deviceOwner": {
"type": "object",
"properties": {
"active": {
"type": "boolean"
},
"uninstallBlocked": {
"type": "boolean"
},
"wifiLockdown": {
"type": "boolean"
},
"updatePolicy": {
"type": "string",
"enum": [
"none",
"automatic",
"windowed",
"postpone"
]
},
"updatePendingSinceMs": {
"anyOf": [
{
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
{
"type": "null"
}
]
},
"failure": {
"type": "string",
"pattern": "^[a-z][a-z0-9_]{1,63}$"
}
},
"required": [
"active",
"uninstallBlocked",
"wifiLockdown",
"updatePolicy",
"updatePendingSinceMs"
],
"additionalProperties": false
},
"link": {
"type": "object",
"properties": {
"transport": {
"type": "string",
"enum": [
"usb",
"wifi",
"other"
]
},
"adbRttMs": {
"anyOf": [
{
"type": "number",
"minimum": 0,
"maximum": 60000
},
{
"type": "null"
}
]
},
"tcpRttMs": {
"anyOf": [
{
"type": "number",
"minimum": 0,
"maximum": 60000
},
{
"type": "null"
}
]
},
"wifi": {
"anyOf": [
{
"type": "object",
"properties": {
"rssiDbm": {
"anyOf": [
{
"type": "integer",
"minimum": -127,
"maximum": 0
},
{
"type": "null"
}
]
},
"linkSpeedMbps": {
"anyOf": [
{
"type": "integer",
"minimum": 0,
"maximum": 100000
},
{
"type": "null"
}
]
},
"frequencyMhz": {
"anyOf": [
{
"type": "integer",
"minimum": 0,
"maximum": 100000
},
{
"type": "null"
}
]
}
},
"required": [
"rssiDbm",
"linkSpeedMbps",
"frequencyMhz"
],
"additionalProperties": false
},
{
"type": "null"
}
]
}
},
"required": [
"transport",
"adbRttMs",
"tcpRttMs",
"wifi"
],
"additionalProperties": false
}
},
"required": [
"connection",
"battery",
"storage",
"connectivity",
"uptimeSeconds",
"safety"
],
"additionalProperties": false
}
},
"required": [
"reportedAt",
"report"
],
"additionalProperties": false
},
{
"type": "null"
}
]
}
},
"required": [
"id",
"hubId",
"brand",
"manufacturer",
"model",
"device",
"buildFingerprint",
"androidVersion",
"apiLevel",
"abi",
"state",
"stateReason",
"hasBaseline",
"online",
"listing",
"securityPatch",
"prerequisites",
"safetyHold",
"health"
],
"additionalProperties": false
}
}
},
"required": [
"phones"
],
"additionalProperties": false
}

Set a phone’s hourly price and visibility (hosts).

Authentication: API key with listings:write.

Parameter In Type Required Notes
id path string (uuid) yes

Request body:

Field Type Required Notes
hourlyRateMicros integer yes ≥ 0
visible boolean yes
downloadRateMicrosPerGb integer ≥ 0
uploadRateMicrosPerGb integer ≥ 0

Response 200:

Field Type Required Notes
id string (uuid) yes
hubId string (uuid) yes
brand string yes
manufacturer string yes
model string yes
device string or null yes
buildFingerprint string yes
androidVersion string yes
apiLevel integer yes ≥ -9007199254740991
abi string yes
state "pending_review", "available", "rented", "cleaning", "quarantined", "paused", "offline", "removed" yes
stateReason string or null yes
hasBaseline boolean yes
online boolean yes
listing object or null yes
Request JSON Schema
{
"type": "object",
"properties": {
"hourlyRateMicros": {
"type": "integer",
"minimum": 0,
"maximum": 1000000000000
},
"visible": {
"type": "boolean"
},
"downloadRateMicrosPerGb": {
"type": "integer",
"minimum": 0,
"maximum": 1000000000000
},
"uploadRateMicrosPerGb": {
"type": "integer",
"minimum": 0,
"maximum": 1000000000000
}
},
"required": [
"hourlyRateMicros",
"visible"
],
"additionalProperties": false
}
Response JSON Schema
{
"type": "object",
"properties": {
"id": {
"type": "string",
"format": "uuid"
},
"hubId": {
"type": "string",
"format": "uuid"
},
"brand": {
"type": "string"
},
"manufacturer": {
"type": "string"
},
"model": {
"type": "string"
},
"device": {
"type": [
"string",
"null"
]
},
"buildFingerprint": {
"type": "string"
},
"androidVersion": {
"type": "string"
},
"apiLevel": {
"type": "integer",
"minimum": -9007199254740991,
"maximum": 9007199254740991
},
"abi": {
"type": "string"
},
"state": {
"type": "string",
"enum": [
"pending_review",
"available",
"rented",
"cleaning",
"quarantined",
"paused",
"offline",
"removed"
]
},
"stateReason": {
"type": [
"string",
"null"
]
},
"hasBaseline": {
"type": "boolean"
},
"online": {
"type": "boolean"
},
"listing": {
"anyOf": [
{
"type": "object",
"properties": {
"hourlyRateMicros": {
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
"downloadRateMicrosPerGb": {
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
"uploadRateMicrosPerGb": {
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
"visible": {
"type": "boolean"
}
},
"required": [
"hourlyRateMicros",
"downloadRateMicrosPerGb",
"uploadRateMicrosPerGb",
"visible"
],
"additionalProperties": false
},
{
"type": "null"
}
]
}
},
"required": [
"id",
"hubId",
"brand",
"manufacturer",
"model",
"device",
"buildFingerprint",
"androidVersion",
"apiLevel",
"abi",
"state",
"stateReason",
"hasBaseline",
"online",
"listing"
],
"additionalProperties": false
}

Pause or resume a phone (hosts).

Authentication: API key with hubs:write.

Parameter In Type Required Notes
id path string (uuid) yes

Request body:

Field Type Required Notes
paused boolean yes

Response 200:

Field Type Required Notes
id string (uuid) yes
hubId string (uuid) yes
brand string yes
manufacturer string yes
model string yes
device string or null yes
buildFingerprint string yes
androidVersion string yes
apiLevel integer yes ≥ -9007199254740991
abi string yes
state "pending_review", "available", "rented", "cleaning", "quarantined", "paused", "offline", "removed" yes
stateReason string or null yes
hasBaseline boolean yes
online boolean yes
listing object or null yes
Request JSON Schema
{
"type": "object",
"properties": {
"paused": {
"type": "boolean"
}
},
"required": [
"paused"
],
"additionalProperties": false
}
Response JSON Schema
{
"type": "object",
"properties": {
"id": {
"type": "string",
"format": "uuid"
},
"hubId": {
"type": "string",
"format": "uuid"
},
"brand": {
"type": "string"
},
"manufacturer": {
"type": "string"
},
"model": {
"type": "string"
},
"device": {
"type": [
"string",
"null"
]
},
"buildFingerprint": {
"type": "string"
},
"androidVersion": {
"type": "string"
},
"apiLevel": {
"type": "integer",
"minimum": -9007199254740991,
"maximum": 9007199254740991
},
"abi": {
"type": "string"
},
"state": {
"type": "string",
"enum": [
"pending_review",
"available",
"rented",
"cleaning",
"quarantined",
"paused",
"offline",
"removed"
]
},
"stateReason": {
"type": [
"string",
"null"
]
},
"hasBaseline": {
"type": "boolean"
},
"online": {
"type": "boolean"
},
"listing": {
"anyOf": [
{
"type": "object",
"properties": {
"hourlyRateMicros": {
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
"downloadRateMicrosPerGb": {
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
"uploadRateMicrosPerGb": {
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
"visible": {
"type": "boolean"
}
},
"required": [
"hourlyRateMicros",
"downloadRateMicrosPerGb",
"uploadRateMicrosPerGb",
"visible"
],
"additionalProperties": false
},
{
"type": "null"
}
]
}
},
"required": [
"id",
"hubId",
"brand",
"manufacturer",
"model",
"device",
"buildFingerprint",
"androidVersion",
"apiLevel",
"abi",
"state",
"stateReason",
"hasBaseline",
"online",
"listing"
],
"additionalProperties": false
}

Wipe a phone now (hosts).

Asks the hub to run the cleanup it runs after every rental: app data, recent tasks, clipboard, files, settings and apps back to the phone’s baseline, a reboot and the verification. The phone must be available, paused or quarantined after a failed cleanup, on an online hub; it is cleaning until the hub reports, then back where it was, or quarantined if a check failed. At most 6 wipes per phone an hour (429 too_many_wipes).

Authentication: API key with hubs:write.

Parameter In Type Required Notes
id path string (uuid) yes

Response 202:

Field Type Required Notes
cleanupRunId string (uuid) yes
phoneState "cleaning" yes
Response JSON Schema
{
"type": "object",
"properties": {
"cleanupRunId": {
"type": "string",
"format": "uuid"
},
"phoneState": {
"type": "string",
"const": "cleaning"
}
},
"required": [
"cleanupRunId",
"phoneState"
],
"additionalProperties": false
}

Months with an earnings statement (hosts).

Authentication: API key with hubs:read.

Response 200:

Field Type Required Notes
months array of string yes
Response JSON Schema
{
"type": "object",
"properties": {
"months": {
"type": "array",
"items": {
"type": "string",
"pattern": "^20\\d{2}-(0[1-9]|1[0-2])$"
}
}
},
"required": [
"months"
],
"additionalProperties": false
}

Monthly payables statement (hosts).

Opening balance, earnings per rental (never the renter), refunds and dispute reversals, payouts and the closing balance of a UTC month (YYYY-MM). format=csv returns a CSV download.

Authentication: API key with hubs:read.

Parameter In Type Required Notes
month path string yes
format query "json", "csv"

Response 200:

Field Type Required Notes
account "host_payable" yes
month string yes
start string (date-time) yes
end string (date-time) yes
generatedAt string (date-time) yes
openingBalanceMicros integer yes ≥ -9007199254740991
closingBalanceMicros integer yes ≥ -9007199254740991
totals object yes
lines array of object yes
Response JSON Schema
{
"type": "object",
"properties": {
"account": {
"type": "string",
"const": "host_payable"
},
"month": {
"type": "string",
"pattern": "^20\\d{2}-(0[1-9]|1[0-2])$"
},
"start": {
"type": "string",
"format": "date-time"
},
"end": {
"type": "string",
"format": "date-time"
},
"generatedAt": {
"type": "string",
"format": "date-time"
},
"openingBalanceMicros": {
"type": "integer",
"minimum": -9007199254740991,
"maximum": 9007199254740991
},
"closingBalanceMicros": {
"type": "integer",
"minimum": -9007199254740991,
"maximum": 9007199254740991
},
"totals": {
"type": "object",
"propertyNames": {
"type": "string",
"enum": [
"earnings",
"rental_refund",
"chargeback_reversal",
"chargeback_restored",
"payout",
"adjustment"
]
},
"additionalProperties": {
"type": "integer",
"minimum": -9007199254740991,
"maximum": 9007199254740991
}
},
"lines": {
"type": "array",
"items": {
"type": "object",
"properties": {
"at": {
"type": "string",
"format": "date-time"
},
"category": {
"type": "string",
"enum": [
"earnings",
"rental_refund",
"chargeback_reversal",
"chargeback_restored",
"payout",
"adjustment"
]
},
"description": {
"type": "string"
},
"transactionId": {
"anyOf": [
{
"type": "string",
"format": "uuid"
},
{
"type": "null"
}
]
},
"rentalId": {
"anyOf": [
{
"type": "string",
"format": "uuid"
},
{
"type": "null"
}
]
},
"topupId": {
"anyOf": [
{
"type": "string",
"format": "uuid"
},
{
"type": "null"
}
]
},
"amountMicros": {
"type": "integer",
"minimum": -9007199254740991,
"maximum": 9007199254740991
},
"balanceMicros": {
"type": "integer",
"minimum": -9007199254740991,
"maximum": 9007199254740991
}
},
"required": [
"at",
"category",
"description",
"transactionId",
"rentalId",
"topupId",
"amountMicros",
"balanceMicros"
],
"additionalProperties": false
}
}
},
"required": [
"account",
"month",
"start",
"end",
"generatedAt",
"openingBalanceMicros",
"closingBalanceMicros",
"totals",
"lines"
],
"additionalProperties": false
}

Service health.

Authentication: none (public).

Response 200:

Field Type Required Notes
version 2 yes
status "ok" yes
service "pocketshare-api-v2" yes
Response JSON Schema
{
"type": "object",
"properties": {
"version": {
"type": "number",
"const": 2
},
"status": {
"type": "string",
"const": "ok"
},
"service": {
"type": "string",
"const": "pocketshare-api-v2"
}
},
"required": [
"version",
"status",
"service"
],
"additionalProperties": false
}