@neetru/sdk 2.2.0 → 2.3.0

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/mocks.d.cts CHANGED
@@ -1,4 +1,4 @@
1
- import { w as NeetruUser, A as AuthNamespace, H as SignInOptions, a as AuthStateListener, p as NeetruDb, v as NeetruSqlClient, E as EntitlementCheck, J as SupportNamespace, i as CreateTicketInput, Q as SupportTicket, Y as UsageNamespace, Z as UsageQuota } from './types-DlDxttiG.cjs';
1
+ import { x as NeetruUser, A as AuthNamespace, I as SignInOptions, a as AuthStateListener, p as NeetruDb, w as NeetruSqlClient, E as EntitlementCheck, K as SupportNamespace, i as CreateTicketInput, T as SupportTicket, Z as UsageNamespace, _ as UsageQuota } from './types-B6YJrynl.cjs';
2
2
  import { c as DbCollectionRef, S as SyncState, U as Unsubscribe, C as ConflictRecord } from './collection-ref-DqAAhuhX.cjs';
3
3
  import '@neetru/realtime-protocol';
4
4
  import 'drizzle-orm/node-postgres';
package/dist/mocks.d.ts CHANGED
@@ -1,4 +1,4 @@
1
- import { w as NeetruUser, A as AuthNamespace, H as SignInOptions, a as AuthStateListener, p as NeetruDb, v as NeetruSqlClient, E as EntitlementCheck, J as SupportNamespace, i as CreateTicketInput, Q as SupportTicket, Y as UsageNamespace, Z as UsageQuota } from './types-CvTje138.js';
1
+ import { x as NeetruUser, A as AuthNamespace, I as SignInOptions, a as AuthStateListener, p as NeetruDb, w as NeetruSqlClient, E as EntitlementCheck, K as SupportNamespace, i as CreateTicketInput, T as SupportTicket, Z as UsageNamespace, _ as UsageQuota } from './types-DvhtZ4bi.js';
2
2
  import { c as DbCollectionRef, S as SyncState, U as Unsubscribe, C as ConflictRecord } from './collection-ref-DqAAhuhX.js';
3
3
  import '@neetru/realtime-protocol';
4
4
  import 'drizzle-orm/node-postgres';
@@ -1,4 +1,4 @@
1
- export { L as ListNotificationsOptions, m as MockNotifications, x as NotificationsNamespace, y as ProductNotification, z as ProductNotificationSeverity, S as SendNotificationInput, a5 as createNotificationsNamespace } from './types-DlDxttiG.cjs';
1
+ export { L as ListNotificationsOptions, m as MockNotifications, y as NotificationsNamespace, z as ProductNotification, B as ProductNotificationSeverity, S as SendNotificationInput, a6 as createNotificationsNamespace } from './types-B6YJrynl.cjs';
2
2
  import './collection-ref-DqAAhuhX.cjs';
3
3
  import '@neetru/realtime-protocol';
4
4
  import 'drizzle-orm/node-postgres';
@@ -1,4 +1,4 @@
1
- export { L as ListNotificationsOptions, m as MockNotifications, x as NotificationsNamespace, y as ProductNotification, z as ProductNotificationSeverity, S as SendNotificationInput, a5 as createNotificationsNamespace } from './types-CvTje138.js';
1
+ export { L as ListNotificationsOptions, m as MockNotifications, y as NotificationsNamespace, z as ProductNotification, B as ProductNotificationSeverity, S as SendNotificationInput, a6 as createNotificationsNamespace } from './types-DvhtZ4bi.js';
2
2
  import './collection-ref-DqAAhuhX.js';
3
3
  import '@neetru/realtime-protocol';
4
4
  import 'drizzle-orm/node-postgres';
package/dist/react.d.cts CHANGED
@@ -1,5 +1,5 @@
1
1
  import * as React from 'react';
2
- import { N as NeetruClient, g as CheckoutStartResult } from './types-DlDxttiG.cjs';
2
+ import { N as NeetruClient, g as CheckoutStartResult } from './types-B6YJrynl.cjs';
3
3
  import './collection-ref-DqAAhuhX.cjs';
4
4
  import '@neetru/realtime-protocol';
5
5
  import 'drizzle-orm/node-postgres';
package/dist/react.d.ts CHANGED
@@ -1,5 +1,5 @@
1
1
  import * as React from 'react';
2
- import { N as NeetruClient, g as CheckoutStartResult } from './types-CvTje138.js';
2
+ import { N as NeetruClient, g as CheckoutStartResult } from './types-DvhtZ4bi.js';
3
3
  import './collection-ref-DqAAhuhX.js';
4
4
  import '@neetru/realtime-protocol';
5
5
  import 'drizzle-orm/node-postgres';
@@ -1,4 +1,4 @@
1
- import { G as ResolvedConfig, J as SupportNamespace } from './types-DlDxttiG.cjs';
1
+ import { H as ResolvedConfig, K as SupportNamespace } from './types-B6YJrynl.cjs';
2
2
  import './collection-ref-DqAAhuhX.cjs';
3
3
  import '@neetru/realtime-protocol';
