appwrite-utils
Version:
`appwrite-utils` is a comprehensive TypeScript library designed to streamline the development process for Appwrite projects. Version 1.0.0 aligns with the YAML-first architecture of `appwrite-utils-cli`, providing enhanced integration capabilities and rob
84 lines (83 loc) • 3.54 kB
TypeScript
import { z } from "zod";
export declare const importDefSchema: z.ZodObject<{
type: z.ZodOptional<z.ZodDefault<z.ZodEnum<{
create: "create";
update: "update";
}>>>;
filePath: z.ZodString;
basePath: z.ZodOptional<z.ZodString>;
primaryKeyField: z.ZodDefault<z.ZodString>;
idMappings: z.ZodOptional<z.ZodArray<z.ZodObject<{
sourceField: z.ZodString;
fieldToSet: z.ZodOptional<z.ZodString>;
targetFieldToMatch: z.ZodOptional<z.ZodString>;
targetField: z.ZodString;
targetCollection: z.ZodString;
}, z.core.$strip>>>;
createUsers: z.ZodOptional<z.ZodNullable<z.ZodDefault<z.ZodBoolean>>>;
updateMapping: z.ZodOptional<z.ZodObject<{
originalIdField: z.ZodString;
targetField: z.ZodString;
}, z.core.$strip>>;
attributeMappings: z.ZodArray<z.ZodObject<{
oldKey: z.ZodOptional<z.ZodString>;
oldKeys: z.ZodOptional<z.ZodArray<z.ZodString>>;
targetKey: z.ZodString;
valueToSet: z.ZodOptional<z.ZodAny>;
fileData: z.ZodOptional<z.ZodObject<{
name: z.ZodString;
path: z.ZodString;
}, z.core.$strip>>;
converters: z.ZodOptional<z.ZodDefault<z.ZodArray<z.ZodString>>>;
validationActions: z.ZodOptional<z.ZodDefault<z.ZodArray<z.ZodObject<{
action: z.ZodString;
params: z.ZodArray<z.ZodString>;
}, z.core.$strip>>>>;
postImportActions: z.ZodOptional<z.ZodDefault<z.ZodArray<z.ZodObject<{
action: z.ZodString;
params: z.ZodArray<z.ZodUnion<[z.ZodString, z.ZodRecord<z.ZodString, z.ZodAny>]>>;
}, z.core.$strip>>>>;
}, z.core.$strip>>;
}, z.core.$strip>;
export declare const importDefSchemas: z.ZodArray<z.ZodObject<{
type: z.ZodOptional<z.ZodDefault<z.ZodEnum<{
create: "create";
update: "update";
}>>>;
filePath: z.ZodString;
basePath: z.ZodOptional<z.ZodString>;
primaryKeyField: z.ZodDefault<z.ZodString>;
idMappings: z.ZodOptional<z.ZodArray<z.ZodObject<{
sourceField: z.ZodString;
fieldToSet: z.ZodOptional<z.ZodString>;
targetFieldToMatch: z.ZodOptional<z.ZodString>;
targetField: z.ZodString;
targetCollection: z.ZodString;
}, z.core.$strip>>>;
createUsers: z.ZodOptional<z.ZodNullable<z.ZodDefault<z.ZodBoolean>>>;
updateMapping: z.ZodOptional<z.ZodObject<{
originalIdField: z.ZodString;
targetField: z.ZodString;
}, z.core.$strip>>;
attributeMappings: z.ZodArray<z.ZodObject<{
oldKey: z.ZodOptional<z.ZodString>;
oldKeys: z.ZodOptional<z.ZodArray<z.ZodString>>;
targetKey: z.ZodString;
valueToSet: z.ZodOptional<z.ZodAny>;
fileData: z.ZodOptional<z.ZodObject<{
name: z.ZodString;
path: z.ZodString;
}, z.core.$strip>>;
converters: z.ZodOptional<z.ZodDefault<z.ZodArray<z.ZodString>>>;
validationActions: z.ZodOptional<z.ZodDefault<z.ZodArray<z.ZodObject<{
action: z.ZodString;
params: z.ZodArray<z.ZodString>;
}, z.core.$strip>>>>;
postImportActions: z.ZodOptional<z.ZodDefault<z.ZodArray<z.ZodObject<{
action: z.ZodString;
params: z.ZodArray<z.ZodUnion<[z.ZodString, z.ZodRecord<z.ZodString, z.ZodAny>]>>;
}, z.core.$strip>>>>;
}, z.core.$strip>>;
}, z.core.$strip>>;
export type ImportDef = z.infer<typeof importDefSchema>;
export type ImportDefs = z.infer<typeof importDefSchemas>;