fortify / fcli

fcli is a command-line utility for interacting with various Fortify products
https://fortify.github.io/fcli/
Other
27 stars 16 forks source link

`fcli * action`: Add paging & transformation capabilities to custom request targets #541

Open rsenden opened 1 month ago

rsenden commented 1 month ago

The addRequestTargets instruction currently doesn't allow for configuring paging-related functionality or generic input transformations. We should add configuration properties, for example based on SpEL expressions that given a full response (headers, body, ...) can extract the next page URL, or given the full response body, can extract a particular property. For example:

addRequestTargets:
  - name: github
     baseUrl: ...
     headers: ...
     nextPage: ${headers['Link'].next} # Given that this is a composite header, we'd need some easy way to extract the `rel="next"` element
     transform: ${body.data}