> ## Documentation Index
> Fetch the complete documentation index at: https://www.dynamic.xyz/docs/llms.txt
> Use this file to discover all available pages before exploring further.

# Create a Business Account

> Create a business account in Unity, then list, read, and rename it.

> [!NOTE]
>
> Business Accounts are in **early access**. See [Business Accounts](https://www.dynamic.xyz/docs/business-accounts/accounts.md) for the model.

Create a business account as an authenticated user. You become the **owner**, and can then add [wallets](https://www.dynamic.xyz/docs/unity/business-accounts/add-wallets.md), [signers](https://www.dynamic.xyz/docs/unity/business-accounts/manage-signers.md), and [members](https://www.dynamic.xyz/docs/unity/business-accounts/members-and-roles.md). Every business account operation lives on `DynamicSDK.Instance.BusinessAccounts`.

## Prerequisites

* `DynamicSDK` initialized with your environment ID (see the [installation guide](https://www.dynamic.xyz/docs/unity/installation-guide.md))
* An authenticated user, because account operations act on behalf of the signed-in user
* Business Accounts enabled for your environment

## Create an account

`Create` takes an optional `name`, `externalRef`, and `metadata`, and returns the new account.

```csharp theme={"system"}
using System.Collections.Generic;
using DynamicSDK.Models.BusinessAccounts;
using UnityEngine;

var account = await DynamicSDK.Instance.BusinessAccounts.Create(
    name: "Acme Treasury",
    externalRef: "org_acme_123",
    metadata: new Dictionary<string, object> { { "tier", "enterprise" } });

Debug.Log(account.Id); // use this to add wallets, signers, and members
```

**name** `string`

Display name for the account.

**externalRef** `string`

A developer-supplied label for mapping your own org or tenant ID onto this account. Not unique, so multiple accounts may share a value.

**metadata** `object`

Arbitrary key-value metadata stored alongside the account.

The returned `BusinessAccount` has `Id`, `Name`, `ExternalRef`, `Metadata`, `ProjectEnvironmentId`, `CreatedAt`, and `UpdatedAt`.

## List accounts

`List` returns the accounts the current user is a member of, for the active environment. Pass `externalRefs` to filter by your own org or tenant IDs.

```csharp theme={"system"}
var list = await DynamicSDK.Instance.BusinessAccounts.List();

foreach (var item in list.Items ?? new List<BusinessAccount>())
{
    Debug.Log(item.Name ?? item.Id);
}

// Filter by your own references
var filtered = await DynamicSDK.Instance.BusinessAccounts.List(
    new List<string> { "org_acme_123" });
```

`BusinessAccountList` returns `Items` plus a `NextCursor` for paging.

## Read one account

`Get` returns the account plus its `Members`, `Signers`, and `Wallets`.

```csharp theme={"system"}
var detail = await DynamicSDK.Instance.BusinessAccounts.Get(account.Id);

Debug.Log(detail.Members.Count);
Debug.Log(detail.Signers.Count);
Debug.Log(detail.Wallets?.Count ?? 0);
```

Each entry in `detail.Wallets` is a `BusinessAccountWalletSummary` with `Id`, `Chain`, and `PublicKey`. Use the `Id` when you [add or remove wallets](https://www.dynamic.xyz/docs/unity/business-accounts/add-wallets.md) and when you [manage signers](https://www.dynamic.xyz/docs/unity/business-accounts/manage-signers.md).

> [!TIP]
>
> Only members of an account can read it. A request from a non-member returns 404 rather than 403, so account existence is not leaked across tenants.

## Rename an account

`Update` changes the account name.

```csharp theme={"system"}
var renamed = await DynamicSDK.Instance.BusinessAccounts.Update(
    account.Id, "Acme Operating Funds");
```

## On error

Every method returns a `UniTask` that throws on failure. Wrap calls in `try/catch` and show the failure to the player:

```csharp theme={"system"}
try
{
    var account = await DynamicSDK.Instance.BusinessAccounts.Create(name: "Acme Treasury");
    Debug.Log(account.Id);
}
catch (System.Exception e)
{
    Debug.LogError($"Failed to create business account: {e.Message}");
}
```

## Next steps

> [card] [Add wallets](https://www.dynamic.xyz/docs/unity/business-accounts/add-wallets.md)
>
> Link an embedded wallet to the account.

> [card] [Members and roles](https://www.dynamic.xyz/docs/unity/business-accounts/members-and-roles.md)
>
> Add admins and viewers, and transfer ownership.


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.