@privy-io/js-sdk-core 0.6.1 → 0.7.0-beta-20231102133607
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/index.js +5 -7
- package/dist/index.mjs +5 -7
- package/package.json +4 -3
package/dist/index.js
CHANGED
|
@@ -1784,7 +1784,7 @@ class $99761f88b99b6cb6$export$2e2bcd8739ae039 {
|
|
|
1784
1784
|
|
|
1785
1785
|
|
|
1786
1786
|
var $af98a8a573bb7c25$exports = {};
|
|
1787
|
-
$af98a8a573bb7c25$exports = JSON.parse('{"name":"@privy-io/js-sdk-core","version":"0.
|
|
1787
|
+
$af98a8a573bb7c25$exports = JSON.parse('{"name":"@privy-io/js-sdk-core","version":"0.7.0-beta-20231102133607","description":"Vanilla JS client for the Privy Auth API","keywords":["authentication","authorization","identity","privacy","privy","user data","web3"],"license":"Apache-2.0","source":"./src/index.ts","main":"./dist/index.js","module":"./dist/index.mjs","types":"./dist/index.d.ts","exports":{".":{"require":"./dist/index.js","import":"./dist/index.mjs","types":"./dist/index.d.ts"}},"targets":{"main":{"isLibrary":true,"sourceMap":false},"module":{"isLibrary":true,"sourceMap":false}},"files":["dist/**/*","LICENSE","README.md"],"scripts":{"build":"npx parcel build --no-cache","clean":"rm -rf dist .turbo","prepublishOnly":"npm run clean && npm run build","dev":"npx parcel watch -p 1234","test":"jest --testMatch \\"**/test/unit/**/*.test.ts\\"","test:ci":"npm run test","test-integration":"jest --testMatch \\"**/test/integration/**/*.test.ts\\"","lint":"eslint \\"src/**/*.{ts,tsx,js,jsx}\\" && npx tsc --noEmit","format":"eslint \\"src/**/*.{ts,tsx,js,jsx}\\" --fix"},"devDependencies":{"@privy-io/tsconfig":"*","@privy-io/parcel-config":"*","@tsconfig/node16-strictest-esm":"^1.0.3","@types/text-encoding":"^0.0.37","parcel":"2.10.1"},"dependencies":{"@ethersproject/providers":"^5.7.2","@privy-io/public-api":"1.5.0-beta-20231102133607","eventemitter3":"^5.0.1","fetch-retry":"^5.0.6","jose":"^4.11.2","js-cookie":"^3.0.5","text-encoding":"^0.7.0","uuid":">=8 <10"},"author":"privy.io","browserslist":["defaults","node >= 18","not op_mini all"],"publishConfig":{"access":"public"}}');
|
|
1788
1788
|
|
|
1789
1789
|
|
|
1790
1790
|
|
|
@@ -1987,7 +1987,6 @@ class $5945f4703f62befa$export$9e80c3751b841788 {
|
|
|
1987
1987
|
#storage;
|
|
1988
1988
|
#clientId;
|
|
1989
1989
|
#sdkVersion;
|
|
1990
|
-
/** Populates the `origin` header for outgoing native app requests */ #nativeAppOrigin;
|
|
1991
1990
|
#fetch;
|
|
1992
1991
|
/**
|
|
1993
1992
|
* Constructor for PrivyInternal class
|
|
@@ -2004,10 +2003,9 @@ class $5945f4703f62befa$export$9e80c3751b841788 {
|
|
|
2004
2003
|
this.#sdkVersion = o.sdkVersion ?? this.#sdkVersion;
|
|
2005
2004
|
this.callbacks = o.callbacks;
|
|
2006
2005
|
// If the sdk is being used in a non-browser environment,
|
|
2007
|
-
// (native mobile app), the
|
|
2008
|
-
// when creating the privy client, otherwise outgoing requests
|
|
2009
|
-
|
|
2010
|
-
if (typeof document === "undefined") this.#nativeAppOrigin = o.nativeAppOrigin;
|
|
2006
|
+
// (native mobile app), the application identifier must be manually specified
|
|
2007
|
+
// when creating the privy client, otherwise outgoing requests will be rejected
|
|
2008
|
+
if (typeof document === "undefined") this.nativeAppIdentifier = o.nativeAppIdentifier;
|
|
2011
2009
|
this.session = new (0, $4a5ceffc04a8e7b0$export$1fb4852a55678982)({
|
|
2012
2010
|
storage: this.#storage,
|
|
2013
2011
|
isUsingServerCookies: false
|
|
@@ -2070,7 +2068,7 @@ class $5945f4703f62befa$export$9e80c3751b841788 {
|
|
|
2070
2068
|
headers.set("Authorization", `Bearer ${token}`);
|
|
2071
2069
|
headers.set("Content-Type", "application/json");
|
|
2072
2070
|
headers.set("Accept", "application/json");
|
|
2073
|
-
if (this
|
|
2071
|
+
if (this.nativeAppIdentifier) headers.set("x-native-app-identifier", this.nativeAppIdentifier);
|
|
2074
2072
|
return {
|
|
2075
2073
|
signal: (0, $6e80017c879d5d9d$export$2e2bcd8739ae039)(3000),
|
|
2076
2074
|
headers: headers,
|
package/dist/index.mjs
CHANGED
|
@@ -1747,7 +1747,7 @@ class $a3295537bbaaa670$export$2e2bcd8739ae039 {
|
|
|
1747
1747
|
|
|
1748
1748
|
|
|
1749
1749
|
var $53a9b3651331d972$exports = {};
|
|
1750
|
-
$53a9b3651331d972$exports = JSON.parse('{"name":"@privy-io/js-sdk-core","version":"0.
|
|
1750
|
+
$53a9b3651331d972$exports = JSON.parse('{"name":"@privy-io/js-sdk-core","version":"0.7.0-beta-20231102133607","description":"Vanilla JS client for the Privy Auth API","keywords":["authentication","authorization","identity","privacy","privy","user data","web3"],"license":"Apache-2.0","source":"./src/index.ts","main":"./dist/index.js","module":"./dist/index.mjs","types":"./dist/index.d.ts","exports":{".":{"require":"./dist/index.js","import":"./dist/index.mjs","types":"./dist/index.d.ts"}},"targets":{"main":{"isLibrary":true,"sourceMap":false},"module":{"isLibrary":true,"sourceMap":false}},"files":["dist/**/*","LICENSE","README.md"],"scripts":{"build":"npx parcel build --no-cache","clean":"rm -rf dist .turbo","prepublishOnly":"npm run clean && npm run build","dev":"npx parcel watch -p 1234","test":"jest --testMatch \\"**/test/unit/**/*.test.ts\\"","test:ci":"npm run test","test-integration":"jest --testMatch \\"**/test/integration/**/*.test.ts\\"","lint":"eslint \\"src/**/*.{ts,tsx,js,jsx}\\" && npx tsc --noEmit","format":"eslint \\"src/**/*.{ts,tsx,js,jsx}\\" --fix"},"devDependencies":{"@privy-io/tsconfig":"*","@privy-io/parcel-config":"*","@tsconfig/node16-strictest-esm":"^1.0.3","@types/text-encoding":"^0.0.37","parcel":"2.10.1"},"dependencies":{"@ethersproject/providers":"^5.7.2","@privy-io/public-api":"1.5.0-beta-20231102133607","eventemitter3":"^5.0.1","fetch-retry":"^5.0.6","jose":"^4.11.2","js-cookie":"^3.0.5","text-encoding":"^0.7.0","uuid":">=8 <10"},"author":"privy.io","browserslist":["defaults","node >= 18","not op_mini all"],"publishConfig":{"access":"public"}}');
|
|
1751
1751
|
|
|
1752
1752
|
|
|
1753
1753
|
|
|
@@ -1950,7 +1950,6 @@ class $83ff42e2a0f1e24a$export$9e80c3751b841788 {
|
|
|
1950
1950
|
#storage;
|
|
1951
1951
|
#clientId;
|
|
1952
1952
|
#sdkVersion;
|
|
1953
|
-
/** Populates the `origin` header for outgoing native app requests */ #nativeAppOrigin;
|
|
1954
1953
|
#fetch;
|
|
1955
1954
|
/**
|
|
1956
1955
|
* Constructor for PrivyInternal class
|
|
@@ -1967,10 +1966,9 @@ class $83ff42e2a0f1e24a$export$9e80c3751b841788 {
|
|
|
1967
1966
|
this.#sdkVersion = o.sdkVersion ?? this.#sdkVersion;
|
|
1968
1967
|
this.callbacks = o.callbacks;
|
|
1969
1968
|
// If the sdk is being used in a non-browser environment,
|
|
1970
|
-
// (native mobile app), the
|
|
1971
|
-
// when creating the privy client, otherwise outgoing requests
|
|
1972
|
-
|
|
1973
|
-
if (typeof document === "undefined") this.#nativeAppOrigin = o.nativeAppOrigin;
|
|
1969
|
+
// (native mobile app), the application identifier must be manually specified
|
|
1970
|
+
// when creating the privy client, otherwise outgoing requests will be rejected
|
|
1971
|
+
if (typeof document === "undefined") this.nativeAppIdentifier = o.nativeAppIdentifier;
|
|
1974
1972
|
this.session = new (0, $0b6eb30d38bf8477$export$1fb4852a55678982)({
|
|
1975
1973
|
storage: this.#storage,
|
|
1976
1974
|
isUsingServerCookies: false
|
|
@@ -2033,7 +2031,7 @@ class $83ff42e2a0f1e24a$export$9e80c3751b841788 {
|
|
|
2033
2031
|
headers.set("Authorization", `Bearer ${token}`);
|
|
2034
2032
|
headers.set("Content-Type", "application/json");
|
|
2035
2033
|
headers.set("Accept", "application/json");
|
|
2036
|
-
if (this
|
|
2034
|
+
if (this.nativeAppIdentifier) headers.set("x-native-app-identifier", this.nativeAppIdentifier);
|
|
2037
2035
|
return {
|
|
2038
2036
|
signal: (0, $972f0079ffedc5b0$export$2e2bcd8739ae039)(3000),
|
|
2039
2037
|
headers: headers,
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@privy-io/js-sdk-core",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.7.0-beta-20231102133607",
|
|
4
4
|
"description": "Vanilla JS client for the Privy Auth API",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"authentication",
|
|
@@ -51,13 +51,14 @@
|
|
|
51
51
|
},
|
|
52
52
|
"devDependencies": {
|
|
53
53
|
"@privy-io/tsconfig": "*",
|
|
54
|
+
"@privy-io/parcel-config": "*",
|
|
54
55
|
"@tsconfig/node16-strictest-esm": "^1.0.3",
|
|
55
56
|
"@types/text-encoding": "^0.0.37",
|
|
56
|
-
"parcel": "2.10.
|
|
57
|
+
"parcel": "2.10.1"
|
|
57
58
|
},
|
|
58
59
|
"dependencies": {
|
|
59
60
|
"@ethersproject/providers": "^5.7.2",
|
|
60
|
-
"@privy-io/public-api": "
|
|
61
|
+
"@privy-io/public-api": "1.5.0-beta-20231102133607",
|
|
61
62
|
"eventemitter3": "^5.0.1",
|
|
62
63
|
"fetch-retry": "^5.0.6",
|
|
63
64
|
"jose": "^4.11.2",
|