UNPKG

@fibery/ai-utils

Version:

Utilities for Fibery AI

69 lines (68 loc) 2.13 kB
import { TypeObject, Schema } from '@fibery/schema'; import { EnumFetcher, ProcessedApp, DataTypeMap, Enums, ProcessSchemaParams, GetSchemaStringParams } from './types'; export declare const processSchema: ({ fetchEnums, typeObjects, compact, fiberySchema, overrideFieldNameType, includeEnumId, }: ProcessSchemaParams) => Promise<{ spaceSchema: ProcessedApp; dataTypeMap: DataTypeMap; enums: Enums; }>; export declare const getSchemaString: ({ fetchEnums, typeObjects, schema, nonExistentTypes, compact, overrideFieldNameType, includeEnumId, }: GetSchemaStringParams) => Promise<{ spaceSchema: ProcessedApp; dataTypeMap: DataTypeMap; schemaString: string; typeObjects: TypeObject[]; schema: Schema; enums: Enums; }>; export declare const getWorkspaceStructureString: ({ schema, apps }: { schema: Schema; apps: { name: string; }[]; }) => Promise<{ spaces: Record<string, { name: string; type: TypeObject; }[]>; schemaString: string; schema: Schema; }>; export declare const getDomainTypes: ({ schema, apps }: { schema: Schema; apps: { name: string; }[]; }) => { schema: Schema; typeObjects: TypeObject[]; }; export declare const getDomainTypesString: ({ fetchEnums, schema, apps, detection, includeEnumId, buildSchema, }: { fetchEnums?: EnumFetcher; schema: Schema; apps: { name: string; }[]; detection?: string[]; includeEnumId?: boolean; buildSchema?: typeof getSchemaString; }) => Promise<{ spaceSchema: ProcessedApp; dataTypeMap: DataTypeMap; schemaString: string; typeObjects: TypeObject[]; schema: Schema; enums: Enums; }>; export declare const getAllTypesString: ({ fetchEnums, schema, detection, includeEnumId, buildSchema, }: { fetchEnums?: EnumFetcher; schema: Schema; detection?: string[]; includeEnumId?: boolean; buildSchema?: typeof getSchemaString; }) => Promise<{ spaceSchema: ProcessedApp; dataTypeMap: DataTypeMap; schemaString: string; typeObjects: TypeObject[]; schema: Schema; enums: Enums; }>;