rasa-writing-custom-actions

Create custom Python actions for Rasa CALM assistants using the Rasa SDK.

5|3|Updated Mar 2, 2026
One-click install
npx skills add https://github.com/RasaHQ/rasa-agent-skills --skill rasa-writing-custom-actions
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: rasa-writing-custom-actions
Source: https://github.com/RasaHQ/rasa-agent-skills/tree/main/skills/rasa-writing-custom-actions
Command: npx skills add https://github.com/RasaHQ/rasa-agent-skills --skill rasa-writing-custom-actions

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) components.

What problem does it solve?

This Skill provides guidance and best practices for writing custom Python actions in Rasa, enabling developers to extend conversational AI agents with custom logic and integrations.

Core Features & Use Cases

  • Custom Logic Implementation: Execute Python code for tasks like API calls, database queries, or complex computations.
  • Integration with External Services: Connect Rasa agents to external systems and data sources.
  • Dynamic Responses & Validation: Create custom responses and implement sophisticated slot validation logic.
  • Use Case: You need to integrate your Rasa chatbot with a CRM to fetch customer details before responding to a query. This Skill will guide you on creating a custom action to perform that API call and update the conversation state.

Quick Start

Use the rasa-writing-custom-actions skill to create a new custom action file named action_get_user_profile.py in the actions/ directory.

Frequently Asked Questions about rasa-writing-custom-actions

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I write custom Python actions for a Rasa chatbot?

You can integrate external APIs in Rasa by creating custom Python action files using the Rasa SDK, which handle API calls to fetch or update data from external systems like a CRM before responding to user queries.

How does slot validation logic work with Rasa custom actions?

Yes, you can use custom Python actions to execute complex computations like database queries or API calls within your Rasa assistant, extending your conversational AI agents with custom logic and integrations.

What is the process for registering custom action files with the Rasa SDK?

Rasa custom actions require adherence to the Rasa SDK protocols and action server communication mechanisms, utilizing Python to structure and register action files that execute custom logic and handle dynamic conversational flows.

How do I structure Python action files for dynamic conversational flows in Rasa?

Rasa custom actions handle dynamic conversational flows by executing Python code that connects to external services, implementing sophisticated slot validation logic and custom responses based on real-time data retrieval from external systems.