service.dataObject|Function

The data to send with the AI service request.

Example

<div id="aiprompt"></div>
<script>
    $("#aiprompt").kendoAIPrompt({
        service: {
            url: "/api/llm",
            data: {
                "key": "value"
            }
        }
    });
</script>

Example

<div id="aiprompt"></div>
<script>
    $("#aiprompt").kendoAIPrompt({
        service: {
            url: "/api/llm",
            data: function(prompt, isRetry, history) {
                return {
                    "messages": [{
                        type: messageTypes.user,
                        text: prompt
                    }],
                    "key": "value"
                }
            }
        }
    });
</script>
In this article
service.data
Not finding the help you need?
Contact Support