> For the complete documentation index, see [llms.txt](https://docs.leather.io/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.leather.io/developers/stacks-methods/stx_getaddresses.md).

# stx\_getAddresses

Request the Bitcoin and Stacks addresses for the active account of the user's wallet, using the SIP-030 method name.

## Method name

`stx_getAddresses`

`stx_getAddresses` is the [SIP-030](https://github.com/stacksgov/sips/blob/main/sips/sip-030/sip-030-wallet-interface.md) name for [`getAddresses`](/developers/methods/getaddresses.md). Leather runs both through the same connection flow and returns the same response shape, so the guidance on the `getAddresses` page applies here too: every call opens a connection prompt, and addresses must be read by `symbol` and `type`, never by index.

Unlike `getAddresses`, it takes no `chains` parameter. It always requests both Bitcoin and Stacks addresses.

## **Parameters**

| Parameter             | Description                                                                                                                                              | Required | Type      |
| --------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------- | -------- | --------- |
| `network`             | Network identifier                                                                                                                                       | ❌        | `string`  |
| `allowPolicyAccounts` | Currently has no effect: Leather offers multisig vaults on every request. See [Multisig accounts](/developers/methods/getaddresses.md#multisig-accounts) | ❌        | `boolean` |

## **Example request**

```typescript
try {
  const response = await window.LeatherProvider.request("stx_getAddresses");

  const stxAddress = response.result.addresses.find(
    (address) => address.symbol === "STX"
  );

  console.log("Stacks address:", stxAddress?.address);
} catch (error) {
  console.log("Request error:", error);
}
```

## Example Response

```json
{
    "jsonrpc": "2.0",
    "id": "288a4a32-899b-47da-ac43-b6adbb8caec2",
    "result": {
        "addresses": [
            {
                "symbol": "BTC",
                "type": "p2wpkh",
                "address": "bc1qetcn9fdtzq3wez6vrljjyry225ml7j52h3kwgl",
                "publicKey": "0328e268de2bd09f703b379d20b8a53fdc9c599a09a8c2fcd9c35e7b3cc48d0ece",
                "derivationPath": "m/84'/0'/1'/0/0",
                "descriptor": "wpkh(xpub...)",
                "fingerprint": "..."
            },
            {
                "symbol": "BTC",
                "type": "p2tr",
                "address": "bc1ph65ywff65f0nl84xaxwdxgc2rc2gpr70tptllffktt3qzyx859zsp3zvwl",
                "publicKey": "03482aa14965b71358082b110a30b91ef8dfbe6fbae3b18f5b841323f599b954f8",
                "tweakedPublicKey": "482aa14965b71358082b110a30b91ef8dfbe6fbae3b18f5b841323f599b954f8",
                "derivationPath": "m/86'/0'/1'/0/0",
                "descriptor": "tr(xpub...)",
                "fingerprint": "..."
            },
            {
                "symbol": "STX",
                "kind": "single-sig",
                "address": "SPY0682ZM7VGPMVGQP99Z05J3QWMVV83RA6N42SA",
                "publicKey": "..."
            }
        ]
    }
}
```
