Getting logged in
Method 1: API Keys
curl -H "Authorization: APIKeyGoesHere" https://api.sponsus.org/v1/profiles/@meimport aiohttp
import asyncio
APIKey = "APIKeyGoesHere"
# AsyncIO is the future of Python ✨
async def main():
client = aiohttp.ClientSession(loop=asyncio.get_event_loop())
headers = {
"Authorization": APIKey
}
async with client.get("https://api.sponsus.org/v1/profiles/@me") as response:
my_profile = await response.json()
# do things with my_profile!
asyncio.run(main())Method 2: OAuth


Last updated