List cost estimations
Returns your organisation’s cost estimations, most recent first. Page through them with offset-based pagination.
Note
Unlike most list endpoints, cost estimations use offset-based pagination (limit and offset) instead of page and limit. Pagination, filtering, and sorting covers the general conventions.
Request
GET /cost-estimations
Send an API key with the read scope in the X-Api-Key header.
Query parameters
| Parameter | Description |
|---|---|
limitnumber | |
offsetnumber |
Responses
200 OK
| Field | Description |
|---|---|
dataarray of object, required | |
data[].string, required | Estimation UUID. |
data[].string, required | Organization UUID. |
data[].string, required | User UUID. |
data[].string | Friendly name for this estimation. |
data[].string, required | Task identifier. |
data[].string, required | Estimation status. One of pending, running, completed, partial, or failed. |
data[].array of object, required | Input repositories. |
data[].repos[].string | Source type. One of connected, public, or upload. |
data[].repos[].string | Repository URL. |
data[].repos[].string | Branch name. |
data[].repos[].string | Resolved commit SHA. |
data[].repos[].string | Archive ID (for upload sources). |
data[].number | Total estimated credits across all repos. |
data[].array of object | Per-repo estimation results. |
data[].repo_results[].string, required | Repository URL. |
data[].repo_results[].string | Branch name. |
data[].repo_results[].string | Commit SHA. |
data[].repo_results[].string, required | Result status. One of completed or failed. |
data[].repo_results[].boolean, required | Whether result was served from cache. |
data[].repo_results[].array of object | Detected applications. |
data[].repo_results[].applications[].string, required | Application name. |
data[].repo_results[].applications[].string, required | Application root path. |
data[].repo_results[].applications[].string | Architecture description. |
data[].repo_results[].number | Estimated credits for this repo. |
data[].repo_results[].string | Error message (when status is failed). |
data[].repo_results[].string | Structured failure reason. One of unsupported_language or scope_no_match. |
data[].repo_results[].array of string | Detected unsupported languages among the top languages. |
data[].repo_results[].number | Files that matched the repository’s whitebox scope rules, counted on disk before analysis. Absent for unscoped repositories. |
data[].repo_results[].number | Non-blank lines of code in the files the engine indexes. |
data[].repo_results[].number | Non-whitespace bytes of code used to calculate the quote. |
data[].repo_results[].object | Lines of code and allocated credits per folder. |
data[].repo_results[].loc_tree.string, required | Folder name. |
data[].repo_results[].loc_tree.string, required | Folder path from the repository root; surplus subfolders fold into a row whose path ends in an ellipsis. |
data[].repo_results[].loc_tree.number, required | Non-blank lines of code in the folder, including subfolders. |
data[].repo_results[].loc_tree.number | Non-whitespace bytes of code in the folder, including subfolders. |
data[].repo_results[].loc_tree.number | Credits allocated to the folder; subfolders share them by bytes and the folder’s own files keep the rest, so they can add up to less. |
data[].repo_results[].loc_tree.array of object, required | Subfolders, largest first. Each child has the same fields as loc_tree. |
data[].string | Error message. |
data[].boolean, required | Whether human triage is mandatory for a scan of this estimation (large app, above the predicted-cost threshold). The customer cannot opt out when true. |
data[].number, required | Triage fee in credits (a percentage of the scan base credits) added when triage is enabled. |
data[].string (date-time), required | Timestamp when estimation was created. |
data[].string (date-time), required | Timestamp when estimation was last updated. |
totalnumber, required |