Skip to content

Latest commit

 

History

History
87 lines (67 loc) · 3.55 KB

File metadata and controls

87 lines (67 loc) · 3.55 KB

Lambda.GraphQL Documentation

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.

📚 Documentation Sections

Getting Started

API Reference

Advanced Topics

Development

🚀 Quick Start

// 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

🎯 Key Features

  • 🔧 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

📖 Learn More

🤝 Community


Lambda.GraphQL is designed to make GraphQL development with AWS AppSync as seamless and type-safe as possible for .NET developers.