Commit 3636579 1 parent 1c88d05 commit 3636579 Copy full SHA for 3636579
File tree 2 files changed +328
-56
lines changed
2 files changed +328
-56
lines changed Original file line number Diff line number Diff line change
1
+ import { Asset } from "stellar-base" ;
1
2
import { CallBuilder } from "./call_builder" ;
2
3
import { ServerApi } from "./server_api" ;
3
4
@@ -29,4 +30,27 @@ export class AccountCallBuilder extends CallBuilder<ServerApi.AccountRecord> {
29
30
this . filter . push ( [ "accounts" , id ] ) ;
30
31
return this ;
31
32
}
33
+
34
+ /**
35
+ * This endpoint filters accounts by signer account.
36
+ * @see [Accounts](https://www.stellar.org/developers/horizon/reference/endpoints/accounts.html)
37
+ * @param {string } value For example: `GDGQVOKHW4VEJRU2TETD6DBRKEO5ERCNF353LW5WBFW3JJWQ2BRQ6KDD`
38
+ * @returns {AccountCallBuilder } current AccountCallBuilder instance
39
+ */
40
+ public forSigner ( id : string ) {
41
+ this . url . setQuery ( "signer" , id ) ;
42
+ return this ;
43
+ }
44
+
45
+ /**
46
+ * This endpoint filters all accounts who are trustees to an asset.
47
+ * @see [Accounts](https://www.stellar.org/developers/horizon/reference/endpoints/accounts.html)
48
+ * @see Asset
49
+ * @param {Asset } value For example: `new Asset('USD','GDGQVOKHW4VEJRU2TETD6DBRKEO5ERCNF353LW5WBFW3JJWQ2BRQ6KDD')`
50
+ * @returns {AccountCallBuilder } current AccountCallBuilder instance
51
+ */
52
+ public forAsset ( asset : Asset ) {
53
+ this . url . setQuery ( "asset" , `${ asset } ` ) ;
54
+ return this ;
55
+ }
32
56
}
You can’t perform that action at this time.
0 commit comments