Kategorie: Skripte

  • Tronity

    #!/bin/bashTOKEN=$( curl -s –connect-timeout 2 –location ‚https://api.tronity.tech/authentication‘ –header ‚Content-Type: application/json‘ –data ‚{ „client_id“: „Client-ID“, „client_secret“: „Client-Secret“, „grant_type“: „app“ }‘ | jq .access_token |sed s/“\““//g )RESULT=echo „curl -s –connect-timeout 2 –location ‚https://api.tronity.tech/tronity/vehicles/‘ –header ‚Content-Type: application/json‘ –header ‚Authorization: Bearer $TOKEN'“|bashID=echo $RESULT|jq .data[].id|sed s/“\““//gecho $IDRESULT=echo „curl -s –connect-timeout 2 –location ‚https://api.tronity.tech/tronity/vehicles/$ID‘ –header ‚Content-Type: application/json‘ –header ‚Authorization: Bearer $TOKEN'“|bashecho…