Introducing Yelp's GraphQL API
31–40 of 54 posts
Re: Introducing Yelp's GraphQL API
#32Can someone explain why GraphQL was designed to be non-JSON? Seems like a stupid decision, unless I'm missing something.
Your question doesn't really make sense. You are specifying the data that you want back from the API. What gain would be using key:value syntax be in this situation? The request would just be littered with `"requested_data": true` which is just wasteful.
Re: Introducing Yelp's GraphQL API
#33Nooooooooooo! Don't choose my favorite Taco spot as your sample query. The line is already too long.
Re: Introducing Yelp's GraphQL API
#34It's really validating to see Yelp putting a GraphQL API out there as there were a number of questions on whether or not GraphQL made sense as we approached introducing a new API. We (Kiva) also just released our own GraphQL API, though very much in "Beta" it is available at https://api.kivaws.org/graphql with some general API info at https://build.kiva.org We're still working on documentation among other things befo…
Re: Introducing Yelp's GraphQL API
#35Earlier quoted context omitted.
Your question doesn't really make sense. You are specifying the data that you want back from the API. What gain would be using key:value syntax be in this situation? The request would just be littered with `"requested_data": true` which is just wasteful.
Equally important to note: the result of a GraphQL query is valid JSON.
Re: Introducing Yelp's GraphQL API
#36Re: Introducing Yelp's GraphQL API
#37What language or tech stack has been used to implement this API?
Re: Introducing Yelp's GraphQL API
#38Another option for providing a queryable RESTful API interface is OData http://www.odata.org/
I now see people on HN have very similar complaints about GraphQL - how its power and flexibility makes making a performant and secure GraphQL backend significantly harder than making an oldschool REST API backend.
We ended up regex-parsing the OData query fragments that our app happened to use and made it work. We felt dirty for months after, though.
Does anyone have experience with both? Is GraphQL any better than OData in server-side implementability?
Re: Introducing Yelp's GraphQL API
#39Is it possible to do more complex requests in GraphQL, like getting the favorite venues of people that favored "Garaje" or is it left to the API provider?
Yes.. Its left to the API provider. Try https://learngraphql.com gives a very good idea of what graphql is. Way better than reading the official documentation or spec. Once I went through it, made up my mind that our API as a service product should support Graphql. Note: I am in no way related to the site.. It is free and I finally actually understood what graphql is in 15 mins.