@everfur/sdk 0.7.0 → 0.7.1

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.
Files changed (106) hide show
  1. package/CHANGELOG.md +15 -0
  2. package/dist/{Chat-DZpYH8Uh.d.ts → Chat-CFi5cNUF.d.ts} +3 -3
  3. package/dist/{Chat-bATY4atj.d.cts → Chat-DQOsAumH.d.cts} +3 -3
  4. package/dist/{DepthViews-C4DC4Kom.d.cts → DepthViews-C409ubw-.d.cts} +1 -1
  5. package/dist/{DepthViews-BpHUbjSY.d.cts → DepthViews-D81c95Ra.d.cts} +1 -1
  6. package/dist/{DepthViews-dLTizxjr.d.ts → DepthViews-es8mIK0w.d.ts} +1 -1
  7. package/dist/{DepthViews-qBIoA48w.d.ts → DepthViews-uilL1NJZ.d.ts} +1 -1
  8. package/dist/{BookedScreen-DFJcgf1e.d.ts → IntakeMedia-BcjjUizr.d.ts} +40 -1
  9. package/dist/{BookedScreen-R5X_Zrlh.d.cts → IntakeMedia-CL_S2tZE.d.cts} +40 -1
  10. package/dist/animations/index.d.cts +3 -3
  11. package/dist/animations/index.d.ts +3 -3
  12. package/dist/{attachments-Ce06TWqe.d.cts → attachments-B2GjBgvF.d.cts} +2 -2
  13. package/dist/{attachments-CUOGILir.d.cts → attachments-DI710no4.d.cts} +5 -5
  14. package/dist/{attachments-CPRFfoHT.d.ts → attachments-DNaSbmA3.d.ts} +2 -2
  15. package/dist/{attachments-CXAnZcEg.d.ts → attachments-SF88N654.d.ts} +5 -5
  16. package/dist/{bookingCopy-DFTv9w6J.d.ts → bookingCopy-D2N3RhsV.d.ts} +2 -2
  17. package/dist/{bookingCopy-BwVopcoV.d.cts → bookingCopy-xlXxORCA.d.cts} +2 -2
  18. package/dist/{casesRepository-CJchNp3x.d.cts → casesRepository-B-md8h1S.d.cts} +1 -1
  19. package/dist/{casesRepository-DAVcY3jC.d.ts → casesRepository-CC6951TK.d.ts} +1 -1
  20. package/dist/chat/index.d.cts +9 -9
  21. package/dist/chat/index.d.ts +9 -9
  22. package/dist/client/index.cjs +1 -1
  23. package/dist/client/index.d.cts +6 -6
  24. package/dist/client/index.d.ts +6 -6
  25. package/dist/client/index.js +1 -1
  26. package/dist/{config-ZxwCylac.d.ts → config-BM0sv5jx.d.ts} +1 -1
  27. package/dist/{config-h5h6TsHL.d.cts → config-Daa1plhQ.d.cts} +1 -1
  28. package/dist/consent/index.d.cts +5 -5
  29. package/dist/consent/index.d.ts +5 -5
  30. package/dist/{context-DtPIshVA.d.ts → context-CDV2pwGI.d.ts} +5 -5
  31. package/dist/{context-CtsAgJnc.d.cts → context-DQHtwcHN.d.cts} +5 -5
  32. package/dist/{copy-CaWaplQc.d.cts → copy-BEx5F71o.d.cts} +2 -2
  33. package/dist/{copy-Cg89Qoal.d.ts → copy-Cl1l-qmY.d.ts} +2 -2
  34. package/dist/core/index.cjs +1 -1
  35. package/dist/core/index.d.cts +12 -12
  36. package/dist/core/index.d.ts +12 -12
  37. package/dist/core/index.js +1 -1
  38. package/dist/{depth-EXZYEO70.d.cts → depth-CAAwiStc.d.cts} +3 -3
  39. package/dist/{depth-Bo4bAwcn.d.ts → depth-DfNRVtrV.d.ts} +3 -3
  40. package/dist/{entitlementRepository-DcbIx8yV.d.ts → entitlementRepository-CVWvND1P.d.ts} +2 -2
  41. package/dist/{entitlementRepository-BYtVb1oU.d.cts → entitlementRepository-DPvWjV-N.d.cts} +2 -2
  42. package/dist/{identity-EC5-apbY.d.ts → identity-BhT7oJDS.d.ts} +1 -1
  43. package/dist/{identity-b5Vp32Vp.d.cts → identity-DUlshgow.d.cts} +1 -1
  44. package/dist/index.cjs +1 -1
  45. package/dist/index.d.cts +12 -12
  46. package/dist/index.d.ts +12 -12
  47. package/dist/index.js +1 -1
  48. package/dist/notifications/index.d.cts +2 -2
  49. package/dist/notifications/index.d.ts +2 -2
  50. package/dist/{pets-DM8QvKLo.d.cts → pets-Bneph9m1.d.cts} +1 -1
  51. package/dist/{pets-B_27_agU.d.ts → pets-DjcLmRrW.d.ts} +1 -1
  52. package/dist/{petsRepository-BJsJ4cju.d.cts → petsRepository-BnVre3q7.d.cts} +1 -1
  53. package/dist/{petsRepository-CuYZZaI5.d.ts → petsRepository-BwxmfX_s.d.ts} +1 -1
  54. package/dist/{ports-ZmJYgd5I.d.cts → ports-BPKxFOSe.d.cts} +4 -4
  55. package/dist/{ports-nXHf50_X.d.ts → ports-Di9rdLO9.d.ts} +4 -4
  56. package/dist/records/depth/index.d.cts +7 -7
  57. package/dist/records/depth/index.d.ts +7 -7
  58. package/dist/records/index.d.cts +9 -9
  59. package/dist/records/index.d.ts +9 -9
  60. package/dist/{requestFunnel-Ve9BshTB.d.ts → requestFunnel-CiSX2pun.d.ts} +2 -2
  61. package/dist/{requestFunnel-C_cZXhIA.d.cts → requestFunnel-DMR_1T3O.d.cts} +2 -2
  62. package/dist/{runtimeTypes-D155OlBW.d.cts → runtimeTypes-2gJ5hYoE.d.cts} +4 -4
  63. package/dist/{runtimeTypes-ByKsp8hm.d.ts → runtimeTypes-CkMFCbHW.d.ts} +4 -4
  64. package/dist/server/events/index.cjs +1 -1
  65. package/dist/server/events/index.d.cts +2 -2
  66. package/dist/server/events/index.d.ts +2 -2
  67. package/dist/server/events/index.js +1 -1
  68. package/dist/server/index.cjs +1 -1
  69. package/dist/server/index.d.cts +3 -3
  70. package/dist/server/index.d.ts +3 -3
  71. package/dist/server/index.js +1 -1
  72. package/dist/televet/booking/index.d.cts +6 -6
  73. package/dist/televet/booking/index.d.ts +6 -6
  74. package/dist/testing/index.d.cts +1 -1
  75. package/dist/testing/index.d.ts +1 -1
  76. package/dist/testing/rn/index.d.cts +7 -7
  77. package/dist/testing/rn/index.d.ts +7 -7
  78. package/dist/testing/web/index.d.cts +7 -7
  79. package/dist/testing/web/index.d.ts +7 -7
  80. package/dist/{timelineRows-DXpjECfA.d.ts → timelineRows-D3171ksh.d.ts} +1 -1
  81. package/dist/{timelineRows-BNF43SXK.d.cts → timelineRows-DDnz4gx2.d.cts} +1 -1
  82. package/dist/{useRecordsDepth-CARTuHKh.d.cts → useRecordsDepth-COJ0wSYK.d.cts} +1 -1
  83. package/dist/{useRecordsDepth-fPSv-GXU.d.ts → useRecordsDepth-Z9FF5X4E.d.ts} +1 -1
  84. package/dist/{view-Dc-JlFkf.d.ts → view-DoQEHXJR.d.ts} +2 -2
  85. package/dist/{view-DGPaVno8.d.cts → view-nRy6SitU.d.cts} +2 -2
  86. package/dist/web/consent/index.d.cts +5 -5
  87. package/dist/web/consent/index.d.ts +5 -5
  88. package/dist/web/index.cjs +2 -2
  89. package/dist/web/index.d.cts +14 -14
  90. package/dist/web/index.d.ts +14 -14
  91. package/dist/web/index.js +2 -2
  92. package/dist/web/notifications/index.d.cts +3 -3
  93. package/dist/web/notifications/index.d.ts +3 -3
  94. package/dist/web/records/depth/index.d.cts +7 -7
  95. package/dist/web/records/depth/index.d.ts +7 -7
  96. package/dist/web/records/index.d.cts +9 -9
  97. package/dist/web/records/index.d.ts +9 -9
  98. package/dist/web/televet/booking/index.cjs +1 -1
  99. package/dist/web/televet/booking/index.d.cts +15 -49
  100. package/dist/web/televet/booking/index.d.ts +15 -49
  101. package/dist/web/televet/booking/index.js +1 -1
  102. package/dist/web/televet/index.cjs +1 -1
  103. package/dist/web/televet/index.d.cts +11 -3
  104. package/dist/web/televet/index.d.ts +11 -3
  105. package/dist/web/televet/index.js +1 -1
  106. package/package.json +1 -1
package/CHANGELOG.md CHANGED
@@ -10,6 +10,21 @@ changes that has not been earned by any production integration yet.
10
10
 
11
11
  ## [Unreleased]
12
12
 
13
+ ## [0.7.1] - 2026-10-01
14
+
15
+ ### Fixed
16
+
17
+ - **`RecordShareAudience` is now exported (type-only) from `@everfur/sdk/records/depth` and
18
+ `@everfur/sdk/web/records/depth`**, the audience `RecordsDepthClient.createShare(petRef, { audience })` takes.
19
+ Before, both depth API reports carried an api-extractor warning pinned to a hashed build file
20
+ (`dist/depth-<hash>.d.ts`), so `npm run api:check` failed on every version bump until the reports were
21
+ regenerated.
22
+ - **`EverfurTelevetHost` takes `onPickMedia` (web).** The intake step has had a picker seam since booking photos
23
+ shipped (`onPickMedia` on `EverfurTelevet`), but the default in-page visit never reached it: the host and
24
+ `EverfurTelevetDialog` rendered the flow without a picker, so a partner on the button, chat or its own host
25
+ could not offer photos even with booking media served. The host now passes it through, as it does
26
+ `onAddToCalendar`. Absent, the intake step has no attachment row, as before.
27
+
13
28
  ## [0.7.0] - 2026-10-01
14
29
 
15
30
  ### Added
@@ -2,9 +2,9 @@ import { ReactNode } from 'react';
2
2
  import { StyleProp, ViewStyle } from 'react-native';
3
3
  import { P as PetRef, C as ConversationId } from './ids-B2GAAifq.js';
4
4
  import { F as FileHandle } from './ports-BN6RHF9W.js';
5
- import { a as ChatCheckinTarget } from './ports-nXHf50_X.js';
6
- import { W as WidgetPet, P as PetProfileInput } from './petsRepository-CuYZZaI5.js';
7
- import { U as UrgencyDisplayLevel, L as LifecyclePort, E as EverfurChatDraftStore } from './attachments-CXAnZcEg.js';
5
+ import { a as ChatCheckinTarget } from './ports-Di9rdLO9.js';
6
+ import { W as WidgetPet, P as PetProfileInput } from './petsRepository-BwxmfX_s.js';
7
+ import { U as UrgencyDisplayLevel, L as LifecyclePort, E as EverfurChatDraftStore } from './attachments-SF88N654.js';
8
8
 
9
9
  /** Where a picked image comes from: the host's photo library, or its camera. */
10
10
  type AttachmentSource = 'photo' | 'camera';
@@ -2,9 +2,9 @@ import { ReactNode } from 'react';
2
2
  import { StyleProp, ViewStyle } from 'react-native';
3
3
  import { P as PetRef, C as ConversationId } from './ids-B2GAAifq.cjs';
4
4
  import { F as FileHandle } from './ports-BN6RHF9W.cjs';
5
- import { a as ChatCheckinTarget } from './ports-ZmJYgd5I.cjs';
6
- import { W as WidgetPet, P as PetProfileInput } from './petsRepository-BJsJ4cju.cjs';
7
- import { U as UrgencyDisplayLevel, L as LifecyclePort, E as EverfurChatDraftStore } from './attachments-CUOGILir.cjs';
5
+ import { a as ChatCheckinTarget } from './ports-BPKxFOSe.cjs';
6
+ import { W as WidgetPet, P as PetProfileInput } from './petsRepository-BnVre3q7.cjs';
7
+ import { U as UrgencyDisplayLevel, L as LifecyclePort, E as EverfurChatDraftStore } from './attachments-DI710no4.cjs';
8
8
 
9
9
  /** Where a picked image comes from: the host's photo library, or its camera. */
10
10
  type AttachmentSource = 'photo' | 'camera';
@@ -1,6 +1,6 @@
1
1
  import { ReactNode } from 'react';
2
2
  import { StyleProp, ViewStyle } from 'react-native';
3
- import { f as RecordsScreenBaseProps } from './useRecordsDepth-CARTuHKh.cjs';
3
+ import { f as RecordsScreenBaseProps } from './useRecordsDepth-COJ0wSYK.cjs';
4
4
 
5
5
  interface EverfurRecordsDepthProps extends Pick<RecordsScreenBaseProps, 'petRef' | 'petName' | 'onNavigate' | 'onBack'> {
6
6
  readonly style?: StyleProp<ViewStyle>;
@@ -1,5 +1,5 @@
1
1
  import { CSSProperties, ReactNode } from 'react';
2
- import { f as RecordsScreenBaseProps } from './useRecordsDepth-CARTuHKh.cjs';
2
+ import { f as RecordsScreenBaseProps } from './useRecordsDepth-COJ0wSYK.cjs';
3
3
 
4
4
  interface EverfurRecordsDepthProps extends Pick<RecordsScreenBaseProps, 'petRef' | 'petName' | 'onNavigate' | 'onBack'> {
5
5
  readonly style?: CSSProperties;
@@ -1,6 +1,6 @@
1
1
  import { ReactNode } from 'react';
2
2
  import { StyleProp, ViewStyle } from 'react-native';
3
- import { f as RecordsScreenBaseProps } from './useRecordsDepth-fPSv-GXU.js';
3
+ import { f as RecordsScreenBaseProps } from './useRecordsDepth-Z9FF5X4E.js';
4
4
 
5
5
  interface EverfurRecordsDepthProps extends Pick<RecordsScreenBaseProps, 'petRef' | 'petName' | 'onNavigate' | 'onBack'> {
6
6
  readonly style?: StyleProp<ViewStyle>;
@@ -1,5 +1,5 @@
1
1
  import { CSSProperties, ReactNode } from 'react';
2
- import { f as RecordsScreenBaseProps } from './useRecordsDepth-fPSv-GXU.js';
2
+ import { f as RecordsScreenBaseProps } from './useRecordsDepth-Z9FF5X4E.js';
3
3
 
4
4
  interface EverfurRecordsDepthProps extends Pick<RecordsScreenBaseProps, 'petRef' | 'petName' | 'onNavigate' | 'onBack'> {
5
5
  readonly style?: CSSProperties;
@@ -61,4 +61,43 @@ interface TelevetBookedScreenProps {
61
61
  }
62
62
  declare function TelevetBookedScreen({ consult, petName, onDone, onAddToCalendar, canJoinInApp, lengthMinutes, sharedRecords, sentPhoto, }: TelevetBookedScreenProps): ReactNode;
63
63
 
64
- export { type TelevetCalendarWriter as T, type TelevetCalendarEvent as a, TelevetBookedScreen as b, type TelevetBookedScreenProps as c, televetConsultCalendarKey as t };
64
+ /** A picked-but-not-yet-uploaded attachment, in the host's own terms. */
65
+ interface TelevetIntakeMediaItem {
66
+ readonly uri: string;
67
+ readonly filename: string;
68
+ readonly mimeType: string;
69
+ readonly fileSize: number;
70
+ }
71
+ /**
72
+ * The host's media picker.
73
+ *
74
+ * Resolves the picks, or null when the owner cancelled. The SDK takes no picker dependency and opens no file
75
+ * dialog of its own; a partner supplies whichever picker its site already has, typically an `<input
76
+ * type="file">` whose `File` objects it turns into object URLs.
77
+ *
78
+ * `limit` is the remaining headroom, so the host can cap its own selection rather than returning picks this
79
+ * row has to silently discard.
80
+ */
81
+ type TelevetMediaPicker = (limit: number) => Promise<readonly TelevetIntakeMediaItem[] | null>;
82
+ interface TelevetIntakeMediaProps {
83
+ readonly media: readonly TelevetIntakeMediaItem[];
84
+ readonly onChange: (next: readonly TelevetIntakeMediaItem[]) => void;
85
+ /** Absent, the row renders nothing at all. There is no disabled Add control. */
86
+ readonly onPickMedia?: TelevetMediaPicker | undefined;
87
+ /**
88
+ * The list's accessible name.
89
+ *
90
+ * Required, with no default string here: naming the group is what makes the tiles announce as a set, and
91
+ * the name is user-facing copy this SDK does not author. The intake step passes a ported key down.
92
+ */
93
+ readonly listLabel: string;
94
+ /**
95
+ * A line under the row, or nothing. The booking passes the artifact's "Optional. A close-up in good light
96
+ * helps." only once the televet presign has answered, because the advice is true only when a photo can reach
97
+ * the vet. Absent, nothing is drawn.
98
+ */
99
+ readonly meta?: string | null | undefined;
100
+ }
101
+ declare function TelevetIntakeMedia({ media, onChange, onPickMedia, listLabel, meta }: TelevetIntakeMediaProps): ReactNode;
102
+
103
+ export { type TelevetCalendarWriter as T, type TelevetMediaPicker as a, type TelevetCalendarEvent as b, type TelevetIntakeMediaItem as c, TelevetBookedScreen as d, type TelevetBookedScreenProps as e, TelevetIntakeMedia as f, type TelevetIntakeMediaProps as g, televetConsultCalendarKey as t };
@@ -61,4 +61,43 @@ interface TelevetBookedScreenProps {
61
61
  }
62
62
  declare function TelevetBookedScreen({ consult, petName, onDone, onAddToCalendar, canJoinInApp, lengthMinutes, sharedRecords, sentPhoto, }: TelevetBookedScreenProps): ReactNode;
63
63
 
64
- export { type TelevetCalendarWriter as T, type TelevetCalendarEvent as a, TelevetBookedScreen as b, type TelevetBookedScreenProps as c, televetConsultCalendarKey as t };
64
+ /** A picked-but-not-yet-uploaded attachment, in the host's own terms. */
65
+ interface TelevetIntakeMediaItem {
66
+ readonly uri: string;
67
+ readonly filename: string;
68
+ readonly mimeType: string;
69
+ readonly fileSize: number;
70
+ }
71
+ /**
72
+ * The host's media picker.
73
+ *
74
+ * Resolves the picks, or null when the owner cancelled. The SDK takes no picker dependency and opens no file
75
+ * dialog of its own; a partner supplies whichever picker its site already has, typically an `<input
76
+ * type="file">` whose `File` objects it turns into object URLs.
77
+ *
78
+ * `limit` is the remaining headroom, so the host can cap its own selection rather than returning picks this
79
+ * row has to silently discard.
80
+ */
81
+ type TelevetMediaPicker = (limit: number) => Promise<readonly TelevetIntakeMediaItem[] | null>;
82
+ interface TelevetIntakeMediaProps {
83
+ readonly media: readonly TelevetIntakeMediaItem[];
84
+ readonly onChange: (next: readonly TelevetIntakeMediaItem[]) => void;
85
+ /** Absent, the row renders nothing at all. There is no disabled Add control. */
86
+ readonly onPickMedia?: TelevetMediaPicker | undefined;
87
+ /**
88
+ * The list's accessible name.
89
+ *
90
+ * Required, with no default string here: naming the group is what makes the tiles announce as a set, and
91
+ * the name is user-facing copy this SDK does not author. The intake step passes a ported key down.
92
+ */
93
+ readonly listLabel: string;
94
+ /**
95
+ * A line under the row, or nothing. The booking passes the artifact's "Optional. A close-up in good light
96
+ * helps." only once the televet presign has answered, because the advice is true only when a photo can reach
97
+ * the vet. Absent, nothing is drawn.
98
+ */
99
+ readonly meta?: string | null | undefined;
100
+ }
101
+ declare function TelevetIntakeMedia({ media, onChange, onPickMedia, listLabel, meta }: TelevetIntakeMediaProps): ReactNode;
102
+
103
+ export { type TelevetCalendarWriter as T, type TelevetMediaPicker as a, type TelevetCalendarEvent as b, type TelevetIntakeMediaItem as c, TelevetBookedScreen as d, type TelevetBookedScreenProps as e, TelevetIntakeMedia as f, type TelevetIntakeMediaProps as g, televetConsultCalendarKey as t };
@@ -1,8 +1,8 @@
1
1
  import { ReactNode } from 'react';
2
2
  import { StyleProp, ViewStyle } from 'react-native';
3
3
  import { E as EverfurResult } from '../EverfurResult-ZtH-YV1h.cjs';
4
- import { A as AuthContext } from '../identity-b5Vp32Vp.cjs';
5
- export { I as IdentityProvider, n as newSessionId } from '../identity-b5Vp32Vp.cjs';
4
+ import { A as AuthContext } from '../identity-DUlshgow.cjs';
5
+ export { I as IdentityProvider, n as newSessionId } from '../identity-DUlshgow.cjs';
6
6
  import { P as PetRef } from '../ids-B2GAAifq.cjs';
7
7
  export { B as Brand, U as UserRef, _ as __brand } from '../ids-B2GAAifq.cjs';
8
8
  import { z } from 'zod';
@@ -13,7 +13,7 @@ import { E as EverfurError } from '../EverfurError-DmELDpXp.cjs';
13
13
  export { a as EverfurErrorCategory, b as EverfurErrorCode } from '../EverfurError-DmELDpXp.cjs';
14
14
  import { D as DisabledLevel, a as CapabilityDecision } from '../resolve-D4Ywz5OS.cjs';
15
15
  export { b as CapabilityDisabled, C as CapabilityName } from '../resolve-D4Ywz5OS.cjs';
16
- export { A as AcceptedFrame, a as AnalysisCompleteFrame, b as AnalysisStartedFrame, D as DeltaFrame, c as DoneFrame, E as ErrorFrame, d as EverfurRequest, e as EverfurRequestBase, F as Frame, f as FrameBase, g as FrameKind, H as HeartbeatFrame, h as HttpMethod, M as MultipartBody, T as TransportPort, U as UnknownFrame, i as UrgencyLevel } from '../config-h5h6TsHL.cjs';
16
+ export { A as AcceptedFrame, a as AnalysisCompleteFrame, b as AnalysisStartedFrame, D as DeltaFrame, c as DoneFrame, E as ErrorFrame, d as EverfurRequest, e as EverfurRequestBase, F as Frame, f as FrameBase, g as FrameKind, H as HeartbeatFrame, h as HttpMethod, M as MultipartBody, T as TransportPort, U as UnknownFrame, i as UrgencyLevel } from '../config-Daa1plhQ.cjs';
17
17
 
18
18
  /**
19
19
  * The full /state payload. `degraded` + `cache_epoch` + `cache_key` are additive fields an older backend
@@ -1,8 +1,8 @@
1
1
  import { ReactNode } from 'react';
2
2
  import { StyleProp, ViewStyle } from 'react-native';
3
3
  import { E as EverfurResult } from '../EverfurResult-SGvHKsCB.js';
4
- import { A as AuthContext } from '../identity-EC5-apbY.js';
5
- export { I as IdentityProvider, n as newSessionId } from '../identity-EC5-apbY.js';
4
+ import { A as AuthContext } from '../identity-BhT7oJDS.js';
5
+ export { I as IdentityProvider, n as newSessionId } from '../identity-BhT7oJDS.js';
6
6
  import { P as PetRef } from '../ids-B2GAAifq.js';
7
7
  export { B as Brand, U as UserRef, _ as __brand } from '../ids-B2GAAifq.js';
8
8
  import { z } from 'zod';
@@ -13,7 +13,7 @@ import { E as EverfurError } from '../EverfurError-DmELDpXp.js';
13
13
  export { a as EverfurErrorCategory, b as EverfurErrorCode } from '../EverfurError-DmELDpXp.js';
14
14
  import { D as DisabledLevel, a as CapabilityDecision } from '../resolve-D4Ywz5OS.js';
15
15
  export { b as CapabilityDisabled, C as CapabilityName } from '../resolve-D4Ywz5OS.js';
16
- export { A as AcceptedFrame, a as AnalysisCompleteFrame, b as AnalysisStartedFrame, D as DeltaFrame, c as DoneFrame, E as ErrorFrame, d as EverfurRequest, e as EverfurRequestBase, F as Frame, f as FrameBase, g as FrameKind, H as HeartbeatFrame, h as HttpMethod, M as MultipartBody, T as TransportPort, U as UnknownFrame, i as UrgencyLevel } from '../config-ZxwCylac.js';
16
+ export { A as AcceptedFrame, a as AnalysisCompleteFrame, b as AnalysisStartedFrame, D as DeltaFrame, c as DoneFrame, E as ErrorFrame, d as EverfurRequest, e as EverfurRequestBase, F as Frame, f as FrameBase, g as FrameKind, H as HeartbeatFrame, h as HttpMethod, M as MultipartBody, T as TransportPort, U as UnknownFrame, i as UrgencyLevel } from '../config-BM0sv5jx.js';
17
17
 
18
18
  /**
19
19
  * The full /state payload. `degraded` + `cache_epoch` + `cache_key` are additive fields an older backend
@@ -1,7 +1,7 @@
1
1
  import { E as EverfurError } from './EverfurError-DmELDpXp.cjs';
2
- import { R as RequestFunnel } from './requestFunnel-C_cZXhIA.cjs';
2
+ import { R as RequestFunnel } from './requestFunnel-DMR_1T3O.cjs';
3
3
  import { F as FileHandle, U as UploadTransport, a as UploadPolicyWire } from './ports-BN6RHF9W.cjs';
4
- import { R as ReadableStore, T as Timers } from './ports-ZmJYgd5I.cjs';
4
+ import { R as ReadableStore, T as Timers } from './ports-BPKxFOSe.cjs';
5
5
 
6
6
  /** The image MIME types the chat accepts (the server's `CHAT_ATTACHMENT` rule, plus the `image/jpg` alias). */
7
7
  declare const ATTACHMENT_MIME_TYPES: readonly string[];
@@ -1,12 +1,12 @@
1
1
  import { E as EverfurError } from './EverfurError-DmELDpXp.cjs';
2
2
  import { E as EverfurResult } from './EverfurResult-ZtH-YV1h.cjs';
3
3
  import { C as ConversationId, P as PetRef, b as ResponseId } from './ids-B2GAAifq.cjs';
4
- import { f as ChatFeedbackType, l as ChatStatus, i as ChatMessage, c as ChatConversationListOptions, d as ChatConversationPage, g as ChatHistoryOptions, h as ChatMessagePage, a as ChatCheckinTarget, e as ChatFeedbackReceipt } from './ports-ZmJYgd5I.cjs';
5
- import { C as CheckinAnswer, a as CheckinOutcome } from './casesRepository-CJchNp3x.cjs';
6
- import { i as UrgencyLevel } from './config-h5h6TsHL.cjs';
7
- import { W as WidgetPet } from './petsRepository-BJsJ4cju.cjs';
4
+ import { f as ChatFeedbackType, l as ChatStatus, i as ChatMessage, c as ChatConversationListOptions, d as ChatConversationPage, g as ChatHistoryOptions, h as ChatMessagePage, a as ChatCheckinTarget, e as ChatFeedbackReceipt } from './ports-BPKxFOSe.cjs';
5
+ import { C as CheckinAnswer, a as CheckinOutcome } from './casesRepository-B-md8h1S.cjs';
6
+ import { i as UrgencyLevel } from './config-Daa1plhQ.cjs';
7
+ import { W as WidgetPet } from './petsRepository-BnVre3q7.cjs';
8
8
  import { U as UploadTransport, F as FileHandle } from './ports-BN6RHF9W.cjs';
9
- import { c as AttachmentQueue, d as AttachmentState, A as AttachmentError, b as AttachmentOutcome } from './attachments-Ce06TWqe.cjs';
9
+ import { c as AttachmentQueue, d as AttachmentState, A as AttachmentError, b as AttachmentOutcome } from './attachments-B2GjBgvF.cjs';
10
10
 
11
11
  /** The three thumbs. `'neutral'` is the app's rotated thumbs-down glyph. */
12
12
  type ChatSentiment = 'up' | 'neutral' | 'down';
@@ -1,7 +1,7 @@
1
1
  import { E as EverfurError } from './EverfurError-DmELDpXp.js';
2
- import { R as RequestFunnel } from './requestFunnel-Ve9BshTB.js';
2
+ import { R as RequestFunnel } from './requestFunnel-CiSX2pun.js';
3
3
  import { F as FileHandle, U as UploadTransport, a as UploadPolicyWire } from './ports-BN6RHF9W.js';
4
- import { R as ReadableStore, T as Timers } from './ports-nXHf50_X.js';
4
+ import { R as ReadableStore, T as Timers } from './ports-Di9rdLO9.js';
5
5
 
6
6
  /** The image MIME types the chat accepts (the server's `CHAT_ATTACHMENT` rule, plus the `image/jpg` alias). */
7
7
  declare const ATTACHMENT_MIME_TYPES: readonly string[];
@@ -1,12 +1,12 @@
1
1
  import { E as EverfurError } from './EverfurError-DmELDpXp.js';
2
2
  import { E as EverfurResult } from './EverfurResult-SGvHKsCB.js';
3
3
  import { C as ConversationId, P as PetRef, b as ResponseId } from './ids-B2GAAifq.js';
4
- import { f as ChatFeedbackType, l as ChatStatus, i as ChatMessage, c as ChatConversationListOptions, d as ChatConversationPage, g as ChatHistoryOptions, h as ChatMessagePage, a as ChatCheckinTarget, e as ChatFeedbackReceipt } from './ports-nXHf50_X.js';
5
- import { C as CheckinAnswer, a as CheckinOutcome } from './casesRepository-DAVcY3jC.js';
6
- import { i as UrgencyLevel } from './config-ZxwCylac.js';
7
- import { W as WidgetPet } from './petsRepository-CuYZZaI5.js';
4
+ import { f as ChatFeedbackType, l as ChatStatus, i as ChatMessage, c as ChatConversationListOptions, d as ChatConversationPage, g as ChatHistoryOptions, h as ChatMessagePage, a as ChatCheckinTarget, e as ChatFeedbackReceipt } from './ports-Di9rdLO9.js';
5
+ import { C as CheckinAnswer, a as CheckinOutcome } from './casesRepository-CC6951TK.js';
6
+ import { i as UrgencyLevel } from './config-BM0sv5jx.js';
7
+ import { W as WidgetPet } from './petsRepository-BwxmfX_s.js';
8
8
  import { U as UploadTransport, F as FileHandle } from './ports-BN6RHF9W.js';
9
- import { c as AttachmentQueue, d as AttachmentState, A as AttachmentError, b as AttachmentOutcome } from './attachments-CPRFfoHT.js';
9
+ import { c as AttachmentQueue, d as AttachmentState, A as AttachmentError, b as AttachmentOutcome } from './attachments-DNaSbmA3.js';
10
10
 
11
11
  /** The three thumbs. `'neutral'` is the app's rotated thumbs-down glyph. */
12
12
  type ChatSentiment = 'up' | 'neutral' | 'down';
@@ -1,8 +1,8 @@
1
1
  import { n as TelevetStatePolicy, j as TelevetBookingEntitlement, k as TelevetCancellationPolicy, l as TelevetClinician, b as TelevetSlot, m as TelevetSlotHold, i as TelevetBookingBody, T as TelevetConsult, a as TelevetCancelReceipt, o as TelevetTriageVerdict, g as ConsultStatus } from './bookingTypes-D4pD3tHs.js';
2
2
  import { E as EverfurError } from './EverfurError-DmELDpXp.js';
3
3
  import { E as EverfurResult } from './EverfurResult-SGvHKsCB.js';
4
- import { R as RequestFunnel } from './requestFunnel-Ve9BshTB.js';
5
- import { A as AuthContext } from './identity-EC5-apbY.js';
4
+ import { R as RequestFunnel } from './requestFunnel-CiSX2pun.js';
5
+ import { A as AuthContext } from './identity-BhT7oJDS.js';
6
6
  import { E as ErrorPolicyPort } from './ErrorPolicyPort-D22LUVrK.js';
7
7
  import { T as TelemetryPort } from './TelemetryPort-BDNr00hu.js';
8
8
  import { b as VetCallCredential, c as VetCallJoinRefusal } from './callRoom-7wrE3RP2.js';
@@ -1,8 +1,8 @@
1
1
  import { n as TelevetStatePolicy, j as TelevetBookingEntitlement, k as TelevetCancellationPolicy, l as TelevetClinician, b as TelevetSlot, m as TelevetSlotHold, i as TelevetBookingBody, T as TelevetConsult, a as TelevetCancelReceipt, o as TelevetTriageVerdict, g as ConsultStatus } from './bookingTypes-D4pD3tHs.cjs';
2
2
  import { E as EverfurError } from './EverfurError-DmELDpXp.cjs';
3
3
  import { E as EverfurResult } from './EverfurResult-ZtH-YV1h.cjs';
4
- import { R as RequestFunnel } from './requestFunnel-C_cZXhIA.cjs';
5
- import { A as AuthContext } from './identity-b5Vp32Vp.cjs';
4
+ import { R as RequestFunnel } from './requestFunnel-DMR_1T3O.cjs';
5
+ import { A as AuthContext } from './identity-DUlshgow.cjs';
6
6
  import { E as ErrorPolicyPort } from './ErrorPolicyPort-D6CybiqJ.cjs';
7
7
  import { T as TelemetryPort } from './TelemetryPort-BDNr00hu.cjs';
8
8
  import { b as VetCallCredential, c as VetCallJoinRefusal } from './callRoom-B_EqaUzx.cjs';
@@ -1,5 +1,5 @@
1
1
  import { E as EverfurResult } from './EverfurResult-ZtH-YV1h.cjs';
2
- import { A as AuthContext } from './identity-b5Vp32Vp.cjs';
2
+ import { A as AuthContext } from './identity-DUlshgow.cjs';
3
3
  import { P as PetRef } from './ids-B2GAAifq.cjs';
4
4
 
5
5
  /** The owner's answer to a check-in, the wire values of the consumer `CheckinResponse` enum. */
@@ -1,5 +1,5 @@
1
1
  import { E as EverfurResult } from './EverfurResult-SGvHKsCB.js';
2
- import { A as AuthContext } from './identity-EC5-apbY.js';
2
+ import { A as AuthContext } from './identity-BhT7oJDS.js';
3
3
  import { P as PetRef } from './ids-B2GAAifq.js';
4
4
 
5
5
  /** The owner's answer to a check-in, the wire values of the consumer `CheckinResponse` enum. */
@@ -1,18 +1,18 @@
1
- export { C as ChatFeedbackReason, a as ChatFeedbackReasonOption, b as ChatSentiment, E as EverfurChatDraftStore, L as LifecyclePort, U as UrgencyDisplayLevel, c as UseChatAttachmentsOptions, d as UseChatAttachmentsState, e as UseEverfurChatState, f as UseEverfurPetsState, u as useChatAttachments, g as useEverfurChat, h as useEverfurPets } from '../attachments-CUOGILir.cjs';
2
- export { A as AttachmentSource, E as EverfurChat, a as EverfurChatAttachments, b as EverfurChatProps, R as RenderVetAction } from '../Chat-bATY4atj.cjs';
1
+ export { C as ChatFeedbackReason, a as ChatFeedbackReasonOption, b as ChatSentiment, E as EverfurChatDraftStore, L as LifecyclePort, U as UrgencyDisplayLevel, c as UseChatAttachmentsOptions, d as UseChatAttachmentsState, e as UseEverfurChatState, f as UseEverfurPetsState, u as useChatAttachments, g as useEverfurChat, h as useEverfurPets } from '../attachments-DI710no4.cjs';
2
+ export { A as AttachmentSource, E as EverfurChat, a as EverfurChatAttachments, b as EverfurChatProps, R as RenderVetAction } from '../Chat-DQOsAumH.cjs';
3
3
  import { U as UploadTransport } from '../ports-BN6RHF9W.cjs';
4
- export { C as ChatCheckin, a as ChatCheckinTarget, b as ChatConversation, c as ChatConversationListOptions, d as ChatConversationPage, e as ChatFeedbackReceipt, f as ChatFeedbackType, g as ChatHistoryOptions, h as ChatMessagePage } from '../ports-ZmJYgd5I.cjs';
5
- export { C as CheckinAnswer, a as CheckinOutcome, W as WatchCase } from '../casesRepository-CJchNp3x.cjs';
6
- export { P as EverfurChatPet, W as WidgetPet } from '../petsRepository-BJsJ4cju.cjs';
7
- export { A as AttachmentError, a as AttachmentErrorCode, b as AttachmentOutcome, c as AttachmentQueue, d as AttachmentState, e as AttachmentStatus } from '../attachments-Ce06TWqe.cjs';
4
+ export { C as ChatCheckin, a as ChatCheckinTarget, b as ChatConversation, c as ChatConversationListOptions, d as ChatConversationPage, e as ChatFeedbackReceipt, f as ChatFeedbackType, g as ChatHistoryOptions, h as ChatMessagePage } from '../ports-BPKxFOSe.cjs';
5
+ export { C as CheckinAnswer, a as CheckinOutcome, W as WatchCase } from '../casesRepository-B-md8h1S.cjs';
6
+ export { P as EverfurChatPet, W as WidgetPet } from '../petsRepository-BnVre3q7.cjs';
7
+ export { A as AttachmentError, a as AttachmentErrorCode, b as AttachmentOutcome, c as AttachmentQueue, d as AttachmentState, e as AttachmentStatus } from '../attachments-B2GjBgvF.cjs';
8
8
  import '../EverfurError-DmELDpXp.cjs';
9
9
  import '../EverfurResult-ZtH-YV1h.cjs';
10
10
  import '../ids-B2GAAifq.cjs';
11
- import '../config-h5h6TsHL.cjs';
11
+ import '../config-Daa1plhQ.cjs';
12
12
  import 'react';
13
13
  import 'react-native';
14
- import '../identity-b5Vp32Vp.cjs';
15
- import '../requestFunnel-C_cZXhIA.cjs';
14
+ import '../identity-DUlshgow.cjs';
15
+ import '../requestFunnel-DMR_1T3O.cjs';
16
16
  import '../ErrorPolicyPort-D6CybiqJ.cjs';
17
17
  import '../TelemetryPort-BDNr00hu.cjs';
18
18
  import '../profile-CSs1wlXT.cjs';
@@ -1,18 +1,18 @@
1
- export { C as ChatFeedbackReason, a as ChatFeedbackReasonOption, b as ChatSentiment, E as EverfurChatDraftStore, L as LifecyclePort, U as UrgencyDisplayLevel, c as UseChatAttachmentsOptions, d as UseChatAttachmentsState, e as UseEverfurChatState, f as UseEverfurPetsState, u as useChatAttachments, g as useEverfurChat, h as useEverfurPets } from '../attachments-CXAnZcEg.js';
2
- export { A as AttachmentSource, E as EverfurChat, a as EverfurChatAttachments, b as EverfurChatProps, R as RenderVetAction } from '../Chat-DZpYH8Uh.js';
1
+ export { C as ChatFeedbackReason, a as ChatFeedbackReasonOption, b as ChatSentiment, E as EverfurChatDraftStore, L as LifecyclePort, U as UrgencyDisplayLevel, c as UseChatAttachmentsOptions, d as UseChatAttachmentsState, e as UseEverfurChatState, f as UseEverfurPetsState, u as useChatAttachments, g as useEverfurChat, h as useEverfurPets } from '../attachments-SF88N654.js';
2
+ export { A as AttachmentSource, E as EverfurChat, a as EverfurChatAttachments, b as EverfurChatProps, R as RenderVetAction } from '../Chat-CFi5cNUF.js';
3
3
  import { U as UploadTransport } from '../ports-BN6RHF9W.js';
4
- export { C as ChatCheckin, a as ChatCheckinTarget, b as ChatConversation, c as ChatConversationListOptions, d as ChatConversationPage, e as ChatFeedbackReceipt, f as ChatFeedbackType, g as ChatHistoryOptions, h as ChatMessagePage } from '../ports-nXHf50_X.js';
5
- export { C as CheckinAnswer, a as CheckinOutcome, W as WatchCase } from '../casesRepository-DAVcY3jC.js';
6
- export { P as EverfurChatPet, W as WidgetPet } from '../petsRepository-CuYZZaI5.js';
7
- export { A as AttachmentError, a as AttachmentErrorCode, b as AttachmentOutcome, c as AttachmentQueue, d as AttachmentState, e as AttachmentStatus } from '../attachments-CPRFfoHT.js';
4
+ export { C as ChatCheckin, a as ChatCheckinTarget, b as ChatConversation, c as ChatConversationListOptions, d as ChatConversationPage, e as ChatFeedbackReceipt, f as ChatFeedbackType, g as ChatHistoryOptions, h as ChatMessagePage } from '../ports-Di9rdLO9.js';
5
+ export { C as CheckinAnswer, a as CheckinOutcome, W as WatchCase } from '../casesRepository-CC6951TK.js';
6
+ export { P as EverfurChatPet, W as WidgetPet } from '../petsRepository-BwxmfX_s.js';
7
+ export { A as AttachmentError, a as AttachmentErrorCode, b as AttachmentOutcome, c as AttachmentQueue, d as AttachmentState, e as AttachmentStatus } from '../attachments-DNaSbmA3.js';
8
8
  import '../EverfurError-DmELDpXp.js';
9
9
  import '../EverfurResult-SGvHKsCB.js';
10
10
  import '../ids-B2GAAifq.js';
11
- import '../config-ZxwCylac.js';
11
+ import '../config-BM0sv5jx.js';
12
12
  import 'react';
13
13
  import 'react-native';
14
- import '../identity-EC5-apbY.js';
15
- import '../requestFunnel-Ve9BshTB.js';
14
+ import '../identity-BhT7oJDS.js';
15
+ import '../requestFunnel-CiSX2pun.js';
16
16
  import '../ErrorPolicyPort-D22LUVrK.js';
17
17
  import '../TelemetryPort-BDNr00hu.js';
18
18
  import '../profile-CSs1wlXT.js';
@@ -1,4 +1,4 @@
1
- 'use strict';var zod=require('zod');var Pt=Object.defineProperty;var o=(e,r)=>Pt(e,"name",{value:r,configurable:true});var je=Object.freeze([Object.freeze({wireCode:"AccessDeniedException",envelope:"http_envelope",httpStatus:403,retryable:false}),Object.freeze({wireCode:"AuthorizationException",envelope:"http_envelope",httpStatus:401,retryable:false}),Object.freeze({wireCode:"ConflictException",envelope:"http_envelope",httpStatus:409,retryable:true}),Object.freeze({wireCode:"DAILY_QUOTA_EXCEEDED",envelope:"http_envelope",httpStatus:429,retryable:true}),Object.freeze({wireCode:"FILE_TOO_LARGE",envelope:"http_envelope",httpStatus:400,retryable:false}),Object.freeze({wireCode:"IDEMPOTENCY_KEY_IN_FLIGHT",envelope:"http_envelope",httpStatus:409,retryable:true}),Object.freeze({wireCode:"IDEMPOTENCY_KEY_REUSED_DIFFERENT_REQUEST",envelope:"http_envelope",httpStatus:409,retryable:false}),Object.freeze({wireCode:"INVALID_CONTENT_TYPE",envelope:"http_envelope",httpStatus:400,retryable:false}),Object.freeze({wireCode:"InternalFailureException",envelope:"http_envelope",httpStatus:500,retryable:true}),Object.freeze({wireCode:"MethodNotAllowedException",envelope:"http_envelope",httpStatus:405,retryable:false}),Object.freeze({wireCode:"NotImplementedException",envelope:"http_envelope",httpStatus:501,retryable:false}),Object.freeze({wireCode:"PaymentRequiredException",envelope:"http_envelope",httpStatus:402,retryable:false}),Object.freeze({wireCode:"ResourceNotFoundException",envelope:"http_envelope",httpStatus:404,retryable:false}),Object.freeze({wireCode:"ServiceUnavailableException",envelope:"http_envelope",httpStatus:503,retryable:true}),Object.freeze({wireCode:"TIER_UPGRADE_REQUIRED",envelope:"http_envelope",httpStatus:402,retryable:false}),Object.freeze({wireCode:"ThrottlingException",envelope:"http_envelope",httpStatus:429,retryable:true}),Object.freeze({wireCode:"ValidationException",envelope:"http_envelope",httpStatus:400,retryable:false}),Object.freeze({wireCode:"accessDenied",envelope:"http_envelope",httpStatus:403,retryable:false}),Object.freeze({wireCode:"access_denied",envelope:"oauth_error",httpStatus:302,retryable:false}),Object.freeze({wireCode:"attachment_unreadable",envelope:"http_envelope",httpStatus:400,retryable:false}),Object.freeze({wireCode:"authExpired",envelope:"http_envelope",httpStatus:401,retryable:true}),Object.freeze({wireCode:"authRejected",envelope:"http_envelope",httpStatus:401,retryable:false}),Object.freeze({wireCode:"consent_invalid",envelope:"http_envelope",httpStatus:422,retryable:false}),Object.freeze({wireCode:"consent_required",envelope:"http_envelope",httpStatus:422,retryable:false}),Object.freeze({wireCode:"consent_scope_wrong_route",envelope:"http_envelope",httpStatus:400,retryable:false}),Object.freeze({wireCode:"device_cipher_unavailable",envelope:"http_envelope",httpStatus:503,retryable:true}),Object.freeze({wireCode:"email_invalid",envelope:"http_envelope",httpStatus:422,retryable:false}),Object.freeze({wireCode:"event_cursor_invalid",envelope:"http_envelope",httpStatus:400,retryable:false}),Object.freeze({wireCode:"event_filter_invalid",envelope:"http_envelope",httpStatus:400,retryable:false}),Object.freeze({wireCode:"event_payload_invalid",envelope:"http_envelope",httpStatus:400,retryable:false}),Object.freeze({wireCode:"event_type_not_available",envelope:"http_envelope",httpStatus:400,retryable:false}),Object.freeze({wireCode:"event_type_unknown",envelope:"http_envelope",httpStatus:400,retryable:false}),Object.freeze({wireCode:"idempotency_key_invalid",envelope:"http_envelope",httpStatus:400,retryable:false}),Object.freeze({wireCode:"idempotency_key_required",envelope:"http_envelope",httpStatus:400,retryable:false}),Object.freeze({wireCode:"idempotency_key_reused",envelope:"http_envelope",httpStatus:409,retryable:false}),Object.freeze({wireCode:"insufficientCapability",envelope:"http_envelope",httpStatus:403,retryable:false}),Object.freeze({wireCode:"insufficient_scope",envelope:"http_envelope",httpStatus:403,retryable:false}),Object.freeze({wireCode:"internal_error",envelope:"sse_frame",httpStatus:200,retryable:false}),Object.freeze({wireCode:"invalidRequest",envelope:"http_envelope",httpStatus:400,retryable:false}),Object.freeze({wireCode:"invalid_client",envelope:"oauth_error",httpStatus:401,retryable:false}),Object.freeze({wireCode:"invalid_client_metadata",envelope:"oauth_error",httpStatus:400,retryable:false}),Object.freeze({wireCode:"invalid_grant",envelope:"oauth_error",httpStatus:400,retryable:false}),Object.freeze({wireCode:"invalid_redirect_uri",envelope:"oauth_error",httpStatus:400,retryable:false}),Object.freeze({wireCode:"invalid_request",envelope:"oauth_error",httpStatus:400,retryable:false}),Object.freeze({wireCode:"invalid_scope",envelope:"oauth_error",httpStatus:400,retryable:false}),Object.freeze({wireCode:"invalid_target",envelope:"oauth_error",httpStatus:400,retryable:false}),Object.freeze({wireCode:"mcp_connection_not_found",envelope:"http_envelope",httpStatus:404,retryable:false}),Object.freeze({wireCode:"mcp_request_conflict",envelope:"http_envelope",httpStatus:409,retryable:false}),Object.freeze({wireCode:"mcp_request_gone",envelope:"http_envelope",httpStatus:410,retryable:false}),Object.freeze({wireCode:"mcp_request_not_found",envelope:"http_envelope",httpStatus:404,retryable:false}),Object.freeze({wireCode:"not_found",envelope:"sse_frame",httpStatus:200,retryable:false}),Object.freeze({wireCode:"partner_visit_link_conflict",envelope:"http_envelope",httpStatus:409,retryable:false}),Object.freeze({wireCode:"partner_visit_owner_only",envelope:"http_envelope",httpStatus:403,retryable:false}),Object.freeze({wireCode:"partner_visit_pet_already_mapped",envelope:"http_envelope",httpStatus:409,retryable:false}),Object.freeze({wireCode:"payload_too_large",envelope:"http_envelope",httpStatus:413,retryable:false}),Object.freeze({wireCode:"petRefInUse",envelope:"http_envelope",httpStatus:409,retryable:false}),Object.freeze({wireCode:"pet_health_list_removals_unconfirmed",envelope:"http_envelope",httpStatus:422,retryable:false}),Object.freeze({wireCode:"pet_health_species_unsupported",envelope:"http_envelope",httpStatus:422,retryable:false}),Object.freeze({wireCode:"pet_not_registered",envelope:"http_envelope",httpStatus:404,retryable:false}),Object.freeze({wireCode:"provider_unsupported",envelope:"http_envelope",httpStatus:422,retryable:false}),Object.freeze({wireCode:"rateLimited",envelope:"http_envelope",httpStatus:429,retryable:true}),Object.freeze({wireCode:"record_species_unsupported",envelope:"http_envelope",httpStatus:422,retryable:false}),Object.freeze({wireCode:"record_subject_not_found",envelope:"http_envelope",httpStatus:404,retryable:false}),Object.freeze({wireCode:"record_upload_invalid",envelope:"http_envelope",httpStatus:400,retryable:false}),Object.freeze({wireCode:"records_consent_required",envelope:"http_envelope",httpStatus:409,retryable:false}),Object.freeze({wireCode:"sandbox_only",envelope:"http_envelope",httpStatus:403,retryable:false}),Object.freeze({wireCode:"session_required",envelope:"http_envelope",httpStatus:403,retryable:false}),Object.freeze({wireCode:"share_limit_reached",envelope:"http_envelope",httpStatus:429,retryable:false}),Object.freeze({wireCode:"slow_down",envelope:"oauth_error",httpStatus:429,retryable:true}),Object.freeze({wireCode:"species_unsupported",envelope:"http_envelope",httpStatus:422,retryable:false}),Object.freeze({wireCode:"tenant_filter_invalid",envelope:"http_envelope",httpStatus:400,retryable:false}),Object.freeze({wireCode:"tenant_has_no_capabilities",envelope:"http_envelope",httpStatus:409,retryable:false}),Object.freeze({wireCode:"tenant_resource_not_found",envelope:"http_envelope",httpStatus:404,retryable:false}),Object.freeze({wireCode:"tenant_surface_not_enabled",envelope:"http_envelope",httpStatus:409,retryable:false}),Object.freeze({wireCode:"timeout",envelope:"sse_frame",httpStatus:200,retryable:true}),Object.freeze({wireCode:"token_invalid",envelope:"http_envelope",httpStatus:422,retryable:false}),Object.freeze({wireCode:"unavailable",envelope:"sse_frame",httpStatus:200,retryable:true}),Object.freeze({wireCode:"unavailable",envelope:"http_envelope",httpStatus:503,retryable:true}),Object.freeze({wireCode:"unsupported_grant_type",envelope:"oauth_error",httpStatus:400,retryable:false}),Object.freeze({wireCode:"unsupported_response_type",envelope:"oauth_error",httpStatus:302,retryable:false}),Object.freeze({wireCode:"verify_mint_rate_limited",envelope:"http_envelope",httpStatus:429,retryable:true}),Object.freeze({wireCode:"verify_mint_refused",envelope:"http_envelope",httpStatus:403,retryable:false}),Object.freeze({wireCode:"verify_mint_unavailable",envelope:"http_envelope",httpStatus:503,retryable:true}),Object.freeze({wireCode:"verify_user_ref_invalid",envelope:"http_envelope",httpStatus:422,retryable:false}),Object.freeze({wireCode:"webhook_endpoint_update_empty",envelope:"http_envelope",httpStatus:400,retryable:false}),Object.freeze({wireCode:"webhook_endpoint_update_invalid",envelope:"http_envelope",httpStatus:400,retryable:false}),Object.freeze({wireCode:"webhook_url_rejected",envelope:"http_envelope",httpStatus:400,retryable:false})]);Object.freeze(je.map(e=>e.wireCode));var Dt=Object.freeze({ValidationException:"validationFailed",AuthorizationException:"authRejected",PaymentRequiredException:"paymentRequired",AccessDeniedException:"accessDenied",ResourceNotFoundException:"resourceNotFound",ConflictException:"conflict",ThrottlingException:"rateLimited",InternalFailureException:"internalError",NotImplementedException:"notImplemented",ServiceUnavailableException:"serviceUnavailable",MethodNotAllowedException:"validationFailed",authExpired:"authExpired",unavailable:"serviceUnavailable",session_required:"sessionRequired",accessDenied:"accessDenied",invalidRequest:"sdkUpdateRequired",authRejected:"authRejected",rateLimited:"rateLimited",insufficientCapability:"accessDenied",event_cursor_invalid:"validationFailed",event_filter_invalid:"validationFailed",event_payload_invalid:"validationFailed",event_type_unknown:"validationFailed",idempotency_key_invalid:"validationFailed",idempotency_key_required:"validationFailed",idempotency_key_reused:"idempotencyConflict",payload_too_large:"validationFailed",webhook_url_rejected:"validationFailed",webhook_endpoint_update_empty:"validationFailed",webhook_endpoint_update_invalid:"validationFailed",event_type_not_available:"conflict",record_subject_not_found:"resourceNotFound",records_consent_required:"conflict",record_species_unsupported:"validationFailed",record_upload_invalid:"validationFailed",FILE_TOO_LARGE:"validationFailed",INVALID_CONTENT_TYPE:"validationFailed",attachment_unreadable:"validationFailed",provider_unsupported:"validationFailed",token_invalid:"validationFailed",device_cipher_unavailable:"serviceUnavailable",email_invalid:"validationFailed",consent_required:"validationFailed",consent_invalid:"validationFailed",consent_scope_wrong_route:"validationFailed",IDEMPOTENCY_KEY_IN_FLIGHT:"idempotencyInFlight",IDEMPOTENCY_KEY_REUSED_DIFFERENT_REQUEST:"idempotencyConflict",DAILY_QUOTA_EXCEEDED:"quotaExceeded",TIER_UPGRADE_REQUIRED:"paymentRequired",not_found:"conversationNotFound",timeout:"streamTimeout",internal_error:"internalError",invalid_request:"validationFailed",invalid_client:"authRejected",invalid_grant:"authRejected",unsupported_grant_type:"validationFailed",invalid_scope:"validationFailed",invalid_target:"validationFailed",invalid_redirect_uri:"validationFailed",invalid_client_metadata:"validationFailed",unsupported_response_type:"validationFailed",access_denied:"accessDenied",slow_down:"rateLimited",mcp_request_not_found:"resourceNotFound",mcp_request_gone:"resourceNotFound",mcp_connection_not_found:"resourceNotFound",mcp_request_conflict:"conflict",sandbox_only:"accessDenied",tenant_has_no_capabilities:"conflict",verify_mint_refused:"accessDenied",verify_mint_rate_limited:"rateLimited",verify_mint_unavailable:"serviceUnavailable",verify_user_ref_invalid:"validationFailed",insufficient_scope:"accessDenied",tenant_filter_invalid:"validationFailed",tenant_resource_not_found:"resourceNotFound",tenant_surface_not_enabled:"conflict",pet_health_species_unsupported:"validationFailed",pet_health_list_removals_unconfirmed:"validationFailed",petRefInUse:"conflict",share_limit_reached:"conflict",pet_not_registered:"resourceNotFound",species_unsupported:"validationFailed",partner_visit_owner_only:"accessDenied",partner_visit_link_conflict:"conflict",partner_visit_pet_already_mapped:"conflict"}),Lr=Object.freeze(je.map(e=>Object.freeze({wireCode:e.wireCode,envelope:e.envelope,retryable:e.retryable,normalized:Dt[e.wireCode]}))),Nt=new Map(Lr.map(e=>[e.envelope+e.wireCode.toUpperCase(),e])),Mt=Object.freeze(["http_envelope",...[...new Set(Lr.map(e=>e.envelope))].filter(e=>e!=="http_envelope").sort()]);function ve(e,r){if(typeof e!="string")return;let n=e.trim().toUpperCase();if(n.length!==0)for(let t of [r??"http_envelope",...Mt]){let i=Nt.get(t+n);if(i)return i}}o(ve,"contractErrorFor");function Lt(e){return e.envelope==="sse_frame"?`/errors#sse-${e.wireCode}`:e.envelope==="oauth_error"?`/errors#oauth-${e.wireCode}`:`/errors#${e.wireCode}`}o(Lt,"contractDocUrl");var Mr=null;function Br(e){return null}o(Br,"publishedDocUrl");var us=Object.freeze(["authExpired","authRejected","sessionRequired","accessDenied","paymentRequired","quotaExceeded","rateLimited","validationFailed","sdkUpdateRequired","conflict","idempotencyConflict","idempotencyInFlight","conversationNotFound","petNotFound","resourceNotFound","streamTimeout","mediaUploadFailed","moderationBlocked","upstreamLlmTimeout","internalError","notImplemented","serviceUnavailable","streamIncomplete","unknown"]),ds=Object.freeze(["authentication","authorization","entitlement","rateLimit","invalidRequest","notFound","conflict","connection","server","media","policy","unknown"]),Bt=Object.freeze({authExpired:"authentication",authRejected:"authentication",sessionRequired:"authentication",accessDenied:"authorization",paymentRequired:"entitlement",quotaExceeded:"rateLimit",rateLimited:"rateLimit",validationFailed:"invalidRequest",sdkUpdateRequired:"invalidRequest",conversationNotFound:"notFound",petNotFound:"notFound",resourceNotFound:"notFound",conflict:"conflict",idempotencyConflict:"conflict",idempotencyInFlight:"conflict",streamTimeout:"connection",streamIncomplete:"connection",upstreamLlmTimeout:"connection",serviceUnavailable:"connection",internalError:"server",notImplemented:"server",mediaUploadFailed:"media",moderationBlocked:"policy",unknown:"unknown"});function zr(e){return Bt[e]}o(zr,"categoryFor");function oe(e){let r=ve(e);if(r)return r.normalized;let n=(e??"").trim().toUpperCase(),t=n.replace(/[^A-Z0-9]/g,"");if(t==="AUTHREJECTED")return "authRejected";if(n.startsWith("AUTH"))return "authExpired";switch(t){case "DAILYQUOTAEXCEEDED":case "QUOTAEXCEEDED":return "quotaExceeded";case "RATELIMITED":case "TOOMANYREQUESTS":case "TELEVETRATELIMITED":return "rateLimited";case "IDEMPOTENCYKEYCONFLICT":case "IDEMPOTENCYCONFLICT":return "idempotencyConflict";case "ACCESSDENIED":case "FORBIDDEN":return "accessDenied";case "NOTFOUND":case "CONVERSATIONNOTFOUND":return "conversationNotFound";case "PETNOTFOUND":return "petNotFound";case "TIMEOUT":case "STREAMTIMEOUT":return "streamTimeout";case "MEDIAUPLOADFAILED":case "UNRECOGNIZEDVIDEOFORMAT":case "FILETOOSMALL":return "mediaUploadFailed";case "MODERATIONBLOCKED":return "moderationBlocked";case "UPSTREAMLLMTIMEOUT":return "upstreamLlmTimeout";case "INTERNALERROR":case "INTERNALSERVERERROR":return "internalError";case "STREAMINCOMPLETE":case "CHATSTREAMINCOMPLETE":return "streamIncomplete";case "INVALIDANALYSISTYPE":case "INVALIDUPLOADPURPOSE":return "unknown";default:return "unknown"}}o(oe,"fromWire");function jr(e){return e===401?"authExpired":e===403?"accessDenied":e===404?"conversationNotFound":e===409?"idempotencyConflict":e===421?"unknown":e===429?"rateLimited":e===400||e===422?"unknown":e>=500?"internalError":"unknown"}o(jr,"fromHttpStatus");var zt=new Set(["streamTimeout","rateLimited","internalError","upstreamLlmTimeout","streamIncomplete"]);function W(e){return zt.has(e)}o(W,"isAutoRetryable");var jt=new Set(["serviceUnavailable","conflict","idempotencyInFlight"]);function Ur(e){return W(e)||jt.has(e)}o(Ur,"isRetryableCode");function cs(e,r=false){return r||W(e)}o(cs,"shouldRetry");var Ut=500,Ue=8e3,qr=4;function Hr(e,r=Math.random){let n=Math.max(0,e),t=Math.min(Ut*2**n,Ue);return Math.floor(r()*t)}o(Hr,"backoffDelayMs");function fs(e){return e==="conversationNotFound"}o(fs,"canRecreateOnNotFound");var qt=Object.freeze({authExpired:"Please sign in again to continue.",authRejected:"Please sign in again to continue.",sessionRequired:"This app needs to be updated to keep using Everfur.",accessDenied:"This feature isn't available on your account right now.",paymentRequired:"This is part of a paid plan.",quotaExceeded:"You have used today's messages. This resets tomorrow.",rateLimited:"You are sending messages quickly. Try again in a few seconds.",validationFailed:"Something in that request was not right. Check the details and try again.",sdkUpdateRequired:"This app needs to be updated to keep using Everfur.",conflict:"That is already running. Wait for it to finish, then try again.",idempotencyConflict:"That message was already delivered.",idempotencyInFlight:"That is still processing. Give it a moment.",conversationNotFound:"This conversation is no longer available.",petNotFound:"We could not find that pet. Please pick a pet and try again.",resourceNotFound:"We could not find that.",streamTimeout:"The response timed out. Tap retry to try again.",mediaUploadFailed:"We could not upload that photo. Please attach it again.",moderationBlocked:"This request cannot be answered here.",upstreamLlmTimeout:"The response timed out. Tap retry to try again.",internalError:"We hit a snag on our end. Please try again.",notImplemented:"That is not available yet.",serviceUnavailable:"That service is briefly unavailable. Try again shortly.",streamIncomplete:"The connection dropped mid-answer. Tap retry to continue.",unknown:"Something went wrong. Please try again."});function qe(e){return qt[e]}o(qe,"userFacingError");function Kr(e,r,n){Object.defineProperty(e,r,{value:n,enumerable:false,writable:false,configurable:false});}o(Kr,"defineHidden");var Ht=/^[a-z][a-z0-9_]{0,63}$/;function S(e,r){let n=ve(r?.wireCode,r?.wireEnvelope),t={code:e,category:zr(e),retryable:r?.retryable??Ur(e),displayMessage:qe(e)};if(r?.httpStatus!==void 0&&(t.httpStatus=r.httpStatus),r?.requestId&&(t.requestId=r.requestId),typeof r?.reasonCode=="string"&&Ht.test(r.reasonCode)&&(t.reasonCode=r.reasonCode),n);return r?.wireMessage&&Kr(t,"wireMessage",r.wireMessage),r?.raw!==void 0&&r.raw!==null&&Kr(t,"raw",r.raw),Object.freeze(t)}o(S,"makeEverfurError");function x(e,r){return Object.freeze(r===void 0?{ok:true,value:e}:{ok:true,value:e,warning:r})}o(x,"ok");function y(e){return Object.freeze({ok:false,error:e})}o(y,"err");function Es(e){return e.ok}o(Es,"isOk");function vs(e){return !e.ok}o(vs,"isErr");var _e=class _e extends Error{constructor(r){super(`${r.code}: ${r.displayMessage}`),this.name="EverfurThrownError",this.error=r,this.code=r.code,this.category=r.category,Object.setPrototypeOf(this,_e.prototype);}};o(_e,"EverfurThrownError");var He=_e;function _s(e){if(e.ok)return e.value;throw new He(e.error)}o(_s,"unwrap");var Re=class Re extends Error{constructor(r,n){super(n),this.name="EverfurConfigError",this.kind=r,Object.setPrototypeOf(this,Re.prototype);}};o(Re,"EverfurConfigError");var k=Re;var Kt="0.7.0",$t="react-native",Gt="2026-09-19",$r="EVERFUR_API_BASE_URL";function de(e,r){return Object.freeze({ok:false,failure:Object.freeze({reason:e,message:r})})}o(de,"configFailure");function Wt(e){let r=typeof e=="string"?e.trim():"";return r.length===0?{reason:"missing-publishable-key",message:"publishableKey is required"}:/^sk[_-]/i.test(r)?{reason:"secret-key-as-publishable-key",message:"publishableKey looks like a SECRET key (sk_...). A device must never hold a partner secret key: use the pk_ publishable key here, and keep the secret key on your server."}:null}o(Wt,"checkPublishableKey");function Vt(e,r){let n=Wt(e?.publishableKey);if(n!==null)return Object.freeze({ok:false,failure:n});let t=e.publishableKey.trim(),i=Gr(e.apiBaseUrl);if(!i.ok)return i;let a=e.contractVersion?.trim()||Gt;return Object.freeze({ok:true,config:Object.freeze({publishableKey:t,apiBaseUrl:i.value,contractVersion:a,sdkVersion:Kt,platform:r?.platform??$t,debug:e.debug===true})})}o(Vt,"tryResolveClientConfig");function Ts(e,r){let n=Vt(e,r);if(!n.ok)throw new k("invalid-argument",n.failure.message);return n.config}o(Ts,"resolveClientConfig");function Gr(e){let r=e?.trim(),n=r&&r.length>0?r:no($r);return n?eo(n):de("missing-api-base-url",`apiBaseUrl is required: pass config.apiBaseUrl or set ${$r}. The SDK never ships a hardcoded host.`)}o(Gr,"tryResolveApiBaseUrl");function Ss(e){let r=Gr(e);if(!r.ok)throw new k("invalid-argument",r.failure.message);return r.value}o(Ss,"resolveApiBaseUrl");function Wr(e){return {"X-Everfur-SDK-Version":e.sdkVersion,"X-Everfur-SDK-Platform":e.platform,"X-Everfur-Contract":e.contractVersion}}o(Wr,"buildBaseHeaders");var Yt=/^([A-Za-z][A-Za-z0-9+.-]*):\/\/([^/?#]*)/;function Xt(e){return e.slice(e.lastIndexOf("@")+1).replace(/:\d+$/,"").toLowerCase()}o(Xt,"hostOf");function Qt(e){return e.length===0||e.includes("@")?false:e.startsWith("[")&&e.endsWith("]")?true:!e.includes(":")}o(Qt,"isPrintableHost");function Jt(e,r){let n=e.indexOf("://");return n<0||e.slice(n+3).includes("@")?false:Qt(r)}o(Jt,"canEchoOrigin");function Zt(e,r){return `${e}://${r}`}o(Zt,"safeOrigin");function eo(e){let r=e.trim(),n=Yt.exec(r);if(n===null||n[2]===void 0||n[2].length===0)return de("malformed-api-base-url","apiBaseUrl is not a valid absolute URL");let t=(n[1]??"").toLowerCase(),i=Xt(n[2]);if(i.length===0)return de("malformed-api-base-url","apiBaseUrl is not a valid absolute URL");let a=Jt(r,i)?`: ${Zt(t,i)}`:"";if(t!=="https"){if(!(t==="http"&&ro(i)))return t==="http"?de("insecure-api-base-url",`apiBaseUrl must use https (cleartext http is only allowed for localhost)${a}`):de("unsupported-api-base-url-scheme",`apiBaseUrl must be http(s)${a}`)}let s=r.endsWith("/")?r.slice(0,-1):r;return Object.freeze({ok:true,value:s})}o(eo,"normalizeBaseUrl");function ro(e){let r=e.toLowerCase();return r==="localhost"||r==="127.0.0.1"||r==="[::1]"||r==="::1"}o(ro,"isLoopbackHost");function no(e){let n=globalThis.process?.env?.[e];return typeof n=="string"&&n.trim().length>0?n.trim():void 0}o(no,"readEnv");function ie(e){for(let r=0;r<e.length;r+=1){let n=e.charCodeAt(r);if(n>=55296&&n<=56319){let t=e.charCodeAt(r+1);if(!(t>=56320&&t<=57343))return true;r+=1;}else if(n>=56320&&n<=57343)return true}return false}o(ie,"hasLoneSurrogate");function V(e){return [...e].length}o(V,"serverLength");var Vr=128,Yr=128,Xr=/[\u0000-\u001F\u007F]/,to=/^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$/i;function Ps(e){let r=e,n=V(r);if(n===0||n>Yr)throw new k("invalid-argument",`petRef must be 1..${Yr} characters`);if(Xr.test(r))throw new k("invalid-argument","petRef must be printable (no control characters)");return r}o(Ps,"petRef");function Ds(e){let r=e,n=V(r);if(n===0||n>Vr)throw new k("invalid-argument",`userRef must be 1..${Vr} characters`);if(r.includes("@"))throw new k("invalid-argument","userRef must not contain '@'");if(Xr.test(r))throw new k("invalid-argument","userRef must be printable (no control characters)");return r}o(Ds,"userRef");function Ns(e){if(!to.test(e))throw new k("invalid-argument","conversationId must be a UUID");return e}o(Ns,"conversationId");function Ms(e){return e}o(Ms,"unsafePetRef");function Ls(e){return e}o(Ls,"unsafeUserRef");function Bs(e){return e}o(Bs,"unsafeConversationId");function zs(e){return e}o(zs,"unsafeResponseId");function js(e){return e}o(js,"unsafeClientId");function Us(e){return e}o(Us,"unsafeDocumentId");function qs(e){return e}o(qs,"unsafeJobId");function Hs(e){return e}o(Hs,"unsafeRecordsRequestId");function Vs(e,r,n){let t=null,i=null,a=false,s=o(()=>i||(i=(async()=>{try{let l=await r(),u=typeof l=="string"?l:l?.token;if(typeof u!="string"||u.length===0)throw new k("invalid-argument","TokenProvider returned an empty token");return t=u,n?.(typeof l=="string"?null:oo(l.expiresAt)),u}finally{i=null;}})(),i),"load");return {userRef:e,async currentToken(l){if(a)throw new k("not-initialized","This identity was cleared (sign-out); mint a new one.");return l?.forceRefresh&&(t=null),t!==null?t:s()},hasToken(){return !a&&t!==null},clear(){a=true,t=null;}}}o(Vs,"createIdentityProvider");function oo(e){if(e===void 0)return null;let r=typeof e=="number"?e<1e11?e*1e3:e:new Date(e).getTime();return Number.isFinite(r)?r:null}o(oo,"expiryMs");function Ys(){let e=new Uint8Array(16),r=globalThis.crypto;if(typeof r?.getRandomValues=="function")r.getRandomValues(e);else for(let t=0;t<e.length;t+=1)e[t]=Math.floor(Math.random()*256);e[6]=e[6]&15|64,e[8]=e[8]&63|128;let n=[];for(let t=0;t<e.length;t+=1)n.push(e[t].toString(16).padStart(2,"0"));return n.slice(0,4).join("")+"-"+n.slice(4,6).join("")+"-"+n.slice(6,8).join("")+"-"+n.slice(8,10).join("")+"-"+n.slice(10,16).join("")}o(Ys,"newSessionId");function io(e){let r={};return e.mode==="personalized"?r.authorization=`Bearer ${e.token}`:r["x-everfur-partner-key"]=e.publishableKey,e.userRef&&(r["x-everfur-user-ref"]=e.userRef),e.sessionId&&(r["x-everfur-session-id"]=e.sessionId),r}o(io,"authHeaders");function ce(e,r){return {...e,headers:{...ao(e.headers),...io(r)}}}o(ce,"withAuthHeaders");function ao(e){if(!e)return {};let r={};for(let[n,t]of Object.entries(e)){let i=n.toLowerCase();i==="authorization"||i==="x-everfur-partner-key"||(r[n]=t);}return r}o(ao,"stripAuthHeaders");async function Qr(e,r){if(r.mode==="anonymous")return r.transport.request(ce(e,{mode:"anonymous",publishableKey:r.publishableKey,userRef:r.userRef,...r.sessionId?{sessionId:r.sessionId}:{}}));let n;try{n=await r.identity.currentToken();}catch{return y(Ke())}let t=await r.transport.request(ce(e,{mode:"personalized",token:n,userRef:r.userRef,...r.sessionId?{sessionId:r.sessionId}:{}}));if(t.ok||t.error.httpStatus!==401)return t;let i;try{i=await r.identity.currentToken({forceRefresh:!0});}catch{return y(Ke())}let a=await r.transport.request(ce(e,{mode:"personalized",token:i,userRef:r.userRef,...r.sessionId?{sessionId:r.sessionId}:{}}));return !a.ok&&a.error.httpStatus===401?y(Ke(a.error.httpStatus)):a}o(Qr,"authedSend");function Ke(e){return S("authRejected",{retryable:false,...e!==void 0?{httpStatus:e}:{}})}o(Ke,"authRejectedError");function Js(e){throw new Error(`assertNever: unhandled discriminated-union member ${JSON.stringify(e)}`)}o(Js,"assertNever");var so=Object.freeze([]),lo=Object.freeze([]);function Jr(e,r,n=null){return Object.freeze({kind:"accepted",streamId:e,lastEventId:r,serverRequestId:n,terminal:false})}o(Jr,"acceptedFrame");function Zr(e,r=null){return Object.freeze({kind:"heartbeat",lastEventId:e,serverRequestId:r,terminal:false})}o(Zr,"heartbeatFrame");function en(e,r,n=null){return Object.freeze({kind:"delta",delta:e,lastEventId:r,serverRequestId:n,terminal:false})}o(en,"deltaFrame");function rn(e,r=null){return Object.freeze({kind:"done",terminal:true,conversationId:e.conversationId,messageId:e.messageId,title:e.title,followUpQuestions:Object.freeze([...e.followUpQuestions]),citations:Object.freeze([...e.citations]),citationStatus:e.citationStatus,urgencyLevel:e.urgencyLevel,urgencyReason:e.urgencyReason,urgencyProvided:e.urgencyProvided??e.urgencyLevel!==null,resultId:e.resultId,lastEventId:e.lastEventId,serverRequestId:r})}o(rn,"doneFrame");function j(e){return Object.freeze({kind:"error",terminal:true,code:e.code,retryable:e.retryable,wireMessage:e.wireMessage,synthesized:e.synthesized,lastEventId:e.lastEventId,serverRequestId:e.serverRequestId??null})}o(j,"errorFrame");function nn(e,r,n=null){return Object.freeze({kind:"analysisStarted",requestId:e,lastEventId:r,serverRequestId:n,terminal:false})}o(nn,"analysisStartedFrame");function tn(e,r=null){return Object.freeze({kind:"analysisComplete",terminal:false,resultId:e.resultId,analysisType:e.analysisType,modelVersion:e.modelVersion,confidence:e.confidence,detections:Object.freeze([...e.detections]),interpretation:e.interpretation,lastEventId:e.lastEventId,serverRequestId:r})}o(tn,"analysisCompleteFrame");function on(e,r,n=null){return Object.freeze({kind:"unknown",raw:{...e},lastEventId:r,serverRequestId:n,terminal:false})}o(on,"unknownFrame");var Zs=Object.freeze({strings:so,maps:lo});var an=`
1
+ 'use strict';var zod=require('zod');var Pt=Object.defineProperty;var o=(e,r)=>Pt(e,"name",{value:r,configurable:true});var je=Object.freeze([Object.freeze({wireCode:"AccessDeniedException",envelope:"http_envelope",httpStatus:403,retryable:false}),Object.freeze({wireCode:"AuthorizationException",envelope:"http_envelope",httpStatus:401,retryable:false}),Object.freeze({wireCode:"ConflictException",envelope:"http_envelope",httpStatus:409,retryable:true}),Object.freeze({wireCode:"DAILY_QUOTA_EXCEEDED",envelope:"http_envelope",httpStatus:429,retryable:true}),Object.freeze({wireCode:"FILE_TOO_LARGE",envelope:"http_envelope",httpStatus:400,retryable:false}),Object.freeze({wireCode:"IDEMPOTENCY_KEY_IN_FLIGHT",envelope:"http_envelope",httpStatus:409,retryable:true}),Object.freeze({wireCode:"IDEMPOTENCY_KEY_REUSED_DIFFERENT_REQUEST",envelope:"http_envelope",httpStatus:409,retryable:false}),Object.freeze({wireCode:"INVALID_CONTENT_TYPE",envelope:"http_envelope",httpStatus:400,retryable:false}),Object.freeze({wireCode:"InternalFailureException",envelope:"http_envelope",httpStatus:500,retryable:true}),Object.freeze({wireCode:"MethodNotAllowedException",envelope:"http_envelope",httpStatus:405,retryable:false}),Object.freeze({wireCode:"NotImplementedException",envelope:"http_envelope",httpStatus:501,retryable:false}),Object.freeze({wireCode:"PaymentRequiredException",envelope:"http_envelope",httpStatus:402,retryable:false}),Object.freeze({wireCode:"ResourceNotFoundException",envelope:"http_envelope",httpStatus:404,retryable:false}),Object.freeze({wireCode:"ServiceUnavailableException",envelope:"http_envelope",httpStatus:503,retryable:true}),Object.freeze({wireCode:"TIER_UPGRADE_REQUIRED",envelope:"http_envelope",httpStatus:402,retryable:false}),Object.freeze({wireCode:"ThrottlingException",envelope:"http_envelope",httpStatus:429,retryable:true}),Object.freeze({wireCode:"ValidationException",envelope:"http_envelope",httpStatus:400,retryable:false}),Object.freeze({wireCode:"accessDenied",envelope:"http_envelope",httpStatus:403,retryable:false}),Object.freeze({wireCode:"access_denied",envelope:"oauth_error",httpStatus:302,retryable:false}),Object.freeze({wireCode:"attachment_unreadable",envelope:"http_envelope",httpStatus:400,retryable:false}),Object.freeze({wireCode:"authExpired",envelope:"http_envelope",httpStatus:401,retryable:true}),Object.freeze({wireCode:"authRejected",envelope:"http_envelope",httpStatus:401,retryable:false}),Object.freeze({wireCode:"consent_invalid",envelope:"http_envelope",httpStatus:422,retryable:false}),Object.freeze({wireCode:"consent_required",envelope:"http_envelope",httpStatus:422,retryable:false}),Object.freeze({wireCode:"consent_scope_wrong_route",envelope:"http_envelope",httpStatus:400,retryable:false}),Object.freeze({wireCode:"device_cipher_unavailable",envelope:"http_envelope",httpStatus:503,retryable:true}),Object.freeze({wireCode:"email_invalid",envelope:"http_envelope",httpStatus:422,retryable:false}),Object.freeze({wireCode:"event_cursor_invalid",envelope:"http_envelope",httpStatus:400,retryable:false}),Object.freeze({wireCode:"event_filter_invalid",envelope:"http_envelope",httpStatus:400,retryable:false}),Object.freeze({wireCode:"event_payload_invalid",envelope:"http_envelope",httpStatus:400,retryable:false}),Object.freeze({wireCode:"event_type_not_available",envelope:"http_envelope",httpStatus:400,retryable:false}),Object.freeze({wireCode:"event_type_unknown",envelope:"http_envelope",httpStatus:400,retryable:false}),Object.freeze({wireCode:"idempotency_key_invalid",envelope:"http_envelope",httpStatus:400,retryable:false}),Object.freeze({wireCode:"idempotency_key_required",envelope:"http_envelope",httpStatus:400,retryable:false}),Object.freeze({wireCode:"idempotency_key_reused",envelope:"http_envelope",httpStatus:409,retryable:false}),Object.freeze({wireCode:"insufficientCapability",envelope:"http_envelope",httpStatus:403,retryable:false}),Object.freeze({wireCode:"insufficient_scope",envelope:"http_envelope",httpStatus:403,retryable:false}),Object.freeze({wireCode:"internal_error",envelope:"sse_frame",httpStatus:200,retryable:false}),Object.freeze({wireCode:"invalidRequest",envelope:"http_envelope",httpStatus:400,retryable:false}),Object.freeze({wireCode:"invalid_client",envelope:"oauth_error",httpStatus:401,retryable:false}),Object.freeze({wireCode:"invalid_client_metadata",envelope:"oauth_error",httpStatus:400,retryable:false}),Object.freeze({wireCode:"invalid_grant",envelope:"oauth_error",httpStatus:400,retryable:false}),Object.freeze({wireCode:"invalid_redirect_uri",envelope:"oauth_error",httpStatus:400,retryable:false}),Object.freeze({wireCode:"invalid_request",envelope:"oauth_error",httpStatus:400,retryable:false}),Object.freeze({wireCode:"invalid_scope",envelope:"oauth_error",httpStatus:400,retryable:false}),Object.freeze({wireCode:"invalid_target",envelope:"oauth_error",httpStatus:400,retryable:false}),Object.freeze({wireCode:"mcp_connection_not_found",envelope:"http_envelope",httpStatus:404,retryable:false}),Object.freeze({wireCode:"mcp_request_conflict",envelope:"http_envelope",httpStatus:409,retryable:false}),Object.freeze({wireCode:"mcp_request_gone",envelope:"http_envelope",httpStatus:410,retryable:false}),Object.freeze({wireCode:"mcp_request_not_found",envelope:"http_envelope",httpStatus:404,retryable:false}),Object.freeze({wireCode:"not_found",envelope:"sse_frame",httpStatus:200,retryable:false}),Object.freeze({wireCode:"partner_visit_link_conflict",envelope:"http_envelope",httpStatus:409,retryable:false}),Object.freeze({wireCode:"partner_visit_owner_only",envelope:"http_envelope",httpStatus:403,retryable:false}),Object.freeze({wireCode:"partner_visit_pet_already_mapped",envelope:"http_envelope",httpStatus:409,retryable:false}),Object.freeze({wireCode:"payload_too_large",envelope:"http_envelope",httpStatus:413,retryable:false}),Object.freeze({wireCode:"petRefInUse",envelope:"http_envelope",httpStatus:409,retryable:false}),Object.freeze({wireCode:"pet_health_list_removals_unconfirmed",envelope:"http_envelope",httpStatus:422,retryable:false}),Object.freeze({wireCode:"pet_health_species_unsupported",envelope:"http_envelope",httpStatus:422,retryable:false}),Object.freeze({wireCode:"pet_not_registered",envelope:"http_envelope",httpStatus:404,retryable:false}),Object.freeze({wireCode:"provider_unsupported",envelope:"http_envelope",httpStatus:422,retryable:false}),Object.freeze({wireCode:"rateLimited",envelope:"http_envelope",httpStatus:429,retryable:true}),Object.freeze({wireCode:"record_species_unsupported",envelope:"http_envelope",httpStatus:422,retryable:false}),Object.freeze({wireCode:"record_subject_not_found",envelope:"http_envelope",httpStatus:404,retryable:false}),Object.freeze({wireCode:"record_upload_invalid",envelope:"http_envelope",httpStatus:400,retryable:false}),Object.freeze({wireCode:"records_consent_required",envelope:"http_envelope",httpStatus:409,retryable:false}),Object.freeze({wireCode:"sandbox_only",envelope:"http_envelope",httpStatus:403,retryable:false}),Object.freeze({wireCode:"session_required",envelope:"http_envelope",httpStatus:403,retryable:false}),Object.freeze({wireCode:"share_limit_reached",envelope:"http_envelope",httpStatus:429,retryable:false}),Object.freeze({wireCode:"slow_down",envelope:"oauth_error",httpStatus:429,retryable:true}),Object.freeze({wireCode:"species_unsupported",envelope:"http_envelope",httpStatus:422,retryable:false}),Object.freeze({wireCode:"tenant_filter_invalid",envelope:"http_envelope",httpStatus:400,retryable:false}),Object.freeze({wireCode:"tenant_has_no_capabilities",envelope:"http_envelope",httpStatus:409,retryable:false}),Object.freeze({wireCode:"tenant_resource_not_found",envelope:"http_envelope",httpStatus:404,retryable:false}),Object.freeze({wireCode:"tenant_surface_not_enabled",envelope:"http_envelope",httpStatus:409,retryable:false}),Object.freeze({wireCode:"timeout",envelope:"sse_frame",httpStatus:200,retryable:true}),Object.freeze({wireCode:"token_invalid",envelope:"http_envelope",httpStatus:422,retryable:false}),Object.freeze({wireCode:"unavailable",envelope:"sse_frame",httpStatus:200,retryable:true}),Object.freeze({wireCode:"unavailable",envelope:"http_envelope",httpStatus:503,retryable:true}),Object.freeze({wireCode:"unsupported_grant_type",envelope:"oauth_error",httpStatus:400,retryable:false}),Object.freeze({wireCode:"unsupported_response_type",envelope:"oauth_error",httpStatus:302,retryable:false}),Object.freeze({wireCode:"verify_mint_rate_limited",envelope:"http_envelope",httpStatus:429,retryable:true}),Object.freeze({wireCode:"verify_mint_refused",envelope:"http_envelope",httpStatus:403,retryable:false}),Object.freeze({wireCode:"verify_mint_unavailable",envelope:"http_envelope",httpStatus:503,retryable:true}),Object.freeze({wireCode:"verify_user_ref_invalid",envelope:"http_envelope",httpStatus:422,retryable:false}),Object.freeze({wireCode:"webhook_endpoint_update_empty",envelope:"http_envelope",httpStatus:400,retryable:false}),Object.freeze({wireCode:"webhook_endpoint_update_invalid",envelope:"http_envelope",httpStatus:400,retryable:false}),Object.freeze({wireCode:"webhook_url_rejected",envelope:"http_envelope",httpStatus:400,retryable:false})]);Object.freeze(je.map(e=>e.wireCode));var Dt=Object.freeze({ValidationException:"validationFailed",AuthorizationException:"authRejected",PaymentRequiredException:"paymentRequired",AccessDeniedException:"accessDenied",ResourceNotFoundException:"resourceNotFound",ConflictException:"conflict",ThrottlingException:"rateLimited",InternalFailureException:"internalError",NotImplementedException:"notImplemented",ServiceUnavailableException:"serviceUnavailable",MethodNotAllowedException:"validationFailed",authExpired:"authExpired",unavailable:"serviceUnavailable",session_required:"sessionRequired",accessDenied:"accessDenied",invalidRequest:"sdkUpdateRequired",authRejected:"authRejected",rateLimited:"rateLimited",insufficientCapability:"accessDenied",event_cursor_invalid:"validationFailed",event_filter_invalid:"validationFailed",event_payload_invalid:"validationFailed",event_type_unknown:"validationFailed",idempotency_key_invalid:"validationFailed",idempotency_key_required:"validationFailed",idempotency_key_reused:"idempotencyConflict",payload_too_large:"validationFailed",webhook_url_rejected:"validationFailed",webhook_endpoint_update_empty:"validationFailed",webhook_endpoint_update_invalid:"validationFailed",event_type_not_available:"conflict",record_subject_not_found:"resourceNotFound",records_consent_required:"conflict",record_species_unsupported:"validationFailed",record_upload_invalid:"validationFailed",FILE_TOO_LARGE:"validationFailed",INVALID_CONTENT_TYPE:"validationFailed",attachment_unreadable:"validationFailed",provider_unsupported:"validationFailed",token_invalid:"validationFailed",device_cipher_unavailable:"serviceUnavailable",email_invalid:"validationFailed",consent_required:"validationFailed",consent_invalid:"validationFailed",consent_scope_wrong_route:"validationFailed",IDEMPOTENCY_KEY_IN_FLIGHT:"idempotencyInFlight",IDEMPOTENCY_KEY_REUSED_DIFFERENT_REQUEST:"idempotencyConflict",DAILY_QUOTA_EXCEEDED:"quotaExceeded",TIER_UPGRADE_REQUIRED:"paymentRequired",not_found:"conversationNotFound",timeout:"streamTimeout",internal_error:"internalError",invalid_request:"validationFailed",invalid_client:"authRejected",invalid_grant:"authRejected",unsupported_grant_type:"validationFailed",invalid_scope:"validationFailed",invalid_target:"validationFailed",invalid_redirect_uri:"validationFailed",invalid_client_metadata:"validationFailed",unsupported_response_type:"validationFailed",access_denied:"accessDenied",slow_down:"rateLimited",mcp_request_not_found:"resourceNotFound",mcp_request_gone:"resourceNotFound",mcp_connection_not_found:"resourceNotFound",mcp_request_conflict:"conflict",sandbox_only:"accessDenied",tenant_has_no_capabilities:"conflict",verify_mint_refused:"accessDenied",verify_mint_rate_limited:"rateLimited",verify_mint_unavailable:"serviceUnavailable",verify_user_ref_invalid:"validationFailed",insufficient_scope:"accessDenied",tenant_filter_invalid:"validationFailed",tenant_resource_not_found:"resourceNotFound",tenant_surface_not_enabled:"conflict",pet_health_species_unsupported:"validationFailed",pet_health_list_removals_unconfirmed:"validationFailed",petRefInUse:"conflict",share_limit_reached:"conflict",pet_not_registered:"resourceNotFound",species_unsupported:"validationFailed",partner_visit_owner_only:"accessDenied",partner_visit_link_conflict:"conflict",partner_visit_pet_already_mapped:"conflict"}),Lr=Object.freeze(je.map(e=>Object.freeze({wireCode:e.wireCode,envelope:e.envelope,retryable:e.retryable,normalized:Dt[e.wireCode]}))),Nt=new Map(Lr.map(e=>[e.envelope+e.wireCode.toUpperCase(),e])),Mt=Object.freeze(["http_envelope",...[...new Set(Lr.map(e=>e.envelope))].filter(e=>e!=="http_envelope").sort()]);function ve(e,r){if(typeof e!="string")return;let n=e.trim().toUpperCase();if(n.length!==0)for(let t of [r??"http_envelope",...Mt]){let i=Nt.get(t+n);if(i)return i}}o(ve,"contractErrorFor");function Lt(e){return e.envelope==="sse_frame"?`/errors#sse-${e.wireCode}`:e.envelope==="oauth_error"?`/errors#oauth-${e.wireCode}`:`/errors#${e.wireCode}`}o(Lt,"contractDocUrl");var Mr=null;function Br(e){return null}o(Br,"publishedDocUrl");var us=Object.freeze(["authExpired","authRejected","sessionRequired","accessDenied","paymentRequired","quotaExceeded","rateLimited","validationFailed","sdkUpdateRequired","conflict","idempotencyConflict","idempotencyInFlight","conversationNotFound","petNotFound","resourceNotFound","streamTimeout","mediaUploadFailed","moderationBlocked","upstreamLlmTimeout","internalError","notImplemented","serviceUnavailable","streamIncomplete","unknown"]),ds=Object.freeze(["authentication","authorization","entitlement","rateLimit","invalidRequest","notFound","conflict","connection","server","media","policy","unknown"]),Bt=Object.freeze({authExpired:"authentication",authRejected:"authentication",sessionRequired:"authentication",accessDenied:"authorization",paymentRequired:"entitlement",quotaExceeded:"rateLimit",rateLimited:"rateLimit",validationFailed:"invalidRequest",sdkUpdateRequired:"invalidRequest",conversationNotFound:"notFound",petNotFound:"notFound",resourceNotFound:"notFound",conflict:"conflict",idempotencyConflict:"conflict",idempotencyInFlight:"conflict",streamTimeout:"connection",streamIncomplete:"connection",upstreamLlmTimeout:"connection",serviceUnavailable:"connection",internalError:"server",notImplemented:"server",mediaUploadFailed:"media",moderationBlocked:"policy",unknown:"unknown"});function zr(e){return Bt[e]}o(zr,"categoryFor");function oe(e){let r=ve(e);if(r)return r.normalized;let n=(e??"").trim().toUpperCase(),t=n.replace(/[^A-Z0-9]/g,"");if(t==="AUTHREJECTED")return "authRejected";if(n.startsWith("AUTH"))return "authExpired";switch(t){case "DAILYQUOTAEXCEEDED":case "QUOTAEXCEEDED":return "quotaExceeded";case "RATELIMITED":case "TOOMANYREQUESTS":case "TELEVETRATELIMITED":return "rateLimited";case "IDEMPOTENCYKEYCONFLICT":case "IDEMPOTENCYCONFLICT":return "idempotencyConflict";case "ACCESSDENIED":case "FORBIDDEN":return "accessDenied";case "NOTFOUND":case "CONVERSATIONNOTFOUND":return "conversationNotFound";case "PETNOTFOUND":return "petNotFound";case "TIMEOUT":case "STREAMTIMEOUT":return "streamTimeout";case "MEDIAUPLOADFAILED":case "UNRECOGNIZEDVIDEOFORMAT":case "FILETOOSMALL":return "mediaUploadFailed";case "MODERATIONBLOCKED":return "moderationBlocked";case "UPSTREAMLLMTIMEOUT":return "upstreamLlmTimeout";case "INTERNALERROR":case "INTERNALSERVERERROR":return "internalError";case "STREAMINCOMPLETE":case "CHATSTREAMINCOMPLETE":return "streamIncomplete";case "INVALIDANALYSISTYPE":case "INVALIDUPLOADPURPOSE":return "unknown";default:return "unknown"}}o(oe,"fromWire");function jr(e){return e===401?"authExpired":e===403?"accessDenied":e===404?"conversationNotFound":e===409?"idempotencyConflict":e===421?"unknown":e===429?"rateLimited":e===400||e===422?"unknown":e>=500?"internalError":"unknown"}o(jr,"fromHttpStatus");var zt=new Set(["streamTimeout","rateLimited","internalError","upstreamLlmTimeout","streamIncomplete"]);function W(e){return zt.has(e)}o(W,"isAutoRetryable");var jt=new Set(["serviceUnavailable","conflict","idempotencyInFlight"]);function Ur(e){return W(e)||jt.has(e)}o(Ur,"isRetryableCode");function cs(e,r=false){return r||W(e)}o(cs,"shouldRetry");var Ut=500,Ue=8e3,qr=4;function Hr(e,r=Math.random){let n=Math.max(0,e),t=Math.min(Ut*2**n,Ue);return Math.floor(r()*t)}o(Hr,"backoffDelayMs");function fs(e){return e==="conversationNotFound"}o(fs,"canRecreateOnNotFound");var qt=Object.freeze({authExpired:"Please sign in again to continue.",authRejected:"Please sign in again to continue.",sessionRequired:"This app needs to be updated to keep using Everfur.",accessDenied:"This feature isn't available on your account right now.",paymentRequired:"This is part of a paid plan.",quotaExceeded:"You have used today's messages. This resets tomorrow.",rateLimited:"You are sending messages quickly. Try again in a few seconds.",validationFailed:"Something in that request was not right. Check the details and try again.",sdkUpdateRequired:"This app needs to be updated to keep using Everfur.",conflict:"That is already running. Wait for it to finish, then try again.",idempotencyConflict:"That message was already delivered.",idempotencyInFlight:"That is still processing. Give it a moment.",conversationNotFound:"This conversation is no longer available.",petNotFound:"We could not find that pet. Please pick a pet and try again.",resourceNotFound:"We could not find that.",streamTimeout:"The response timed out. Tap retry to try again.",mediaUploadFailed:"We could not upload that photo. Please attach it again.",moderationBlocked:"This request cannot be answered here.",upstreamLlmTimeout:"The response timed out. Tap retry to try again.",internalError:"We hit a snag on our end. Please try again.",notImplemented:"That is not available yet.",serviceUnavailable:"That service is briefly unavailable. Try again shortly.",streamIncomplete:"The connection dropped mid-answer. Tap retry to continue.",unknown:"Something went wrong. Please try again."});function qe(e){return qt[e]}o(qe,"userFacingError");function Kr(e,r,n){Object.defineProperty(e,r,{value:n,enumerable:false,writable:false,configurable:false});}o(Kr,"defineHidden");var Ht=/^[a-z][a-z0-9_]{0,63}$/;function S(e,r){let n=ve(r?.wireCode,r?.wireEnvelope),t={code:e,category:zr(e),retryable:r?.retryable??Ur(e),displayMessage:qe(e)};if(r?.httpStatus!==void 0&&(t.httpStatus=r.httpStatus),r?.requestId&&(t.requestId=r.requestId),typeof r?.reasonCode=="string"&&Ht.test(r.reasonCode)&&(t.reasonCode=r.reasonCode),n);return r?.wireMessage&&Kr(t,"wireMessage",r.wireMessage),r?.raw!==void 0&&r.raw!==null&&Kr(t,"raw",r.raw),Object.freeze(t)}o(S,"makeEverfurError");function x(e,r){return Object.freeze(r===void 0?{ok:true,value:e}:{ok:true,value:e,warning:r})}o(x,"ok");function y(e){return Object.freeze({ok:false,error:e})}o(y,"err");function Es(e){return e.ok}o(Es,"isOk");function vs(e){return !e.ok}o(vs,"isErr");var _e=class _e extends Error{constructor(r){super(`${r.code}: ${r.displayMessage}`),this.name="EverfurThrownError",this.error=r,this.code=r.code,this.category=r.category,Object.setPrototypeOf(this,_e.prototype);}};o(_e,"EverfurThrownError");var He=_e;function _s(e){if(e.ok)return e.value;throw new He(e.error)}o(_s,"unwrap");var Re=class Re extends Error{constructor(r,n){super(n),this.name="EverfurConfigError",this.kind=r,Object.setPrototypeOf(this,Re.prototype);}};o(Re,"EverfurConfigError");var k=Re;var Kt="0.7.1",$t="react-native",Gt="2026-09-19",$r="EVERFUR_API_BASE_URL";function de(e,r){return Object.freeze({ok:false,failure:Object.freeze({reason:e,message:r})})}o(de,"configFailure");function Wt(e){let r=typeof e=="string"?e.trim():"";return r.length===0?{reason:"missing-publishable-key",message:"publishableKey is required"}:/^sk[_-]/i.test(r)?{reason:"secret-key-as-publishable-key",message:"publishableKey looks like a SECRET key (sk_...). A device must never hold a partner secret key: use the pk_ publishable key here, and keep the secret key on your server."}:null}o(Wt,"checkPublishableKey");function Vt(e,r){let n=Wt(e?.publishableKey);if(n!==null)return Object.freeze({ok:false,failure:n});let t=e.publishableKey.trim(),i=Gr(e.apiBaseUrl);if(!i.ok)return i;let a=e.contractVersion?.trim()||Gt;return Object.freeze({ok:true,config:Object.freeze({publishableKey:t,apiBaseUrl:i.value,contractVersion:a,sdkVersion:Kt,platform:r?.platform??$t,debug:e.debug===true})})}o(Vt,"tryResolveClientConfig");function Ts(e,r){let n=Vt(e,r);if(!n.ok)throw new k("invalid-argument",n.failure.message);return n.config}o(Ts,"resolveClientConfig");function Gr(e){let r=e?.trim(),n=r&&r.length>0?r:no($r);return n?eo(n):de("missing-api-base-url",`apiBaseUrl is required: pass config.apiBaseUrl or set ${$r}. The SDK never ships a hardcoded host.`)}o(Gr,"tryResolveApiBaseUrl");function Ss(e){let r=Gr(e);if(!r.ok)throw new k("invalid-argument",r.failure.message);return r.value}o(Ss,"resolveApiBaseUrl");function Wr(e){return {"X-Everfur-SDK-Version":e.sdkVersion,"X-Everfur-SDK-Platform":e.platform,"X-Everfur-Contract":e.contractVersion}}o(Wr,"buildBaseHeaders");var Yt=/^([A-Za-z][A-Za-z0-9+.-]*):\/\/([^/?#]*)/;function Xt(e){return e.slice(e.lastIndexOf("@")+1).replace(/:\d+$/,"").toLowerCase()}o(Xt,"hostOf");function Qt(e){return e.length===0||e.includes("@")?false:e.startsWith("[")&&e.endsWith("]")?true:!e.includes(":")}o(Qt,"isPrintableHost");function Jt(e,r){let n=e.indexOf("://");return n<0||e.slice(n+3).includes("@")?false:Qt(r)}o(Jt,"canEchoOrigin");function Zt(e,r){return `${e}://${r}`}o(Zt,"safeOrigin");function eo(e){let r=e.trim(),n=Yt.exec(r);if(n===null||n[2]===void 0||n[2].length===0)return de("malformed-api-base-url","apiBaseUrl is not a valid absolute URL");let t=(n[1]??"").toLowerCase(),i=Xt(n[2]);if(i.length===0)return de("malformed-api-base-url","apiBaseUrl is not a valid absolute URL");let a=Jt(r,i)?`: ${Zt(t,i)}`:"";if(t!=="https"){if(!(t==="http"&&ro(i)))return t==="http"?de("insecure-api-base-url",`apiBaseUrl must use https (cleartext http is only allowed for localhost)${a}`):de("unsupported-api-base-url-scheme",`apiBaseUrl must be http(s)${a}`)}let s=r.endsWith("/")?r.slice(0,-1):r;return Object.freeze({ok:true,value:s})}o(eo,"normalizeBaseUrl");function ro(e){let r=e.toLowerCase();return r==="localhost"||r==="127.0.0.1"||r==="[::1]"||r==="::1"}o(ro,"isLoopbackHost");function no(e){let n=globalThis.process?.env?.[e];return typeof n=="string"&&n.trim().length>0?n.trim():void 0}o(no,"readEnv");function ie(e){for(let r=0;r<e.length;r+=1){let n=e.charCodeAt(r);if(n>=55296&&n<=56319){let t=e.charCodeAt(r+1);if(!(t>=56320&&t<=57343))return true;r+=1;}else if(n>=56320&&n<=57343)return true}return false}o(ie,"hasLoneSurrogate");function V(e){return [...e].length}o(V,"serverLength");var Vr=128,Yr=128,Xr=/[\u0000-\u001F\u007F]/,to=/^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$/i;function Ps(e){let r=e,n=V(r);if(n===0||n>Yr)throw new k("invalid-argument",`petRef must be 1..${Yr} characters`);if(Xr.test(r))throw new k("invalid-argument","petRef must be printable (no control characters)");return r}o(Ps,"petRef");function Ds(e){let r=e,n=V(r);if(n===0||n>Vr)throw new k("invalid-argument",`userRef must be 1..${Vr} characters`);if(r.includes("@"))throw new k("invalid-argument","userRef must not contain '@'");if(Xr.test(r))throw new k("invalid-argument","userRef must be printable (no control characters)");return r}o(Ds,"userRef");function Ns(e){if(!to.test(e))throw new k("invalid-argument","conversationId must be a UUID");return e}o(Ns,"conversationId");function Ms(e){return e}o(Ms,"unsafePetRef");function Ls(e){return e}o(Ls,"unsafeUserRef");function Bs(e){return e}o(Bs,"unsafeConversationId");function zs(e){return e}o(zs,"unsafeResponseId");function js(e){return e}o(js,"unsafeClientId");function Us(e){return e}o(Us,"unsafeDocumentId");function qs(e){return e}o(qs,"unsafeJobId");function Hs(e){return e}o(Hs,"unsafeRecordsRequestId");function Vs(e,r,n){let t=null,i=null,a=false,s=o(()=>i||(i=(async()=>{try{let l=await r(),u=typeof l=="string"?l:l?.token;if(typeof u!="string"||u.length===0)throw new k("invalid-argument","TokenProvider returned an empty token");return t=u,n?.(typeof l=="string"?null:oo(l.expiresAt)),u}finally{i=null;}})(),i),"load");return {userRef:e,async currentToken(l){if(a)throw new k("not-initialized","This identity was cleared (sign-out); mint a new one.");return l?.forceRefresh&&(t=null),t!==null?t:s()},hasToken(){return !a&&t!==null},clear(){a=true,t=null;}}}o(Vs,"createIdentityProvider");function oo(e){if(e===void 0)return null;let r=typeof e=="number"?e<1e11?e*1e3:e:new Date(e).getTime();return Number.isFinite(r)?r:null}o(oo,"expiryMs");function Ys(){let e=new Uint8Array(16),r=globalThis.crypto;if(typeof r?.getRandomValues=="function")r.getRandomValues(e);else for(let t=0;t<e.length;t+=1)e[t]=Math.floor(Math.random()*256);e[6]=e[6]&15|64,e[8]=e[8]&63|128;let n=[];for(let t=0;t<e.length;t+=1)n.push(e[t].toString(16).padStart(2,"0"));return n.slice(0,4).join("")+"-"+n.slice(4,6).join("")+"-"+n.slice(6,8).join("")+"-"+n.slice(8,10).join("")+"-"+n.slice(10,16).join("")}o(Ys,"newSessionId");function io(e){let r={};return e.mode==="personalized"?r.authorization=`Bearer ${e.token}`:r["x-everfur-partner-key"]=e.publishableKey,e.userRef&&(r["x-everfur-user-ref"]=e.userRef),e.sessionId&&(r["x-everfur-session-id"]=e.sessionId),r}o(io,"authHeaders");function ce(e,r){return {...e,headers:{...ao(e.headers),...io(r)}}}o(ce,"withAuthHeaders");function ao(e){if(!e)return {};let r={};for(let[n,t]of Object.entries(e)){let i=n.toLowerCase();i==="authorization"||i==="x-everfur-partner-key"||(r[n]=t);}return r}o(ao,"stripAuthHeaders");async function Qr(e,r){if(r.mode==="anonymous")return r.transport.request(ce(e,{mode:"anonymous",publishableKey:r.publishableKey,userRef:r.userRef,...r.sessionId?{sessionId:r.sessionId}:{}}));let n;try{n=await r.identity.currentToken();}catch{return y(Ke())}let t=await r.transport.request(ce(e,{mode:"personalized",token:n,userRef:r.userRef,...r.sessionId?{sessionId:r.sessionId}:{}}));if(t.ok||t.error.httpStatus!==401)return t;let i;try{i=await r.identity.currentToken({forceRefresh:!0});}catch{return y(Ke())}let a=await r.transport.request(ce(e,{mode:"personalized",token:i,userRef:r.userRef,...r.sessionId?{sessionId:r.sessionId}:{}}));return !a.ok&&a.error.httpStatus===401?y(Ke(a.error.httpStatus)):a}o(Qr,"authedSend");function Ke(e){return S("authRejected",{retryable:false,...e!==void 0?{httpStatus:e}:{}})}o(Ke,"authRejectedError");function Js(e){throw new Error(`assertNever: unhandled discriminated-union member ${JSON.stringify(e)}`)}o(Js,"assertNever");var so=Object.freeze([]),lo=Object.freeze([]);function Jr(e,r,n=null){return Object.freeze({kind:"accepted",streamId:e,lastEventId:r,serverRequestId:n,terminal:false})}o(Jr,"acceptedFrame");function Zr(e,r=null){return Object.freeze({kind:"heartbeat",lastEventId:e,serverRequestId:r,terminal:false})}o(Zr,"heartbeatFrame");function en(e,r,n=null){return Object.freeze({kind:"delta",delta:e,lastEventId:r,serverRequestId:n,terminal:false})}o(en,"deltaFrame");function rn(e,r=null){return Object.freeze({kind:"done",terminal:true,conversationId:e.conversationId,messageId:e.messageId,title:e.title,followUpQuestions:Object.freeze([...e.followUpQuestions]),citations:Object.freeze([...e.citations]),citationStatus:e.citationStatus,urgencyLevel:e.urgencyLevel,urgencyReason:e.urgencyReason,urgencyProvided:e.urgencyProvided??e.urgencyLevel!==null,resultId:e.resultId,lastEventId:e.lastEventId,serverRequestId:r})}o(rn,"doneFrame");function j(e){return Object.freeze({kind:"error",terminal:true,code:e.code,retryable:e.retryable,wireMessage:e.wireMessage,synthesized:e.synthesized,lastEventId:e.lastEventId,serverRequestId:e.serverRequestId??null})}o(j,"errorFrame");function nn(e,r,n=null){return Object.freeze({kind:"analysisStarted",requestId:e,lastEventId:r,serverRequestId:n,terminal:false})}o(nn,"analysisStartedFrame");function tn(e,r=null){return Object.freeze({kind:"analysisComplete",terminal:false,resultId:e.resultId,analysisType:e.analysisType,modelVersion:e.modelVersion,confidence:e.confidence,detections:Object.freeze([...e.detections]),interpretation:e.interpretation,lastEventId:e.lastEventId,serverRequestId:r})}o(tn,"analysisCompleteFrame");function on(e,r,n=null){return Object.freeze({kind:"unknown",raw:{...e},lastEventId:r,serverRequestId:n,terminal:false})}o(on,"unknownFrame");var Zs=Object.freeze({strings:so,maps:lo});var an=`
2
2
 
3
3
  `,uo=1048576,co=zod.z.record(zod.z.string(),zod.z.unknown()),fo=["emergency","schedule_soon","home_care"];async function*Ce(e,r=null){let n=null,t=o(()=>(n!==null||(n=typeof r=="function"?r():r),n),"requestIdNow"),i=new TextDecoder("utf-8"),a="",s=0,l=false;for await(let u of e){for(a+=i.decode(u,{stream:true});;){let d=a.indexOf(an,s);if(d===-1)break;let f=a.slice(0,d);a=a.slice(d+an.length),s=0;let c=sn(f,t());if(c!==null&&(c.kind==="delta"&&(l=true),yield c,c.terminal))return}if(s=a.length>0?a.length-1:0,a.length>uo){yield j({code:l?"CHAT_STREAM_INCOMPLETE":"internal_error",retryable:true,wireMessage:null,synthesized:true,lastEventId:null,serverRequestId:t()});return}}if(a+=i.decode(),a.trim().length>0){let u=sn(a,t());if(u!==null&&(u.kind==="delta"&&(l=true),yield u,u.terminal))return}yield j({code:l?"CHAT_STREAM_INCOMPLETE":"internal_error",retryable:true,wireMessage:null,synthesized:true,lastEventId:null,serverRequestId:t()});}o(Ce,"parseSse");function sn(e,r){let n=null,t=[];for(let s of e.split(`
4
4
  `)){let l=s.replace(/\s+$/,"");l.length===0||l.startsWith(":")||(l.startsWith("id:")?n=l.slice(3).trim():l.startsWith("data:")&&t.push(l.slice(5).replace(/^ /,"")));}if(t.length===0)return null;let i;try{i=JSON.parse(t.join(`
@@ -1,18 +1,18 @@
1
1
  import { b as EverfurErrorCode } from '../EverfurError-DmELDpXp.cjs';
2
2
  export { A as AUTO_RETRYABLE_CODES, B as BACKOFF_BASE_MS, d as BACKOFF_CAP_MS, e as EVERFUR_ERROR_CATEGORIES, f as EVERFUR_ERROR_CODES, E as EverfurError, a as EverfurErrorCategory, M as MAX_RETRY_ATTEMPTS, g as MakeEverfurErrorOptions, R as RETRYABLE_CONTRACT_CODES, h as backoffDelayMs, j as canRecreateOnNotFound, c as categoryFor, k as fromHttpStatus, l as fromWire, m as isAutoRetryable, i as isRetryableCode, n as makeEverfurError, s as shouldRetry, u as userFacingError } from '../EverfurError-DmELDpXp.cjs';
3
3
  export { a as EverfurConfigError, E as EverfurResult, b as EverfurThrownError, e as err, i as isErr, c as isOk, o as ok, u as unwrap } from '../EverfurResult-ZtH-YV1h.cjs';
4
- export { A as AcceptedFrame, a as AnalysisCompleteFrame, b as AnalysisStartedFrame, B as ByteSource, C as ClientConfigFailure, k as ClientConfigFailureReason, l as ClientConfigOutcome, m as DEFAULT_CONTRACT_VERSION, D as DeltaFrame, c as DoneFrame, n as EMPTY_FRAME_ARRAYS, o as ENV_API_BASE_URL, E as ErrorFrame, p as EventSourceFactory, q as EventSourceInit, r as EventSourceLike, s as EventSourceMessage, t as EverfurConfig, d as EverfurRequest, e as EverfurRequestBase, u as FetchInit, j as FetchLike, v as FetchResponseLike, F as Frame, f as FrameBase, g as FrameKind, H as HeartbeatFrame, h as HttpMethod, M as MultipartBody, R as RawResponse, w as ReadableStreamLike, x as ResolveClientConfigOptions, y as ResolvedClientConfig, S as SDK_PLATFORM, z as SDK_VERSION, G as SdkPlatform, I as ServerRequestIdSource, J as TransportDeps, T as TransportPort, U as UnknownFrame, i as UrgencyLevel, K as acceptedFrame, L as analysisCompleteFrame, N as analysisStartedFrame, O as assertNever, P as bufferedTextByteSource, Q as buildBaseHeaders, V as checkPublishableKey, W as createHttpTransport, X as deltaFrame, Y as doneFrame, Z as errorFrame, _ as errorFromResponse, $ as eventSourceByteSource, a0 as eventSourceRequestId, a1 as fetchByteSource, a2 as getGlobalFetch, a3 as heartbeatFrame, a4 as networkError, a5 as parseSse, a6 as requestIdOf, a7 as requestJson, a8 as requestRaw, a9 as resolveApiBaseUrl, aa as resolveClientConfig, ab as tryResolveApiBaseUrl, ac as tryResolveClientConfig, ad as unknownFrame } from '../config-h5h6TsHL.cjs';
4
+ export { A as AcceptedFrame, a as AnalysisCompleteFrame, b as AnalysisStartedFrame, B as ByteSource, C as ClientConfigFailure, k as ClientConfigFailureReason, l as ClientConfigOutcome, m as DEFAULT_CONTRACT_VERSION, D as DeltaFrame, c as DoneFrame, n as EMPTY_FRAME_ARRAYS, o as ENV_API_BASE_URL, E as ErrorFrame, p as EventSourceFactory, q as EventSourceInit, r as EventSourceLike, s as EventSourceMessage, t as EverfurConfig, d as EverfurRequest, e as EverfurRequestBase, u as FetchInit, j as FetchLike, v as FetchResponseLike, F as Frame, f as FrameBase, g as FrameKind, H as HeartbeatFrame, h as HttpMethod, M as MultipartBody, R as RawResponse, w as ReadableStreamLike, x as ResolveClientConfigOptions, y as ResolvedClientConfig, S as SDK_PLATFORM, z as SDK_VERSION, G as SdkPlatform, I as ServerRequestIdSource, J as TransportDeps, T as TransportPort, U as UnknownFrame, i as UrgencyLevel, K as acceptedFrame, L as analysisCompleteFrame, N as analysisStartedFrame, O as assertNever, P as bufferedTextByteSource, Q as buildBaseHeaders, V as checkPublishableKey, W as createHttpTransport, X as deltaFrame, Y as doneFrame, Z as errorFrame, _ as errorFromResponse, $ as eventSourceByteSource, a0 as eventSourceRequestId, a1 as fetchByteSource, a2 as getGlobalFetch, a3 as heartbeatFrame, a4 as networkError, a5 as parseSse, a6 as requestIdOf, a7 as requestJson, a8 as requestRaw, a9 as resolveApiBaseUrl, aa as resolveClientConfig, ab as tryResolveApiBaseUrl, ac as tryResolveClientConfig, ad as unknownFrame } from '../config-Daa1plhQ.cjs';
5
5
  export { B as Brand, a as ClientId, C as ConversationId, D as DocumentId, J as JobId, P as PetRef, R as RecordsRequestId, b as ResponseId, U as UserRef, _ as __brand, c as conversationId, p as petRef, d as unsafeClientId, e as unsafeConversationId, f as unsafeDocumentId, g as unsafeJobId, h as unsafePetRef, i as unsafeRecordsRequestId, j as unsafeResponseId, k as unsafeUserRef, u as userRef } from '../ids-B2GAAifq.cjs';
6
- export { A as AuthContext, D as DeviceAuth, I as IdentityProvider, M as MintedToken, T as TokenProvider, a as authHeaders, b as authedSend, c as createIdentityProvider, n as newSessionId, w as withAuthHeaders } from '../identity-b5Vp32Vp.cjs';
6
+ export { A as AuthContext, D as DeviceAuth, I as IdentityProvider, M as MintedToken, T as TokenProvider, a as authHeaders, b as authedSend, c as createIdentityProvider, n as newSessionId, w as withAuthHeaders } from '../identity-DUlshgow.cjs';
7
7
  export { a as CapabilityDecision, b as CapabilityDisabled, C as CapabilityName, c as DecideOptions, D as DisabledLevel, E as EntitlementDecision, L as LevelGrant, R as ResolvedEntitlements, d as decideCapability, e as deniedDecisionsFor, r as requires, f as resolveEntitlements } from '../resolve-D4Ywz5OS.cjs';
8
- export { E as ENTITLEMENTS_PATH, a as EntitlementResolution, F as FetchEntitlementsArgs, f as fetchEntitlements } from '../entitlementRepository-BYtVb1oU.cjs';
8
+ export { E as ENTITLEMENTS_PATH, a as EntitlementResolution, F as FetchEntitlementsArgs, f as fetchEntitlements } from '../entitlementRepository-DPvWjV-N.cjs';
9
9
  import { E as EverfurTheme } from '../tokens-BYtbKwFh.cjs';
10
10
  export { D as DEFAULT_MAX_FONT_SCALE, v as EASING_CURVES, w as EVERFUR_DARK, x as EVERFUR_LIGHT, c as EverfurColorTokens, y as EverfurEasingCurve, b as EverfurFontFaceKey, d as EverfurFontFamilies, a as EverfurFontWeight, e as EverfurLetterSpacingTokens, f as EverfurLineHeightTokens, g as EverfurMotionDurationTokens, h as EverfurMotionTokens, i as EverfurRadiusTokens, j as EverfurSpaceTokens, k as EverfurSpringToken, l as EverfurTextColorTokens, z as EverfurTextScaleTier, m as EverfurThemeMeta, n as EverfurThemeSlot, o as EverfurThemeSlotKey, p as EverfurThemeSlotName, q as EverfurThemeSlots, r as EverfurTypeSizeTokens, s as EverfurTypeTokens, t as EverfurWeightTokens, S as SLOT_MIN_BORDER_CONTRAST, A as SLOT_MIN_CONTRAST, B as SYSTEM_FONT_FAMILY, C as SYSTEM_MONO_FAMILY, F as SlotGrounds, G as TEXT_SCALE_TIER_CAPS, T as THEME_SLOT_KEYS, u as THEME_SLOT_NAMES, H as cssCubicBezier, I as deepFreeze, J as guardSlotContrast, K as mergeThemeSlots, L as parseThemeSlots } from '../tokens-BYtbKwFh.cjs';
11
11
  export { E as EverfurFaceStyle, R as ResolveThemeInput, T as TEXT_SCALE_FLOOR, f as face, p as previewTheme, r as resolveTheme, w as withServerBranding } from '../typeStyle-BqfwxZH4.cjs';
12
12
  export { A as APPEARANCE_PRESETS, a as APPEARANCE_PRESET_NAMES, b as APPEARANCE_SIZE_RANGES, C as ClientBranding, c as EverfurAppearance, d as EverfurAppearancePreset, e as EverfurAppearanceRules, f as EverfurAppearanceVariables, g as EverfurThemeFontFaceKey, h as EverfurThemeFontUrlsInput, i as EverfurThemeFontsInput, E as EverfurThemeInput, j as EverfurThemeSlotInput, k as EverfurThemeSlotsInput, L as LOCKABLE_THEME_FIELDS, m as LockableThemeField, M as MAX_FONT_SCALE_CEILING, R as RadiusScale, n as SLOT_LOCK_PREFIX, o as SlotLockName, S as SurfaceStyle, T as THEME_SCHEMA_VERSIONS, p as ThemeLockName, l as expandAppearance, q as hardenHttpsUrl, r as isEmptyBranding, s as isKnownBrandingSchema, t as lockedFieldsOf, u as parseClientBranding, v as parsePx } from '../branding-Bio5MM6g.cjs';
13
- export { F as FunnelSendOptions, R as RequestFunnel, a as RequestFunnelDeps, c as createRequestFunnel } from '../requestFunnel-C_cZXhIA.cjs';
14
- export { c as PET_AGE_YEARS_MAX, d as PET_BREED_MAX, e as PET_NAME_MAX, f as PET_SPECIES_MAX, g as PET_WEIGHT_KG_MAX, P as PetProfileInput, a as PetProfilePatch, h as PetsRepository, R as RegisteredPet, W as WidgetPet, i as createPetsRepository, w as widgetPetFromWire } from '../petsRepository-BJsJ4cju.cjs';
15
- export { b as CHECKIN_ANSWERS, c as CasesRepository, C as CheckinAnswer, a as CheckinOutcome, W as WatchCase, d as createCasesRepository } from '../casesRepository-CJchNp3x.cjs';
13
+ export { F as FunnelSendOptions, R as RequestFunnel, a as RequestFunnelDeps, c as createRequestFunnel } from '../requestFunnel-DMR_1T3O.cjs';
14
+ export { c as PET_AGE_YEARS_MAX, d as PET_BREED_MAX, e as PET_NAME_MAX, f as PET_SPECIES_MAX, g as PET_WEIGHT_KG_MAX, P as PetProfileInput, a as PetProfilePatch, h as PetsRepository, R as RegisteredPet, W as WidgetPet, i as createPetsRepository, w as widgetPetFromWire } from '../petsRepository-BnVre3q7.cjs';
15
+ export { b as CHECKIN_ANSWERS, c as CasesRepository, C as CheckinAnswer, a as CheckinOutcome, W as WatchCase, d as createCasesRepository } from '../casesRepository-B-md8h1S.cjs';
16
16
  import '../ErrorPolicyPort-D6CybiqJ.cjs';
17
17
  import '../profile-CSs1wlXT.cjs';
18
18