New to Kendo UI for jQuery? Start a free 30-day trial

SmartPaste

configuration

Configures the SmartPasteButton integration for AI-powered form filling. When enabled, adds a SmartPasteButton that can intelligently parse clipboard content and distribute it to appropriate form fields using AI processing.

<form id="myForm"></form>

<script>
    $("#myForm").kendoForm({
        formData: {
            firstName: "",
            lastName: "",
            email: "",
            phone: ""
        },
        smartPaste: {
            service: {
                url: "https://your-ai-service.com/api/smart-paste",
                headers: {
                    "Authorization": "Bearer YOUR_API_KEY"
                }
            }
        }
    });
</script>

Specifies custom form field configurations for AI processing. If not provided, the SmartPasteButton will automatically detect form fields from the Form's items configuration.

smartPaste.formFields.field String

The name of the form field that corresponds to a form element.

smartPaste.formFields.type String

The expected data type of the form field.

smartPaste.formFields.description String

A description of the form field that helps the AI service understand its purpose.

smartPaste.formFields.allowedValues Array

An array of allowed values that restricts the AI service to only use specific values for this field.

<form id="myForm"></form>

<script>
    $("#myForm").kendoForm({
        formData: {
            firstName: "",
            lastName: "",
            email: "",
            category: ""
        },
        items: [
            { field: "firstName", label: "First Name" },
            { field: "lastName", label: "Last Name" },
            { field: "email", label: "Email", validation: { required: true } },
            { 
                field: "category", 
                label: "Category",
                editor: "DropDownList",
                editorOptions: {
                    dataSource: ["business", "personal", "urgent"]
                }
            }
        ],
        smartPaste: {
            formFields: [
                { field: "firstName", type: "string", description: "Person's first name" },
                { field: "lastName", type: "string", description: "Person's last name" },
                { field: "email", type: "email", description: "Email address" },
                { field: "category", type: "string", description: "Contact category", allowedValues: ["business", "personal", "urgent"] }
            ],
            service: {
                url: "https://your-ai-service.com/api/smart-paste",
                headers: {
                    "Authorization": "Bearer YOUR_API_KEY"
                }
            }
        }
    });
</script>

The AI service configuration for processing clipboard content and generating intelligent field mappings.

<form id="myForm"></form>

<script>
    $("#myForm").kendoForm({
        formData: {
            firstName: "",
            lastName: "",
            email: ""
        },
        smartPaste: {
            service: {
                url: "https://api.example.com/parse",
                headers: {
                    "Authorization": "Bearer token123",
                    "Content-Type": "application/json"
                },
                data: {
                    locale: "en-US"
                }
            }
        }
    });
</script>