Skip to content

docs: add C# (.NET) SDK as a first-class language#215

Open
GarrettBeatty wants to merge 9 commits into
aws:mainfrom
GarrettBeatty:dotnet
Open

docs: add C# (.NET) SDK as a first-class language#215
GarrettBeatty wants to merge 9 commits into
aws:mainfrom
GarrettBeatty:dotnet

Conversation

@GarrettBeatty

@GarrettBeatty GarrettBeatty commented Jul 1, 2026

Copy link
Copy Markdown

Summary

Adds C# (.NET) as a first-class language across the docs, matching the existing TypeScript / Python / Java coverage. C# now appears in every content-tab group, both language lists, the nav, the Getting-help / Resources links, and the contributor policy.

The Amazon.Lambda.DurableExecution SDK's durable operations and execution model match the other SDKs; the divergent host surface (envelope handler + DurableFunction.WrapAsync, programming models, single-serializer, CancellationToken) is documented on a new C# SDK guide page.

What changed

  • New page: docs/sdk-reference/languages/csharp/index.md — handler/envelope, programming models (executable, class library, Lambda Annotations), serialization, cancellation, logging.
  • C# tab added to every tabbed page: all 8 operation pages, error-handling, serialization, logging, custom-lambda-client, getting-started (key-concepts, quickstart), all 6 patterns/best-practices pages, and the testing pages (api-reference's 39 groups, assertions, authoring, cloud-runner, workflow-patterns).
  • ~120 new examples/csharp/** files, mirroring the existing TS/Python/Java examples.
  • Policy: authoring-guide.md and CONTRIBUTING.md now treat C# as first-class (four languages, tab order TS → Python → Java → C#, .NET SDK source paths in the verification table).
  • Prose/links: README.md, docs/index.md, docs/sdk-reference/index.md, manage-executions.md.

Verification

** note this is all throwaway verification stuff. will be deleted before mergining


All C# in the docs is verified against the `aws/aws-lambda-dotnet` SDK source by a one-command driver, `scripts/csharp-verify/verify-all.sh` (local, **not** wired into CI — CI only runs `zensical build`). It:

1. builds the core + testing SDKs;
2. compiles every `examples/csharp/**` file against the SDK (103 compile, 17 signature/fragment snippets skipped by design);
3. extracts every **inline** C# block from the docs and checks that every redeclared SDK type's members exist in source (18 type-mirror blocks, 102 identifiers);
4. checks that every SDK identifier in inline signature/fragment blocks exists in source (30 blocks, 134 identifiers), and compiles the runnable inline fragments with scaffolding.

Current result: **PASS**, 0 defects across all 176 C# blocks.

Notes for reviewers

  • quickstart-container-image.md is intentionally left Java-only — it's a Java-specific container walkthrough; a C# tab there read incoherently.

Generated with assistance from Claude Code.

Add C# as a fourth language tab (order TS -> Python -> Java -> C#) across
the SDK reference, plus a new C# language guide page. Covers the
Amazon.Lambda.DurableExecution .NET SDK: envelope handler + WrapAsync,
executable/class-library/Annotations programming models, single-serializer
(AOT/trim) serialization, and the linked CancellationToken.

Pages: languages/csharp/index.md (new), all 8 operation pages, errors,
retries, serialization, logging, custom-lambda-client, and the Getting help
list on index.md.

Examples: 79 examples/csharp/**.cs files. Every compilable example is
verified against the SDK source via a local (non-CI) compile harness under
scripts/csharp-verify/ (62 pass, 0 fail, 17 non-compilable signature/fragment
snippets that mirror the other languages). Pseudo-signature and
exception-hierarchy files hand-verified against source.
…, testing

Add C# tabs (order TS -> Python -> Java -> C#) to getting-started key-concepts
and quickstart, all six patterns/best-practices pages, and the testing pages
(assertions, authoring, cloud-runner, workflow-patterns). 41 new
examples/csharp files; all compilable ones verified against the SDK via the
local harness (testing examples use Amazon.Lambda.DurableExecution.Testing).

Promote C# to first-class in the contributor policy: authoring-guide.md and
CONTRIBUTING.md now mandate all four languages, tab order TS -> Python -> Java
-> C#, with the .NET SDK source paths added to the verification table and a
pointer to scripts/csharp-verify/. Update README and index prose to list C#.

The container-image quickstart stays Java-only by design (it is a
Java-specific walkthrough), so it keeps a single Java tab.

testing/api-reference.md still needs C# and is handled separately.
Add C# tabs to all 39 tab groups on testing/api-reference.md, covering the
.NET DurableTestRunner / CloudDurableTestRunner, TestResult, TestStep,
TestRunnerOptions / CloudTestRunnerOptions, OperationKind, and OperationStatus.
All C# types and members verified against the Amazon.Lambda.DurableExecution.Testing
source; sections with no .NET equivalent (static setup/teardown lifecycle) say
so rather than inventing API. Fixed an invented `InvokeDurableAsync` reference
to the real `InvokeAsync`.

Rewrite the C# quickstart deploy tab to match the sibling tabs: concrete
dotnet add package / dotnet publish / zip / aws lambda create-function
--runtime dotnet10 commands, with the model-specific handler string pointing to
the C# SDK guide. Runtime id, package, handler formats, and Zip packaging all
verified against source.
… tab

- sdk-reference/index.md: list the C# language guide alongside TS/Python/Java
- manage-executions.md: C# deploys via zip, so add it to the
  "Zip (TypeScript/Python/C#)" packaging tab label
The .NET SDK is 1.0 at merge time, so remove the "preview (0.x)" admonition.
Also remove the target-frameworks sentence; the managed dotnet10 runtime is
already covered in the programming-models section.
…etails

- Trim the programming-models prose (remove cross-SDK framing and verbose
  per-model explanations; keep both code examples)
- Stop naming the specific dotnet runtime version: use "managed .NET runtime"
  and a <dotnet-runtime> placeholder in the quickstart CLI, so the docs need
  no update when the runtime version changes
- Drop the AOT/IsTrimmable trim-clean guidance from the serialization section
scripts/csharp-verify/verify-all.sh runs the full verification:
  1. build core + testing SDKs
  2. compile every examples/csharp file against the SDK (verify.sh)
  3. extract-inline.py pulls every inline C# block from the docs; verify-types.py
     checks each redeclared SDK type's members exist in source
  4. verify-frags.py checks every SDK identifier in inline signature/fragment
     blocks exists in source

Covers all 176 C# blocks in the docs (120 example-file includes + 56 inline),
so nothing is verified by hand. Not wired into CI.
A copy-pasteable create-function command needs a real runtime value; keep the
prose version-agnostic but use the concrete identifier in the command itself.
@@ -0,0 +1,176 @@
export const meta = {

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ignore all of these scripts for now, im going to remove them before merging.

@GarrettBeatty GarrettBeatty marked this pull request as ready for review July 1, 2026 20:57
dotnet publish -c Release -o publish
cd publish && zip -r ../function.zip . && cd ..

aws lambda create-function \

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

i wasnt sure if we wanted to have the dotnet specific tooling here. e.g. https://docs.aws.amazon.com/toolkit-for-visual-studio/latest/user-guide/lambda-cli-publish.html for now i kept it using the aws cli to be consistent. what do other think?

Comment thread authoring-guide.md
| [aws-durable-execution-sdk-python-testing](https://github.com/aws/aws-durable-execution-sdk-python-testing) | `src/aws_durable_execution_sdk_python_testing` |
| [aws-lambda-dotnet](https://github.com/aws/aws-lambda-dotnet) | `Libraries/src/Amazon.Lambda.DurableExecution.Testing` |

The C# examples have a local compile-check harness under `scripts/csharp-verify/`

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

will remove this comment before merging

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant