Wenmar Pro Ledger API

The general ledger: entries, settings and the lock date

GitHub OpenAPI
Pull this API's OpenAPI, operations, scores and pricing into your own code or AI agent with a free APIs.io key — sign in with GitHub, Google or LinkedIn. No form to fill in; signing in shares your email address with us (Privacy).

Operations 11

GET /ledger/entries Ledger entries index #
POST /ledger/entries Ledger entries create #
GET /ledger/entries/{id} Ledger entries show #
POST /ledger/entries/{id}/reverse Ledger entries reverse #
POST /ledger/import Ledger import #
PUT /ledger/lock Ledger lock #
GET /ledger/package Ledger package #
POST /ledger/post Ledger post #
POST /ledger/send_package Ledger send package #
GET /ledger/settings Ledger settings show #
PATCH /ledger/settings Ledger settings update #

Work with this as data

Every API here is available over the APIs.io API and to AI agents over MCP.

MCP server

One button, every client — Claude, Cursor, VS Code and the rest.

https://apis.io/mcp

Tools for apis

7 MCP tools reach this
  • find_apisBrowse and filter every API in the catalog.
  • get_api_artifactsOne API's artifacts, grouped by type.
  • get_openapiThe primary OpenAPI for this API.
  • find_similar_apisAPIs that look like this one.
  • apis_io_searchSTART HERE — APIs, providers and tags for one query, each with its total.
  • resolveTurn a domain, URL or GitHub org into the provider it belongs to.
  • find_cohortsEvery scored population of providers in the catalog.
All 92 tools →

Call it yourself

curl for this page
This API
curl "https://apis.io/api/v1/apis/wenmarpro-com:wenmarpro-com-ledger-api"
All apis
curl "https://apis.io/api/v1/apis?limit=25"

Calls without X-API-Key need no key. Calls with it need a paid plan — get a key.

Get an API key

Free tier, no form to fill in. Signing in shares your email address with us — we store it to create your key and to recognise you if you sign in with another provider. By signing up you are subscribing to the APIs.io and API Evangelist newsletters — you can unsubscribe from any issue. See our Privacy Policy and Terms.

A second provider on the same verified email joins the account you already have.

OpenAPI Specification

wenmarpro-com-ledger-api-openapi.yml Raw ↑
openapi: 3.2.0
info:
  description: 'The general ledger: entries, settings and the lock date'
  license:
    name: ''
  title: Wenmar Ledger API
  version: 0.1.0
tags:
- description: 'The general ledger: entries, settings and the lock date'
  name: Ledger
