Welcome to the Lambda.GraphQL documentation! This library enables you to generate GraphQL schemas from C# Lambda functions for AWS AppSync with compile-time type safety and automatic resolver configuration.
- Getting Started Guide - Installation, setup, and your first GraphQL schema
- Examples - Working code examples from basic to advanced usage
- API Reference - Complete API documentation for all classes and methods
- Attributes Reference - Detailed guide to all GraphQL attributes
- Advanced Features - Union types, directives, subscriptions, and AWS scalars
- AWS Integration - AppSync integration and CDK deployment guides
- Architecture - Source generator design and system architecture
- Performance - Performance considerations and optimization tips
- Troubleshooting - Common issues and solutions
- Contributing - Development setup and contribution guidelines
- Migration Guide - Version migration and breaking changes (Coming Soon)
// 1. Define your GraphQL types
[GraphQLType("Product")]
public class Product
{
[GraphQLField(Description = "Product identifier")]
public Guid Id { get; set; }
[GraphQLField(Description = "Product name")]
public string Name { get; set; }
[GraphQLField(Description = "Product price")]
public decimal Price { get; set; }
}
// 2. Create Lambda functions with GraphQL operations
public class ProductFunctions
{
[LambdaFunction]
[GraphQLQuery("getProduct")]
[GraphQLResolver(DataSource = "ProductsLambda")]
public async Task<Product> GetProduct(
[GraphQLArgument] Guid id)
{
// Your implementation here
return new Product { Id = id, Name = "Sample", Price = 9.99m };
}
}This automatically generates:
- GraphQL Schema (
schema.graphql) with proper SDL syntax - Resolver Manifest (
resolvers.json) for CDK deployment - Type Safety at compile time with full IntelliSense support
- 🔧 Compile-Time Generation - GraphQL schemas generated during build
- 🛡️ Type Safety - Full C# type safety with GraphQL schema validation
- ☁️ AWS Integration - Native AppSync and CDK support
- 🚀 Advanced Features - Union types, directives, subscriptions, custom scalars
- 📦 Zero Runtime Dependencies - Pure compile-time source generation
- 🔄 AOT Compatible - Works with Native AOT compilation
- Start with the Getting Started Guide for installation and setup
- Explore Examples to see the library in action
- Check Advanced Features for union types, directives, and more
- Review AWS Integration for deployment with CDK
- Issues: Report bugs and request features on GitHub Issues
- Discussions: Join the conversation on GitHub Discussions
- Contributing: See our Contributing Guide to get involved
Lambda.GraphQL is designed to make GraphQL development with AWS AppSync as seamless and type-safe as possible for .NET developers.