Guidelines for building RoboCorp RPA automation with Python, emphasizing functional programming, Pydantic validation, and async operations.
Install
npx skills add https://github.com/mindrally/skills --skill robocorp-cursor-rulesSKILL.md
RoboCorp Python Development
You are an expert in Python and RoboCorp RPA development.
Core Guidelines
Key Principles
- Write concise, technical responses with accurate Python examples
- Emphasize functional, declarative programming while avoiding classes
- Prioritize iteration and modularization over code duplication
- Use descriptive variable names with auxiliary verbs (e.g.,
is_active,has_permission) - Adopt lowercase with underscores for directories/files (e.g.,
tasks/data_processing.py) - Favor named exports for utility functions and task definitions
- Implement the Receive an Object, Return an Object (RORO) pattern
Python/RoboCorp Standards
- Use
deffor pure functions andasync deffor asynchronous operations - Include type hints for all function signatures
- Prefer Pydantic models over raw dictionaries for input validation
- Structure files with: exported tasks, sub-tasks, utilities, static content, types
Error Handling and Validation
- Handle errors and edge cases at the beginning of functions
- Use early returns for error conditions to avoid deeply nested statements
- Place the happy path last for improved readability
- Implement guard clauses for preconditions and invalid states
- Provide proper error logging and user-friendly messages
- Use custom error types for consistent handling
RoboCorp-Specific Guidelines
- Use functional components (plain functions) and Pydantic models
- Create declarative task definitions with clear return type annotations
- Minimize lifecycle event handlers; prefer context managers
- Employ middleware for logging, error monitoring, and optimization
- Optimize performance using async functions for I/O-bound tasks
- Use specific exceptions like
RPA.HTTP.HTTPExceptionfor expected errors - Apply Pydantic's
BaseModelfor consistent input/output validation
Performance Optimization
- Minimize blocking I/O operations; use asynchronous operations for all database calls
- Implement caching for static and frequently accessed data using Redis or in-memory stores
- Optimize data serialization/deserialization with Pydantic
- Use lazy loading techniques for large datasets
Key Conventions
- Rely on RoboCorp's dependency injection system
- Prioritize RPA performance metrics (execution time, resource utilization, throughput)
- Limit blocking operations; favor asynchronous flows
- Structure tasks and dependencies clearly for maintainability
Related skills
agent-browservercel-labs967KBrowser automation CLI for AI agents. Use when the user needs to interact with websites, including navigating pages, filling forms, clicking buttons, taking screenshots, extracting data, testing web apps, or automating any browser task. Triggers include requests to "open a website", "fill out a form", "click a button", "take a screenshot", "scrape data from a page", "test this web app", "login to a site", "automate browser actions", or any task requiring programmatic web interaction. Also use fojust-scrapescrapegraphai245KSearch, scrape, crawl, extract structured data, and monitor web pages via the ScrapeGraph AI CLI. Use when the user asks to search the web, scrape a webpage, grab content from a URL, extract JSON from a site, crawl documentation or site sections, monitor a page for changes, inspect request history, check ScrapeGraph credits, or validate API setup.browser-actbrowser-act108Kagent-browser101-skills104KBrowser automation for AI agents via inference.sh. Navigate web pages, interact with elements using @e refs, take screenshots, record video. Capabilities: web scraping, form filling, clicking, typing, drag-drop, file upload, JavaScript execution. Use for: web automation, data extraction, testing, agent browsing, research. Triggers: browser, web automation, scrape, navigate, click, fill form, screenshot, browse web, playwright, headless browser, web agent, surf internet, record video