User Profiles Banner Photo
To use an image from the Files page as a user banner photo, pass the file ID in the fileId property of the request body or in the fileId request parameter. Images uploaded on the User Profile page don’t have a file ID and can’t be used as the fileId.
To upload a binary file as the user banner photo, send it in a multipart/form-data message. For information about how to create the multipart/form-data message, see Uploading Binary Files.
- Resource
-
/connect/user-profiles/userId/banner-photo
/connect/communities/communityId/user-profiles/userId/banner-photo
- Available version
- 36.0
- Requires Chatter
- Yes
- HTTP methods
- GET, HEAD, POST, DELETE
- Request body for POST
-
- Root XML tag
- <bannerPhoto>
- JSON example
-
{ "cropHeight" : "120", "cropWidth" : "240", "fileId" : "069D00000001IOh" }
- Properties
-
- Request parameters for POST
-
Name Type Description Required or Optional Available Version cropHeight Integer The length of an edge in pixels of the crop rectangle. Optional 36.0 cropWidth Integer The width of an edge in pixels of the crop rectangle. Optional 36.0 cropX Integer The position X in pixels from the left edge of the image to start the crop square. Top left is position (0,0). Optional 36.0 cropY Integer The position Y in pixels from the top edge of the image to start the crop square. Top left is position (0,0). Optional 36.0 fileId String ID of an existing file. The key prefix must be 069 and the file size must be less than 8 MB. Required to use an existing file 36.0 versionNumber Integer Version number of an existing file. If not provided, the latest version is used. Optional 36.0 - Response body for GET and POST
- Banner Photo
- Response body for DELETE
- 204: Successful Delete