XBOX-GDK-dotnet
AGENTS.md1 starsChanged 2 months agoMITView on GitHub
The dotnet implementation of the Microsoft GDK idiomatic projection. It is one of eight sibling language repositories split out of the gdk-projections-plans meta repo. The authoritative specification for this repository is plans/dotnet.md in the gdk-projections-plans meta repo, alongside the nine shared, language-agnostic reference docs under reference/ (gdk-surface.md, xuser-pilot.md, state-change.md, multiplayer-pilot.md, roadmap.md, security-privacy.md, compliance.md, glossary.md, testing.md). The plan follows a shared 15-section template; §4 (the mapping table) is the heart, §9 is the acceptance slice (the XUser pilot, plus the PFMP…
Where files are headingNew AGENTS.md files have more rules about keeping secrets out of the code, and fewer about checking a change actually works.
Of the AGENTS.md files we read, the 11,736 first seen in the last six months, against the older ones: the kind of rule that gained most share, and the kind that lost most. About files like this in general, not this one, and an estimate, since a kind is a pattern in the words.
The file
We split this AGENTS.md into the rules it gives an agent
1 rule. About 0 are common, 0 are distinctive, and 1 is very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈0
Distinctive · estimate
This author's own choices. Worth a look.
1
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- could be automatic: a setting could enforce it
- Very specific: line 51
After any public API change, re-run pwsh eng/generate-docs.ps1 and commit docs/api/.
≈ “Common” is an estimate: at least 1 in 5 of the 16,597 AGENTS.md files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
AGENTS.md: gdk-dotnet
What this repository is
The dotnet implementation of the Microsoft GDK idiomatic projection. It is one of eight
sibling language repositories split out of the gdk-projections-plans meta repo.
The specification lives in the meta repo
The authoritative specification for this repository is plans/dotnet.md in the
gdk-projections-plans meta repo, alongside the nine shared, language-agnostic reference docs
under reference/ (gdk-surface.md, xuser-pilot.md, state-change.md, multiplayer-pilot.md,
roadmap.md, security-privacy.md, compliance.md, glossary.md, testing.md). The plan follows
a shared 15-section template; §4 (the mapping table) is the heart, §9 is the acceptance slice (the
XUser pilot, plus the PFMP Lobby state-change slice).
Those documents are not vendored into this repository. This repo is public and the meta repo is not, so the specification is not mirrored here and must not be copied back in. Read it in the meta repo, and fix it there.
Everything under docs/ is authored here
docs/ is canonical for this repository. There is no vendored content and no re-vendor step.
| Path | Notes |
docs/README.md | The documentation index. Add new authored pages here. |
docs/building.md | Build, test, run, package. |
docs/getting-started.md | Idioms and a first sign-in. |
docs/architecture.md | Layering, target frameworks, the AOT contract. |
docs/gdk-edition.md | The re-pin procedure and minimum version. |
docs/status.md | What is projected, what is out of scope, the coverage numbers. |
docs/native-aot.md | How AOT safety is enforced, and how to AOT-publish a title. |
docs/custom-game-ui.md | Title-implemented UI and its threading rules. |
docs/repository-layout.md | Where things live; what is generated. |
docs/api/ | Generated. Do not hand-edit; edit the XML doc comments and run eng/generate-docs.ps1. One folder per namespace, each with a generated README.md index. |
Because this repository is public, do not add links to the meta repo or to any other private resource in documentation, source comments or commit messages: they resolve for nobody outside Microsoft.
Public API changes must stay documented
src/GDK.Net/GDK.Net.csproj sets GenerateDocumentationFile, and TreatWarningsAsErrors is on
repo-wide, so a new public type or member without an XML doc comment fails the build (CS1591).
This is deliberate: it is what keeps docs/api/ complete.
- Hand-written code: write the doc comment.
- Generated PlayFab/Party code: fix the emitter under
eng/playfab/, never the output. The enum member summaries come fromemit_native.emit_enum(..., document: true). - After any public API change, re-run
pwsh eng/generate-docs.ps1and commitdocs/api/.ApiReferenceDriftTestsfails when a type has no page or a page outlives its type. docs/api/is one folder per namespace, each holding the type pages and a generatedREADME.mdindex. The layout is applied byeng/api-layout.ps1, whichgenerate-docs.ps1calls last and which can also be run alone. Never add or rename a folder there by hand: changeeng/api-areas.jsonand re-run. Folders exist because GitHub truncates a directory listing at 1,000 entries and the flat output is past that.
Ground rules
- Idiomatic, not mechanical. Callers must never see an
HRESULT, a raw handle, anXAsyncBlock, a registration token, or a two-call size buffer. - Scope. In: the core
X*runtime + the_cservices (XSAPI, libHttpClient, GameChat2, PlayFab incl. PFMP and Party). Out: XCurl, XAL, GameInput, the GXDK console tree. - Pinned GDK edition
260404. Headers come from the edition'swindows\includetree and import libraries fromwindows\lib\{x64,arm64}. Never use theGRDK\GameKit\*paths: they omit the XBOX Live / PlayFab stack and ship noarm64libraries. Derive paths from%GameDKCoreLatest%(the edition root), never%GRDKLatest%or%GXDKLatest%. - Cancellation (
E_ABORT) routes to the language's cancellation idiom, never a generic error. The numeric HRESULT is always preserved for diagnostics. - Testing is live. The pilot is validated in a packaged GDK app against a real sandbox; CI only builds and lints.
- Supported versions are declared in
README.md. Any change to the supported runtime, architecture, engine, or toolchain matrix must update that table in the same change.
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

