Tenant Display Picture - UPDATE

Tenant Display Picture - UPDATE API Endpoint
StoRegister - Tenant

Update Tenant Profile Display Picture API

The Update Tenant Profile Display Picture API offers a secure endpoint for users to modify their profile images. By making a PUT request to the designated endpoint, logged-in users can update their display pictures. The API supports multipart/form-data with a specified boundary for seamless image uploads.

PUT
/v1/tenant/profile/change-display-picture
Request Content Type
multipart/form-data; boundary=[boundary]
Response Content Type
application/json

Request Header

  • api-key string required

    api-key is a string of letters and numbers, used to authenticate and control access to an API which can be generated in StoRegister management application.
  • token string required

    token refers to wrapped user's legal information (user's credentials) that grants or denies access to the application.

Request Body:

  • profileImage file required

    Form data representation of the logged-in user profile image.

Response Payload:

  • succeeded boolean

    Indicates whether the request to change display picture was successful.
  • status string

    Describes the status of the request to change display picture for the login user.
  • data object

    data containing success id for changes display picture.
  • errors array

    Holds any error information if applicable.

Request Header

Authorization: X-API-Key --api-key--
Authorization: X-Token --token--

API Request

--[boundary]
Content-Disposition: form-data; name="profileImage"; filename="[fileName]"
Content-Type: [fileMimeType]

[fileContent]
--[boundary]--

API Response

{
    "data": "65353E22-C3A6-4600-9DE4-9813D5ECC6B4",
    "succeeded": true,
    "status": "SUCCESS",
    "errors": null
}

Error Codes

  • INVALID_PARAM_CONTACT_BOOK_ID

    INVALID_PARAM_CONTACT_BOOK_ID refers to invalid contact id or invaild user id to retrieve contact details.
  • INVALID_PARAM_FILES

    INVALID_PARAM_FILES refers to invalid Iformfile .
  • IMAGE_UPLOAD_FAILED

    IMAGE_UPLOAD_FAILED refers to image upload failed.
  • NO_RECORDS_FOUND

    NO_RECORDS_FOUND means there is no relevant information found.
  • FAILED

    FAILED refers to an unsuccessful API call.
  • SOMETHING_WENT_WRONG

    SOMETHING_WENT_WRONG refers to technical glitch. Please contact administrator.