← Back to Skills Marketplace
teckyuen

AutoCount

by teckyuen · GitHub ↗ · v1.0.0 · MIT-0
cross-platform ⚠ suspicious
95
Downloads
0
Stars
0
Active Installs
1
Versions
Install in OpenClaw
/install autocount
Description
Create and validate AutoCount business documents through AutoCount Web API. Use when the user wants to create or test sales invoices, purchase invoices, good...
README (SKILL.md)

AutoCount

Use this skill to create or test AutoCount documents through the AutoCount Web API.

Supported document work in this skill:

  • sales invoice
  • sales order / delivery order / credit note
  • purchase invoice
  • goods received note
  • purchase order inspection/listing
  • master-data lookup for debtors, creditors, items, locations, and currencies

Workflow

  1. Confirm the base URL, API name, and API key.
  2. Use the headers:
    • X-API-NAME: 9999
    • X-API-KEY: 9999
    • Content-Type: application/json
  3. Prefer SaveAsDraft: true unless the user explicitly wants final posting.
  4. For transfer chains, the source document must be final (SaveAsDraft: false). Draft purchase documents cannot be used as transfer sources.
  5. Prefer AutoCount defaults (\x3C\x3C\x3CDefault>>>) over guessed business values.
  6. Do not hardcode tax codes. Use defaults or system-derived values only.
  7. After each create call, fetch the created record and report the actual document number.

Known API pattern

Base URL example:

  • http://your-autocount-host:9999

Headers example:

X-API-NAME: \x3Cyour-api-name>
X-API-KEY: \x3Cyour-api-key>
Content-Type: application/json

Endpoints verified

Sales

  • POST {{localURL}}/api/SalesOrder/CreateRecord
  • GET {{localURL}}/api/SalesOrder/GetRecord?docKey=...
  • POST {{localURL}}/api/DeliveryOrder/CreateRecord
  • GET {{localURL}}/api/DeliveryOrder/GetRecord?docKey=...
  • POST {{localURL}}/api/Invoice/CreateRecord
  • GET {{localURL}}/api/Invoice/GetRecord?docKey=...
  • POST {{localURL}}/api/CreditNote/CreateRecord
  • GET {{localURL}}/api/CreditNote/GetRecord?docKey=...
  • POST {{localURL}}/api/CreditNote/UpdateRecord?docKey=...
  • POST {{localURL}}/api/CreditNote/CancelRecord?docKey=...
  • POST {{localURL}}/api/CreditNote/DeleteRecord?docKey=...

Purchase

  • POST {{localURL}}/api/PurchaseOrder/CreateRecord
  • POST {{localURL}}/api/PurchaseOrder/UpdateRecord?docKey=...
  • POST {{localURL}}/api/PurchaseInvoice/CreateRecord
  • POST {{localURL}}/api/GoodsReceivedNote/CreateRecord
  • GET {{localURL}}/api/PurchaseOrder/GetRecord?docKey=...
  • POST {{localURL}}/api/PurchaseOrder/GetRecordList
  • GET {{localURL}}/api/GoodsReceivedNote/GetRecord?docKey=...
  • POST {{localURL}}/api/GoodsReceivedNote/GetRecordList
  • GET {{localURL}}/api/PurchaseInvoice/GetRecord?docKey=...

Master data

  • GET {{localURL}}/api/Debtor/GetRecordList
  • GET {{localURL}}/api/Creditor/GetRecordList
  • GET {{localURL}}/api/Item/GetRecordList
  • GET {{localURL}}/api/Location/GetRecordList
  • GET {{localURL}}/api/Currency/GetRecordList

Core rules

Defaults

Use AutoCount defaults where supported:

  • DocNo: "\x3C\x3C\x3CDefault>>>"
  • DocNoFormatName: "\x3C\x3C\x3CDefault>>>"
  • DebtorName: "\x3C\x3C\x3CDefault>>>" when not enriching from master data
  • DisplayTerm: "\x3C\x3C\x3CDefault>>>"
  • CurrencyCode: "\x3C\x3C\x3CDefault>>>"
  • address/phone/attention fields may also accept \x3C\x3C\x3CDefault>>>
  • TaxCode: "\x3C\x3C\x3CDefault>>>" is preferred over manually forcing a tax code

