DevOp.ERP.Abstractions
0.5.0
dotnet add package DevOp.ERP.Abstractions --version 0.5.0
NuGet\Install-Package DevOp.ERP.Abstractions -Version 0.5.0
<PackageReference Include="DevOp.ERP.Abstractions" Version="0.5.0" />
<PackageVersion Include="DevOp.ERP.Abstractions" Version="0.5.0" />
<PackageReference Include="DevOp.ERP.Abstractions" />
paket add DevOp.ERP.Abstractions --version 0.5.0
#r "nuget: DevOp.ERP.Abstractions, 0.5.0"
#:package DevOp.ERP.Abstractions@0.5.0
#addin nuget:?package=DevOp.ERP.Abstractions&version=0.5.0
#tool nuget:?package=DevOp.ERP.Abstractions&version=0.5.0
DevOp.ERP.Abstractions
Provider-neutral .NET 10 contracts and DTOs for applications that integrate with multiple ERP systems.
Install this package in shared application layers. Provider packages such as DevOp.DK.Plus supply the implementation.
dotnet add package DevOp.ERP.Abstractions
Depend on the wide client at an application boundary instead of injecting a separate service for every ERP resource:
using DevOp.ERP;
using DevOp.ERP.Models;
public sealed class CustomerSync(IExternalErpClient erp)
{
public Task<IReadOnlyList<Customer>> GetChangesAsync(
DateTimeOffset since,
CancellationToken cancellationToken) =>
erp.Customer.Query()
.ModifiedSince(since)
.ToListAsync(cancellationToken);
}
Related sales resources are grouped under Sales:
var invoices = await erp.Sales.Invoice.Query()
.ForCustomer("C-100")
.Take(100)
.ToListAsync(cancellationToken);
Root resources use singular names. Reference data is available through Currency, Payment.Mode/Term/Type, Customer.Group, and Product.Group/Category/Unit. Large queries can be consumed page by page with AsAsyncEnumerable(cancellationToken); continuation tokens also preserve the remaining Take limit.
IExternalErpClientResolver selects a named connection when one process talks to several companies or ERP providers. Capabilities lets orchestration code inspect what a provider supports. Provider-specific writes remain on the provider package so the shared contract stays portable.
The models in DevOp.ERP.Models are owned by DevOp rather than generated from one vendor, and they are deliberately lean: a member is portable only when another ERP clearly has it with the same meaning. Customer holds Number, Name, NationalId, Address, Email, and Phone; Product the item code, descriptions, prices, stock quantity, and inactive flag; Employee the identity, address, contact, and status; Project the number, name, description, customer, and status; and Vendor the number, name, national ID, and balance (read through IExternalErpClient.Purchase.Vendor when ErpCapability.Vendors is advertised). Sales documents share SalesDocument with a SalesDocumentParty customer, AmountWithTax, ExchangeRate, and SalesDocumentLine lines. Every entity inherits ExternalId, Created, Modified, Deleted, and AdditionalData from ErpEntity. The models are unsealed so a provider can extend them: provider-specific data such as DK Plus VAT numbers, classification codes, commercial defaults, configuration groups, and memos belongs on the provider's subtype (DkPlusCustomer : Customer in DevOp.DK.Plus), not in this package. Nullable fields and AdditionalData preserve vendor data without leaking generated transport types into application code.
An adapter may return its own subtype typed as the portable model. Consumers that serialize or log by runtime type (ASP.NET Core output formatters, Serilog {@Customer}) will emit the subtype's extra members, so project results to your own DTOs before exposing or logging them.
Human-identifiable records expose AsString() for compact selector text, for example Example product (P-1). Public DTO properties also carry resource-backed DisplayAttribute metadata. English is the neutral fallback language and Icelandic is included for is and is-IS UI cultures.
CultureInfo.CurrentUICulture = CultureInfo.GetCultureInfo("is-IS");
var property = typeof(Product).GetProperty(nameof(Product.ItemCode))!;
var label = property.GetCustomAttribute<DisplayAttribute>()!.GetName();
// Vörunúmer
See the repository's Doc/Localization.md for culture and ASP.NET Core integration guidance.
| Product | Versions Compatible and additional computed target framework versions. |
|---|---|
| .NET | net10.0 is compatible. 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. |
-
net10.0
- No dependencies.
NuGet packages (1)
Showing the top 1 NuGet packages that depend on DevOp.ERP.Abstractions:
| Package | Downloads |
|---|---|
|
DevOp.DK.Plus
Modern typed .NET client for the DK Plus v1 and v2 APIs. |
GitHub repositories
This package is not used by any popular GitHub repositories.
v0.4.0: adds the ModelDisplayNames.ObjectDate label (Stored Date / Vistað dags., the time the provider stored the record) used by the DK Plus ObjectDate members, and the ModelDisplayNames SumReference, ReverseAccount, SubName, TaxType, InputTaxType, TaxAccount, InUse, Reconcile, PercentageOfVat and ValidTo labels (English and Icelandic) used by the DK Plus general-ledger create requests. v0.3.0 (breaking): portable models are now lean and unsealed. Customer, Product, Employee, Project, SalesPerson and the sales documents keep only members that another ERP clearly shares; DK Plus configuration, codes, enums, memos, change history and attachment metadata moved to DkPlus subtypes in DevOp.DK.Plus. Removes CustomerOptions, CustomerContactDetails, CustomerItemReceiver, CustomerProperty, MemoPage, EntityChange, FieldChange, AttachmentInfo, the product and project grouped detail models, and Project.RecordId (ErpEntity.ExternalId is the identity). Adds the portable Vendor model, IErpPurchaseResource (IExternalErpClient.Purchase.Vendor) with ErpCapability.Vendors, SalesDocumentParty, SalesDocument.Customer, AmountWithTax and ExchangeRate, and a lean SalesDocumentLine. Consumers that serialize or log by runtime type (ASP.NET Core output formatters, Serilog destructuring) emit provider subtype members; project results to your own DTOs.