Logo van Fubon Trade Api

Fubon Trade Api

Community
Kelu0427
fubon-trade-api

Use when helping users write, review, debug, or validate code for Fubon Neo / Fubon Securities TradeAPI / 富邦新一代 API / 富邦證券 API, including natural-language requests about market data, stock trading, futures/options trading, account queries, conditional orders, SDK installation, local environment checks, latest SDK setup, authentication, certificates, and API Key login. This skill uses the official online llms.txt and llms-full.txt first, with bundled local copies as offline fallback.

Overzicht

UitgeverKelu0427
Repositoryfubon-tradeapi-ai-skill
Skillnaamfubon-trade-api
Sterren
48
Forks
0
Meegeleverde bestanden
6
LicentieMIT
Links
  • Instructies in Markdown

    Het model laadt het bestand SKILL.md alleen als dat nodig is. Dat kost dus alleen tokens als een verzoek daadwerkelijk bij de skill past.

  • Werkt met elk LLM

    AI-skills bestaan uit instructies in gewone Markdown, niet uit aanbiederspecifieke code. Daardoor werken ze met GPT, Claude, Gemini, Grok of een lokaal model.

  • Meegeleverde bestanden: 6

    Scripts, sjablonen en referentiemateriaal die het model tijdens het werken kan lezen. De bestanden kunnen alleen worden gelezen en worden nooit uitgevoerd.

  • Open source

    Gepubliceerd door Kelu0427 op GitHub. Bekijk de bronbestanden voordat je de skill installeert.

Installatie

Installeer de AI-skill Fubon Trade Api in TypingMind om deze met elk LLM te gebruiken, of voeg de skill toe aan een andere agent die SKILL.md kan lezen.

1

Installeren in TypingMind

TypingMind installeert een skill rechtstreeks vanuit de GitHub-map. De app leest SKILL.md, bundelt de bijbehorende bestanden en slaat het resultaat lokaal op.

  1. Open de app en ga naar Plug-ins → Skills.
  2. Kies "Installeren via GitHub".
  3. Plak de onderstaande URL van de skillmap en bevestig.
    https://github.com/Kelu0427/fubon-tradeapi-ai-skill/tree/main
  4. Schakel de skill in voor elke chat waarin je de skill wilt kunnen gebruiken.
Plug-ins → Skills → Skill toevoegen → Via GitHub-URL. Plak vervolgens de map-URL en druk op Doorgaan.
2

Installeren in een andere agent

Elke agent die het Agent Skills-formaat kan lezen, kan deze skill gebruiken — kopieer de map naar de skillmap van die agent.

Claude Code — .claude/skills
git clone --depth 1 https://github.com/Kelu0427/fubon-tradeapi-ai-skill.git \
  .claude/skills/fubon-trade-api
Start Claude Code na het kopiëren opnieuw op, zodat de nieuwe skill wordt herkend.

Gebruik deze skill in TypingMind

Schakel Fubon Trade Api in voor een chat naar keuze in TypingMind en het model doet de rest. De naam en beschrijving staan in de systeemprompt. Zodra een verzoek bij de skill past, laadt het model zelf de volledige instructies. Je hoeft de skill nooit handmatig aan te roepen. Pas als het model de skill daadwerkelijk gebruikt, kost dat tokens.

Het model laadt Fubon Trade Api automatisch zodra een verzoek erbij past.

Werkt met elk AI-model

AI-skills zijn gewone Markdown-instructies in plaats van aanbiederspecifieke code. Daardoor is Fubon Trade Api niet gebonden aan het model waarvoor de skill is geschreven. Installeer de skill één keer in TypingMind en gebruik deze met GPT-5, Claude, Gemini, Grok, DeepSeek, Mistral, Llama of een lokaal model dat je zelf draait — allemaal met je eigen API-sleutels.

  • Alleen geladen wanneer nodig

    De systeemprompt bevat alleen de naam en beschrijving. De instructies worden bij het eerste bijpassende verzoek opgehaald, dus een ongebruikte skill kost niets.

  • Wissel van model tijdens een chat

    Omdat de skill uit instructies bestaat en niet uit code, blijft deze werken als je van model wisselt — het volgende model leest hetzelfde SKILL.md-bestand.

Skillinstructies

Dit is de inhoud van SKILL.md die het model laadt. Lees deze vóór de installatie — een skill bestaat uit instructies die je model zal volgen.

Fubon TradeAPI Skill

Use this skill whenever the user asks for help with Fubon Neo, Fubon Securities API, Fubon TradeAPI, 富邦新一代 API, 富邦證券 API, or natural-language-to-code assistance for Fubon market data, trading, account, futures/options, condition-order workflows, or large-project Fubon API audits.

Source Of Truth

  • Official online index: https://www.fbs.com.tw/TradeAPI/llms.txt. Use first for navigation when network is available.
  • Official online full docs: https://www.fbs.com.tw/TradeAPI/llms-full.txt. Use for exact signatures, object fields, examples, constants, version notes, and error codes when network is available.
  • Bundled llms.txt and llms-full.txt: local cache and offline fallback.
  • references/fubon-api-guidance.md: local workflow and recurring gotchas for agents.
  • scripts/search_docs.py: deterministic search/extract/sync helper for official online docs and local cached docs.