Draft option

"Options": {
  "DocNoFormatName": "\x3C\x3C\x3CDefault>>>",
  "SaveAsDraft": true
}

Reporting rule

After a successful create:

  1. capture the returned docKey
  2. call the matching GetRecord endpoint
  3. report back at least:
    • DocNo
    • DocKey
    • party code/name
    • total/final total

Sales invoice pattern

Minimal stable sales invoice template

{
  "Master": {
    "DocNo": "\x3C\x3C\x3CDefault>>>",
    "DocDate": "2026-03-27",
    "DebtorCode": "SS29",
    "DebtorName": "\x3C\x3C\x3CDefault>>>",
    "SalesLocation": "HQ",
    "DisplayTerm": "\x3C\x3C\x3CDefault>>>",
    "CurrencyCode": "\x3C\x3C\x3CDefault>>>"
  },
  "Details": [
    {
      "ItemCode": "00001",
      "UOM": "METER",
      "UserUOM": "\x3C\x3C\x3CDefault>>>",
      "Location": "HQ",
      "Description": "\x3C\x3C\x3CDefault>>>",
      "Qty": 2,
      "UnitPrice": 22.22,
      "TaxCode": "\x3C\x3C\x3CDefault>>>",
      "Classification": "010",
      "OriginCountryCode": "MYS"
    }
  ],
  "Options": {
    "DocNoFormatName": "\x3C\x3C\x3CDefault>>>",
    "SaveAsDraft": true
  }
}

Purchase-side pattern

Purchase documents use a similar body shape to sales invoices, but with purchase-side party/location fields.

Purchase invoice template

{
  "Master": {
    "DocNo": "\x3C\x3C\x3CDefault>>>",
    "CreditorCode": "400-S001",
    "CreditorName": "SUPPLIER",
    "PurchaseLocation": "HQ",
    "DocDate": "2026-03-27",
    "Description": "PURCHASE INVOICE",
    "DisplayTerm": "C.O.D.",
    "CurrencyCode": "MYR",
    "CurrencyRate": 1
  },
  "Details": [
    {
      "DeliveryDate": "2026-03-27",
      "ItemCode": "00002",
      "UOM": "SET",
      "UserUOM": "SET",
      "Location": "HQ",
      "Description": "SOFA 沙发",
      "Qty": 10,
      "FOCQty": 0,
      "UnitPrice": 1000,
      "Discount": "",
      "TaxCode": "\x3C\x3C\x3CDefault>>>"
    }
  ],
  "Options": {
    "DocNoFormatName": "\x3C\x3C\x3CDefault>>>",
    "SaveAsDraft": true
  }
}

Goods received note template

{
  "Master": {
    "DocNo": "\x3C\x3C\x3CDefault>>>",
    "SupplierDONo": "AUTO-GRN-20260327-01",
    "CreditorCode": "400-S001",
    "CreditorName": "SUPPLIER",
    "PurchaseLocation": "HQ",
    "DocDate": "2026-03-27",
    "Description": "GOODS RECEIVED NOTE",
    "DisplayTerm": "C.O.D.",
    "CurrencyCode": "MYR",
    "CurrencyRate": 1
  },
  "Details": [
    {
      "DeliveryDate": "2026-03-27",
      "ItemCode": "00002",
      "UOM": "SET",
      "UserUOM": "SET",
      "Location": "HQ",
      "Description": "SOFA 沙发",
      "Qty": 10,
      "FOCQty": 0,
      "UnitPrice": 1000,
      "Discount": "",
      "TaxCode": "\x3C\x3C\x3CDefault>>>"
    }
  ],
  "Options": {
    "DocNoFormatName": "\x3C\x3C\x3CDefault>>>",
    "SaveAsDraft": true
  }
}

