|
|
|
|
|
by somada141
2896 days ago
|
|
I find that REST was 'perfect' given the status-quo of APIs at the time it came out. It allowed for massive simplification of APIs compared to its XML-based predecessors and enabled every man and his dog to make a half-decent semi-standardized API. For better of for worse as things progressed new requirements and complicating factors like the ones you mentioned (filtering, pagination, need for dynamism etc) came up that ended up being handled in a dozen different ways muddying up the waters. To me, GraphQL built on top of REST to cover those bases and IMHO that's how these technology standards are supposed to evolve: thing comes up, it gets used till previously unknown requirements surface, new thing learning from old thing and addressing new requirements comes up. I was really bothered when I realised that GraphQL doesn't allow for heterogeneous input-type unions though, cause that makes filtering a hassle (eg if you wanna have a query that can take an arbitrary number of filters for fields of different types). |
|