Skip to content
Back to skills

Invoice Housekeeping

ASecurity

Clean up Fawaterak invoices — list, cancel stale unpaid ones, refund paid ones

  • 29 stars
  • 0 votes
  • 0 copies
  • 1 view
  • Added September 20, 2026
ai-agentsgoapi

Works with

  • api

Security analysis

A100/100

Scanned September 20, 2026

npx -y skills add theYahia/WWmcp --skill invoice-housekeeping --agent claude-code

Installs into .claude/skills of the current project.

Are you the author of Invoice Housekeeping?

Add the live security badge to your README. It updates with every re-scan.

Security grade badge for Invoice Housekeeping
[![Security: A — Skills Directory](https://www.skillsdirectory.com/api/skills/theyahia-invoice-housekeeping/badge)](https://www.skillsdirectory.com/skills/theyahia-invoice-housekeeping)

More formats (shields.io, HTML) on the badges page. Keep it an A: scan every change in CI with Pro.

Download with Pro
SKILL.md
---
name: invoice-housekeeping
description: Clean up Fawaterak invoices — list, cancel stale unpaid ones, refund paid ones
argument-hint: "[status paid|unpaid|expired|cancelled]"
---

# /invoice-housekeeping — Invoice cleanup and refunds

## Algorithm

1. Call `list_invoices` with page, per_page and status (paid | unpaid | expired | cancelled).
   Start with unpaid to find stale checkouts.
2. Page through until the list is exhausted. Do not report a total you have not paged to.
3. For anything ambiguous, call `get_invoice_data` with its invoice_id for the full record
   (amount, method, transaction_id, customer).
4. To cancel: `cancel_invoice` with invoice_id. This only works on unpaid invoices — check
   status first, and confirm with the user before cancelling anything.
5. To refund: `refund_payment` with invoice_id, optional amount (omit for full refund) and
   optional reason. Refund support depends on the rail — a Fawry cash payment may not be
   refundable through the API. Report the error as-is rather than retrying blindly.
6. Call `get_balance` at the end so the user sees the account position after the cleanup.

## Response format

```
## Fawaterak housekeeping

**Balance**: 18,420 EGP

### Unpaid over 48 h — 6 invoices, 3,100 EGP
| Invoice | Amount | Created | Action |
|---------|--------|---------|--------|
| 88101 | 450 EGP | 2026-08-30 | cancelled |

### Refunds issued
| Invoice | Amount | Reason | Status |
|---------|--------|--------|--------|
| 88044 | 200 EGP | partial return | success |
```

## Notes

- Always confirm before `cancel_invoice` or `refund_payment` — neither is reversible.
- Partial refund = pass amount. Full refund = omit amount entirely.
- `get_balance` reflects settled money; a just-issued refund may not be deducted yet.

## Examples

```
/invoice-housekeeping unpaid
/invoice-housekeeping refund 88044 200 "partial return"
```

Attribution

Is this your skill, or is something wrong with this listing? Request removal or report an issue. Author removals are honored within 72 hours.

Comments

Loading comments…

Newsletter

Get the weekly list of safe new skills, and the ones we pulled.