Skip to content

Getting Started

This guide walks you through setting up and running Virtufin API for the first time.

Prerequisites

Component Version Purpose
.NET SDK 10.0+ Build and run the API service
Dapr CLI 1.18+ Initialize state store and pub/sub components
Docker 24+ Containerized deployment (optional)
Protocol Buffers proto3 Service definition format

Quick Start

1. Clone and Build

git clone https://git.haenerconsulting.com/virtufin/virtufin-api.git
cd virtufin-api
dotnet build

2. Initialize Dapr

dapr init

3. Run the Service

cd src/Virtufin.Api
dapr run --app-id virtufin-api --app-protocol grpc --app-port 5002 -- dotnet run

The service starts on port 5001 (HTTP/REST) and port 5002 (native gRPC).

4. Verify

# Health check
curl http://localhost:5001/health

# List available services (native gRPC)
grpcurl -plaintext localhost:5002 virtufin.api.Gateway/ListServices

Running with Docker

docker build --build-arg DOTNET_VERSION=10.0 -t virtufin-api -f src/Virtufin.Api/Dockerfile .
docker run -p 5001:5001 -p 5002:5002 virtufin-api

Configuration

Configuration is read from appsettings.json with environment variable overrides:

# Custom ports
ASPNETCORE_URLS="http://+:5001" dotnet run

# Or, using the HttpPort config key (env var):
HttpPort=5001 dotnet run

See the Configuration page for all available settings.

Full Stack Integration

For deploying all three Virtufin services together, see the Cross-Service Integration Guide. It covers deploy order, topic ownership, the health-check sequence, shared Dapr components, and complete Docker Compose + Kubernetes manifests.

Next Steps