Write OpenAPI with TypeSpec
41–50 of 74 posts
Re: Write OpenAPI with TypeSpec
#42This looks great, is there a converter to convert an OpenAPI yml file to TypeSpec?
Re: Write OpenAPI with TypeSpec
#43Discussion on magick.css from 5 days ago: https://news.ycombinator.com/item?id=39793513
Re: Write OpenAPI with TypeSpec
#44Ooh, magick.css ( https://css.winterveil.net/ ) spotted in the wild! Discussion on magick.css from 5 days ago: https://news.ycombinator.com/item?id=39793513
Re: Write OpenAPI with TypeSpec
#45Re: Write OpenAPI with TypeSpec
#46I don’t see a way to specify the security scheme. Am I missing something?
Re: Write OpenAPI with TypeSpec
#47I don’t see a way to specify the security scheme. Am I missing something?
Re: Write OpenAPI with TypeSpec
#48As someone who has used JAX-RS (Java) and ASP.NET, APIs are basically created with these kinds of annotations right in the language. @GET public Character getCharacter(@PathParam("id") int id) { return db.getCharacter(id); } That's very similar to TypeSpec's op getCharacter(@path id: safeint): Character; Java and C# classes already have the type information that you'd be getting from a TypeSpec: // TypeSpec model Cha…
This is the code-first vs schema-first debate. Both have their pros and cons. Personally a die hard advocate of schema-first.
Then switch as soon as you have customers.
Re: Write OpenAPI with TypeSpec
#49What are people's thoughts on this vs AWS's Smithy? We've been looking to buy into Smithy heavily as we no longer have the appetite to deal with OpenAPI and it's horrendous ecosystem.
I would pick Smithy if I had to go spec-first. I currently tolerate OpenAPI because I'm using a robust code-first approach (Tapir in Scala) on the server side, but I otherwise agree, the ecosystem seems brittle.
This is an example the author created of TypeSpec being used to generate clients in many languages as well as the OpenAPI spec.