This web service get a json from an url then parse it with jq (check https://github.com/stedolan/jq). We use it for rundeck which accept specific json format.
Docker image available here https://hub.docker.com/r/thecampagnards/jq-api/. Run the service with this command:
docker run -p 8080:8080 thecampagnards/jq-api
Api params, can be url encoded:
url
: the url of your jsonjq
: the jq query
The headers, body and request type used to request the api will be used to request the url
.
Example :
curl 'http://localhost:8080?jq=.tags&url=https://mydockerregistry.com/v2/alpine/tags/list'
> ["latest","v0.28.3"]