@magmaprotocol/magma-clmm-sdk 0.5.66 → 0.5.68
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.
- package/README.md +9 -5
- package/dist/index.d.ts +5 -4
- package/dist/index.js +153 -330
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +153 -330
- package/dist/index.mjs.map +1 -1
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -43,7 +43,7 @@ Our SDK now includes a default initialization method that allows for quick gener
|
|
|
43
43
|
```typescript
|
|
44
44
|
import { initMagmaSDK } from '@magmaprotocol/magma-clmm-sdk'
|
|
45
45
|
|
|
46
|
-
const magmaClmmSDK = initMagmaSDK({network: 'mainnet'})
|
|
46
|
+
const magmaClmmSDK = initMagmaSDK({ network: 'mainnet' })
|
|
47
47
|
```
|
|
48
48
|
|
|
49
49
|
If you wish to set your own full node URL and simulate address, you can do so as follows:
|
|
@@ -51,24 +51,28 @@ If you wish to set your own full node URL and simulate address, you can do so as
|
|
|
51
51
|
```typescript
|
|
52
52
|
import { initMagmaSDK } from '@magmaprotocol/magma-clmm-sdk'
|
|
53
53
|
|
|
54
|
-
const network = 'mainnnet'
|
|
55
|
-
const fullNodeUrl =
|
|
56
|
-
const simulationAccount =
|
|
57
|
-
const magmaClmmSDK = initMagmaSDK({network, fullNodeUrl, simulationAccount})
|
|
54
|
+
const network = 'mainnnet'
|
|
55
|
+
const fullNodeUrl = 'https://...'
|
|
56
|
+
const simulationAccount = '0x...'
|
|
57
|
+
const magmaClmmSDK = initMagmaSDK({ network, fullNodeUrl, simulationAccount })
|
|
58
58
|
```
|
|
59
59
|
|
|
60
60
|
Now, you can start using Magma SDK.
|
|
61
61
|
|
|
62
62
|
### Typrscript Doc
|
|
63
|
+
|
|
63
64
|
You can view this typescript sdk in
|
|
64
65
|
<a href="https://github.com/MagmaFinanceIO/magma_sdk_doc"><strong> Magma Development Documents. </strong></a>
|
|
65
66
|
<br />
|
|
66
67
|
|
|
67
68
|
## LICENSE
|
|
69
|
+
|
|
68
70
|
MAGMA-CLMM-SDK released under the Apache license. See the [LICENSE](./LICENSE) file for details.
|
|
69
71
|
|
|
70
72
|
## More About Magma
|
|
73
|
+
|
|
71
74
|
Use the following links to learn more about Magma:
|
|
75
|
+
|
|
72
76
|
- [ ] Learn more about working with Magma in the [Magma Documentation]().
|
|
73
77
|
|
|
74
78
|
- [ ] Join the Magma community on [Magma Discord]().
|
package/dist/index.d.ts
CHANGED
|
@@ -1754,6 +1754,7 @@ type DlmmPoolInfo = {
|
|
|
1754
1754
|
active_index: number;
|
|
1755
1755
|
coinAmountA: string;
|
|
1756
1756
|
coinAmountB: string;
|
|
1757
|
+
index?: number;
|
|
1757
1758
|
};
|
|
1758
1759
|
type DlmmAddLiquidityParams = {
|
|
1759
1760
|
pool_id: string;
|
|
@@ -1832,7 +1833,7 @@ type DlmmCreatePairAddLiquidityParams = {
|
|
|
1832
1833
|
coinTypeA: string;
|
|
1833
1834
|
coinTypeB: string;
|
|
1834
1835
|
activeId: number;
|
|
1835
|
-
|
|
1836
|
+
realIds: number[];
|
|
1836
1837
|
amountsX: number[];
|
|
1837
1838
|
amountsY: number[];
|
|
1838
1839
|
to: string;
|
|
@@ -2416,9 +2417,9 @@ type CollectFeesQuote = {
|
|
|
2416
2417
|
declare function collectFeesQuote(param: CollectFeesQuoteParam): CollectFeesQuote;
|
|
2417
2418
|
|
|
2418
2419
|
declare enum StrategyType {
|
|
2419
|
-
Spot =
|
|
2420
|
-
Curve =
|
|
2421
|
-
BidAsk =
|
|
2420
|
+
Spot = 1,
|
|
2421
|
+
Curve = 2,
|
|
2422
|
+
BidAsk = 3
|
|
2422
2423
|
}
|
|
2423
2424
|
type BinLiquidity = {
|
|
2424
2425
|
ActiveId: number;
|