Keyboard shortcuts

Press or to navigate between chapters

Press S or / to search in the book

Press ? to show this help

Press Esc to hide this help

Examples Overview

This section provides practical examples demonstrating the key features and capabilities of the SCIM Server library. Each example is designed to showcase specific functionality with clear, executable code that you can run and modify.

How to Use These Examples

All examples are located in the examples/ directory of the repository. Each example can be run directly:

# Basic examples
cargo run --example basic_usage
cargo run --example multi_tenant_example

# MCP examples (require mcp feature)
cargo run --example mcp_server_example --features mcp

Example Categories

🚀 Core Examples

Learn the fundamental building blocks of SCIM server implementation:

🔧 Advanced Features

Explore sophisticated server capabilities:

🤖 MCP Integration (AI Agents)

See how AI agents can interact with your SCIM server:

🔐 Security & Authentication

Implement robust security patterns:

🛠️ Infrastructure & Operations

Production-ready operational patterns:

Learning Path

New to SCIM? Start with Basic Usage to understand core concepts.

Building multi-tenant systems? Progress to Multi-Tenant Server for isolation patterns.

Adding AI capabilities? Explore the MCP Integration examples starting with Simple MCP Demo.

Production deployment? Review ETag Concurrency Control and logging examples.

Running Examples

Prerequisites

Basic Examples

cd scim-server
cargo run --example basic_usage

MCP Examples

# Enable MCP feature for AI integration examples
cargo run --example mcp_server_example --features mcp

Development Setup

# Run with logging to see detailed output
RUST_LOG=debug cargo run --example multi_tenant_example

Key Concepts Demonstrated

Each example showcases different aspects of the SCIM Server library:

Contributing Examples

Have an interesting use case or pattern? Examples are welcome! See the contribution guidelines for details on adding new examples.