Using the Metrics API you can retrieve metrics for a synthetic job by specifying an application name and metric path as input parameters.
The Metrics API also supports wildcards in the metric path.
For example:
{{base_url}}/controller/rest/applications/{{application_name}}/metric-data?metric-path=Application Infrastructure Performance|*|Agent|App|Availability&time-range-type=BEFORE_NOW&duration-in-mins=15