Discoveries automatically explore a website or Android application by spawning multiple agents across several phases. Starting from a URL (web) or an APK (Android), agents map pages/screens, forms, and interactions, then the system identifies gaps and sends agents to explore further.
Overview
A discovery is an automated exploration of a website. You provide a starting URL and the system spawns multiple agents that navigate the site, cataloging every page, form, and interaction they find. The result is a structured map of the application that can be used to generate test tests.
Discoveries run in multiple phases. The first phase explores from the entry URL. After the agents finish, the system analyzes their findings, identifies unexplored areas and gated pages (areas behind login or authentication), and spawns a second wave of agents to cover the gaps. This continues for up to three phases, with up to three agents per phase, progressively building a more complete picture of the site.
Lifecycle
A discovery moves through several statuses: running (agents are actively exploring), building (the system is processing the findings from a phase and deciding whether to spawn more agents), and completed when all phases are done. It can also be stopped manually or failed if something goes wrong.
The final output is an app map: a structured JSON representation of all discovered pages, their relationships, forms, and interactive elements. This map is stored on the project and used as context for future agent runs and test generation.
Pipeline stage. pending/review_pending are waiting to be picked up; preparing/crawling/reviewing are running; completed/failed/canceled are terminal.
. Values: pending, preparing, crawling, review_pending, reviewing, completed, failed, canceled.
discoveries[].cancel_requested
boolean
A cancellation was requested; the run stops at its next safe point and moves to canceled.
discoveries[].failure_reason
string
Why the discovery failed, set exactly when status is failed.
discoveries[].stats
object
Summary of what the crawl did, written when the crawl ends.
discoveries[].stats.nodes
integer
discoveries[].stats.edges
integer
discoveries[].stats.duration_seconds
number
discoveries[].stats.actions_fired
integer
discoveries[].stats.failed_actions
integer
discoveries[].stats.lost
integer
discoveries[].stats.out_of_scope
integer
discoveries[].stats.skipped_known_hrefs
integer
discoveries[].stats.suppressed_near_dup
integer
discoveries[].stats.exit_reason
string
Why the crawl ended. Absent while the crawl is still running — progress stats are reported before there is a reason. Values: exhausted, max_states, max_duration, canceled.
discoveries[].stats.unreached_hrefs
string[]
In-scope links the crawl saw on some page but never landed on (scheme, host and path). The crawl's own account of what it did not cover.
discoveries[].stats.failed_action_samples
object[]
The first few actions the browser refused or the crawler could not return to, with the element and the driver's error, so a thin crawl can be diagnosed from the API alone.
discoveries[].app_description
string
Reviewer's best-effort description of the application.
discoveries[].created_at
date-time
discoveries[].updated_at
date-time
discoveries[].completed_at
date-time
next_cursor
uuid
POST/api/v1/discoveries
Start a discovery
Creates a discovery against the given entry URL and returns it in the pending state; a background coordinator then runs the pipeline — an optional login stage using the supplied credentials, a deterministic crawl, and a review producing suggested tests and findings. Poll GET /discoveries/{id} to follow progress. Credentials are write-only and never returned; supply non-sensitive test credentials only — they are shared with an LLM during login.
Request Body (application/json)
Field
Type
Required
Description
project_id
uuid
Yes
ID of the project this discovery belongs to
entry_url
uri
Yes
Absolute http(s) URL the crawl starts from
credentials
json
No
Write-only credentials for the login stage
preset
string
No
Crawler settings preset. server suits server-rendered applications, spa waits longer for client-side rendering, custom requires the settings object.
settings
json
No
Resolved crawler settings a discovery runs with. Returned on every discovery; accepted at creation only with the custom preset.
Pipeline stage. pending/review_pending are waiting to be picked up; preparing/crawling/reviewing are running; completed/failed/canceled are terminal.
. Values: pending, preparing, crawling, review_pending, reviewing, completed, failed, canceled.
cancel_requested
boolean
A cancellation was requested; the run stops at its next safe point and moves to canceled.
failure_reason
string
Why the discovery failed, set exactly when status is failed.
stats
object
Summary of what the crawl did, written when the crawl ends.
stats.nodes
integer
stats.edges
integer
stats.duration_seconds
number
stats.actions_fired
integer
stats.failed_actions
integer
stats.lost
integer
stats.out_of_scope
integer
stats.skipped_known_hrefs
integer
stats.suppressed_near_dup
integer
stats.exit_reason
string
Why the crawl ended. Absent while the crawl is still running — progress stats are reported before there is a reason. Values: exhausted, max_states, max_duration, canceled.
stats.unreached_hrefs
string[]
In-scope links the crawl saw on some page but never landed on (scheme, host and path). The crawl's own account of what it did not cover.
stats.failed_action_samples
object[]
The first few actions the browser refused or the crawler could not return to, with the element and the driver's error, so a thin crawl can be diagnosed from the API alone.
stats.failed_action_samples[].from_node
integer
stats.failed_action_samples[].url
string
stats.failed_action_samples[].tag
string
stats.failed_action_samples[].label
string
stats.failed_action_samples[].href
string
stats.failed_action_samples[].xpath
string
stats.failed_action_samples[].error
string
stats.failed_action_samples[].kind
string
Values: click, reposition, observe.
app_description
string
Reviewer's best-effort description of the application.
Pipeline stage. pending/review_pending are waiting to be picked up; preparing/crawling/reviewing are running; completed/failed/canceled are terminal.
. Values: pending, preparing, crawling, review_pending, reviewing, completed, failed, canceled.
cancel_requested
boolean
A cancellation was requested; the run stops at its next safe point and moves to canceled.
failure_reason
string
Why the discovery failed, set exactly when status is failed.
stats
object
Summary of what the crawl did, written when the crawl ends.
stats.nodes
integer
stats.edges
integer
stats.duration_seconds
number
stats.actions_fired
integer
stats.failed_actions
integer
stats.lost
integer
stats.out_of_scope
integer
stats.skipped_known_hrefs
integer
stats.suppressed_near_dup
integer
stats.exit_reason
string
Why the crawl ended. Absent while the crawl is still running — progress stats are reported before there is a reason. Values: exhausted, max_states, max_duration, canceled.
stats.unreached_hrefs
string[]
In-scope links the crawl saw on some page but never landed on (scheme, host and path). The crawl's own account of what it did not cover.
stats.failed_action_samples
object[]
The first few actions the browser refused or the crawler could not return to, with the element and the driver's error, so a thin crawl can be diagnosed from the API alone.
stats.failed_action_samples[].from_node
integer
stats.failed_action_samples[].url
string
stats.failed_action_samples[].tag
string
stats.failed_action_samples[].label
string
stats.failed_action_samples[].href
string
stats.failed_action_samples[].xpath
string
stats.failed_action_samples[].error
string
stats.failed_action_samples[].kind
string
Values: click, reposition, observe.
app_description
string
Reviewer's best-effort description of the application.
Requests cancellation of a non-terminal discovery. Cancellation is asynchronous: the run stops at its next safe point and moves to the canceled state. The response echoes the discovery with cancel_requested set; poll GET /discoveries/{id} for the terminal state.
Parameters
Parameter
Type
In
Required
Description
id
uuid
path
Yes
Discovery ID.
Example Request
curl
curl -X POST "http://app.aiqaramba.com/api/v1/discoveries/<id>/cancel" \
-H "Authorization: Bearer $AIQA_API_KEY"
Status Codes
Code
Description
200
Discovery canceled.
400
The request is malformed or failed validation.
401
Authentication is missing or invalid.
404
The requested resource does not exist.
409
The request conflicts with the current resource state.
500
The server could not complete the request.
Response Fields (200)
Field
Type
Description
id
uuid
tenant_id
uuid
project_id
uuid
entry_url
uri
preset
string
Values: server, spa, custom.
settings
object
Resolved crawler settings a discovery runs with. Returned on every discovery; accepted at creation only with the custom preset.
settings.max_states
integer
State budget of the crawl.
settings.max_depth
integer
Maximum exploration depth from the entry state; 0 means unlimited.
settings.max_duration_seconds
integer
Wall-clock budget of the crawl.
settings.settle_navigate_ms
integer
Wait after a navigation before observing the page.
Pipeline stage. pending/review_pending are waiting to be picked up; preparing/crawling/reviewing are running; completed/failed/canceled are terminal.
. Values: pending, preparing, crawling, review_pending, reviewing, completed, failed, canceled.
cancel_requested
boolean
A cancellation was requested; the run stops at its next safe point and moves to canceled.
failure_reason
string
Why the discovery failed, set exactly when status is failed.
stats
object
Summary of what the crawl did, written when the crawl ends.
stats.nodes
integer
stats.edges
integer
stats.duration_seconds
number
stats.actions_fired
integer
stats.failed_actions
integer
stats.lost
integer
stats.out_of_scope
integer
stats.skipped_known_hrefs
integer
stats.suppressed_near_dup
integer
stats.exit_reason
string
Why the crawl ended. Absent while the crawl is still running — progress stats are reported before there is a reason. Values: exhausted, max_states, max_duration, canceled.
stats.unreached_hrefs
string[]
In-scope links the crawl saw on some page but never landed on (scheme, host and path). The crawl's own account of what it did not cover.
stats.failed_action_samples
object[]
The first few actions the browser refused or the crawler could not return to, with the element and the driver's error, so a thin crawl can be diagnosed from the API alone.
stats.failed_action_samples[].from_node
integer
stats.failed_action_samples[].url
string
stats.failed_action_samples[].tag
string
stats.failed_action_samples[].label
string
stats.failed_action_samples[].href
string
stats.failed_action_samples[].xpath
string
stats.failed_action_samples[].error
string
stats.failed_action_samples[].kind
string
Values: click, reposition, observe.
app_description
string
Reviewer's best-effort description of the application.
created_at
date-time
updated_at
date-time
completed_at
date-time
GET/api/v1/discoveries/{id}/map
Get the crawled map
Returns the state-flow graph discovered so far: one node per distinct UI state, one edge per observed transition. Available while the crawl is still running — nodes and edges appear as they are discovered.
Number of clickable elements extracted from the state.
nodes[].near_duplicate_of
integer
nodes[].near_dup_distance
number
nodes[].console_error_count
integer
SEVERE console entries captured when the state was first observed.
nodes[].discovered_at
date-time
edges
object[]
edges[].from_node
integer
edges[].to_node
integer
edges[].tag
string
edges[].label
string
GET/api/v1/discoveries/{id}/suggestions
List a discovery's suggestions
Returns the reviewer's drafted tests and findings for a discovery. Populated once the review stage completes; empty before then. These are drafts — accepting one into a real test or finding is a separate action.