Skip to content
fal.ai logo

fal.ai

fal.ai AI image generation. Use this skill when you need to use fal, fal.ai, or generate images from text prompts using AI text-to-image models.

SKILL.md

Full skill instructions

fal.ai Image Generator

Use the fal.ai API to generate images from text prompts.

Official docs: https://fal.ai/​docs


When to Use

Use this skill when you need to:

  • Generate images from text descriptions
  • Create illustrations or visual content
  • Generate blog headers, thumbnails, or social media images

Prerequisites

  1. Sign up at fal.ai
  2. Get your API key from the dashboard
export FAL_KEY="your-api-key"

Important: When using $VAR in a command that pipes to another command, wrap the command containing $VAR in bash -c '...'. Due to a Claude Code bug, environment variables are silently cleared when pipes are used directly.

bash -c 'curl -s "https://api.example.com" -H "Authorization: Bearer $API_KEY"'

How to Use

1. Generate Image (nano-banana-pro - fast)

Write to /​tmp/​fal_request.json:

{
  "prompt": "A futuristic city at sunset, cyberpunk style"
}

Then run:

bash -c 'curl -s -X POST "https://fal.run/​fal-ai/​nano-banana-pro" --header "Authorization: Key ${FAL_KEY}" --header "Content-Type: application/​json" -d @/​tmp/​fal_request.json' | jq -r '.images[0].url'

2. Generate Image (flux/​schnell - fast)

Write to /​tmp/​fal_request.json:

{
  "prompt": "A cute cat eating a cookie"
}

Then run:

bash -c 'curl -s -X POST "https://fal.run/​fal-ai/​flux/​schnell" --header "Authorization: Key ${FAL_KEY}" --header "Content-Type: application/​json" -d @/​tmp/​fal_request.json' | jq -r '.images[0].url'

3. Generate Image (recraft-v3 - high quality)

Write to /​tmp/​fal_request.json:

{
  "prompt": "Abstract art, vibrant colors"
}

Then run:

bash -c 'curl -s -X POST "https://fal.run/​fal-ai/​recraft-v3" --header "Authorization: Key ${FAL_KEY}" --header "Content-Type: application/​json" -d @/​tmp/​fal_request.json' | jq -r '.images[0].url'

4. Generate with Custom Size

Write to /​tmp/​fal_request.json:

{
  "prompt": "Mountain landscape",
  "image_size": "landscape_16_9"
}

Then run:

bash -c 'curl -s -X POST "https://fal.run/​fal-ai/​nano-banana-pro" --header "Authorization: Key ${FAL_KEY}" --header "Content-Type: application/​json" -d @/​tmp/​fal_request.json' | jq -r '.images[0].url'

5. Download Generated Image

Write to /​tmp/​fal_request.json:

{
  "prompt": "A minimalist workspace"
}

Then run:

bash -c 'curl -s -X POST "https://fal.run/​fal-ai/​nano-banana-pro" --header "Authorization: Key ${FAL_KEY}" --header "Content-Type: application/​json" -d @/​tmp/​fal_request.json' | jq -r '.images[0].url' | xargs curl -sL -o /​tmp/​image.png

6. Pipe Prompt from Echo (JSON escaped)

echo "A dragon breathing fire, epic fantasy art" | jq -Rs '{prompt: .}' > /​tmp/​fal_request.json
bash -c 'curl -s -X POST "https://fal.run/​fal-ai/​nano-banana-pro" --header "Authorization: Key ${FAL_KEY}" --header "Content-Type: application/​json" -d @/​tmp/​fal_request.json' | jq -r '.images[0].url'

7. Pipe Prompt from File (JSON escaped)

cat /​tmp/​prompt.txt | jq -Rs '{prompt: .}' > /​tmp/​fal_request.json
bash -c 'curl -s -X POST "https://fal.run/​fal-ai/​nano-banana-pro" --header "Authorization: Key ${FAL_KEY}" --header "Content-Type: application/​json" -d @/​tmp/​fal_request.json' | jq -r '.images[0].url'

