Greeva.Core
1.0.5
dotnet add package Greeva.Core --version 1.0.5
NuGet\Install-Package Greeva.Core -Version 1.0.5
<PackageReference Include="Greeva.Core" Version="1.0.5" />
<PackageVersion Include="Greeva.Core" Version="1.0.5" />
<PackageReference Include="Greeva.Core" />
paket add Greeva.Core --version 1.0.5
#r "nuget: Greeva.Core, 1.0.5"
#:package Greeva.Core@1.0.5
#addin nuget:?package=Greeva.Core&version=1.0.5
#tool nuget:?package=Greeva.Core&version=1.0.5
Greeva.Core
Core domain models and interfaces for Greeva electronic invoicing library.
Overview
Greeva.Core provides the foundational domain models, interfaces, and business logic for electronic invoicing in Peru according to SUNAT standards.
Key Features
- Domain Models: Invoice, Note, Summary, Despatch, Perception, Retention
- UBL 2.1 Support: Complete implementation of UBL 2.1 standard
- Client & Company: Customer and company information models
- Address Management: Peruvian address structure with ubigeo support
- Tax Calculations: IGV, ISC, ICBPER tax handling
- Document References: Support for document relationships
Core Entities
Invoice (Factura)
- Electronic invoices with full tax calculations
- Support for national and export operations
- Multiple payment terms and methods
Note (Nota de Crédito/Débito)
- Credit and debit notes
- Reference to original documents
- Automatic tax adjustments
Summary (Resumen Diario)
- Daily summary documents
- Batch processing for multiple documents
- SUNAT required for some document types
Despatch (Guía de Remisión)
- Electronic despatch guides
- Transport information
- Goods tracking
Usage
using Greeva.Core.Domain.Sale;
using Greeva.Core.Domain.Company;
using Greeva.Core.Domain.Clients;
// Create an invoice
var invoice = new Invoice
{
UblVersion = UblVersion.UblVersion21,
TipoOperacion = TipoOperacion.VentaInterna,
TipoDoc = TipoDocumento.Factura,
Serie = "F001",
Correlativo = "123",
FechaEmision = DateTime.Now.Date,
TipoMoneda = TipoMoneda.NuevoSol,
Company = new Company
{
Ruc = "20123456789",
RazonSocial = "MI EMPRESA S.A.C.",
Address = new Address
{
Ubigeo = "150101",
Departamento = "LIMA",
Provincia = "LIMA",
Distrito = "LIMA",
Direccion = "AV. PRINCIPAL 123"
}
},
Client = new Client
{
TipoDoc = TipoDocumento.Dni,
NumDoc = "12345678",
RznSocial = "CLIENTE EJEMPLO"
},
Details = new List<InvoiceDetail>
{
new InvoiceDetail
{
CodProducto = "PROD001",
Descripcion = "PRODUCTO DE EJEMPLO",
Cantidad = 1,
UnidadMedida = "NIU",
MtoValorUnitario = 100.00m,
MtoValorVenta = 100.00m,
MtoBaseIgv = 100.00m,
PorcentajeIgv = 18.00m,
Igv = 18.00m,
TipAfeIgv = TipoAfectacionIgv.GravadoOperacionOnerosa,
MtoPrecioUnitario = 118.00m
}
}
};
// Calculate totals
invoice.MtoOperGravadas = 100.00m;
invoice.MtoIGV = 18.00m;
invoice.MtoImpVenta = 118.00m;
Dependencies
- .NET 8.0
- System.ComponentModel.DataAnnotations
- Newtonsoft.Json (for JSON serialization)
Related Packages
- Greeva.Xml: XML generation and templates
- Greeva.Xml.Sign: Digital signature functionality
- Greeva.Sunat.GRE: SUNAT web services integration
- Greeva.Domain.Validator: Business rule validation
- Greeva.Ubl.Validator: UBL XML schema validation
License
MIT License - see LICENSE file for details.
Support
For issues and questions, please visit: https://github.com/augustoteles/greeva/issues
| Product | Versions Compatible and additional computed target framework versions. |
|---|---|
| .NET | net8.0 is compatible. 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. |
-
net8.0
- No dependencies.
NuGet packages (4)
Showing the top 4 NuGet packages that depend on Greeva.Core:
| Package | Downloads |
|---|---|
|
Greeva.Sunat.GRE
SUNAT web services integration for Greeva electronic invoicing - CPE services and authentication |
|
|
Greeva.Domain.Validator
FluentValidation-based domain model validators for Greeva electronic invoicing |
|
|
Greeva.Xml
XML generation and template engine for Greeva electronic invoicing using RazorLight |
|
|
Greeva.WebApi
Greeva library optimized for Web APIs with DI support and embedded templates |
GitHub repositories
This package is not used by any popular GitHub repositories.