#!/bin/bash
source $FLEET_ENV_PATH
endpoint="api/v1/kolide/schedule"
jq -n \
  --arg pack_id "$1" \
  --arg query_id "$2" \
  '.pack_id = ($pack_id|tonumber)
  |.query_id = ($query_id|tonumber)
  |.interval = 60
  |.removed = false
  |.snapshot = true
  |.platform = "darwin"
  '|\
  curl $CURL_FLAGS -H "Authorization: Bearer $TOKEN" "$SERVER_URL/$endpoint" -d@- 
