Slack v0.23.5 Slack.Web.Users.Profile View Source
Link to this section Summary
Link to this section Functions
Link to this function
get(optional_params \\ %{}) View Source
Retrieves a user's profile information.
Optional Params
include_labels
- Include labels for each ID in custom profile fields ex:true
user
- User to retrieve profile info for ex:W1234567890
Errors the API can return:
user_not_found
- Value passed foruser
was invalid.
Link to this function
set(optional_params \\ %{}) View Source
Set the profile information for a user.
Optional Params
name
- Name of a single key to set. Usable only ifprofile
is not passed. ex:first_name
profile
- Collection of key:value pairs presented as a URL-encoded JSON hash. At most 50 fields may be set. Each field name is limited to 255 characters. ex:{ first_name: "John", ... }
user
- User to retrieve profile info for ex:W1234567890
value
- Value to set a single key to. Usable only ifprofile
is not passed. ex:John
Errors the API can return:
cannot_update_admin_user
- Only a primary owner can update the profile of an admin.invalid_profile
- Profile object passed in is not valid JSON (make sure it is URL encoded!).not_admin
- Only admins can update the profile of another user. Some fields, like email may only be updated by an admin.not_app_admin
- Only team owners and selected members can update the profile of a bot user.profile_set_failed
- Failed to set user profile.reserved_name
- First or last name are reserved.