Finished clone script

This commit is contained in:
2025-10-03 10:09:04 -04:00
parent 8006b35d21
commit 1508078efb
2 changed files with 79 additions and 42 deletions

View File

@@ -184,6 +184,13 @@ rest_api_post () {
check_http_error
}
rest_api_post_file () {
check_get_token
http_response=$(curl -s -k -o /tmp/rbkresponse.$$ -w "%{http_code}" -X POST $ENDPOINT -H "accept: application/json" -H "Authorization: Bearer $AUTH_TOKEN" -H "Content-Type: application/json" --data-binary @/tmp/payload.$$)
check_http_error
rm -f /tmp/payload.$$
}
rest_api_post_empty () {
check_get_token
http_response=$(curl -s -k -o /tmp/rbkresponse.$$ -w "%{http_code}" -X POST $ENDPOINT -H "accept: application/json" -H "Authorization: Bearer $AUTH_TOKEN" -H "Content-Type: application/json")