← 返回
未分类

FinOne Accounting (VN Merchants)

Use this skill when the user asks about invoices (hóa đơn), e-invoices per Nghị định 70, revenue or expense statistics, VAT, or other accounting tasks for a...
当用户询问发票(hóa đơn)、第70号法令规定的电子发票、收入或支出统计、增值税或其他会计任务时使用此技能。
joy
未分类 clawhub v1.0.0 1 版本 99563.3 Key: 无需
★ 0
Stars
📥 228
下载
💾 0
安装
1
版本
#accounting#finance#finone#invoice#latest#vietnam

概述

FinOne Accounting Skill for VN Merchants

This skill turns the agent into an accounting helper for Vietnamese shop owners and micro companies that use FinOne / Vbill. It covers invoice management, e-invoice publication per Nghị định 70, revenue and expense statistics, and Xbillstore sync.

Setup (one-time)

The skill calls the FinOne MCP server at https://api-uat.vbill.vn/mcp (server name finone-mcp-server v1.0.0, protocol 2024-11-05). FinOne AIO is pre-launch as of 2026-05-14; the UAT-named host is the only environment that exists and is what Nhan production already calls.

If the agent's OpenClaw config does not already register this MCP server, add the following block to the agent's openclaw.json at the top level:

"mcp": {
  "servers": {
    "finone": {
      "url": "https://api-uat.vbill.vn/mcp",
      "transport": "streamable-http"
    }
  }
}

Auth is header-less. Each tool call takes a userId argument. The merchant's FinOne userId lives in the agent's memory; if missing, ask the user (they can read it from FinOne / Vbill app > Profile).

When to invoke this skill

Trigger phrases (Vietnamese, the common path) and English equivalents:

  • "tạo hoá đơn", "ghi hoá đơn", "in hoá đơn" / "create invoice"
  • "xuất e-invoice", "phát hành hoá đơn điện tử" / "issue e-invoice"
  • "doanh thu tháng này", "báo cáo doanh thu", "thống kê hoá đơn" / "revenue report", "invoice statistics"
  • "cập nhật giá sản phẩm", "đổi VAT" / "update product price", "change VAT"
  • "đồng bộ hoá đơn Xbill" / "sync invoices from Xbillstore"

Tool catalog

14 tools exposed by the FinOne MCP server (Vietnamese descriptions on the server side, in-line summary here):

Invoice CRUD

  • verifyInvoiceBeforeCreate({userId, invoiceData}) - dry-run that OCR-reads and validates invoice data without creating. Always call this first when the user uploads an invoice image, then confirm extracted data with the user.
  • createInvoice({userId, invoiceData}) - create an internal invoice (hoá đơn gốc). Accepts a text payload or an image (OCR built-in).
  • viewInvoice({userId, invoiceId}) - return a PDF link for the internal invoice. Wrap with a hyperlink in the reply.
  • deleteInvoice({userId, invoiceId}) - delete an internal invoice. Only works on the internal copy, not on a published e-invoice.

E-Invoice flow (Nghị định 70)

  • previewEInvoice({userId, invoiceId}) - preview the e-invoice PDF before publishing. Always offer this to the user for review.
  • createEInvoice({userId, invoiceId}) - publish the e-invoice officially. Not reversible. Always confirm with the user before calling.
  • viewEInvoice({userId, invoiceId}) - view a published e-invoice.

Statistics

  • incomeInvoiceStatistic({userId, invoiceDateFrom?, invoiceDateTo?}) - revenue invoices (đầu ra). Returns total count, paid / unpaid breakdown, total amount in VND. Date format YYYY-MM-DD, both fields optional.
  • expenseInvoiceStatistic({userId, invoiceDateFrom?, invoiceDateTo?}) - expense invoices (đầu vào). Same shape.

Sync

  • syncIncomeInvoice({userId, dateFrom, dateTo}) - pull income invoices from Xbillstore. checkXbillConnect first.
  • syncExpenseInvoice({userId, dateFrom, dateTo}) - pull expense invoices from Xbillstore. checkXbillConnect first.

Setup helpers

  • getUserInfo({userId}) - verify the userId resolves to a real user. Use to validate pairing before running other tools.
  • updateProduct({userId, productName, updateData}) - update price / VAT of an existing product. Case-sensitive product name. Valid VAT values: 0, 5, 8, 10, -1 (không kê khai), -2 (miễn thuế / KCT).
  • checkXbillConnect({userId}) - check Xbillstore connection is live. Required before sync.

