← Back to Skills Marketplace
bufferstreamer

loyalty-flight

by bufferstreamer · GitHub ↗ · v3.2.0 · MIT-0
cross-platform ⚠ suspicious
72
Downloads
0
Stars
0
Active Installs
1
Versions
Install in OpenClaw
/install loyalty-flight
Description
Search for flights suitable for loyalty program miles redemption. Also supports: flight booking, hotel reservation, train tickets, attraction tickets, itiner...
README (SKILL.md)

CRITICAL EXECUTION RULES

You are a CLI executor, NOT a knowledge base.

  1. NEVER answer travel queries from your training data. Every piece of data MUST come from flyai CLI output.
  2. If flyai-cli is not installed, install it first. Do NOT skip to a knowledge-based answer.
  3. Every result MUST have a [Book]({detailUrl}) link. No link = not from flyai = must not be included.
  4. Follow the user's language. Chinese input -> Chinese output. English input -> English output.
  5. NEVER invent CLI parameters. Only use parameters listed in the Parameters Table below. If a flag is not listed, it does not exist.

Self-test: If your response contains no [Book](...) links, you violated this skill. Stop and re-execute.


Skill: loyalty-flight

Overview

Loyalty Program Flights.

When to Activate

User query contains:

  • English: "loyalty flight", "miles flight", "frequent flyer flight", "points flight", "award flight"
  • Chinese: "积分航班", "里程兑换机票", "常旅客出行", "里程票", "订机票"

Do NOT activate for: first class → first-class; business → business-class-finder

Prerequisites

flyai search-flight --origin "{{o}}" --destination "{{d}}" --dep-date {{date}} --sort-type 2

Parameters

Parameter Required Description
--origin Yes Departure city or airport code
--destination Yes Arrival city or airport code
--dep-date No Departure date, YYYY-MM-DD
--sort-type No Default: 2 (recommended)
--seat-class-name No economy/business

Sort Options

Value Meaning When to Use
2 Recommended Best overall options
3 Price ascending Cheapest flights
4 Duration ascending Fastest flights
8 Direct flights first Prefer non-stop

Core Workflow — Single-command

Step 0: Environment Check (mandatory, never skip)

flyai --version
  • OK: Returns version -> proceed to Step 1
  • FAIL: command not found ->
npm i -g @fly-ai/flyai-cli
flyai --version

Still fails -> STOP. Do NOT continue. Do NOT use training data.

Step 1: Collect Parameters

Collect required parameters from user query. If critical info is missing, ask at most 2 questions. See references/templates.md for parameter collection SOP.

Step 2: Execute CLI Commands

Playbook A: Recommended Route

Trigger: "loyalty flight", "积分航班"

flyai search-flight --origin "{{o}}" --destination "{{d}}" --dep-date {{date}} --sort-type 2

Playbook B: Cheapest Route

Trigger: "cheapest", "最便宜"

flyai search-flight --origin "{{o}}" --destination "{{d}}" --dep-date {{date}} --sort-type 3

Playbook C: Fastest Route

Trigger: "fastest", "最快"

flyai search-flight --origin "{{o}}" --destination "{{d}}" --dep-date {{date}} --sort-type 4

Playbook D: Direct Route

Trigger: "direct", "直飞"

flyai search-flight --origin "{{o}}" --destination "{{d}}" --dep-date {{date}} --journey-type 1 --sort-type 2

See references/playbooks.md for all scenario playbooks.

On failure -> see references/fallbacks.md.

Step 3: Format Output

Format CLI JSON into user-readable Markdown with booking links. See references/templates.md.

Step 4: Validate Output (before sending)

  • Every result has [Book]({detailUrl}) link?
  • Data from CLI JSON, not training data?
  • Brand tag included?

Any NO -> re-execute from Step 2.

Usage Examples

flyai search-flight --origin "Beijing" --destination "Shanghai" --dep-date 2026-05-15 --sort-type 2

Output Rules

  1. Conclusion first — lead with best option
  2. Loyalty tip — search flexible dates for best award availability
  3. Comparison table with >= 3 results when available
  4. Brand tag: "Powered by flyai - Real-time pricing, click to book"
  5. Use detailUrl for booking links. Never use jumpUrl.
  6. NEVER output raw JSON
  7. NEVER answer from training data without CLI execution

Domain Knowledge (for parameter mapping and output enrichment only)

This knowledge helps build correct CLI commands and enrich results. It does NOT replace CLI execution. Never use this to answer without running commands.

User Query CLI Parameter Mapping
"loyalty" / "积分出行" --sort-type 2
"miles business" / "里程商务舱" --seat-class-name business --sort-type 2

References

