API access to perf results #406
-
I'm trying to call the Bencher REST API to access performance metrics directly, following the API docs here: https://bencher.dev/docs/api/projects/perf/#get-v0projectsprojectperf So far I've not been able to construct a valid URL. First it seems all of the query parameters are required. Omitting any query parameter produces an error response like the following:
The But even when I provide all of them, I'm getting an error response that seems to be about url encoding:
As far as I can tell, the argument is correctly URL encoded. Other variations suggest the argument is being correctly decoded, but somehow it's still unhappy with the value:
Any idea what's going on there? |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment
-
@eddyashton sorry you're running into trouble. You have to use the UUIDs for the So something like this should work: https://api.bencher.dev/v0/projects/ccf/perf?branches=d5004f0a-5dbe-42bb-a821-1f55704d6ec2&testbeds=1e6f6a27-eb58-4f16-8d01-0148fbaed70e&benchmarks=3bae8305-29e0-4e5f-8157-01f8f471b408&measures=bc9fb376-9a85-478a-97fd-ebd7703c9663 The Bencher Console Perf Query UI query param API is a super set of the Bencher server API. So you can always just copy and paste everything after the Great point on adding |
Beta Was this translation helpful? Give feedback.
@eddyashton sorry you're running into trouble.
You have to use the UUIDs for the
branches
,testbeds
,benchmarks
, andmeasures
query params.So something like this should work: https://api.bencher.dev/v0/projects/ccf/perf?branches=d5004f0a-5dbe-42bb-a821-1f55704d6ec2&testbeds=1e6f6a27-eb58-4f16-8d01-0148fbaed70e&benchmarks=3bae8305-29e0-4e5f-8157-01f8f471b408&measures=bc9fb376-9a85-478a-97fd-ebd7703c9663
The Bencher Console Perf Query UI query param API is a super set of the Bencher server API. So you can always just copy and paste everything after the
?
in your URL and be able to hit (in your case) https://api.bencher.dev/v0/projects/ccf/perf with it.The additional UI specific query para…