2022-06-30 11:54:14 +02:00
import { FromSchema } from 'json-schema-to-ts' ;
export const clientFeaturesQuerySchema = {
$id : '#/components/schemas/clientFeaturesQuerySchema' ,
type : 'object' ,
additionalProperties : false ,
2023-06-14 14:19:00 +02:00
description : 'Query parameters active for a client features request' ,
2022-06-30 11:54:14 +02:00
properties : {
tag : {
type : 'array' ,
2023-06-14 14:19:00 +02:00
description : 'Features tagged with one of these tags are included' ,
2022-06-30 11:54:14 +02:00
items : {
type : 'array' ,
items : {
type : 'string' ,
} ,
} ,
2023-06-14 14:19:00 +02:00
example : [ [ 'simple:payment' , 'simple:stripejourney' ] ] ,
2022-06-30 11:54:14 +02:00
} ,
project : {
type : 'array' ,
items : {
type : 'string' ,
} ,
2023-06-14 14:19:00 +02:00
description :
'Features that are part of these projects are included in this response. (DEPRECATED) - Handled by API tokens' ,
example : [ 'new.payment.flow' ] ,
deprecated : true ,
2022-06-30 11:54:14 +02:00
} ,
namePrefix : {
2023-06-14 14:19:00 +02:00
description :
'Features are filtered to only include features whose name starts with this prefix' ,
2022-06-30 11:54:14 +02:00
type : 'string' ,
2023-06-14 14:19:00 +02:00
example : 'payment' ,
2022-06-30 11:54:14 +02:00
} ,
environment : {
type : 'string' ,
2023-06-14 14:19:00 +02:00
description :
'Strategies for the feature toggle configured for this environment are included. (DEPRECATED) - Handled by API tokens' ,
deprecated : true ,
2022-06-30 11:54:14 +02:00
} ,
inlineSegmentConstraints : {
2023-06-14 14:19:00 +02:00
description :
'Set to true if requesting client does not support Unleash-Client-Specification 4.2.2 or newer. Modern SDKs will have this set to false, since they will be able to merge constraints and segments themselves' ,
2022-06-30 11:54:14 +02:00
type : 'boolean' ,
2023-06-14 14:19:00 +02:00
example : true ,
2022-06-30 11:54:14 +02:00
} ,
} ,
components : { } ,
} as const ;
export type ClientFeaturesQuerySchema = FromSchema <
typeof clientFeaturesQuerySchema
> ;