4
4
  import 'drizzle-orm/node-postgres';
package/dist/support.d.ts CHANGED
@@ -1,4 +1,4 @@
1
- import { G as ResolvedConfig, J as SupportNamespace } from './types-CvTje138.js';
1
+ import { H as ResolvedConfig, K as SupportNamespace } from './types-DvhtZ4bi.js';
2
2
  import './collection-ref-DqAAhuhX.js';
3
3
  import '@neetru/realtime-protocol';
4
4
  import 'drizzle-orm/node-postgres';
@@ -1,4 +1,4 @@
1
- import { G as ResolvedConfig, U as TelemetryEventInput, T as TelemetryEventAck, W as TelemetryLogInput, V as TelemetryLogAck } from './types-DlDxttiG.cjs';
1
+ import { H as ResolvedConfig, V as TelemetryEventInput, U as TelemetryEventAck, X as TelemetryLogInput, W as TelemetryLogAck } from './types-B6YJrynl.cjs';
2
2
  import './collection-ref-DqAAhuhX.cjs';
3
3
  import '@neetru/realtime-protocol';
4
4
  import 'drizzle-orm/node-postgres';
@@ -1,4 +1,4 @@
1
- import { G as ResolvedConfig, U as TelemetryEventInput, T as TelemetryEventAck, W as TelemetryLogInput, V as TelemetryLogAck } from './types-CvTje138.js';
1
+ import { H as ResolvedConfig, V as TelemetryEventInput, U as TelemetryEventAck, X as TelemetryLogInput, W as TelemetryLogAck } from './types-DvhtZ4bi.js';
2
2
  import './collection-ref-DqAAhuhX.js';
3
3
  import '@neetru/realtime-protocol';
4
4
  import 'drizzle-orm/node-postgres';
@@ -720,16 +720,30 @@ declare class NeetruRealtimeClient {
720
720
  }
721
721
 
722
722
  /**
723
- * Engine do banco lógico — determina o transporte de realtime.
723
+ * Transporte SDK↔Core do banco lógico — determina o protocolo de realtime.
724
724
  *
725
725
  * - `'firestore'` — Firestore Web SDK como transporte (memoryLocalCache).
726
726
  * - `'nosql-vm'` — WebSocket via gateway `neetru-realtime`.
727
727
  * - `'rest'` — REST puro (default MVP; sem realtime nativo).
728
728
  *
729
+ * Nota: "transport" descreve o protocolo SDK↔Core (REST / Firestore / WebSocket).
730
+ * Não confundir com "engine" de armazenamento do admin database (firestore-instance,
731
+ * cloud-sql-postgres, vm-postgres-single…), que é uma configuração do Core —
732
+ * um storage engine pode ser acessado por vários SDK transports.
733
+ *
729
734
  * O produto NUNCA vê a diferença de transporte — o comportamento offline
730
- * é idêntico nos dois engines de Documentos (02-sdk.md §3.7).
735
+ * é idêntico nos dois transportes de Documentos (02-sdk.md §3.7).
731
736
  */
732
- type NeetruDbEngine = 'firestore' | 'nosql-vm' | 'rest';
737
+ type NeetruDbTransport = 'firestore' | 'nosql-vm' | 'rest';
738
+ /**
739
+ * @deprecated Use `NeetruDbTransport`. Este alias será removido em v3.0.
740
+ *
741
+ * O nome "engine" colide com o conceito de storage engine do admin database
742
+ * (firestore-instance, cloud-sql-postgres, vm-postgres-single…).
743
+ * No contexto do SDK, o campo configura o TRANSPORTE (REST/Firestore/WebSocket),
744
+ * não o engine de armazenamento. Use `transport` em vez de `engine`.
745
+ */
746
+ type NeetruDbEngine = NeetruDbTransport;
733
747
  /**
734
748
  * Opções de configuração do banco lógico.
735
749
  *
@@ -743,20 +757,37 @@ interface NeetruDbOptions {
743
757
  */
744
758
  dbId?: string;
745
759
  /**
746
- * Engine do banco lógico — determina o transporte de realtime.
747
- * Default: `'rest'` (MVP — funciona para todos os engines SQL e Documentos).
760
+ * Transporte SDK↔Core — determina o protocolo de realtime.
761
+ * Default: `'rest'` (MVP — funciona para todos os storage engines SQL e Documentos).
762
+ *
763
+ * Valores:
764
+ * - `'rest'` — REST puro (sem realtime nativo; compatível com todos os storage engines).
765
+ * - `'firestore'` — Firestore Web SDK como transporte (memoryLocalCache).
766
+ * - `'nosql-vm'` — WebSocket via gateway `neetru-realtime`.
767
+ *
768
+ * Não confundir com o storage engine do admin database (firestore-instance,
769
+ * cloud-sql-postgres, vm-postgres-single…). Um storage engine pode ser acessado
770
+ * por vários transports SDK (ex.: cloud-sql-postgres funciona com transport='rest').
771
+ */
772
+ transport?: NeetruDbTransport;
773
+ /**
774
+ * @deprecated Use `transport` em vez de `engine`. Será removido em v3.0.
775
+ *
776
+ * O nome "engine" colide com o conceito de storage engine do admin database
777
+ * (firestore-instance, cloud-sql-postgres, vm-postgres-single…).
778
+ * Se `transport` e `engine` forem passados simultaneamente, `transport` prevalece.
748
779
  */
