Session
Using AsyncAPI To generate code
AsyncAPI allows us to describe our messaging endpoints so that we can document our Messaging and Event APIs for others, but AsyncAPI can be used for more than this: it allows us to generate code from that definition. At the simple level, this is how we generate HTML documentation, but there are a wider range of use cases:
- We can use AsyncAPI to scaffold our application, allowing us to build our API contract-first then generate the matching code for both our producers and consumers.
- We can use AsyncAPI to register our message schemas with a registry for validation, allowing us to be strict about what we send (or receive).
- We can use AsyncAPI to create the infrastructure that we need for messaging such as topics, queue and their permissions.
Derived from how we use AsyncAPI day-to-day for these tasks at Just Eat Takeaway, in this talk we will build simple versions of our tools that demonstrate how to generate code from your AsyncAPI definitions in C#, JavaScript and Go to fulfil the above use cases.
As a result of this talk you should understand code generation from AsyncAPI and how to provide added value to your developers from their AsyncAPI definitions, encouraging the spread of AsyncAPI within your organisation.

Ian Cooper
Coding architect, pierced, bearded, tattooed
London, United Kingdom
Links
Please note that Sessionize is not responsible for the accuracy or validity of the data provided by speakers. If you suspect this profile to be fake or spam, please let us know.
Jump to top