doc-doctor
Skill0 starsChanged 3 months agoMITView on GitHub
Diagnose and fix stuck or erroring Acumatica transactional documents - purchase orders that will not receive, totals that look wrong, documents stuck on hold or in the wrong status. Use when someone reports a document problem by number (for example PO P010001 will not receive, or bill 010001 total is off), when a PO shows Completed but still has open quantity, when a receipt will not convert to a bill, or when asked why a document is stuck, blocked, or cannot be released. Pulls the document, its lines, and related documents, runs a rules-based diagnosis, explains the root cause in plain language, and proposes the corrective action. Read-only by default - any write (reopen, uncheck a line Completed flag, release, hold) is previewed and applied only after explicit confirmation.
1 other project uses a version of this.
Adopted by
Most recently taken up by
- jongio/skillstheir own version, first seen Nov 1, 2026
Other versions1 project uses a version of this.
Word for word · 0
None found.
Edited · 0
None found.
Wrote their own version · 1
- jongio/skills★ 18same name
How matches are found. Word for word: the exact same text. Edited: shares passages with this file (“99% same” means 99% of its five-word phrases also appear here; 10% or more counts). Their own version: similar meaning, or, weakest, the same name. We can’t tell which project had it first. Projects are counted among the 200 most-starred candidates, and mentions are links to the repository we found, up to 50 per site, so both counts are a floor.
In this repository5 other files it gives its agents.
- CLAUDE.mdCLAUDE.md
- ap-healthSkill
- ar-healthSkill
- recent-recordsSkill
- three-way-matchSkill
The file
We split this skill into the rules it gives an agent
6 rules. About 0 are common, 2 are distinctive, and 4 are very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈2
Distinctive · estimate
This author's own choices. Worth a look.
4
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Very specific: line 16
Always render the document number as a Markdown link using the browser_url field returned.
- Very specific: line 41
CompleteOnthreshold reached: - when QtyOnReceipts >= OrderQty * CompleteOn/100 the line auto-completes. - Distinctive: line 57
If the API rejects the line edit because the order is Completed/Closed, the order has to be reopened in the UI first (PO301000 -> Actions) …
- Very specific: line 66
If LineTotal/OrderTotal reconcile to the lines but a "Detail Total" differs -> it is the stale stored display value, not a data error.
- Very specific: line 68
If ControlTotal != OrderTotal, the document will not release until they match - surface the delta.
- Distinctive: line 110
Never write without showing the before/after and getting a yes.
≈ “Common” is an estimate: at least 1 in 5 of the 350,495 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
Acumatica - Document Doctor
Diagnose why a transactional document is stuck or wrong, then propose the fix. This is the tool for the "can you look at PO P0xxxxx?" requests - receive failures, total mismatches, on-hold/blocked docs.
⚠️ Known tenant behaviour
$orderbyis silently ignored - sort client-side.- Date filters need
datetimeoffset'YYYY-MM-DDTHH:MM:SS-04:00'literals. $select/$filterfield names must match exactly or you get a hard 500.- Always render the document number as a Markdown link using the
browser_urlfield returned.
How to run a diagnosis
- Identify the entity from the document number prefix when not stated:
P-> PurchaseOrder,R-> PurchaseReceipt, numeric AP ref (e.g.010001) -> Bill,O/I/QT-> SalesOrder, transfers/issues by ReferenceNbr. - Pull the document with its lines:
get_record(entity, id, expand="Details"). Key formats: PurchaseOrderType/OrderNbr(Type is usuallyNormal); PurchaseReceiptType/ReceiptNbr; BillType/ReferenceNbr(TypeBill); SalesOrderOrderType/OrderNbr; TransferOrder / InventoryIssue singleReferenceNbr. - Run the matching playbook below.
- Report: root cause in plain language -> the exact field(s) that prove it -> the proposed fix.
- Only write after the user confirms. Show the before/after first.
Playbook - PurchaseOrder will not receive ⭐ most common
Header fields: Type, OrderNbr, Status, Hold, VendorID, OrderTotal, LineTotal, ControlTotal, Date.
Line (Details) fields: LineNbr, InventoryID, OrderQty, QtyOnReceipts, Completed, Cancelled,
CompleteOn, MinReceiptPercent, MaxReceiptPercent, ReceiptAction, UnitCost, ExtendedCost, WarehouseID.
Check, in order:
- Line
Completed= true whileQtyOnReceipts < OrderQty-> the line was auto/ manually completed and is closed to further receipt. This is the classic "Status Completed, can't receive" case. Fix: reopen the PO and set the lineCompletedback tofalse(uncheck Completed per line). CompleteOnthreshold reached - whenQtyOnReceipts >= OrderQty * CompleteOn/100the line auto-completes. If they need to receive past it, the line must be reopened.- Line
Cancelled= true -> line was cancelled; cannot receive. Needs re-add, not reopen. - Header
Status=Completed/Closed-> reopen the order before any line will accept receipt. - Header
Hold= true -> on hold; remove hold first. MaxReceiptPercentlimits over-receipt;ReceiptActionshows the over-receipt policy.
Open qty per line = OrderQty - QtyOnReceipts. Report which line(s) block receiving.
Proposed fix (preview, confirm before applying):
upsert_record(entity="PurchaseOrder", entity_record={
"Type": {"value":"Normal"}, "OrderNbr": {"value":"P0xxxxx"},
"Details": [{"LineNbr": {"value": 1}, "Completed": {"value": false}}]
})If the API rejects the line edit because the order is Completed/Closed, the order has to be reopened in the UI first (PO301000 -> Actions) - say so plainly rather than forcing it.
Playbook - total looks wrong (PO/SO detail-total mismatch)
The PO/SO header carries OrderTotal (and LineTotal, ControlTotal). A "Detail Total" shown in the
UI can be a stored value that does not recalc when a unit cost is changed, so it shows the original
price while LineTotal/OrderTotal are correct and are what actually drive the document.
- Recompute from lines:
sum(ExtendedCost)should equalLineTotal. - If
LineTotal/OrderTotalreconcile to the lines but a "Detail Total" differs -> it is the stale stored display value, not a data error. State this; no write needed. - If
ControlTotal!=OrderTotal, the document will not release until they match - surface the delta.
Playbook - PurchaseReceipt will not convert to a Bill
Header: Status, Hold, CreateBill, UnbilledQuantity, TotalQty, TotalCost, VendorID, Type.
StatusnotReleased-> release the receipt first (ReleasePurchaseReceipt).UnbilledQuantity= 0 -> already fully billed; nothing to convert.Hold= true -> remove hold.- Otherwise create the bill via
invoke_action(entity="PurchaseReceipt", action="CreateAPBill", ...).
Playbook - Bill stuck / will not release
Header: Status, Hold, ApprovedForPayment, Balance, Amount, DueDate, Vendor, Type.
Line (Details): Amount, Qty, UnitCost, ExtendedCost, Account, POOrderNbr, POReceiptNbr.
Status = Pending Approval-> needs approval; not an error.Hold = true-> on hold.Status = Balancedbut unreleased -> release withReleaseBill.- Amount != sum of line
Amount-> line/tax imbalance; show the delta.
Playbook - SalesOrder stuck
Header: OrderType, OrderNbr, Status, Hold, Date. Common blocks: Status = Credit Hold
(use ReleaseFromCreditHoldSalesOrder), On Hold (remove hold), Back Order (insufficient
allocation/stock). Expand Details to see line allocation.
TransferOrder / InventoryIssue
Header: Status, Hold, ReferenceNbr (+ FromWarehouseID/ToWarehouseID for transfers). Usual block
is Status not Released or Hold = true; release with ReleaseTransferOrder /
ReleaseInventoryIssue after confirming.
Output format
Document: [P0xxxxx](browser_url) - PurchaseOrder, Status=Open, Hold=No
Problem: Line 1 cannot receive.
Cause: Line 1 Completed=true with QtyOnReceipts 2 of OrderQty 5 (3 still open).
Fix: Reopen the PO and set Line 1 Completed=false. Preview of the change is below.Tips
- Never write without showing the before/after and getting a yes.
- Pull
expand="Details"for any receive/total/match question - the answer is almost always at line level. - For "who changed this / when", add
custom="Document.LastModifiedByID,Document.CreatedByID"(see also a change-audit skill if present).
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

