-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add hurl in tools/ for login, status and cleanup
- Loading branch information
Showing
3 changed files
with
42 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
################################################################################# | ||
# Get an access token using the login token | ||
################################################################################# | ||
|
||
GET {{host}}/api/v1/login | ||
Authorization: Bearer {{login_token}} | ||
HTTP 200 | ||
[Asserts] | ||
jsonpath "$.access_token" isString | ||
jsonpath "$.access_token_exp" isString |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
################################################################################# | ||
# Stop a placement | ||
################################################################################# | ||
|
||
PUT {{host}}/api/v1/accounts/{{type}}/{{name}}/cleanup | ||
Authorization: Bearer {{access_token}} | ||
HTTP 200 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
#n################################################################################ | ||
# Get status | ||
################################################################################# | ||
|
||
PUT {{host}}/api/v1/accounts/{{type}}/{{name}}/status | ||
Authorization: Bearer {{access_token}} | ||
HTTP 202 | ||
[Captures] | ||
r_status: jsonpath "$.request_id" | ||
[Asserts] | ||
jsonpath "$.message" == "status request created" | ||
|
||
GET {{host}}/api/v1/requests/{{r_status}}/status | ||
Authorization: Bearer {{access_token}} | ||
[Options] | ||
retry: 140 | ||
HTTP 200 | ||
[Asserts] | ||
jsonpath "$.status" == "success" | ||
|
||
|
||
# Get status | ||
GET {{host}}/api/v1/accounts/{{type}}/{{name}}/status | ||
Authorization: Bearer {{access_token}} | ||
HTTP 200 |