UNPKG

unleash-server

Version:

Unleash is an enterprise ready feature toggles service. It provides different strategies for handling feature toggles.

87 lines (86 loc) 3.71 kB
import { FromSchema } from 'json-schema-to-ts'; export declare const playgroundRequestSchema: { readonly $id: "#/components/schemas/playgroundRequestSchema"; readonly description: "Data for the playground API to evaluate toggles"; readonly type: "object"; readonly required: readonly ["environment", "context"]; readonly properties: { readonly environment: { readonly type: "string"; readonly example: "development"; readonly description: "The environment to evaluate toggles in."; }; readonly projects: { readonly oneOf: readonly [{ readonly type: "array"; readonly items: { readonly type: "string"; }; readonly example: readonly ["my-project"]; readonly description: "A list of projects to check for toggles in."; }, { readonly type: "string"; readonly enum: readonly ["*"]; readonly description: "Check toggles in all projects."; }]; }; readonly context: { readonly description: "The context to use when evaluating toggles"; readonly $ref: "#/components/schemas/sdkContextSchema"; }; }; readonly components: { readonly schemas: { readonly sdkContextSchema: { readonly $id: "#/components/schemas/sdkContextSchema"; readonly description: "The Unleash context as modeled in client SDKs"; readonly type: "object"; readonly additionalProperties: { readonly type: "string"; readonly example: "top-level custom context value"; }; readonly required: readonly ["appName"]; readonly properties: { readonly appName: { readonly type: "string"; readonly minLength: 1; readonly example: "My cool application."; }; readonly currentTime: { readonly type: "string"; readonly format: "date-time"; readonly example: "2022-07-05T12:56:41+02:00"; }; readonly environment: { readonly type: "string"; readonly deprecated: true; }; readonly properties: { readonly type: "object"; readonly additionalProperties: { readonly type: "string"; }; readonly example: { readonly customContextField: "this is one!"; readonly otherCustomField: "3"; }; }; readonly remoteAddress: { readonly type: "string"; readonly example: "192.168.1.1"; }; readonly sessionId: { readonly type: "string"; readonly example: "b65e7b23-fec0-4814-a129-0e9861ef18fc"; }; readonly userId: { readonly type: "string"; readonly example: "username@provider.com"; }; }; readonly components: {}; }; }; }; }; export declare type PlaygroundRequestSchema = FromSchema<typeof playgroundRequestSchema>;