Custom URL shortener for sharing branded links
Rebrandly is a custom URL shortener for creating and managing branded links using an API.
import requests
import json
url = "https://api.rebrandly.com/v1/links"
headers = {
"Content-Type": "application/json",
"apikey": "YOUR_API_KEY"
}
payload = {
"destination": "https://www.google.com",
"domain": { "fullName": "rebrand.ly" }
}
response = requests.post(url, headers=headers, data=json.dumps(payload))
print(response.status_code)
print(response.json())Last 50 checks (10 min intervals)