@openfort/openfort-node 0.7.5 → 0.7.6
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/CHANGELOG.md +6 -0
- package/dist/index.d.mts +172 -250
- package/dist/index.d.ts +172 -250
- package/dist/index.js +17 -49
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +15 -46
- package/dist/index.mjs.map +1 -1
- package/openapi.json +83 -399
- package/package.json +1 -1
- package/examples/exchange/createSwap.ts +0 -50
- package/examples/exchange/quoteSwap.ts +0 -34
package/dist/index.js
CHANGED
|
@@ -96,6 +96,7 @@ __export(index_exports, {
|
|
|
96
96
|
EntityTypeTRANSACTIONINTENT: () => EntityTypeTRANSACTIONINTENT,
|
|
97
97
|
EntityTypeTRIGGER: () => EntityTypeTRIGGER,
|
|
98
98
|
EntityTypeUSER: () => EntityTypeUSER,
|
|
99
|
+
EntityTypeWALLET: () => EntityTypeWALLET,
|
|
99
100
|
ErrorTypeINVALIDREQUESTERROR: () => ErrorTypeINVALIDREQUESTERROR,
|
|
100
101
|
EvmClient: () => EvmClient,
|
|
101
102
|
ExportPrivateKeyResponseObject: () => ExportPrivateKeyResponseObject,
|
|
@@ -177,7 +178,6 @@ __export(index_exports, {
|
|
|
177
178
|
TimeIntervalType: () => TimeIntervalType,
|
|
178
179
|
TimeoutError: () => TimeoutError,
|
|
179
180
|
TokenType: () => TokenType,
|
|
180
|
-
TradeType: () => TradeType,
|
|
181
181
|
TransactionAbstractionType: () => TransactionAbstractionType,
|
|
182
182
|
TransactionIntentResponseExpandable: () => TransactionIntentResponseExpandable,
|
|
183
183
|
TransactionStatus: () => TransactionStatus,
|
|
@@ -216,7 +216,6 @@ __export(index_exports, {
|
|
|
216
216
|
createPolicyWithdrawal: () => createPolicyWithdrawal,
|
|
217
217
|
createSession: () => createSession,
|
|
218
218
|
createSubscription: () => createSubscription,
|
|
219
|
-
createSwap: () => createSwap,
|
|
220
219
|
createTransactionIntent: () => createTransactionIntent,
|
|
221
220
|
createTrigger: () => createTrigger,
|
|
222
221
|
decryptExportedPrivateKey: () => decryptExportedPrivateKey,
|
|
@@ -283,6 +282,7 @@ __export(index_exports, {
|
|
|
283
282
|
getTransactionIntents: () => getTransactionIntents,
|
|
284
283
|
getTrigger: () => getTrigger,
|
|
285
284
|
getTriggers: () => getTriggers,
|
|
285
|
+
getUserWallet: () => getUserWallet,
|
|
286
286
|
getVerificationPayload: () => getVerificationPayload,
|
|
287
287
|
getWebhookLogsByProjectId: () => getWebhookLogsByProjectId,
|
|
288
288
|
grantOAuth: () => grantOAuth,
|
|
@@ -312,7 +312,6 @@ __export(index_exports, {
|
|
|
312
312
|
poolOAuth: () => poolOAuth,
|
|
313
313
|
pregenerateUserV2: () => pregenerateUserV2,
|
|
314
314
|
query: () => query,
|
|
315
|
-
quoteSwap: () => quoteSwap,
|
|
316
315
|
readContract: () => readContract,
|
|
317
316
|
refresh: () => refresh,
|
|
318
317
|
registerGuest: () => registerGuest,
|
|
@@ -720,7 +719,7 @@ function requiresWalletAuth(requestMethod, requestPath) {
|
|
|
720
719
|
}
|
|
721
720
|
|
|
722
721
|
// src/version.ts
|
|
723
|
-
var VERSION = "0.7.
|
|
722
|
+
var VERSION = "0.7.6";
|
|
724
723
|
var PACKAGE = "@openfort/openfort-node";
|
|
725
724
|
|
|
726
725
|
// src/openapi-client/openfortApiClient.ts
|
|
@@ -2417,30 +2416,6 @@ var deleteEvent = (id, options) => {
|
|
|
2417
2416
|
);
|
|
2418
2417
|
};
|
|
2419
2418
|
|
|
2420
|
-
// src/openapi-client/generated/exchange/exchange.ts
|
|
2421
|
-
var createSwap = (createExchangeRequest, options) => {
|
|
2422
|
-
return openfortApiClient(
|
|
2423
|
-
{
|
|
2424
|
-
url: `/v1/exchange`,
|
|
2425
|
-
method: "POST",
|
|
2426
|
-
headers: { "Content-Type": "application/json" },
|
|
2427
|
-
data: createExchangeRequest
|
|
2428
|
-
},
|
|
2429
|
-
options
|
|
2430
|
-
);
|
|
2431
|
-
};
|
|
2432
|
-
var quoteSwap = (createExchangeRequest, options) => {
|
|
2433
|
-
return openfortApiClient(
|
|
2434
|
-
{
|
|
2435
|
-
url: `/v1/exchange/quote`,
|
|
2436
|
-
method: "POST",
|
|
2437
|
-
headers: { "Content-Type": "application/json" },
|
|
2438
|
-
data: createExchangeRequest
|
|
2439
|
-
},
|
|
2440
|
-
options
|
|
2441
|
-
);
|
|
2442
|
-
};
|
|
2443
|
-
|
|
2444
2419
|
// src/openapi-client/generated/forwarder-contract/forwarder-contract.ts
|
|
2445
2420
|
var createForwarderContract = (createForwarderContractRequest, options) => {
|
|
2446
2421
|
return openfortApiClient(
|
|
@@ -2731,10 +2706,6 @@ var OnrampProvider = {
|
|
|
2731
2706
|
var EntityTypeFORWARDERCONTRACT = {
|
|
2732
2707
|
forwarderContract: "forwarderContract"
|
|
2733
2708
|
};
|
|
2734
|
-
var TradeType = {
|
|
2735
|
-
EXACT_INPUT: "EXACT_INPUT",
|
|
2736
|
-
EXACT_OUTPUT: "EXACT_OUTPUT"
|
|
2737
|
-
};
|
|
2738
2709
|
var APITopicBALANCECONTRACT = {
|
|
2739
2710
|
balancecontract: "balance.contract"
|
|
2740
2711
|
};
|
|
@@ -2777,6 +2748,9 @@ var AuthProviderResponseV2 = {
|
|
|
2777
2748
|
oidc: "oidc",
|
|
2778
2749
|
siwe: "siwe"
|
|
2779
2750
|
};
|
|
2751
|
+
var EntityTypeWALLET = {
|
|
2752
|
+
wallet: "wallet"
|
|
2753
|
+
};
|
|
2780
2754
|
var PregenerateAccountResponseCustody = {
|
|
2781
2755
|
Developer: "Developer",
|
|
2782
2756
|
User: "User"
|
|
@@ -3727,6 +3701,15 @@ var deleteUser = (id, options) => {
|
|
|
3727
3701
|
options
|
|
3728
3702
|
);
|
|
3729
3703
|
};
|
|
3704
|
+
var getUserWallet = (id, options) => {
|
|
3705
|
+
return openfortApiClient(
|
|
3706
|
+
{
|
|
3707
|
+
url: `/v2/users/${id}/wallet`,
|
|
3708
|
+
method: "GET"
|
|
3709
|
+
},
|
|
3710
|
+
options
|
|
3711
|
+
);
|
|
3712
|
+
};
|
|
3730
3713
|
var pregenerateUserV2 = (pregenerateUserRequestV2, options) => {
|
|
3731
3714
|
return openfortApiClient(
|
|
3732
3715
|
{
|
|
@@ -4745,20 +4728,6 @@ var Openfort = class {
|
|
|
4745
4728
|
};
|
|
4746
4729
|
}
|
|
4747
4730
|
// ============================================
|
|
4748
|
-
// Exchange API
|
|
4749
|
-
// ============================================
|
|
4750
|
-
/**
|
|
4751
|
-
* Exchange endpoints
|
|
4752
|
-
*/
|
|
4753
|
-
get exchange() {
|
|
4754
|
-
return {
|
|
4755
|
-
/** Create swap */
|
|
4756
|
-
createSwap,
|
|
4757
|
-
/** Get swap quote */
|
|
4758
|
-
quoteSwap
|
|
4759
|
-
};
|
|
4760
|
-
}
|
|
4761
|
-
// ============================================
|
|
4762
4731
|
// Auth API
|
|
4763
4732
|
// ============================================
|
|
4764
4733
|
/**
|
|
@@ -5077,6 +5046,7 @@ var index_default = Openfort;
|
|
|
5077
5046
|
EntityTypeTRANSACTIONINTENT,
|
|
5078
5047
|
EntityTypeTRIGGER,
|
|
5079
5048
|
EntityTypeUSER,
|
|
5049
|
+
EntityTypeWALLET,
|
|
5080
5050
|
ErrorTypeINVALIDREQUESTERROR,
|
|
5081
5051
|
EvmClient,
|
|
5082
5052
|
ExportPrivateKeyResponseObject,
|
|
@@ -5158,7 +5128,6 @@ var index_default = Openfort;
|
|
|
5158
5128
|
TimeIntervalType,
|
|
5159
5129
|
TimeoutError,
|
|
5160
5130
|
TokenType,
|
|
5161
|
-
TradeType,
|
|
5162
5131
|
TransactionAbstractionType,
|
|
5163
5132
|
TransactionIntentResponseExpandable,
|
|
5164
5133
|
TransactionStatus,
|
|
@@ -5197,7 +5166,6 @@ var index_default = Openfort;
|
|
|
5197
5166
|
createPolicyWithdrawal,
|
|
5198
5167
|
createSession,
|
|
5199
5168
|
createSubscription,
|
|
5200
|
-
createSwap,
|
|
5201
5169
|
createTransactionIntent,
|
|
5202
5170
|
createTrigger,
|
|
5203
5171
|
decryptExportedPrivateKey,
|
|
@@ -5263,6 +5231,7 @@ var index_default = Openfort;
|
|
|
5263
5231
|
getTransactionIntents,
|
|
5264
5232
|
getTrigger,
|
|
5265
5233
|
getTriggers,
|
|
5234
|
+
getUserWallet,
|
|
5266
5235
|
getVerificationPayload,
|
|
5267
5236
|
getWebhookLogsByProjectId,
|
|
5268
5237
|
grantOAuth,
|
|
@@ -5292,7 +5261,6 @@ var index_default = Openfort;
|
|
|
5292
5261
|
poolOAuth,
|
|
5293
5262
|
pregenerateUserV2,
|
|
5294
5263
|
query,
|
|
5295
|
-
quoteSwap,
|
|
5296
5264
|
readContract,
|
|
5297
5265
|
refresh,
|
|
5298
5266
|
registerGuest,
|