Link Dynamic Analysis Results to an Application

Veracode APIs

This use case scenario provides the Dynamic Analysis commands and payload for linking the results of a Dynamic Analysis to a Veracode application.

To link analysis results to an application:
  1. Run this command to find your application by name and obtain its UUID:
    http --auth-type=veracode_hmac GET https://api.veracode.com/was/configservice/v1/platform_applications
    You can also get application details by making a GET call to the Applications API.
  2. Run this command to create an analysis that links the results to the specified UUID for your application:
    http --auth-type=veracode_hmac POST https://api.veracode.com/was/configservice/v1/analyses
The API passes the JSON file that you populate with the necessary values as shown in this example payload:
{
  "name": "Veracode API applink",
  "scans": [
    {
      "linked_platform_app_uuid": "abcd1234-e6d0-475d-ac70-abff5388fa75",
      "scan_config_request": {
        "target_url": {
          "url": "http://www.example.com/",
          "http_and_https": true,
          "directory_restriction_type": "DIRECTORY_AND_SUBDIRECTORY"
        }
      }
    }
  ],
  "schedule": {
    "now": true,
    "duration": {
      "length": 1,
      "unit": "DAY"
    }
  }
}         
This example links the application UUID specified for linked_platform_app_uuid to the scan results from the target URL configuration specified for target_url.