Wenche.Aarsregnskap (wenche v0.1.1)

Copy Markdown View Source

Annual accounts submission to Brønnøysundregistrene via Altinn 3.

Ported from wenche/aarsregnskap.py in the original Python Wenche project.

Handles config reading, validation, and submission of annual accounts.

Summary

Functions

Reads a config.yaml file and returns an Aarsregnskap struct.

Submits the annual accounts to Brønnøysundregistrene via Altinn.

Validates the accounts and returns a list of error messages.

Functions

les_config(config_fil)

Reads a config.yaml file and returns an Aarsregnskap struct.

Returns {:ok, aarsregnskap} or {:error, reason}.

send_inn(regnskap, client, opts \\ [])

Submits the annual accounts to Brønnøysundregistrene via Altinn.

Options

  • :dry_run — if true, writes XML files locally without sending to Altinn (default: false)

Returns {:ok, inbox_url} or {:error, reason}.

valider(regnskap)

Validates the accounts and returns a list of error messages.

Empty list means OK.