@openfeature/flagd-provider 0.13.3 → 0.14.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,362 @@
1
+ import { CallOptions, ChannelCredentials, Client, ClientOptions, ClientReadableStream, ClientUnaryCall, handleServerStreamingCall, handleUnaryCall, Metadata, ServiceError, UntypedServiceImplementation } from "@grpc/grpc-js";
2
+ import _m0 from "protobufjs/minimal";
3
+ export declare const protobufPackage = "flagd.evaluation.v2";
4
+ /**
5
+ * Flag evaluation API
6
+ *
7
+ * This proto forms the basis of a flag-evaluation API.
8
+ * It supports single and bulk evaluation RPCs, and flags of various types, as well as establishing a stream for getting notifications about changes in a flag definition.
9
+ * It supports the inclusion of a "context" with each evaluation, which may contain arbitrary attributes relevant to flag evaluation.
10
+ */
11
+ /** A variant type flag response. */
12
+ export interface AnyFlag {
13
+ /** The reason for the given return value, see https://openfeature.dev/docs/specification/types#resolution-details */
14
+ reason: string;
15
+ /** The variant name of the returned flag value. */
16
+ variant?: string | undefined;
17
+ boolValue?: boolean | undefined;
18
+ stringValue?: string | undefined;
19
+ doubleValue?: number | undefined;
20
+ objectValue?: {
21
+ [key: string]: any;
22
+ } | undefined;
23
+ /** Metadata for this evaluation */
24
+ metadata: {
25
+ [key: string]: any;
26
+ } | undefined;
27
+ }
28
+ /** Request body for boolean flag evaluation, used by the ResolveBoolean rpc. */
29
+ export interface ResolveBooleanRequest {
30
+ /** Flag key of the requested flag. */
31
+ flagKey: string;
32
+ /** Object structure describing the EvaluationContext used in the flag evaluation, see https://openfeature.dev/docs/reference/concepts/evaluation-context */
33
+ context: {
34
+ [key: string]: any;
35
+ } | undefined;
36
+ }
37
+ /** Response body for boolean flag evaluation. used by the ResolveBoolean rpc. */
38
+ export interface ResolveBooleanResponse {
39
+ /** The response value of the boolean flag evaluation, will be unset in the case of error. */
40
+ value?: boolean | undefined;
41
+ /** The reason for the given return value, see https://openfeature.dev/docs/specification/types#resolution-details */
42
+ reason: string;
43
+ /** The variant name of the returned flag value. */
44
+ variant?: string | undefined;
45
+ /** Metadata for this evaluation */
46
+ metadata: {
47
+ [key: string]: any;
48
+ } | undefined;
49
+ }
50
+ /** Request body for string flag evaluation, used by the ResolveString rpc. */
51
+ export interface ResolveStringRequest {
52
+ /** Flag key of the requested flag. */
53
+ flagKey: string;
54
+ /** Object structure describing the EvaluationContext used in the flag evaluation, see https://openfeature.dev/docs/reference/concepts/evaluation-context */
55
+ context: {
56
+ [key: string]: any;
57
+ } | undefined;
58
+ }
59
+ /** Response body for string flag evaluation. used by the ResolveString rpc. */
60
+ export interface ResolveStringResponse {
61
+ /** The response value of the string flag evaluation, will be unset in the case of error. */
62
+ value?: string | undefined;
63
+ /** The reason for the given return value, see https://openfeature.dev/docs/specification/types#resolution-details */
64
+ reason: string;
65
+ /** The variant name of the returned flag value. */
66
+ variant?: string | undefined;
67
+ /** Metadata for this evaluation */
68
+ metadata: {
69
+ [key: string]: any;
70
+ } | undefined;
71
+ }
72
+ /** Request body for float flag evaluation, used by the ResolveFloat rpc. */
73
+ export interface ResolveFloatRequest {
74
+ /** Flag key of the requested flag. */
75
+ flagKey: string;
76
+ /** Object structure describing the EvaluationContext used in the flag evaluation, see https://openfeature.dev/docs/reference/concepts/evaluation-context */
77
+ context: {
78
+ [key: string]: any;
79
+ } | undefined;
80
+ }
81
+ /** Response body for float flag evaluation. used by the ResolveFloat rpc. */
82
+ export interface ResolveFloatResponse {
83
+ /** The response value of the float flag evaluation, will be empty in the case of error. */
84
+ value?: number | undefined;
85
+ /** The reason for the given return value, see https://openfeature.dev/docs/specification/types#resolution-details */
86
+ reason: string;
87
+ /** The variant name of the returned flag value. */
88
+ variant?: string | undefined;
89
+ /** Metadata for this evaluation */
90
+ metadata: {
91
+ [key: string]: any;
92
+ } | undefined;
93
+ }
94
+ /** Request body for int flag evaluation, used by the ResolveInt rpc. */
95
+ export interface ResolveIntRequest {
96
+ /** Flag key of the requested flag. */
97
+ flagKey: string;
98
+ /** Object structure describing the EvaluationContext used in the flag evaluation, see https://openfeature.dev/docs/reference/concepts/evaluation-context */
99
+ context: {
100
+ [key: string]: any;
101
+ } | undefined;
102
+ }
103
+ /** Response body for int flag evaluation. used by the ResolveInt rpc. */
104
+ export interface ResolveIntResponse {
105
+ /** The response value of the int flag evaluation, will be unset in the case of error. */
106
+ value?: string | undefined;
107
+ /** The reason for the given return value, see https://openfeature.dev/docs/specification/types#resolution-details */
108
+ reason: string;
109
+ /** The variant name of the returned flag value. */
110
+ variant?: string | undefined;
111
+ /** Metadata for this evaluation */
112
+ metadata: {
113
+ [key: string]: any;
114
+ } | undefined;
115
+ }
116
+ /** Request body for object flag evaluation, used by the ResolveObject rpc. */
117
+ export interface ResolveObjectRequest {
118
+ /** Flag key of the requested flag. */
119
+ flagKey: string;
120
+ /** Object structure describing the EvaluationContext used in the flag evaluation, see https://openfeature.dev/docs/reference/concepts/evaluation-context */
121
+ context: {
122
+ [key: string]: any;
123
+ } | undefined;
124
+ }
125
+ /** Response body for object flag evaluation. used by the ResolveObject rpc. */
126
+ export interface ResolveObjectResponse {
127
+ /**
128
+ * The response value of the object flag evaluation, will be unset in the case of error.
129
+ *
130
+ * NOTE: This structure will need to be decoded from google/protobuf/struct.proto before it is returned to the SDK
131
+ */
132
+ value?: {
133
+ [key: string]: any;
134
+ } | undefined;
135
+ /** The reason for the given return value, see https://openfeature.dev/docs/specification/types#resolution-details */
136
+ reason: string;
137
+ /** The variant name of the returned flag value. */
138
+ variant?: string | undefined;
139
+ /** Metadata for this evaluation */
140
+ metadata: {
141
+ [key: string]: any;
142
+ } | undefined;
143
+ }
144
+ /** Response body for the EventStream stream response */
145
+ export interface EventStreamResponse {
146
+ /** String key indicating the type of event that is being received, for example, provider_ready or configuration_change */
147
+ type: string;
148
+ /**
149
+ * Object structure for use when sending relevant metadata to provide context to the event.
150
+ * Can be left unset when it is not required.
151
+ */
152
+ data: {
153
+ [key: string]: any;
154
+ } | undefined;
155
+ }
156
+ /** Empty stream request body */
157
+ export interface EventStreamRequest {
158
+ }
159
+ export declare const AnyFlag: {
160
+ encode(message: AnyFlag, writer?: _m0.Writer): _m0.Writer;
161
+ decode(input: _m0.Reader | Uint8Array, length?: number): AnyFlag;
162
+ fromJSON(object: any): AnyFlag;
163
+ toJSON(message: AnyFlag): unknown;
164
+ create<I extends Exact<DeepPartial<AnyFlag>, I>>(base?: I): AnyFlag;
165
+ fromPartial<I extends Exact<DeepPartial<AnyFlag>, I>>(object: I): AnyFlag;
166
+ };
167
+ export declare const ResolveBooleanRequest: {
168
+ encode(message: ResolveBooleanRequest, writer?: _m0.Writer): _m0.Writer;
169
+ decode(input: _m0.Reader | Uint8Array, length?: number): ResolveBooleanRequest;
170
+ fromJSON(object: any): ResolveBooleanRequest;
171
+ toJSON(message: ResolveBooleanRequest): unknown;
172
+ create<I extends Exact<DeepPartial<ResolveBooleanRequest>, I>>(base?: I): ResolveBooleanRequest;
173
+ fromPartial<I extends Exact<DeepPartial<ResolveBooleanRequest>, I>>(object: I): ResolveBooleanRequest;
174
+ };
175
+ export declare const ResolveBooleanResponse: {
176
+ encode(message: ResolveBooleanResponse, writer?: _m0.Writer): _m0.Writer;
177
+ decode(input: _m0.Reader | Uint8Array, length?: number): ResolveBooleanResponse;
178
+ fromJSON(object: any): ResolveBooleanResponse;
179
+ toJSON(message: ResolveBooleanResponse): unknown;
180
+ create<I extends Exact<DeepPartial<ResolveBooleanResponse>, I>>(base?: I): ResolveBooleanResponse;
181
+ fromPartial<I extends Exact<DeepPartial<ResolveBooleanResponse>, I>>(object: I): ResolveBooleanResponse;
182
+ };
183
+ export declare const ResolveStringRequest: {
184
+ encode(message: ResolveStringRequest, writer?: _m0.Writer): _m0.Writer;
185
+ decode(input: _m0.Reader | Uint8Array, length?: number): ResolveStringRequest;
186
+ fromJSON(object: any): ResolveStringRequest;
187
+ toJSON(message: ResolveStringRequest): unknown;
188
+ create<I extends Exact<DeepPartial<ResolveStringRequest>, I>>(base?: I): ResolveStringRequest;
189
+ fromPartial<I extends Exact<DeepPartial<ResolveStringRequest>, I>>(object: I): ResolveStringRequest;
190
+ };
191
+ export declare const ResolveStringResponse: {
192
+ encode(message: ResolveStringResponse, writer?: _m0.Writer): _m0.Writer;
193
+ decode(input: _m0.Reader | Uint8Array, length?: number): ResolveStringResponse;
194
+ fromJSON(object: any): ResolveStringResponse;
195
+ toJSON(message: ResolveStringResponse): unknown;
196
+ create<I extends Exact<DeepPartial<ResolveStringResponse>, I>>(base?: I): ResolveStringResponse;
197
+ fromPartial<I extends Exact<DeepPartial<ResolveStringResponse>, I>>(object: I): ResolveStringResponse;
198
+ };
199
+ export declare const ResolveFloatRequest: {
200
+ encode(message: ResolveFloatRequest, writer?: _m0.Writer): _m0.Writer;
201
+ decode(input: _m0.Reader | Uint8Array, length?: number): ResolveFloatRequest;
202
+ fromJSON(object: any): ResolveFloatRequest;
203
+ toJSON(message: ResolveFloatRequest): unknown;
204
+ create<I extends Exact<DeepPartial<ResolveFloatRequest>, I>>(base?: I): ResolveFloatRequest;
205
+ fromPartial<I extends Exact<DeepPartial<ResolveFloatRequest>, I>>(object: I): ResolveFloatRequest;
206
+ };
207
+ export declare const ResolveFloatResponse: {
208
+ encode(message: ResolveFloatResponse, writer?: _m0.Writer): _m0.Writer;
209
+ decode(input: _m0.Reader | Uint8Array, length?: number): ResolveFloatResponse;
210
+ fromJSON(object: any): ResolveFloatResponse;
211
+ toJSON(message: ResolveFloatResponse): unknown;
212
+ create<I extends Exact<DeepPartial<ResolveFloatResponse>, I>>(base?: I): ResolveFloatResponse;
213
+ fromPartial<I extends Exact<DeepPartial<ResolveFloatResponse>, I>>(object: I): ResolveFloatResponse;
214
+ };
215
+ export declare const ResolveIntRequest: {
216
+ encode(message: ResolveIntRequest, writer?: _m0.Writer): _m0.Writer;
217
+ decode(input: _m0.Reader | Uint8Array, length?: number): ResolveIntRequest;
218
+ fromJSON(object: any): ResolveIntRequest;
219
+ toJSON(message: ResolveIntRequest): unknown;
220
+ create<I extends Exact<DeepPartial<ResolveIntRequest>, I>>(base?: I): ResolveIntRequest;
221
+ fromPartial<I extends Exact<DeepPartial<ResolveIntRequest>, I>>(object: I): ResolveIntRequest;
222
+ };
223
+ export declare const ResolveIntResponse: {
224
+ encode(message: ResolveIntResponse, writer?: _m0.Writer): _m0.Writer;
225
+ decode(input: _m0.Reader | Uint8Array, length?: number): ResolveIntResponse;
226
+ fromJSON(object: any): ResolveIntResponse;
227
+ toJSON(message: ResolveIntResponse): unknown;
228
+ create<I extends Exact<DeepPartial<ResolveIntResponse>, I>>(base?: I): ResolveIntResponse;
229
+ fromPartial<I extends Exact<DeepPartial<ResolveIntResponse>, I>>(object: I): ResolveIntResponse;
230
+ };
231
+ export declare const ResolveObjectRequest: {
232
+ encode(message: ResolveObjectRequest, writer?: _m0.Writer): _m0.Writer;
233
+ decode(input: _m0.Reader | Uint8Array, length?: number): ResolveObjectRequest;
234
+ fromJSON(object: any): ResolveObjectRequest;
235
+ toJSON(message: ResolveObjectRequest): unknown;
236
+ create<I extends Exact<DeepPartial<ResolveObjectRequest>, I>>(base?: I): ResolveObjectRequest;
237
+ fromPartial<I extends Exact<DeepPartial<ResolveObjectRequest>, I>>(object: I): ResolveObjectRequest;
238
+ };
239
+ export declare const ResolveObjectResponse: {
240
+ encode(message: ResolveObjectResponse, writer?: _m0.Writer): _m0.Writer;
241
+ decode(input: _m0.Reader | Uint8Array, length?: number): ResolveObjectResponse;
242
+ fromJSON(object: any): ResolveObjectResponse;
243
+ toJSON(message: ResolveObjectResponse): unknown;
244
+ create<I extends Exact<DeepPartial<ResolveObjectResponse>, I>>(base?: I): ResolveObjectResponse;
245
+ fromPartial<I extends Exact<DeepPartial<ResolveObjectResponse>, I>>(object: I): ResolveObjectResponse;
246
+ };
247
+ export declare const EventStreamResponse: {
248
+ encode(message: EventStreamResponse, writer?: _m0.Writer): _m0.Writer;
249
+ decode(input: _m0.Reader | Uint8Array, length?: number): EventStreamResponse;
250
+ fromJSON(object: any): EventStreamResponse;
251
+ toJSON(message: EventStreamResponse): unknown;
252
+ create<I extends Exact<DeepPartial<EventStreamResponse>, I>>(base?: I): EventStreamResponse;
253
+ fromPartial<I extends Exact<DeepPartial<EventStreamResponse>, I>>(object: I): EventStreamResponse;
254
+ };
255
+ export declare const EventStreamRequest: {
256
+ encode(_: EventStreamRequest, writer?: _m0.Writer): _m0.Writer;
257
+ decode(input: _m0.Reader | Uint8Array, length?: number): EventStreamRequest;
258
+ fromJSON(_: any): EventStreamRequest;
259
+ toJSON(_: EventStreamRequest): unknown;
260
+ create<I extends Exact<DeepPartial<EventStreamRequest>, I>>(base?: I): EventStreamRequest;
261
+ fromPartial<I extends Exact<DeepPartial<EventStreamRequest>, I>>(_: I): EventStreamRequest;
262
+ };
263
+ /** Service defines the exposed rpcs of flagd */
264
+ export type ServiceService = typeof ServiceService;
265
+ export declare const ServiceService: {
266
+ readonly resolveBoolean: {
267
+ readonly path: "/flagd.evaluation.v2.Service/ResolveBoolean";
268
+ readonly requestStream: false;
269
+ readonly responseStream: false;
270
+ readonly requestSerialize: (value: ResolveBooleanRequest) => Buffer<ArrayBuffer>;
271
+ readonly requestDeserialize: (value: Buffer) => ResolveBooleanRequest;
272
+ readonly responseSerialize: (value: ResolveBooleanResponse) => Buffer<ArrayBuffer>;
273
+ readonly responseDeserialize: (value: Buffer) => ResolveBooleanResponse;
274
+ };
275
+ readonly resolveString: {
276
+ readonly path: "/flagd.evaluation.v2.Service/ResolveString";
277
+ readonly requestStream: false;
278
+ readonly responseStream: false;
279
+ readonly requestSerialize: (value: ResolveStringRequest) => Buffer<ArrayBuffer>;
280
+ readonly requestDeserialize: (value: Buffer) => ResolveStringRequest;
281
+ readonly responseSerialize: (value: ResolveStringResponse) => Buffer<ArrayBuffer>;
282
+ readonly responseDeserialize: (value: Buffer) => ResolveStringResponse;
283
+ };
284
+ readonly resolveFloat: {
285
+ readonly path: "/flagd.evaluation.v2.Service/ResolveFloat";
286
+ readonly requestStream: false;
287
+ readonly responseStream: false;
288
+ readonly requestSerialize: (value: ResolveFloatRequest) => Buffer<ArrayBuffer>;
289
+ readonly requestDeserialize: (value: Buffer) => ResolveFloatRequest;
290
+ readonly responseSerialize: (value: ResolveFloatResponse) => Buffer<ArrayBuffer>;
291
+ readonly responseDeserialize: (value: Buffer) => ResolveFloatResponse;
292
+ };
293
+ readonly resolveInt: {
294
+ readonly path: "/flagd.evaluation.v2.Service/ResolveInt";
295
+ readonly requestStream: false;
296
+ readonly responseStream: false;
297
+ readonly requestSerialize: (value: ResolveIntRequest) => Buffer<ArrayBuffer>;
298
+ readonly requestDeserialize: (value: Buffer) => ResolveIntRequest;
299
+ readonly responseSerialize: (value: ResolveIntResponse) => Buffer<ArrayBuffer>;
300
+ readonly responseDeserialize: (value: Buffer) => ResolveIntResponse;
301
+ };
302
+ readonly resolveObject: {
303
+ readonly path: "/flagd.evaluation.v2.Service/ResolveObject";
304
+ readonly requestStream: false;
305
+ readonly responseStream: false;
306
+ readonly requestSerialize: (value: ResolveObjectRequest) => Buffer<ArrayBuffer>;
307
+ readonly requestDeserialize: (value: Buffer) => ResolveObjectRequest;
308
+ readonly responseSerialize: (value: ResolveObjectResponse) => Buffer<ArrayBuffer>;
309
+ readonly responseDeserialize: (value: Buffer) => ResolveObjectResponse;
310
+ };
311
+ readonly eventStream: {
312
+ readonly path: "/flagd.evaluation.v2.Service/EventStream";
313
+ readonly requestStream: false;
314
+ readonly responseStream: true;
315
+ readonly requestSerialize: (value: EventStreamRequest) => Buffer<ArrayBuffer>;
316
+ readonly requestDeserialize: (value: Buffer) => EventStreamRequest;
317
+ readonly responseSerialize: (value: EventStreamResponse) => Buffer<ArrayBuffer>;
318
+ readonly responseDeserialize: (value: Buffer) => EventStreamResponse;
319
+ };
320
+ };
321
+ export interface ServiceServer extends UntypedServiceImplementation {
322
+ resolveBoolean: handleUnaryCall<ResolveBooleanRequest, ResolveBooleanResponse>;
323
+ resolveString: handleUnaryCall<ResolveStringRequest, ResolveStringResponse>;
324
+ resolveFloat: handleUnaryCall<ResolveFloatRequest, ResolveFloatResponse>;
325
+ resolveInt: handleUnaryCall<ResolveIntRequest, ResolveIntResponse>;
326
+ resolveObject: handleUnaryCall<ResolveObjectRequest, ResolveObjectResponse>;
327
+ eventStream: handleServerStreamingCall<EventStreamRequest, EventStreamResponse>;
328
+ }
329
+ export interface ServiceClient extends Client {
330
+ resolveBoolean(request: ResolveBooleanRequest, callback: (error: ServiceError | null, response: ResolveBooleanResponse) => void): ClientUnaryCall;
331
+ resolveBoolean(request: ResolveBooleanRequest, metadata: Metadata, callback: (error: ServiceError | null, response: ResolveBooleanResponse) => void): ClientUnaryCall;
332
+ resolveBoolean(request: ResolveBooleanRequest, metadata: Metadata, options: Partial<CallOptions>, callback: (error: ServiceError | null, response: ResolveBooleanResponse) => void): ClientUnaryCall;
333
+ resolveString(request: ResolveStringRequest, callback: (error: ServiceError | null, response: ResolveStringResponse) => void): ClientUnaryCall;
334
+ resolveString(request: ResolveStringRequest, metadata: Metadata, callback: (error: ServiceError | null, response: ResolveStringResponse) => void): ClientUnaryCall;
335
+ resolveString(request: ResolveStringRequest, metadata: Metadata, options: Partial<CallOptions>, callback: (error: ServiceError | null, response: ResolveStringResponse) => void): ClientUnaryCall;
336
+ resolveFloat(request: ResolveFloatRequest, callback: (error: ServiceError | null, response: ResolveFloatResponse) => void): ClientUnaryCall;
337
+ resolveFloat(request: ResolveFloatRequest, metadata: Metadata, callback: (error: ServiceError | null, response: ResolveFloatResponse) => void): ClientUnaryCall;
338
+ resolveFloat(request: ResolveFloatRequest, metadata: Metadata, options: Partial<CallOptions>, callback: (error: ServiceError | null, response: ResolveFloatResponse) => void): ClientUnaryCall;
339
+ resolveInt(request: ResolveIntRequest, callback: (error: ServiceError | null, response: ResolveIntResponse) => void): ClientUnaryCall;
340
+ resolveInt(request: ResolveIntRequest, metadata: Metadata, callback: (error: ServiceError | null, response: ResolveIntResponse) => void): ClientUnaryCall;
341
+ resolveInt(request: ResolveIntRequest, metadata: Metadata, options: Partial<CallOptions>, callback: (error: ServiceError | null, response: ResolveIntResponse) => void): ClientUnaryCall;
342
+ resolveObject(request: ResolveObjectRequest, callback: (error: ServiceError | null, response: ResolveObjectResponse) => void): ClientUnaryCall;
343
+ resolveObject(request: ResolveObjectRequest, metadata: Metadata, callback: (error: ServiceError | null, response: ResolveObjectResponse) => void): ClientUnaryCall;
344
+ resolveObject(request: ResolveObjectRequest, metadata: Metadata, options: Partial<CallOptions>, callback: (error: ServiceError | null, response: ResolveObjectResponse) => void): ClientUnaryCall;
345
+ eventStream(request: EventStreamRequest, options?: Partial<CallOptions>): ClientReadableStream<EventStreamResponse>;
346
+ eventStream(request: EventStreamRequest, metadata?: Metadata, options?: Partial<CallOptions>): ClientReadableStream<EventStreamResponse>;
347
+ }
348
+ export declare const ServiceClient: {
349
+ new (address: string, credentials: ChannelCredentials, options?: Partial<ClientOptions>): ServiceClient;
350
+ service: typeof ServiceService;
351
+ };
352
+ type Builtin = Date | Function | Uint8Array | string | number | boolean | undefined;
353
+ export type DeepPartial<T> = T extends Builtin ? T : T extends Array<infer U> ? Array<DeepPartial<U>> : T extends ReadonlyArray<infer U> ? ReadonlyArray<DeepPartial<U>> : T extends {} ? {
354
+ [K in keyof T]?: DeepPartial<T[K]>;
355
+ } : Partial<T>;
356
+ type KeysOfUnion<T> = T extends T ? keyof T : never;
357
+ export type Exact<P, I extends P> = P extends Builtin ? P : P & {
358
+ [K in keyof P]: Exact<P[K], I[K]>;
359
+ } & {
360
+ [K in Exclude<keyof I, KeysOfUnion<P>>]: never;
361
+ };
362
+ export {};
@@ -25,13 +25,19 @@ export interface SyncFlagsRequest {
25
25
  * flag configurations from a collection, select the source of the flag or combine this to any desired underlying
26
26
  * filtering mechanism.
27
27
  * ex:- selector: 'source=database,app=weatherapp'
28
+ *
29
+ * @deprecated
28
30
  */
29
31
  selector: string;
30
32
  }
