"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.FieldsValidationSchema = exports.fields = void 0;
const extensions_core_1 = require("@awell-health/extensions-core");
const zod_1 = require("zod");
exports.fields = {
    id: {
        id: 'id',
        label: 'ID',
        description: 'The id of the patient in Healthie.',
        type: extensions_core_1.FieldType.STRING,
        required: true,
    },
    first_name: {
        id: 'first_name',
        label: 'First name',
        description: 'The first name of the patient.',
        type: extensions_core_1.FieldType.STRING,
        required: false,
    },
    last_name: {
        id: 'last_name',
        label: 'Last name',
        description: 'The last name of the patient.',
        type: extensions_core_1.FieldType.STRING,
        required: false,
    },
    legal_name: {
        id: 'legal_name',
        label: 'Legal name',
        description: "The patient's legal name which will be used in CMS 1500 Claims, Invoices, and Superbills.",
        type: extensions_core_1.FieldType.STRING,
        required: false,
    },
    email: {
        id: 'email',
        label: 'Email',
        description: 'The email address of the patient.',
        type: extensions_core_1.FieldType.STRING,
        required: false,
    },
    dob: {
        id: 'dob',
        label: 'Date of birth',
        description: 'Date of birth of the patient',
        type: extensions_core_1.FieldType.DATE,
        required: false,
    },
    phone_number: {
        id: 'phone_number',
        label: 'Phone number',
        description: 'The phone number of the patient.',
        type: extensions_core_1.FieldType.STRING,
        stringType: extensions_core_1.StringType.PHONE,
        required: false,
    },
    provider_id: {
        id: 'provider_id',
        label: 'Provider ID',
        description: 'This is the ID of the provider and defaults to the user the API key is associated with. Also known as the `dietitian_id`.',
        type: extensions_core_1.FieldType.STRING,
        required: false,
    },
    user_group_id: {
        id: 'user_group_id',
        label: 'User group ID',
        description: 'The user group the patient belongs to.',
        type: extensions_core_1.FieldType.STRING,
        required: false,
    },
    active: {
        id: 'active',
        label: 'Active',
        description: 'Whether the patient is still active.',
        type: extensions_core_1.FieldType.BOOLEAN,
        required: false,
    },
    height: {
        id: 'height',
        label: 'Height',
        description: 'The height of the patient.',
        type: extensions_core_1.FieldType.STRING,
        required: false,
    },
    gender: {
        id: 'gender',
        label: 'Gender',
        description: 'The gender of the patient. Either "Female", "Male", or "Other".',
        type: extensions_core_1.FieldType.STRING,
        required: false,
    },
    gender_identity: {
        id: 'gender_identity',
        label: 'Gender identity',
        description: 'Should only be passed when gender is "Other"',
        type: extensions_core_1.FieldType.STRING,
        required: false,
    },
    sex: {
        id: 'sex',
        label: 'Sex',
        description: 'The sex of the patient. Either "Female", "Male".',
        type: extensions_core_1.FieldType.STRING,
        required: false,
    },
    resend_welcome_email: {
        id: 'resend_welcome_email',
        label: 'Resend welcome email',
        description: 'Whether to resend the welcome email to the patient',
        type: extensions_core_1.FieldType.BOOLEAN,
        required: false,
    },
};
exports.FieldsValidationSchema = zod_1.z.object({
    id: zod_1.z.string().min(1),
    first_name: zod_1.z.string().optional(),
    last_name: zod_1.z.string().optional(),
    legal_name: zod_1.z.string().optional(),
    email: zod_1.z.string().optional(),
    dob: zod_1.z.string().optional(),
    phone_number: zod_1.z.string().optional(),
    provider_id: zod_1.z.string().optional(),
    user_group_id: zod_1.z.string().optional(),
    active: zod_1.z.boolean().optional(),
    height: zod_1.z.string().optional(),
    gender: zod_1.z.enum(['Female', 'Male', 'Other']).optional(),
    gender_identity: zod_1.z.string().optional(),
    sex: zod_1.z.enum(['Female', 'Male']).optional(),
    resend_welcome_email: zod_1.z.boolean().optional(),
});
//# sourceMappingURL=fields.js.map