From 000eb34ab38824d37f4de1a394f307bbc1b937b4 Mon Sep 17 00:00:00 2001 From: Patrick Gallagher Date: Wed, 24 Jul 2024 22:35:18 -0700 Subject: [PATCH 1/4] Add Pt tokens and simplify icons --- package.json | 2 +- src/contracts/addreses.ts | 20 +++++++++++++++++++- src/utils.ts | 31 +++++++++++-------------------- 3 files changed, 31 insertions(+), 22 deletions(-) diff --git a/package.json b/package.json index 71b45bd..d769705 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "@opendollar/sdk", - "version": "1.7.4-rc.3", + "version": "1.7.5", "description": "Javascript client for Open Dollar", "license": "MIT", "main": "lib", diff --git a/src/contracts/addreses.ts b/src/contracts/addreses.ts index 0587ae0..22d2620 100644 --- a/src/contracts/addreses.ts +++ b/src/contracts/addreses.ts @@ -1,4 +1,4 @@ -import { WETH, ARB, OD, WSTETH, CBETH, RETH, OP, GRT, PUFETH } from '../utils' +import { WETH, ARB, OD, WSTETH, CBETH, RETH, OP, GRT, PUFETH, PT_wstETH_26JUN2025, PT_rETH_26JUN2025 } from '../utils' // All keys are mandatory export type ContractKey = @@ -238,6 +238,24 @@ const tokens: Record = { bytes32String: GRT, isCollateral: true, }, + 'PT-rETH-26JUN2025': { + address: '0x685155D3BD593508Fe32Be39729810A591ED9c87', + collateralJoin: '0x3bdbf35fda5b7235e7a381466c436392f259c22c', + collateralAuctionHouse: '0x2cC2D6b1027E4d56D6C73dFb8624142F6ac478D5', + decimals: 18, + symbol: 'PT-rETH-26JUN2025', + bytes32String: PT_rETH_26JUN2025, + isCollateral: true, + }, + 'PT-wstETH-26JUN2025': { + address: '0x1255638EFeca62e12E344E0b6B22ea853eC6e2c7', + collateralJoin: '0xe4c6aff8d5733905d35cb590a52ee51318d27f49', + collateralAuctionHouse: '0xd5Bf49BE72D6c2dbaB744086cD879C18b8071E65', + decimals: 18, + symbol: 'PT-wstETH-26JUN2025', + bytes32String: PT_wstETH_26JUN2025, + isCollateral: true, + }, }, 'arbitrum-sepolia': { OD: { diff --git a/src/utils.ts b/src/utils.ts index c079818..3db6c21 100644 --- a/src/utils.ts +++ b/src/utils.ts @@ -49,15 +49,17 @@ export function fromBigNumber(number: BigNumber, decimals: number = 18): number /** * byte32 values for each collateral */ -const WETH = '0x5745544800000000000000000000000000000000000000000000000000000000' -const ARB = '0x4152420000000000000000000000000000000000000000000000000000000000' -const OD = '0x4f44000000000000000000000000000000000000000000000000000000000000' -const WSTETH = '0x5753544554480000000000000000000000000000000000000000000000000000' -const CBETH = '0x4342455448000000000000000000000000000000000000000000000000000000' -const RETH = '0x5245544800000000000000000000000000000000000000000000000000000000' -const OP = '0x4f50000000000000000000000000000000000000000000000000000000000000' -const PUFETH = '0x5055464554480000000000000000000000000000000000000000000000000000' -const GRT = '0x4752540000000000000000000000000000000000000000000000000000000000' +export const WETH = '0x5745544800000000000000000000000000000000000000000000000000000000' +export const ARB = '0x4152420000000000000000000000000000000000000000000000000000000000' +export const OD = '0x4f44000000000000000000000000000000000000000000000000000000000000' +export const WSTETH = '0x5753544554480000000000000000000000000000000000000000000000000000' +export const CBETH = '0x4342455448000000000000000000000000000000000000000000000000000000' +export const RETH = '0x5245544800000000000000000000000000000000000000000000000000000000' +export const OP = '0x4f50000000000000000000000000000000000000000000000000000000000000' +export const PUFETH = '0x5055464554480000000000000000000000000000000000000000000000000000' +export const GRT = '0x4752540000000000000000000000000000000000000000000000000000000000' +export const PT_wstETH_26JUN2025 = '0x50542d7773744554482d32364a554e3230323500000000000000000000000000' +export const PT_rETH_26JUN2025 = '0x50542d724554482d32364a554e32303235000000000000000000000000000000' /** * 0x0 address or burn address @@ -149,17 +151,6 @@ const getRequireString = (error: any): string | null => { } export { - // Constants - WETH, - ARB, - OD, - WSTETH, - CBETH, - RETH, - OP, - GRT, - PUFETH, - // MAGIC, NULL_ADDRESS, WAD, RAY, From 801a6acbf1ffd26ef2eb011a635ad5b45e22507a Mon Sep 17 00:00:00 2001 From: Patrick Gallagher Date: Thu, 25 Jul 2024 21:47:56 -0700 Subject: [PATCH 2/4] Initial draft for ARB-Griff --- src/contracts/addreses.ts | 24 +++++++++++++++++++++++- src/utils.ts | 1 + 2 files changed, 24 insertions(+), 1 deletion(-) diff --git a/src/contracts/addreses.ts b/src/contracts/addreses.ts index 22d2620..1d8c0d6 100644 --- a/src/contracts/addreses.ts +++ b/src/contracts/addreses.ts @@ -1,4 +1,17 @@ -import { WETH, ARB, OD, WSTETH, CBETH, RETH, OP, GRT, PUFETH, PT_wstETH_26JUN2025, PT_rETH_26JUN2025 } from '../utils' +import { + WETH, + ARB, + OD, + WSTETH, + CBETH, + RETH, + OP, + GRT, + PUFETH, + PT_wstETH_26JUN2025, + PT_rETH_26JUN2025, + ARB_Griff, +} from '../utils' // All keys are mandatory export type ContractKey = @@ -256,6 +269,15 @@ const tokens: Record = { bytes32String: PT_wstETH_26JUN2025, isCollateral: true, }, + 'ARB-Griff': { + address: '0x912CE59144191C1204E64559FE8253a0e49E6548', + collateralJoin: '', // Pending execution of Pendle asset proposal + collateralAuctionHouse: '', // Pending execution of Pendle asset proposal + decimals: 18, + symbol: 'ARB-Griff', + bytes32String: ARB_Griff, + isCollateral: true, + }, }, 'arbitrum-sepolia': { OD: { diff --git a/src/utils.ts b/src/utils.ts index 3db6c21..1d63ff3 100644 --- a/src/utils.ts +++ b/src/utils.ts @@ -60,6 +60,7 @@ export const PUFETH = '0x5055464554480000000000000000000000000000000000000000000 export const GRT = '0x4752540000000000000000000000000000000000000000000000000000000000' export const PT_wstETH_26JUN2025 = '0x50542d7773744554482d32364a554e3230323500000000000000000000000000' export const PT_rETH_26JUN2025 = '0x50542d724554482d32364a554e32303235000000000000000000000000000000' +export const ARB_Griff = '0x4152422d47726966660000000000000000000000000000000000000000000000' /** * 0x0 address or burn address From 4a0e11cbd05034e61628a1575dbd16cb5a71cdc8 Mon Sep 17 00:00:00 2001 From: Patrick Gallagher Date: Thu, 1 Aug 2024 14:04:30 -0700 Subject: [PATCH 3/4] Add ARB-Griff collateralJoin and collateralAuctionHouse --- src/contracts/addreses.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/contracts/addreses.ts b/src/contracts/addreses.ts index 1d8c0d6..fb79128 100644 --- a/src/contracts/addreses.ts +++ b/src/contracts/addreses.ts @@ -271,8 +271,8 @@ const tokens: Record = { }, 'ARB-Griff': { address: '0x912CE59144191C1204E64559FE8253a0e49E6548', - collateralJoin: '', // Pending execution of Pendle asset proposal - collateralAuctionHouse: '', // Pending execution of Pendle asset proposal + collateralJoin: '0x9c4dea4c1e4c9300c8eb67356e701cafdb966c37', + collateralAuctionHouse: '0x4fb268e154571b7a99f85d69732255b16b98b4b4', decimals: 18, symbol: 'ARB-Griff', bytes32String: ARB_Griff, From 7c912af674f4884416e2b5f262352f5f3d2937e9 Mon Sep 17 00:00:00 2001 From: Patrick Gallagher Date: Sun, 4 Aug 2024 19:41:12 -0700 Subject: [PATCH 4/4] bump version --- package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/package.json b/package.json index d769705..f2ebd47 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "@opendollar/sdk", - "version": "1.7.5", + "version": "1.7.6", "description": "Javascript client for Open Dollar", "license": "MIT", "main": "lib",