749
780
  engine?: NeetruDbEngine;
750
781
  /**
751
- * Opções do transporte Firestore (somente quando `engine === 'firestore'`).
782
+ * Opções do transporte Firestore (somente quando `transport === 'firestore'`).
752
783
  * O `firestore` handle (inicializado com `memoryLocalCache`) é injetado aqui.
753
784
  *
754
785
  * Injeção explícita — o SDK não importa `firebase/firestore` diretamente
755
- * para não poluir o bundle de quem não usa este engine.
786
+ * para não poluir o bundle de quem não usa este transporte.
756
787
  */
757
788
  firestoreTransport?: RealtimeTransport;
758
789
  /**
759
- * Opções do transporte WebSocket (somente quando `engine === 'nosql-vm'`).
790
+ * Opções do transporte WebSocket (somente quando `transport === 'nosql-vm'`).
760
791
  * URL do gateway `neetru-realtime`.
761
792
  */
762
793
  realtimeGatewayUrl?: string;
@@ -779,11 +810,11 @@ interface NeetruDbOptions {
779
810
  singleTab?: boolean;
780
811
  /**
781
812
  * Transporte de sync customizado (injetado em testes).
782
- * Se presente, sobrepõe a detecção por `engine`.
813
+ * Se presente, sobrepõe a detecção por `transport`.
783
814
  */
784
815
  _transport?: RealtimeTransport;
785
816
  /**
786
- * Factory de WebSocket injetável (somente quando `engine === 'nosql-vm'`).
817
+ * Factory de WebSocket injetável (somente quando `transport === 'nosql-vm'`).
787
818
  * Default: `(url) => new WebSocket(url)`.
788
819
  * Injetar em testes para evitar rede real.
789
820
  */
@@ -985,8 +1016,11 @@ interface NeetruClientConfig {
985
1016
  */
986
1017
  tenantId?: string;
987
1018
  /**
988
- * v2.0 — Configuração do banco lógico: engine, dbId, coleções, transport.
989
- * Gerado pelo scaffold `neetru db init`. Opcional — padrão é engine='rest'.
1019
+ * v2.0 — Configuração do banco lógico: transport, dbId, coleções.
1020
+ * Gerado pelo scaffold `neetru db init`. Opcional — padrão é transport='rest'.
1021
+ *
1022
+ * Use `transport` (v2.3+) em vez do campo `engine` depreciado.
1023
+ * Valores: `'rest'` | `'firestore'` | `'nosql-vm'`.
990
1024
  */
991
1025
  db?: NeetruDbOptions;
992
1026
  }
@@ -1405,4 +1439,4 @@ interface CatalogListOptions {
1405
1439
  includeDrafts?: boolean;
1406
1440
  }
1407
1441
 
1408
- export { type WebhookEndpoint as $, type AuthNamespace as A, type ProductPlan as B, type CatalogListOptions as C, DEFAULT_BASE_URL as D, type EntitlementCheck as E, type ProductStatus as F, type ResolvedConfig as G, type SignInOptions as H, type SqlOptions as I, type SupportNamespace as J, type SupportSeverity as K, type ListNotificationsOptions as L, MockCheckout as M, type NeetruClient as N, type SupportStatus as O, type Product as P, type SupportTicket as Q, type RegisterWebhookInput as R, type SendNotificationInput as S, type TelemetryEventAck as T, type TelemetryEventInput as U, type TelemetryLogAck as V, type TelemetryLogInput as W, type UsageEventInput as X, type UsageNamespace as Y, type UsageQuota as Z, type VerifyTokenOptions as _, type AuthStateListener as a, type WebhookEvent as a0, type WebhookTestResult as a1, type WebhooksNamespace as a2, createCheckoutNamespace as a3, createNeetruDb as a4, createNotificationsNamespace as a5, createRestSyncTransport as a6, createWebhooksNamespace as a7, getWebSocketRealtimeClient as a8, verifyWebhookSignature as a9, type CatalogListResponse as b, type CheckoutIntentInfo as c, type CheckoutIntentStatus as d, type CheckoutNamespace as e, type CheckoutStartInput as f, type CheckoutStartResult as g, type CheckoutTenantType as h, type CreateTicketInput as i, type DbNamespace as j, type DbSqlLease as k, type DbWhereFilter as l, MockNotifications as m, MockWebhooks as n, type NeetruClientConfig as o, type NeetruDb as p, type NeetruDbEngine as q, NeetruDbError as r, type NeetruDbErrorCode as s, type NeetruDbOptions as t, type NeetruEnv as u, type NeetruSqlClient as v, type NeetruUser as w, type NotificationsNamespace as x, type ProductNotification as y, type ProductNotificationSeverity as z };
1442
+ export { type VerifyTokenOptions as $, type AuthNamespace as A, type ProductNotificationSeverity as B, type CatalogListOptions as C, DEFAULT_BASE_URL as D, type EntitlementCheck as E, type ProductPlan as F, type ProductStatus as G, type ResolvedConfig as H, type SignInOptions as I, type SqlOptions as J, type SupportNamespace as K, type ListNotificationsOptions as L, MockCheckout as M, type NeetruClient as N, type SupportSeverity as O, type Product as P, type SupportStatus as Q, type RegisterWebhookInput as R, type SendNotificationInput as S, type SupportTicket as T, type TelemetryEventAck as U, type TelemetryEventInput as V, type TelemetryLogAck as W, type TelemetryLogInput as X, type UsageEventInput as Y, type UsageNamespace as Z, type UsageQuota as _, type AuthStateListener as a, type WebhookEndpoint as a0, type WebhookEvent as a1, type WebhookTestResult as a2, type WebhooksNamespace as a3, createCheckoutNamespace as a4, createNeetruDb as a5, createNotificationsNamespace as a6, createRestSyncTransport as a7, createWebhooksNamespace as a8, getWebSocketRealtimeClient as a9, verifyWebhookSignature as aa, type CatalogListResponse as b, type CheckoutIntentInfo as c, type CheckoutIntentStatus as d, type CheckoutNamespace as e, type CheckoutStartInput as f, type CheckoutStartResult as g, type CheckoutTenantType as h, type CreateTicketInput as i, type DbNamespace as j, type DbSqlLease as k, type DbWhereFilter as l, MockNotifications as m, MockWebhooks as n, type NeetruClientConfig as o, type NeetruDb as p, type NeetruDbEngine as q, NeetruDbError as r, type NeetruDbErrorCode as s, type NeetruDbOptions as t, type NeetruDbTransport as u, type NeetruEnv as v, type NeetruSqlClient as w, type NeetruUser as x, type NotificationsNamespace as y, type ProductNotification as z };
@@ -720,16 +720,30 @@ declare class NeetruRealtimeClient {
720
720
  }
721
721
 
722
722
  /**
723
- * Engine do banco lógico — determina o transporte de realtime.
723
+ * Transporte SDK↔Core do banco lógico — determina o protocolo de realtime.
724
724
  *
725
725
  * - `'firestore'` — Firestore Web SDK como transporte (memoryLocalCache).
726
726
  * - `'nosql-vm'` — WebSocket via gateway `neetru-realtime`.
727
727
  * - `'rest'` — REST puro (default MVP; sem realtime nativo).
728
728
  *
729
+ * Nota: "transport" descreve o protocolo SDK↔Core (REST / Firestore / WebSocket).
730
+ * Não confundir com "engine" de armazenamento do admin database (firestore-instance,
731
+ * cloud-sql-postgres, vm-postgres-single…), que é uma configuração do Core —
732
+ * um storage engine pode ser acessado por vários SDK transports.
733
+ *
729
734
  * O produto NUNCA vê a diferença de transporte — o comportamento offline
730
- * é idêntico nos dois engines de Documentos (02-sdk.md §3.7).
735
+ * é idêntico nos dois transportes de Documentos (02-sdk.md §3.7).
731
736
  */
732
- type NeetruDbEngine = 'firestore' | 'nosql-vm' | 'rest';
737
+ type NeetruDbTransport = 'firestore' | 'nosql-vm' | 'rest';
738
+ /**
739
+ * @deprecated Use `NeetruDbTransport`. Este alias será removido em v3.0.
740
+ *
741
+ * O nome "engine" colide com o conceito de storage engine do admin database
742
+ * (firestore-instance, cloud-sql-postgres, vm-postgres-single…).
743
+ * No contexto do SDK, o campo configura o TRANSPORTE (REST/Firestore/WebSocket),
744
+ * não o engine de armazenamento. Use `transport` em vez de `engine`.
745
+ */
746
+ type NeetruDbEngine = NeetruDbTransport;
733
747
  /**
734
748
  * Opções de configuração do banco lógico.
735
749
  *
@@ -743,20 +757,37 @@ interface NeetruDbOptions {
743
757
  */
744
758
  dbId?: string;
745
759
  /**
746
- * Engine do banco lógico — determina o transporte de realtime.
747
- * Default: `'rest'` (MVP — funciona para todos os engines SQL e Documentos).
760
+ * Transporte SDK↔Core — determina o protocolo de realtime.
761
+ * Default: `'rest'` (MVP — funciona para todos os storage engines SQL e Documentos).
762
+ *
763
+ * Valores:
764
+ * - `'rest'` — REST puro (sem realtime nativo; compatível com todos os storage engines).
765
+ * - `'firestore'` — Firestore Web SDK como transporte (memoryLocalCache).
766
+ * - `'nosql-vm'` — WebSocket via gateway `neetru-realtime`.
767
+ *
768
+ * Não confundir com o storage engine do admin database (firestore-instance,
769
+ * cloud-sql-postgres, vm-postgres-single…). Um storage engine pode ser acessado
770
+ * por vários transports SDK (ex.: cloud-sql-postgres funciona com transport='rest').
771
+ */
772
+ transport?: NeetruDbTransport;
773
+ /**
774
+ * @deprecated Use `transport` em vez de `engine`. Será removido em v3.0.
775
+ *
776
+ * O nome "engine" colide com o conceito de storage engine do admin database
777
+ * (firestore-instance, cloud-sql-postgres, vm-postgres-single…).
778
+ * Se `transport` e `engine` forem passados simultaneamente, `transport` prevalece.
748
779
  */
749
780
  engine?: NeetruDbEngine;
750
781
  /**
751
- * Opções do transporte Firestore (somente quando `engine === 'firestore'`).
782
+ * Opções do transporte Firestore (somente quando `transport === 'firestore'`).
752
783
  * O `firestore` handle (inicializado com `memoryLocalCache`) é injetado aqui.
753
784
  *
754
785
  * Injeção explícita — o SDK não importa `firebase/firestore` diretamente
755
- * para não poluir o bundle de quem não usa este engine.
786
+ * para não poluir o bundle de quem não usa este transporte.
756
787
  */
757
788
  firestoreTransport?: RealtimeTransport;
758
789
  /**
759
- * Opções do transporte WebSocket (somente quando `engine === 'nosql-vm'`).
790
+ * Opções do transporte WebSocket (somente quando `transport === 'nosql-vm'`).
760
791
  * URL do gateway `neetru-realtime`.
761
792
  */
762
793
  realtimeGatewayUrl?: string;
@@ -779,11 +810,11 @@ interface NeetruDbOptions {
779
810
  singleTab?: boolean;
780
811
  /**
781
812
  * Transporte de sync customizado (injetado em testes).
782
- * Se presente, sobrepõe a detecção por `engine`.
813
+ * Se presente, sobrepõe a detecção por `transport`.
783
814
  */
784
815
  _transport?: RealtimeTransport;
785
816
  /**
786
- * Factory de WebSocket injetável (somente quando `engine === 'nosql-vm'`).
817
+ * Factory de WebSocket injetável (somente quando `transport === 'nosql-vm'`).
787
818
  * Default: `(url) => new WebSocket(url)`.
788
819
  * Injetar em testes para evitar rede real.
789
820
  */
@@ -985,8 +1016,11 @@ interface NeetruClientConfig {
985
1016
  */
986
1017
  tenantId?: string;
987
1018
  /**
988
- * v2.0 — Configuração do banco lógico: engine, dbId, coleções, transport.
989
- * Gerado pelo scaffold `neetru db init`. Opcional — padrão é engine='rest'.
1019
+ * v2.0 — Configuração do banco lógico: transport, dbId, coleções.
1020
+ * Gerado pelo scaffold `neetru db init`. Opcional — padrão é transport='rest'.
1021
+ *
1022
+ * Use `transport` (v2.3+) em vez do campo `engine` depreciado.
1023
+ * Valores: `'rest'` | `'firestore'` | `'nosql-vm'`.
990
1024
  */
991
1025
  db?: NeetruDbOptions;
992
1026
  }
@@ -1405,4 +1439,4 @@ interface CatalogListOptions {
1405
1439
  includeDrafts?: boolean;
1406
1440
  }
1407
1441
 
1408
- export { type WebhookEndpoint as $, type AuthNamespace as A, type ProductPlan as B, type CatalogListOptions as C, DEFAULT_BASE_URL as D, type EntitlementCheck as E, type ProductStatus as F, type ResolvedConfig as G, type SignInOptions as H, type SqlOptions as I, type SupportNamespace as J, type SupportSeverity as K, type ListNotificationsOptions as L, MockCheckout as M, type NeetruClient as N, type SupportStatus as O, type Product as P, type SupportTicket as Q, type RegisterWebhookInput as R, type SendNotificationInput as S, type TelemetryEventAck as T, type TelemetryEventInput as U, type TelemetryLogAck as V, type TelemetryLogInput as W, type UsageEventInput as X, type UsageNamespace as Y, type UsageQuota as Z, type VerifyTokenOptions as _, type AuthStateListener as a, type WebhookEvent as a0, type WebhookTestResult as a1, type WebhooksNamespace as a2, createCheckoutNamespace as a3, createNeetruDb as a4, createNotificationsNamespace as a5, createRestSyncTransport as a6, createWebhooksNamespace as a7, getWebSocketRealtimeClient as a8, verifyWebhookSignature as a9, type CatalogListResponse as b, type CheckoutIntentInfo as c, type CheckoutIntentStatus as d, type CheckoutNamespace as e, type CheckoutStartInput as f, type CheckoutStartResult as g, type CheckoutTenantType as h, type CreateTicketInput as i, type DbNamespace as j, type DbSqlLease as k, type DbWhereFilter as l, MockNotifications as m, MockWebhooks as n, type NeetruClientConfig as o, type NeetruDb as p, type NeetruDbEngine as q, NeetruDbError as r, type NeetruDbErrorCode as s, type NeetruDbOptions as t, type NeetruEnv as u, type NeetruSqlClient as v, type NeetruUser as w, type NotificationsNamespace as x, type ProductNotification as y, type ProductNotificationSeverity as z };
1442
+ export { type VerifyTokenOptions as $, type AuthNamespace as A, type ProductNotificationSeverity as B, type CatalogListOptions as C, DEFAULT_BASE_URL as D, type EntitlementCheck as E, type ProductPlan as F, type ProductStatus as G, type ResolvedConfig as H, type SignInOptions as I, type SqlOptions as J, type SupportNamespace as K, type ListNotificationsOptions as L, MockCheckout as M, type NeetruClient as N, type SupportSeverity as O, type Product as P, type SupportStatus as Q, type RegisterWebhookInput as R, type SendNotificationInput as S, type SupportTicket as T, type TelemetryEventAck as U, type TelemetryEventInput as V, type TelemetryLogAck as W, type TelemetryLogInput as X, type UsageEventInput as Y, type UsageNamespace as Z, type UsageQuota as _, type AuthStateListener as a, type WebhookEndpoint as a0, type WebhookEvent as a1, type WebhookTestResult as a2, type WebhooksNamespace as a3, createCheckoutNamespace as a4, createNeetruDb as a5, createNotificationsNamespace as a6, createRestSyncTransport as a7, createWebhooksNamespace as a8, getWebSocketRealtimeClient as a9, verifyWebhookSignature as aa, type CatalogListResponse as b, type CheckoutIntentInfo as c, type CheckoutIntentStatus as d, type CheckoutNamespace as e, type CheckoutStartInput as f, type CheckoutStartResult as g, type CheckoutTenantType as h, type CreateTicketInput as i, type DbNamespace as j, type DbSqlLease as k, type DbWhereFilter as l, MockNotifications as m, MockWebhooks as n, type NeetruClientConfig as o, type NeetruDb as p, type NeetruDbEngine as q, NeetruDbError as r, type NeetruDbErrorCode as s, type NeetruDbOptions as t, type NeetruDbTransport as u, type NeetruEnv as v, type NeetruSqlClient as w, type NeetruUser as x, type NotificationsNamespace as y, type ProductNotification as z };
package/dist/usage.d.cts CHANGED
@@ -1,4 +1,4 @@
1
- import { G as ResolvedConfig, Y as UsageNamespace } from './types-DlDxttiG.cjs';
1
+ import { H as ResolvedConfig, Z as UsageNamespace } from './types-B6YJrynl.cjs';
2
2
  import './collection-ref-DqAAhuhX.cjs';
3
3
  import '@neetru/realtime-protocol';
4
4
  import 'drizzle-orm/node-postgres';
package/dist/usage.d.ts CHANGED
@@ -1,4 +1,4 @@
1
- import { G as ResolvedConfig, Y as UsageNamespace } from './types-CvTje138.js';
1
+ import { H as ResolvedConfig, Z as UsageNamespace } from './types-DvhtZ4bi.js';
2
2
  import './collection-ref-DqAAhuhX.js';
3
3
  import '@neetru/realtime-protocol';
4
4
  import 'drizzle-orm/node-postgres';
@@ -1,4 +1,4 @@
1
- export { n as MockWebhooks, R as RegisterWebhookInput, $ as WebhookEndpoint, a0 as WebhookEvent, a1 as WebhookTestResult, a2 as WebhooksNamespace, a7 as createWebhooksNamespace, a9 as verifyWebhookSignature } from './types-DlDxttiG.cjs';
1
+ export { n as MockWebhooks, R as RegisterWebhookInput, a0 as WebhookEndpoint, a1 as WebhookEvent, a2 as WebhookTestResult, a3 as WebhooksNamespace, a8 as createWebhooksNamespace, aa as verifyWebhookSignature } from './types-B6YJrynl.cjs';
2
2
  import './collection-ref-DqAAhuhX.cjs';
3
3
  import '@neetru/realtime-protocol';
4
4
  import 'drizzle-orm/node-postgres';
@@ -1,4 +1,4 @@
1
- export { n as MockWebhooks, R as RegisterWebhookInput, $ as WebhookEndpoint, a0 as WebhookEvent, a1 as WebhookTestResult, a2 as WebhooksNamespace, a7 as createWebhooksNamespace, a9 as verifyWebhookSignature } from './types-CvTje138.js';
1
+ export { n as MockWebhooks, R as RegisterWebhookInput, a0 as WebhookEndpoint, a1 as WebhookEvent, a2 as WebhookTestResult, a3 as WebhooksNamespace, a8 as createWebhooksNamespace, aa as verifyWebhookSignature } from './types-DvhtZ4bi.js';
2
2
  import './collection-ref-DqAAhuhX.js';
3
3
  import '@neetru/realtime-protocol';
4
4
  import 'drizzle-orm/node-postgres';
package/package.json CHANGED
@@ -1,134 +1,134 @@
1
- {
2
- "name": "@neetru/sdk",
3
- "version": "2.2.0",
4
- "description": "Neetru SDK 1.1 — biblioteca runtime estável para consumir o ecossistema Neetru (auth OIDC, catalog, entitlements, telemetry, usage metering, support tickets, datastore, checkout).",
5
- "type": "module",
6
- "main": "./dist/index.cjs",
7
- "module": "./dist/index.mjs",
8
- "types": "./dist/index.d.ts",
9
- "exports": {
10
- ".": {
11
- "types": "./dist/index.d.ts",
12
- "import": "./dist/index.mjs",
13
- "require": "./dist/index.cjs"
14
- },
15
- "./auth": {
16
- "types": "./dist/auth.d.ts",
17
- "import": "./dist/auth.mjs",
18
- "require": "./dist/auth.cjs"
19
- },
20
- "./catalog": {
21
- "types": "./dist/catalog.d.ts",
22
- "import": "./dist/catalog.mjs",
23
- "require": "./dist/catalog.cjs"
24
- },
25
- "./entitlements": {
26
- "types": "./dist/entitlements.d.ts",
27
- "import": "./dist/entitlements.mjs",
28
- "require": "./dist/entitlements.cjs"
29
- },
30
- "./telemetry": {
31
- "types": "./dist/telemetry.d.ts",
32
- "import": "./dist/telemetry.mjs",
33
- "require": "./dist/telemetry.cjs"
34
- },
35
- "./usage": {
36
- "types": "./dist/usage.d.ts",
37
- "import": "./dist/usage.mjs",
38
- "require": "./dist/usage.cjs"
39
- },
40
- "./support": {
41
- "types": "./dist/support.d.ts",
42
- "import": "./dist/support.mjs",
43
- "require": "./dist/support.cjs"
44
- },
45
- "./mocks": {
46
- "types": "./dist/mocks.d.ts",
47
- "import": "./dist/mocks.mjs",
48
- "require": "./dist/mocks.cjs"
49
- },
50
- "./db": {
51
- "types": "./dist/db.d.ts",
52
- "import": "./dist/db.mjs",
53
- "require": "./dist/db.cjs"
54
- },
55
- "./errors": {
56
- "types": "./dist/errors.d.ts",
57
- "import": "./dist/errors.mjs",
58
- "require": "./dist/errors.cjs"
59
- },
60
- "./checkout": {
61
- "types": "./dist/checkout.d.ts",
62
- "import": "./dist/checkout.mjs",
63
- "require": "./dist/checkout.cjs"
64
- },
65
- "./react": {
66
- "types": "./dist/react.d.ts",
67
- "import": "./dist/react.mjs",
68
- "require": "./dist/react.cjs"
69
- },
70
- "./db/react": {
71
- "types": "./dist/db-react.d.ts",
72
- "import": "./dist/db-react.mjs",
73
- "require": "./dist/db-react.cjs"
74
- },
75
- "./webhooks": {
76
- "types": "./dist/webhooks.d.ts",
77
- "import": "./dist/webhooks.mjs",
78
- "require": "./dist/webhooks.cjs"
79
- },
80
- "./notifications": {
81
- "types": "./dist/notifications.d.ts",
82
- "import": "./dist/notifications.mjs",
83
- "require": "./dist/notifications.cjs"
84
- }
85
- },
86
- "peerDependencies": {
87
- "react": "^18.0.0 || ^19.0.0"
88
- },
89
- "peerDependenciesMeta": {
90
- "react": {
91
- "optional": true
92
- }
93
- },
94
- "sideEffects": false,
95
- "scripts": {
96
- "build": "tsup",
97
- "dev": "tsup --watch",
98
- "test": "vitest run",
99
- "lint": "tsc --noEmit",
100
- "docs:gen": "typedoc --options scripts/typedoc.config.json"
101
- },
102
- "files": [
103
- "dist",
104
- "README.md",
105
- "CHANGELOG.md"
106
- ],
107
- "engines": {
108
- "node": ">=20"
109
- },
110
- "license": "UNLICENSED",
111
- "devDependencies": {
112
- "@testing-library/jest-dom": "^6.9.1",
113
- "@testing-library/react": "^16.3.2",
114
- "@types/pg": "^8.11.10",
115
- "@types/react": "^19.2.15",
116
- "@types/react-dom": "^19.2.3",
117
- "@vitest/browser": "^4.1.7",
118
- "fake-indexeddb": "^6.2.5",
119
- "jsdom": "^29.1.1",
120
- "react": "^19.2.6",
121
- "react-dom": "^19.2.6",
122
- "tsup": "^8.3.5",
123
- "typedoc": "^0.28.19",
124
- "typescript": "^5.9.3",
125
- "vitest": "^4.1.7"
126
- },
127
- "dependencies": {
128
- "@neetru/realtime-protocol": "file:../neetru_libs/packages/realtime-protocol",
129
- "drizzle-orm": "^0.43.1",
130
- "idb": "^8.0.3",
131
- "jose": "^6.2.3",
132
- "pg": "^8.15.6"
133
- }
134
- }
1
+ {
2
+ "name": "@neetru/sdk",
3
+ "version": "2.3.0",
4
+ "description": "Neetru SDK 1.1 — biblioteca runtime estável para consumir o ecossistema Neetru (auth OIDC, catalog, entitlements, telemetry, usage metering, support tickets, datastore, checkout).",
5
+ "type": "module",
6
+ "main": "./dist/index.cjs",
7
+ "module": "./dist/index.mjs",
8
+ "types": "./dist/index.d.ts",
9
+ "exports": {
10
+ ".": {
11
+ "types": "./dist/index.d.ts",
12
+ "import": "./dist/index.mjs",
13
+ "require": "./dist/index.cjs"
14
+ },
15
+ "./auth": {
16
+ "types": "./dist/auth.d.ts",
17
+ "import": "./dist/auth.mjs",
18
+ "require": "./dist/auth.cjs"
19
+ },
20
+ "./catalog": {
21
+ "types": "./dist/catalog.d.ts",
22
+ "import": "./dist/catalog.mjs",
23
+ "require": "./dist/catalog.cjs"
24
+ },
25
+ "./entitlements": {
26
+ "types": "./dist/entitlements.d.ts",
27
+ "import": "./dist/entitlements.mjs",
28
+ "require": "./dist/entitlements.cjs"
29
+ },
30
+ "./telemetry": {
31
+ "types": "./dist/telemetry.d.ts",
32
+ "import": "./dist/telemetry.mjs",
33
+ "require": "./dist/telemetry.cjs"
34
+ },
35
+ "./usage": {
36
+ "types": "./dist/usage.d.ts",
37
+ "import": "./dist/usage.mjs",
38
+ "require": "./dist/usage.cjs"
39
+ },
40
+ "./support": {
41
+ "types": "./dist/support.d.ts",
42
+ "import": "./dist/support.mjs",
43
+ "require": "./dist/support.cjs"
44
+ },
45
+ "./mocks": {
46
+ "types": "./dist/mocks.d.ts",
47
+ "import": "./dist/mocks.mjs",
48
+ "require": "./dist/mocks.cjs"
49
+ },
50
+ "./db": {
51
+ "types": "./dist/db.d.ts",
52
+ "import": "./dist/db.mjs",
53
+ "require": "./dist/db.cjs"
54
+ },
55
+ "./errors": {
56
+ "types": "./dist/errors.d.ts",
57
+ "import": "./dist/errors.mjs",
58
+ "require": "./dist/errors.cjs"
59
+ },
60
+ "./checkout": {
61
+ "types": "./dist/checkout.d.ts",
62
+ "import": "./dist/checkout.mjs",
63
+ "require": "./dist/checkout.cjs"
64
+ },
65
+ "./react": {
66
+ "types": "./dist/react.d.ts",
67
+ "import": "./dist/react.mjs",
68
+ "require": "./dist/react.cjs"
69
+ },
70
+ "./db/react": {
71
+ "types": "./dist/db-react.d.ts",
72
+ "import": "./dist/db-react.mjs",
73
+ "require": "./dist/db-react.cjs"
74
+ },
75
+ "./webhooks": {
76
+ "types": "./dist/webhooks.d.ts",
77
+ "import": "./dist/webhooks.mjs",
78
+ "require": "./dist/webhooks.cjs"
79
+ },
80
+ "./notifications": {
81
+ "types": "./dist/notifications.d.ts",
82
+ "import": "./dist/notifications.mjs",
83
+ "require": "./dist/notifications.cjs"
84
+ }
85
+ },
86
+ "peerDependencies": {
87
+ "react": "^18.0.0 || ^19.0.0"
88
+ },
89
+ "peerDependenciesMeta": {
90
+ "react": {
91
+ "optional": true
92
+ }
93
+ },
94
+ "sideEffects": false,
95
+ "scripts": {
96
+ "build": "tsup",
97
+ "dev": "tsup --watch",
98
+ "test": "vitest run",
99
+ "lint": "tsc --noEmit",
100
+ "docs:gen": "typedoc --options scripts/typedoc.config.json"
101
+ },
102
+ "files": [
103
+ "dist",
104
+ "README.md",
105
+ "CHANGELOG.md"
106
+ ],
107
+ "engines": {
108
+ "node": ">=20"
109
+ },
110
+ "license": "UNLICENSED",
111
+ "devDependencies": {
112
+ "@testing-library/jest-dom": "^6.9.1",
113
+ "@testing-library/react": "^16.3.2",
114
+ "@types/pg": "^8.11.10",
115
+ "@types/react": "^19.2.15",
116
+ "@types/react-dom": "^19.2.3",
117
+ "@vitest/browser": "^4.1.7",
118
+ "fake-indexeddb": "^6.2.5",
119
+ "jsdom": "^29.1.1",
120
+ "react": "^19.2.6",
121
+ "react-dom": "^19.2.6",
122
+ "tsup": "^8.3.5",
123
+ "typedoc": "^0.28.19",
124
+ "typescript": "^5.9.3",
125
+ "vitest": "^4.1.7"
126
+ },
127
+ "dependencies": {
128
+ "@neetru/realtime-protocol": "file:../neetru_libs/packages/realtime-protocol",
129
+ "drizzle-orm": "^0.43.1",
130
+ "idb": "^8.0.3",
131
+ "jose": "^6.2.3",
132
+ "pg": "^8.15.6"
133
+ }
134
+ }