Refly refly
Base skill for Refly ecosystem: creates, discovers, and runs domain-specific skills bound to workflows. Routes user intent to matching domain skills via symlinks, delegates execution to Refly backend. Use when user asks to: create skills, run workflows, automate multi-step tasks, or manage pipelines. Triggers: refly, skill, workflow, run skill, create skill, automation, pipeline. Requires: @refly/cli installed and authenticated.
git clone https://github.com/refly-ai/refly
T=$(mktemp -d) && git clone --depth=1 https://github.com/refly-ai/refly "$T" && mkdir -p ~/.claude/skills && cp -r "$T/packages/cli/skill" ~/.claude/skills/refly-ai-refly-refly && rm -rf "$T"
packages/cli/skill/SKILL.mdRefly
Rules
- CLI only - Use
, never call API directly.refly <command> - Trust JSON - Only trust CLI JSON (
,ok
,payload
,error
).hint - No fabricated IDs - Never invent workflow/run/node IDs.
- No tokens - Never print or request auth tokens.
- Stop on error - If
, stop and showok=false
.hint
Available Commands
| Command | ID Format | Description |
|---|---|---|
| - | Check authentication and connection status |
| - | Authenticate with Refly |
| - | List all available skills in the marketplace |
| - | List your installed skills (get installationId here) |
| skpi-xxx | Run an installed skill, returns runId (we-xxx) |
| we-xxx | Watch workflow execution status |
| we-xxx | Get workflow run details |
| we-xxx | Get files from latest toolcall |
| df-xxx | Download a file |
Tip: Get
installationId (skpi-xxx) from refly skill installations.
Command Options
| Command | Option | Description |
|---|---|---|
| | Poll until workflow completes |
| | Polling interval in milliseconds (default: 5000) |
| | Return simplified output with only files and content |
| | With , return only files from the most recent toolcall |
| | Disable output sanitization (show full tool outputs) |
Recommended: Use
--files --latest to get files from the final output without processing all toolcalls.
Skill Categories & Execution Patterns
Choose the execution pattern based on the skill's output type:
| Category | Skills | Output | Pattern |
|---|---|---|---|
| File Generation | image, video, audio skills | Files (png/mp4/mp3) | Run → Wait → Download → Open |
| Text/Data | search, research, report skills | Text content | Run → Wait → Extract content |
| Action | email, messaging, integration skills | Status confirmation | Run → Wait → Confirm |
Pattern A: File Generation Skills
Use for: nano-banana-pro, fal-image, fal-video, fal-audio, seedream-image, kling-video, wan-video
# Step 1: Run and capture RUN_ID RESULT=$(refly skill run --id <installationId> --input '<json>') RUN_ID=$(echo "$RESULT" | jq -r '.payload.workflowExecutions[0].id') # Step 2: Wait for completion refly workflow status "$RUN_ID" --watch --interval 30000 # Step 3: Get files and download to Desktop FILES=$(refly workflow toolcalls "$RUN_ID" --files --latest | jq -r '.payload.files[]') echo "$FILES" | jq -c '.' | while read -r file; do FILE_ID=$(echo "$file" | jq -r '.fileId') FILE_NAME=$(echo "$file" | jq -r '.name') if [ -n "$FILE_ID" ] && [ "$FILE_ID" != "null" ]; then refly file download "$FILE_ID" -o "$HOME/Desktop/${FILE_NAME}" open "$HOME/Desktop/${FILE_NAME}" fi done
Pattern B: Text/Data Skills
Use for: jina, perplexity, weather-report, exa, research skills
# Step 1: Run and capture RUN_ID RESULT=$(refly skill run --id <installationId> --input '<json>') RUN_ID=$(echo "$RESULT" | jq -r '.payload.workflowExecutions[0].id') # Step 2: Wait for completion refly workflow status "$RUN_ID" --watch --interval 30000 # Step 3: Extract text content from toolcalls CONTENT=$(refly workflow toolcalls "$RUN_ID" --files --latest | jq -r '.payload.nodes[].content') echo "$CONTENT"
Pattern C: Action Skills
Use for: send-email, slack, microsoft-teams, zoom, calendar, CRM integrations
# Step 1: Run and capture RUN_ID RESULT=$(refly skill run --id <installationId> --input '<json>') RUN_ID=$(echo "$RESULT" | jq -r '.payload.workflowExecutions[0].id') # Step 2: Wait for completion refly workflow status "$RUN_ID" --watch --interval 30000 # Step 3: Confirm action status STATUS=$(refly workflow detail "$RUN_ID" | jq -r '.payload.status') echo "Action completed with status: $STATUS"
ID Types:
| ID Format | Example | Used For |
|---|---|---|
| skpi-h9kpmts9ho1kl9l1sohaloeu | only |
| we-abc123def456 | , , |
| c-g6emwcpi1wpalsz6j4gyi3d9 | Browser URL only |
| df-b3yxyelshtwsbxbrkmcqxmx9 | |
| skpe-qga5lpyv59yjzz2ghz2iv9bu | ⚠️ Do NOT use for workflow commands |
Required behavior:
returnsskill run
(we-xxx) inRUN_ID.payload.workflowExecutions[0].id- Use
for all workflow commands (we-xxx
,status
,detail
)toolcalls - Choose execution pattern (A/B/C) based on skill category
- File skills: Download to
and~/Desktop/
to show useropen - Text skills: Extract
for text output.payload.nodes[].content - Action skills: Confirm
for completion.payload.status
Directory Structure
~/.refly/skills/ ├── base/ # Base skill files (this symlink target) │ ├── SKILL.md │ └── rules/ │ ├── execution.md │ ├── workflow.md │ ├── node.md │ ├── file.md │ └── skill.md └── <skill-name>/ # Domain skill directories └── SKILL.md ~/.claude/skills/ ├── refly → ~/.refly/skills/base/ # Base skill symlink └── <skill-name> → ~/.refly/skills/<name>/ # Domain skill symlinks
Routing
User intent -> match domain skill (name/trigger) in
~/.claude/skills/
-> read domain skill SKILL.md -> execute via refly skill run -> return CLI-verified result.
References
- Skill execution patterns and error handlingrules/execution.md
- Workflow command referencerules/workflow.md
- Node command referencerules/node.md
- File command referencerules/file.md
- Customized Skill command referencerules/skill.md