Quests

Beta: Quests API is currently in beta mode, and is only available for early access previews right now

Introduction

This endpoint allows you to suggest quests based on the onchain state of an address across various chains. Suggestions will vary based on current and historic holdings, address history and previous quest interactions (if applicable).

Get Quests for a wallet

GET /quests/{address}

Cache

The response of this endpoint is cached for 8 hours or until the request parameter refresh is being provided.

Request Parameters

ParamTypeDescription

limit

int

limit of max results. default: 3. max: 5

refresh

Boolean

Bust the cache. default: false

network

String | null

any of: ethereum, polygon, polygon-zkevm, optimism, arbitrum, starknet, polygon, zora, taiko, solana, zksync, mantle, base. Default: <empty>

type

Array<String> | null

can be left empty. One or multiple values. Values: Earn, Hunt, Mint, Buy, Play. Default: Earn, Hunt, Mint, Buy, Play

Response Parameters

[].wallet

String

Wallet this quest was suggested for

[].enables

Int

Indicates the amount of quests this enables

[].id

Long

Id of the quest

[].type

String

Hunt, Learn, Earn

[].title

String

Quest Title

[].minsToComplete

Int

Minutes to complete Quest

[].ctaTitle

[].ctaLink

[].steps

Array<String>

[].description

String

[].prerequisites[].type

String

[].prerequisites[].reason

String

[].profile.id

String

[].profile.title

String

[].profile.link

String

[].profile.imageUrl

String

[].profile.slug

String

[].profile.category

String

[].profile.shortDescription

String

[].profile.website

URI

[].profile.twitter

URI

[].profile.likelihood

String

[].profile.telegram

String

[].profile.networks

Array<Network>

list of associated networks

[].profile.networks[].network

String

[].profile.networks[].averageGasPrices

Object

[].profile.networks[].averageGasPrices.1h

Object

[].profile.networks[].averageGasPrices.1h.amount.amount

Double

amount in gwei

[].profile.networks[].averageGasPrices.1h.amount.amountUsd

Double

amount of gas in usd

[].profile.networks[].averageGasPrices.1h.percentageChange

double

percentage of change compared to previous 1h

[].profile.networks[].averageGasPrices.1h.textIndicator

String

human readable format of gas

Example Request

curl 'https://api.bankless.com/quests/0x469b33E0B70725184175750920AfD81B4BD94619'

Example Response

[
    {
    id: 1,
    enables: 22,
    type: "Hunt",
    title: "Bridge Funds to Polygon zkEVM with Orbiter",
    minsToComplete: 2,
    ctaTitle: "Bridge Funds with Orbiter",
    ctaLink: "https://www.orbiter.finance/?source=Ethereum&dest=Polygon%20zkEVM",
    steps: [
        "Connect a wallet funded with ETH to Orbiter",
        "Select the origin chain and input the amount of ETH you want to send",
        "Select “Polygon zkEVM” as the destination chain",
        "Click “Send” and approve the associated transactions"
    ],
    description: "Bridging funds into Polygon will count as a transaction type and is necessary for the next step! Orbiter is a tokenless bridging and exchange protocol and one of the most popular bridge routes to Polygon zkEVM. ",
    prerequisites: [
        {
            type: "token-absence",
            reason: "The wallet doesn't hold any native currency on polygon-zkevm"
        }
    ],
    profile: {
        id: 2,
        title: "Polygon zkEVM",
        link: "https://www.bankless.com/airdrop-hunter/polygon-zkevm",
        imageURL: "https://www.bankless.com/assets/cdn/airdrops/2023-07-19/Polygon Logo.jpeg-3b1018d59fe7548b65c3bd40d0a71740.jpeg",
        slug: "polygon-zkevm",
        category: "L2",
        shortDescription: "EVM-equivalent zero-knowledge rollup",
        website: "https://polygon.technology/",
        twitter: "https://twitter.com/0xPolygonLabs",
        likelihood: "Medium",
        telegram: "",
        networks: [
        {
            network: "ETHEREUM",
            averageGasPrices: {
                1h: {
                    amount: {
                        amount: 6.059012229516667,
                        amountUsd: 0.437271702379659
                    },
                    percentageChange: 17.34,
                    textIndicator: "high"
                    }
                }
            }]
        }
    }
]

