Skip to content

Commit

Permalink
Update the documentation
Browse files Browse the repository at this point in the history
  • Loading branch information
leganz committed Jul 4, 2020
1 parent f7be0e7 commit 70466f6
Showing 1 changed file with 5 additions and 24 deletions.
29 changes: 5 additions & 24 deletions docs/accounts/getAccountCurrencies.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
# Get an accocunt
# Get the currencies for a account

Getting an account (= wallet) is easy. What you need to know is the wallet id (= starts with ARDOR-*)
If you need the informatin which currency an account has. Please be aware that the [monetary system](https://ardordocs.jelurida.com/Monetary_system) within is meant with this endpoint. This endpoint will not provide detailed information for you ignis or ardor holdings.
We recommend to use the [getAccount](getAccount.md) endpoint for that purpose.

```php

Expand All @@ -12,32 +13,12 @@ use \AMBERSIVE\Ardor\Models\ArdorAccount;
public function returnAcccountData():ArdorAccount {

$ardor = new ArdorAccounts();
$account = $ardor->getAccount('ARDOR-DAZJ-VVSM-552M-8K459');
$currencies = $ardor->getAccountCurrencies('ARDOR-DAZJ-VVSM-552M-8K459');

}
```

The account method also provides some addtional parameter.

```php
public function getAccount(String $account, array $more = []):ArdorAccount
```

The $more paramter will be merged into the body. What kind of parameter make sense can be extracted form the original documentation from ardor => [https://ardordocs.jelurida.com/Accounts#Get_Account](https://ardordocs.jelurida.com/Accounts#Get_Account)

An example could look like:

```php


$ardor = new ArdorAccounts();
$account = $ardor->getAccount('ARDOR-DAZJ-VVSM-552M-8K459', [
'includeEffectiveBalance' => 'true'
]);

```

This will automatically add the NQT Balance to the response. Please note that the related attribute in the object is always present.
The official [documentation](https://ardordocs.jelurida.com/Accounts#Get_Account_Currencies) for this endpoint providesa a detailed documentation.

---
Return to the [overview](../overview.md) page for all topics.

0 comments on commit 70466f6

Please sign in to comment.