@0xsequence/api 0.0.0-20231205222341 → 0.0.0-20240111142017
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.
|
@@ -61,6 +61,8 @@ let SortOrder = /*#__PURE__*/function (SortOrder) {
|
|
|
61
61
|
//
|
|
62
62
|
class API {
|
|
63
63
|
constructor(hostname, fetch) {
|
|
64
|
+
this.hostname = void 0;
|
|
65
|
+
this.fetch = void 0;
|
|
64
66
|
this.path = '/rpc/API/';
|
|
65
67
|
this.ping = headers => {
|
|
66
68
|
return this.fetch(this.url('Ping'), createHTTPRequest({}, headers)).then(res => {
|
|
@@ -600,8 +602,10 @@ const buildResponse = res => {
|
|
|
600
602
|
|
|
601
603
|
const fetch = typeof global === 'object' ? global.fetch : window.fetch;
|
|
602
604
|
class SequenceAPIClient extends API {
|
|
603
|
-
constructor(hostname,
|
|
605
|
+
constructor(hostname, projectAccessKey, jwtAuth) {
|
|
604
606
|
super(hostname.endsWith('/') ? hostname.slice(0, -1) : hostname, fetch);
|
|
607
|
+
this.projectAccessKey = projectAccessKey;
|
|
608
|
+
this.jwtAuth = jwtAuth;
|
|
605
609
|
this._fetch = (input, init) => {
|
|
606
610
|
// automatically include jwt and access key auth header to requests
|
|
607
611
|
// if its been set on the api client
|
|
@@ -619,8 +623,6 @@ class SequenceAPIClient extends API {
|
|
|
619
623
|
init.headers = _extends({}, init.headers, headers);
|
|
620
624
|
return fetch(input, init);
|
|
621
625
|
};
|
|
622
|
-
this.projectAccessKey = _projectAccessKey;
|
|
623
|
-
this.jwtAuth = _jwtAuth;
|
|
624
626
|
this.fetch = this._fetch;
|
|
625
627
|
}
|
|
626
628
|
}
|
|
@@ -61,6 +61,8 @@ let SortOrder = /*#__PURE__*/function (SortOrder) {
|
|
|
61
61
|
//
|
|
62
62
|
class API {
|
|
63
63
|
constructor(hostname, fetch) {
|
|
64
|
+
this.hostname = void 0;
|
|
65
|
+
this.fetch = void 0;
|
|
64
66
|
this.path = '/rpc/API/';
|
|
65
67
|
this.ping = headers => {
|
|
66
68
|
return this.fetch(this.url('Ping'), createHTTPRequest({}, headers)).then(res => {
|
|
@@ -600,8 +602,10 @@ const buildResponse = res => {
|
|
|
600
602
|
|
|
601
603
|
const fetch = typeof global === 'object' ? global.fetch : window.fetch;
|
|
602
604
|
class SequenceAPIClient extends API {
|
|
603
|
-
constructor(hostname,
|
|
605
|
+
constructor(hostname, projectAccessKey, jwtAuth) {
|
|
604
606
|
super(hostname.endsWith('/') ? hostname.slice(0, -1) : hostname, fetch);
|
|
607
|
+
this.projectAccessKey = projectAccessKey;
|
|
608
|
+
this.jwtAuth = jwtAuth;
|
|
605
609
|
this._fetch = (input, init) => {
|
|
606
610
|
// automatically include jwt and access key auth header to requests
|
|
607
611
|
// if its been set on the api client
|
|
@@ -619,8 +623,6 @@ class SequenceAPIClient extends API {
|
|
|
619
623
|
init.headers = _extends({}, init.headers, headers);
|
|
620
624
|
return fetch(input, init);
|
|
621
625
|
};
|
|
622
|
-
this.projectAccessKey = _projectAccessKey;
|
|
623
|
-
this.jwtAuth = _jwtAuth;
|
|
624
626
|
this.fetch = this._fetch;
|
|
625
627
|
}
|
|
626
628
|
}
|
|
@@ -57,6 +57,8 @@ let SortOrder = /*#__PURE__*/function (SortOrder) {
|
|
|
57
57
|
//
|
|
58
58
|
class API {
|
|
59
59
|
constructor(hostname, fetch) {
|
|
60
|
+
this.hostname = void 0;
|
|
61
|
+
this.fetch = void 0;
|
|
60
62
|
this.path = '/rpc/API/';
|
|
61
63
|
this.ping = headers => {
|
|
62
64
|
return this.fetch(this.url('Ping'), createHTTPRequest({}, headers)).then(res => {
|
|
@@ -596,8 +598,10 @@ const buildResponse = res => {
|
|
|
596
598
|
|
|
597
599
|
const fetch = typeof global === 'object' ? global.fetch : window.fetch;
|
|
598
600
|
class SequenceAPIClient extends API {
|
|
599
|
-
constructor(hostname,
|
|
601
|
+
constructor(hostname, projectAccessKey, jwtAuth) {
|
|
600
602
|
super(hostname.endsWith('/') ? hostname.slice(0, -1) : hostname, fetch);
|
|
603
|
+
this.projectAccessKey = projectAccessKey;
|
|
604
|
+
this.jwtAuth = jwtAuth;
|
|
601
605
|
this._fetch = (input, init) => {
|
|
602
606
|
// automatically include jwt and access key auth header to requests
|
|
603
607
|
// if its been set on the api client
|
|
@@ -615,8 +619,6 @@ class SequenceAPIClient extends API {
|
|
|
615
619
|
init.headers = _extends({}, init.headers, headers);
|
|
616
620
|
return fetch(input, init);
|
|
617
621
|
};
|
|
618
|
-
this.projectAccessKey = _projectAccessKey;
|
|
619
|
-
this.jwtAuth = _jwtAuth;
|
|
620
622
|
this.fetch = this._fetch;
|
|
621
623
|
}
|
|
622
624
|
}
|
package/package.json
CHANGED