line-flex-message
SKILL.md
LINE Flex Message & Reliability Skill
This skill extends Claude's ability to design high-quality, brand-consistent LINE Flex Messages and implement reliable messaging workflows.
Core Capabilities
- Advanced Flex Layouts: Precise control over nested boxes, dynamic widths, and complex UI patterns (e.g., flight tickets, product lists).
- Video Integration: Guidelines and templates for embedding video components in the hero block.
- Reliable Communication: Implementing
X-Line-Retry-Keyand exponential backoff strategies to handle 429/5xx errors.
Workflow Patterns
1. Designing a Complex Flex Message
- Identify Layout: Determine if it's a single Bubble or a Carousel.
- Component Mapping: Map UI elements to Flex blocks (Header, Hero, Body, Footer).
- Refine Nesting: Use
scripts/flex_builder.pyor referencereferences/flex-elements.mdto create multi-layer box nesting. - Add Actionability: Ensure all buttons and images have correct
actiondefinitions.
2. Implementing API Retries
- Generate Key: Use
scripts/flex_builder.pyto generate a uniqueX-Line-Retry-Key. - Header Injection: Always include the retry key in the first request for supported APIs (Push, Multicast, etc.).
- Error Handling: Follow the decision matrix in
references/retry-policy.md:- 429/5xx/Timeout: Retry with exponential backoff.
- 409: Log as "already accepted" and proceed.
- 2xx: Success.
Resources
- Flex Elements & Layout Guide: Detailed component specifications.
- Flex Video Guide: Requirements and examples for video embedding.
- Retry & Reliability Policy: Strategic guide for headers and error handling.
- Flex Builder Script: Python utility for generating complex Flex JSON and retry headers.
Layout Patterns Examples
- Product List: Use nested horizontal boxes for image + text rows.
- Video Hero: Mega/Giga sized bubbles with
type: videoin hero block. - Carousel: Side-scrolling bubbles for browsing multiple items.
Quality Standards
- Consistency: Use
spacingandmarginconsistently across bubbles. - Responsiveness: Use
wrap: truefor text and test layouts with different font sizes. - Stability: Never send high-frequency messages without a retry strategy.
Weekly Installs
2
Repository
yangnim21029/li…-api-devFirst Seen
Feb 22, 2026
Security Audits
Installed on
opencode2
gemini-cli2
antigravity2
github-copilot2
codex2
kimi-cli2