kifas.session.status
kifas.session.status
Section titled “kifas.session.status”Poll the status of an async session.create. Returns status=“acquiring” while the orchestrator is acquiring the underlying resource (DF RemoteAccessSession for mobile, no-op short-circuit for browser); status=“ready” with the connect/Appium endpoint info once acquisition completes; status=“failed” with an error message on failure. An Android emulator request that is waiting for a device returns status=“queued” with a plain-language message and a queue object (reason, position, gives_up_at). The recommended polling interval is 2-3s; a queued request can wait up to 10 minutes; queue.gives_up_at says when Kifas stops trying.
Required scopes: session:create
Parameters
Section titled “Parameters”| Name | Type | Required | Default | Description |
|---|---|---|---|---|
session_id |
string |
yes | — |
Returns
Section titled “Returns”{ "type": "object", "properties": { "session_id": { "type": "string", "format": "uuid", "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$" }, "status": { "type": "string", "enum": [ "queued", "acquiring", "ready", "failed" ] }, "appium_endpoint": { "type": "string" }, "live_preview_url": { "type": "string" }, "connect_url": { "type": "string", "format": "uri" }, "df_arn": { "type": "string" }, "app_package": { "type": "string" }, "app_activity": { "type": "string" }, "error": { "type": "string" }, "message": { "type": "string" }, "queue": { "type": "object", "properties": { "reason": { "type": "string", "enum": [ "device", "starting_devices", "org_limit", "at_capacity" ] }, "position": { "anyOf": [ { "type": "integer", "exclusiveMinimum": 0, "maximum": 9007199254740991 }, { "type": "null" } ] }, "org_running": { "type": "integer", "minimum": 0, "maximum": 9007199254740991 }, "org_limit": { "type": "integer", "minimum": 0, "maximum": 9007199254740991 }, "typical_wait_s": { "anyOf": [ { "type": "array", "items": [ { "type": "number" }, { "type": "number" } ], "additionalItems": false, "minItems": 2, "maxItems": 2 }, { "type": "null" } ] }, "gives_up_at": { "anyOf": [ { "type": "string", "format": "date-time", "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])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$" }, { "type": "null" } ] } }, "required": [ "reason", "position", "org_running", "org_limit", "typical_wait_s", "gives_up_at" ], "additionalProperties": false } }, "required": [ "session_id", "status" ], "additionalProperties": false}Code samples
Section titled “Code samples”TypeScript (Anthropic MCP SDK)
import { Client } from '@modelcontextprotocol/sdk/client/index.js'import { StreamableHTTPClientTransport } from '@modelcontextprotocol/sdk/client/streamable-http.js'
const transport = new StreamableHTTPClientTransport( new URL('https://mcp.kifas.io/'), { requestInit: { headers: { Authorization: `Bearer ${process.env.KIFAS_API_KEY}` }, }, },)const client = new Client({ name: 'demo', version: '0.1.0' })await client.connect(transport)
const result = await client.callTool({ name: 'kifas.session.status', arguments: { "session_id": "00000000-0000-0000-0000-000000000000" },})console.log(result)Python (httpx, raw JSON-RPC)
import osimport httpx
resp = httpx.post( "https://mcp.kifas.io/", headers={ "Authorization": f"Bearer {os.environ['KIFAS_API_KEY']}", "Content-Type": "application/json", }, json={ "jsonrpc": "2.0", "id": 1, "method": "tools/call", "params": { "name": "kifas.session.status", "arguments": { "session_id": "00000000-0000-0000-0000-000000000000" }, }, },)print(resp.json())curl
curl https://mcp.kifas.io/ \ -H "Authorization: Bearer $KIFAS_API_KEY" \ -H "Content-Type: application/json" \ -d '{ "jsonrpc": "2.0", "id": 1, "method": "tools/call", "params": { "name": "kifas.session.status", "arguments": { "session_id": "00000000-0000-0000-0000-000000000000" } }}'Raw JSON-RPC body
{ "jsonrpc": "2.0", "id": 1, "method": "tools/call", "params": { "name": "kifas.session.status", "arguments": { "session_id": "00000000-0000-0000-0000-000000000000" } }}Try it
Section titled “Try it”Want to try kifas.session.status? Sign in to the dashboard and run it against a real session.