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
import * as crypto from 'crypto'; | |
export class ClearbitSignatureValidation { | |
static getSignature(raw_body: string, signature: string): string { | |
const signature_without_prefix = signature.replace(/^(sk\_)/, ''); | |
return ( | |
'sha1=' + | |
crypto | |
.createHmac('sha1', signature_without_prefix) |
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
{ | |
"lists": [ | |
{ | |
"id": "2265d00fe6", | |
"web_id": 57533, | |
"name": "Västerorts RC Sportklubb", | |
"contact": { | |
"company": "Västerorts RC Sportklubb", | |
"address1": "Kyrkhamnsvägen 1", | |
"address2": "", |
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
xargs -n 1 -I{} \ | |
sh -c " \ | |
curl -s -X GET \ | |
https://api-ssl.bitly.com/v4/bitlinks/bit.ly%2F2{}/clicks/summary \ | |
-H 'Authorization: Bearer ad7ecf6cd10e8f072651f00cf90e2bc983a4a974' \ | |
| jq .total_clicks" \ | |
< shortlinks.txt |
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
curl -X GET \ | |
https://api-ssl.bitly.com/v4/bitlinks/bit.ly%2F2Km4Nro/clicks/summary \ | |
-H 'Authorization: Bearer ad7ecf6cd10e8f072651f00cf90e2bc983a4a974' |
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
cat links.txt | xargs -n 1 -I{} \ | |
curl -s -X POST \ | |
https://api-ssl.bitly.com/v4/bitlinks \ | |
-H 'Authorization: Bearer ad7ecf6cd10e8f072651f00cf90e2bc983a4a974' \ | |
-H 'Content-Type: application/json' \ | |
-d '{ "group_guid": "B99h99pjymR", "long_url": "{}" }' \ | |
2>&1 | jq -r '. | "\(.long_url)\t\(.link)"' |
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
curl -X POST \ | |
https://api-ssl.bitly.com/v4/bitlinks \ | |
-H 'Authorization: Bearer ad7ecf6cd10e8f072651f00cf90e2bc983a4a974' \ | |
-H 'Content-Type: application/json' \ | |
-d '{ | |
"group_guid": "B99h99pjymR", | |
"long_url": "https://www.relatable.me/case-studies" | |
}' |
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
curl -u "[email protected]:xyz123mypassword" -X POST "https://api-ssl.bitly.com/oauth/access_token" |
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
{ | |
"AF": "Afghanistan", | |
"AX": "Aland Islands", | |
"AL": "Albania", | |
"DZ": "Algeria", | |
"AS": "American Samoa", | |
"AD": "Andorra", | |
"AO": "Angola", | |
"AI": "Anguilla", | |
"AQ": "Antarctica", |
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
{ | |
"zxx": "Not applicable", | |
"ab": "Abkhazian", | |
"aa": "Afar", | |
"af": "Afrikaans", | |
"sq": "Albanian", | |
"ase": "American Sign Language", | |
"am": "Amharic", | |
"ar": "Arabic", | |
"arc": "Aramaic", |
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
[ | |
{ | |
"id": "1", | |
"title": "Film & Animation" | |
}, | |
{ | |
"id": "2", | |
"title": "Autos & Vehicles" | |
}, | |
{ |
NewerOlder