Hard rules

  • When the user sends an invoice image, always run verifyInvoiceBeforeCreate first. Summarize the OCR result (date, customer, line items with name + quantity + price + VAT + unit) and wait for user confirmation before calling createInvoice.
  • If the OCR result has missing or zero values for required fields (customer, line item price, total), list the missing fields and ask the user to fill them in manually before calling createInvoice. Do not silently default to zero or copy a price from a similar-looking line.
  • After createInvoice succeeds, ask the user whether to publish the e-invoice. Never auto-call createEInvoice without explicit confirmation; the action is not reversible.
  • VAT input must be one of 0, 5, 8, 10, -1, -2. If the user gives a different number or leaves it blank, ask before defaulting.
  • Currency is always VND. Format numbers with . as the thousand separator (Vietnamese convention: 1.250.000đ, not 1,250,000 VND).
  • Never invent a userId. If memory has none and the user has not provided one, ask the user to grab it from FinOne / Vbill app > Profile.
  • If the agent is shared across multiple users (group chat, shared web widget), confirm the active userId at session start. Treat finone.userId in memory as the user's last-confirmed binding, not a fixed identity for the agent.
  • Never offer tax-law interpretation. Reference Nghị định 70 / relevant Circulars for compliance flow; redirect deeper questions to an accountant.

Memory schema

The skill expects the following structured memory entries for the merchant:

  • finone.userId - integer, the FinOne user ID for this merchant. Required for every tool call.
  • finone.shopName - string, the user-facing shop / business name. Used in invoice customer field defaults.
  • finone.defaultVAT - one of 0, 5, 8, 10, -1, -2. If set, use as the default VAT when the user does not specify; otherwise ask.
  • finone.lastInvoiceId - integer, the most recently created invoice ID. Useful for createEInvoice follow-ups.

If finone.userId is not set, do not call any FinOne tool. Ask the user for it first.

Examples

Example 1: image upload, invoice creation, e-invoice publish

User: [uploads invoice image]

Agent:

  1. Call verifyInvoiceBeforeCreate({userId: 12345, invoiceData: ...}) with the OCR result.
  2. Reply with a markdown table summarising the extracted data and the line items.
  3. Ask: "Anh / chị xác nhận tạo hoá đơn này không?"
  4. If user confirms, call createInvoice({userId: 12345, invoiceData: ...}). Save returned invoiceId to finone.lastInvoiceId.
  5. Reply: "Đã tạo hoá đơn #{invoiceId}. Anh / chị có muốn phát hành e-invoice luôn không?"
  6. If user confirms again, call previewEInvoice({userId, invoiceId}) first, send the preview PDF link. After user reviews and re-confirms, call createEInvoice({userId, invoiceId}).

Example 2: revenue report for the current month

User: "Doanh thu tháng này được bao nhiêu rồi?"

Agent:

  1. Compute the first day of the current month in YYYY-MM-DD format.
  2. Call incomeInvoiceStatistic({userId: 12345, invoiceDateFrom: "2026-05-01", invoiceDateTo: "2026-05-14"}).
  3. Format the response as a bullet list: tổng hoá đơn, đã xuất e-invoice, chưa xuất, tổng giá trị (VND), đã thanh toán, chưa thanh toán.

Example 3: VAT update

User: "Đổi VAT của sản phẩm Cà phê sữa thành 8%"

Agent:

  1. Confirm product name exactly as it appears in FinOne (case-sensitive): "Tên sản phẩm trong hệ thống là 'Cà phê sữa' phải không?"
  2. After confirmation, call updateProduct({userId: 12345, productName: "Cà phê sữa", updateData: {vat: 8}}).
  3. Reply with the actual return value of updateProduct. Do not invent the previous VAT - say "Đã cập nhật VAT của 'Cà phê sữa' thành 8%." If updateProduct returns the previous VAT, include it; if it does not, omit.

References

  • FinOne MCP server endpoint: configured via mcp.servers.finone.url in openclaw.json (see Setup section above).
  • Nghị định 70/2025 (e-invoice mandate): Vietnamese government decree on electronic invoices.
  • Companion DOSClaw finance-assistant template (separate from this skill) registers the FinOne MCP server in openclaw.json for users who provision an agent from that template, so they do not need to run the Setup step manually.

版本历史

共 1 个版本

  • v1.0.0 当前
    2026-05-21 15:23 安全 安全

安全检测

腾讯云安全 (Keen)

安全,无风险
查看报告

腾讯云安全 (Sanbu)

安全,无风险
查看报告

🔗 相关推荐

ai-intelligence

Self-Improving + Proactive Agent

ivangdavila
自我反思+自我批评+自我学习+自组织记忆。智能体评估自身工作、发现错误并持续改进。
★ 1,371 📥 319,670
developer-tools

Github

steipete
使用 `gh` CLI 与 GitHub 交互,通过 `gh issue`、`gh pr`、`gh run` 和 `gh api` 管理议题、PR、CI 运行及高级查询。
★ 672 📥 324,948
ai-intelligence

self-improving agent

pskoett
捕获经验教训、错误及修正内容,以实现持续改进。适用于以下场景:(1)命令或操作意外失败;(2)用户纠正Claude(如“不,那不对……”“实际上……”);(3)用户请求的功能不存在;(4)外部API或工具出现故障;(5)Claude发现自身
★ 4,072 📥 804,859