Added cards list script
Signed-off-by: James Ketrenos <james_eikona@ketrenos.com>
This commit is contained in:
parent
b7acd73440
commit
9d4596c50a
21
server/cards
Executable file
21
server/cards
Executable file
@ -0,0 +1,21 @@
|
||||
#!/bin/bash
|
||||
ADMIN=$(jq -r .admin config/local.json)
|
||||
if [[ "${ADMIN}" == "" ]]; then
|
||||
echo "You need to set your { 'admin': 'secret' } in config/local.json"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
id=$1
|
||||
|
||||
if [[ "${id}" == "" ]]; then
|
||||
echo "Usage: pass GAME-ID"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
curl --noproxy '*' -s -L \
|
||||
--request PUT \
|
||||
--header "PRIVATE-TOKEN: ${ADMIN}" \
|
||||
--header "Content-Type: application/json" \
|
||||
http://localhost:8930/ketr.ketran/api/v1/games/${id}/cards |
|
||||
jq -r .status
|
||||
|
Loading…
x
Reference in New Issue
Block a user