Class: Portfolios
api/entities/Identity/Portfolios.Portfolios
Handles all Portfolio related functionality on the Identity side
Hierarchy
-
Namespace
<Identity
>↳
Portfolios
Methods
delete
▸ delete(args
, opts?
): Promise
<GenericPolymeshTransaction
<void
, void
>>
Delete a Portfolio by ID
Parameters
Name | Type |
---|---|
args | Object |
args.portfolio | BigNumber | NumberedPortfolio |
opts? | ProcedureOpts |
Returns
Promise
<GenericPolymeshTransaction
<void
, void
>>
Note
required role:
- Portfolio Custodian
Note
this method is of type ProcedureMethod, which means you can call delete.checkAuthorization on it to see whether the signing Account and Identity have the required roles and permissions to run it
Defined in
api/entities/Identity/Portfolios.ts:213
getCustodiedPortfolios
▸ getCustodiedPortfolios(paginationOpts?
): Promise
<ResultSet
<NumberedPortfolio
| DefaultPortfolio
>>
Retrieve all Portfolios custodied by this Identity. This only includes portfolios owned by a different Identity but custodied by this one. To fetch Portfolios owned by this Identity, use getPortfolios
Parameters
Name | Type |
---|---|
paginationOpts? | PaginationOptions |
Returns
Promise
<ResultSet
<NumberedPortfolio
| DefaultPortfolio
>>
Note
supports pagination
Defined in
api/entities/Identity/Portfolios.ts:92
getPortfolio
▸ getPortfolio(): Promise
<DefaultPortfolio
>
Retrieve a Numbered Portfolio or the Default Portfolio if Portfolio ID is not passed
Returns
Promise
<DefaultPortfolio
>
Defined in
api/entities/Identity/Portfolios.ts:139
▸ getPortfolio(args
): Promise
<NumberedPortfolio
>
Parameters
Name | Type |
---|---|
args | Object |
args.portfolioId | BigNumber |
Returns
Promise
<NumberedPortfolio
>
Defined in
api/entities/Identity/Portfolios.ts:140
getPortfolioByName
▸ getPortfolioByName(args
): Promise
<NumberedPortfolio
>
Retrieve a Numbered Portfolio by its name
Parameters
Name | Type |
---|---|
args | Object |
args.name | string |
Returns
Promise
<NumberedPortfolio
>
Throws
if no Portfolio exists with the given name
Defined in
api/entities/Identity/Portfolios.ts:175
getPortfolios
▸ getPortfolios(): Promise
<[DefaultPortfolio
, ...NumberedPortfolio[]]>
Retrieve all the Portfolios owned by this Identity
Returns
Promise
<[DefaultPortfolio
, ...NumberedPortfolio[]]>
Defined in
api/entities/Identity/Portfolios.ts:61
getTransactionHistory
▸ getTransactionHistory(filters?
): Promise
<HistoricSettlement
[]>
Retrieve a list of transactions where this identity was involved. Can be filtered using parameters
Parameters
Name | Type | Description |
---|---|---|
filters | Object | - |
filters.account? | string | Account involved in the settlement |
filters.assetId? | string | - |
filters.ticker? | string | Deprecated in favour of assetId |
Returns
Promise
<HistoricSettlement
[]>
Note
uses the middlewareV2