@unicitylabs/sphere-sdk 0.16.0 → 0.17.1
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/dist/connect/index.cjs +11 -5
- package/dist/connect/index.cjs.map +1 -1
- package/dist/connect/index.d.cts +4 -1
- package/dist/connect/index.d.ts +4 -1
- package/dist/connect/index.js +11 -5
- package/dist/connect/index.js.map +1 -1
- package/dist/core/index.cjs +692 -268
- package/dist/core/index.cjs.map +1 -1
- package/dist/core/index.d.cts +69 -0
- package/dist/core/index.d.ts +69 -0
- package/dist/core/index.js +692 -268
- package/dist/core/index.js.map +1 -1
- package/dist/impl/browser/connect/index.cjs +11 -5
- package/dist/impl/browser/connect/index.cjs.map +1 -1
- package/dist/impl/browser/connect/index.d.cts +3 -1
- package/dist/impl/browser/connect/index.d.ts +3 -1
- package/dist/impl/browser/connect/index.js +11 -5
- package/dist/impl/browser/connect/index.js.map +1 -1
- package/dist/impl/nodejs/connect/index.cjs +10 -4
- package/dist/impl/nodejs/connect/index.cjs.map +1 -1
- package/dist/impl/nodejs/connect/index.d.cts +1 -1
- package/dist/impl/nodejs/connect/index.d.ts +1 -1
- package/dist/impl/nodejs/connect/index.js +10 -4
- package/dist/impl/nodejs/connect/index.js.map +1 -1
- package/dist/impl/nodejs/index.d.cts +11 -0
- package/dist/impl/nodejs/index.d.ts +11 -0
- package/dist/impl/shared/wallet-api/index.d.cts +11 -0
- package/dist/impl/shared/wallet-api/index.d.ts +11 -0
- package/dist/impl/wallet-api-v2/index.cjs +2 -0
- package/dist/impl/wallet-api-v2/index.cjs.map +1 -1
- package/dist/impl/wallet-api-v2/index.d.cts +13 -0
- package/dist/impl/wallet-api-v2/index.d.ts +13 -0
- package/dist/impl/wallet-api-v2/index.js +2 -0
- package/dist/impl/wallet-api-v2/index.js.map +1 -1
- package/dist/index.cjs +692 -268
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +63 -1
- package/dist/index.d.ts +63 -1
- package/dist/index.js +692 -268
- package/dist/index.js.map +1 -1
- package/dist/modules/payments-v2/index.cjs +767 -398
- package/dist/modules/payments-v2/index.cjs.map +1 -1
- package/dist/modules/payments-v2/index.d.cts +91 -14
- package/dist/modules/payments-v2/index.d.ts +91 -14
- package/dist/modules/payments-v2/index.js +767 -398
- package/dist/modules/payments-v2/index.js.map +1 -1
- package/dist/token-engine/index.cjs +132 -34
- package/dist/token-engine/index.cjs.map +1 -1
- package/dist/token-engine/index.d.cts +19 -0
- package/dist/token-engine/index.d.ts +19 -0
- package/dist/token-engine/index.js +132 -34
- package/dist/token-engine/index.js.map +1 -1
- package/package.json +1 -1
|
@@ -223,7 +223,7 @@ var SPHERE_NETWORKS = {
|
|
|
223
223
|
|
|
224
224
|
// connect/protocol.ts
|
|
225
225
|
var SPHERE_CONNECT_NAMESPACE = "sphere-connect";
|
|
226
|
-
var SPHERE_CONNECT_VERSION = "2.
|
|
226
|
+
var SPHERE_CONNECT_VERSION = "2.2";
|
|
227
227
|
var RPC_METHODS = {
|
|
228
228
|
GET_IDENTITY: "sphere_getIdentity",
|
|
229
229
|
GET_BALANCE: "sphere_getBalance",
|
|
@@ -246,7 +246,10 @@ var INTENT_ACTIONS = {
|
|
|
246
246
|
PAYMENT_REQUEST: "payment_request",
|
|
247
247
|
RECEIVE: "receive",
|
|
248
248
|
SIGN_MESSAGE: "sign_message",
|
|
249
|
-
MINT: "mint"
|
|
249
|
+
MINT: "mint",
|
|
250
|
+
// #777: params { to, tokenId, memo? }. Named NFT rather than 'send_token':
|
|
251
|
+
// coins are tokens too, so 'token' does not say which kind moves.
|
|
252
|
+
SEND_NFT: "send_nft"
|
|
250
253
|
};
|
|
251
254
|
var ERROR_CODES = {
|
|
252
255
|
// Standard JSON-RPC
|
|
@@ -340,7 +343,9 @@ var PERMISSION_SCOPES = {
|
|
|
340
343
|
DM_MANAGE: "dm:manage",
|
|
341
344
|
PAYMENT_REQUEST: "payment:request",
|
|
342
345
|
SIGN_REQUEST: "sign:request",
|
|
343
|
-
MINT_REQUEST: "mint:request"
|
|
346
|
+
MINT_REQUEST: "mint:request",
|
|
347
|
+
/** #777: moving a coinless token (an NFT). Distinct from transfer:request. */
|
|
348
|
+
NFT_TRANSFER: "nft:transfer"
|
|
344
349
|
};
|
|
345
350
|
var ALL_PERMISSIONS = Object.values(PERMISSION_SCOPES);
|
|
346
351
|
var DEFAULT_PERMISSIONS = [
|
|
@@ -367,7 +372,8 @@ var INTENT_PERMISSIONS = {
|
|
|
367
372
|
[INTENT_ACTIONS.PAYMENT_REQUEST]: PERMISSION_SCOPES.PAYMENT_REQUEST,
|
|
368
373
|
[INTENT_ACTIONS.RECEIVE]: PERMISSION_SCOPES.IDENTITY_READ,
|
|
369
374
|
[INTENT_ACTIONS.SIGN_MESSAGE]: PERMISSION_SCOPES.SIGN_REQUEST,
|
|
370
|
-
[INTENT_ACTIONS.MINT]: PERMISSION_SCOPES.MINT_REQUEST
|
|
375
|
+
[INTENT_ACTIONS.MINT]: PERMISSION_SCOPES.MINT_REQUEST,
|
|
376
|
+
[INTENT_ACTIONS.SEND_NFT]: PERMISSION_SCOPES.NFT_TRANSFER
|
|
371
377
|
};
|
|
372
378
|
|
|
373
379
|
// connect/host/payments-compat.ts
|