@@ -215,7 +215,7 @@ export interface IRBSegment {
215215 } | null
216216}
217217
218- // Similar to ISplit
218+ // Superset of ISplit (i.e., ISplit extends IConfig)
219219// - with optional fields related to targeting information and
220220// - an optional link fields that binds configurations to other entities
221221export interface IConfig {
@@ -234,7 +234,7 @@ export interface IConfig {
234234 trafficAllocation ?: number ,
235235 trafficAllocationSeed ?: number
236236 configurations : {
237- [ variantName : string ] : string | object | null
237+ [ treatmentName : string ] : string | object | null
238238 } ,
239239 sets ?: string [ ] ,
240240 impressionsDisabled ?: boolean ,
@@ -246,6 +246,21 @@ export interface IConfig {
246246 }
247247}
248248
249+ /** Interface of the parsed JSON response of `/configs` */
250+ export interface IConfigsResponse {
251+ configs ?: {
252+ t : number ,
253+ s ?: number ,
254+ d : IConfig [ ]
255+ } ,
256+ rbs ?: {
257+ t : number ,
258+ s ?: number ,
259+ d : IRBSegment [ ]
260+ }
261+ }
262+
263+ // @TODO : rename to IDefinition (Configs and Feature Flags are definitions)
249264export interface ISplit {
250265 name : string ,
251266 changeNumber : number ,
@@ -285,20 +300,6 @@ export interface ISplitChangesResponse {
285300 }
286301}
287302
288- /** Interface of the parsed JSON response of `/configs` */
289- export interface IConfigsResponse {
290- configs ?: {
291- t : number ,
292- s ?: number ,
293- d : IConfig [ ]
294- } ,
295- rbs ?: {
296- t : number ,
297- s ?: number ,
298- d : IRBSegment [ ]
299- }
300- }
301-
302303/** Interface of the parsed JSON response of `/segmentChanges/{segmentName}` */
303304export interface ISegmentChangesResponse {
304305 name : string ,
0 commit comments