@codex-data/sdk 1.0.26 → 1.0.30

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -263,6 +263,19 @@ export type BarsResponse = {
263
263
  volumeNativeToken?: Maybe<Array<Maybe<Scalars['String']['output']>>>;
264
264
  };
265
265
 
266
+ export type Block = {
267
+ __typename?: 'Block';
268
+ blockNumber: Scalars['Int']['output'];
269
+ hash: Scalars['String']['output'];
270
+ timestamp: Scalars['Int']['output'];
271
+ };
272
+
273
+ export type BlocksInput = {
274
+ blockNumbers?: InputMaybe<Array<Scalars['Int']['input']>>;
275
+ networkId: Scalars['Int']['input'];
276
+ timestamps?: InputMaybe<Array<Scalars['Int']['input']>>;
277
+ };
278
+
266
279
  /** The mathematical formula that defines how the prices of NFTs change after each buy or sell within a pool. */
267
280
  export enum BondingCurveType {
268
281
  Exponential = 'EXPONENTIAL',
@@ -468,7 +481,7 @@ export enum ContractType {
468
481
  export type CreateApiTokensInput = {
469
482
  /** Number of tokens to create, default is 1 */
470
483
  count?: InputMaybe<Scalars['Int']['input']>;
471
- /** Number of seconds until the token expires, defaults to 1 hour (3600) */
484
+ /** Number of milliseconds until the token expires, defaults to 1 hour (3600000) */
472
485
  expiresIn?: InputMaybe<Scalars['Int']['input']>;
473
486
  /** Number of requests allowed per token, represented as a string, default is 5000 */
474
487
  requestLimit?: InputMaybe<Scalars['String']['input']>;
@@ -2004,6 +2017,8 @@ export enum LaunchpadTokenProtocol {
2004
2017
  BoopFun = 'BoopFun',
2005
2018
  /** Protocol name for Clanker. */
2006
2019
  Clanker = 'Clanker',
2020
+ /** Protocol name for Clanker V4. */
2021
+ ClankerV4 = 'ClankerV4',
2007
2022
  /** Protocol name for EgoTech. */
2008
2023
  EgoTech = 'EgoTech',
2009
2024
  /** Protocol name for Four.meme. */
@@ -2020,6 +2035,8 @@ export enum LaunchpadTokenProtocol {
2020
2035
  Rainbow = 'Rainbow',
2021
2036
  /** Protocol name for LaunchLab and Bonk. */
2022
2037
  RaydiumLaunchpad = 'RaydiumLaunchpad',
2038
+ /** Protocol name for TokenMill V2. */
2039
+ TokenMillV2 = 'TokenMillV2',
2023
2040
  /** Protocol name for Vertigo. */
2024
2041
  Vertigo = 'Vertigo',
2025
2042
  /** Protocol name for Virtuals. */
@@ -5146,9 +5163,9 @@ export type OnEventsCreatedByMakerInput = {
5146
5163
  export type OnLaunchpadTokenEventBatchInput = {
5147
5164
  /** The type of event. */
5148
5165
  eventType?: InputMaybe<LaunchpadTokenEventType>;
5149
- /** The name of the launchpad. One of the following: Pump.fun, Bonk, Baseapp, Zora, Zora Creator, Four.meme, Believe, Moonshot, Jupiter Studio, boop, Heaven, Virtuals, Clanker, ArenaTrade, Moonit, LaunchLab, MeteoraDBC, Vertigo, Cooking.City, time.fun, BAGS, Circus, Dealr, OhFuckFun, PrintFun, Trend, shout.fun, xApple, Sendshot, DubDub, cults. */
5166
+ /** The name of the launchpad. One of the following: Pump.fun, Bonk, Baseapp, Zora, Zora Creator, Four.meme, Believe, Moonshot, Jupiter Studio, boop, Heaven, TokenMill V2, Virtuals, Clanker, Clanker V4, ArenaTrade, Moonit, LaunchLab, MeteoraDBC, Vertigo, Cooking.City, time.fun, BAGS, Circus, Dealr, OhFuckFun, PrintFun, Trend, shout.fun, xApple, Sendshot, DubDub, cults. */
5150
5167
  launchpadName?: InputMaybe<Scalars['String']['input']>;
5151
- /** A list of launchpad names. Any of the following: Pump.fun, Bonk, Baseapp, Zora, Zora Creator, Four.meme, Believe, Moonshot, Jupiter Studio, boop, Heaven, Virtuals, Clanker, ArenaTrade, Moonit, LaunchLab, MeteoraDBC, Vertigo, Cooking.City, time.fun, BAGS, Circus, Dealr, OhFuckFun, PrintFun, Trend, shout.fun, xApple, Sendshot, DubDub, cults. */
5168
+ /** A list of launchpad names. Any of the following: Pump.fun, Bonk, Baseapp, Zora, Zora Creator, Four.meme, Believe, Moonshot, Jupiter Studio, boop, Heaven, TokenMill V2, Virtuals, Clanker, Clanker V4, ArenaTrade, Moonit, LaunchLab, MeteoraDBC, Vertigo, Cooking.City, time.fun, BAGS, Circus, Dealr, OhFuckFun, PrintFun, Trend, shout.fun, xApple, Sendshot, DubDub, cults. */
5152
5169
  launchpadNames?: InputMaybe<Array<Scalars['String']['input']>>;
5153
5170
  /** The network ID that the token is deployed on. */
5154
5171
  networkId?: InputMaybe<Scalars['Int']['input']>;
@@ -5164,9 +5181,9 @@ export type OnLaunchpadTokenEventInput = {
5164
5181
  address?: InputMaybe<Scalars['String']['input']>;
5165
5182
  /** The type of event. */
5166
5183
  eventType?: InputMaybe<LaunchpadTokenEventType>;
5167
- /** The name of the launchpad. One of the following: Pump.fun, Bonk, Baseapp, Zora, Zora Creator, Four.meme, Believe, Moonshot, Jupiter Studio, boop, Heaven, Virtuals, Clanker, ArenaTrade, Moonit, LaunchLab, MeteoraDBC, Vertigo, Cooking.City, time.fun, BAGS, Circus, Dealr, OhFuckFun, PrintFun, Trend, shout.fun, xApple, Sendshot, DubDub, cults. */
5184
+ /** The name of the launchpad. One of the following: Pump.fun, Bonk, Baseapp, Zora, Zora Creator, Four.meme, Believe, Moonshot, Jupiter Studio, boop, Heaven, TokenMill V2, Virtuals, Clanker, Clanker V4, ArenaTrade, Moonit, LaunchLab, MeteoraDBC, Vertigo, Cooking.City, time.fun, BAGS, Circus, Dealr, OhFuckFun, PrintFun, Trend, shout.fun, xApple, Sendshot, DubDub, cults. */
5168
5185
  launchpadName?: InputMaybe<Scalars['String']['input']>;
5169
- /** A list of launchpad names. Any of the following: Pump.fun, Bonk, Baseapp, Zora, Zora Creator, Four.meme, Believe, Moonshot, Jupiter Studio, boop, Heaven, Virtuals, Clanker, ArenaTrade, Moonit, LaunchLab, MeteoraDBC, Vertigo, Cooking.City, time.fun, BAGS, Circus, Dealr, OhFuckFun, PrintFun, Trend, shout.fun, xApple, Sendshot, DubDub, cults. */
5186
+ /** A list of launchpad names. Any of the following: Pump.fun, Bonk, Baseapp, Zora, Zora Creator, Four.meme, Believe, Moonshot, Jupiter Studio, boop, Heaven, TokenMill V2, Virtuals, Clanker, Clanker V4, ArenaTrade, Moonit, LaunchLab, MeteoraDBC, Vertigo, Cooking.City, time.fun, BAGS, Circus, Dealr, OhFuckFun, PrintFun, Trend, shout.fun, xApple, Sendshot, DubDub, cults. */
5170
5187
  launchpadNames?: InputMaybe<Array<Scalars['String']['input']>>;
5171
5188
  /** The network ID that the token is deployed on. */
5172
5189
  networkId?: InputMaybe<Scalars['Int']['input']>;
@@ -5191,11 +5208,20 @@ export type OnTokenBarsUpdatedResponse = {
5191
5208
  eventSortKey: Scalars['String']['output'];
5192
5209
  /** The network ID the pair is deployed on. */
5193
5210
  networkId: Scalars['Int']['output'];
5194
- /** The contract address for the pair. */
5195
- pairAddress: Scalars['String']['output'];
5196
- /** The ID for the pair (`pairAddress`:`networkId`). */
5197
- pairId: Scalars['String']['output'];
5198
- /** The quote token within the pair. */
5211
+ /**
5212
+ * The contract address for the pair.
5213
+ * @deprecated pairs are no longer used for pricing
5214
+ */
5215
+ pairAddress?: Maybe<Scalars['String']['output']>;
5216
+ /**
5217
+ * The ID for the pair (`pairAddress`:`networkId`).
5218
+ * @deprecated pairs are no longer used for pricing
5219
+ */
5220
+ pairId?: Maybe<Scalars['String']['output']>;
5221
+ /**
5222
+ * The quote token within the pair.
5223
+ * @deprecated pairs are no longer used for pricing
5224
+ */
5199
5225
  quoteToken?: Maybe<QuoteToken>;
5200
5226
  /** The type of statistics used. Can be `Filtered` or `Unfiltered`. */
5201
5227
  statsType: TokenPairStatisticsType;
@@ -5680,6 +5706,8 @@ export type PairMetadata = {
5680
5706
  priceChange12?: Maybe<Scalars['Float']['output']>;
5681
5707
  /** The percent price change in the past 24 hours. Decimal format. */
5682
5708
  priceChange24?: Maybe<Scalars['Float']['output']>;
5709
+ /** The non-quote token price in USD. */
5710
+ priceNonQuoteToken: Scalars['String']['output'];
5683
5711
  /** The token of interest within the pair. Can be `token0` or `token1`. */
5684
5712
  quoteToken?: Maybe<QuoteToken>;
5685
5713
  /** The type of statistics returned. Can be `FILTERED` or `UNFILTERED` */
@@ -6114,6 +6142,8 @@ export type Price = {
6114
6142
  address: Scalars['String']['output'];
6115
6143
  /** Ratio of how confident we are in the price */
6116
6144
  confidence?: Maybe<Scalars['Float']['output']>;
6145
+ /** The internal pool address for the price */
6146
+ internalPoolAddress?: Maybe<Scalars['String']['output']>;
6117
6147
  /** The network ID the token is deployed on. */
6118
6148
  networkId: Scalars['Int']['output'];
6119
6149
  /** The pool that emitted the swap generating this price */
@@ -6666,6 +6696,8 @@ export type Query = {
6666
6696
  apiTokens: Array<ApiToken>;
6667
6697
  /** Returns list of token balances that a wallet has. */
6668
6698
  balances: BalancesResponse;
6699
+ /** Returns block data for the input blockNumbers or timestamps, maximum 25 inputs. */
6700
+ blocks: Array<Block>;
6669
6701
  /** Returns a URL for a pair chart. */
6670
6702
  chartUrls?: Maybe<ChartUrlsResponse>;
6671
6703
  /** Returns detailed stats for a wallet. */
@@ -6761,6 +6793,8 @@ export type Query = {
6761
6793
  getPrimePools?: Maybe<PrimePoolConnection>;
6762
6794
  /** Returns charting metadata for a given pair. Used for implementing a Trading View datafeed. */
6763
6795
  getSymbol?: Maybe<SymbolResponse>;
6796
+ /** Returns bar chart data to track price changes over time. */
6797
+ getTokenBars?: Maybe<TokenBarsResponse>;
6764
6798
  /** Returns transactions for a pair. */
6765
6799
  getTokenEvents?: Maybe<EventConnection>;
6766
6800
  /** Returns a list of token events for a given maker across all pairs. */
@@ -6832,6 +6866,11 @@ export type QueryBalancesArgs = {
6832
6866
  };
6833
6867
 
6834
6868
 
6869
+ export type QueryBlocksArgs = {
6870
+ input: BlocksInput;
6871
+ };
6872
+
6873
+
6835
6874
  export type QueryChartUrlsArgs = {
6836
6875
  input: ChartInput;
6837
6876
  };
@@ -7169,6 +7208,19 @@ export type QueryGetSymbolArgs = {
7169
7208
  };
7170
7209
 
7171
7210
 
7211
+ export type QueryGetTokenBarsArgs = {
7212
+ countback?: InputMaybe<Scalars['Int']['input']>;
7213
+ currencyCode?: InputMaybe<QuoteCurrency>;
7214
+ from: Scalars['Int']['input'];
7215
+ removeEmptyBars?: InputMaybe<Scalars['Boolean']['input']>;
7216
+ removeLeadingNullValues?: InputMaybe<Scalars['Boolean']['input']>;
7217
+ resolution: Scalars['String']['input'];
7218
+ statsType?: InputMaybe<TokenPairStatisticsType>;
7219
+ symbol: Scalars['String']['input'];
7220
+ to: Scalars['Int']['input'];
7221
+ };
7222
+
7223
+
7172
7224
  export type QueryGetTokenEventsArgs = {
7173
7225
  cursor?: InputMaybe<Scalars['String']['input']>;
7174
7226
  direction?: InputMaybe<RankingDirection>;
@@ -7631,7 +7683,7 @@ export type Subscription = {
7631
7683
  onDetailedStatsUpdated?: Maybe<DetailedStats>;
7632
7684
  /** Live-streamed event labels for a token. */
7633
7685
  onEventLabelCreated?: Maybe<EventLabel>;
7634
- /** Live-streamed transactions for a token. */
7686
+ /** Live-streamed transactions for a pair. */
7635
7687
  onEventsCreated?: Maybe<AddEventsOutput>;
7636
7688
  /** Live-streamed transactions for a maker. */
7637
7689
  onEventsCreatedByMaker?: Maybe<AddEventsByMakerOutput>;
@@ -8023,6 +8075,47 @@ export enum SymbolType {
8023
8075
  Token = 'TOKEN'
8024
8076
  }
8025
8077
 
8078
+ /** Bar chart data to track price changes over time. */
8079
+ export type TokenBarsResponse = {
8080
+ __typename?: 'TokenBarsResponse';
8081
+ /** The buy volume in USD */
8082
+ buyVolume: Array<Maybe<Scalars['String']['output']>>;
8083
+ /** The number of unique buyers */
8084
+ buyers: Array<Maybe<Scalars['Int']['output']>>;
8085
+ /** The number of buys */
8086
+ buys: Array<Maybe<Scalars['Int']['output']>>;
8087
+ /** The closing price. */
8088
+ c: Array<Maybe<Scalars['Float']['output']>>;
8089
+ /** The high price. */
8090
+ h: Array<Maybe<Scalars['Float']['output']>>;
8091
+ /** The low price. */
8092
+ l: Array<Maybe<Scalars['Float']['output']>>;
8093
+ /** Liquidity in USD */
8094
+ liquidity: Array<Maybe<Scalars['String']['output']>>;
8095
+ /** The opening price. */
8096
+ o: Array<Maybe<Scalars['Float']['output']>>;
8097
+ /** The status code for the batch: `ok` for successful data retrieval and `no_data` for empty responses signaling the end of server data. */
8098
+ s: Scalars['String']['output'];
8099
+ /** The sell volume in USD */
8100
+ sellVolume: Array<Maybe<Scalars['String']['output']>>;
8101
+ /** The number of unique sellers */
8102
+ sellers: Array<Maybe<Scalars['Int']['output']>>;
8103
+ /** The number of sells */
8104
+ sells: Array<Maybe<Scalars['Int']['output']>>;
8105
+ /** The timestamp for the bar. */
8106
+ t: Array<Scalars['Int']['output']>;
8107
+ /** The token that is being returned */
8108
+ token: EnhancedToken;
8109
+ /** The number of traders */
8110
+ traders: Array<Maybe<Scalars['Int']['output']>>;
8111
+ /** The number of transactions */
8112
+ transactions: Array<Maybe<Scalars['Int']['output']>>;
8113
+ /** The volume with higher precision. */
8114
+ volume?: Maybe<Array<Maybe<Scalars['String']['output']>>>;
8115
+ /** The volume in the native token for the network */
8116
+ volumeNativeToken?: Maybe<Array<Maybe<Scalars['String']['output']>>>;
8117
+ };
8118
+
8026
8119
  /** Token burn event data. */
8027
8120
  export type TokenBurnEventData = {
8028
8121
  __typename?: 'TokenBurnEventData';
@@ -8290,17 +8383,17 @@ export type TokenFilters = {
8290
8383
  isVerified?: InputMaybe<Scalars['Boolean']['input']>;
8291
8384
  /** The unix timestamp for the token's last transaction. */
8292
8385
  lastTransaction?: InputMaybe<NumberFilter>;
8293
- /** Indicates if the launchpad is completed */
8386
+ /** Indicates if the launchpad is completed. */
8294
8387
  launchpadCompleted?: InputMaybe<Scalars['Boolean']['input']>;
8295
- /** The timestamp when the launchpad was completed */
8388
+ /** The timestamp when the launchpad was completed. */
8296
8389
  launchpadCompletedAt?: InputMaybe<NumberFilter>;
8297
- /** The graduation percentage */
8390
+ /** The graduation percentage. */
8298
8391
  launchpadGraduationPercent?: InputMaybe<NumberFilter>;
8299
- /** Indicates if the launchpad has migrated */
8392
+ /** Indicates if the launchpad has migrated. */
8300
8393
  launchpadMigrated?: InputMaybe<Scalars['Boolean']['input']>;
8301
8394
  /** The timestamp when the launchpad was migrated */
8302
8395
  launchpadMigratedAt?: InputMaybe<NumberFilter>;
8303
- /** A list of launchpad names. Any of the following: Pump.fun, Bonk, Baseapp, Zora, Zora Creator, Four.meme, Believe, Moonshot, Jupiter Studio, boop, Heaven, Virtuals, Clanker, ArenaTrade, Moonit, LaunchLab, MeteoraDBC, Vertigo, Cooking.City, time.fun, BAGS, Circus, Dealr, OhFuckFun, PrintFun, Trend, shout.fun, xApple, Sendshot, DubDub, cults. */
8396
+ /** A list of launchpad names. Any of the following: Pump.fun, Bonk, Baseapp, Zora, Zora Creator, Four.meme, Believe, Moonshot, Jupiter Studio, boop, Heaven, TokenMill V2, Virtuals, Clanker, Clanker V4, ArenaTrade, Moonit, LaunchLab, MeteoraDBC, Vertigo, Cooking.City, time.fun, BAGS, Circus, Dealr, OhFuckFun, PrintFun, Trend, shout.fun, xApple, Sendshot, DubDub, cults. */
8304
8397
  launchpadName?: InputMaybe<Array<Scalars['String']['input']>>;
8305
8398
  /** A list of launchpad protocols. */
8306
8399
  launchpadProtocol?: InputMaybe<Array<Scalars['String']['input']>>;
@@ -8931,8 +9024,12 @@ export type TokenWalletFilterResult = {
8931
9024
  tokenAmountSoldAll1y: Scalars['String']['output'];
8932
9025
  /** Token amount sold all in the past 30 days */
8933
9026
  tokenAmountSoldAll30d: Scalars['String']['output'];
8934
- /** The current token balance */
9027
+ /** The token balance in the wallet. This value does not update with every transfer and can be slightly stale. Use tokenBalanceLive for live data. */
8935
9028
  tokenBalance: Scalars['String']['output'];
9029
+ /** The current token balance in the wallet. */
9030
+ tokenBalanceLive?: Maybe<Scalars['String']['output']>;
9031
+ /** The current USD value of the token balance. */
9032
+ tokenBalanceLiveUsd?: Maybe<Scalars['String']['output']>;
8936
9033
  };
8937
9034
 
8938
9035
  /** A token with metadata. */
@@ -9143,6 +9240,8 @@ export type UnconfirmedSwapEventData = {
9143
9240
 
9144
9241
  export type UniswapV4Data = {
9145
9242
  __typename?: 'UniswapV4Data';
9243
+ /** Whether the token is the network token for the Uniswap V4 pool. */
9244
+ isToken0NetworkToken?: Maybe<Scalars['Boolean']['output']>;
9146
9245
  type: Scalars['String']['output'];
9147
9246
  /** The address of the hook contract for Uniswap V4 pools. */
9148
9247
  uniswapV4HookAddress?: Maybe<Scalars['String']['output']>;
@@ -583,7 +583,7 @@
583
583
  "networkType": "EVM",
584
584
  "networkId": 7700,
585
585
  "name": "canto",
586
- "enabled": true,
586
+ "enabled": false,
587
587
  "newTokensEnabled": null,
588
588
  "mainnet": true,
589
589
  "wrappedBaseTokenSymbol": "WCANTO",
@@ -2819,6 +2819,39 @@
2819
2819
  "baseTokenName": "Wrapped SOL",
2820
2820
  "baseTokenDecimals": 9
2821
2821
  },
2822
+ {
2823
+ "__typename": "EvmNetworkConfig",
2824
+ "id": "5031",
2825
+ "networkType": "EVM",
2826
+ "networkId": 5031,
2827
+ "name": "Somnia",
2828
+ "enabled": false,
2829
+ "newTokensEnabled": true,
2830
+ "mainnet": true,
2831
+ "wrappedBaseTokenSymbol": "WSOMI",
2832
+ "baseTokenSymbol": "SOMI",
2833
+ "baseTokenAddress": "0x046ede9564a72571df6f5e44d0405360c0f4dcab",
2834
+ "defaultPairAddress": "0xe5467be8b8db6b074904134e8c1a581f5565e2c3",
2835
+ "defaultPairQuoteToken": "token0",
2836
+ "stableCoinAddresses": [
2837
+ "0x28bec7e30e6faee657a03e19bf1128aad7632a00",
2838
+ "0x67b302e35aef5eee8c32d934f5856869ef428330",
2839
+ "0x3243f9acb8c3bc6945131db91c5f678faf9093f1",
2840
+ "0x43cce55ffb83c2bfd2454964a6dfae20bd01adb9",
2841
+ "0x0827c58e2a44e94ab97a6a9fab1b8364328c1a4b"
2842
+ ],
2843
+ "networkIconUrl": "https://icons.defined.fi/networks/somnia.png",
2844
+ "color": "#9c3381",
2845
+ "networkShortName": "somnia",
2846
+ "networkName": "Somnia",
2847
+ "explorer": {
2848
+ "name": "Somnia Explorer",
2849
+ "url": "https://explorer.somnia.network/",
2850
+ "checksummed": false,
2851
+ "icon": "https://icons.defined.fi/networks/somnia.png"
2852
+ },
2853
+ "baseTokenName": "SOMI"
2854
+ },
2822
2855
  {
2823
2856
  "__typename": "EvmNetworkConfig",
2824
2857
  "id": "50312",
@@ -5,6 +5,10 @@ type Query {
5
5
  apiToken(
6
6
  token: String!
7
7
  ): ApiToken!
8
+ """Returns block data for the input blockNumbers or timestamps, maximum 25 inputs."""
9
+ blocks(
10
+ input: BlocksInput!
11
+ ): [Block!]!
8
12
  """Returns a list of all networks supported on Codex."""
9
13
  getNetworks: [Network!]!
10
14
  """Returns the status of a list of networks supported on Codex."""
@@ -455,6 +459,27 @@ type Query {
455
459
  inputs: [GetPriceInput]
456
460
  ): [Price]
457
461
  """Returns bar chart data to track price changes over time."""
462
+ getTokenBars(
463
+ """The ID of the pair or token (`pairAddress:networkId` or `tokenAddress:networkId`). If a token contract address is provided, the token's top pair is used. For example, `0xc02aaa39b223fe8d0a0e5c4f27ead9083c756cc2:1` returns WETH's top pair on Ethereum."""
464
+ symbol: String!
465
+ """The unix timestamp for the start of the requested range."""
466
+ from: Int!
467
+ """The unix timestamp for the end of the requested range."""
468
+ to: Int!
469
+ """The time frame for each candle. Available options are `1S`, `5S`, `15S`, `30S`, `1`, `5`, `15`, `30`, `60`, `240`, `720`, `1D`, `7D`. Resolutions lower than 1 minute are only updated for the last 24 hours due to the volume of data produced."""
470
+ resolution: String!
471
+ """The currency to use for the response. Can be `USD` or `TOKEN`. Default is `USD`. Use `currencyCode: TOKEN` for native token pricing."""
472
+ currencyCode: QuoteCurrency
473
+ """Whether to remove leading null values from the response. Default is `false`. To fetch a token's entire history, set resolution to `1D`, `from` value to `0` and `removeLeadingNullValues` to `true`."""
474
+ removeLeadingNullValues: Boolean
475
+ """Whether to remove empty bars from the response. This is useful for eliminating gaps in low-activity tokens. Default is `false`."""
476
+ removeEmptyBars: Boolean
477
+ """The token of interest within the token's top pair. Can be `token0` or `token1`. If omitted, the base token is inferred automatically. You can invert the pair by quoting the other token."""
478
+ statsType: TokenPairStatisticsType
479
+ """Guarantees number of bars returned is at most this number. Use `countback: 1500` with `from: 0` for maximum results."""
480
+ countback: Int
481
+ ): TokenBarsResponse
482
+ """Returns bar chart data to track price changes over time."""
458
483
  getBars(
459
484
  """The ID of the pair or token (`pairAddress:networkId` or `tokenAddress:networkId`). If a token contract address is provided, the token's top pair is used. For example, `0xc02aaa39b223fe8d0a0e5c4f27ead9083c756cc2:1` returns WETH's top pair on Ethereum."""
460
485
  symbol: String!
@@ -735,7 +760,7 @@ type Subscription {
735
760
  """The networkId to use when getting all bars per network"""
736
761
  networkId: Int
737
762
  ): OnTokenBarsUpdatedResponse
738
- """Live-streamed transactions for a token."""
763
+ """Live-streamed transactions for a pair."""
739
764
  onEventsCreated(
740
765
  """The pair contract address."""
741
766
  address: String
@@ -1062,6 +1087,18 @@ type BarsResponse {
1062
1087
  pair: Pair!
1063
1088
  }
1064
1089
 
1090
+ type Block {
1091
+ blockNumber: Int!
1092
+ timestamp: Int!
1093
+ hash: String!
1094
+ }
1095
+
1096
+ input BlocksInput {
1097
+ networkId: Int!
1098
+ blockNumbers: [Int!]
1099
+ timestamps: [Int!]
1100
+ }
1101
+
1065
1102
  """The mathematical formula that defines how the prices of NFTs change after each buy or sell within a pool."""
1066
1103
  enum BondingCurveType {
1067
1104
  EXPONENTIAL
@@ -1262,7 +1299,7 @@ input CreateApiTokensInput {
1262
1299
  count: Int
1263
1300
  """Number of requests allowed per token, represented as a string, default is 5000"""
1264
1301
  requestLimit: String
1265
- """Number of seconds until the token expires, defaults to 1 hour (3600)"""
1302
+ """Number of milliseconds until the token expires, defaults to 1 hour (3600000)"""
1266
1303
  expiresIn: Int
1267
1304
  }
1268
1305
 
@@ -2735,6 +2772,10 @@ enum LaunchpadTokenProtocol {
2735
2772
  Clanker
2736
2773
  """Protocol name for Heaven."""
2737
2774
  HeavenAMM
2775
+ """Protocol name for TokenMill V2."""
2776
+ TokenMillV2
2777
+ """Protocol name for Clanker V4."""
2778
+ ClankerV4
2738
2779
  }
2739
2780
 
2740
2781
  scalar link__Import
@@ -5684,9 +5725,9 @@ input OnLaunchpadTokenEventBatchInput {
5684
5725
  protocols: [LaunchpadTokenProtocol!]
5685
5726
  """The network ID that the token is deployed on."""
5686
5727
  networkId: Int
5687
- """The name of the launchpad. One of the following: Pump.fun, Bonk, Baseapp, Zora, Zora Creator, Four.meme, Believe, Moonshot, Jupiter Studio, boop, Heaven, Virtuals, Clanker, ArenaTrade, Moonit, LaunchLab, MeteoraDBC, Vertigo, Cooking.City, time.fun, BAGS, Circus, Dealr, OhFuckFun, PrintFun, Trend, shout.fun, xApple, Sendshot, DubDub, cults."""
5728
+ """The name of the launchpad. One of the following: Pump.fun, Bonk, Baseapp, Zora, Zora Creator, Four.meme, Believe, Moonshot, Jupiter Studio, boop, Heaven, TokenMill V2, Virtuals, Clanker, Clanker V4, ArenaTrade, Moonit, LaunchLab, MeteoraDBC, Vertigo, Cooking.City, time.fun, BAGS, Circus, Dealr, OhFuckFun, PrintFun, Trend, shout.fun, xApple, Sendshot, DubDub, cults."""
5688
5729
  launchpadName: String
5689
- """A list of launchpad names. Any of the following: Pump.fun, Bonk, Baseapp, Zora, Zora Creator, Four.meme, Believe, Moonshot, Jupiter Studio, boop, Heaven, Virtuals, Clanker, ArenaTrade, Moonit, LaunchLab, MeteoraDBC, Vertigo, Cooking.City, time.fun, BAGS, Circus, Dealr, OhFuckFun, PrintFun, Trend, shout.fun, xApple, Sendshot, DubDub, cults."""
5730
+ """A list of launchpad names. Any of the following: Pump.fun, Bonk, Baseapp, Zora, Zora Creator, Four.meme, Believe, Moonshot, Jupiter Studio, boop, Heaven, TokenMill V2, Virtuals, Clanker, Clanker V4, ArenaTrade, Moonit, LaunchLab, MeteoraDBC, Vertigo, Cooking.City, time.fun, BAGS, Circus, Dealr, OhFuckFun, PrintFun, Trend, shout.fun, xApple, Sendshot, DubDub, cults."""
5690
5731
  launchpadNames: [String!]
5691
5732
  """The type of event."""
5692
5733
  eventType: LaunchpadTokenEventType
@@ -5698,9 +5739,9 @@ input OnLaunchpadTokenEventInput {
5698
5739
  protocol: LaunchpadTokenProtocol
5699
5740
  """A list of launchpad protocols."""
5700
5741
  protocols: [LaunchpadTokenProtocol!]
5701
- """The name of the launchpad. One of the following: Pump.fun, Bonk, Baseapp, Zora, Zora Creator, Four.meme, Believe, Moonshot, Jupiter Studio, boop, Heaven, Virtuals, Clanker, ArenaTrade, Moonit, LaunchLab, MeteoraDBC, Vertigo, Cooking.City, time.fun, BAGS, Circus, Dealr, OhFuckFun, PrintFun, Trend, shout.fun, xApple, Sendshot, DubDub, cults."""
5742
+ """The name of the launchpad. One of the following: Pump.fun, Bonk, Baseapp, Zora, Zora Creator, Four.meme, Believe, Moonshot, Jupiter Studio, boop, Heaven, TokenMill V2, Virtuals, Clanker, Clanker V4, ArenaTrade, Moonit, LaunchLab, MeteoraDBC, Vertigo, Cooking.City, time.fun, BAGS, Circus, Dealr, OhFuckFun, PrintFun, Trend, shout.fun, xApple, Sendshot, DubDub, cults."""
5702
5743
  launchpadName: String
5703
- """A list of launchpad names. Any of the following: Pump.fun, Bonk, Baseapp, Zora, Zora Creator, Four.meme, Believe, Moonshot, Jupiter Studio, boop, Heaven, Virtuals, Clanker, ArenaTrade, Moonit, LaunchLab, MeteoraDBC, Vertigo, Cooking.City, time.fun, BAGS, Circus, Dealr, OhFuckFun, PrintFun, Trend, shout.fun, xApple, Sendshot, DubDub, cults."""
5744
+ """A list of launchpad names. Any of the following: Pump.fun, Bonk, Baseapp, Zora, Zora Creator, Four.meme, Believe, Moonshot, Jupiter Studio, boop, Heaven, TokenMill V2, Virtuals, Clanker, Clanker V4, ArenaTrade, Moonit, LaunchLab, MeteoraDBC, Vertigo, Cooking.City, time.fun, BAGS, Circus, Dealr, OhFuckFun, PrintFun, Trend, shout.fun, xApple, Sendshot, DubDub, cults."""
5704
5745
  launchpadNames: [String!]
5705
5746
  """The type of event."""
5706
5747
  eventType: LaunchpadTokenEventType
@@ -5719,11 +5760,11 @@ input OnPricesUpdatedInput {
5719
5760
  """Response returned by `onBarsUpdated`."""
5720
5761
  type OnTokenBarsUpdatedResponse {
5721
5762
  """The contract address for the pair."""
5722
- pairAddress: String!
5763
+ pairAddress: String @deprecated(reason: "pairs are no longer used for pricing")
5723
5764
  """The network ID the pair is deployed on."""
5724
5765
  networkId: Int!
5725
5766
  """The ID for the pair (`pairAddress`:`networkId`)."""
5726
- pairId: String!
5767
+ pairId: String @deprecated(reason: "pairs are no longer used for pricing")
5727
5768
  """The unix timestamp for the new bar."""
5728
5769
  timestamp: Int!
5729
5770
  """The type of statistics used. Can be `Filtered` or `Unfiltered`."""
@@ -5733,7 +5774,7 @@ type OnTokenBarsUpdatedResponse {
5733
5774
  """Price data broken down by resolution."""
5734
5775
  aggregates: ResolutionBarData!
5735
5776
  """The quote token within the pair."""
5736
- quoteToken: QuoteToken
5777
+ quoteToken: QuoteToken @deprecated(reason: "pairs are no longer used for pricing")
5737
5778
  """The address of the token being quoted"""
5738
5779
  tokenAddress: String!
5739
5780
  """The address of the token being quoted"""
@@ -6154,6 +6195,8 @@ type PairMetadata {
6154
6195
  statsType: TokenPairStatisticsType!
6155
6196
  """The quote token price in USD."""
6156
6197
  price: String!
6198
+ """The non-quote token price in USD."""
6199
+ priceNonQuoteToken: String!
6157
6200
  """The percent price change in the past 5 minutes. Decimal format."""
6158
6201
  priceChange5m: Float
6159
6202
  """The percent price change in the past hour. Decimal format."""
@@ -6621,6 +6664,8 @@ type Price {
6621
6664
  poolAddress: String!
6622
6665
  """Ratio of how confident we are in the price"""
6623
6666
  confidence: Float
6667
+ """The internal pool address for the price"""
6668
+ internalPoolAddress: String
6624
6669
  }
6625
6670
 
6626
6671
  """Webhook conditions for a price event."""
@@ -7649,6 +7694,46 @@ enum SymbolType {
7649
7694
  POOL
7650
7695
  }
7651
7696
 
7697
+ """Bar chart data to track price changes over time."""
7698
+ type TokenBarsResponse {
7699
+ """The opening price."""
7700
+ o: [Float]!
7701
+ """The high price."""
7702
+ h: [Float]!
7703
+ """The low price."""
7704
+ l: [Float]!
7705
+ """The closing price."""
7706
+ c: [Float]!
7707
+ """The timestamp for the bar."""
7708
+ t: [Int!]!
7709
+ """The status code for the batch: `ok` for successful data retrieval and `no_data` for empty responses signaling the end of server data."""
7710
+ s: String!
7711
+ """The volume with higher precision."""
7712
+ volume: [String]
7713
+ """The volume in the native token for the network"""
7714
+ volumeNativeToken: [String]
7715
+ """The number of unique buyers"""
7716
+ buyers: [Int]!
7717
+ """The number of buys"""
7718
+ buys: [Int]!
7719
+ """The buy volume in USD"""
7720
+ buyVolume: [String]!
7721
+ """The number of unique sellers"""
7722
+ sellers: [Int]!
7723
+ """The number of sells"""
7724
+ sells: [Int]!
7725
+ """The sell volume in USD"""
7726
+ sellVolume: [String]!
7727
+ """Liquidity in USD"""
7728
+ liquidity: [String]!
7729
+ """The number of traders"""
7730
+ traders: [Int]!
7731
+ """The number of transactions"""
7732
+ transactions: [Int]!
7733
+ """The token that is being returned"""
7734
+ token: EnhancedToken!
7735
+ }
7736
+
7652
7737
  """Token burn event data."""
7653
7738
  type TokenBurnEventData {
7654
7739
  """The amount of tokens burned."""
@@ -8011,15 +8096,15 @@ input TokenFilters {
8011
8096
  creatorAddress: String
8012
8097
  """A list of launchpad protocols."""
8013
8098
  launchpadProtocol: [String!]
8014
- """A list of launchpad names. Any of the following: Pump.fun, Bonk, Baseapp, Zora, Zora Creator, Four.meme, Believe, Moonshot, Jupiter Studio, boop, Heaven, Virtuals, Clanker, ArenaTrade, Moonit, LaunchLab, MeteoraDBC, Vertigo, Cooking.City, time.fun, BAGS, Circus, Dealr, OhFuckFun, PrintFun, Trend, shout.fun, xApple, Sendshot, DubDub, cults."""
8099
+ """A list of launchpad names. Any of the following: Pump.fun, Bonk, Baseapp, Zora, Zora Creator, Four.meme, Believe, Moonshot, Jupiter Studio, boop, Heaven, TokenMill V2, Virtuals, Clanker, Clanker V4, ArenaTrade, Moonit, LaunchLab, MeteoraDBC, Vertigo, Cooking.City, time.fun, BAGS, Circus, Dealr, OhFuckFun, PrintFun, Trend, shout.fun, xApple, Sendshot, DubDub, cults."""
8015
8100
  launchpadName: [String!]
8016
- """Indicates if the launchpad is completed"""
8101
+ """Indicates if the launchpad is completed."""
8017
8102
  launchpadCompleted: Boolean
8018
- """Indicates if the launchpad has migrated"""
8103
+ """Indicates if the launchpad has migrated."""
8019
8104
  launchpadMigrated: Boolean
8020
- """The graduation percentage"""
8105
+ """The graduation percentage."""
8021
8106
  launchpadGraduationPercent: NumberFilter
8022
- """The timestamp when the launchpad was completed"""
8107
+ """The timestamp when the launchpad was completed."""
8023
8108
  launchpadCompletedAt: NumberFilter
8024
8109
  """The timestamp when the launchpad was migrated"""
8025
8110
  launchpadMigratedAt: NumberFilter
@@ -8529,8 +8614,12 @@ type TokenWalletFilterResult {
8529
8614
  purchasedTokenBalance: String!
8530
8615
  """The token acquisition cost in USD"""
8531
8616
  tokenAcquisitionCostUsd: String!
8532
- """The current token balance"""
8617
+ """The token balance in the wallet. This value does not update with every transfer and can be slightly stale. Use tokenBalanceLive for live data."""
8533
8618
  tokenBalance: String!
8619
+ """The current token balance in the wallet."""
8620
+ tokenBalanceLive: String
8621
+ """The current USD value of the token balance."""
8622
+ tokenBalanceLiveUsd: String
8534
8623
  """The token metadata"""
8535
8624
  token: EnhancedToken!
8536
8625
  """The scammer score for the wallet."""
@@ -8744,6 +8833,8 @@ type UnconfirmedSwapEventData {
8744
8833
  type UniswapV4Data {
8745
8834
  """The address of the hook contract for Uniswap V4 pools."""
8746
8835
  uniswapV4HookAddress: String
8836
+ """Whether the token is the network token for the Uniswap V4 pool."""
8837
+ isToken0NetworkToken: Boolean
8747
8838
  type: String!
8748
8839
  }
8749
8840
 
@@ -15,15 +15,15 @@ import { Codex } from "./index";
15
15
 
16
16
  export class Mutation {
17
17
  constructor(private sdk: Codex) {}
18
- backfillWalletAggregates = async (
19
- vars: BackfillWalletAggregatesMutationVariables,
20
- ) => this.sdk.mutation(BackfillWalletAggregatesDocument, vars);
21
18
  createWebhooks = async (vars: CreateWebhooksMutationVariables) =>
22
19
  this.sdk.mutation(CreateWebhooksDocument, vars);
23
- deleteApiToken = async (vars: DeleteApiTokenMutationVariables) =>
24
- this.sdk.mutation(DeleteApiTokenDocument, vars);
25
- createApiTokens = async (vars: CreateApiTokensMutationVariables) =>
26
- this.sdk.mutation(CreateApiTokensDocument, vars);
27
20
  deleteWebhooks = async (vars: DeleteWebhooksMutationVariables) =>
28
21
  this.sdk.mutation(DeleteWebhooksDocument, vars);
22
+ createApiTokens = async (vars: CreateApiTokensMutationVariables) =>
23
+ this.sdk.mutation(CreateApiTokensDocument, vars);
24
+ deleteApiToken = async (vars: DeleteApiTokenMutationVariables) =>
25
+ this.sdk.mutation(DeleteApiTokenDocument, vars);
26
+ backfillWalletAggregates = async (
27
+ vars: BackfillWalletAggregatesMutationVariables,
28
+ ) => this.sdk.mutation(BackfillWalletAggregatesDocument, vars);
29
29
  }