Coder Social home page Coder Social logo

Comments (8)

ms-ati avatar ms-ati commented on June 22, 2024

All: please try to restrain yourselves from the xkcd multiple competing standards links.

from http-api-design.

geemus avatar geemus commented on June 22, 2024

Both the design outlined in this guide and in jsonapi have similar goals, but we disagree on some specifics. I think we do complement one another in exploring the same problem space and we certainly do agree on a number of points, but I'm not sure how we can improve compatibility around those places in which we disagree. That said, I'm also not sure I entirely understand what you envision in terms of an ideal future. In an ideal world, what do you imagine compatibility would look like?

from http-api-design.

ms-ati avatar ms-ati commented on June 22, 2024

Good question. In an ideal world?

Perhaps there are some specifics that differ for no good reason, and these can be unified after discussion. Perhaps there are other specifics that may differ due to actually different goals, and these differences in goals can be examined and explained.

Ultimately, I think in the web development community we'd like to pick one standard, and design libraries which adhere to the standard. That's my interest, at least, for starting the conversation about this.

Alternatively, competition can drive excellence. Perhaps both projects can market why they think their individual differences are better. But again, that requires being aware of and minutely examining the differences.

Does that make sense?

from http-api-design.

geemus avatar geemus commented on June 22, 2024

Yeah, I think so. Thanks for taking the time to dig in, I wanted to try and speak to your particular concerns rather than just glazing over things.

In my view one of the biggest differences is about where to communicate the shape of the API. We do it using schemas, which are out-of-band. So you fetch a schema to see what links are available, how to do various operations, what attributes are valid etc. jsonapi instead passes this and a lot of related information over the wire with things like links envelopes. I think that these sorts of things should remain relatively stable and be cacheable (which can be done via headers with a schema, but not so much with links that come back with all requests). I think that is probably the most fundamental difference, but I suspect it informs many of the smaller differences that bubble up around the edges.

We have chosen json-schema as the standard to base our schema upon and have seen others also move toward this (ie https://github.com/pandastrike/jsck). Similarly we have seen others in the space, like swagger and blueprint, starting to adopt more json-schema usage in their tooling. I think this does offer some of what you hope for, namely that there are a few projects working on different edges but with more of a shared core. Unfortunately jsonapi does not provide a json-schema and indicates that they don't believe json-schema can fully represent their design, so they are not really able to participate in this part of things.

So, we hope at least to be moving toward the sort of ideal you mention, but maybe not in quite the same part of the ecosystem as jsonapi is. Does that help/make sense?

from http-api-design.

ms-ati avatar ms-ati commented on June 22, 2024

Thank you that is very helpful. So much so, that I was wondering if it might make sense to capture this text, or a variation of it, in a document that is part of what you publish. Maybe a FAQ "How does this project differ from jsonapi.org?", or such?

from http-api-design.

geemus avatar geemus commented on June 22, 2024

Quite possibly. I have a few revisions I hope to undertake, but seem never to quite get to. In the mean time I'll certainly leave the issue here for others to find and hopefully I'll find a good home for it in a future revision. Thanks for asking about it and certainly let me know if you have further questions or concerns.

from http-api-design.

oliverbarnes avatar oliverbarnes commented on June 22, 2024

Not sure if this is a new development, but jsonapi does have a schema now, fwiw

from http-api-design.

geemus avatar geemus commented on June 22, 2024

Cool, thanks for the heads up!

from http-api-design.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.