Skip to content

Commit bb17667

Browse files
authored
Merge pull request #89 from nash-io/ts/deprecate-getaccountportfolio
Ts/deprecate getaccountportfolio
2 parents a7b4902 + a124b86 commit bb17667

File tree

5 files changed

+17
-1
lines changed

5 files changed

+17
-1
lines changed

CHANGELOG.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,11 @@
22

33
All notable changes to this project will be documented in this file. See [standard-version](https://github.com/conventional-changelog/standard-version) for commit guidelines.
44

5+
<a name="6.3.5"></a>
6+
## [6.3.5](https://github.com/nash-io/api-client-typescript/compare/v6.3.3...v6.3.5) (2021-10-07)
7+
8+
9+
510
<a name="6.3.3"></a>
611
## [6.3.3](https://github.com/nash-io/api-client-typescript/compare/v6.3.1...v6.3.3) (2021-09-27)
712

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "@neon-exchange/api-client-typescript",
3-
"version": "6.3.3",
3+
"version": "6.3.5",
44
"description": "Official TypeScript client for interacting with the Nash exchange",
55
"main": "build/main/index.js",
66
"typings": "build/main/index.d.ts",

src/client/client.ts

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1575,6 +1575,9 @@ export class Client {
15751575
fiatSymbol,
15761576
period
15771577
}: GetAccountPortfolioParams = {}): Promise<AccountPortfolio> {
1578+
console.warn(
1579+
'getAccountPortfolio is deprecated. Please use listAccountBalances'
1580+
)
15781581
const result = await this.gql.query<{
15791582
getAccountPortfolio: AccountPortfolio
15801583
}>({

src/queries/account/fragments/accountBalance.ts

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,12 @@ export const ACCOUNT_BALANCE_FRAGMENT = gql`
1717
personal {
1818
...currencyAmountFields
1919
}
20+
staked {
21+
...currencyAmountFields
22+
}
23+
total {
24+
...currencyAmountFields
25+
}
2026
asset {
2127
...assetFields
2228
}

src/types/balance.ts

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,5 +6,7 @@ export interface AccountBalance {
66
inOrders: CurrencyAmount
77
pending: CurrencyAmount
88
personal: CurrencyAmount
9+
staked: CurrencyAmount
10+
total: CurrencyAmount
911
depositAddress: string
1012
}

0 commit comments

Comments
 (0)