31
33
  /** SyncFlagsResponse is the server response containing feature flag configurations and the state */
32
34
  export interface SyncFlagsResponse {
33
- /** flagd feature flag configuration. Must be validated to schema - https://raw.githubusercontent.com/open-feature/schemas/main/json/flagd-definitions.json */
35
+ /** flagd feature flag configuration. Must be validated to schema - https://raw.githubusercontent.com/open-feature/flagd-schemas/main/json/flags.json */
34
36
  flagConfiguration: string;
37
+ /** Static context to be included in in-process evaluations (optional). */
38
+ syncContext?: {
39
+ [key: string]: any;
40
+ } | undefined;
35
41
  }
36
42
  /** FetchAllFlagsRequest is the request to fetch all flags. Clients send this request as the client in order to resync their internal state */
37
43
  export interface FetchAllFlagsRequest {
@@ -48,18 +54,29 @@ export interface FetchAllFlagsRequest {
48
54
  * flag configurations from a collection, select the source of the flag or combine this to any desired underlying
49
55
  * filtering mechanism.
50
56
  * ex:- selector: 'source=database,app=weatherapp'
57
+ *
58
+ * @deprecated
51
59
  */
52
60
  selector: string;
53
61
  }
54
62
  /** FetchAllFlagsResponse is the server response containing feature flag configurations */
55
63
  export interface FetchAllFlagsResponse {
56
- /** flagd feature flag configuration. Must be validated to schema - https://raw.githubusercontent.com/open-feature/schemas/main/json/flagd-definitions.json */
64
+ /** flagd feature flag configuration. Must be validated to schema - https://raw.githubusercontent.com/open-feature/flagd-schemas/main/json/flags.json */
57
65
  flagConfiguration: string;
58
66
  }
59
- /** GetMetadataRequest is the request for retrieving metadata from the sync service */
67
+ /**
68
+ * GetMetadataRequest is the request for retrieving metadata from the sync service
69
+ *
70
+ * @deprecated
71
+ */
60
72
  export interface GetMetadataRequest {
61
73
  }
62
- /** GetMetadataResponse contains metadata from the sync service */
74
+ /**
75
+ * GetMetadataResponse contains metadata from the sync service
76
+ * DEPRECATED; use flagd.sync.v1.SyncFlagsResponse.sync_context
77
+ *
78
+ * @deprecated
79
+ */
63
80
  export interface GetMetadataResponse {
64
81
  metadata: {
65
82
  [key: string]: any;
@@ -134,6 +151,7 @@ export declare const FlagSyncServiceService: {
134
151
  readonly responseSerialize: (value: FetchAllFlagsResponse) => Buffer<ArrayBuffer>;
135
152
  readonly responseDeserialize: (value: Buffer) => FetchAllFlagsResponse;
136
153
  };
154
+ /** @deprecated */
137
155
  readonly getMetadata: {
138
156
  readonly path: "/flagd.sync.v1.FlagSyncService/GetMetadata";
139
157
  readonly requestStream: false;
@@ -147,6 +165,7 @@ export declare const FlagSyncServiceService: {
147
165
  export interface FlagSyncServiceServer extends UntypedServiceImplementation {
148
166
  syncFlags: handleServerStreamingCall<SyncFlagsRequest, SyncFlagsResponse>;
149
167
  fetchAllFlags: handleUnaryCall<FetchAllFlagsRequest, FetchAllFlagsResponse>;
168
+ /** @deprecated */
150
169
  getMetadata: handleUnaryCall<GetMetadataRequest, GetMetadataResponse>;
151
170
  }
152
171
  export interface FlagSyncServiceClient extends Client {
@@ -155,6 +174,7 @@ export interface FlagSyncServiceClient extends Client {
155
174
  fetchAllFlags(request: FetchAllFlagsRequest, callback: (error: ServiceError | null, response: FetchAllFlagsResponse) => void): ClientUnaryCall;
156
175
  fetchAllFlags(request: FetchAllFlagsRequest, metadata: Metadata, callback: (error: ServiceError | null, response: FetchAllFlagsResponse) => void): ClientUnaryCall;
157
176
  fetchAllFlags(request: FetchAllFlagsRequest, metadata: Metadata, options: Partial<CallOptions>, callback: (error: ServiceError | null, response: FetchAllFlagsResponse) => void): ClientUnaryCall;
177
+ /** @deprecated */
158
178
  getMetadata(request: GetMetadataRequest, callback: (error: ServiceError | null, response: GetMetadataResponse) => void): ClientUnaryCall;
159
179
  getMetadata(request: GetMetadataRequest, metadata: Metadata, callback: (error: ServiceError | null, response: GetMetadataResponse) => void): ClientUnaryCall;
160
180
  getMetadata(request: GetMetadataRequest, metadata: Metadata, options: Partial<CallOptions>, callback: (error: ServiceError | null, response: GetMetadataResponse) => void): ClientUnaryCall;
@@ -57,7 +57,7 @@ export interface SyncFlagsRequest {
57
57
  }
58
58
  /** SyncFlagsResponse is the server response containing feature flag configurations and the state */
59
59
  export interface SyncFlagsResponse {
60
- /** flagd feature flag configuration. Must be validated to schema - https://raw.githubusercontent.com/open-feature/schemas/main/json/flagd-definitions.json */
60
+ /** flagd feature flag configuration. Must be validated to schema - https://raw.githubusercontent.com/open-feature/flagd-schemas/main/json/flags.json */
61
61
  flagConfiguration: string;
62
62
  /**
63
63
  * State conveying the operation to be performed by flagd. See the descriptions of SyncState for an explanation of
@@ -85,7 +85,7 @@ export interface FetchAllFlagsRequest {
85
85
  }
86
86
  /** FetchAllFlagsResponse is the server response containing feature flag configurations */
87
87
  export interface FetchAllFlagsResponse {
88
- /** flagd feature flag configuration. Must be validated to schema - https://raw.githubusercontent.com/open-feature/schemas/main/json/flagd-definitions.json */
88
+ /** flagd feature flag configuration. Must be validated to schema - https://raw.githubusercontent.com/open-feature/flagd-schemas/main/json/flags.json */
89
89
  flagConfiguration: string;
90
90
  }
91
91
  export declare const SyncFlagsRequest: {