Evolvit.VismaNetOld 5.0.0

Prefix Reserved
dotnet add package Evolvit.VismaNetOld --version 5.0.0
                    
NuGet\Install-Package Evolvit.VismaNetOld -Version 5.0.0
                    
This command is intended to be used within the Package Manager Console in Visual Studio, as it uses the NuGet module's version of Install-Package.
<PackageReference Include="Evolvit.VismaNetOld" Version="5.0.0" />
                    
For projects that support PackageReference, copy this XML node into the project file to reference the package.
<PackageVersion Include="Evolvit.VismaNetOld" Version="5.0.0" />
                    
Directory.Packages.props
<PackageReference Include="Evolvit.VismaNetOld" />
                    
Project file
For projects that support Central Package Management (CPM), copy this XML node into the solution Directory.Packages.props file to version the package.
paket add Evolvit.VismaNetOld --version 5.0.0
                    
#r "nuget: Evolvit.VismaNetOld, 5.0.0"
                    
#r directive can be used in F# Interactive and Polyglot Notebooks. Copy this into the interactive tool or source code of the script to reference the package.
#:package Evolvit.VismaNetOld@5.0.0
                    
#:package directive can be used in C# file-based apps starting in .NET 10 preview 4. Copy this into a .cs file before any lines of code to reference the package.
#addin nuget:?package=Evolvit.VismaNetOld&version=5.0.0
                    
Install as a Cake Addin
#tool nuget:?package=Evolvit.VismaNetOld&version=5.0.0
                    
Install as a Cake Tool

Visma.net Integrations API Client for .NET

Build status NuGet version

⚠️ WARNING: This project should be avoided for use. Please use the official Visma.net API documentation and swagger from https://finance.visma.net/swaggerui/index.html instead.


A comprehensive .NET client library for integrating with the Visma.net Integrations API. This library provides strongly-typed models and easy-to-use methods for interacting with Visma's ERP system.

Developed by: Evolvit Solutions AB

Table of Contents

Installation

Install the package via NuGet:

Install-Package Visma.net

Or via .NET CLI:

dotnet add package Visma.net

Quick Start

using Visma.net;

// Set your application name for identification
VismaNet.ApplicationName = "My Integration App";

// Initialize the client
var vismaNet = new VismaNet(companyId: 12345, token: "your-api-token");

// Test the connection
var connectionTest = await vismaNet.TestConnection();
if (connectionTest.success)
{
    Console.WriteLine("Successfully connected to Visma.net!");
}

Authentication

Using API Token

var vismaNet = new VismaNet(companyId: 12345, token: "your-api-token");

Getting a Token Programmatically

// Get token using username/password
var token = await VismaNet.GetToken(
    username: "your-username",
    password: "your-password", 
    clientId: "your-client-id",
    secret: "your-client-secret"
);

// Get token using OAuth
var oauthUrl = VismaNet.GetOAuthUrl(
    clientId: "your-client-id",
    callback: "https://yourapp.com/callback"
);

// Exchange OAuth code for token
var token = await VismaNet.GetTokenUsingOAuth(
    clientId: "your-client-id",
    clientSecret: "your-client-secret",
    code: "oauth-code",
    redirectUri: "https://yourapp.com/callback"
);

// Get token from Visma Connect
var token = await VismaNet.GetTokenFromVismaConnect(
    clientId: "your-client-id",
    secret: "your-client-secret",
    tenantId: "your-tenant-id"
);

Core Features

  • Strongly-typed models for all Visma.net entities
  • Async/await support throughout the API
  • Dynamic API access for accessing any endpoint
  • Automatic pagination handling
  • Built-in error handling with custom exceptions
  • Attachment support for file operations
  • Background job support for long-running operations

Usage Examples

Working with Customers

// Get all customers
var customers = await vismaNet.Customer.GetAll();

// Get a specific customer
var customer = await vismaNet.Customer.Get("CUST001");

