Ambystech.Neo4j.Repository.Contracts 0.3.1

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

Ambystech.Neo4j.Repository

Ambystech.Neo4j.Repository

Neo4j Repository pattern implementation for .NET.

Overview

This library provides a repository implementation for Neo4j graph databases, enabling easy CRUD operations, relationship management, and search functionality.

Packages

  • Ambystech.Neo4j.Repository - Main repository implementation
  • Ambystech.Neo4j.Repository.Contracts - Base contracts and attributes

Installation

dotnet add package Ambystech.Neo4j.Repository
dotnet add package Ambystech.Neo4j.Repository.Contracts

Quick Start

  1. Configure Neo4j connection in appsettings.json or user secrets:
{
  "Neo4j-Uri": "bolt://localhost:7687",
  "Neo4j-User": "neo4j",
  "Neo4j-Password": "password"
}
  1. Register services:
builder.Services.AddNeo4jRepository();
builder.Services.AddSingleton<INodeConverter<YourEntity>, YourEntityConverter>();
builder.Services.AddScoped<IBaseGraphRepository<YourEntity>, YourEntityRepository>();
  1. Use the repository:
var repository = serviceProvider.GetRequiredService<IBaseGraphRepository<YourEntity>>();
var entities = await repository.GetAllAsync();

Features

  • Generic CRUD operations
  • Relationship management
  • Search and filtering
  • Soft delete support
  • Automatic relationship loading.

Example

See the example/ directory for a complete working example with a social network graph (Users, Posts, Likes, Dislikes).

Example Graph

License

MIT License - see LICENSE file for details.

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 is compatible.  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 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.
  • net10.0

    • No dependencies.
  • net8.0

    • No dependencies.
  • net9.0

    • No dependencies.

NuGet packages (1)

Showing the top 1 NuGet packages that depend on Ambystech.Neo4j.Repository.Contracts:

Package Downloads
Ambystech.Neo4j.Repository

A lightweight and flexible generic repository pattern implementation for Neo4j, built in C# for .NET, designed to simplify data access, promote clean architecture, and enable reusable, maintainable graph-based applications.

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last Updated
0.3.1 105 4/20/2026
0.3.0-alpha0015 198 1/7/2026
0.2.0 98 4/20/2026
0.1.3 120 1/8/2026
0.1.2 313 1/8/2026