function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
Jamie ThompsonJamie Thompson 

How can I use Chatter API to update profile with PATCH method?

Hello - I'm using the Chatter API for iOS and Android. I was wondering if anyone has any code samples of using the PATCH method for updating profile parameters - where the values are in the json/xml?  I can't seem to find any samples. 

Does this help?
Jamie ThompsonJamie Thompson
Thanks Jody - do you have any code samples for the PATCH method for nickname, name, avatar?  I'm guessing this would be communityNickname, displayName and photo?

There's a lot of properties there and not much in the way of code samples for them. :( 
Hi Jamie -- the only property you can PATCH with that resource is aboutMe. You can use other Chatter REST API resources to update the user photo (or a group photo) and change email notification settings. To update your name, you need to use the regular REST API:
Jamie ThompsonJamie Thompson
Thanks Jody,

I have tried to updated Account fields successful. But I actually want to update User fields (Name, Nickname...). That was not working for User. I am not sure that I was giving correct uri. Here is the uri. Can you correct me?
Make sure you're using the correct field name and that the field has the Update property.

For example, the User object's FirstName field can be updated. Passing this JSON request body updates the field:

{ "FirstName" : "Natalie" }
Jamie ThompsonJamie Thompson
Thanks Jody. It's working.
Anthony HernandezAnthony Hernandez
Hi Jamie, do you have a working iOS code sample? I've been strugling with this for a while. I can query information very easily, but have stumbled on updating the objects.