8. Pipe with Additional Parameters

echo "Neon city at night" | jq -Rs '{prompt: ., image_size: "landscape_16_9"}' > /​tmp/​fal_request.json
bash -c 'curl -s -X POST "https://fal.run/​fal-ai/​nano-banana-pro" --header "Authorization: Key ${FAL_KEY}" --header "Content-Type: application/​json" -d @/​tmp/​fal_request.json' | jq -r '.images[0].url'

Available Models

ModelDescription
nano-banana-proFast, good quality (recommended)
flux/​schnellFast generation
flux-proHigh quality
recraft-v3High quality vector/​illustration

See more at: https://fal.ai/models


Image Sizes

SizeAspect Ratio
square1:1
square_hd1:1 (high res)
portrait_4_34:3
portrait_16_916:9
landscape_4_33:4
landscape_16_99:16

Prompt Guidelines

For best results:

  1. Be specific - Describe the subject clearly
  2. Add style hints - "modern", "minimalist", "photorealistic", "digital art", "cinematic"
  3. Specify colors/​mood - "blue and purple gradient", "warm tones", "dark and moody"
  4. Keep it concise - Clear and focused descriptions work better

More Marketing skills

copywriting logo
Marketing

copywriting

Marketing copy for homepages, landing pages, pricing pages, and other conversion-focused web pages.

53.3K 216.1K
View
flux-2-klein logo
Marketing

flux-2-klein

Fast image generation with Flux 2 Klein, optimized for sub-second iteration and multi-reference brand styling.

52 176.2K
View

Psychological principles and mental models for understanding customer behavior and influencing marketing decisions.

53.3K 153K
View

Plan searchable and shareable content that drives traffic, builds authority, and generates leads.

53.3K 150.9K
View

Build SEO-optimized pages at scale using templates, data, and proven playbook patterns.

53.3K 140.1K
View

Brainstorm and prioritize marketing strategies tailored to your SaaS stage, budget, and goals.

53.3K 137.2K
View
ai-seo logo
Marketing

ai-seo

Optimize content for discovery, citation, and visibility across AI search platforms and LLM assistants.

53.3K 136.7K
View
copy-editing logo
Marketing

copy-editing

Systematic improvement of existing marketing copy through seven focused editing passes.

53.3K 136.4K
View

Plan and optimize your website's page hierarchy, navigation, URL structure, and internal linking.

53.3K 112.8K
View
revops logo
Marketing

revops

Design and optimize systems connecting marketing, sales, and customer success into a unified revenue engine.

53.3K 104.9K
View

Applies Anthropic's official brand colors and typography to any sort of artifact that may benefit from having Anthropic's look-and-feel. Use it when brand colors or style guidelines, visual formatting, or company design standards apply.

179.7K 100.1K
View

Convert websites into professional HyperFrames videos with guided storyboarding and brand-aligned composition.

57K 93.5K
View

Sales & marketing AI tools

KreadoAI logo
Sales & marketing

KreadoAI

Revolutionize Video Creation with AI-Generated Avatars and Voices

Paid
View
Followr logo
Sales & marketing

Followr

Social media on autopilot

Paid
View
Logodiffusion logo
Sales & marketing

Logodiffusion

Design custom logos instantly with AI.

Paid
View
I
Sales & marketing

Ideogram

Text-heavy marketing and design images

Freemium
View
Prompt Silo logo
Sales & marketing

Prompt Silo

Boost Your SEO with Content and SEO Silos

Free
View
Marketing Blocks logo
Sales & marketing

Marketing Blocks

Revolutionize Your Marketing with AI-Powered MarketingBlocks!

Paid
View
Scrip AI logo
Sales & marketing

Scrip AI

10X faster & free AI content creation for 100+ use cases

Free
View
Tribescaler logo
Sales & marketing

Tribescaler

Tribescaler | Make Your Tweets Go Viral

Paid
View