Live data from Hacker News

Introspected REST: An Alternative to REST and GraphQL

introspected.rest

61–64 of 64 posts

Re: Introspected REST: An Alternative to REST and GraphQL

#61
post #6

Earlier quoted context omitted.

Yeah seriously... +1 to this. Even just a handful of examples of client and server usage would be far more useful for determining if it’s worth digging deeper

This is a formal proposition. If it catches on I expect others to explain it in various levels of complexity but this document is intended to be dense and deeply descriptive.

Sure, but couldn't it begin with an executive summary?

If you take RFCs as an example, many start with a simplified description or problem statement before then proceeding to get into the details.

Re: Introspected REST: An Alternative to REST and GraphQL

#62

Can we just have back SOAP/WSDL and return to rational design and interoperability, or at least limit "REST" to a web facade? I think after 10-15 years of mucking around with "REST" (or what people think it is, as rightfully pointed out in TFA) it's very clear that there's not going to be a common understanding, let alone standard for it. As a freelancer having worked on maintaining many "REST" trainwrecks, I can tel…

OpenAPI is gaining momentum.

3GPP for example have adopted it for several interfaces inside the 5G core network.

https://en.m.wikipedia.org/wiki/OpenAPI_Specification

Re: Introspected REST: An Alternative to REST and GraphQL

#63
Generally speaking, I think a lot of developers get into trouble by not really putting the effort into grasping the ideology of architectural frameworks like REST, 12factor, and React.

For example, our API needed a way to serve a different view of an existing model. How do I get the API to know which view to serve? When I asked around, they said the best way was to do /cars/1/prices, which I didn't like because I feel it breaks REST. There's no price model to the car, prices are fields of cars, at least for now.

I had to think for a few seconds before coming up with just using a query parameter to set which view to serve, /cars/1?view=pricelist, preserving REST. But most coders just take the first thing that comes to mind, and then wonder why their applications are so messy after a few years.

Coders seem to not want to bother learning how existing solutions are supposed to work before jumping to a half-baked newer solution just because it seems more intuitive. If you understand REST, then you can see how GraphQL can improve certain aspects of API interaction.

But it's not a panacea any more than React is. If you understood how HTML, CSS, and Javascript are supposed to work, then you can see how React improves on it. But if you can't then your React applications will be just as horrendous as your jQuery ones were.

Re: Introspected REST: An Alternative to REST and GraphQL

#64
post #12

This looks a lot like OData - a REST-ful API standard with schema introspection, patterns for defining and traversing resource relationships, well-defined guidance around mechanics, tooling support. In particular, the "Microtypes" concept resembles how entities work in OData - rich query support for collections (eg. sorts, filters, order by), "expansions" on related resources, even inheritance semantics (ie. being ab…

The fact that OData calls itself not only RESTful, but literally "the best way to REST", while using requests like this: GET serviceRoot/People('russellwhyte')/Microsoft.OData.SampleService.Models.TripPin.GetFavoriteAirline() is an absolute insult to REST and the target developer audience. https://www.odata.org/getting-started/basic-tutorial/#bounde...

[deleted]
Post reply on HN