~/talk

Building and generating a .NET client for a large API

Talkat DotNext 2020 Moscow · 2020-12-02..12-05· [dotnet]
slides:none on file

The Space HTTP API surface is massive — about 170 endpoints and more than 700 DTOs — so a generator reads the server’s API model (JSON), emits C# via string-builder templates and extension helpers, and targets System.Text.Json with custom converters for enums and polymorphism. The result is a generated .NET SDK with flattened request signatures, factory helpers, IAsyncEnumerable paging, and property-not-requested exceptions; code lives on GitHub and works, while a .NET 5 source-generator variant works too but needs a better trigger to regenerate on demand.

AI-written summary · about

  1. 0:00Introduction and welcome
  2. 3:03What is JetBrains Space
  3. 7:13Space API challenges and opportunities
  4. 17:03Why manual SDKs don't scale
  5. 20:37Exposing the API model
  6. 27:17Generating enums in .NET
  7. 30:29Code generation approaches
  8. 32:13System.Text.Json limitations
  9. 34:01Custom JSON converters
  10. 38:53Developer experience focus
  11. 47:01Batching and async enumerables
  12. 51:37Flattening request bodies
  13. 55:54Factory methods and defaults
  14. 56:36ASP.NET Core integration
  15. 58:22Conclusion and Q&A
~/search
type to search 8,222 conferences, 162,397 speakers and 219,688 talks
~/help
cmdctrl k
search every conference, speaker and series
/
focus the filter search
h
home
c
conferences
s
speakers
e
series
t
light / dark — the status bar button does the same
← →
on a talk: 5 seconds back / forward
0–9
on a talk: jump to 0%–90% of the recording
?
this help
esc
close this, then clear every filter — or just the search, while you are typing in it

Ignored while you are typing. Pages without a filter rail have no search to focus.