Upload Organization Photo
Upload the brand logo or image of the organization. With this API, you can also update an existing organization's logo or image.
Endpoints
Request URL
{api-domain}/bigin/v2/org/photo
Choose domain-specific URL to replace {api-domain}
You can use the domain-specific URL to access Bigin resources. Based on the data center in which the Bigin account's resources are available, replace {api-domain} in the preceding request with one of the following API domain URLs:
- For US, https://www.zohoapis.com
- For EU, https://www.zohoapis.eu
- For AU, https://www.zohoapis.com.au
- For IN, https://www.zohoapis.in
- For CN, https://www.zohoapis.com.cn
- For JP, https://www.zohoapis.jp
For more information, see Multi DC Support.
Authorization
For this endpoint, pass the access token as an authorization header. See OAuth Authentication for more information about access tokens.
Authorization: Zoho-oauthtoken <ACCESS_TOKEN>
You must authenticate using an access token that is associated with one of the following scopes:
- ZohoBigin.org.ALL
- ZohoBigin.org.CREATE
- ZohoBigin.org.WRITE
Request parameters
The available request parameters are given below:
Body parameters
file fileRequired
This parameter represents the logo or image file to be uploaded. It should be included in the request body using the multipart/form-data encoding. The file size should not exceed 1 Mb. Make sure to provide the logo or image path and extension for proper file upload.
Sample request
Copiedcurl "https://www.zohoapis.com/bigin/v2/org/photo"
-X POST
-H "Authorization: Zoho-oauthtoken 1000.8cb99dxxxxxxxxxxxxx9be93.9b8xxxxxxxxxxxxxxxf"
-F "file=@"/path-to-file/logo.png""
Copiedphoto = invokeUrl
[
url: "https://pbs.twimg.com/profile_images/1212572524128563200/w2ub-ATf_400x400.jpg"
type: GET
];
photo.setParamName("file");
response = invokeurl
[
url: "https://www.zohoapis.com/bigin/v1/org/photo"
type: POST
files: photo
connection:"bigin_oauth_connection"
];
Response object
The response object provides information regarding the success message or status.
Possible error codes
The response of this resource includes HTTP status and error codes.
The most common HTTP error codes that occur when you request access to this endpoint are given in the following:
Unsupported Media Type 415
FILE_SIZE_MORE_THAN_ALLOWED_SIZE
Message: Image resolution is more than allowed limit 10 MP, please upload after resizing image dimension or choose other image
Resolution: Make sure that the image or logo you are attempting to upload meets the specified requirements. It should not exceed the allowed file size of 1 Mb or the allowed resolution of 10 MP.
Sample response
Copied{
"code": "SUCCESS",
"details": {},
"message": "photo uploaded successfully",
"status": "success"
}