Do not invent API names, enum names, parameter order, or object fields. Prefer official online llms-full.txt; if network is unavailable, use the bundled llms-full.txt cache and say it is the local snapshot.

Workflow

  1. Classify the user's intent:
    • SDK setup/version compatibility, local environment checks, and latest SDK installation/update
    • authentication, password login, API Key login, certificate login
    • market data REST
    • market data WebSocket
    • stock trading and stock account queries
    • futures/options trading and account queries
    • smart/conditional orders
    • large-project audit for an existing app/repository using Fubon APIs
    • error handling, reconnect, or rate limit behavior
  2. Determine the target language. If unspecified, default to Python and say that assumption.
  3. Search the docs with scripts/search_docs.py; add --online when current official docs are needed and network is available.
  4. Read the exact matching section(s) from llms-full.txt; prefer official examples in the user's language.
  5. Produce code that includes imports, login/init steps, object construction, API call, response/error handling, and logout/cleanup when relevant.
  6. If reviewing code, check every SDK call, enum, object field, and argument order against llms-full.txt.

Intent Mapping

Use these natural-language cues and stable API terms to choose searches:

  • setup/version/install/environment check/latest SDK/Python version/SDK: search SDK, compatibility, Python 3.13, v2.2.8, platform-specific SDK download names, and install steps.
  • login/certificate/API Key/account: search login, apikey_login, API Key, certPath, Account.
  • stock quote/price/K-line/books/trades: search Intraday Quote, intraday.quote, Historical Candles, Trades, Books.
  • WebSocket/subscribe/realtime streaming: search websocket_client, subscribe, Trades, Books, Candles.
  • stock order/buy/sell/modify/cancel/order result: search place_order, Order Object, modify_price, cancel_order, get_order_results.
  • futures/options/margin/position: search trading-future, place_order, query_margin_equity, query_single_position, query_estimate_margin.
  • conditional order/TPSL/trailing profit/time slice: search smart-condition, single_condition, multi_condition, TPSL, trail_profit, time_slice_order.
  • large project audit/repository review/automation system/Fubon integration: scan code for Fubon SDK imports, login/session managers, market-data clients, order adapters, accounting services, .env.example, secret handling, paper/live gates, risk managers, mock fallbacks, and docs. Verify SDK calls against llms-full.txt; do not log in or place orders.

Large Project Audit Output

For a large project audit, produce a structured report:

  • Scope: files/modules inspected and Fubon workflows found.
  • P0: issues that can leak secrets, place unintended live orders, bypass risk controls, or use clearly wrong Fubon API calls.
  • P1: likely API mismatches, missing login/init/logout handling, weak paper/live separation, incomplete .env.example, or stale SDK/version assumptions.
  • P2: maintainability, observability, documentation, and test coverage improvements.
  • Verification: commands/tests the user can run without real credentials, plus any manual checks needed before live use.
  • Safety note: state whether the review was static only and whether any real login/order action was intentionally avoided.

Search Examples

bash
python scripts/search_docs.py sync
python scripts/search_docs.py search "place_order OrderType PriceType TimeInForce" --online
python scripts/search_docs.py search "API Key apikey_login" --online
python scripts/search_docs.py section "Intraday Quote" --online
python scripts/search_docs.py section "API Key"
python scripts/search_docs.py lines 23770 23820

On Windows PowerShell:

powershell
python .\scripts\search_docs.py search "place_order OrderType PriceType TimeInForce"

Response Requirements

  • State the verified SDK version or version constraint when relevant.
  • Name the exact documentation anchors searched when giving non-trivial code, e.g. place_order, Order Object, Intraday Quote, apikey_login.
  • Use placeholders for secrets and personal data. Never ask users to paste passwords, API keys, private keys, ID numbers, or certificate passwords into chat.
  • When generating runnable examples that require Fubon credentials, create or update .env.example with placeholder variable names and ensure .env is ignored. Do not create a real .env with secret values unless the user explicitly asks, and never fill it with real credentials.
  • For trading code, explicitly identify whether it may place a real order. Prefer dry-run/review snippets unless the user explicitly asks for live order code.
  • For live order examples, make the account/order parameters obvious placeholders and include a final confirmation step in comments.
  • For market data examples, include sdk.login(...) and sdk.init_realtime() when the official docs require login for market data permission.
  • Prefer modern behavior documented for SDK v2.2.8 unless the user states an older version.
  • If the docs are ambiguous or language-specific, answer with the verified language only and say what still needs checking for other languages.

Common Python Anchors

Verify details in llms-full.txt before finalizing, but these anchors help search:

  • SDK import: from fubon_neo.sdk import FubonSDK
  • Stock order object: from fubon_neo.sdk import Order
  • Trading constants commonly include BSAction, OrderType, PriceType, MarketType, TimeInForce
  • Market data REST client: sdk.marketdata.rest_client.stock or sdk.marketdata.rest_client.futopt
  • Market data WebSocket client: sdk.marketdata.websocket_client.stock or sdk.marketdata.websocket_client.futopt
  • Stock trading namespace: sdk.stock
  • Futures/options trading namespace: commonly documented under trading-future

Quality Checklist

Before answering:

  • You searched official online llms-full.txt when possible, or the bundled local cache when offline. Do not rely on llms.txt alone.
  • The code path matches the requested domain: stock vs futures/options, REST vs WebSocket, trading vs condition order.
  • For large projects, all Fubon SDK entry points, secret sources, paper/live gates, risk controls, and mock/fallback paths were identified or explicitly called out as not found.
  • The code imports every SDK class/constant it uses.
  • Function/method names match the target language casing (place_order in Python, placeOrder in JavaScript, PlaceOrder in C#).
  • Enum/member casing matches the target language.
  • Date/time strings match the documented format.
  • Quantity units are clear: stocks usually use shares; futures/options use lots/contracts per docs.
  • Price fields follow the documented type: many order APIs use string prices.
  • Market/order/price/time-in-force combinations are plausible and documented.
  • Error handling follows the documented SDK version behavior where available.
  • Secrets are placeholders or environment variables.
  • Credential setup uses .env.example or shell environment variables, not secrets in source code.

Meegeleverde bestanden

Zolang de skill geladen is, leest het model deze bestanden als dat nodig is. Het model kan ze alleen lezen; ze worden nooit uitgevoerd.

Veelgestelde vragen

Wat doet de AI-skill Fubon Trade Api?

Use when helping users write, review, debug, or validate code for Fubon Neo / Fubon Securities TradeAPI / 富邦新一代 API / 富邦證券 API, including natural-language requests about market data, stock trading, futures/options trading, account queries, conditional orders, SDK installation, local environment checks, latest SDK setup, authentication, certificates, and API Key login. This skill uses the official online llms.txt and llms-full.txt first, with bundled local copies as offline fallback.

Waarom Fubon Trade Api gebruiken in TypingMind?

Omdat je deze skill één keer installeert en met elk model kunt gebruiken. Fubon Trade Api bestaat uit gewone Markdown in plaats van aanbiederspecifieke code. Dezelfde skill werkt dus met GPT-5, Claude, Gemini, Grok of een lokaal model. Ook als je midden in een chat van model wisselt, blijft de skill werken. TypingMind werkt met je eigen API-sleutels, dus je betaalt aanbieders rechtstreeks in plaats van een abonnement per gebruikersplek af te sluiten. Je skills en chats blijven in je eigen opslag.

Hoe installeer ik Fubon Trade Api in TypingMind?

Open Plug-ins → Skills → Installeren vanaf GitHub in TypingMind en plak https://github.com/Kelu0427/fubon-tradeapi-ai-skill/tree/main. TypingMind leest het bestand SKILL.md, bundelt de bijbehorende bestanden en installeert het geheel als een skill die je per chat kunt inschakelen.

Welke AI-modellen kunnen Fubon Trade Api gebruiken?

Elk model dat je in TypingMind koppelt. AI-skills bestaan uit gewone Markdown-instructies in plaats van aanbiederspecifieke code. GPT, Claude, Gemini, Grok en lokale modellen kunnen deze skill dus allemaal laden wanneer een verzoek erbij past.

Hoeveel AI-modellen kan ik met Fubon Trade Api gebruiken?

Zoveel als je wilt. Je kunt Fubon Trade Api gebruiken met elk model dat skills ondersteunt, zoals GPT, Claude, Gemini, Grok, DeepSeek, Mistral of Llama. Allemaal in TypingMind met je eigen API-sleutels.

Is de AI-skill Fubon Trade Api gratis?

Ja. Deze skill is door Kelu0427 op GitHub gepubliceerd onder de licentie MIT. Je betaalt alleen je eigen AI-aanbieder voor de tokens die je gebruikt.

Wat zijn AI-skills?

Een AI-skill is een herbruikbare bundel instructies die een AI-model leert hoe het één specifieke taak moet uitvoeren. De skill volgt het open Agent Skills-formaat: het bestand SKILL.md bevat de naam en beschrijving van de skill. Daarnaast kan de skill scripts, sjablonen of referentiebestanden bevatten die het model nodig heeft. Het model leest de instructies alleen als je verzoek bij de skill past. Een geïnstalleerde skill kost dus niets zolang deze niet wordt gebruikt.

Waarin verschillen AI-skills van plug-ins of MCP-servers?

Een plug-in of MCP-server geeft een model nieuwe tools om aan te roepen: code die ergens wordt uitgevoerd en een resultaat teruggeeft. Een AI-skill geeft het model juist kennis en een werkwijze: hoe het een taak moet aanpakken, welke stappen het moet volgen en hoe goede uitvoer eruitziet. Skills bestaan uit gewone Markdown en hebben dus geen server, API-sleutel of runtime nodig. Ze werken met elk model.

Bekijk alles

Maak nu je eigen AI-werkruimte

Schrijf je in voor onze nieuwsbrief en blijf op de hoogte van nieuwe functies en toekomstige weggeefacties 👇