Skip to content

Commit 54b76a4

Browse files
Merge pull request #488 from alchemyplatform/shreyas/new-params
add params to token and price APIs; update naming for clarity
2 parents c27d4d8 + ad005c3 commit 54b76a4

File tree

7 files changed

+35
-7
lines changed

7 files changed

+35
-7
lines changed

data/assets/nfts/by-address.yaml

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
summary: NFTs By Wallet
22
description: >
3-
Retrieves all NFTs currently owned by multiple addresses using network and address pairs. This endpoint is supported on Ethereum and many L2s, including Polygon, Arbitrum, Optimism, Base, World Chain and more. See the full list of supported networks [here](https://dashboard.alchemy.com/chains?service=token-api&utm_source=readme&utm_medium=link&utm_campaign=docs_method_chains_link_v1_tokens).
3+
Fetches NFTs for multiple wallet addresses and networks. Returns a list of NFTs and metadata for each wallet/network combination. This endpoint is supported on Ethereum and many L2s, including Polygon, Arbitrum, Optimism, Base, World Chain and more. See the full list of supported networks [here](https://dashboard.alchemy.com/chains?service=token-api&utm_source=readme&utm_medium=link&utm_campaign=docs_method_chains_link_v1_tokens).
44
tags: ["📚 Portfolio APIs"]
55
x-readme:
66
samples-languages:

data/assets/nfts/contracts/by-address.yaml

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
1-
summary: Contracts By Wallet
1+
summary: NFT Collections By Wallet
22
description: >
3-
Retrieves all NFT contracts currently owned by multiple addresses using network and address pairs. This endpoint is supported on Ethereum and many L2s, including Polygon, Arbitrum, Optimism, Base, World Chain and more. See the full list of supported networks [here](https://dashboard.alchemy.com/chains?service=token-api&utm_source=readme&utm_medium=link&utm_campaign=docs_method_chains_link_v1_tokens).
3+
Fetches NFT collections (contracts) for multiple wallet addresses and networks. Returns a list of collections and metadata for each wallet/network combination. This endpoint is supported on Ethereum and many L2s, including Polygon, Arbitrum, Optimism, Base, World Chain and more. See the full list of supported networks [here](https://dashboard.alchemy.com/chains?service=token-api&utm_source=readme&utm_medium=link&utm_campaign=docs_method_chains_link_v1_tokens).
44
tags: ["📚 Portfolio APIs"]
55
x-readme:
66
samples-languages:

data/assets/tokens/balances/by-address.yaml

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
summary: Token Balances By Wallet
22
description: >
3-
Fetches current balances for multiple addresses using network and address pairs. Returns a list of token balances, each containing the network and address. This endpoint is supported on Ethereum, Solana, and 30+ EVM chains. See the full list of supported networks [here](https://dashboard.alchemy.com/chains?service=token-api&utm_source=readme&utm_medium=link&utm_campaign=docs_method_chains_link_v1_tokens)
3+
Fetches fungible tokens (native and ERC-20) for multiple wallet addresses and networks. Returns a list of tokens with balances for each wallet/network combination. This endpoint is supported on Ethereum, Solana, and 30+ EVM chains. See the full list of supported networks [here](https://dashboard.alchemy.com/chains?service=token-api&utm_source=readme&utm_medium=link&utm_campaign=docs_method_chains_link_v1_tokens)
44
tags: ["📚 Portfolio APIs"]
55
x-readme:
66
samples-languages:

data/assets/tokens/by-address.yaml

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
summary: Tokens By Wallet
22
description: >
3-
Fetches current balances, prices, and metadata for multiple addresses using network and address pairs. Returns a list of token balances, each containing the network and address. This endpoint is supported on Ethereum, Solana, and 30+ EVM chains. See the full list of supported networks [here](https://dashboard.alchemy.com/chains?service=token-api&utm_source=readme&utm_medium=link&utm_campaign=docs_method_chains_link_v1_tokens).
3+
Fetches fungible tokens (native and ERC-20) for multiple wallet addresses and networks. Returns a list of tokens with balances, prices, and metadata for each wallet/network combination. This endpoint is supported on Ethereum, Solana, and 30+ EVM chains. See the full list of supported networks [here](https://dashboard.alchemy.com/chains?service=token-api&utm_source=readme&utm_medium=link&utm_campaign=docs_method_chains_link_v1_tokens).
44
tags: ["📚 Portfolio APIs"]
55
x-readme:
66
samples-languages:

data/transactions/history/by-address.yaml

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
1-
summary: Transaction History By Wallet
1+
summary: Transactions By Wallet
22
description: >
3-
Fetches all transactions addresses using network and address pairs (currently limited to 1 in BETA) Returns a list of transaction objects. This endpoint will be supported on Ethereum, Solana, and 30+ EVM chains (currently limited to ETH and Base)
3+
Fetches all historical transactions (internal & external) for multiple wallet addresses and networks. Returns a list of transaction objects with metadata and log information. This endpoint will be supported on Ethereum, Solana, and 30+ EVM chains (Beta: currently limited to Ethereum and Base with a limit of 1 address)
44
tags: ["📚 Portfolio APIs"]
55
x-readme:
66
samples-languages:

data/v1.yaml

+10
Original file line numberDiff line numberDiff line change
@@ -455,6 +455,11 @@ components:
455455
Array of address and networks pairs (limit 3 pairs, max 20 networks each). Networks should match network enums.
456456
items:
457457
$ref: "#/components/schemas/AddressItemWith20Maximum"
458+
includeNativeTokens:
459+
type: boolean
460+
description: Whether to include each chain's native token in the response (e.g. ETH on Ethereum). The native token will have a null contract address.
461+
example: true
462+
default: true
458463
required:
459464
- addresses
460465

@@ -477,6 +482,11 @@ components:
477482
description: 'Boolean - if set to `true`, returns token prices. Setting this to false will reduce payload size and may result in a faster API call. Defaults to `true`.'
478483
type: boolean
479484
default: true
485+
includeNativeTokens:
486+
type: boolean
487+
description: Whether to include each chain's native token in the response (e.g. ETH on Ethereum). The native token will have a null contract address.
488+
example: true
489+
default: true
480490
required:
481491
- addresses
482492

prices/prices.yaml

+18
Original file line numberDiff line numberDiff line change
@@ -355,6 +355,11 @@ components:
355355
enum: [ "5m", "1h", "1d" ]
356356
default: "1d"
357357
example: "1d"
358+
withMarketData:
359+
type: boolean
360+
description: Whether to include market cap and volume for each token
361+
example: true
362+
default: false
358363
- required: ["network", "address", "startTime", "endTime"]
359364
properties:
360365
network:
@@ -396,6 +401,11 @@ components:
396401
enum: [ "5m", "1h", "1d" ]
397402
default: "1d"
398403
example: "1d"
404+
withMarketData:
405+
type: boolean
406+
description: Whether to include market cap and volume for each token
407+
example: true
408+
default: false
399409

400410
HistoricalPricesResponse:
401411
type: object
@@ -461,6 +471,14 @@ components:
461471
format: date-time
462472
description: Timestamp of the price data point.
463473
example: "2024-01-01T00:00:00Z"
474+
marketCap:
475+
type: string
476+
description: Total market capitalization at the timestamp
477+
example: "274292310008.21802"
478+
totalVolume:
479+
type: string
480+
description: Volume traded during the defined interval
481+
example: "6715146404.608721"
464482
required:
465483
- value
466484
- timestamp

0 commit comments

Comments
 (0)