> For the complete documentation index, see [llms.txt](https://l1x-sdk.gitbook.io/l1x-wallet-sdk/4BgPf6WH50hnVEUCHE22/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://l1x-sdk.gitbook.io/l1x-wallet-sdk/4BgPf6WH50hnVEUCHE22/core-methods/how-to-get-account-state.md).

# How to get Account State?

* **getAccountState:**

Retrieves the account state information from the L1X Core blockchain.

{% code overflow="wrap" lineNumbers="true" fullWidth="false" %}

```typescript
import { L1XProvider, GetAccountStateArg } from "@l1x/l1x-wallet-sdk";

let l1xProvider = new L1XProvider({
  clusterType: "mainnet",
  endpoint: "https://v2-mainnet-rpc.l1x.foundation",
});

const accountStateRequest: GetAccountStateArg = {
  address: "6e371a05d5766c692172744f4907940ef324fcb9",
};

l1xProvider.core
  .getAccountState(accountStateRequest)
  .then((response) => console.log(response))    // log response
  .catch((err) => console.error(err));          // log error

```

{% endcode %}

**Parameters**:

The account state request parameters.

<pre class="language-json"><code class="lang-json"><strong>{
</strong><strong>    "address": "6e371a05d5766c692172744f4907940ef324fcb9"
</strong><strong>}
</strong></code></pre>

**Returns:**

A promise that resolves with the account state response.

```json
{
   "account_state":{
      "balance":"158",
      "nonce":0,
      "account_type":1,
      "balance_formatted":"158000000000000000000"
   }
}
```
