home / skills / openclaw / skills / akaunting

akaunting skill

/skills/liekzejaws/akaunting

This skill helps you manage accounting tasks by integrating with Akaunting via REST API to create invoices, track income, and automate bookkeeping.

npx playbooks add skill openclaw/skills --skill akaunting

Review the files below or copy the command above to add this skill to your agents.

Files (6)
SKILL.md
3.0 KB
---
name: akaunting
description: Interact with Akaunting open-source accounting software via REST API. Use for creating invoices, tracking income/expenses, managing accounts, and bookkeeping automation. Triggers on accounting, bookkeeping, invoicing, expenses, income tracking, or Akaunting mentions.
---

# Akaunting Skill

CLI and API integration for Akaunting, a free open-source accounting platform.

## Quick Start

```bash
# Test connection
akaunting ping

# List data
akaunting accounts
akaunting categories  
akaunting transactions

# Create transactions
akaunting income --amount 100 --category Sales --description "Payment received"
akaunting expense --amount 50 --category Other --description "Office supplies"
```

## Setup

### 1. Deploy Akaunting

```bash
# Use the provided docker-compose
cp skills/akaunting/assets/docker-compose.yml ~/akaunting/
cd ~/akaunting && docker compose up -d
```

Access web UI at `http://YOUR_IP:8080` and complete the setup wizard.

### 2. Apply Required Fix

**Critical:** Akaunting has a bug where module event listeners don't auto-register. Run:

```bash
python3 skills/akaunting/scripts/fix_event_listener.py
```

Or manually add to `/var/www/html/app/Providers/Event.php` in the `$listen` array:

```php
'App\Events\Module\PaymentMethodShowing' => [
    'Modules\OfflinePayments\Listeners\ShowAsPaymentMethod',
],
```

### 3. Configure Credentials

```bash
mkdir -p ~/.config/akaunting
cat > ~/.config/akaunting/config.json << EOF
{
  "url": "http://YOUR_IP:8080",
  "email": "[email protected]",
  "password": "your-password"
}
EOF
```

Or set environment variables: `AKAUNTING_URL`, `AKAUNTING_EMAIL`, `AKAUNTING_PASSWORD`

## CLI Commands

| Command | Description |
|---------|-------------|
| `akaunting ping` | Test API connection |
| `akaunting accounts` | List bank accounts |
| `akaunting categories [--type income\|expense]` | List categories |
| `akaunting transactions [--type income\|expense]` | List transactions |
| `akaunting items` | List products/services |
| `akaunting income --amount X --category Y` | Create income |
| `akaunting expense --amount X --category Y` | Create expense |
| `akaunting item --name X --price Y` | Create item |

Add `--json` to any command for JSON output.

## API Reference

See `references/api.md` for full endpoint documentation.

### Key Endpoints

- `GET /api/ping` - Health check
- `GET/POST /api/accounts` - Bank accounts
- `GET/POST /api/categories` - Income/expense categories
- `GET/POST /api/transactions` - Income/expense records
- `GET/POST /api/items` - Products/services

Authentication: HTTP Basic Auth with user email/password. User needs `read-api` permission (Admin role has this by default).

## Troubleshooting

**"Payment method is invalid" error:**
The event listener fix wasn't applied. Run `fix_event_listener.py`.

**401 Unauthorized:**
Check credentials in config.json. User must have API access permission.

**403 Forbidden on contacts/documents:**
User needs additional permissions for these endpoints.

Overview

This skill integrates with Akaunting open-source accounting software via its REST API to automate invoicing, income and expense tracking, account management, and basic bookkeeping tasks. It provides CLI-like commands and API calls to list accounts, categories, transactions, and items, and to create income, expenses, and items programmatically. Use it to connect systems, run health checks, and automate routine accounting workflows.

How this skill works

The skill authenticates to Akaunting using HTTP Basic Auth (email/password) and calls key endpoints like /api/ping, /api/accounts, /api/categories, /api/transactions, and /api/items. It maps common bookkeeping actions to simple operations: list resources, create income/expense transactions, and manage products/services. Commands support JSON output for easy scripting and integration into automation pipelines.

When to use it

  • Automate invoice creation and recurring income records from other systems.
  • Import or export transactions and account lists for backups or analytics.
  • Validate Akaunting installation health and API connectivity programmatically.
  • Create or update product/service items from inventory or e-commerce systems.
  • Run scripted expense entry for batch receipts or reimbursements.

Best practices

  • Ensure the API user has read-api permission (Admin role grants this by default) to avoid authorization errors.
  • Store credentials securely: use the config file at ~/.config/akaunting/config.json or environment variables AKAUNTING_URL, AKAUNTING_EMAIL, AKAUNTING_PASSWORD.
  • Apply the event listener fix if deploying Akaunting from the provided containers; a missing listener causes payment method errors.
  • Use --json output in automated scripts to parse responses reliably and handle errors gracefully.
  • Limit operations in production: test transactions in a staging instance before running bulk imports on live data.

Example use cases

  • Health check script that calls GET /api/ping and alerts on failures.
  • Daily import job that reads bank CSVs and creates corresponding income/expense transactions.
  • Sync product catalog from an e-commerce platform into Akaunting via POST /api/items.
  • Automated expense ingestion: scan receipts, classify categories, and create expense records via the transactions endpoint.
  • Bulk create customers or contacts (where permission allows) and then issue invoices programmatically.

FAQ

What credentials does the skill need?

It uses HTTP Basic Auth with an Akaunting user email and password. The user needs API access (read-api permission). Use the config file or environment variables to supply credentials.

I see 'Payment method is invalid'—what should I do?

That indicates the Akaunting event listener bug. Run the provided fix_event_listener.py script or add the missing listener to the app/Providers/Event.php $listen array to resolve it.