Skip to content
Open source

Connector libraries, open source.

The pieces SpanFlow pipelines use to read templates and talk to other systems: HTTP and its many sign-in schemes, files in every common format, cloud storage and databases. Each one is a small NuGet package you can use in your own .NET code, with no SpanFlow server needed.

Try it now

The libraries playground

No account, nothing to install. Open libraries.spanflow.app and see what each package does with your own input, on our server, with fair-use limits per visitor.

Drag, join, run

  • Build a flow from nodes on a canvas: JSON data, Expression, Shape JSON, Filter rows, HTTP request, Convert file and SQL query
  • Each node hands its answer to the next, and every answer is shown on the node and in full beside it
  • HTTP nodes sign with API key, basic, bearer, Digest, Hawk, OAuth 1.0a, JWT or OAuth 2, against a demo API that checks the signature
  • One click gives the C# for the whole flow, with the NuGet packages it needs

Nothing real is reached

Requests go only to a built-in demo API, queries only to a demo database that reads and nothing else, and files are converted in memory and never stored. The playground has no route to the internet at all.

Open libraries.spanflow.app

Call it from code

Every panel is an API too. POST the same JSON the page sends:

curl -X POST https://libraries.spanflow.app/api/expressions/evaluate \
  -H "Content-Type: application/json" \
  -d '{ "mode": "template",
        "template": "Order #{{ input.id }} for {{ input.name }}",
        "data": { "input": { "id": 42, "name": "Ada" } } }'
{ "result": "Order #42 for Ada", "type": "string" }

Routes: /api/expressions/evaluate, /api/http/send, /api/http/preview, /api/files/convert, /api/database/inspect and /api/database/query. Each panel is limited per caller; a refusal answers { "error", "reason" } with Retry-After and RateLimit-* headers.

NuGet

Five packages, one job each

MIT-licensed. Targets .NET 8, 9 and 10. Take only the ones you need.

SpanFlow.Expressions

The safe {{ template }} and expression language over JSON: paths, comparisons and boolean logic, nothing that runs code.

dotnet add package SpanFlow.Expressions

SpanFlow.Connectors.Http

Builds HTTP requests from JSON and signs them: API key, basic, bearer, OAuth 2, token endpoints, Digest, Hawk, OAuth 1.0a and JWT bearer.

dotnet add package SpanFlow.Connectors.Http

SpanFlow.Connectors.Files

CSV, TSV, JSON, NDJSON and Excel rows, streamed or whole, on a local folder, Amazon S3, Azure Blob Storage or FTP.

dotnet add package SpanFlow.Connectors.Files

SpanFlow.Connectors.Database

One adapter over PostgreSQL, SQL Server, MySQL and SQLite, with a query advisor that flags risky SQL before it runs.

dotnet add package SpanFlow.Connectors.Database

SpanFlow.Connectors.Abstractions

The small types the connector packages share. You get it with them.

dotnet add package SpanFlow.Connectors.Abstractions
Examples

A few lines each

Every package's NuGet page has its own readme with more.

Evaluate a template

SpanFlow.Expressions

using System.Text.Json.Nodes;
using SpanFlow.Expressions;

var context = new ExpressionContext
{
    Input = JsonNode.Parse("""{ "order": { "id": 42, "total": 120.5 } }"""),
};

ExpressionEvaluator.EvaluateAsBool("input.order.total > 100", context);    // true
TemplateRenderer.RenderString("Order #{{ input.order.id }}", context);    // "Order #42"
Try expressions in the playground

Build and sign a request

SpanFlow.Connectors.Http

using System.Text.Json.Nodes;
using SpanFlow.Connectors.Http;
using SpanFlow.Connectors.Http.Auth;

var request = JsonNode.Parse("""
{ "method": "GET", "path": "/v1/orders", "query": { "status": "open" } }
""")!.AsObject();

var settings = HttpRequestSettings.Default;
using var message = new HttpRequestMessage(HttpMethod.Get,
    HttpRequestBuilder.BuildUri("https://api.example.com", request, settings));

var auth = JsonNode.Parse("""{ "type": "bearer", "token": "..." }""")!.AsObject();
await AuthStrategyRegistry.CreateStatic().Get("bearer").ApplyAsync(message, auth, CancellationToken.None);
Send a signed request in the playground

Stream rows from a file

SpanFlow.Connectors.Files

using System.Text.Json.Nodes;
using SpanFlow.Connectors.Files;

var store = new LocalFileStore("/srv/exports");
IFileFormat csv = new CsvFormat();

await using var input = await store.OpenReadAsync("people.csv", CancellationToken.None);
await foreach (var row in csv.ReadRowsAsync(input, new JsonObject(), CancellationToken.None))
{
    Console.WriteLine(row["name"]);
}
Convert a file in the playground

Read a schema, check a query

SpanFlow.Connectors.Database

using SpanFlow.Connectors.Database;

var registry = new DbProviderRegistry([new PostgresAdapter(), new SqlServerAdapter(), new MySqlAdapter(), new SqliteAdapter()]);
var sqlite = registry.Get("sqlite");

await using var connection = sqlite.CreateConnection("Data Source=app.db");
await connection.OpenAsync();
var tables = await sqlite.ListTablesAsync(connection, CancellationToken.None);

foreach (var advice in QueryAdvisor.Inspect("SELECT * FROM orders"))
    Console.WriteLine($"{advice.Severity}: {advice.Message}");
Run a query in the playground
Source

The same code SpanFlow runs

Tested on every target

The libraries and their tests are on GitHub. The tests run on .NET 8, 9 and 10 before any version is published, including the published test vectors for Digest, Hawk and OAuth 1.0a signing.

github.com/SpanFlow/spanflow

Safe by default

  • Expressions read data; they never run code
  • A local file store refuses any path that leaves its folder
  • The query advisor flags a whole-table read before it runs
  • Tokens are fetched, cached and renewed before they expire

Stop moving data by hand.

Start free with three projects, or talk to us about running it across your organisation.