bounswe / bounswe2017group6

InterestHub
http://34.209.230.231:8080/
6 stars 10 forks source link

Profile patch validation error #347

Closed gokceuludogan closed 6 years ago

gokceuludogan commented 6 years ago

About

I am trying to patch the user profile with the below request: patchreq

However, I am getting Validation error but I don't know why since it is not defined.

patchres

gokceuludogan commented 6 years ago

Accept: / Accept-Encoding: gzip, deflate Authorization: Bearer eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJlbWFpbCI6Imdva2NldWx1ZG9nYW5AZ21haWwuY29tIiwidXNlcm5hbWUiOiJnb2tjZXVsdWRvZ2FuIiwiZXhwIjoxNTE0MTg5MTgzLCJ1c2VyX2lkIjoxMH0.GaLirbVkUDgsdAVAbkRV_FsQ9PlJQrQSyf2iedpKAQY Content-Length: 284 Content-Type: application/json User-Agent: runscope/0.1 BODY

{ "profile": { "interests": [ { "label": "Person of Interest", "description": "television crime drama series by Jonathan Nolan", "url": "https://www.wikidata.org/wiki/Q564345" }, { "label": "Fringe", "description": "American science fiction television series", "url": "//www.wikidata.org/wiki/Q3815" } ] } }

yhkalayci commented 6 years ago

The reasons for getting this error are:

An important note: If you would like to update some fields of a tag, you must do it with using patch request to /tags/. You can not update description or URL field with using this post request since it only looks the label if the tag has already added to the system.