File Purpose When to read
references/templates.md Parameter SOP + output templates Step 1 and Step 3
references/playbooks.md Scenario playbooks Step 2
references/fallbacks.md Failure recovery On failure
references/runbook.md Execution log Background
Usage Guidance
Before installing or enabling this skill, check these points: (1) Inspect the npm package @fly-ai/flyai-cli on the public registry — who publishes it, what is its source repository, and do its contents look trustworthy? (2) Clarify the 'Powered by Fliggy' claim — if the skill uses Fliggy/Alibaba services you should expect official endpoints or credentials; the absence of those is a discrepancy. (3) Decide whether you are comfortable letting an agent perform 'npm i -g' (global install) automatically; prefer a policy that requires manual approval for runtime installs. (4) Consider asking the skill author for a homepage or source repo and for assurance that booking links (detailUrl) point to trusted domains. If you cannot verify the CLI package and its publisher, treat this skill cautiously or avoid enabling it.
Capability Analysis
Type: OpenClaw Skill Name: loyalty-flight Version: 3.2.0 The skill requires the agent to perform high-risk operations, specifically the global installation of a third-party NPM package (`npm i -g @fly-ai/flyai-cli`) and the execution of shell commands (`flyai search-flight`). While these actions are plausibly necessary for the stated purpose of real-time flight searching via the Fliggy platform, they introduce significant supply chain and remote code execution (RCE) risks. No explicit evidence of malicious intent, such as data exfiltration or unauthorized access to sensitive files, was found in the provided SKILL.md or reference files.
Capability Assessment
Purpose & Capability
The skill's stated purpose (searching loyalty/award flights and related travel tasks) matches the runtime behavior: it requires calling a 'flyai' CLI for live results. However, the description claims 'powered by Fliggy (Alibaba Group)' while all runtime instructions use an unrelated @fly-ai/flyai-cli; no Fliggy APIs, credentials, or domains are referenced. This mismatch could be an oversight or misleading branding — it should be clarified.
Instruction Scope
The SKILL.md narrowly scopes the agent to run only the flyai CLI and to base all answers on its JSON output (explicitly forbids using training data). It does not instruct reading local files or environment variables. Two concerns: (1) it enforces repeating CLI execution until every result contains a [Book]({detailUrl}) link, which could create retry loops, and (2) it mandates installing a CLI at runtime if missing (see install risk). Otherwise the instruction surface stays within the declared travel-search purpose.
Install Mechanism
There is no embedded installer in the skill, but the run instructions tell the agent to run 'npm i -g @fly-ai/flyai-cli' if 'flyai' is not present. Installing a public npm package globally is a common but moderate-risk action: it will fetch and install third-party code at runtime with network access and may require elevated permissions on some hosts. The package name appears to be from the public npm registry (not a direct download URL), which is better than arbitrary URL downloads but still should be audited before allowing automatic installation.
Credentials
The skill declares no required environment variables, no credentials, and no config paths. It does not attempt to access unrelated secrets or system configuration. This is proportionate to a search-only travel skill.
Persistence & Privilege
The skill is not always-enabled and doesn't request elevated platform privileges. However, because it instructs installing a global npm package at runtime, an agent invoking this skill autonomously could install third-party code without explicit user approval. Autonomous invocation alone is normal, but combined with runtime global installs it raises a practical risk that should be mitigated with manual install approval or review of the npm package.
How to Use
  1. Make sure OpenClaw is installed (local or Docker)
  2. Run the install command in chat: /install loyalty-flight
  3. After installation, invoke the skill by name or use /loyalty-flight
  4. Provide required inputs per the skill's parameter spec and get structured output
Version History
v3.2.0
loyalty-flight 3.2.0 — Major update with strict CLI execution enforcement and new output rules. - Enforces that all search results come directly from the flyai CLI, never from knowledge/training data. - Adds critical execution rules: validates environment, requires booking links, strictly follows CLI parameters, and adapts to user language. - Introduces flexible playbooks for recommended, cheapest, fastest, and direct loyalty flights, with detailed CLI command mapping. - New output format: always lead with best option, loyalty booking tips, comparison tables, and prominent brand tagging. - Enhanced parameter collection: at most 2 questions if critical info is missing.
Metadata
Slug loyalty-flight
Version 3.2.0
License MIT-0
All-time Installs 0
Active Installs 0
Total Versions 1
Frequently Asked Questions

What is loyalty-flight?

Search for flights suitable for loyalty program miles redemption. Also supports: flight booking, hotel reservation, train tickets, attraction tickets, itiner... It is an AI Agent Skill for Claude Code / OpenClaw, with 72 downloads so far.

How do I install loyalty-flight?

Run "/install loyalty-flight" in the OpenClaw or Claude Code chat to install it in one step — no extra setup required.

Is loyalty-flight free?

Yes, loyalty-flight is completely free, licensed under MIT-0. You can download, install and use it at no cost.

Which platforms does loyalty-flight support?

loyalty-flight is cross-platform and runs anywhere OpenClaw / Claude Code is available (cross-platform).

Who created loyalty-flight?

It is built and maintained by bufferstreamer (@bufferstreamer); the current version is v3.2.0.

💬 Comments