// Create a new customer
var newCustomer = new Customer("CUST002")
{
    name = "Acme Corporation",
    mainAddress = new Address
    {
        addressLine1 = "123 Main Street",
        city = "New York",
        postalCode = "10001"
    },
    mainContact = new ContactInfo
    {
        email = "contact@acme.com",
        phone = "+1-555-0123"
    }
};

await vismaNet.Customer.Add(newCustomer);

// Update a customer
customer.name = "Updated Company Name";
await vismaNet.Customer.Update(customer);

Working with Customer Invoices

// Create a new invoice
var invoice = new CustomerInvoice("INV-2024-001")
{
    customer = new CustomerSummary { number = "CUST001" },
    documentDate = DateTime.Today,
    documentDueDate = DateTime.Today.AddDays(30),
    currencyId = "USD"
};

// Add invoice lines
invoice.Add("ITEM001", quantity: 2);
invoice.Add(new CustomerInvoiceLine
{
    inventoryNumber = "ITEM002",
    quantity = 1,
    unitPrice = 99.99m
});

await vismaNet.CustomerInvoice.Add(invoice);

// Get all invoices
var invoices = await vismaNet.CustomerInvoice.GetAll();

// Get invoices with filtering
var recentInvoices = await vismaNet.CustomerInvoice.GetAll(
    filter: "documentDate ge 2024-01-01"
);

Working with Inventory

// Get all inventory items
var inventory = await vismaNet.Inventory.GetAll();

// Get a specific item
var item = await vismaNet.Inventory.Get("ITEM001");

// Create a new inventory item
var newItem = new Inventory("ITEM002")
{
    description = "New Product",
    type = InventoryType.Stock,
    status = InventoryStatus.Active,
    defaultPrice = 49.99m,
    vatCode = new VatCode { vatCodeId = "VAT25" }
};

await vismaNet.Inventory.Add(newItem);

Working with Suppliers

// Get all suppliers
var suppliers = await vismaNet.Supplier.GetAll();

// Create a new supplier
var supplier = new Supplier("SUPP001")
{
    name = "Supplier Corp",
    mainAddress = new Address
    {
        addressLine1 = "456 Supplier Ave",
        city = "Chicago",
        postalCode = "60601"
    },
    currencyId = "USD"
};

await vismaNet.Supplier.Add(supplier);

Supported Entities

The library provides full support for the following Visma.net entities:

Financial

  • Customer Invoices - Create, read, update customer invoices
  • Customer Payments - Handle customer payment processing
  • Supplier Invoices - Manage supplier invoice data
  • Supplier Payments - Process supplier payments
  • Journal Transactions - Record journal entries
  • General Ledger - Access GL transactions and balances

Master Data

  • Customers - Customer master data management
  • Suppliers - Supplier information and settings
  • Inventory - Product and service catalog
  • Contacts - Contact information management
  • Employees - Employee data and settings

Operations

  • Purchase Orders - Purchase order management
  • Purchase Receipts - Goods receipt processing
  • Inventory Issues - Stock issue transactions
  • Inventory Receipts - Stock receipt processing
  • Shipments - Shipment and delivery management

System

  • Branches - Branch/division management
  • Warehouses - Warehouse and location data
  • Currencies - Currency and exchange rate data
  • Attributes - Custom attribute management
  • Projects - Project and task management

Dynamic API Access

For accessing endpoints not covered by strongly-typed models, use the dynamic API:

// Access any endpoint dynamically
dynamic result = await vismaNet.Dynamic.Customer["CUST001"].Note.Get();
Console.WriteLine(result);

// Access resource endpoints
dynamic userInfo = await vismaNet.Resources.Context.UserDetails.Get();
Console.WriteLine(JsonConvert.SerializeObject(userInfo));

// POST data dynamically
dynamic newData = new
{
    name = "Dynamic Test",
    value = 123
};
await vismaNet.Dynamic.CustomEndpoint.Post(newData);

