You’re welcome and happy to hear it!
As for the API side of things, we have some examples of utilizing the API in bash scripts here:
Hi There!
Recently the Support team created a script for easily getting the total number of credits used on a workflow. This was created since the insights endpoint for workflow credits is scoped per branch, which means you need to do an API call per branch to get this information.
This script will likely need to be modified to be used for your purposes, but should be a good starting point!
A few notes/caveats:
It will only look at branches from the last 100 builds
The credit data that is r…
And here:
Hi There!
Recently the Support team created a script for easily getting artifacts from a pipeline. This was created since the artifacts are associated with the jobs in the pipeline, it requires finding the jobs and returning the results.
This script will likely need to be modified to be used for your purposes, but should be a good starting point!
A few notes/caveats:
It is not setup for pagination, so if you have a lot of jobs associated with your workflows you may need to update to account…
And here:
Hello Everyone!
Recently the Support team created a script for determining who triggered a workflow by using our v2 API. Feel free to mix up the script how ever you best see fit!
Note: We’re making us of jq which makes using JSON in scripts possible
Also, if you have an environment variable set with your CIRCLE_API_TOKEN, feel free to delete the variable declaration line from the script!
#!/bin/bash -e
# This script will return the user who started a workflow
# Can be called with "sh name_o…
We also have a thing called CircleCI Academy that has a “General Developer” course that includes information on utilizing the API, you can signup and access here:
Hope that helps!
3 Likes