RulebricksApi 2.0.0

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

Banner

<p> <a href="https://www.nuget.org/packages/RulebricksApi" alt="NuGet"> <img src="https://img.shields.io/nuget/v/RulebricksApi" /></a> <a href="https://github.com/rulebricks/csharp-sdk" alt="License"> <img src="https://img.shields.io/github/license/rulebricks/csharp-sdk" /></a> </p>

Installation

To install the Rulebricks C# SDK, add the following package reference to your project file:

<PackageReference Include="RulebricksApi" Version="1.8.0" />

Usage

Initialization

To use the SDK, you need to initialize the RulebricksApiClient with your API key:

using RulebricksApi;

var apiKey = "your_api_key";
var client = new RulebricksApiClient(apiKey);

Solving a Rule

Here's a simple example of how to solve a rule:

var requestData = new Dictionary<string, object>
{
    { "exampleKey", "exampleValue" } // Replace with actual rule data keys and values
};

var result = client.Rules.Solve("example-rule-slug", requestData);
Console.WriteLine($"Result: {result}");

Solving a Flow

Here's a simple example of how to solve a flow:

var requestData = new Dictionary<string, object>
{
    { "exampleKey", "exampleValue" } // Replace with actual flow data keys and values
};

var result = client.Flows.Solve("example-flow-slug", requestData);
Console.WriteLine($"Result: {result}");

Contributing

We welcome contributions to the Rulebricks C# SDK. Please follow these steps to contribute:

  1. Fork the repository on GitHub.
  2. Create a new branch with a descriptive name.
  3. Make your changes and commit them with clear and concise messages.
  4. Push your changes to your forked repository.
  5. Open a pull request on the main repository.

For major changes, please open an issue first to discuss what you would like to change.

Troubleshooting

If you encounter any issues while using the SDK, please check the following:

  • Ensure that you have the correct API key and that it has the necessary permissions.
  • Verify that you are using the correct version of the SDK and .NET framework.
  • Check the API reference documentation for any changes or updates to the API endpoints.

If the issue persists, please open an issue on GitHub with detailed information about the problem.

License

This project is licensed under the MIT License. See the LICENSE file for details.

Product Compatible and additional computed target framework versions.
.NET net5.0 was computed.  net5.0-windows was computed.  net6.0 is compatible.  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 is compatible.  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 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. 
.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 net461 was computed.  net462 is compatible.  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
2.0.0 143 5/29/2025
1.9.0 146 5/28/2025
1.8.0 491 3/25/2025
1.7.0 481 3/25/2025
1.6.0 479 3/25/2025
1.5.0 111 12/20/2024
1.3.0 96 12/11/2024
1.1.0 97 12/10/2024
1.0.6 119 12/6/2024
1.0.0 119 7/12/2024