Configuration

Application Identification

Always set your application name for proper identification:

VismaNet.ApplicationName = "My Company Integration v1.0";

Request Limits

Configure concurrent request limits:

// Set maximum concurrent requests (1-8)
VismaNet.MaxConcurrentRequests = 5;

// Set maximum retries (1-5)
VismaNet.MaxRetries = 3;

Custom HttpClient

Use your own HttpClient instance:

var httpClient = new HttpClient();
httpClient.Timeout = TimeSpan.FromMinutes(5);

var vismaNet = new VismaNet(
    companyId: 12345, 
    token: "your-token", 
    httpClient: httpClient
);

Error Handling

The library provides specific exception types for different error scenarios:

try
{
    var customer = await vismaNet.Customer.Get("INVALID_ID");
}
catch (InvalidTokenException ex)
{
    // Handle authentication errors
    Console.WriteLine("Invalid token: " + ex.Message);
}
catch (InvalidArgumentsException ex)
{
    // Handle invalid parameters
    Console.WriteLine("Invalid arguments: " + ex.Message);
}
catch (VismaNetException ex)
{
    // Handle general API errors
    Console.WriteLine("API Error: " + ex.Message);
}

Contributing

Contributions are welcome! Please feel free to submit pull requests or open issues for bugs and feature requests.

License

This project is licensed under the MIT License - see the LICENSE.md file for details.


Note: This library is maintained by Evolvit Solutions AB. For support or questions about Visma.net integrations, please contact us.

Product Compatible and additional computed target framework versions.
.NET net5.0 was computed.  net5.0-windows was computed.  net6.0 was computed.  net6.0-android was computed.  net6.0-ios was computed.  net6.0-maccatalyst was computed.  net6.0-macos was computed.  net6.0-tvos was computed.  net6.0-windows was computed.  net7.0 was computed.  net7.0-android was computed.  net7.0-ios was computed.  net7.0-maccatalyst was computed.  net7.0-macos was computed.  net7.0-tvos was computed.  net7.0-windows was computed.  net8.0 was computed.  net8.0-android was computed.  net8.0-browser was computed.  net8.0-ios was computed.  net8.0-maccatalyst was computed.  net8.0-macos was computed.  net8.0-tvos was computed.  net8.0-windows was computed.  net9.0 was computed.  net9.0-android was computed.  net9.0-browser was computed.  net9.0-ios was computed.  net9.0-maccatalyst was computed.  net9.0-macos was computed.  net9.0-tvos was computed.  net9.0-windows was computed.  net10.0 was computed.  net10.0-android was computed.  net10.0-browser was computed.  net10.0-ios was computed.  net10.0-maccatalyst was computed.  net10.0-macos was computed.  net10.0-tvos was computed.  net10.0-windows was computed. 
.NET Core netcoreapp2.0 was computed.  netcoreapp2.1 was computed.  netcoreapp2.2 was computed.  netcoreapp3.0 was computed.  netcoreapp3.1 was computed. 
.NET Standard netstandard2.0 is compatible.  netstandard2.1 was computed. 
.NET Framework net45 is compatible.  net451 was computed.  net452 was computed.  net46 was computed.  net461 is compatible.  net462 was computed.  net463 was computed.  net47 was computed.  net471 was computed.  net472 was computed.  net48 was computed.  net481 was computed. 
MonoAndroid monoandroid was computed. 
MonoMac monomac was computed. 
MonoTouch monotouch was computed. 
Tizen tizen40 was computed.  tizen60 was computed. 
Xamarin.iOS xamarinios was computed. 
Xamarin.Mac xamarinmac was computed. 
Xamarin.TVOS xamarintvos was computed. 
Xamarin.WatchOS xamarinwatchos was computed. 
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.

NuGet packages

This package is not used by any NuGet packages.

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last Updated
5.0.0 284 10/15/2025