> For clean Markdown of any page, append .md to the page URL.
> For a complete documentation index, see https://developer.saturnos.com/llms.txt.
> For AI client integration (Claude Code, Cursor, etc.), connect to the MCP server at https://developer.saturnos.com/_mcp/server.

# Update employee

PATCH https://<provided-by-saturn>/partner/employees/{saturn_ref_id}
Content-Type: application/json

Partial update of `first_name`, `last_name`, `role`, `gender` or `fca_number`. Only the fields you send are changed.

`email` cannot be changed here — it is the login identifier, so changing it is an identity change rather than a profile edit.

**Role changes are restricted.** Moving an employee out of SUPPORT or "CLIENT MANAGER" while they still hold active assignments returns **422**: the assignments would be left pointing at someone who can no longer act on them. Remove the assignments first, then change the role.

Your organisation is derived from your API key. There is no field for naming an organisation or a CRM, and any unrecognised field in the body returns 400 rather than being ignored — so a misunderstanding surfaces immediately instead of silently doing nothing.

Reference: https://developer.saturnos.com/partner/employees/update-employee

## Authentication

- `Authorization` header (required) — API Key authentication via header

## Request

### Path parameters

- `saturn_ref_id` (string, required)

### Body (application/json)

This endpoint expects an object.

- `role` (string, required)

## Response

### 200

Successful response

## Examples

**Request**

```json
{
  "role": "DIRECTOR"
}
```

**Response**

```json
{}
```

**SDK Code**

```python Employees_Update employee_example
import requests

url = "https://api.example.com/partner/employees/saturn_ref_id"

payload = { "role": "DIRECTOR" }
headers = {
    "Authorization": "<apiKey>",
    "Content-Type": "application/json"
}

response = requests.patch(url, json=payload, headers=headers)

print(response.json())
```

```javascript Employees_Update employee_example
const url = 'https://api.example.com/partner/employees/saturn_ref_id';
const options = {
  method: 'PATCH',
  headers: {Authorization: '<apiKey>', 'Content-Type': 'application/json'},
  body: '{"role":"DIRECTOR"}'
};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
```

```go Employees_Update employee_example
package main

import (
	"fmt"
	"strings"
	"net/http"
	"io"
)

func main() {

	url := "https://api.example.com/partner/employees/saturn_ref_id"

	payload := strings.NewReader("{\n  \"role\": \"DIRECTOR\"\n}")

	req, _ := http.NewRequest("PATCH", url, payload)

	req.Header.Add("Authorization", "<apiKey>")
	req.Header.Add("Content-Type", "application/json")

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := io.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}
```

```ruby Employees_Update employee_example
require 'uri'
require 'net/http'

url = URI("https://api.example.com/partner/employees/saturn_ref_id")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Patch.new(url)
request["Authorization"] = '<apiKey>'
request["Content-Type"] = 'application/json'
request.body = "{\n  \"role\": \"DIRECTOR\"\n}"

response = http.request(request)
puts response.read_body
```

```java Employees_Update employee_example
import com.mashape.unirest.http.HttpResponse;
import com.mashape.unirest.http.Unirest;

HttpResponse<String> response = Unirest.patch("https://api.example.com/partner/employees/saturn_ref_id")
  .header("Authorization", "<apiKey>")
  .header("Content-Type", "application/json")
  .body("{\n  \"role\": \"DIRECTOR\"\n}")
  .asString();
```

```php Employees_Update employee_example
<?php
require_once('vendor/autoload.php');

$client = new \GuzzleHttp\Client();

$response = $client->request('PATCH', 'https://api.example.com/partner/employees/saturn_ref_id', [
  'body' => '{
  "role": "DIRECTOR"
}',
  'headers' => [
    'Authorization' => '<apiKey>',
    'Content-Type' => 'application/json',
  ],
]);

echo $response->getBody();
```

```csharp Employees_Update employee_example
using RestSharp;

var client = new RestClient("https://api.example.com/partner/employees/saturn_ref_id");
var request = new RestRequest(Method.PATCH);
request.AddHeader("Authorization", "<apiKey>");
request.AddHeader("Content-Type", "application/json");
request.AddParameter("application/json", "{\n  \"role\": \"DIRECTOR\"\n}", ParameterType.RequestBody);
IRestResponse response = client.Execute(request);
```

```swift Employees_Update employee_example
import Foundation

let headers = [
  "Authorization": "<apiKey>",
  "Content-Type": "application/json"
]
let parameters = ["role": "DIRECTOR"] as [String : Any]

let postData = JSONSerialization.data(withJSONObject: parameters, options: [])

let request = NSMutableURLRequest(url: NSURL(string: "https://api.example.com/partner/employees/saturn_ref_id")! as URL,
                                        cachePolicy: .useProtocolCachePolicy,
                                    timeoutInterval: 10.0)
request.httpMethod = "PATCH"
request.allHTTPHeaderFields = headers
request.httpBody = postData as Data

let session = URLSession.shared
let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in
  if (error != nil) {
    print(error as Any)
  } else {
    let httpResponse = response as? HTTPURLResponse
    print(httpResponse)
  }
})

dataTask.resume()
```