@bigso/auth-sdk 0.5.0 → 0.5.2

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.
@@ -1,4 +1,4 @@
1
- import { B as BigsoAuthOptions, a as BigsoAuthResult } from '../types-BQzACpj3.cjs';
1
+ import { B as BigsoAuthOptions, a as BigsoAuthResult } from '../types-D5BaCbus.cjs';
2
2
 
3
3
  declare class EventEmitter {
4
4
  private events;
@@ -1,4 +1,4 @@
1
- import { B as BigsoAuthOptions, a as BigsoAuthResult } from '../types-BQzACpj3.js';
1
+ import { B as BigsoAuthOptions, a as BigsoAuthResult } from '../types-D5BaCbus.js';
2
2
 
3
3
  declare class EventEmitter {
4
4
  private events;
@@ -1,6 +1,6 @@
1
1
  import { Request, Response, NextFunction, Router } from 'express';
2
2
  import { BigsoSsoClient } from '../node/index.cjs';
3
- import { S as SsoTokenPayload, V as V2ExchangeResponse } from '../types-BQzACpj3.cjs';
3
+ import { S as SsoJwtTenant, b as SsoTokenPayload, V as V2ExchangeResponse } from '../types-D5BaCbus.cjs';
4
4
 
5
5
  interface SsoAuthMiddlewareOptions {
6
6
  ssoClient: BigsoSsoClient;
@@ -14,12 +14,7 @@ declare global {
14
14
  firstName: string;
15
15
  lastName: string;
16
16
  };
17
- tenant?: {
18
- tenantId: string;
19
- name: string;
20
- slug: string;
21
- role: string;
22
- };
17
+ tenant?: SsoJwtTenant;
23
18
  tokenPayload?: SsoTokenPayload;
24
19
  }
25
20
  }
@@ -1,6 +1,6 @@
1
1
  import { Request, Response, NextFunction, Router } from 'express';
2
2
  import { BigsoSsoClient } from '../node/index.js';
3
- import { S as SsoTokenPayload, V as V2ExchangeResponse } from '../types-BQzACpj3.js';
3
+ import { S as SsoJwtTenant, b as SsoTokenPayload, V as V2ExchangeResponse } from '../types-D5BaCbus.js';
4
4
 
5
5
  interface SsoAuthMiddlewareOptions {
6
6
  ssoClient: BigsoSsoClient;
@@ -14,12 +14,7 @@ declare global {
14
14
  firstName: string;
15
15
  lastName: string;
16
16
  };
17
- tenant?: {
18
- tenantId: string;
19
- name: string;
20
- slug: string;
21
- role: string;
22
- };
17
+ tenant?: SsoJwtTenant;
23
18
  tokenPayload?: SsoTokenPayload;
24
19
  }
25
20
  }
@@ -1,4 +1,4 @@
1
- import { S as SsoTokenPayload, b as V2LoginResponse, V as V2ExchangeResponse, c as V2RefreshResponse } from '../types-BQzACpj3.cjs';
1
+ import { b as SsoTokenPayload, c as V2LoginResponse, V as V2ExchangeResponse, d as V2RefreshResponse } from '../types-D5BaCbus.cjs';
2
2
 
3
3
  interface SsoClientOptions {
4
4
  ssoBackendUrl: string;
@@ -1,4 +1,4 @@
1
- import { S as SsoTokenPayload, b as V2LoginResponse, V as V2ExchangeResponse, c as V2RefreshResponse } from '../types-BQzACpj3.js';
1
+ import { b as SsoTokenPayload, c as V2LoginResponse, V as V2ExchangeResponse, d as V2RefreshResponse } from '../types-D5BaCbus.js';
2
2
 
3
3
  interface SsoClientOptions {
4
4
  ssoBackendUrl: string;
@@ -20,6 +20,13 @@ interface SsoTenant {
20
20
  slug: string;
21
21
  role: string;
22
22
  }
23
+ interface SsoJwtTenant {
24
+ id: string;
25
+ name: string;
26
+ slug: string;
27
+ role: string;
28
+ apps: string[];
29
+ }
23
30
  interface SsoTokenPayload {
24
31
  sub: string;
25
32
  jti: string;
@@ -27,7 +34,7 @@ interface SsoTokenPayload {
27
34
  aud: string;
28
35
  exp: number;
29
36
  iat: number;
30
- tenants: SsoTenant[];
37
+ tenants: SsoJwtTenant[];
31
38
  systemRole: string;
32
39
  deviceFingerprint?: string;
33
40
  }
@@ -70,4 +77,4 @@ interface BigsoAuthResult {
70
77
  iat?: number;
71
78
  }
72
79
 
73
- export type { BigsoAuthOptions as B, SsoTokenPayload as S, V2ExchangeResponse as V, BigsoAuthResult as a, V2LoginResponse as b, V2RefreshResponse as c };
80
+ export type { BigsoAuthOptions as B, SsoJwtTenant as S, V2ExchangeResponse as V, BigsoAuthResult as a, SsoTokenPayload as b, V2LoginResponse as c, V2RefreshResponse as d };
@@ -20,6 +20,13 @@ interface SsoTenant {
20
20
  slug: string;
21
21
  role: string;
22
22
  }
23
+ interface SsoJwtTenant {
24
+ id: string;
25
+ name: string;
26
+ slug: string;
27
+ role: string;
28
+ apps: string[];
29
+ }
23
30
  interface SsoTokenPayload {
24
31
  sub: string;
25
32
  jti: string;
@@ -27,7 +34,7 @@ interface SsoTokenPayload {
27
34
  aud: string;
28
35
  exp: number;
29
36
  iat: number;
30
- tenants: SsoTenant[];
37
+ tenants: SsoJwtTenant[];
31
38
  systemRole: string;
32
39
  deviceFingerprint?: string;
33
40
  }
@@ -70,4 +77,4 @@ interface BigsoAuthResult {
70
77
  iat?: number;
71
78
  }
72
79
 
73
- export type { BigsoAuthOptions as B, SsoTokenPayload as S, V2ExchangeResponse as V, BigsoAuthResult as a, V2LoginResponse as b, V2RefreshResponse as c };
80
+ export type { BigsoAuthOptions as B, SsoJwtTenant as S, V2ExchangeResponse as V, BigsoAuthResult as a, SsoTokenPayload as b, V2LoginResponse as c, V2RefreshResponse as d };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@bigso/auth-sdk",
3
- "version": "0.5.0",
3
+ "version": "0.5.2",
4
4
  "description": "SDK de autenticación para SSO v2 - JWT Bearer + PKCE",
5
5
  "publishConfig": {
6
6
  "registry": "https://registry.npmjs.org/",