This file contains hidden or 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
| function getOsImageUrl(contractAddress, tokenId) { | |
| let assetUrl = `https://api.opensea.io/api/v1/asset/${contractAddress}/${tokenId}` | |
| let jsonResp = JSON.parse(request(assetUrl)) | |
| return jsonResp["image_thumbnail_url"] | |
| } | |
| function openSeaHighestBid(contractAddress, tokenId) { | |
| let assetUrl = `https://api.opensea.io/api/v1/asset/${contractAddress}/${tokenId}` | |
| try { | |
| let jsonResp = JSON.parse(request(assetUrl)) |
This file contains hidden or 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 aiohttp | |
| import asyncio | |
| from aiohttp import ClientSession | |
| async def get_pokemon(session: ClientSession, url: str): | |
| async with session.get(url) as resp: | |
| pokemon = await resp.json() | |
| return pokemon["name"] |