EmpireReportSenderSettings 1.0.1

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

Settings for Empire Report Sending

This is a C# library class to store common settings for Empire report projects - database connections, SQL query, recipients, etc.

Expected usage

Create a settings blob as an environment variable

SettingsBlob:

{
  "SqlQuery": "SELECT * FROM ReportData",
  "ReportTemplateFileName": "reports/ReportTemplateFileName.rpt"
}

Consume data

using EmpireReportSenderSettings;

IEmpireReportSenderSettingsBase settings = new EmailReportSettings();
List<MailAddress> recipients = settings.EmailRecipients;
string connectionString = settings.GetConnectionString();

Expected values

The following values are expected in the settings blob.

Report Base Settings

Base class intending to be inherited to various report types based on their presentation.

  • SqlQuery: The SQL query to run to get the data for the report
  • ReportTemplateFileName: The name of the report template file
  • ReportDataFile: The name of the report data file
  • DatabaseConnectionString: The connection string to the database
  • DatabaseUsername: The username to connect to the database
  • DatabasePassword: The password to connect to the database
  • LogWebhookUri: The URI to send logs to

Email Report Settings

For reports that are to be sent via email.

  • OutputFileName: The name of the output file
  • OutputFilePat: The path to the output file
  • EmailList: A comma separated list of email addresses to send the report to (e.g. "nb@empireindustries.com,jaris@empireindustries.com" or "nb@empireindustries.com")
  • EmailApiKey: The API key for sending emails
  • ReportEmailSenderName: The name of the sender of the email
  • ReportEmailSenderAddress: The email address of the sender of the email
  • ReportEmailSubject: The subject of the email
  • ReportEmailPlainTextBody: The plain text body of the email
  • ReportEmailHtmlBody: The HTML body of the email
Product 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. 
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
1.0.1 349 7/13/2024
1.0.0 152 7/13/2024