Update employee of the center with given catalog details

PUT https://api.zenoti.com/v1/employees/{employee_id}

This API updates the existing employee profile with additional parameters for taking catalog information. If the catalog details are provided then the same will be updated and other values are set to default. If the sub-object catalog details are not passed in the request body, the default values will be set for catalog details ('ShowInCatalog' are set to false and ‘DisplayName' and 'Description’ would be set to empty)..

Note: For information on how to create an employee profile in a center, click here.

You must specify necessary details for the employee_id URI parameter in the API request. If you assign a new role ID to the employee, this API will update the employee's profile with the specified role ID and remove the existing role IDs. For more information on security roles, refer to the Retrieve the list of security roles in a center API.

Optionally, you can specify updated information for any of the request body parameters.

Before you begin

Permission: Manage API Keys (on the Administrator security object) — Required to access Zenoti APIs.

Endpoint

PUT /v1/employees/{employee_id}

Base URL: https://api.zenoti.com

Request

Headers

Header Required Description
Authorization Yes bearer {{access_token}}

Path parameters

Parameter Type Required Description
employee_id string Yes Mandatory Unique 32-character identifier of the employee for whom you want to update profile details.

Query parameters

Parameter Type Required Default Description
expand string (json) No — Additional json keys to display the key value pairs in the response json.

Request body

Field Type Required Description
raw_body string (json) No

Response

Success (200 OK)

{}

Example

curl --request PUT \
  --url 'https://api.zenoti.com/v1/employees/{employee_id}' \
  --header 'Authorization: bearer {{access_token}}' \
  --header 'Content-Type: application/json' \
  --data '{
  "raw_body": "string"
}'
const response = await fetch('https://api.zenoti.com/v1/employees/{employee_id}', {
  method: 'PUT',
  headers: {
    'Authorization': 'bearer {{access_token}}',
    'Content-Type': 'application/json'
  },
  body: JSON.stringify({ raw_body: 'string' })
});
const data = await response.json();
import requests

response = requests.put(
    'https://api.zenoti.com/v1/employees/{employee_id}',
    headers={
        'Authorization': 'bearer {{access_token}}',
    },
    json={'raw_body': 'string'}
)
data = response.json()
using var client = new HttpClient();
client.DefaultRequestHeaders.Add("Authorization", "bearer {{access_token}}");
var content = new StringContent(
    JsonSerializer.Serialize(new { raw_body = "string" }),
    Encoding.UTF8, "application/json");
var response = await client.PutAsync(
    "https://api.zenoti.com/v1/employees/{employee_id}", content);
var data = await response.Content.ReadAsStringAsync();
require 'net/http'
require 'json'

uri = URI('https://api.zenoti.com/v1/employees/{employee_id}')
http = Net::HTTP.new(uri.host, uri.port)
http.use_ssl = true
request = Net::HTTP::Put.new(uri)
request['Authorization'] = 'bearer {{access_token}}'
request['Content-Type'] = 'application/json'
request.body = { raw_body: 'string' }.to_json
response = http.request(request)
data = JSON.parse(response.body)

Error codes

Status Description
400 400
401 Unauthorized -- invalid or expired access token
429 Too many requests -- rate limit exceeded
500 500