"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.FieldsValidationSchema = exports.fields = void 0;
const zod_1 = require("zod");
const extensions_core_1 = require("@awell-health/extensions-core");
exports.fields = {
    urlTemplate: {
        id: 'urlTemplate',
        label: 'URL template',
        description: 'The URL with the placeholder marked by double curly braces like (e.g. https://your-url.com/[placeholder]).',
        type: extensions_core_1.FieldType.STRING,
        required: true,
    },
    value: {
        id: 'value',
        label: 'Value',
        description: 'The actual value to replace the placeholder with. When left blank, we will use the id of orchestrated care flow.',
        type: extensions_core_1.FieldType.STRING,
        required: false,
    },
};
exports.FieldsValidationSchema = zod_1.z.object({
    urlTemplate: zod_1.z
        .string()
        .url()
        .refine((input) => input.includes('[placeholder]'), {
        message: 'Your URL template does not include a [placeholder]',
    }),
    value: zod_1.z.string().optional(),
});
//# sourceMappingURL=fields.js.map