Simulate

Workspaces Policies Simulate List

Simulates the execution of a Policy to verify its behavior without taking any actions. This endpoint evaluates all packages in the workspace, generating a "decision log" for each evaluation. Each log contains: - Package metadata provided to the policy engine at runtime. - Output from the user-defined Rego policy. No actions associated with the policy are executed. Instead, the endpoint reports what would happen to each package if the policy were active.

Request

gethttps://api.cloudsmith.io/v2/workspaces/{workspace}/policies/{policy}/simulate
Path params
policy
string
required
workspace
string
required
Query params
package_query_string
string
A [package search](https://help.cloudsmith.io/docs/search-packages) query by which to filter the packages being evaluated.
page
integer
A page number within the paginated result set.
page_size
integer
Number of results to return per page.

Response

Responses

Response body

object

object

results
array of objects
required