Skip to main content
POST
/
sdk
/
{environmentId}
/
businessAccounts
/
{businessAccountId}
/
transferOwnership
SDK — transfer ownership of a business account
curl --request POST \
  --url https://app.dynamicauth.com/api/v0/sdk/{environmentId}/businessAccounts/{businessAccountId}/transferOwnership \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "newOwnerUserId": "3c90c3cc-0d44-4b50-8888-8dd25736052a"
}
'
import requests

url = "https://app.dynamicauth.com/api/v0/sdk/{environmentId}/businessAccounts/{businessAccountId}/transferOwnership"

payload = { "newOwnerUserId": "3c90c3cc-0d44-4b50-8888-8dd25736052a" }
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}

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

print(response.text)
const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({newOwnerUserId: '3c90c3cc-0d44-4b50-8888-8dd25736052a'})
};

fetch('https://app.dynamicauth.com/api/v0/sdk/{environmentId}/businessAccounts/{businessAccountId}/transferOwnership', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));
<?php

$curl = curl_init();

curl_setopt_array($curl, [
CURLOPT_URL => "https://app.dynamicauth.com/api/v0/sdk/{environmentId}/businessAccounts/{businessAccountId}/transferOwnership",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'newOwnerUserId' => '3c90c3cc-0d44-4b50-8888-8dd25736052a'
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json"
],
]);

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}
package main

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

func main() {

url := "https://app.dynamicauth.com/api/v0/sdk/{environmentId}/businessAccounts/{businessAccountId}/transferOwnership"

payload := strings.NewReader("{\n \"newOwnerUserId\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\"\n}")

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

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

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

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

fmt.Println(string(body))

}
HttpResponse<String> response = Unirest.post("https://app.dynamicauth.com/api/v0/sdk/{environmentId}/businessAccounts/{businessAccountId}/transferOwnership")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"newOwnerUserId\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\"\n}")
.asString();
require 'uri'
require 'net/http'

url = URI("https://app.dynamicauth.com/api/v0/sdk/{environmentId}/businessAccounts/{businessAccountId}/transferOwnership")

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

request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"newOwnerUserId\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\"\n}"

response = http.request(request)
puts response.read_body
{
  "id": "95b11417-f18f-457f-8804-68e361f9164f",
  "projectEnvironmentId": "95b11417-f18f-457f-8804-68e361f9164f",
  "members": [
    {
      "id": "95b11417-f18f-457f-8804-68e361f9164f",
      "businessAccountId": "95b11417-f18f-457f-8804-68e361f9164f",
      "userId": "95b11417-f18f-457f-8804-68e361f9164f",
      "addedByUserId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
      "createdAt": "2023-11-07T05:31:56Z"
    }
  ],
  "signers": [
    {
      "id": "95b11417-f18f-457f-8804-68e361f9164f",
      "businessAccountId": "95b11417-f18f-457f-8804-68e361f9164f",
      "walletId": "95b11417-f18f-457f-8804-68e361f9164f",
      "userId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
      "shareSetId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
      "derivedFromUserId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
      "apiKeyIdentityRef": "<string>",
      "expiresAt": "2023-11-07T05:31:56Z",
      "revokedAt": "2023-11-07T05:31:56Z",
      "createdAt": "2023-11-07T05:31:56Z"
    }
  ],
  "name": "<string>",
  "externalRef": "<string>",
  "metadata": {},
  "createdAt": "2023-11-07T05:31:56Z",
  "updatedAt": "2023-11-07T05:31:56Z",
  "wallets": [
    {
      "id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
      "publicKey": "<string>",
      "createdAt": "2023-11-07T05:31:56Z"
    }
  ]
}
{
"error": "<string>"
}
{
"error": "No jwt provided!"
}
{
"error": {
"code": "<string>",
"message": "<string>"
},
"payload": {
"walletPublicKey": "0xbF394748301603f18d953C90F0b087CBEC0E1834",
"email": "jsmith@example.com"
}
}
{
"error": "Not Found",
"code": "not_found"
}
{
"error": "Conflict: invalid state transition"
}
{
"error": "Internal Server Error"
}

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Path Parameters

environmentId
string
required

ID of the environment

Required string length: 36
Pattern: ^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$
Example:

"95b11417-f18f-457f-8804-68e361f9164f"

businessAccountId
string
required

ID of the business account

Required string length: 36
Pattern: ^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$
Example:

"95b11417-f18f-457f-8804-68e361f9164f"

Body

application/json

SDK transferOwnership body. Promotes newOwnerUserId (must already be a member) to owner and demotes the current owner to admin, atomically.

newOwnerUserId
string<uuid>
required

Response

Ownership transferred; updated business account returned

SDK-side business account response with embedded members, signers, and wallets. Origin 2 callers (low member count) get everything in one fetch; if a business account ever needs pagination we add a separate paginated list endpoint without changing this shape.

id
string
required
Required string length: 36
Pattern: ^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$
Example:

"95b11417-f18f-457f-8804-68e361f9164f"

projectEnvironmentId
string
required
Required string length: 36
Pattern: ^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$
Example:

"95b11417-f18f-457f-8804-68e361f9164f"

members
object[]
required
signers
object[]
required
name
string | null
Maximum string length: 255
externalRef
string | null

Developer-supplied stable ID inside the env

Maximum string length: 255
metadata
object
createdAt
string<date-time>
updatedAt
string<date-time>
wallets
object[]

Wallets bound to this business account via Wallets.business_account_id. Superset of signers[].walletId — a wallet exists before any signer row is minted on it (staged-then-resolved lifecycle).

Last modified on July 13, 2026