> For the complete documentation index, see [llms.txt](https://api.my.nethesis.it/llms.txt)

# /customers/{id}/transfer - Change the customer manager

> PATCH /customers/{id}/transfer
> 
> Move the customer under another managing organization (reseller or
> distributor) by rewriting its `custom_data.createdBy`, in Logto and
> locally. Allowed to the Owner organization and to distributors, for a
> customer inside their hierarchy (403 otherwise). An unusable target is
> a 400 on key `organization_id` with message `not_in_hierarchy` or
> `not_a_manager` (not a reseller or distributor).
> 
> Systems, users, backups and alert history stay with the customer and
> follow it: visibility, rebranding and the alerting tenant derive from
> the manager. What belongs to the manager it leaves goes away: add-ons
> bought by that side stop renewing (they stay valid until they expire),
> its silences on the customer's systems are removed, alerts assigned to
> its users are released. The response carries the applied counters.



## Servers
- Backend API server: https://my.nethesis.it/backend/api (Backend API server)


## Authentication methods
- Bearer auth


## Parameters

### Path parameters

- **id** (string)
  Customer Logto ID



### Body: application/json (object)

- **organization_id** (string)
  Logto ID of the reseller or distributor that will manage the customer



## Responses
### 200
Customer transferred

#### Body: application/json (object)
- **code** (integer)

- **message** (string)

- **data** (object)


### 400
Bad request - validation error

#### Body: application/json (object)
- **code** (integer)
  HTTP error code

- **message** (string)
  Error message

- **data** (object)


### 401
Unauthorized - invalid or missing token

#### Body: application/json (object)
- **code** (integer)

- **message** (string)

- **data** (object | null)


### 403
Forbidden - insufficient permissions

#### Body: application/json (object)
- **code** (integer)

- **message** (string)

- **data** (object | null)


### 404
Resource not found

#### Body: application/json (object)
- **code** (integer)
  HTTP error code

- **message** (string)
  Error message

- **data** (object)


### 409
The customer cannot be transferred in its current state. `data.type`
is `validation_error`, on key `transfer`, with stable `message` codes:
`customer_is_suspended` (reactivate it first), `customer_not_synced`
(no Logto organization yet), `same_organization` (already managed by
the target), `target_is_suspended`, `transfer_in_progress` (another
transfer of the same customer is running).


#### Body: application/json (object)
- **code** (integer)
  HTTP error code

- **message** (string)
  Error message

- **data** (object)



[Powered by Bump.sh](https://bump.sh)
