"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 = {
    resourceJson: {
        id: 'resourceJson',
        label: 'Resource JSON',
        description: 'FHIR resource or Bundle as JSON. Supports single resources (e.g., Patient, Observation) or FHIR Bundles (transaction/batch) for creating multiple resources.',
        type: extensions_core_1.FieldType.JSON,
        required: true,
    },
    searchResourceType: {
        id: 'searchResourceType',
        label: 'Search Resource Type',
        description: 'Optional: FHIR resource type to search for (e.g., Patient, Observation). If provided along with Search Identifier, the action will search for existing resources before creating a new one.',
        type: extensions_core_1.FieldType.STRING,
        required: false,
    },
    searchIdentifier: {
        id: 'searchIdentifier',
        label: 'Search Identifier',
        description: 'Optional: Identifier value to search for (e.g., MRN, SSN). If provided along with Search Resource Type, the action will search for existing resources with this identifier before creating a new one.',
        type: extensions_core_1.FieldType.STRING,
        required: false,
    },
};
exports.FieldsValidationSchema = zod_1.z.object({
    resourceJson: zod_1.z.string().min(1),
    searchResourceType: zod_1.z.string().optional(),
    searchIdentifier: zod_1.z.string().optional(),
});
//# sourceMappingURL=fields.js.map