Permissions

This endpoint requires you to have the QUESTS permission.

Get Quests for multiple wallets

POST /quests

Cache

The response of this endpoint is not cached.

Request Body

ParamTypeDescription

addresses

Array<String>

list of evm addresses to suggest quests for

limit

int

limit of max results. default: 3. max: 5

refresh

Boolean

Bust the cache. default: false

Response Parameters

[].wallet

String

wallet this quest was suggested for

[].id

Long

Id of the quest

[].type

String

Hunt, Learn, Earn

[].title

String

Quest Title

[].minsToComplete

Int

Minutes to complete Quest

[].ctaTitle

[].ctaLink

[].steps

Array<String>

[].description

String

[].prerequisites[].type

String

[].prerequisites[].reason

String

[].profile.id

String

[].profile.title

String

[].profile.link

String

[].profile.imageUrl

String

[].profile.slug

String

[].profile.category

String

[].profile.shortDescription

String

[].profile.website

URI

[].profile.twitter

URI

[].profile.likelihood

String

[].profile.telegram

String

[].profile.networks

Array<Network>

list of associated networks

[].profile.networks[].network

String

[].profile.networks[].averageGasPrices

Object

[].profile.networks[].averageGasPrices.1h

Object

[].profile.networks[].averageGasPrices.1h.amount.amount

Double

amount in gwei

[].profile.networks[].averageGasPrices.1h.amount.amountUsd

Double

amount of gas in usd

[].profile.networks[].averageGasPrices.1h.percentageChange

double

percentage of change compared to previous 1h

[].profile.networks[].averageGasPrices.1h.textIndicator

String

human readable format of gas

Example Request

POST https://api.bankless.com/quests
content-type: application/json

{
  "addresses": ["0xA4D94019934D8333Ef880ABFFbF2FDd611C762BD", "0x83A524af3cf8eB146132A2459664f7680A5515bE"],
  "limit": 5
}

Example Response

[
    {
    id: 1,
    type: "Hunt",
    title: "Bridge Funds to Polygon zkEVM with Orbiter",
    minsToComplete: 2,
    ctaTitle: "Bridge Funds with Orbiter",
    ctaLink: "https://www.orbiter.finance/?source=Ethereum&dest=Polygon%20zkEVM",
    steps: [
        "Connect a wallet funded with ETH to Orbiter",
        "Select the origin chain and input the amount of ETH you want to send",
        "Select “Polygon zkEVM” as the destination chain",
        "Click “Send” and approve the associated transactions"
    ],
    description: "Bridging funds into Polygon will count as a transaction type and is necessary for the next step! Orbiter is a tokenless bridging and exchange protocol and one of the most popular bridge routes to Polygon zkEVM. ",
    prerequisites: [
        {
            type: "token-absence",
            reason: "The wallet doesn't hold any native currency on polygon-zkevm"
        }
    ],
    profile: {
        id: 2,
        title: "Polygon zkEVM",
        link: "https://www.bankless.com/airdrop-hunter/polygon-zkevm",
        imageURL: "https://www.bankless.com/assets/cdn/airdrops/2023-07-19/Polygon Logo.jpeg-3b1018d59fe7548b65c3bd40d0a71740.jpeg",
        slug: "polygon-zkevm",
        category: "L2",
        shortDescription: "EVM-equivalent zero-knowledge rollup",
        website: "https://polygon.technology/",
        twitter: "https://twitter.com/0xPolygonLabs",
        likelihood: "Medium",
        telegram: "",
        networks: [
        {
            network: "ETHEREUM",
            averageGasPrices: {
                1h: {
                    amount: {
                        amount: 6.059012229516667,
                        amountUsd: 0.437271702379659
                    },
                    percentageChange: 17.34,
                    textIndicator: "high"
                    }
                }
            }]
        }
    }
]

Permissions

This endpoint requires you to have the QUESTS permission.

Last updated