curl --request GET \
--url https://api.anchorbrowser.io/v1/identities/dynamic/state/{session_id} \
--header 'anchor-api-key: <api-key>'import requests
url = "https://api.anchorbrowser.io/v1/identities/dynamic/state/{session_id}"
headers = {"anchor-api-key": "<api-key>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {'anchor-api-key': '<api-key>'}};
fetch('https://api.anchorbrowser.io/v1/identities/dynamic/state/{session_id}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.anchorbrowser.io/v1/identities/dynamic/state/{session_id}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"anchor-api-key: <api-key>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.anchorbrowser.io/v1/identities/dynamic/state/{session_id}"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("anchor-api-key", "<api-key>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api.anchorbrowser.io/v1/identities/dynamic/state/{session_id}")
.header("anchor-api-key", "<api-key>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.anchorbrowser.io/v1/identities/dynamic/state/{session_id}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["anchor-api-key"] = '<api-key>'
response = http.request(request)
puts response.read_body{
"session_id": "<string>",
"graph_id": 123,
"current_step_id": "<string>",
"discovery_status": "in_progress",
"phase": "navigating",
"updated_at": 123,
"nav": {
"status": "pending",
"error": "<string>",
"credentials_rejected": true
},
"discovery_error": "<string>",
"target": {
"step_id": "<string>",
"label": "<string>"
},
"view": {
"session_id": "<string>",
"host": "<string>",
"current_step_label": "<string>",
"step_id": "<string>",
"cdp_url": "<string>",
"live_view_url": "<string>",
"type": "decision",
"options": [
{
"step_id": "<string>",
"label": "<string>",
"automatable": true
}
],
"discovery_error": "<string>"
}
}{
"error": {
"code": 123,
"message": "<string>"
}
}{
"error": {
"code": 123,
"message": "<string>"
}
}Get Dynamic Auth Flow State
Read-only snapshot of an in-progress dynamic auth flow. Does not acquire the flow lock or mutate state.
Poll this endpoint when:
- start/resolve returned
type: detection_failedwithretryable: true(the next login step is still being determined and may take longer than the request timeout) - start/resolve timed out or returned 409 while a transition is in flight
- you need the current presentation without submitting an answer
view is that presentation — the same object start/resolve return. Treat it
as the live step when phase is settled. While phase is navigating,
view may already describe the next step; target is only a progress
label for the in-flight transition.
Keep polling until view.type is decision, form, authenticated, a
non-retryable detection_failed, or a non-retryable failed. Then call
/resolve only for decision/form, /finalize for authenticated, or
open live_view_url for detection_failed.
curl --request GET \
--url https://api.anchorbrowser.io/v1/identities/dynamic/state/{session_id} \
--header 'anchor-api-key: <api-key>'import requests
url = "https://api.anchorbrowser.io/v1/identities/dynamic/state/{session_id}"
headers = {"anchor-api-key": "<api-key>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {'anchor-api-key': '<api-key>'}};
fetch('https://api.anchorbrowser.io/v1/identities/dynamic/state/{session_id}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.anchorbrowser.io/v1/identities/dynamic/state/{session_id}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"anchor-api-key: <api-key>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.anchorbrowser.io/v1/identities/dynamic/state/{session_id}"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("anchor-api-key", "<api-key>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api.anchorbrowser.io/v1/identities/dynamic/state/{session_id}")
.header("anchor-api-key", "<api-key>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.anchorbrowser.io/v1/identities/dynamic/state/{session_id}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["anchor-api-key"] = '<api-key>'
response = http.request(request)
puts response.read_body{
"session_id": "<string>",
"graph_id": 123,
"current_step_id": "<string>",
"discovery_status": "in_progress",
"phase": "navigating",
"updated_at": 123,
"nav": {
"status": "pending",
"error": "<string>",
"credentials_rejected": true
},
"discovery_error": "<string>",
"target": {
"step_id": "<string>",
"label": "<string>"
},
"view": {
"session_id": "<string>",
"host": "<string>",
"current_step_label": "<string>",
"step_id": "<string>",
"cdp_url": "<string>",
"live_view_url": "<string>",
"type": "decision",
"options": [
{
"step_id": "<string>",
"label": "<string>",
"automatable": true
}
],
"discovery_error": "<string>"
}
}{
"error": {
"code": 123,
"message": "<string>"
}
}{
"error": {
"code": 123,
"message": "<string>"
}
}Authorizations
API key for your Anchor Browser account, sent as the anchor-api-key header on every
request. Create one at app.anchorbrowser.io (API Access),
or obtain one programmatically via the unauthenticated agent-access flow
(POST /v1/agent-access).
Path Parameters
Session whose auth flow state to read.
Response
Current auth flow state
Poll this after retryable detection_failed, a request timeout, or 409.
view is the same presentation start/resolve return (type discriminant).
When phase is settled, it is the current step. When phase is navigating,
it may already describe the next step so you can render (or answer) before the
browser finishes moving; it is omitted until there is something to show.
Call /resolve only when view.type is decision or form.
Internal identifier for this auth flow.
Identifier of the step the flow last committed. While phase is navigating,
view may already describe a later step.
Whether automatic detection of the login steps is still running.
in_progress, complete, failed navigating — a browser transition is in flight; view may already be the next step.
settled — idle at a step; view is that step.
navigating, settled Unix epoch milliseconds of the last state change.
Outcome of the latest navigation operation.
Show child attributes
Show child attributes
Step the browser is moving toward. Present only while phase is navigating.
Use for progress copy (for example "Preparing {label}…"). Not a second
presentation — view is what to show.
Show child attributes
Show child attributes
What to render or answer. Same shape as start/resolve, derived read-only.
phase: settled— the current step.phase: navigating— the upcoming step, when known; omitted until then.
- decision
- form
- detection_failed
- authenticated
- failed
Show child attributes
Show child attributes
Was this page helpful?

