Sign up (with export icon)

AIQuickActionCustomActionDefinition

Api-interface iconinterface

A custom AI quick action definition.

An example of an action that inserts content in the editor. The model property is optional — if not specified, the default model (from ai.models.defaultModelId configuration or the first available model) will be used:

{
	id: 'add-quote-from-famous-person',
	label: 'Add a quote from a famous person',
	prompt: 'Add a quote from a known person, which would make sense in the context of the selected text.',
	type: 'action',
	model: 'claude-4-6-sonnet'
}
Copy code

Properties

  • Chevron-right icon

    id : string
    readonlyinherited

    The unique identifier of the action.

  • Chevron-right icon

    label : string
    readonlyinherited

    The human-readable label of the action.

  • Chevron-right icon

    model : string | undefined
    readonlyinherited

    The AI model to use for the action. For 'action' type, if not specified, the default model will be used. For 'chat' type, if not specified, the model currently selected in the AI Chat will be used.

  • Chevron-right icon

    prompt : string
    readonlyinherited

    The prompt to be sent to the AI model when the action is executed.

  • Chevron-right icon

    type : 'action'

    The type of the action.