diff --git a/README.md b/README.md index a1f1b30e..65a2f6b5 100644 --- a/README.md +++ b/README.md @@ -124,8 +124,8 @@ query { sequenceNumber balances { asset { + id code - native issuer { id } } balance @@ -172,8 +172,6 @@ query { } ``` -*NOTE*: Please note that native balance is returned inside a trustline too, and is marked with the boolean flag. - ## Subscriptions The most exciting and powerful feature of Astrograph is subscriptions. @@ -226,9 +224,9 @@ subscription { account { id } values { asset { + id code issuer { id } - native } balance } diff --git a/examples/balance-cli.ts b/examples/balance-cli.ts index 7be5081d..604365cb 100644 --- a/examples/balance-cli.ts +++ b/examples/balance-cli.ts @@ -24,6 +24,7 @@ client balance limit asset { + id code issuer { id } } @@ -37,6 +38,6 @@ client }) .then((result: { data: any }) => { for (const t of result.data.account.balances) { - console.log("Balance", t.balance, t.id, "with limit", t.limit); + console.log("Balance", t.balance, t.asset.id, "with limit", t.limit); } }); diff --git a/examples/balance-monitor-cli.ts b/examples/balance-monitor-cli.ts index 6f45dda9..8a1ea540 100644 --- a/examples/balance-monitor-cli.ts +++ b/examples/balance-monitor-cli.ts @@ -28,11 +28,13 @@ const SUBSCRIPTION = gql` } mutationType asset { + id code issuer { id } } values { asset { + id code issuer { id } } @@ -69,7 +71,7 @@ apolloClient console.log( "New balance for", - values.id, + values.asset.id, "is now", values.balance, "with limit",