Skip to main content

Troubleshooting & Operations of Winvoice Agent

This guide helps system administrators and IT personnel monitor, troubleshoot, and maintain the Winvoice Agent in production environments.


Checking Agent Connection Status​

In the Winvoice Web Interface​

  1. Log in to app.winvoice.se as an administrator.
  2. Navigate to Settings -> Integrations -> Winvoice Agent.
  3. Review the status box:
    • Green Indicator (Online): The agent sends heartbeat signals and is active. The Last Contact timestamp updates every 60 seconds.
    • Red Indicator (Offline): No contact has been recorded for over 15 minutes. Verify that the server is running and the service is active.

In Windows Services (services.msc)​

  1. Press Win + R, type services.msc, and press Enter.
  2. Locate Winvoice Agent Service.
  3. Verify that the Status column displays Running and that Startup type is set to Automatic.

Logs & Diagnostics​

Winvoice Agent logs all activity both in local text files and in the integrated Windows Event Log.

1. Local Log Files​

The agent generates detailed rolling daily logs on the server:

  • Path: C:\ProgramData\Winvoice\Agent\logs\
  • Log format: agent-YYYY-MM-DD.log
  • This logs startup/shutdown events, synchronization intervals, number of exported invoices, and any stack traces in the event of errors.

2. Windows Event Log (Event Viewer)​

Critical events are reported directly to the Windows Event Log:

  1. Open Event Viewer (eventvwr.msc).
  2. Navigate to Windows Logs -> Application.
  3. Filter by source: WinvoiceAgent.

Common Issues and Solutions​

Issue 1: Status Displays "Offline" in Winvoice​

  • Cause: The service has stopped or the server lacks an internet connection.
  • Resolution:
    1. Open PowerShell as an administrator and run:
      Restart-Service WinvoiceAgent
    2. Check the internet connection and verify that outbound traffic to api.winvoice.se:443 is permitted in the firewall.

Issue 2: File Sharing Error or Access Denied to Visma Directory​

  • Cause: The service account lacks read and write permissions to the Visma Administration network share.
  • Resolution:
    1. By default, the service runs under the Local System account. If the company directory resides on a network share (\\SERVER\share), change the service account in services.msc to a dedicated domain or service account with full permissions to the folder.
    2. Verify that no users have locked the database files in exclusive mode in Visma.

Issue 3: Invalid or Expired Agent Token (HTTP 401)​

  • Cause: The API key has been revoked or deleted in the Winvoice web interface.
  • Resolution:
    1. Create a new key under Settings -> Integrations -> Winvoice Agent.
    2. Update the configuration file C:\ProgramData\Winvoice\Agent\appsettings.json with the new key and restart the service.