Different RESTful representations of the same resource

后端 未结 5 931
梦毁少年i
梦毁少年i 2020-12-12 14:24

My application has a resource at /foo. Normally, it is represented by an HTTP response payload like this:

{\"a\": \"some text\", \"b\": \"some t         


        
5条回答
  •  暖寄归人
    2020-12-12 15:06

    you could use a second vendor media-type in the request header application/vnd.com.mycompany.resource.rep2, you can't bookmark this however, query-parameters are not cacheable (/foo?sections=a,b,c) you could take a look at matrix-parameters however regarding this question they should be cacheable URL matrix parameters vs. request parameters

提交回复
热议问题