Most developers have heard of the architectural style known as REST, but even experienced developers often find it difficult to apply RESTful principles when building real-world applications. This workshop is all about building and running RESTful systems in the real world.
Over two days, you’ll get a comprehensive grounding in the principles and patterns behind HTTP APIs, the architectural style known as REST, and the frameworks and formats that exist to support developers building HTTP APIs using C# and Microsoft .NET. We’ll start by going right back to Roy Fielding’s original thesis “Architectural Styles and the Design of Network-based Software Architectures”, in which he describes the set of constraints that define this much-misunderstood architectural style. We’ll learn the significance of each of these constraints, and explore some examples of real-world systems that demonstrate each constraint in action.
We’ll look in depth at how to use Microsoft’s own ASP.NET Core framework to build and host high-performance REST APIs. We’ll discuss how running on .NET Core opens up new possibilities for developing and hosting your APIs, from cross-platform IDEs like Rider and Visual Studio Code, to running .NET Core on Linux and using serverless hosting environments like AWS Lambda. We’ll explore the various formats that exist for representing hypermedia resources in JSON - HAL, SIREN, HYDRA, JSON-LD and Collection+JSON, and the relative merits of each. We’ll go beyond 200 OK and 404 Not Found and explore how you can use the full range of HTTP verbs, headers and response codes to build expressive, responsive APIs. We’ll look at ways of securing your HTTP APIs, and techniques and patterns you can use to document and test your APIs in development, and monitor them when they’re running in production.
Finally, to put all this in context, we’ll talk about why REST might not always be the best solution to your problem, look briefly at some of the alternative API patterns you may want to consider using, and finish up with some discussion of how RESTful services can fit into your organisation’s technology strategy - and how to persuade your boss, and your team, that they’re worth investing in.
You’ll leave the workshop with a comprehensive understanding of building HTTP APIs in C# and .NET, your own working implementations of the patterns and techniques we’ve talked about, and a much clearer idea of what REST is - and why people are still talking about it, nearly twenty years after it was first defined.
- Learn how to design and implement RESTful APIs in C# and ASP.NET Core.
- Learn how to use the full range of HTTP verbs and response codes effectively.
- Learn about the various hypermedia formats that are available for building HTTP APIs.
- Learn about the rich set of tools that can help you design, build and manage your APIs.
- What is REST?.
- Architectural styles and constraints.
Module 1: Retrieving Resources
- Building your first hypermedia API.
- Hypermedia formats and content negotiation.
- Linked resources and resource expansion.
- Layered systems and cacheability.
Module 2: Creating and Updating Resources
- Understanding PUT and DELETE.
- Understanding POST and PATCH.
- Beyond CRUD: modelling complex domains with HTTP and REST.
Module 3: Security and Identity for REST APIs
- Securing REST APIs.
- Authentication, API keys.
- Using OAuth2 and OpenID Connect.
- Request validation and signatures.
Module 4: Content Types and Versioning
- Resource and representations.
- Content negotiation.
- REST API versioning strategies .
- Custom media types.
Module 5: Tools and Testing
- Testing and monitoring hypermedia APIs.
- Tunneling APIs with NGrok.
- Building integration tests for REST APIs.
Module 6: Running REST in Production
- Hosting APIs: IIS, OWIN, Kestrel.
- Deployment and hosting architecture APIs.
- Load balancers, API Gateways, Backends for Frontends (BFFs).
- Going serverless.
Module 7: Integration and Collaboration
- Documenting and versioning HTTP APIs
- Integrating REST: message queues, gRPC, CQRS.
Module 8: REST and API Strategy
- Alternatives to REST, and when to consider using them.
- REST on your roadmap - and how to sell it to your boss.
About the Trainer
Dylan Beattie is a software developer, musician and international keynote speaker. With over 20 years experience working in the software industry, Dylan has spoken and taught at over 100 software development conferences all over the world. He's the founder and director of Ursatile, established in 2020 to provide high-quality workshop training for software professionals. He was CTO at Skills Matter in London from 2017-2019, and throughout 2020 he's been working with NDC Conferences to virtualise their events in the wake of the coronavirus pandemic.