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
4138 4139 4140 4141 4142 4143 4144 4145 4146 4147 4148 4149 4150 4151 4152 4153 4154 4155 4156 4157 4158 4159 4160 4161 4162 4163 4164 4165 4166 4167 4168 4169 4170 4171 4172 4173 4174 4175 4176 4177 4178 4179 4180 4181 4182 4183 4184 4185 4186 4187 4188 4189 4190 4191 4192 4193 4194 4195 4196 4197 4198 4199 4200 | |