Skip to content

Instantly share code, notes, and snippets.

@garymm
Last active November 28, 2022 19:01
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save garymm/99aa012f2d77e8f33a4a81682767f550 to your computer and use it in GitHub Desktop.
Save garymm/99aa012f2d77e8f33a4a81682767f550 to your computer and use it in GitHub Desktop.
set -o errexit
set -o nounset
set -o pipefail
# get ACCESS_KEY and SECRETY_KEY from ~/clearml.conf
CLEARML_TOKEN=$(curl --request GET -u "${ACCESS_KEY}:${SECRET_KEY}" -H "Accept: application/json" -H "Content-Type: application/json" https://api.clear.ml/auth.login | jq --raw-output .data.token)
# Got the project ID from a URL in the web UI
curl --request POST \
-H "Accept: application/json" \
-H "Content-Type: application/json" \
-H "Authorization: Bearer $CLEARML_TOKEN" \
--data '{"project": "b31c2fdffb1c47f690e0d27ff9bc8ee7"}' \
https://api.clear.ml/projects.get_by_id | jq
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment