posthog-node 6.2.0 → 6.2.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (49) hide show
  1. package/dist/client.d.ts +252 -125
  2. package/dist/client.d.ts.map +1 -1
  3. package/dist/client.js +35 -6
  4. package/dist/client.mjs +35 -6
  5. package/dist/entrypoints/otel.d.ts +20 -0
  6. package/dist/entrypoints/otel.d.ts.map +1 -1
  7. package/dist/exports.d.ts +2 -1
  8. package/dist/exports.d.ts.map +1 -1
  9. package/dist/extensions/context/listeners.d.ts +3 -2
  10. package/dist/extensions/context/listeners.d.ts.map +1 -1
  11. package/dist/extensions/context/types.d.ts +2 -0
  12. package/dist/extensions/context/types.d.ts.map +1 -1
  13. package/dist/extensions/express.d.ts +30 -4
  14. package/dist/extensions/express.d.ts.map +1 -1
  15. package/dist/extensions/feature-flags/feature-flags-v2.d.ts +254 -0
  16. package/dist/extensions/feature-flags/feature-flags-v2.d.ts.map +1 -0
  17. package/dist/extensions/feature-flags/feature-flags-v2.js +1408 -0
  18. package/dist/extensions/feature-flags/feature-flags-v2.mjs +1331 -0
  19. package/dist/extensions/feature-flags/feature-flags.d.ts +15 -4
  20. package/dist/extensions/feature-flags/feature-flags.d.ts.map +1 -1
  21. package/dist/extensions/feature-flags/feature-flags.js +55 -7
  22. package/dist/extensions/feature-flags/feature-flags.mjs +55 -7
  23. package/dist/extensions/nestjs.d.ts +23 -0
  24. package/dist/extensions/nestjs.d.ts.map +1 -1
  25. package/dist/feature-flag-evaluations.d.ts +8 -6
  26. package/dist/feature-flag-evaluations.d.ts.map +1 -1
  27. package/dist/flag-events.d.ts +2 -2
  28. package/dist/flag-events.d.ts.map +1 -1
  29. package/dist/flag-events.js +2 -1
  30. package/dist/flag-events.mjs +2 -1
  31. package/dist/types.d.ts +120 -95
  32. package/dist/types.d.ts.map +1 -1
  33. package/dist/version.d.ts +1 -1
  34. package/dist/version.js +1 -1
  35. package/dist/version.mjs +1 -1
  36. package/package.json +4 -4
  37. package/src/client.ts +293 -136
  38. package/src/entrypoints/otel.ts +20 -0
  39. package/src/exports.ts +2 -1
  40. package/src/extensions/context/listeners.ts +3 -2
  41. package/src/extensions/context/types.ts +2 -0
  42. package/src/extensions/express.ts +30 -4
  43. package/src/extensions/feature-flags/feature-flags-v2.ts +2086 -0
  44. package/src/extensions/feature-flags/feature-flags.ts +110 -20
  45. package/src/extensions/nestjs.ts +23 -0
  46. package/src/feature-flag-evaluations.ts +8 -6
  47. package/src/flag-events.ts +3 -2
  48. package/src/types.ts +125 -104
  49. package/src/version.ts +1 -1
@@ -0,0 +1,254 @@
1
+ import type { FeatureFlagDetail, FeatureFlagValue, JsonType, UnresolvedFlagReason } from '@posthog/core';
2
+ import type { FlagRecordValue, ParsedFlagRecord } from '../../flags-response';
3
+ import type { PostHogFeatureFlag } from '../../types';
4
+ /**
5
+ * The flag has a result. `value` is the typed flag value, or `null` when the flag has no value and
6
+ * the caller's default applies. An object value is the configuration's own object, so it must not
7
+ * be changed. The rule fields name the rule that ended the evaluation, and are absent when no rule
8
+ * did. They are the fields a `/flags?v=4` record carries in `reason` and `metadata`.
9
+ */
10
+ export type ConfigV2Evaluated = {
11
+ readonly outcome: 'evaluated';
12
+ readonly value: FlagRecordValue;
13
+ readonly reason: string;
14
+ readonly ruleId?: string;
15
+ readonly ruleType?: string;
16
+ readonly ruleIndex?: number;
17
+ readonly variantKey?: string;
18
+ };
19
+ /** A rule that evaluation reached could not be decided. */
20
+ export type ConfigV2Inconclusive = {
21
+ readonly outcome: 'inconclusive';
22
+ readonly reason: UnresolvedFlagReason;
23
+ readonly detail: string;
24
+ };
25
+ /**
26
+ * The parser rejected the document. `kind` is `malformed` for a document that breaks the
27
+ * configuration format, and `unsupported` for a format this evaluator does not read. `field` names
28
+ * what was rejected.
29
+ */
30
+ export type ConfigV2Unsupported = {
31
+ readonly outcome: 'unsupported';
32
+ readonly kind: 'malformed' | 'unsupported';
33
+ readonly field: string;
34
+ };
35
+ /** Evaluation reached an invalid value. */
36
+ export type ConfigV2EvaluationError = {
37
+ readonly outcome: 'error';
38
+ readonly kind: 'invalid_property' | 'invalid_regex';
39
+ readonly detail: string;
40
+ };
41
+ export type ConfigV2Outcome = ConfigV2Evaluated | ConfigV2Inconclusive | ConfigV2Unsupported | ConfigV2EvaluationError;
42
+ type Operand = number | VersionKey | Requirement | DateValue | null;
43
+ /**
44
+ * One property filter of a rule. `value` is the filter value as stored. `operand` is what a
45
+ * number, semver or date operator compares with, read from `value` once by the parser.
46
+ */
47
+ type Predicate = {
48
+ readonly key: string;
49
+ readonly operator: string;
50
+ readonly value: unknown;
51
+ readonly negation: boolean;
52
+ readonly operand: Operand;
53
+ };
54
+ type Rollout = {
55
+ readonly percentage: number;
56
+ readonly returnDefaultOnMiss: boolean;
57
+ readonly seed: string;
58
+ };
59
+ type Variant = {
60
+ readonly key: string;
61
+ readonly weight: number;
62
+ readonly value: FlagRecordValue;
63
+ };
64
+ type Holdout = {
65
+ readonly seed: string;
66
+ readonly exclusionPercentage: number;
67
+ };
68
+ type Rule = {
69
+ readonly ruleType: 'targeted_release';
70
+ readonly id: string;
71
+ readonly targeting: readonly Predicate[];
72
+ readonly value: FlagRecordValue;
73
+ } | {
74
+ readonly ruleType: 'percentage_rollout';
75
+ readonly id: string;
76
+ readonly targeting: readonly Predicate[];
77
+ readonly value: FlagRecordValue;
78
+ readonly rollout: Rollout;
79
+ } | {
80
+ readonly ruleType: 'experiment';
81
+ readonly id: string;
82
+ readonly targeting: readonly Predicate[];
83
+ readonly paused: boolean;
84
+ readonly rollout: Rollout;
85
+ readonly variants: readonly Variant[];
86
+ readonly holdout: Holdout | undefined;
87
+ };
88
+ /**
89
+ * A parsed `filters` document. `defaultValue` is `null` for a null default. `comparesDates` says
90
+ * whether a rule has a date filter, so that evaluating the document can need the current time.
91
+ */
92
+ export type ConfigV2 = {
93
+ readonly defaultValue: FlagRecordValue;
94
+ readonly rules: readonly Rule[];
95
+ readonly comparesDates: boolean;
96
+ };
97
+ /**
98
+ * What a flag is evaluated for.
99
+ *
100
+ * - `identifier`: the person's resolved targeting key, as a string.
101
+ * - `properties`: the person properties, or `null` when there are none to read. A key whose value
102
+ * is `undefined`, a function or a symbol is absent, as it is from the JSON a remote request
103
+ * sends.
104
+ * - `propertiesComplete`: whether `properties` holds every property of the person. A complete map
105
+ * shows that a property is absent. A partial map does not, so a filter on a key it lacks is
106
+ * inconclusive.
107
+ * - `explicitExactMatching`: the project's setting for the `exact` and `is_not` operators. When
108
+ * false, a filter value that looks like a boolean matches by truthiness.
109
+ * - `timeZone`: the project's timezone, as an IANA name. Dates without a UTC offset and relative
110
+ * dates are read in it. Absent, a filter that needs it is inconclusive.
111
+ * - `now`: the time relative dates count back from. Absent, the current time, read once per
112
+ * evaluation.
113
+ */
114
+ export type ConfigV2Context = {
115
+ readonly identifier: string;
116
+ readonly properties: Readonly<Record<string, unknown>> | null;
117
+ readonly propertiesComplete: boolean;
118
+ readonly explicitExactMatching: boolean;
119
+ readonly timeZone?: string;
120
+ readonly now?: Date;
121
+ };
122
+ /** Draws the hash of one use: `rollout`, `variant` or `holdout`. */
123
+ export type ConfigV2Draw = (use: HashUse, seed: string, subject: string) => number | Promise<number>;
124
+ export type HashUse = 'rollout' | 'variant' | 'holdout';
125
+ /**
126
+ * Reads the `filters` document of a flag as config version 2.
127
+ *
128
+ * The document is the decoded JSON. Three things the reference rejects in the JSON text cannot be
129
+ * seen here: a repeated object key, a nonzero number that rounds to zero, and a percentage written
130
+ * with more than two decimals that rounds to a two-decimal value. The parser never changes the
131
+ * document.
132
+ */
133
+ export declare function parseConfigV2(filters: unknown): ConfigV2 | ConfigV2Unsupported;
134
+ /** Whether a parse result is a rejected document. */
135
+ export declare function isConfigV2Unsupported(config: ConfigV2 | ConfigV2Unsupported): config is ConfigV2Unsupported;
136
+ /**
137
+ * Evaluates a parsed flag for one person. `active` is the flag's own `active` field. An inactive
138
+ * flag has no value, with the reason `flag_disabled`, whatever its document holds.
139
+ */
140
+ export declare function evaluateConfigV2(config: ConfigV2 | ConfigV2Unsupported, context: ConfigV2Context, options?: {
141
+ active?: boolean;
142
+ }): Promise<ConfigV2Outcome>;
143
+ /**
144
+ * Test seam: `draw(use, seed, subject)` replaces every hash an evaluation draws.
145
+ *
146
+ * @internal
147
+ */
148
+ export declare function evaluateConfigV2WithHash(config: ConfigV2 | ConfigV2Unsupported, context: ConfigV2Context, draw: ConfigV2Draw, { active }?: {
149
+ active?: boolean;
150
+ }): Promise<ConfigV2Outcome>;
151
+ /** The `sha1_60_v1` hash: the first 60 bits of a SHA-1 digest, scaled to 0..1. */
152
+ export declare function hash01(prefix: string, identifier: string, salt: string): Promise<number>;
153
+ /** 100 percent includes without hashing. Below it, the comparison is inclusive. */
154
+ export declare function inRollout(percentage: number, draw: () => number | Promise<number>): Promise<boolean>;
155
+ /** Boundaries add left to right. Past the last one, the last variant wins. */
156
+ export declare function selectVariant<T extends {
157
+ readonly weight: number;
158
+ }>(hash: number, variants: readonly T[]): T;
159
+ /** Cuts an identifier to its first 200 Unicode scalar values, as the flags service does. */
160
+ export declare function truncateIdentifier(identifier: string): string;
161
+ /**
162
+ * A value the call passed, as the JSON text the flags service compares. A value JSON cannot carry
163
+ * exactly is a missing context.
164
+ *
165
+ * A string is its own text. Objects list their keys in code point order. A number is sent to the
166
+ * flags service as JSON, which writes an integral number as an integer.
167
+ */
168
+ export declare function jsonText(value: unknown): string;
169
+ type SortKey = readonly (number | bigint | string | SortKey)[];
170
+ type VersionKey = {
171
+ readonly kind: 'version';
172
+ readonly key: SortKey;
173
+ };
174
+ /** A version range. `minor` and `patch` are `null` where any number matches. */
175
+ type Requirement = {
176
+ readonly kind: 'tilde' | 'caret' | 'wildcard';
177
+ readonly major: bigint;
178
+ readonly minor: bigint | null;
179
+ readonly patch: bigint | null;
180
+ readonly pre: string;
181
+ };
182
+ /** A wall clock without a timezone, with whole seconds. Months count from 1. */
183
+ type WallClock = {
184
+ readonly year: number;
185
+ readonly month: number;
186
+ readonly day: number;
187
+ readonly hour: number;
188
+ readonly minute: number;
189
+ readonly second: number;
190
+ };
191
+ /** A date such as `-7d`: seven days before now. The sign changes nothing. */
192
+ type RelativeDate = {
193
+ readonly kind: 'relative';
194
+ readonly number: number;
195
+ readonly interval: string;
196
+ };
197
+ type AbsoluteDate = {
198
+ readonly kind: 'absolute';
199
+ readonly wallClock: WallClock;
200
+ readonly nanoseconds: number;
201
+ /** Seconds east of UTC; `null` means the project's timezone. */
202
+ readonly offset: number | null;
203
+ };
204
+ type DateValue = RelativeDate | AbsoluteDate;
205
+ /**
206
+ * Whether a flag definition is config version 1, the format the version 1 evaluator reads. It is
207
+ * when `filters.version` is absent or the number 1. Any other value, also one that is not a number,
208
+ * belongs to the config version 2 evaluator, which accepts only version 2.
209
+ */
210
+ export declare function isConfigVersion1(flag: unknown): boolean;
211
+ /** A loaded definition and its `filters`, parsed once when definitions load. */
212
+ export type ParsedConfigV2Definition = {
213
+ readonly definition: PostHogFeatureFlag;
214
+ readonly config: ConfigV2 | ConfigV2Unsupported;
215
+ };
216
+ /** The result of a config version 2 definition: the record a `/flags?v=4` response gives. */
217
+ export type ConfigV2LocalResult = {
218
+ /** The legacy rendering of the record, which the existing getters read. */
219
+ readonly detail: FeatureFlagDetail;
220
+ readonly record: ParsedFlagRecord;
221
+ /** The value the legacy getters return: the variant, or whether the flag is enabled. */
222
+ readonly value: FeatureFlagValue;
223
+ /** The decoded payload of a number or object value, or `null`. */
224
+ readonly payload: JsonType | null;
225
+ };
226
+ /** Parses each config version 2 definition of a definitions list, by flag key. */
227
+ export declare function parseConfigV2Definitions(flags: readonly PostHogFeatureFlag[]): ReadonlyMap<string, ParsedConfigV2Definition>;
228
+ /** The reason the definition alone leaves the flag unresolved, known on load. */
229
+ export declare function configV2UnresolvedReason(flag: PostHogFeatureFlag, parsed: ReadonlyMap<string, ParsedConfigV2Definition>): UnresolvedFlagReason | undefined;
230
+ /**
231
+ * Whether a config version 2 flag returns a number or an object, the only values with a payload:
232
+ * the value itself, which the legacy getters render as `true`.
233
+ */
234
+ export declare function configV2HasPayloads(flag: PostHogFeatureFlag): boolean;
235
+ /**
236
+ * Evaluates a config version 2 definition for one person.
237
+ *
238
+ * Returns the record a `/flags?v=4` response gives for the same result, so the client reads it and
239
+ * sends its flag events as for a remote record. Throws `InconclusiveMatchError` with the
240
+ * unresolved reason when the evaluator gives no value; the caller then falls back as for a
241
+ * version 1 flag. A definition of another config version is unsupported, also when the flag is
242
+ * inactive.
243
+ *
244
+ * The flags service evaluates these flags with the distinct ID only, so experience continuity and
245
+ * device bucketing do not apply. The caller never knows that its properties are complete, and
246
+ * dates without an offset are read in UTC, as version 1 local evaluation reads them.
247
+ */
248
+ export declare function evaluateConfigV2Definition(flag: PostHogFeatureFlag, parsed: ReadonlyMap<string, ParsedConfigV2Definition>, context: {
249
+ distinctId: string;
250
+ properties: Record<string, unknown>;
251
+ propertyMatchingVersion: number | undefined;
252
+ }): Promise<ConfigV2LocalResult>;
253
+ export {};
254
+ //# sourceMappingURL=feature-flags-v2.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"feature-flags-v2.d.ts","sourceRoot":"","sources":["../../../src/extensions/feature-flags/feature-flags-v2.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,iBAAiB,EAAE,gBAAgB,EAAE,QAAQ,EAAE,oBAAoB,EAAE,MAAM,eAAe,CAAA;AAGxG,OAAO,KAAK,EAAE,eAAe,EAAE,gBAAgB,EAAE,MAAM,sBAAsB,CAAA;AAC7E,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,aAAa,CAAA;AA+HrD;;;;;GAKG;AACH,MAAM,MAAM,iBAAiB,GAAG;IAC9B,QAAQ,CAAC,OAAO,EAAE,WAAW,CAAA;IAC7B,QAAQ,CAAC,KAAK,EAAE,eAAe,CAAA;IAC/B,QAAQ,CAAC,MAAM,EAAE,MAAM,CAAA;IACvB,QAAQ,CAAC,MAAM,CAAC,EAAE,MAAM,C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