start_pentest_job
async
¶
start_pentest_job(
agent_space_id: str,
pentest_id: str,
*,
config_overrides: Optional[AsyncSecurityAgentClientConfig] = None,
job_type: Optional[JobType] = None,
selected_finding_ids: Optional[StringList] = None,
scope_changes: Optional[ScopeChangeList] = None,
) -> StartPentestJobOutput
Starts a new pentest job for a pentest configuration. The job executes the security tests defined in the pentest.
Parameters:
-
agent_space_id(str) –The unique identifier of the agent space.
-
pentest_id(str) –The unique identifier of the pentest to start a job for.
-
job_type(Optional[JobType], default:None) –The type of pentest job to start. Valid values are FULL, REVALIDATION, and CICD. When set to REVALIDATION, the selectedFindingIds parameter is required. When set to CICD, the scopeChanges parameter defines the code changes to test.
-
selected_finding_ids(Optional[StringList], default:None) –The list of finding identifiers to revalidate. Required when jobType is REVALIDATION. Each finding must belong to the same agent space and pentest.
-
scope_changes(Optional[ScopeChangeList], default:None) –The code changes that define the scope of a CI/CD pentest job. Provide this when starting a job with jobType CICD to test only the changes in the current pipeline run.
Raises:
-
UnknownServiceError–The service returned an error code this client does not model.
Source code in docs_src/capo_securityagent/_services/async_security_agent.py
4240 4241 4242 4243 4244 4245 4246 4247 4248 4249 4250 4251 4252 4253 4254 4255 4256 4257 4258 4259 4260 4261 4262 4263 4264 4265 4266 4267 4268 4269 4270 4271 4272 4273 4274 4275 4276 4277 4278 4279 4280 4281 4282 4283 4284 4285 4286 4287 4288 4289 4290 4291 4292 4293 4294 4295 4296 4297 4298 4299 4300 4301 4302 | |