summaryrefslogtreecommitdiffstats
path: root/bin/_cac_curl_api_v1
blob: 65acebd9abb3d80556fa9e4dddcc7428d58d403e (plain)
1
2
3
4
5
6
7
8
9
10
#! /bin/sh
set -euf

exec _cac_exec curl -fsS "$1" "https://panel.cloudatcost.com/api/v1/$2.php" $(
  shift 2
  set -- "$@" login="$cac_login" key="$cac_key"
  for arg; do
    echo -d $(printf '%s' "$arg" | urlencode)
  done
)