Skip to main content

Update a Dynamic Analysis of an API with the REST API

You can use the Dynamic Analysis API to update an analysis of a REST API. In your request, you specify the ID of the target analysis.

To complete this task:

  1. Edit the values in your JSON payload.

  2. To get a list of analyses by name, send the following request:

    http --auth-type=veracode_hmac GET ""
  3. To get the analysis_id for an analysis, send the following request, where name is the name of the target analysis:

    http --auth-type=veracode_hmac GET "{name}"
  4. To apply the changes in your JSON payload to the analysis, send the following request:

    http --auth-type=veracode_hmac PUT "{analysis_id}?method=PATCH" < input.json

    The following example payload specifies to:

    • Add a new scan for the API specification specified for the spec_id property. For more information, see Get API Specification Details.
    • Delete the scan specified for the scan_id property.
    • Start scanning on the date and time specified for the schedule property, and run for two days.
    "scans": [
    "action_type": "ADD",
    "request_id": "0",
    "scan_config_request": {
    "api_scan_setting": {
    "spec_id": "{ID_of_your_API_specification}"
    "target_url": {
    "url": ""
    "action_type": "REMOVE",
    "scan_id": "{ID_of_scan}"
    "schedule": {
    "duration": {
    "length": 2,
    "unit": "DAY"
    "now": false,
    "schedule_status": "ACTIVE",
    "start_date": "2023-04-21T12:12:11-04:00"