@opexa/portal-sdk 0.0.140 → 0.0.142

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.mjs CHANGED
@@ -1776,12 +1776,12 @@ const ve = {
1776
1776
  class pr {
1777
1777
  constructor(e) {
1778
1778
  d(this, "url");
1779
- d(this, "platform");
1780
- this.url = e.url, this.platform = e.platform;
1779
+ d(this, "options");
1780
+ this.url = e.url, this.options = e.fetchOptions ?? {};
1781
1781
  }
1782
1782
  get headers() {
1783
- const e = new Headers();
1784
- return e.append("Accept", "application/json, text/plain"), e.append("Content-Type", "application/json"), e.append("Platform-Code", this.platform), e.append("Role", "MEMBER"), e;
1783
+ const e = new Headers(this.options.headers);
1784
+ return e.append("Accept", "application/json, text/plain"), e.append("Content-Type", "application/json"), e;
1785
1785
  }
1786
1786
  async createSession(e) {
1787
1787
  const t = new Headers(this.headers);
@@ -3751,7 +3751,15 @@ class Ir {
3751
3751
  }
3752
3752
  }, N = new hr(new j(T, y)), v = new wr(new j(_, y)), S = new br(new j(p, y)), I = new lr(new j(f, y)), P = new gr(new j(w, y)), G = new yr(new j(k, y)), B = new Ar(new j(R, y)), C = new pr({
3753
3753
  url: u,
3754
- platform: a
3754
+ fetchOptions: {
3755
+ headers: {
3756
+ Role: "MEMBER",
3757
+ "Platform-Code": a,
3758
+ ...!c && {
3759
+ "Test-Pass": ""
3760
+ }
3761
+ }
3762
+ }
3755
3763
  }), O = new Dr({
3756
3764
  logs: s,
3757
3765
  authService: C,
@@ -4433,6 +4441,7 @@ class Ir {
4433
4441
  data: e.data.map(this.transformer.transform.cashback)
4434
4442
  } : e;
4435
4443
  }
4444
+ /** @deprecated */
4436
4445
  async bonus() {
4437
4446
  const e = await this.walletService.bonus();
4438
4447
  return e.ok ? {