aboutsummaryrefslogblamecommitdiffstats
path: root/test/endpoints.sh
blob: 85621dd8ed9d92d2f64d6d81097c3537f49b5fb9 (plain) (tree)
1
2
3
4
5
6
7
8



                 



                                                                                                                                 



                                                                                                                                       
#!/usr/bin/env sh
set -e
set -x

# sleep 5
curl -k -X GET https://localhost:8008/crypto/price?name=CAKE&unit=USD
curl -k -X GET https://localhost:8008/crypto/pair?one=ETH&two=CAKE&multiplier=4.0
curl -k -X POST -H "Content-Type: application/json" -d '{"name":"alert1", "expr":"ETH>CAKE"}' https://localhost:8008/crypto/alert

curl -X GET -H "Content-Type: application/json" "https://api.terminaldweller.com/crypto/alert?key=alert10"
curl -X DELETE -H "Content-Type: application/json" "https://api.terminaldweller.com/crypto/alert?key=alert10"
curl -X POST -H "Content-Type: application/json" -d '{"name":"alert1", "expr":"ETH>CAKE"}' https://api.terminaldweller.com/crypto/alert