This API endpoint allows users to update their own profile information on Voomerr.
Endpoint URL #
POST https://admin.voomerr.com/api/update_profile.php
Parameters #
The following parameters are required to successfully make a request to the API:
Parameter | Type | Required | Description |
---|---|---|---|
user_id | Int | Yes | The ID of the user whose profile is being updated. |
first_name | String | No | The first name of the user. |
phone | String | No | The phone number of the user. |
String | No | The email address of the user. | |
address | String | No | The address of the user. |
image | String | No | The URL of the profile picture of the user. |
is_private | Boolean | No | Indicates whether the user’s profile should be private or not. |
currency | String | No | The currency in which the prices are to be displayed. If not provided, the default currency is used. |
Response #
The API will return a JSON object containing the following fields:
Field | Type | Description |
---|---|---|
success | Bool | Indicates whether the profile update was successful. |
error_code | Int | The error code, if any. |
error_msg | String | A message describing the error, if any. |
data | Object | An object containing the updated profile information for the user, if successful. |
The ‘data’ object will contain the following fields:
Field | Type | Description |
---|---|---|
user_id | Int | The user ID of the updated user. |
first_name | String | The updated first name of the user. |
phone | String | The updated phone number of the user. |
String | The updated email address of the user. | |
address | String | The updated address of the user. |
image | String | The updated URL of the profile picture of the user. |
is_private | Bool | Indicates whether the user’s profile is set to private or not. |
currency | String | The currency in which the prices are to be displayed for the user. |
Example Request #
POST https://admin.voomerr.com/api/update_profile.php
Content-Type: application/json
{
"user_id": 123,
"first_name": "John",
"phone": "555-555-5555",
"email": "john@example.com",
"address": "123 Main St, San Francisco, CA",
"image": "https://example.com/images/john.jpg",
"is_private": false,
"currency": "USD"
}
Example Response #
HTTP/1.1 200 OK
Content-Type: application/json
{
"success": true,
"data": {
"user_id": 123,
"first_name": "John",
"phone": "555-555-5555",
"email": "john@example.com",
"address": "123 Main St, San Francisco, CA",
"image": "https://example.com/images/john.jpg",
"is_private": false,