paths:
  /ledger/entries:
    get:
      operationId: ledger_entries_index
      parameters:
      - description: first entry date, YYYY-MM-DD
        in: query
        name: from
        required: false
        schema:
          type: string
      - description: last entry date, YYYY-MM-DD
        in: query
        name: to
        required: false
        schema:
          type: string
      - description: manual, adjusting, opening, invoice, receipt, bill, bill_payment, stock_adjustment, payroll or payroll_remittance
        in: query
        name: source_kind
        required: false
        schema:
          type: string
      - description: only entries with a line on this account
        in: query
        name: account
        required: false
        schema:
          type: string
      - description: 1-100, default 50
        in: query
        name: limit
        required: false
        schema:
          format: int64
          type: integer
      - description: rows to skip
        in: query
        name: offset
        required: false
        schema:
          format: int64
          type: integer
      responses:
        '200':
          content:
            application/json:
              schema:
                type: object
          description: '`{data, total, next_offset}`: entries newest date first, each with its lines (amount_cents signed, debit +; debit_cents, credit_cents)'
        '401':
          description: unauthenticated
        '403':
          description: forbidden (needs reports.view)
        '422':
          description: 'validation_failed: from, to, source_kind'
      security:
      - bearer: []
      tags:
      - Ledger
      summary: Ledger entries index
      x-summary-source: derived
    post:
      operationId: ledger_entries_create
      requestBody:
        content:
          application/json:
            schema:
              properties:
                entry_date:
                  default: ''
                  description: The entry's date, YYYY-MM-DD; must be after the lock date
                  type: string
                kind:
                  default: null
                  description: manual (default), adjusting (from the accountant) or opening (balances when the books begin)
                  type:
                  - string
                  - 'null'
                lines:
                  default: []
                  description: Two or more lines whose debits equal their credits
                  items:
                    properties:
                      account_number:
                        default: ''
                        description: The account number (chart of accounts)
                        type: string
                      credit_cents:
                        default: 0
                        description: Cents credited; give a debit or a credit, not both
                        format: int64
                        type: integer
                      debit_cents:
                        default: 0
                        description: Cents debited; give a debit or a credit, not both
                        format: int64
                        type: integer
                      memo:
                        default: ''
                        description: At most 60 characters
                        type: string
                    type: object
                  type: array
                location_id:
                  default: null
                  description: The location the entry belongs to; absent = the whole account
                  format: int64
                  type:
                  - integer
                  - 'null'
                memo:
                  default: ''
                  description: What the entry is for; at most 120 characters
                  type: string
              type: object
        required: false
      responses:
        '200':
          content:
            application/json:
              schema:
                type: object
          description: the new entry with its lines
        '401':
          description: unauthenticated
        '403':
          description: forbidden (needs ledger.manage)
        '422':
          description: 'validation_failed: entry_date (locked), memo, kind, location_id, lines; idempotency_key_reused'
      security:
      - bearer: []
      tags:
      - Ledger
      summary: Ledger entries create
      x-summary-source: derived
  /ledger/entries/{id}:
    get:
      operationId: ledger_entries_show
      parameters:
      - description: entry id
        in: path
        name: id
        required: true
        schema:
          format: int64
          type: integer
      responses:
        '200':
          content:
            application/json:
              schema:
                type: object
          description: the entry with its lines and reversed_by_entry_id
        '401':
          description: unauthenticated
        '403':
          description: forbidden (needs reports.view)
        '404':
          description: no such entry
      security:
      - bearer: []
      tags:
      - Ledger
      summary: Ledger entries show
      x-summary-source: derived
  /ledger/entries/{id}/reverse:
    post:
      operationId: ledger_entries_reverse
      parameters:
      - description: the entry to reverse
        in: path
        name: id
        required: true
        schema:
          format: int64
          type: integer
      requestBody:
        content:
          application/json:
            schema:
              properties:
                entry_date:
                  default: ''
                  description: The reversal's date, YYYY-MM-DD; must be after the lock date
                  type: string
              type: object
        required: false
      responses:
        '200':
          content:
            application/json:
              schema:
                type: object
          description: the reversing entry
        '401':
          description: unauthenticated
        '403':
          description: forbidden (needs ledger.manage)
        '404':
          description: no such entry
        '409':
          description: 'conflict: already reversed, a reversal, or a posted document''s entry'
        '422':
          description: 'validation_failed: entry_date (locked)'
      security:
      - bearer: []
      tags:
      - Ledger
      summary: Ledger entries reverse
      x-summary-source: derived
  /ledger/import:
    post:
      operationId: ledger_import
      requestBody:
        content:
          application/json:
            schema:
              properties:
                csv:
                  default: ''
                  description: 'The CSV: the header entry,date,account,debit,credit,memo, then one row per entry line'
                  type: string
                dry_run:
                  default: true
                  description: true (the default) checks the file and writes nothing
                  type: boolean
              type: object
        required: false
      responses:
        '200':
          content:
            application/json:
              schema:
                type: object
          description: '`{entries, errors, written, dry_run, replayed}`: the entries read from the csv; with dry_run (the default) nothing is written'
        '401':
          description: unauthenticated
        '403':
          description: forbidden (needs ledger.manage)
        '422':
          description: 'validation_failed: csv (one problem per row, named in field_errors)'
      security:
      - bearer: []
      tags:
      - Ledger
      summary: Ledger import
      x-summary-source: derived
  /ledger/lock:
    put:
      operationId: ledger_lock
      requestBody:
        content:
          application/json:
            schema:
              properties:
                through:
                  default: null
                  description: Nothing may be posted on or before this date (YYYY-MM-DD). Null or absent removes the lock
                  type:
                  - string
                  - 'null'
              type: object
        required: false
      responses:
        '200':
          content:
            application/json:
              schema:
                type: object
          description: the settings with the new locked_through
        '401':
          description: unauthenticated
        '403':
          description: forbidden (needs ledger.manage)
        '422':
          description: 'validation_failed: through'
      security:
      - bearer: []
      tags:
      - Ledger
      summary: Ledger lock
      x-summary-source: derived
  /ledger/package:
    get:
      operationId: ledger_package
      parameters:
      - description: the first day of the period, YYYY-MM-DD
        in: query
        name: from
        required: true
        schema:
          type: string
      - description: the last day of the period, YYYY-MM-DD
        in: query
        name: to
        required: true
        schema:
          type: string
      responses:
        '200':
          content:
            application/zip:
              schema:
                items:
                  format: int32
                  minimum: 0
                  type: integer
                type: array
          description: 'the books for the period as one zip (application/zip): the trial balance, GIFI trial balance, ledger detail, income statement, balance sheet, PDFs, an adjusting-entries template, README.txt and manifest.json'
        '401':
          description: unauthenticated
        '403':
          description: forbidden (needs reports.view)
        '422':
          description: 'validation_failed: from, to'
      security:
      - bearer: []
      tags:
      - Ledger
      summary: Ledger package
      x-summary-source: derived
  /ledger/post:
    post:
      operationId: ledger_post
      responses:
        '200':
          content:
            application/json:
              schema:
                type: object
          description: '`{entries, documents, rejected, posted_at, skipped}`: what the posting sweep entered'
        '401':
          description: unauthenticated
        '403':
          description: forbidden (needs ledger.manage)
      security:
      - bearer: []
      tags:
      - Ledger
      summary: Ledger post
      x-summary-source: derived
  /ledger/send_package:
    post:
      operationId: ledger_send_package
      requestBody:
        content:
          application/json:
            schema:
              properties:
                from:
                  default: ''
                  description: The first day of the period, YYYY-MM-DD
                  type: string
                lock:
                  default: false
                  description: Also lock the books through `to`, so nothing in the period changes once the accountant has it
                  type: boolean
                to:
                  default: ''
                  description: The last day of the period, YYYY-MM-DD
                  type: string
              type: object
        required: false
      responses:
        '200':
          content:
            application/json:
              schema:
                type: object
          description: '`{job_id, event_id, to, locked_through, manifest}`: the package is requested for the accountant''s address (`job_id` is null: the worker queues the job from the event)'
        '401':
          description: unauthenticated
        '403':
          description: forbidden (needs ledger.manage)
        '422':
          description: 'validation_failed: from, to; no_accountant_email'
      security:
      - bearer: []
      tags:
      - Ledger
      summary: Ledger send package
      x-summary-source: derived
  /ledger/settings:
    get:
      operationId: ledger_settings_show
      responses:
        '200':
          content:
            application/json:
              schema:
                type: object
          description: fiscal_year_end_month, locked_through, accountant_email, package_schedule, posting_start, posted_at
        '401':
          description: unauthenticated
        '403':
          description: forbidden (needs reports.view)
      security:
      - bearer: []
      tags:
      - Ledger
      summary: Ledger settings show
      x-summary-source: derived
    patch:
      operationId: ledger_settings_update
      requestBody:
        content:
          application/json:
            schema:
              properties:
                accountant_email:
                  default: null
                  description: Where the accountant package is e-mailed; blank = nobody
                  type:
                  - string
                  - 'null'
                books_kept_in:
                  default: null
                  description: '`wenmar` (default) or `quickbooks`: where the shop keeps its books (plan 2540)'
                  type:
                  - string
                  - 'null'
                fiscal_year_end_month:
                  default: null
                  description: '1-12: the month the fiscal year ends in'
                  format: uint32
                  minimum: 0
                  type:
                  - integer
                  - 'null'
                package_schedule:
                  default: null
                  description: 'none, monthly, quarterly or yearly: when the accountant package is e-mailed on its own'
                  type:
                  - string
                  - 'null'
                posting_start:
                  default: null
                  description: 'YYYY-MM-DD: documents dated before it are never posted to the ledger; must be after the lock date'
                  type:
                  - string
                  - 'null'
                retained_earnings_account:
                  default: null
                  description: The account the prior years' earnings roll into on the balance sheet (1-10 characters, no blanks)
                  type:
                  - string
                  - 'null'
              type: object
        required: false
      responses:
        '200':
          content:
            application/json:
              schema:
                type: object
          description: the settings after the change
        '401':
          description: unauthenticated
        '403':
          description: forbidden (needs ledger.manage)
        '422':
          description: 'validation_failed: fiscal_year_end_month, accountant_email, package_schedule, posting_start'
      security:
      - bearer: []
      tags:
      - Ledger
      summary: Ledger settings update
      x-summary-source: derived
components:
  securitySchemes:
    bearer:
      scheme: bearer
      type: http