mirror of
https://github.com/Unleash/unleash.git
synced 2025-01-11 00:08:30 +01:00
8f5bda6b8a
This PR updates the endpoint documentation and schemas related to Admin UI feedback.
48 lines
1.4 KiB
TypeScript
48 lines
1.4 KiB
TypeScript
import { FromSchema } from 'json-schema-to-ts';
|
|
import { userSchema } from './user-schema';
|
|
import { permissionSchema } from './permission-schema';
|
|
import { feedbackResponseSchema } from './feedback-response-schema';
|
|
|
|
export const meSchema = {
|
|
$id: '#/components/schemas/meSchema',
|
|
type: 'object',
|
|
additionalProperties: false,
|
|
required: ['user', 'permissions', 'feedback', 'splash'],
|
|
description: 'Detailed user information',
|
|
properties: {
|
|
user: {
|
|
$ref: '#/components/schemas/userSchema',
|
|
},
|
|
permissions: {
|
|
description: 'User permissions for projects and environments',
|
|
type: 'array',
|
|
items: {
|
|
$ref: '#/components/schemas/permissionSchema',
|
|
},
|
|
},
|
|
feedback: {
|
|
description: 'User feedback information',
|
|
type: 'array',
|
|
items: {
|
|
$ref: '#/components/schemas/feedbackResponseSchema',
|
|
},
|
|
},
|
|
splash: {
|
|
description: 'Splash screen configuration',
|
|
type: 'object',
|
|
additionalProperties: {
|
|
type: 'boolean',
|
|
},
|
|
},
|
|
},
|
|
components: {
|
|
schemas: {
|
|
userSchema,
|
|
permissionSchema,
|
|
feedbackResponseSchema,
|
|
},
|
|
},
|
|
} as const;
|
|
|
|
export type MeSchema = FromSchema<typeof meSchema>;
|