6 karma · joined Feb 18, 2017 (9y ago) · 5 submissions
comment 2y ago · link · parent
This is an example the author created of TypeSpec being used to generate clients in many languages as well as the OpenAPI spec.
comment 2y ago · link · parent
One of the key things with having the spec is that you can actually describe a lot more than you can with the various attributes and comments in the code. Especially things that are not as much service concerns but potentially client concerns or documentation concerns. You can also encapsulate reusable API patterns so you know different operations are following the same pattern.
The author didn't go into all the details but there are lots of ways in TypeSpec to separate the concerns of different consumers of the spec. There is a lot of opportunity and creative thinking that can be done here.
comment 2y ago · link · parent
Server side codegen is also one the horizon and is a key way to keep the spec and service in sync. So many possibilities here!