SO → DO → Invoice guidance

Use this when the user wants sales document progression.

  1. Create or inspect a final Sales Order first.
  2. For transfer source documents, ensure the source is final, not draft.
  3. For transfer creates, use transfer-only payloads:
    • set Details: []
    • populate TransferDetails[]
    • do not include a matching manual detail row
  4. SO → DO transfer:
    • POST /api/DeliveryOrder/CreateRecord
    • TransferDetails[].DocType = "SO"
  5. DO → Invoice transfer:
    • POST /api/Invoice/CreateRecord
    • TransferDetails[].DocType = "DO"
  6. Use SalesLocation on invoice payloads and sales-side master payloads where appropriate.
  7. Set DocNo: "\x3C\x3C\x3CDefault>>>" and DocNoFormatName: "\x3C\x3C\x3CDefault>>>".
  8. Use TaxCode: "\x3C\x3C\x3CDefault>>>" unless the system proves a specific value.
  9. Fetch created records and report the final document numbers.

Proven live sales chain

A full sales chain was live-tested successfully:

  • Sales Order → Delivery Order using DocType: "SO"
  • Delivery Order → Invoice using DocType: "DO"

PO → GRN → PI guidance

Use this when the user wants purchase document progression.

  1. List purchase orders with:
    • POST /api/PurchaseOrder/GetRecordList and body {}
  2. Inspect a specific PO with:
    • GET /api/PurchaseOrder/GetRecord?docKey=...
  3. For transfer source documents, ensure the source is final, not draft.
  4. For transfer creates, use transfer-only payloads:
    • set Details: []
    • populate TransferDetails[]
    • do not include a matching manual detail row, or AutoCount may create an extra unlinked line
  5. PO → GRN transfer:
    • POST /api/GoodsReceivedNote/CreateRecord
    • TransferDetails[].DocType = "PO"
  6. GRN → PI transfer:
    • POST /api/PurchaseInvoice/CreateRecord
    • TransferDetails[].DocType = "GR"
  7. Direct PO → PI transfer is also supported on a fresh final PO:
    • TransferDetails[].DocType = "PO"
  8. Add GRN-specific SupplierDONo when creating GRNs.
  9. Set DocNo: "\x3C\x3C\x3CDefault>>>" and DocNoFormatName: "\x3C\x3C\x3CDefault>>>".
  10. Use TaxCode: "\x3C\x3C\x3CDefault>>>" unless the system proves a specific value.
  11. Fetch created records and report the final document numbers.

Transfer payload rule

Use this pattern for transfer documents:

{
  "Master": {
    "DocNo": "\x3C\x3C\x3CDefault>>>",
    "DocDate": "2026-04-09",
    "CreditorCode": "400-S001",
    "CreditorName": "\x3C\x3C\x3CDefault>>>",
    "PurchaseLocation": "HQ",
    "DisplayTerm": "\x3C\x3C\x3CDefault>>>",
    "CurrencyCode": "\x3C\x3C\x3CDefault>>>",
    "CurrencyRate": "\x3C\x3C\x3CDefault>>>"
  },
  "Details": [],
  "TransferDetails": [
    {
      "DocType": "PO",
      "DocNo": "PO-000038",
      "ItemCode": "00002",
      "UOM": "SET",
      "TransferQty": 5,
      "TransferFOCQty": 0
    }
  ],
  "Options": {
    "DocNoFormatName": "\x3C\x3C\x3CDefault>>>",
    "SaveAsDraft": false
  }
}

Swap DocType as follows:

  • PO for PO → GRN
  • PO for PO → PI
  • GR for GRN → PI
  • SO for SO → DO
  • DO for DO → Invoice

Proven live chain

A full purchase chain was live-tested successfully:

  • Purchase Order → GRN using DocType: "PO"
  • GRN → Purchase Invoice using DocType: "GR"

Balance and over-transfer notes

AutoCount tracks transfer quantity at table level even when the normal PO API does not expose it. Observed relevant DB fields include:

  • PODTL.Qty
  • PODTL.TransferedQty
  • PODTL.Transferable
  • PIDTL.FromDocType
  • PIDTL.FromDocNo

Working balance formula:

  • remaining transferable qty = Qty - TransferedQty

Important: the standard PurchaseOrder/GetRecord API response did not expose TransferedQty, so automation should not assume the API will prevent over-transfer. Validate quantities before transfer when possible.

Update / cancel / delete safety

Treat these as real mutations.

  1. Prefer testing update/cancel/delete only on fresh test documents unless the user clearly requests mutation on a real document.
  2. UpdateRecord expects a clean create-style payload more often than a raw GetRecord echo.
  3. CancelRecord and DeleteRecord are destructive.
  4. After cancel/delete, a later GetRecord may return record-not-found.
  5. Always report the exact affected DocNo and DocKey back to the user.

Confirmed live mutation routes

For Credit Note, the following worked in live testing:

  • POST /api/CreditNote/UpdateRecord?docKey=...
  • POST /api/CreditNote/CancelRecord?docKey=...
  • POST /api/CreditNote/DeleteRecord?docKey=...

Observed behavior:

  • update changed quantity and total successfully
  • cancel returned true
  • after cancel/delete testing, GetRecord returned record-not-found for the test document

Enrichment guidance

Before document creation, optionally fetch master data and copy display fields into the payload.

Sales enrichment

  • DebtorName
  • InvAddr1..4
  • Phone1
  • Attention
  • DisplayTerm
  • CurrencyCode

Purchase enrichment

  • CreditorName
  • supplier-related address/contact fields if available
  • DisplayTerm
  • CurrencyCode

Item enrichment

  • Description
  • valid UOM
  • location-aware stock hints

This makes the final document more complete in the AutoCount UI.

Known findings from testing

  • AutoCount Web API was reachable on port 9999 over HTTP in the tested environment.
  • Root URL returned 404, which is normal for the service.
  • Authentication uses headers, not curl basic auth:
    • X-API-NAME
    • X-API-KEY
  • Sales order create/get worked.
  • Delivery order create/get worked.
  • Sales invoice create/get worked repeatedly.
  • Credit note create/get worked.
  • Credit note update worked.
  • Credit note cancel worked.
  • Credit note delete route worked and the test document became non-retrievable afterward.
  • Purchase invoice create worked.
  • GRN create worked.
  • Purchase order create worked.
  • Purchase order update worked when using a clean create-style payload against UpdateRecord?docKey=....
  • PO list requires POST {} instead of GET.
  • PO get worked with valid doc keys.
  • Updating a draft PO with SaveAsDraft: false did not reliably convert it into a final transferable PO in UI testing; creating a fresh final PO was reliable.
  • Transfer source docs must be final, not draft.
  • For transfer documents, Details: [] plus TransferDetails[] worked; mixing Details[] with TransferDetails[] created an extra unlinked manual line.
  • TransferDetails[].DocType values confirmed in live testing:
    • PO for PO → GRN
    • PO for PO → PI
    • GR for GRN → PI
  • GRN as a purchase invoice transfer doc type failed with Invalid transfer document.
  • A full live chain succeeded: PO → GRN → PI.
  • A full live chain succeeded: SO → DO → Invoice.
  • Lean payloads can create documents, but UI-visible debtor/item display fields may remain blank unless explicitly enriched.
  • Item 00001 worked repeatedly in sales invoices with:
    • description: FABRIC
    • UOM: METER
    • origin country: MYS
  • Item list response does not necessarily expose tax code fields.
  • Do not manually force tax codes unless explicitly instructed or proven from system data.
  • Using TaxCode: "\x3C\x3C\x3CDefault>>>" worked and is preferred.
  • GRN create initially failed when DocNo was missing; adding DocNo: "\x3C\x3C\x3CDefault>>>" fixed it.
  • Sales invoice route is /api/Invoice/CreateRecord, not /api/SalesInvoice/CreateRecord.
  • Sales transfer doc types confirmed in live testing:
    • SO for SO → DO
    • DO for DO → Invoice

References

Read references/test-notes.md for the observed behavior and payload patterns discovered during live testing.

Usage Guidance
This skill appears to be what it says — a helper for talking to an AutoCount Web API — but there are two practical concerns you should resolve before installing or using it: (1) the SKILL.md requires an API name and API key (X-API-NAME and X-API-KEY) but the skill metadata does not declare any required credentials. Ask the publisher why required credentials are not declared and whether the skill will request/store them. (2) Example traffic uses plain HTTP on port 9999; if you point this skill at a remote or untrusted host your API keys and document data could be sent in cleartext. Only use it against endpoints you control or that support HTTPS. If the publisher can update metadata to list the required env vars (or explain why they are omitted) and confirm TLS support, this would reduce the concern. Also verify you trust the endpoint and that the agent will not be asked to transmit unrelated secrets or sensitive files.
Capability Analysis
Type: OpenClaw Skill Name: autocount Version: 1.0.0 The AutoCount skill bundle (SKILL.md, _meta.json, and references/test-notes.md) is a legitimate tool designed to automate business document workflows, such as sales and purchase invoices, via the AutoCount Web API. The instructions in SKILL.md provide detailed JSON templates, verified endpoints, and safety guidelines (e.g., preferring draft mode and reporting all mutations) that align perfectly with the stated purpose of ERP integration. No indicators of data exfiltration, malicious execution, or harmful prompt injection were found.
Capability Tags
cryptocan-make-purchases
Capability Assessment
Purpose & Capability
The SKILL.md clearly targets AutoCount Web API endpoints and the described endpoints and payloads are consistent with the stated purpose. However, the skill metadata lists no required credentials or primaryEnv while the instructions explicitly require an API name and API key (X-API-NAME and X-API-KEY). That discrepancy is incoherent with how an API integration normally declares required credentials.
Instruction Scope
Runtime instructions are narrowly focused on building and submitting AutoCount document payloads and then fetching created records. They do not instruct reading arbitrary local files or other unrelated credentials. One operational issue: examples and the referenced test notes use HTTP on port 9999 (no TLS), meaning API keys would be sent in cleartext if the base URL is not secured — a network security concern but not scope creep.
Install Mechanism
This is an instruction-only skill with no install spec and no code files, so nothing is written to disk or downloaded during install — low install risk.
Credentials
The SKILL.md requires API credentials (X-API-NAME and X-API-KEY) to operate but the registry metadata lists no required environment variables or primary credential. That mismatch means the skill might prompt the user for secrets at runtime or rely on ad-hoc input rather than declaring them up-front, which reduces transparency. The examples also imply use of HTTP (insecure) which exacerbates the risk of credential exposure.
Persistence & Privilege
The skill does not request always:true, has no install steps, and does not ask to modify other skills or system settings. It appears to run only when invoked, which is appropriate for its purpose.
How to Use
  1. Make sure OpenClaw is installed (local or Docker)
  2. Run the install command in chat: /install autocount
  3. After installation, invoke the skill by name or use /autocount
  4. Provide required inputs per the skill's parameter spec and get structured output
Version History
v1.0.0
Initial public release
Metadata
Slug autocount
Version 1.0.0
License MIT-0
All-time Installs 0
Active Installs 0
Total Versions 1
Frequently Asked Questions

What is AutoCount?

Create and validate AutoCount business documents through AutoCount Web API. Use when the user wants to create or test sales invoices, purchase invoices, good... It is an AI Agent Skill for Claude Code / OpenClaw, with 95 downloads so far.

How do I install AutoCount?

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

Is AutoCount free?

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

Which platforms does AutoCount support?

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

Who created AutoCount?

It is built and maintained by teckyuen (@teckyuen); the current version is v1.0.0.

💬 Comments