31 lines
674 B
Bash
31 lines
674 B
Bash
#!/bin/bash
|
|
|
|
|
|
#Import variable
|
|
source .env
|
|
|
|
|
|
#Login
|
|
$curl -s -c $COOKIE $BML_URL/login \
|
|
--data-raw username=$BML_USERNAME \
|
|
--data-raw password=${BML_PASSWORD}
|
|
echo ""
|
|
echo "Login done"; sleep 2
|
|
echo ""
|
|
|
|
|
|
# Get profiles and select personal profile
|
|
#$curl -s -b $COOKIE $BML_URL/profile | jq -r '.payload | .profile | .[] | .profile' | head -n 1
|
|
$curl -s -b $COOKIE $BML_URL/profile
|
|
echo ""
|
|
echo "Get Profile done"; sleep 2
|
|
echo ""
|
|
|
|
|
|
|
|
#PROFILE=$($curl -s -b $COOKIE $BML_URL/profile | jq -r '.payload | .profile | .[] | .profile' | head -n 1)
|
|
#$curl -s -b $COOKIE $BML_URL/profile \
|
|
# --data-raw profile=$PROFILE >> /dev/null
|
|
#
|
|
#$curl -s -c $COOKIE $BML_URL/api/dashboard
|