silence curl and remove comm

This commit is contained in:
tykayn 2020-11-27 12:15:04 +01:00 committed by Baptiste Lemoine
parent eeec1cc9f7
commit 0b1481b221

View File

@ -31,12 +31,11 @@ source "/etc/mobilizon.chapril.org/mobilizonchaprilorg.conf"
IPV4_PATTERN="[0-9]{1,3}(\.[0-9]{1,3}){3}" IPV4_PATTERN="[0-9]{1,3}(\.[0-9]{1,3}){3}"
IPV6_PATTERN="[0-9a-f]{0,4}(:[0-9a-f]{0,4}){2,7}" IPV6_PATTERN="[0-9a-f]{0,4}(:[0-9a-f]{0,4}){2,7}"
# TODO métriques à récupérer
# https://docs.joinmobilizon.org/contribute/graphql_api/ # https://docs.joinmobilizon.org/contribute/graphql_api/
API_URL="https://mobilizon.chapril.org/api/" API_URL="https://mobilizon.chapril.org/api/"
# get statistics from the graphQL api of the website # get statistics from the graphQL api of the website
json=$(curl -X POST \ json=$(curl -s -X POST \
-H "Content-Type: application/json" \ -H "Content-Type: application/json" \
--data '{"query":"{\n statistics {\n numberOfUsers\n numberOfEvents\n numberOfLocalEvents\n numberOfComments\n numberOfLocalComments\n numberOfGroups\n numberOfLocalGroups\n numberOfInstanceFollowers\n numberOfInstanceFollowings\n }\n}\n"}' $API_URL) --data '{"query":"{\n statistics {\n numberOfUsers\n numberOfEvents\n numberOfLocalEvents\n numberOfComments\n numberOfLocalComments\n numberOfGroups\n numberOfLocalGroups\n numberOfInstanceFollowers\n numberOfInstanceFollowings\n }\n}\n"}' $API_URL)