Created
June 5, 2020 13:31
-
-
Save dfar-io/1297c095101e4bdbeef2c7a058b7b03e to your computer and use it in GitHub Desktop.
Extracts all Bold360 Chats from an account
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# Gets all chat messages from a Bold360 account | |
# you can easily pipe this to output file with: | |
# ./extract-bold-chat.sh | jq '.Data' > output.json | |
accountId=[YOUR_ACCOUNT_KEY] | |
apiSettingId=[YOUR_API_SETTING_KEY] | |
apiKey=[YOUR_API_KEY] | |
auth="$accountId:$apiSettingId:$( date +"%s" )000" | |
authHash="$auth:$( echo -n "$auth$apiKey" | openssl dgst -sha512 | sed 's/^.* //')" | |
curl "https://api.boldchat.com/aid/$accountId/data/rest/json/v1/getAllChatMessages?auth=$authHash" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment