@gearbox-protocol/sdk 12.3.14 → 12.3.16

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.
@@ -101,7 +101,7 @@ class TokenCompressorContract extends import_sdk.BaseContract {
101
101
  const postfix = multivaultSymbol ? `[${multivaultSymbol}]` : "";
102
102
  return {
103
103
  ...tokenInfo,
104
- symbol: `${tokenInfo.symbol} ${postfix}`
104
+ symbol: !postfix ? tokenInfo.symbol : `${tokenInfo.symbol} ${postfix}`
105
105
  };
106
106
  });
107
107
  return tokenInfos;
@@ -114,15 +114,9 @@ class GearboxBackendApi {
114
114
  return `${LEADERBOARD_APIS[chainId]}${url}`;
115
115
  };
116
116
  static getReferralUrl = () => REFERRAL_API;
117
- static apyServerAllRewards = (chainId) => URLApi.getRelativeUrl("https://apy-server.fly.dev/api/rewards/tokens/all", {
118
- params: { chain_id: chainId }
119
- });
120
- static apyServerGearAPY = (chainId) => URLApi.getRelativeUrl("https://apy-server.fly.dev/api/rewards/gear-apy", {
121
- params: { chain_id: chainId }
122
- });
123
- static apyServerAllPoolRewards = (chainId) => URLApi.getRelativeUrl("https://apy-server.fly.dev/api/rewards/pools/all", {
124
- params: { chain_id: chainId }
125
- });
117
+ static apyAllRewards = () => URLApi.getRelativeUrl(
118
+ "https://state-cache.gearbox.foundation/apy-server/latest.json"
119
+ );
126
120
  }
127
121
  class URLApi {
128
122
  static getRelativeUrl = (url, options) => {
@@ -81,7 +81,7 @@ class TokenCompressorContract extends BaseContract {
81
81
  const postfix = multivaultSymbol ? `[${multivaultSymbol}]` : "";
82
82
  return {
83
83
  ...tokenInfo,
84
- symbol: `${tokenInfo.symbol} ${postfix}`
84
+ symbol: !postfix ? tokenInfo.symbol : `${tokenInfo.symbol} ${postfix}`
85
85
  };
86
86
  });
87
87
  return tokenInfos;
@@ -85,15 +85,9 @@ class GearboxBackendApi {
85
85
  return `${LEADERBOARD_APIS[chainId]}${url}`;
86
86
  };
87
87
  static getReferralUrl = () => REFERRAL_API;
88
- static apyServerAllRewards = (chainId) => URLApi.getRelativeUrl("https://apy-server.fly.dev/api/rewards/tokens/all", {
89
- params: { chain_id: chainId }
90
- });
91
- static apyServerGearAPY = (chainId) => URLApi.getRelativeUrl("https://apy-server.fly.dev/api/rewards/gear-apy", {
92
- params: { chain_id: chainId }
93
- });
94
- static apyServerAllPoolRewards = (chainId) => URLApi.getRelativeUrl("https://apy-server.fly.dev/api/rewards/pools/all", {
95
- params: { chain_id: chainId }
96
- });
88
+ static apyAllRewards = () => URLApi.getRelativeUrl(
89
+ "https://state-cache.gearbox.foundation/apy-server/latest.json"
90
+ );
97
91
  }
98
92
  class URLApi {
99
93
  static getRelativeUrl = (url, options) => {
@@ -13,9 +13,7 @@ export declare class GearboxBackendApi {
13
13
  static getNFTMerkleUrl: (network: NetworkType, root: Address) => string;
14
14
  static getLeaderboardUrl: (url: string, chainId: number) => string;
15
15
  static getReferralUrl: () => string;
16
- static apyServerAllRewards: (chainId: number) => string;
17
- static apyServerGearAPY: (chainId: number) => string;
18
- static apyServerAllPoolRewards: (chainId: number) => string;
16
+ static apyAllRewards: () => string;
19
17
  }
20
18
  interface Options {
21
19
  params?: Record<string, string | number>;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@gearbox-protocol/sdk",
3
- "version": "12.3.14",
3
+ "version": "12.3.16",
4
4
  "description": "Gearbox SDK",
5
5
  "license": "MIT",
6
6
  "main": "./dist/cjs/sdk/index.js",