diff --git a/scripts/bms-accounts.sh b/scripts/bms-accounts.sh index 0db2610..e80c6ec 100755 --- a/scripts/bms-accounts.sh +++ b/scripts/bms-accounts.sh @@ -8,7 +8,7 @@ fi curl --silent --show-error --fail \ -H "Authorization: Bearer $token" \ - "https://api.bms.kaseya.com/v2/servicedesk/accounts/lookup" | \ + "https://api.bms.kaseya.com/v2/crm/accounts/lookup" | \ jq -r '.result[]? // .[]' | \ while IFS= read -r line; do id=$(echo "$line" | jq -r '.Id') diff --git a/scripts/bms-locations.sh b/scripts/bms-locations.sh index 1115109..ff8e6d2 100755 --- a/scripts/bms-locations.sh +++ b/scripts/bms-locations.sh @@ -19,7 +19,7 @@ esac curl --silent --show-error --fail \ -H "Authorization: Bearer $token" \ - "https://api.bms.kaseya.com/v2/servicedesk/locations?accountId=$account_id" | \ + "https://api.bms.kaseya.com/v2/crm/accounts/${account_id}/locations/lookup" | \ jq -r '.result[]? // .[]' | \ while IFS= read -r line; do id=$(echo "$line" | jq -r '.Id')