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
const sharp = require("sharp"); | |
const main = async (scale) => { | |
const originalImage = await sharp("text.png").ensureAlpha().raw(); | |
const { width, height } = await originalImage.metadata(); | |
const image = await originalImage | |
.resize({ | |
width: Math.floor(width * scale), | |
height: Math.floor(height * scale), | |
fit: "contain", |
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
{ | |
"name": "ens", | |
"version": "1.0.0", | |
"description": "", | |
"main": "index.js", | |
"scripts": { | |
"test": "echo \"Error: no test specified\" && exit 1" | |
}, | |
"author": "", | |
"license": "ISC", |
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 requests | |
# API endpoint for retrieving transaction information | |
api_url = "https://api-nova.arbiscan.io/api" | |
# Address of the smart contract | |
contract_address = "0x3b4cdb27641bc76214a0cb6cae3560a468d9ad4a" | |
# Start and end blocks to search for transactions | |
start_block = 0 |
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
const { ethers } = require("ethers"); | |
const provider = new ethers.providers.WebSocketProvider( | |
"wss://mainnet.infura.io/ws/v3/992c9dccdfd849dabf68ab78d689595d" | |
); | |
console.log(provider); | |
provider.on("block", (blockNumber) => { | |
provider | |
.getBlockWithTransactions(blockNumber) |
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 multiprocessing.dummy as mp | |
import pymysql | |
import requests | |
class TransactionsTable: | |
def __init__(self, collections): | |
self.collections = collections | |
for collection in self.collections: |
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 json | |
from decimal import Decimal | |
import boto3 | |
import requests | |
class UpdateDB: | |
def __init__(self): | |
self.result = [] |
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 requests | |
import json | |
slug = "azuki" | |
url = f'https://api.opensea.io/vnext/offers/collection/{slug}/traits' | |
headers = { | |
"X-API-KEY": "2972994f68bb4dfc9f68c944f473c329" | |
} |
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
const https = require('https') | |
const { Wallet } = require('ethers') | |
const { | |
addressesByNetwork, | |
SupportedChainId, | |
generateMakerOrderTypedData, | |
} = require('@looksrare/sdk') | |
require('dotenv').config() | |
const WALLET_PRIVATE_KEY = process.env.WALLET_PRIVATE_KEY |
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
// if type module -> cannot use reqiure, need import | |
// In package.json: "type": "module", | |
import { OpenSeaSDK, Network } from "opensea-js"; | |
import HDWalletProvider from "@truffle/hdwallet-provider"; | |
import { config } from 'dotenv'; | |
config(); | |
// https://github.com/ProjectOpenSea/opensea-js#making-offers | |
const WALLET_PRIVATE_KEY = process.env.WALLET_PRIVATE_KEY |
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 { Signer } from 'ethers' | |
import { ethersWallet, init, offer } from '@x2y2-io/sdk' | |
import { Network } from '@x2y2-io/sdk/dist/network' | |
require('dotenv').config() | |
// https://github.com/X2Y2-io/x2y2-sdk#making-offers--collection-offers | |
const X2Y2_API_KEY: string = process.env.X2Y2_API_KEY || "" | |
const WALLET_PRIVATE_KEY: string = process.env.WALLET_PRIVATE_KEY || "" |
NewerOlder