Tagua 0.22.0

dotnet add package Tagua --version 0.22.0
                    
NuGet\Install-Package Tagua -Version 0.22.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="Tagua" Version="0.22.0" />
                    
For projects that support PackageReference, copy this XML node into the project file to reference the package.
<PackageVersion Include="Tagua" Version="0.22.0" />
                    
Directory.Packages.props
<PackageReference Include="Tagua" />
                    
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 Tagua --version 0.22.0
                    
#r "nuget: Tagua, 0.22.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 Tagua@0.22.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=Tagua&version=0.22.0
                    
Install as a Cake Addin
#tool nuget:?package=Tagua&version=0.22.0
                    
Install as a Cake Tool

Tagua

A .NET reporting engine. A template, written in YAML or JSON, describes the document; your application supplies the data; Tagua renders an accessible, archival PDF.

Documentation, guides and examples: taguareports.com.

  • Accessible: tagged PDF with a structure tree, alt text and reading order, PDF/UA-1 and PDF/UA-2.
  • Archival: PDF/A-2b, PDF/A-3b, PDF/A-4 and PDF/A-4f, with embedded, subset fonts (TrueType and CFF).
  • E-invoices: Factur-X / ZUGFeRD hybrid invoices, with the XML attached and described.
  • Reports: bands, groups with totals, tables that break across pages, charts, barcodes (QR, Data Matrix, PDF417, Code 128, EAN-13), subreports, "page n of m".
  • Any script: right-to-left text, font fallback, and Unicode line breaking (Chinese, Japanese, Thai). Add Tagua.Shaping.HarfBuzz for Arabic, Indic and other scripts whose letters join or reorder.
  • Safe and fast: templates hold no SQL or code, expressions are sandboxed and type-checked before any data is read, and there is no reflection: the engine runs under native AOT.

Example

orders.report.yaml:

title: Orders
culture: en-US
data:
  orders: { fields: { Customer: string, Total: decimal } }
body:
  detail:
    - layout: row
      content:
        - { type: text, value: "{Customer}", width: 3fr }
        - { type: text, value: "{Total:C}", width: 1fr, align: end }
  reportFooter:
    - content:
        - { type: text, value: "Total {Sum(Total):C}", fontWeight: bold, align: end }
using Tagua;
using Tagua.Fill;
using Tagua.Pipeline;
using Tagua.Serialization;

TaguaSettings.License = LicenseType.Community;   // once, at startup (see the licensing terms)

var report = CompiledReport.Compile(TemplateLoader.LoadFile("orders.report.yaml"));
var inputs = new ReportInputs
{
    Data = new Dictionary<string, IDataSet>
    {
        ["orders"] = DataSources.FromRows([
            new Dictionary<string, object?> { ["Customer"] = "Contoso", ["Total"] = 1250.00m },
            new Dictionary<string, object?> { ["Customer"] = "Fabrikam", ["Total"] = 480.50m },
        ]),
    },
    // Fonts, images and subreports named in the template are opened from here.
    Resources = new DirectoryResourceResolver("."),
};

await using var pdf = File.Create("orders.pdf");
var result = await Reports.RenderPdfAsync(report, inputs, pdf);
foreach (var diagnostic in result.Diagnostics) Console.WriteLine(diagnostic);

Rows can also come from any DbDataReader (DataSources.FromDataReader).

Your application's functions

Expressions can call .NET functions your application provides, beside the built-in ones. Their parameter and result types are checked like any other call:

var functions = new ReportFunctions()
    .Add("RowColor", (int row) => row % 2 == 0 ? "#F2F2F2" : "#FFFFFF")
    .Add("Words", (decimal amount) => AmountInWords(amount));

var template = TemplateLoader.LoadFile("invoice.report.yaml");
var report = CompiledReport.Compile(template, functions);
// value: "{Words(Total)}", styleFrom: { background: =RowColor(RowNumber()) }

Subreports can call them too. A report filled on several threads calls them on those threads.

Templates

TemplateSchema.Json is the JSON Schema of templates, for editors and for LLM structured output; the Tagua.Cli tool prints it (tagua schema) and renders templates as you edit them (tagua render --watch).

License

Tagua is free under the Community licenses: PolyForm Small Business, for companies with fewer than 100 people and less than USD 1 million in revenue, and PolyForm Noncommercial, for personal use, charities, education, research and government. Anyone may evaluate it for less than 32 days under the PolyForm Free Trial license (LicenseType.Trial). Other companies need a Professional license (per developer) or an Enterprise license (unlimited developers, redistribution in products sold to others, and support): licensing@taguareports.com.

Declare the license once, at startup, with TaguaSettings.License, or with the environment variable TAGUA_LICENSE (community, trial, professional or enterprise). Nothing is checked online and the output is the same under every license: the declaration states that you qualify for it. The terms are in LICENSE.txt.

Product 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. 
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.

NuGet packages (3)

Showing the top 3 NuGet packages that depend on Tagua:

Package Downloads
Tagua.Shaping.HarfBuzz

OpenType text shaping for Tagua reports with HarfBuzz: Arabic, Hebrew, Indic and other complex scripts.

Tagua.Import

Converts SSRS and ReportViewer report definitions (RDLC and RDL, 2005 to 2016) to Tagua templates, and lists anything that needs review.

Tagua.Excel

Excel output for Tagua reports: a workbook built from the report's data, with numbers and dates as such, Excel formats from the template's, collapsible groups and a frozen header. No other dependencies.

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last Updated
0.22.0 128 9/29/2026
0.21.0 116 9/29/2026
0.20.0 122 9/29/2026
0.19.0 128 9/28/2026
0.18.0 120 9/28/2026
0.17.0 127 9/28/2026
0.16.0 118 9/28/2026
0.15.0 114 9/28/2026
0.14.0 120 9/28/2026
0.13.0 121 9/28/2026
0.12.0 132 9/27/2026
0.11.0 120 9/27/2026
0.10.0 111 9/26/2026
0.9.0 122 9/26/2026
0.8.0 118 9/25/2026
0.7.0 120 9/25/2026
0.6.0 118 9/25/2026
0.5.0 111 9/25/2026
0.4.0 118 9/25/2026
0.3.0 114 9/25/2026
Loading failed