GithubHelp home page GithubHelp logo

JSON API conformity about hypermedia HOT 3 CLOSED

cosullivan avatar cosullivan commented on June 20, 2024
JSON API conformity

from hypermedia.

Comments (3)

cosullivan avatar cosullivan commented on June 20, 2024

Hi,

Sorry for the delay in the reply. Is your client side model using int's or string's for the ID's?

I will look at putting in an option to correct that according to the spec, however you can obviously force it to be a string by making your ID properties on your models as int's or Guid's.

If you are using the Hypermedia packages on the server too, then you can currently apply a post-process over the JSON prior to it being sent to the client and resolve that yourself for now. Take a look at how this is being used in the sample;
https://github.com/cosullivan/Hypermedia/blob/master/Src/Hypermedia.Sample.WebApi/Services/JsonApiMetadataMediaTypeFormatter.cs

Thanks,
Cain.

from hypermedia.

 avatar commented on June 20, 2024

Hi Cain,

thank you for the answer. We use both integers and UUIDs. With the JSON API we process both as strings. An option to specify strings as IDs would be very welcome.

Regards,
Jochen

from hypermedia.

hughesjs avatar hughesjs commented on June 20, 2024

I'm closing this because it's stale and the account that raised it has been deleted, if anyone else has this issue please feel free to reopen

from hypermedia.

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.