sdk.lusid.api.transaction_portfolios_api.TransactionPortfoliosApi

class TransactionPortfoliosApi(api_client=None)[source]

NOTE: This class is auto generated by OpenAPI Generator Ref: https://openapi-generator.tech

Do not edit the class manually.

Methods

adjust_holdings

AdjustHoldings: Adjust holdings # noqa: E501

adjust_holdings_with_http_info

AdjustHoldings: Adjust holdings # noqa: E501

batch_adjust_holdings

[EARLY ACCESS] BatchAdjustHoldings: Batch adjust holdings # noqa: E501

batch_adjust_holdings_with_http_info

[EARLY ACCESS] BatchAdjustHoldings: Batch adjust holdings # noqa: E501

batch_create_trade_tickets

[EARLY ACCESS] BatchCreateTradeTickets: Batch Create Trade Tickets # noqa: E501

batch_create_trade_tickets_with_http_info

[EARLY ACCESS] BatchCreateTradeTickets: Batch Create Trade Tickets # noqa: E501

batch_upsert_transactions

[EARLY ACCESS] BatchUpsertTransactions: Batch upsert transactions # noqa: E501

batch_upsert_transactions_with_http_info

[EARLY ACCESS] BatchUpsertTransactions: Batch upsert transactions # noqa: E501

build_transactions

BuildTransactions: Build transactions # noqa: E501

build_transactions_with_http_info

BuildTransactions: Build transactions # noqa: E501

cancel_adjust_holdings

CancelAdjustHoldings: Cancel adjust holdings # noqa: E501

cancel_adjust_holdings_with_http_info

CancelAdjustHoldings: Cancel adjust holdings # noqa: E501

cancel_transactions

CancelTransactions: Cancel transactions # noqa: E501

cancel_transactions_with_http_info

CancelTransactions: Cancel transactions # noqa: E501

create_portfolio

CreatePortfolio: Create portfolio # noqa: E501

create_portfolio_with_http_info

CreatePortfolio: Create portfolio # noqa: E501

create_trade_ticket

[EARLY ACCESS] CreateTradeTicket: Create Trade Ticket # noqa: E501

create_trade_ticket_with_http_info

[EARLY ACCESS] CreateTradeTicket: Create Trade Ticket # noqa: E501

delete_custodian_accounts

[EXPERIMENTAL] DeleteCustodianAccounts: Soft or hard delete multiple custodian accounts # noqa: E501

delete_custodian_accounts_with_http_info

[EXPERIMENTAL] DeleteCustodianAccounts: Soft or hard delete multiple custodian accounts # noqa: E501

delete_properties_from_transaction

DeletePropertiesFromTransaction: Delete properties from transaction # noqa: E501

delete_properties_from_transaction_with_http_info

DeletePropertiesFromTransaction: Delete properties from transaction # noqa: E501

get_a2_b_data

GetA2BData: Get A2B data # noqa: E501

get_a2_b_data_with_http_info

GetA2BData: Get A2B data # noqa: E501

get_a2_b_movements

GetA2BMovements: Get an A2B report at the movement level for the given portfolio.

get_a2_b_movements_with_http_info

GetA2BMovements: Get an A2B report at the movement level for the given portfolio.

get_bucketed_cash_flows

[EXPERIMENTAL] GetBucketedCashFlows: Get bucketed cash flows from a list of portfolios # noqa: E501

get_bucketed_cash_flows_with_http_info

[EXPERIMENTAL] GetBucketedCashFlows: Get bucketed cash flows from a list of portfolios # noqa: E501

get_custodian_account

[EXPERIMENTAL] GetCustodianAccount: Get Custodian Account # noqa: E501

get_custodian_account_with_http_info

[EXPERIMENTAL] GetCustodianAccount: Get Custodian Account # noqa: E501

get_details

GetDetails: Get details # noqa: E501

get_details_with_http_info

GetDetails: Get details # noqa: E501

get_holding_contributors

[EARLY ACCESS] GetHoldingContributors: Get Holdings Contributors # noqa: E501

get_holding_contributors_with_http_info

[EARLY ACCESS] GetHoldingContributors: Get Holdings Contributors # noqa: E501

get_holdings

GetHoldings: Get holdings # noqa: E501

get_holdings_adjustment

GetHoldingsAdjustment: Get holdings adjustment # noqa: E501

get_holdings_adjustment_with_http_info

GetHoldingsAdjustment: Get holdings adjustment # noqa: E501

get_holdings_with_http_info

GetHoldings: Get holdings # noqa: E501

get_holdings_with_orders

[EXPERIMENTAL] GetHoldingsWithOrders: Get holdings with orders # noqa: E501

get_holdings_with_orders_with_http_info

[EXPERIMENTAL] GetHoldingsWithOrders: Get holdings with orders # noqa: E501

get_portfolio_cash_flows

[BETA] GetPortfolioCashFlows: Get portfolio cash flows # noqa: E501

get_portfolio_cash_flows_with_http_info

[BETA] GetPortfolioCashFlows: Get portfolio cash flows # noqa: E501

get_portfolio_cash_ladder

GetPortfolioCashLadder: Get portfolio cash ladder # noqa: E501

get_portfolio_cash_ladder_with_http_info

GetPortfolioCashLadder: Get portfolio cash ladder # noqa: E501

get_portfolio_cash_statement

GetPortfolioCashStatement: Get portfolio cash statement # noqa: E501

get_portfolio_cash_statement_with_http_info

GetPortfolioCashStatement: Get portfolio cash statement # noqa: E501

get_transaction_history

[EARLY ACCESS] GetTransactionHistory: Get the history of a transaction # noqa: E501

get_transaction_history_with_http_info

[EARLY ACCESS] GetTransactionHistory: Get the history of a transaction # noqa: E501

get_transactions

GetTransactions: Get transactions # noqa: E501

get_transactions_with_http_info

GetTransactions: Get transactions # noqa: E501

get_upsertable_portfolio_cash_flows

[BETA] GetUpsertablePortfolioCashFlows: Get upsertable portfolio cash flows.

get_upsertable_portfolio_cash_flows_with_http_info

[BETA] GetUpsertablePortfolioCashFlows: Get upsertable portfolio cash flows.

list_custodian_accounts

[EXPERIMENTAL] ListCustodianAccounts: List Custodian Accounts # noqa: E501

list_custodian_accounts_with_http_info

[EXPERIMENTAL] ListCustodianAccounts: List Custodian Accounts # noqa: E501

list_holdings_adjustments

ListHoldingsAdjustments: List holdings adjustments # noqa: E501

list_holdings_adjustments_with_http_info

ListHoldingsAdjustments: List holdings adjustments # noqa: E501

patch_portfolio_details

[EARLY ACCESS] PatchPortfolioDetails: Patch portfolio details # noqa: E501

patch_portfolio_details_with_http_info

[EARLY ACCESS] PatchPortfolioDetails: Patch portfolio details # noqa: E501

resolve_instrument

[EARLY ACCESS] ResolveInstrument: Resolve instrument # noqa: E501

resolve_instrument_with_http_info

[EARLY ACCESS] ResolveInstrument: Resolve instrument # noqa: E501

set_holdings

SetHoldings: Set holdings # noqa: E501

set_holdings_with_http_info

SetHoldings: Set holdings # noqa: E501

upsert_custodian_accounts

[EXPERIMENTAL] UpsertCustodianAccounts: Upsert Custodian Accounts # noqa: E501

upsert_custodian_accounts_properties

[EXPERIMENTAL] UpsertCustodianAccountsProperties: Upsert custodian accounts properties # noqa: E501

upsert_custodian_accounts_properties_with_http_info

[EXPERIMENTAL] UpsertCustodianAccountsProperties: Upsert custodian accounts properties # noqa: E501

upsert_custodian_accounts_with_http_info

[EXPERIMENTAL] UpsertCustodianAccounts: Upsert Custodian Accounts # noqa: E501

upsert_portfolio_details

UpsertPortfolioDetails: Upsert portfolio details # noqa: E501

upsert_portfolio_details_with_http_info

UpsertPortfolioDetails: Upsert portfolio details # noqa: E501

upsert_transaction_properties

UpsertTransactionProperties: Upsert transaction properties # noqa: E501

upsert_transaction_properties_with_http_info

UpsertTransactionProperties: Upsert transaction properties # noqa: E501

upsert_transactions

UpsertTransactions: Upsert transactions # noqa: E501

upsert_transactions_with_http_info

UpsertTransactions: Upsert transactions # noqa: E501

adjust_holdings(scope, code, effective_at, adjust_holding_request, reconciliation_methods=None, async_req=None, **kwargs)[source]

AdjustHoldings: Adjust holdings # noqa: E501

Adjust one or more holdings of the specified transaction portfolio to the provided targets. LUSID will automatically construct adjustment transactions to ensure that the holdings which have been adjusted are always set to the provided targets for the specified effective datetime. Read more about the difference between adjusting and setting holdings here https://support.lusid.com/how-do-i-adjust-my-holdings. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True

>>> thread = api.adjust_holdings(scope, code, effective_at, adjust_holding_request, reconciliation_methods, async_req=True)
>>> result = thread.get()
Parameters:
  • scope (str) – The scope of the transaction portfolio. (required)

  • code (str) – The code of the transaction portfolio. Together with the scope this uniquely identifies the transaction portfolio. (required)

  • effective_at (str) – The effective datetime or cut label at which the holdings should be set to the provided targets. (required)

  • adjust_holding_request (List[AdjustHoldingRequest]) – The selected set of holdings to adjust to the provided targets for the transaction portfolio. (required)

  • reconciliation_methods (List[str]) – Optional parameter for specifying a reconciliation method: e.g. FxForward.

  • async_req (bool, optional) – Whether to execute the request asynchronously.

  • _request_timeout – timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts.

Returns:

Returns the result object. If the method is called asynchronously, returns the request thread.

Return type:

AdjustHolding

adjust_holdings_with_http_info(scope, code, effective_at, adjust_holding_request, reconciliation_methods=None, **kwargs)[source]

AdjustHoldings: Adjust holdings # noqa: E501

Adjust one or more holdings of the specified transaction portfolio to the provided targets. LUSID will automatically construct adjustment transactions to ensure that the holdings which have been adjusted are always set to the provided targets for the specified effective datetime. Read more about the difference between adjusting and setting holdings here https://support.lusid.com/how-do-i-adjust-my-holdings. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True

>>> thread = api.adjust_holdings_with_http_info(scope, code, effective_at, adjust_holding_request, reconciliation_methods, async_req=True)
>>> result = thread.get()
Parameters:
  • scope (str) – The scope of the transaction portfolio. (required)

  • code (str) – The code of the transaction portfolio. Together with the scope this uniquely identifies the transaction portfolio. (required)

  • effective_at (str) – The effective datetime or cut label at which the holdings should be set to the provided targets. (required)

  • adjust_holding_request (List[AdjustHoldingRequest]) – The selected set of holdings to adjust to the provided targets for the transaction portfolio. (required)

  • reconciliation_methods (List[str]) – Optional parameter for specifying a reconciliation method: e.g. FxForward.

  • async_req (bool, optional) – Whether to execute the request asynchronously.

  • _preload_content (bool, optional) – if False, the ApiResponse.data will be set to none and raw_data will store the HTTP response body without reading/decoding. Default is True.

  • _return_http_data_only (bool, optional) – response data instead of ApiResponse object with status code, headers, etc

  • _request_timeout – timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts.

  • _request_auth (dict, optional) – set to override the auth_settings for an a single request; this effectively ignores the authentication in the spec for a single request.

Returns:

Returns the result object. If the method is called asynchronously, returns the request thread.

Return type:

tuple(AdjustHolding, status_code(int), headers(HTTPHeaderDict))

batch_adjust_holdings(scope, code, success_mode, request_body, reconciliation_methods=None, async_req=None, **kwargs)[source]

[EARLY ACCESS] BatchAdjustHoldings: Batch adjust holdings # noqa: E501

Adjust one or more holdings of the specified transaction portfolio to the provided targets. LUSID will automatically construct adjustment transactions to ensure that the holdings which have been adjusted are always set to the provided targets for the specified effective datetime in each request. Each request must be keyed by a unique correlation id. This id is ephemeral and is not stored by LUSID. It serves only as a way to easily identify each adjustment in the response. Note: If using partial failure modes, then it is important to check the response body for failures as any failures will still return a 200 status code # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True

>>> thread = api.batch_adjust_holdings(scope, code, success_mode, request_body, reconciliation_methods, async_req=True)
>>> result = thread.get()
Parameters:
  • scope (str) – The scope of the transaction portfolio. (required)

  • code (str) – The code of the transaction portfolio. Together with the scope this uniquely identifies the transaction portfolio. (required)

  • success_mode (str) – Whether the batch request should fail Atomically or in a Partial fashion - Allowed Values: Atomic, Partial (required)

  • request_body (Dict[str, AdjustHoldingForDateRequest]) – The selected set of holdings to adjust to the provided targets for the transaction portfolio. (required)

  • reconciliation_methods (List[str]) – Optional parameter for specifying a reconciliation method: e.g. FxForward.

  • async_req (bool, optional) – Whether to execute the request asynchronously.

  • _request_timeout – timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts.

Returns:

Returns the result object. If the method is called asynchronously, returns the request thread.

Return type:

BatchAdjustHoldingsResponse

batch_adjust_holdings_with_http_info(scope, code, success_mode, request_body, reconciliation_methods=None, **kwargs)[source]

[EARLY ACCESS] BatchAdjustHoldings: Batch adjust holdings # noqa: E501

Adjust one or more holdings of the specified transaction portfolio to the provided targets. LUSID will automatically construct adjustment transactions to ensure that the holdings which have been adjusted are always set to the provided targets for the specified effective datetime in each request. Each request must be keyed by a unique correlation id. This id is ephemeral and is not stored by LUSID. It serves only as a way to easily identify each adjustment in the response. Note: If using partial failure modes, then it is important to check the response body for failures as any failures will still return a 200 status code # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True

>>> thread = api.batch_adjust_holdings_with_http_info(scope, code, success_mode, request_body, reconciliation_methods, async_req=True)
>>> result = thread.get()
Parameters:
  • scope (str) – The scope of the transaction portfolio. (required)

  • code (str) – The code of the transaction portfolio. Together with the scope this uniquely identifies the transaction portfolio. (required)

  • success_mode (str) – Whether the batch request should fail Atomically or in a Partial fashion - Allowed Values: Atomic, Partial (required)

  • request_body (Dict[str, AdjustHoldingForDateRequest]) – The selected set of holdings to adjust to the provided targets for the transaction portfolio. (required)

  • reconciliation_methods (List[str]) – Optional parameter for specifying a reconciliation method: e.g. FxForward.

  • async_req (bool, optional) – Whether to execute the request asynchronously.

  • _preload_content (bool, optional) – if False, the ApiResponse.data will be set to none and raw_data will store the HTTP response body without reading/decoding. Default is True.

  • _return_http_data_only (bool, optional) – response data instead of ApiResponse object with status code, headers, etc

  • _request_timeout – timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts.

  • _request_auth (dict, optional) – set to override the auth_settings for an a single request; this effectively ignores the authentication in the spec for a single request.

Returns:

Returns the result object. If the method is called asynchronously, returns the request thread.

Return type:

tuple(BatchAdjustHoldingsResponse, status_code(int), headers(HTTPHeaderDict))

batch_create_trade_tickets(scope, code, lusid_trade_ticket, async_req=None, **kwargs)[source]

[EARLY ACCESS] BatchCreateTradeTickets: Batch Create Trade Tickets # noqa: E501

Batch create trade tickets. Each ticket is broadly equivalent to a singular call to upsert an instrument, then a counterparty and finally a transaction that makes use of the two. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True

>>> thread = api.batch_create_trade_tickets(scope, code, lusid_trade_ticket, async_req=True)
>>> result = thread.get()
Parameters:
  • scope (str) – The scope of the transaction portfolio. (required)

  • code (str) – The code of the transaction portfolio. Together with the scope this uniquely identifies the transaction portfolio. (required)

  • lusid_trade_ticket (List[LusidTradeTicket]) – the trade tickets to create (required)

  • async_req (bool, optional) – Whether to execute the request asynchronously.

  • _request_timeout – timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts.

Returns:

Returns the result object. If the method is called asynchronously, returns the request thread.

Return type:

CreateTradeTicketsResponse

batch_create_trade_tickets_with_http_info(scope, code, lusid_trade_ticket, **kwargs)[source]

[EARLY ACCESS] BatchCreateTradeTickets: Batch Create Trade Tickets # noqa: E501

Batch create trade tickets. Each ticket is broadly equivalent to a singular call to upsert an instrument, then a counterparty and finally a transaction that makes use of the two. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True

>>> thread = api.batch_create_trade_tickets_with_http_info(scope, code, lusid_trade_ticket, async_req=True)
>>> result = thread.get()
Parameters:
  • scope (str) – The scope of the transaction portfolio. (required)

  • code (str) – The code of the transaction portfolio. Together with the scope this uniquely identifies the transaction portfolio. (required)

  • lusid_trade_ticket (List[LusidTradeTicket]) – the trade tickets to create (required)

  • async_req (bool, optional) – Whether to execute the request asynchronously.

  • _preload_content (bool, optional) – if False, the ApiResponse.data will be set to none and raw_data will store the HTTP response body without reading/decoding. Default is True.

  • _return_http_data_only (bool, optional) – response data instead of ApiResponse object with status code, headers, etc

  • _request_timeout – timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts.

  • _request_auth (dict, optional) – set to override the auth_settings for an a single request; this effectively ignores the authentication in the spec for a single request.

Returns:

Returns the result object. If the method is called asynchronously, returns the request thread.

Return type:

tuple(CreateTradeTicketsResponse, status_code(int), headers(HTTPHeaderDict))

batch_upsert_transactions(scope, code, success_mode, request_body, preserve_properties=None, async_req=None, **kwargs)[source]

[EARLY ACCESS] BatchUpsertTransactions: Batch upsert transactions # noqa: E501

Create or update transactions in the transaction portfolio. A transaction will be updated if it already exists and created if it does not. Each request must be keyed by a unique correlation id. This id is ephemeral and is not stored by LUSID. It serves only as a way to easily identify each transaction in the response. Note: If using partial failure modes, then it is important to check the response body for failures as any failures will still return a 200 status code # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True

>>> thread = api.batch_upsert_transactions(scope, code, success_mode, request_body, preserve_properties, async_req=True)
>>> result = thread.get()
Parameters:
  • scope (str) – The scope of the transaction portfolio. (required)

  • code (str) – The code of the transaction portfolio. Together with the scope this uniquely identifies the transaction portfolio. (required)

  • success_mode (str) – Whether the batch request should fail Atomically or in a Partial fashion - Allowed Values: Atomic, Partial. (required)

  • request_body (Dict[str, TransactionRequest]) – The payload describing the transactions to be created or updated. (required)

  • preserve_properties (bool) – If set to false, the entire property set will be overwritten by the provided properties. If not specified or set to true, only the properties provided will be updated.

  • async_req (bool, optional) – Whether to execute the request asynchronously.

  • _request_timeout – timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts.

Returns:

Returns the result object. If the method is called asynchronously, returns the request thread.

Return type:

BatchUpsertPortfolioTransactionsResponse

batch_upsert_transactions_with_http_info(scope, code, success_mode, request_body, preserve_properties=None, **kwargs)[source]

[EARLY ACCESS] BatchUpsertTransactions: Batch upsert transactions # noqa: E501

Create or update transactions in the transaction portfolio. A transaction will be updated if it already exists and created if it does not. Each request must be keyed by a unique correlation id. This id is ephemeral and is not stored by LUSID. It serves only as a way to easily identify each transaction in the response. Note: If using partial failure modes, then it is important to check the response body for failures as any failures will still return a 200 status code # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True

>>> thread = api.batch_upsert_transactions_with_http_info(scope, code, success_mode, request_body, preserve_properties, async_req=True)
>>> result = thread.get()
Parameters:
  • scope (str) – The scope of the transaction portfolio. (required)

  • code (str) – The code of the transaction portfolio. Together with the scope this uniquely identifies the transaction portfolio. (required)

  • success_mode (str) – Whether the batch request should fail Atomically or in a Partial fashion - Allowed Values: Atomic, Partial. (required)

  • request_body (Dict[str, TransactionRequest]) – The payload describing the transactions to be created or updated. (required)

  • preserve_properties (bool) – If set to false, the entire property set will be overwritten by the provided properties. If not specified or set to true, only the properties provided will be updated.

  • async_req (bool, optional) – Whether to execute the request asynchronously.

  • _preload_content (bool, optional) – if False, the ApiResponse.data will be set to none and raw_data will store the HTTP response body without reading/decoding. Default is True.

  • _return_http_data_only (bool, optional) – response data instead of ApiResponse object with status code, headers, etc

  • _request_timeout – timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts.

  • _request_auth (dict, optional) – set to override the auth_settings for an a single request; this effectively ignores the authentication in the spec for a single request.

Returns:

Returns the result object. If the method is called asynchronously, returns the request thread.

Return type:

tuple(BatchUpsertPortfolioTransactionsResponse, status_code(int), headers(HTTPHeaderDict))

build_transactions(scope, code, transaction_query_parameters, as_at=None, filter=None, property_keys=None, limit=None, page=None, async_req=None, **kwargs)[source]

BuildTransactions: Build transactions # noqa: E501

Builds and returns all transactions that affect the holdings of a portfolio over a given interval of effective time into a set of output transactions. This includes transactions automatically generated by LUSID such as holding adjustments. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True

>>> thread = api.build_transactions(scope, code, transaction_query_parameters, as_at, filter, property_keys, limit, page, async_req=True)
>>> result = thread.get()
Parameters:
  • scope (str) – The scope of the transaction portfolio. (required)

  • code (str) – The code of the transaction portfolio. Together with the scope this uniquely identifies the transaction portfolio. (required)

  • transaction_query_parameters (TransactionQueryParameters) – The query queryParameters which control how the output transactions are built. (required)

  • as_at (datetime) – The asAt datetime at which to build the transactions. Defaults to return the latest version of each transaction if not specified.

  • filter (str) – Expression to filter the result set. For example, to return only transactions with a transaction type of ‘Buy’, specify “type eq ‘Buy’”. For more information about filtering LUSID results, see https://support.lusid.com/knowledgebase/article/KA-01914.

  • property_keys (List[str]) – A list of property keys from the “Instrument” or “Transaction” domain to decorate onto the transactions. These take the format {domain}/{scope}/{code} e.g. “Instrument/system/Name” or “Transaction/strategy/quantsignal”.

  • limit (int) – When paginating, limit the number of returned results to this many. Defaults to 100 if not specified.

  • page (str) – The pagination token to use to continue listing transactions from a previous call to BuildTransactions.

  • async_req (bool, optional) – Whether to execute the request asynchronously.

  • _request_timeout – timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts.

Returns:

Returns the result object. If the method is called asynchronously, returns the request thread.

Return type:

VersionedResourceListOfOutputTransaction

build_transactions_with_http_info(scope, code, transaction_query_parameters, as_at=None, filter=None, property_keys=None, limit=None, page=None, **kwargs)[source]

BuildTransactions: Build transactions # noqa: E501

Builds and returns all transactions that affect the holdings of a portfolio over a given interval of effective time into a set of output transactions. This includes transactions automatically generated by LUSID such as holding adjustments. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True

>>> thread = api.build_transactions_with_http_info(scope, code, transaction_query_parameters, as_at, filter, property_keys, limit, page, async_req=True)
>>> result = thread.get()
Parameters:
  • scope (str) – The scope of the transaction portfolio. (required)

  • code (str) – The code of the transaction portfolio. Together with the scope this uniquely identifies the transaction portfolio. (required)

  • transaction_query_parameters (TransactionQueryParameters) – The query queryParameters which control how the output transactions are built. (required)

  • as_at (datetime) – The asAt datetime at which to build the transactions. Defaults to return the latest version of each transaction if not specified.

  • filter (str) – Expression to filter the result set. For example, to return only transactions with a transaction type of ‘Buy’, specify “type eq ‘Buy’”. For more information about filtering LUSID results, see https://support.lusid.com/knowledgebase/article/KA-01914.

  • property_keys (List[str]) – A list of property keys from the “Instrument” or “Transaction” domain to decorate onto the transactions. These take the format {domain}/{scope}/{code} e.g. “Instrument/system/Name” or “Transaction/strategy/quantsignal”.

  • limit (int) – When paginating, limit the number of returned results to this many. Defaults to 100 if not specified.

  • page (str) – The pagination token to use to continue listing transactions from a previous call to BuildTransactions.

  • async_req (bool, optional) – Whether to execute the request asynchronously.

  • _preload_content (bool, optional) – if False, the ApiResponse.data will be set to none and raw_data will store the HTTP response body without reading/decoding. Default is True.

  • _return_http_data_only (bool, optional) – response data instead of ApiResponse object with status code, headers, etc

  • _request_timeout – timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts.

  • _request_auth (dict, optional) – set to override the auth_settings for an a single request; this effectively ignores the authentication in the spec for a single request.

Returns:

Returns the result object. If the method is called asynchronously, returns the request thread.

Return type:

tuple(VersionedResourceListOfOutputTransaction, status_code(int), headers(HTTPHeaderDict))

cancel_adjust_holdings(scope, code, effective_at, async_req=None, **kwargs)[source]

CancelAdjustHoldings: Cancel adjust holdings # noqa: E501

Cancel all previous holding adjustments made on the specified transaction portfolio for a specified effective datetime. This should be used to undo holding adjustments made via set holdings or adjust holdings. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True

>>> thread = api.cancel_adjust_holdings(scope, code, effective_at, async_req=True)
>>> result = thread.get()
Parameters:
  • scope (str) – The scope of the transaction portfolio. (required)

  • code (str) – The code of the transaction portfolio. Together with the scope this uniquely identifies the transaction portfolio. (required)

  • effective_at (str) – The effective datetime or cut label at which the holding adjustments should be undone. (required)

  • async_req (bool, optional) – Whether to execute the request asynchronously.

  • _request_timeout – timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts.

Returns:

Returns the result object. If the method is called asynchronously, returns the request thread.

Return type:

DeletedEntityResponse

cancel_adjust_holdings_with_http_info(scope, code, effective_at, **kwargs)[source]

CancelAdjustHoldings: Cancel adjust holdings # noqa: E501

Cancel all previous holding adjustments made on the specified transaction portfolio for a specified effective datetime. This should be used to undo holding adjustments made via set holdings or adjust holdings. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True

>>> thread = api.cancel_adjust_holdings_with_http_info(scope, code, effective_at, async_req=True)
>>> result = thread.get()
Parameters:
  • scope (str) – The scope of the transaction portfolio. (required)

  • code (str) – The code of the transaction portfolio. Together with the scope this uniquely identifies the transaction portfolio. (required)

  • effective_at (str) – The effective datetime or cut label at which the holding adjustments should be undone. (required)

  • async_req (bool, optional) – Whether to execute the request asynchronously.

  • _preload_content (bool, optional) – if False, the ApiResponse.data will be set to none and raw_data will store the HTTP response body without reading/decoding. Default is True.

  • _return_http_data_only (bool, optional) – response data instead of ApiResponse object with status code, headers, etc

  • _request_timeout – timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts.

  • _request_auth (dict, optional) – set to override the auth_settings for an a single request; this effectively ignores the authentication in the spec for a single request.

Returns:

Returns the result object. If the method is called asynchronously, returns the request thread.

Return type:

tuple(DeletedEntityResponse, status_code(int), headers(HTTPHeaderDict))

cancel_transactions(scope, code, transaction_ids, async_req=None, **kwargs)[source]

CancelTransactions: Cancel transactions # noqa: E501

Cancel one or more transactions from the transaction portfolio. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True

>>> thread = api.cancel_transactions(scope, code, transaction_ids, async_req=True)
>>> result = thread.get()
Parameters:
  • scope (str) – The scope of the transaction portfolio. (required)

  • code (str) – The code of the transaction portfolio. Together with the scope this uniquely identifies the transaction portfolio. (required)

  • transaction_ids (List[str]) – The IDs of the transactions to cancel. (required)

  • async_req (bool, optional) – Whether to execute the request asynchronously.

  • _request_timeout – timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts.

Returns:

Returns the result object. If the method is called asynchronously, returns the request thread.

Return type:

DeletedEntityResponse

cancel_transactions_with_http_info(scope, code, transaction_ids, **kwargs)[source]

CancelTransactions: Cancel transactions # noqa: E501

Cancel one or more transactions from the transaction portfolio. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True

>>> thread = api.cancel_transactions_with_http_info(scope, code, transaction_ids, async_req=True)
>>> result = thread.get()
Parameters:
  • scope (str) – The scope of the transaction portfolio. (required)

  • code (str) – The code of the transaction portfolio. Together with the scope this uniquely identifies the transaction portfolio. (required)

  • transaction_ids (List[str]) – The IDs of the transactions to cancel. (required)

  • async_req (bool, optional) – Whether to execute the request asynchronously.

  • _preload_content (bool, optional) – if False, the ApiResponse.data will be set to none and raw_data will store the HTTP response body without reading/decoding. Default is True.

  • _return_http_data_only (bool, optional) – response data instead of ApiResponse object with status code, headers, etc

  • _request_timeout – timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts.

  • _request_auth (dict, optional) – set to override the auth_settings for an a single request; this effectively ignores the authentication in the spec for a single request.

Returns:

Returns the result object. If the method is called asynchronously, returns the request thread.

Return type:

tuple(DeletedEntityResponse, status_code(int), headers(HTTPHeaderDict))

create_portfolio(scope, create_transaction_portfolio_request, async_req=None, **kwargs)[source]

CreatePortfolio: Create portfolio # noqa: E501

Create a transaction portfolio in a particular scope. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True

>>> thread = api.create_portfolio(scope, create_transaction_portfolio_request, async_req=True)
>>> result = thread.get()
Parameters:
  • scope (str) – The scope in which to create the transaction portfolio. (required)

  • create_transaction_portfolio_request (CreateTransactionPortfolioRequest) – The definition of the transaction portfolio. (required)

  • async_req (bool, optional) – Whether to execute the request asynchronously.

  • _request_timeout – timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts.

Returns:

Returns the result object. If the method is called asynchronously, returns the request thread.

Return type:

Portfolio

create_portfolio_with_http_info(scope, create_transaction_portfolio_request, **kwargs)[source]

CreatePortfolio: Create portfolio # noqa: E501

Create a transaction portfolio in a particular scope. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True

>>> thread = api.create_portfolio_with_http_info(scope, create_transaction_portfolio_request, async_req=True)
>>> result = thread.get()
Parameters:
  • scope (str) – The scope in which to create the transaction portfolio. (required)

  • create_transaction_portfolio_request (CreateTransactionPortfolioRequest) – The definition of the transaction portfolio. (required)

  • async_req (bool, optional) – Whether to execute the request asynchronously.

  • _preload_content (bool, optional) – if False, the ApiResponse.data will be set to none and raw_data will store the HTTP response body without reading/decoding. Default is True.

  • _return_http_data_only (bool, optional) – response data instead of ApiResponse object with status code, headers, etc

  • _request_timeout – timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts.

  • _request_auth (dict, optional) – set to override the auth_settings for an a single request; this effectively ignores the authentication in the spec for a single request.

Returns:

Returns the result object. If the method is called asynchronously, returns the request thread.

Return type:

tuple(Portfolio, status_code(int), headers(HTTPHeaderDict))

create_trade_ticket(scope, code, lusid_trade_ticket=None, async_req=None, **kwargs)[source]

[EARLY ACCESS] CreateTradeTicket: Create Trade Ticket # noqa: E501

Upsert a trade ticket. Broadly equivalent to a singular call to upsert an instrument, then a counterparty and finally a transaction that makes use of the two. It can be viewed as a utility function or part of a workflow more familiar to users with OTC systems than flow and equity trading ones. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True

>>> thread = api.create_trade_ticket(scope, code, lusid_trade_ticket, async_req=True)
>>> result = thread.get()
Parameters:
  • scope (str) – The scope of the transaction portfolio. (required)

  • code (str) – The code of the transaction portfolio. Together with the scope this uniquely identifies the transaction portfolio. (required)

  • lusid_trade_ticket (LusidTradeTicket) – the trade ticket to upsert

  • async_req (bool, optional) – Whether to execute the request asynchronously.

  • _request_timeout – timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts.

Returns:

Returns the result object. If the method is called asynchronously, returns the request thread.

Return type:

LusidTradeTicket

create_trade_ticket_with_http_info(scope, code, lusid_trade_ticket=None, **kwargs)[source]

[EARLY ACCESS] CreateTradeTicket: Create Trade Ticket # noqa: E501

Upsert a trade ticket. Broadly equivalent to a singular call to upsert an instrument, then a counterparty and finally a transaction that makes use of the two. It can be viewed as a utility function or part of a workflow more familiar to users with OTC systems than flow and equity trading ones. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True

>>> thread = api.create_trade_ticket_with_http_info(scope, code, lusid_trade_ticket, async_req=True)
>>> result = thread.get()
Parameters:
  • scope (str) – The scope of the transaction portfolio. (required)

  • code (str) – The code of the transaction portfolio. Together with the scope this uniquely identifies the transaction portfolio. (required)

  • lusid_trade_ticket (LusidTradeTicket) – the trade ticket to upsert

  • async_req (bool, optional) – Whether to execute the request asynchronously.

  • _preload_content (bool, optional) – if False, the ApiResponse.data will be set to none and raw_data will store the HTTP response body without reading/decoding. Default is True.

  • _return_http_data_only (bool, optional) – response data instead of ApiResponse object with status code, headers, etc

  • _request_timeout – timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts.

  • _request_auth (dict, optional) – set to override the auth_settings for an a single request; this effectively ignores the authentication in the spec for a single request.

Returns:

Returns the result object. If the method is called asynchronously, returns the request thread.

Return type:

tuple(LusidTradeTicket, status_code(int), headers(HTTPHeaderDict))

delete_custodian_accounts(scope, code, resource_id, delete_mode=None, async_req=None, **kwargs)[source]

[EXPERIMENTAL] DeleteCustodianAccounts: Soft or hard delete multiple custodian accounts # noqa: E501

Delete one or more custodian accounts from the Transaction Portfolios. Soft deletion marks the custodian account as inactive While the Hard deletion is deleting the custodian account. The batch limit per request is 2,000. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True

>>> thread = api.delete_custodian_accounts(scope, code, resource_id, delete_mode, async_req=True)
>>> result = thread.get()
Parameters:
  • scope (str) – The scope of the Transaction Portfolios. (required)

  • code (str) – The code of the Transaction Portfolios. Together with the scope this uniquely identifies the Transaction Portfolios. (required)

  • resource_id (List[ResourceId]) – The scope and codes of the custodian accounts to delete. (required)

  • delete_mode (str) – The delete mode to use (defaults to ‘Soft’).

  • async_req (bool, optional) – Whether to execute the request asynchronously.

  • _request_timeout – timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts.

Returns:

Returns the result object. If the method is called asynchronously, returns the request thread.

Return type:

DeleteCustodianAccountsResponse

delete_custodian_accounts_with_http_info(scope, code, resource_id, delete_mode=None, **kwargs)[source]

[EXPERIMENTAL] DeleteCustodianAccounts: Soft or hard delete multiple custodian accounts # noqa: E501

Delete one or more custodian accounts from the Transaction Portfolios. Soft deletion marks the custodian account as inactive While the Hard deletion is deleting the custodian account. The batch limit per request is 2,000. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True

>>> thread = api.delete_custodian_accounts_with_http_info(scope, code, resource_id, delete_mode, async_req=True)
>>> result = thread.get()
Parameters:
  • scope (str) – The scope of the Transaction Portfolios. (required)

  • code (str) – The code of the Transaction Portfolios. Together with the scope this uniquely identifies the Transaction Portfolios. (required)

  • resource_id (List[ResourceId]) – The scope and codes of the custodian accounts to delete. (required)

  • delete_mode (str) – The delete mode to use (defaults to ‘Soft’).

  • async_req (bool, optional) – Whether to execute the request asynchronously.

  • _preload_content (bool, optional) – if False, the ApiResponse.data will be set to none and raw_data will store the HTTP response body without reading/decoding. Default is True.

  • _return_http_data_only (bool, optional) – response data instead of ApiResponse object with status code, headers, etc

  • _request_timeout – timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts.

  • _request_auth (dict, optional) – set to override the auth_settings for an a single request; this effectively ignores the authentication in the spec for a single request.

Returns:

Returns the result object. If the method is called asynchronously, returns the request thread.

Return type:

tuple(DeleteCustodianAccountsResponse, status_code(int), headers(HTTPHeaderDict))

delete_properties_from_transaction(scope, code, transaction_id, property_keys, async_req=None, **kwargs)[source]

DeletePropertiesFromTransaction: Delete properties from transaction # noqa: E501

Delete one or more properties from a single transaction in a transaction portfolio. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True

>>> thread = api.delete_properties_from_transaction(scope, code, transaction_id, property_keys, async_req=True)
>>> result = thread.get()
Parameters:
  • scope (str) – The scope of the transaction portfolio. (required)

  • code (str) – The code of the transaction portfolio. Together with the scope this uniquely identifies the transaction portfolio. (required)

  • transaction_id (str) – The unique ID of the transaction from which to delete properties. (required)

  • property_keys (List[str]) – The property keys of the properties to delete. These must be from the “Transaction” domain and have the format {domain}/{scope}/{code}, for example “Transaction/strategy/quantsignal”. (required)

  • async_req (bool, optional) – Whether to execute the request asynchronously.

  • _request_timeout – timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts.

Returns:

Returns the result object. If the method is called asynchronously, returns the request thread.

Return type:

DeletedEntityResponse

delete_properties_from_transaction_with_http_info(scope, code, transaction_id, property_keys, **kwargs)[source]

DeletePropertiesFromTransaction: Delete properties from transaction # noqa: E501

Delete one or more properties from a single transaction in a transaction portfolio. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True

>>> thread = api.delete_properties_from_transaction_with_http_info(scope, code, transaction_id, property_keys, async_req=True)
>>> result = thread.get()
Parameters:
  • scope (str) – The scope of the transaction portfolio. (required)

  • code (str) – The code of the transaction portfolio. Together with the scope this uniquely identifies the transaction portfolio. (required)

  • transaction_id (str) – The unique ID of the transaction from which to delete properties. (required)

  • property_keys (List[str]) – The property keys of the properties to delete. These must be from the “Transaction” domain and have the format {domain}/{scope}/{code}, for example “Transaction/strategy/quantsignal”. (required)

  • async_req (bool, optional) – Whether to execute the request asynchronously.

  • _preload_content (bool, optional) – if False, the ApiResponse.data will be set to none and raw_data will store the HTTP response body without reading/decoding. Default is True.

  • _return_http_data_only (bool, optional) – response data instead of ApiResponse object with status code, headers, etc

  • _request_timeout – timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts.

  • _request_auth (dict, optional) – set to override the auth_settings for an a single request; this effectively ignores the authentication in the spec for a single request.

Returns:

Returns the result object. If the method is called asynchronously, returns the request thread.

Return type:

tuple(DeletedEntityResponse, status_code(int), headers(HTTPHeaderDict))

get_a2_b_data(scope, code, from_effective_at, to_effective_at, as_at=None, recipe_id_scope=None, recipe_id_code=None, property_keys=None, filter=None, async_req=None, **kwargs)[source]

GetA2BData: Get A2B data # noqa: E501

Get an A2B report for the given portfolio. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True

>>> thread = api.get_a2_b_data(scope, code, from_effective_at, to_effective_at, as_at, recipe_id_scope, recipe_id_code, property_keys, filter, async_req=True)
>>> result = thread.get()
Parameters:
  • scope (str) – The scope of the portfolio to retrieve the A2B report for. (required)

  • code (str) – The code of the portfolio to retrieve the A2B report for. Together with the scope this uniquely identifies the portfolio. (required)

  • from_effective_at (str) – The lower bound effective datetime or cut label (inclusive) from which to retrieve the data. There is no lower bound if this is not specified. (required)

  • to_effective_at (str) – The upper bound effective datetime or cut label (inclusive) from which to retrieve the data. There is no upper bound if this is not specified. (required)

  • as_at (datetime) – The asAt datetime at which to retrieve the portfolio. Defaults to return the latest version of each transaction if not specified.

  • recipe_id_scope (str) – The scope of the given recipeId

  • recipe_id_code (str) – The code of the given recipeId

  • property_keys (List[str]) – A list of property keys from the “Instrument” domain to decorate onto the results. These take the format {domain}/{scope}/{code} e.g. “Instrument/system/Name”.

  • filter (str) – Expression to filter the result set. Read more about filtering results from LUSID here https://support.lusid.com/filtering-results-from-lusid.

  • async_req (bool, optional) – Whether to execute the request asynchronously.

  • _request_timeout – timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts.

Returns:

Returns the result object. If the method is called asynchronously, returns the request thread.

Return type:

VersionedResourceListOfA2BDataRecord

get_a2_b_data_with_http_info(scope, code, from_effective_at, to_effective_at, as_at=None, recipe_id_scope=None, recipe_id_code=None, property_keys=None, filter=None, **kwargs)[source]

GetA2BData: Get A2B data # noqa: E501

Get an A2B report for the given portfolio. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True

>>> thread = api.get_a2_b_data_with_http_info(scope, code, from_effective_at, to_effective_at, as_at, recipe_id_scope, recipe_id_code, property_keys, filter, async_req=True)
>>> result = thread.get()
Parameters:
  • scope (str) – The scope of the portfolio to retrieve the A2B report for. (required)

  • code (str) – The code of the portfolio to retrieve the A2B report for. Together with the scope this uniquely identifies the portfolio. (required)

  • from_effective_at (str) – The lower bound effective datetime or cut label (inclusive) from which to retrieve the data. There is no lower bound if this is not specified. (required)

  • to_effective_at (str) – The upper bound effective datetime or cut label (inclusive) from which to retrieve the data. There is no upper bound if this is not specified. (required)

  • as_at (datetime) – The asAt datetime at which to retrieve the portfolio. Defaults to return the latest version of each transaction if not specified.

  • recipe_id_scope (str) – The scope of the given recipeId

  • recipe_id_code (str) – The code of the given recipeId

  • property_keys (List[str]) – A list of property keys from the “Instrument” domain to decorate onto the results. These take the format {domain}/{scope}/{code} e.g. “Instrument/system/Name”.

  • filter (str) – Expression to filter the result set. Read more about filtering results from LUSID here https://support.lusid.com/filtering-results-from-lusid.

  • async_req (bool, optional) – Whether to execute the request asynchronously.

  • _preload_content (bool, optional) – if False, the ApiResponse.data will be set to none and raw_data will store the HTTP response body without reading/decoding. Default is True.

  • _return_http_data_only (bool, optional) – response data instead of ApiResponse object with status code, headers, etc

  • _request_timeout – timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts.

  • _request_auth (dict, optional) – set to override the auth_settings for an a single request; this effectively ignores the authentication in the spec for a single request.

Returns:

Returns the result object. If the method is called asynchronously, returns the request thread.

Return type:

tuple(VersionedResourceListOfA2BDataRecord, status_code(int), headers(HTTPHeaderDict))

get_a2_b_movements(scope, code, from_effective_at, to_effective_at, as_at=None, recipe_id_scope=None, recipe_id_code=None, property_keys=None, filter=None, async_req=None, **kwargs)[source]

GetA2BMovements: Get an A2B report at the movement level for the given portfolio. # noqa: E501

Get an A2B report at the movement level for the given portfolio. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True

>>> thread = api.get_a2_b_movements(scope, code, from_effective_at, to_effective_at, as_at, recipe_id_scope, recipe_id_code, property_keys, filter, async_req=True)
>>> result = thread.get()
Parameters:
  • scope (str) – The scope of the portfolio to retrieve the A2B movement report for. (required)

  • code (str) – The code of the portfolio to retrieve the A2B movement report for. Together with the scope this uniquely identifies the portfolio. (required)

  • from_effective_at (str) – The lower bound effective datetime or cut label (inclusive) from which to retrieve the data. There is no lower bound if this is not specified. (required)

  • to_effective_at (str) – The upper bound effective datetime or cut label (inclusive) from which to retrieve the data. There is no upper bound if this is not specified. (required)

  • as_at (datetime) – The asAt datetime at which to retrieve the portfolio. Defaults to return the latest version of each transaction if not specified.

  • recipe_id_scope (str) – The scope of the given recipeId

  • recipe_id_code (str) – The code of the given recipeId

  • property_keys (List[str]) – A list of property keys from the “Instrument” domain to decorate onto the results. These take the format {domain}/{scope}/{code} e.g. “Instrument/system/Name”.

  • filter (str) – Expression to filter the result set. Read more about filtering results from LUSID here https://support.lusid.com/filtering-results-from-lusid.

  • async_req (bool, optional) – Whether to execute the request asynchronously.

  • _request_timeout – timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts.

Returns:

Returns the result object. If the method is called asynchronously, returns the request thread.

Return type:

VersionedResourceListOfA2BMovementRecord

get_a2_b_movements_with_http_info(scope, code, from_effective_at, to_effective_at, as_at=None, recipe_id_scope=None, recipe_id_code=None, property_keys=None, filter=None, **kwargs)[source]

GetA2BMovements: Get an A2B report at the movement level for the given portfolio. # noqa: E501

Get an A2B report at the movement level for the given portfolio. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True

>>> thread = api.get_a2_b_movements_with_http_info(scope, code, from_effective_at, to_effective_at, as_at, recipe_id_scope, recipe_id_code, property_keys, filter, async_req=True)
>>> result = thread.get()
Parameters:
  • scope (str) – The scope of the portfolio to retrieve the A2B movement report for. (required)

  • code (str) – The code of the portfolio to retrieve the A2B movement report for. Together with the scope this uniquely identifies the portfolio. (required)

  • from_effective_at (str) – The lower bound effective datetime or cut label (inclusive) from which to retrieve the data. There is no lower bound if this is not specified. (required)

  • to_effective_at (str) – The upper bound effective datetime or cut label (inclusive) from which to retrieve the data. There is no upper bound if this is not specified. (required)

  • as_at (datetime) – The asAt datetime at which to retrieve the portfolio. Defaults to return the latest version of each transaction if not specified.

  • recipe_id_scope (str) – The scope of the given recipeId

  • recipe_id_code (str) – The code of the given recipeId

  • property_keys (List[str]) – A list of property keys from the “Instrument” domain to decorate onto the results. These take the format {domain}/{scope}/{code} e.g. “Instrument/system/Name”.

  • filter (str) – Expression to filter the result set. Read more about filtering results from LUSID here https://support.lusid.com/filtering-results-from-lusid.

  • async_req (bool, optional) – Whether to execute the request asynchronously.

  • _preload_content (bool, optional) – if False, the ApiResponse.data will be set to none and raw_data will store the HTTP response body without reading/decoding. Default is True.

  • _return_http_data_only (bool, optional) – response data instead of ApiResponse object with status code, headers, etc

  • _request_timeout – timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts.

  • _request_auth (dict, optional) – set to override the auth_settings for an a single request; this effectively ignores the authentication in the spec for a single request.

Returns:

Returns the result object. If the method is called asynchronously, returns the request thread.

Return type:

tuple(VersionedResourceListOfA2BMovementRecord, status_code(int), headers(HTTPHeaderDict))

get_bucketed_cash_flows(scope, code, bucketed_cash_flow_request=None, async_req=None, **kwargs)[source]

[EXPERIMENTAL] GetBucketedCashFlows: Get bucketed cash flows from a list of portfolios # noqa: E501

We bucket/aggregate a transaction portfolio’s instruments by date or tenor specified in the request. The cashflows are grouped by both instrumentId and currency. If you want transactional level cashflow, please use the ‘GetUpsertableCashFlows’ endpoint. If you want instrument cashflow, please use the ‘GetPortfolioCashFlows’ endpoint. Note that these endpoints do not apply bucketing. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True

>>> thread = api.get_bucketed_cash_flows(scope, code, bucketed_cash_flow_request, async_req=True)
>>> result = thread.get()
Parameters:
  • scope (str) – The scope of the transaction portfolio. (required)

  • code (str) – The code of the transaction portfolio. Together with the scope this uniquely identifies the portfolio. (required)

  • bucketed_cash_flow_request (BucketedCashFlowRequest) – Request specifying the bucketing of cashflows

  • async_req (bool, optional) – Whether to execute the request asynchronously.

  • _request_timeout – timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts.

Returns:

Returns the result object. If the method is called asynchronously, returns the request thread.

Return type:

BucketedCashFlowResponse

get_bucketed_cash_flows_with_http_info(scope, code, bucketed_cash_flow_request=None, **kwargs)[source]

[EXPERIMENTAL] GetBucketedCashFlows: Get bucketed cash flows from a list of portfolios # noqa: E501

We bucket/aggregate a transaction portfolio’s instruments by date or tenor specified in the request. The cashflows are grouped by both instrumentId and currency. If you want transactional level cashflow, please use the ‘GetUpsertableCashFlows’ endpoint. If you want instrument cashflow, please use the ‘GetPortfolioCashFlows’ endpoint. Note that these endpoints do not apply bucketing. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True

>>> thread = api.get_bucketed_cash_flows_with_http_info(scope, code, bucketed_cash_flow_request, async_req=True)
>>> result = thread.get()
Parameters:
  • scope (str) – The scope of the transaction portfolio. (required)

  • code (str) – The code of the transaction portfolio. Together with the scope this uniquely identifies the portfolio. (required)

  • bucketed_cash_flow_request (BucketedCashFlowRequest) – Request specifying the bucketing of cashflows

  • async_req (bool, optional) – Whether to execute the request asynchronously.

  • _preload_content (bool, optional) – if False, the ApiResponse.data will be set to none and raw_data will store the HTTP response body without reading/decoding. Default is True.

  • _return_http_data_only (bool, optional) – response data instead of ApiResponse object with status code, headers, etc

  • _request_timeout – timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts.

  • _request_auth (dict, optional) – set to override the auth_settings for an a single request; this effectively ignores the authentication in the spec for a single request.

Returns:

Returns the result object. If the method is called asynchronously, returns the request thread.

Return type:

tuple(BucketedCashFlowResponse, status_code(int), headers(HTTPHeaderDict))

get_custodian_account(scope, code, custodian_account_scope, custodian_account_code, effective_at=None, as_at=None, property_keys=None, async_req=None, **kwargs)[source]

[EXPERIMENTAL] GetCustodianAccount: Get Custodian Account # noqa: E501

Retrieve the definition of a particular Custodian Account which is part of a Transaction Portfolios. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True

>>> thread = api.get_custodian_account(scope, code, custodian_account_scope, custodian_account_code, effective_at, as_at, property_keys, async_req=True)
>>> result = thread.get()
Parameters:
  • scope (str) – The scope of the Transaction Portfolio. (required)

  • code (str) – The code of the Transaction Portfolio. Together with the scope this uniquely identifies the Transaction Portfolio. (required)

  • custodian_account_scope (str) – The scope of the Custodian Account. (required)

  • custodian_account_code (str) – The code of the Custodian Account. (required)

  • effective_at (str) – The effective datetime or cut label at which to retrieve the Custodian Account properties. Defaults to the current LUSID system datetime if not specified.

  • as_at (datetime) – The asAt datetime at which to retrieve the Custodian Account definition. Defaults to returning the latest version of the Custodian Account definition if not specified.

  • property_keys (List[str]) – A list of property keys from the ‘CustodianAccount’ domain to decorate onto the Custodian Account. These must take the format {domain}/{scope}/{code}, for example ‘CustodianAccount/Manager/Id’. If not provided will return all the entitled properties for that Custodian Account.

  • async_req (bool, optional) – Whether to execute the request asynchronously.

  • _request_timeout – timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts.

Returns:

Returns the result object. If the method is called asynchronously, returns the request thread.

Return type:

CustodianAccount

get_custodian_account_with_http_info(scope, code, custodian_account_scope, custodian_account_code, effective_at=None, as_at=None, property_keys=None, **kwargs)[source]

[EXPERIMENTAL] GetCustodianAccount: Get Custodian Account # noqa: E501

Retrieve the definition of a particular Custodian Account which is part of a Transaction Portfolios. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True

>>> thread = api.get_custodian_account_with_http_info(scope, code, custodian_account_scope, custodian_account_code, effective_at, as_at, property_keys, async_req=True)
>>> result = thread.get()
Parameters:
  • scope (str) – The scope of the Transaction Portfolio. (required)

  • code (str) – The code of the Transaction Portfolio. Together with the scope this uniquely identifies the Transaction Portfolio. (required)

  • custodian_account_scope (str) – The scope of the Custodian Account. (required)

  • custodian_account_code (str) – The code of the Custodian Account. (required)

  • effective_at (str) – The effective datetime or cut label at which to retrieve the Custodian Account properties. Defaults to the current LUSID system datetime if not specified.

  • as_at (datetime) – The asAt datetime at which to retrieve the Custodian Account definition. Defaults to returning the latest version of the Custodian Account definition if not specified.

  • property_keys (List[str]) – A list of property keys from the ‘CustodianAccount’ domain to decorate onto the Custodian Account. These must take the format {domain}/{scope}/{code}, for example ‘CustodianAccount/Manager/Id’. If not provided will return all the entitled properties for that Custodian Account.

  • async_req (bool, optional) – Whether to execute the request asynchronously.

  • _preload_content (bool, optional) – if False, the ApiResponse.data will be set to none and raw_data will store the HTTP response body without reading/decoding. Default is True.

  • _return_http_data_only (bool, optional) – response data instead of ApiResponse object with status code, headers, etc

  • _request_timeout – timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts.

  • _request_auth (dict, optional) – set to override the auth_settings for an a single request; this effectively ignores the authentication in the spec for a single request.

Returns:

Returns the result object. If the method is called asynchronously, returns the request thread.

Return type:

tuple(CustodianAccount, status_code(int), headers(HTTPHeaderDict))

get_details(scope, code, effective_at=None, as_at=None, async_req=None, **kwargs)[source]

GetDetails: Get details # noqa: E501

Get certain details associated with a transaction portfolio. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True

>>> thread = api.get_details(scope, code, effective_at, as_at, async_req=True)
>>> result = thread.get()
Parameters:
  • scope (str) – The scope of the transaction portfolio. (required)

  • code (str) – The code of the transaction portfolio. Together with the scope this uniquely identifies the transaction portfolio. (required)

  • effective_at (str) – The effective datetime or cut label at which to retrieve the details of the transaction portfolio. Defaults to the current LUSID system datetime if not specified.

  • as_at (datetime) – The asAt datetime at which to retrieve the details of the transaction portfolio. Defaults to returning the latest version of the details if not specified.

  • async_req (bool, optional) – Whether to execute the request asynchronously.

  • _request_timeout – timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts.

Returns:

Returns the result object. If the method is called asynchronously, returns the request thread.

Return type:

PortfolioDetails

get_details_with_http_info(scope, code, effective_at=None, as_at=None, **kwargs)[source]

GetDetails: Get details # noqa: E501

Get certain details associated with a transaction portfolio. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True

>>> thread = api.get_details_with_http_info(scope, code, effective_at, as_at, async_req=True)
>>> result = thread.get()
Parameters:
  • scope (str) – The scope of the transaction portfolio. (required)

  • code (str) – The code of the transaction portfolio. Together with the scope this uniquely identifies the transaction portfolio. (required)

  • effective_at (str) – The effective datetime or cut label at which to retrieve the details of the transaction portfolio. Defaults to the current LUSID system datetime if not specified.

  • as_at (datetime) – The asAt datetime at which to retrieve the details of the transaction portfolio. Defaults to returning the latest version of the details if not specified.

  • async_req (bool, optional) – Whether to execute the request asynchronously.

  • _preload_content (bool, optional) – if False, the ApiResponse.data will be set to none and raw_data will store the HTTP response body without reading/decoding. Default is True.

  • _return_http_data_only (bool, optional) – response data instead of ApiResponse object with status code, headers, etc

  • _request_timeout – timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts.

  • _request_auth (dict, optional) – set to override the auth_settings for an a single request; this effectively ignores the authentication in the spec for a single request.

Returns:

Returns the result object. If the method is called asynchronously, returns the request thread.

Return type:

tuple(PortfolioDetails, status_code(int), headers(HTTPHeaderDict))

get_holding_contributors(scope, code, holding_id, effective_date=None, from_trade_date=None, to_trade_date=None, include_historic=None, tax_lot_id=None, limit=None, as_at=None, page=None, async_req=None, **kwargs)[source]

[EARLY ACCESS] GetHoldingContributors: Get Holdings Contributors # noqa: E501

Lists all transactions that affect the holdings of a portfolio over a given effective interval. This includes transactions automatically generated by LUSID such as holding adjustments. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True

>>> thread = api.get_holding_contributors(scope, code, holding_id, effective_date, from_trade_date, to_trade_date, include_historic, tax_lot_id, limit, as_at, page, async_req=True)
>>> result = thread.get()
Parameters:
  • scope (str) – The scope of the transaction portfolio. (required)

  • code (str) – The code of the transaction portfolio. Together with the scope this uniquely identifies the transaction portfolio. (required)

  • holding_id (int) – The unique holding identifier (required)

  • effective_date (str) – Effective date

  • from_trade_date (str) – The from trade date, defaults to first time this holding is opened, lower bound for transactions

  • to_trade_date (str) – The to trade date upper bound date, defaults to effectiveDate. upper bound for transactions

  • include_historic (bool) – If true, transactions from previously closed holdings are returned. If false, only transactions from last time position is opened.

  • tax_lot_id (str) – Constrains the Holding Contributors to those which contributed to the specified tax lot.

  • limit (int) – When paginating, limit the number of returned results to this many. Defaults to 100 if not specified.

  • as_at (datetime) – The asAt datetime at which to build the transactions. Defaults to return the latest version of each transaction if not specified.

  • page (str) – The pagination token to use to continue listing transactions from a previous call to GetHoldingContributors.

  • async_req (bool, optional) – Whether to execute the request asynchronously.

  • _request_timeout – timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts.

Returns:

Returns the result object. If the method is called asynchronously, returns the request thread.

Return type:

VersionedResourceListOfHoldingContributor

get_holding_contributors_with_http_info(scope, code, holding_id, effective_date=None, from_trade_date=None, to_trade_date=None, include_historic=None, tax_lot_id=None, limit=None, as_at=None, page=None, **kwargs)[source]

[EARLY ACCESS] GetHoldingContributors: Get Holdings Contributors # noqa: E501

Lists all transactions that affect the holdings of a portfolio over a given effective interval. This includes transactions automatically generated by LUSID such as holding adjustments. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True

>>> thread = api.get_holding_contributors_with_http_info(scope, code, holding_id, effective_date, from_trade_date, to_trade_date, include_historic, tax_lot_id, limit, as_at, page, async_req=True)
>>> result = thread.get()
Parameters:
  • scope (str) – The scope of the transaction portfolio. (required)

  • code (str) – The code of the transaction portfolio. Together with the scope this uniquely identifies the transaction portfolio. (required)

  • holding_id (int) – The unique holding identifier (required)

  • effective_date (str) – Effective date

  • from_trade_date (str) – The from trade date, defaults to first time this holding is opened, lower bound for transactions

  • to_trade_date (str) – The to trade date upper bound date, defaults to effectiveDate. upper bound for transactions

  • include_historic (bool) – If true, transactions from previously closed holdings are returned. If false, only transactions from last time position is opened.

  • tax_lot_id (str) – Constrains the Holding Contributors to those which contributed to the specified tax lot.

  • limit (int) – When paginating, limit the number of returned results to this many. Defaults to 100 if not specified.

  • as_at (datetime) – The asAt datetime at which to build the transactions. Defaults to return the latest version of each transaction if not specified.

  • page (str) – The pagination token to use to continue listing transactions from a previous call to GetHoldingContributors.

  • async_req (bool, optional) – Whether to execute the request asynchronously.

  • _preload_content (bool, optional) – if False, the ApiResponse.data will be set to none and raw_data will store the HTTP response body without reading/decoding. Default is True.

  • _return_http_data_only (bool, optional) – response data instead of ApiResponse object with status code, headers, etc

  • _request_timeout – timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts.

  • _request_auth (dict, optional) – set to override the auth_settings for an a single request; this effectively ignores the authentication in the spec for a single request.

Returns:

Returns the result object. If the method is called asynchronously, returns the request thread.

Return type:

tuple(VersionedResourceListOfHoldingContributor, status_code(int), headers(HTTPHeaderDict))

get_holdings(scope, code, effective_at=None, as_at=None, filter=None, property_keys=None, by_taxlots=None, async_req=None, **kwargs)[source]

GetHoldings: Get holdings # noqa: E501

Calculate holdings for a transaction portfolio. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True

>>> thread = api.get_holdings(scope, code, effective_at, as_at, filter, property_keys, by_taxlots, async_req=True)
>>> result = thread.get()
Parameters:
  • scope (str) – The scope of the transaction portfolio. (required)

  • code (str) – The code of the transaction portfolio. Together with the scope this uniquely identifies the transaction portfolio. (required)

  • effective_at (str) – The effective datetime or cut label at which to retrieve the holdings of the transaction portfolio. Defaults to the current LUSID system datetime if not specified.

  • as_at (datetime) – The asAt datetime at which to retrieve the holdings of the transaction portfolio. Defaults to return the latest version if not specified.

  • filter (str) – Expression to filter the result set. For example, to filter on the Holding Type, use “holdingType eq ‘p’”. For more information about filtering LUSID results, see https://support.lusid.com/knowledgebase/article/KA-01914.

  • property_keys (List[str]) – A list of property keys from the “Instrument”, “Holding”, “Custodian Account” or “Portfolio” domain to decorate onto holdings. These must have the format {domain}/{scope}/{code}, for example “Instrument/system/Name” or “Holding/system/Cost”.

  • by_taxlots (bool) – Whether or not to expand the holdings to return the underlying tax-lots. Defaults to False.

  • async_req (bool, optional) – Whether to execute the request asynchronously.

  • _request_timeout – timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts.

Returns:

Returns the result object. If the method is called asynchronously, returns the request thread.

Return type:

VersionedResourceListOfPortfolioHolding

get_holdings_adjustment(scope, code, effective_at, as_at=None, property_keys=None, async_req=None, **kwargs)[source]

GetHoldingsAdjustment: Get holdings adjustment # noqa: E501

Get a holdings adjustment made to a transaction portfolio at a specific effective datetime. Note that a holdings adjustment will only be returned if one exists for the specified effective datetime. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True

>>> thread = api.get_holdings_adjustment(scope, code, effective_at, as_at, property_keys, async_req=True)
>>> result = thread.get()
Parameters:
  • scope (str) – The scope of the transaction portfolio. (required)

  • code (str) – The code of the transaction portfolio. Together with the scope this uniquely identifies the transaction portfolio. (required)

  • effective_at (str) – The effective datetime or cut label of the holdings adjustment. (required)

  • as_at (datetime) – The asAt datetime at which to retrieve the holdings adjustment. Defaults to the return the latest version of the holdings adjustment if not specified.

  • property_keys (List[str]) – A list of property keys from the ‘Instrument’ domain to decorate onto holdings adjustments. These must have the format {domain}/{scope}/{code}, for example ‘Instrument/system/Name’. Note that properties from the ‘Holding’ domain are automatically returned.

  • async_req (bool, optional) – Whether to execute the request asynchronously.

  • _request_timeout – timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts.

Returns:

Returns the result object. If the method is called asynchronously, returns the request thread.

Return type:

HoldingsAdjustment

get_holdings_adjustment_with_http_info(scope, code, effective_at, as_at=None, property_keys=None, **kwargs)[source]

GetHoldingsAdjustment: Get holdings adjustment # noqa: E501

Get a holdings adjustment made to a transaction portfolio at a specific effective datetime. Note that a holdings adjustment will only be returned if one exists for the specified effective datetime. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True

>>> thread = api.get_holdings_adjustment_with_http_info(scope, code, effective_at, as_at, property_keys, async_req=True)
>>> result = thread.get()
Parameters:
  • scope (str) – The scope of the transaction portfolio. (required)

  • code (str) – The code of the transaction portfolio. Together with the scope this uniquely identifies the transaction portfolio. (required)

  • effective_at (str) – The effective datetime or cut label of the holdings adjustment. (required)

  • as_at (datetime) – The asAt datetime at which to retrieve the holdings adjustment. Defaults to the return the latest version of the holdings adjustment if not specified.

  • property_keys (List[str]) – A list of property keys from the ‘Instrument’ domain to decorate onto holdings adjustments. These must have the format {domain}/{scope}/{code}, for example ‘Instrument/system/Name’. Note that properties from the ‘Holding’ domain are automatically returned.

  • async_req (bool, optional) – Whether to execute the request asynchronously.

  • _preload_content (bool, optional) – if False, the ApiResponse.data will be set to none and raw_data will store the HTTP response body without reading/decoding. Default is True.

  • _return_http_data_only (bool, optional) – response data instead of ApiResponse object with status code, headers, etc

  • _request_timeout – timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts.

  • _request_auth (dict, optional) – set to override the auth_settings for an a single request; this effectively ignores the authentication in the spec for a single request.

Returns:

Returns the result object. If the method is called asynchronously, returns the request thread.

Return type:

tuple(HoldingsAdjustment, status_code(int), headers(HTTPHeaderDict))

get_holdings_with_http_info(scope, code, effective_at=None, as_at=None, filter=None, property_keys=None, by_taxlots=None, **kwargs)[source]

GetHoldings: Get holdings # noqa: E501

Calculate holdings for a transaction portfolio. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True

>>> thread = api.get_holdings_with_http_info(scope, code, effective_at, as_at, filter, property_keys, by_taxlots, async_req=True)
>>> result = thread.get()
Parameters:
  • scope (str) – The scope of the transaction portfolio. (required)

  • code (str) – The code of the transaction portfolio. Together with the scope this uniquely identifies the transaction portfolio. (required)

  • effective_at (str) – The effective datetime or cut label at which to retrieve the holdings of the transaction portfolio. Defaults to the current LUSID system datetime if not specified.

  • as_at (datetime) – The asAt datetime at which to retrieve the holdings of the transaction portfolio. Defaults to return the latest version if not specified.

  • filter (str) – Expression to filter the result set. For example, to filter on the Holding Type, use “holdingType eq ‘p’”. For more information about filtering LUSID results, see https://support.lusid.com/knowledgebase/article/KA-01914.

  • property_keys (List[str]) – A list of property keys from the “Instrument”, “Holding”, “Custodian Account” or “Portfolio” domain to decorate onto holdings. These must have the format {domain}/{scope}/{code}, for example “Instrument/system/Name” or “Holding/system/Cost”.

  • by_taxlots (bool) – Whether or not to expand the holdings to return the underlying tax-lots. Defaults to False.

  • async_req (bool, optional) – Whether to execute the request asynchronously.

  • _preload_content (bool, optional) – if False, the ApiResponse.data will be set to none and raw_data will store the HTTP response body without reading/decoding. Default is True.

  • _return_http_data_only (bool, optional) – response data instead of ApiResponse object with status code, headers, etc

  • _request_timeout – timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts.

  • _request_auth (dict, optional) – set to override the auth_settings for an a single request; this effectively ignores the authentication in the spec for a single request.

Returns:

Returns the result object. If the method is called asynchronously, returns the request thread.

Return type:

tuple(VersionedResourceListOfPortfolioHolding, status_code(int), headers(HTTPHeaderDict))

get_holdings_with_orders(scope, code, effective_at=None, as_at=None, filter=None, property_keys=None, by_taxlots=None, recipe_id_scope=None, recipe_id_code=None, async_req=None, **kwargs)[source]

[EXPERIMENTAL] GetHoldingsWithOrders: Get holdings with orders # noqa: E501

Get the holdings of a transaction portfolio. Create virtual holdings for any outstanding orders, and account for order state/fulfillment; that is, treat outstanding orders (and related records) as if they had been realised at moment of query. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True

>>> thread = api.get_holdings_with_orders(scope, code, effective_at, as_at, filter, property_keys, by_taxlots, recipe_id_scope, recipe_id_code, async_req=True)
>>> result = thread.get()
Parameters:
  • scope (str) – The scope of the transaction portfolio. (required)

  • code (str) – The code of the transaction portfolio. Together with the scope this uniquely identifies the transaction portfolio. (required)

  • effective_at (str) – The effective datetime or cut label at which to retrieve the holdings of the transaction portfolio. Defaults to the current LUSID system datetime if not specified.

  • as_at (datetime) – The asAt datetime at which to retrieve the holdings of the transaction portfolio. Defaults to return the latest version of the holdings if not specified.

  • filter (str) – Expression to filter the result set. For example, to filter on the Holding Type, use “holdingType eq ‘p’” For more information about filtering LUSID results, see https://support.lusid.com/knowledgebase/article/KA-01914.

  • property_keys (List[str]) – A list of property keys from the “Instrument”, “Holding” or “Portfolio” domain to decorate onto the holdings. These take the format {domain}/{scope}/{code} e.g. “Instrument/system/Name” or “Holding/system/Cost”.

  • by_taxlots (bool) – Whether or not to expand the holdings to return the underlying tax-lots. Defaults to False.

  • recipe_id_scope (str) – The scope of the given recipeId

  • recipe_id_code (str) – The code of the given recipeId

  • async_req (bool, optional) – Whether to execute the request asynchronously.

  • _request_timeout – timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts.

Returns:

Returns the result object. If the method is called asynchronously, returns the request thread.

Return type:

VersionedResourceListWithWarningsOfPortfolioHolding

get_holdings_with_orders_with_http_info(scope, code, effective_at=None, as_at=None, filter=None, property_keys=None, by_taxlots=None, recipe_id_scope=None, recipe_id_code=None, **kwargs)[source]

[EXPERIMENTAL] GetHoldingsWithOrders: Get holdings with orders # noqa: E501

Get the holdings of a transaction portfolio. Create virtual holdings for any outstanding orders, and account for order state/fulfillment; that is, treat outstanding orders (and related records) as if they had been realised at moment of query. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True

>>> thread = api.get_holdings_with_orders_with_http_info(scope, code, effective_at, as_at, filter, property_keys, by_taxlots, recipe_id_scope, recipe_id_code, async_req=True)
>>> result = thread.get()
Parameters:
  • scope (str) – The scope of the transaction portfolio. (required)

  • code (str) – The code of the transaction portfolio. Together with the scope this uniquely identifies the transaction portfolio. (required)

  • effective_at (str) – The effective datetime or cut label at which to retrieve the holdings of the transaction portfolio. Defaults to the current LUSID system datetime if not specified.

  • as_at (datetime) – The asAt datetime at which to retrieve the holdings of the transaction portfolio. Defaults to return the latest version of the holdings if not specified.

  • filter (str) – Expression to filter the result set. For example, to filter on the Holding Type, use “holdingType eq ‘p’” For more information about filtering LUSID results, see https://support.lusid.com/knowledgebase/article/KA-01914.

  • property_keys (List[str]) – A list of property keys from the “Instrument”, “Holding” or “Portfolio” domain to decorate onto the holdings. These take the format {domain}/{scope}/{code} e.g. “Instrument/system/Name” or “Holding/system/Cost”.

  • by_taxlots (bool) – Whether or not to expand the holdings to return the underlying tax-lots. Defaults to False.

  • recipe_id_scope (str) – The scope of the given recipeId

  • recipe_id_code (str) – The code of the given recipeId

  • async_req (bool, optional) – Whether to execute the request asynchronously.

  • _preload_content (bool, optional) – if False, the ApiResponse.data will be set to none and raw_data will store the HTTP response body without reading/decoding. Default is True.

  • _return_http_data_only (bool, optional) – response data instead of ApiResponse object with status code, headers, etc

  • _request_timeout – timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts.

  • _request_auth (dict, optional) – set to override the auth_settings for an a single request; this effectively ignores the authentication in the spec for a single request.

Returns:

Returns the result object. If the method is called asynchronously, returns the request thread.

Return type:

tuple(VersionedResourceListWithWarningsOfPortfolioHolding, status_code(int), headers(HTTPHeaderDict))

get_portfolio_cash_flows(scope, code, effective_at=None, window_start=None, window_end=None, as_at=None, filter=None, recipe_id_scope=None, recipe_id_code=None, exclude_unsettled_trades=None, async_req=None, **kwargs)[source]

[BETA] GetPortfolioCashFlows: Get portfolio cash flows # noqa: E501

Get the set of cash flows that occur in a window for the transaction portfolio’s instruments. Note that grouping can affect the quantity of information returned; where a holding is an amalgamation of one or more (e.g. cash) instruments, a unique transaction identifier will not be available. The same may go for diagnostic information (e.g. multiple sources of an aggregate cash amount on a date that is not split out. Grouping at the transaction and instrument level is recommended for those seeking to attribute individual flows. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True

>>> thread = api.get_portfolio_cash_flows(scope, code, effective_at, window_start, window_end, as_at, filter, recipe_id_scope, recipe_id_code, exclude_unsettled_trades, async_req=True)
>>> result = thread.get()
Parameters:
  • scope (str) – The scope of the transaction portfolio. (required)

  • code (str) – The code of the transaction portfolio. Together with the scope this uniquely identifies the portfolio. (required)

  • effective_at (str) – The valuation (pricing) effective datetime or cut label (inclusive) at which to evaluate the cashflows. This determines whether cashflows are evaluated in a historic or forward looking context and will, for certain models, affect where data is looked up. For example, on a swap if the effectiveAt is in the middle of the window, cashflows before it will be historic and resets assumed to exist where if the effectiveAt is before the start of the range they are forward looking and will be expectations assuming the model supports that. There is evidently a presumption here about availability of data and that the effectiveAt is realistically on or before the real-world today.

  • window_start (str) – The lower bound effective datetime or cut label (inclusive) from which to retrieve the cashflows. There is no lower bound if this is not specified. i.e. it is the minimum date.

  • window_end (str) – The upper bound effective datetime or cut label (inclusive) from which to retrieve the cashflows. The upper bound defaults to ‘max date’ if it is not specified

  • as_at (datetime) – The asAt datetime at which to retrieve the data. Defaults to returning the latest version of each transaction if not specified.

  • filter (str) – Expression to filter the result set. For example, to return only transactions with a transaction type of ‘Buy’, specify “type eq ‘Buy’”. For more information about filtering LUSID results, see https://support.lusid.com/knowledgebase/article/KA-01914.

  • recipe_id_scope (str) – The scope of the given recipeId

  • recipe_id_code (str) – The code of the given recipeID

  • exclude_unsettled_trades (bool) – If absent or set to false, cashflows will returned based on trade date - more specifically, cashflows from any unsettled trades will be included in the results. If set to true, unsettled trades will be excluded from the result set.

  • async_req (bool, optional) – Whether to execute the request asynchronously.

  • _request_timeout – timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts.

Returns:

Returns the result object. If the method is called asynchronously, returns the request thread.

Return type:

ResourceListOfInstrumentCashFlow

get_portfolio_cash_flows_with_http_info(scope, code, effective_at=None, window_start=None, window_end=None, as_at=None, filter=None, recipe_id_scope=None, recipe_id_code=None, exclude_unsettled_trades=None, **kwargs)[source]

[BETA] GetPortfolioCashFlows: Get portfolio cash flows # noqa: E501

Get the set of cash flows that occur in a window for the transaction portfolio’s instruments. Note that grouping can affect the quantity of information returned; where a holding is an amalgamation of one or more (e.g. cash) instruments, a unique transaction identifier will not be available. The same may go for diagnostic information (e.g. multiple sources of an aggregate cash amount on a date that is not split out. Grouping at the transaction and instrument level is recommended for those seeking to attribute individual flows. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True

>>> thread = api.get_portfolio_cash_flows_with_http_info(scope, code, effective_at, window_start, window_end, as_at, filter, recipe_id_scope, recipe_id_code, exclude_unsettled_trades, async_req=True)
>>> result = thread.get()
Parameters:
  • scope (str) – The scope of the transaction portfolio. (required)

  • code (str) – The code of the transaction portfolio. Together with the scope this uniquely identifies the portfolio. (required)

  • effective_at (str) – The valuation (pricing) effective datetime or cut label (inclusive) at which to evaluate the cashflows. This determines whether cashflows are evaluated in a historic or forward looking context and will, for certain models, affect where data is looked up. For example, on a swap if the effectiveAt is in the middle of the window, cashflows before it will be historic and resets assumed to exist where if the effectiveAt is before the start of the range they are forward looking and will be expectations assuming the model supports that. There is evidently a presumption here about availability of data and that the effectiveAt is realistically on or before the real-world today.

  • window_start (str) – The lower bound effective datetime or cut label (inclusive) from which to retrieve the cashflows. There is no lower bound if this is not specified. i.e. it is the minimum date.

  • window_end (str) – The upper bound effective datetime or cut label (inclusive) from which to retrieve the cashflows. The upper bound defaults to ‘max date’ if it is not specified

  • as_at (datetime) – The asAt datetime at which to retrieve the data. Defaults to returning the latest version of each transaction if not specified.

  • filter (str) – Expression to filter the result set. For example, to return only transactions with a transaction type of ‘Buy’, specify “type eq ‘Buy’”. For more information about filtering LUSID results, see https://support.lusid.com/knowledgebase/article/KA-01914.

  • recipe_id_scope (str) – The scope of the given recipeId

  • recipe_id_code (str) – The code of the given recipeID

  • exclude_unsettled_trades (bool) – If absent or set to false, cashflows will returned based on trade date - more specifically, cashflows from any unsettled trades will be included in the results. If set to true, unsettled trades will be excluded from the result set.

  • async_req (bool, optional) – Whether to execute the request asynchronously.

  • _preload_content (bool, optional) – if False, the ApiResponse.data will be set to none and raw_data will store the HTTP response body without reading/decoding. Default is True.

  • _return_http_data_only (bool, optional) – response data instead of ApiResponse object with status code, headers, etc

  • _request_timeout – timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts.

  • _request_auth (dict, optional) – set to override the auth_settings for an a single request; this effectively ignores the authentication in the spec for a single request.

Returns:

Returns the result object. If the method is called asynchronously, returns the request thread.

Return type:

tuple(ResourceListOfInstrumentCashFlow, status_code(int), headers(HTTPHeaderDict))

get_portfolio_cash_ladder(scope, code, from_effective_at, to_effective_at, effective_at, as_at=None, filter=None, recipe_id_scope=None, recipe_id_code=None, exclude_unsettled_trades=None, async_req=None, **kwargs)[source]

GetPortfolioCashLadder: Get portfolio cash ladder # noqa: E501

Get a cash ladder for a transaction portfolio. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True

>>> thread = api.get_portfolio_cash_ladder(scope, code, from_effective_at, to_effective_at, effective_at, as_at, filter, recipe_id_scope, recipe_id_code, exclude_unsettled_trades, async_req=True)
>>> result = thread.get()
Parameters:
  • scope (str) – The scope of the transaction portfolio. (required)

  • code (str) – The code of the transaction portfolio. Together with the scope this uniquely identifies the portfolio. (required)

  • from_effective_at (str) – The lower bound effective datetime or cut label (inclusive) from which to retrieve the data. There is no lower bound if this is not specified. (required)

  • to_effective_at (str) – The upper bound effective datetime or cut label (inclusive) from which to retrieve the data. There is no upper bound if this is not specified. (required)

  • effective_at (str) – The valuation (pricing) effective datetime or cut label (inclusive) at which to evaluate the cashflows. This determines whether cashflows are evaluated in a historic or forward looking context and will, for certain models, affect where data is looked up. For example, on a swap if the effectiveAt is in the middle of the window, cashflows before it will be historic and resets assumed to exist where if the effectiveAt is before the start of the range they are forward looking and will be expectations assuming the model supports that. There is evidently a presumption here about availability of data and that the effectiveAt is realistically on or before the real-world today. (required)

  • as_at (datetime) – The asAt datetime at which to retrieve the portfolio. Defaults to returning the latest version of each transaction if not specified.

  • filter (str) – Expression to filter the result set. For example, to return only transactions with a transaction type of ‘Buy’, specify “type eq ‘Buy’”. For more information about filtering LUSID results, see https://support.lusid.com/knowledgebase/article/KA-01914.

  • recipe_id_scope (str) – The scope of the given recipeId

  • recipe_id_code (str) – The code of the given recipeID

  • exclude_unsettled_trades (bool) – If absent or set to false, cashflows will returned based on trade date - more specifically, cashflows from any unsettled trades will be included in the results. If set to true, unsettled trades will be excluded from the result set.

  • async_req (bool, optional) – Whether to execute the request asynchronously.

  • _request_timeout – timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts.

Returns:

Returns the result object. If the method is called asynchronously, returns the request thread.

Return type:

ResourceListOfPortfolioCashLadder

get_portfolio_cash_ladder_with_http_info(scope, code, from_effective_at, to_effective_at, effective_at, as_at=None, filter=None, recipe_id_scope=None, recipe_id_code=None, exclude_unsettled_trades=None, **kwargs)[source]

GetPortfolioCashLadder: Get portfolio cash ladder # noqa: E501

Get a cash ladder for a transaction portfolio. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True

>>> thread = api.get_portfolio_cash_ladder_with_http_info(scope, code, from_effective_at, to_effective_at, effective_at, as_at, filter, recipe_id_scope, recipe_id_code, exclude_unsettled_trades, async_req=True)
>>> result = thread.get()
Parameters:
  • scope (str) – The scope of the transaction portfolio. (required)

  • code (str) – The code of the transaction portfolio. Together with the scope this uniquely identifies the portfolio. (required)

  • from_effective_at (str) – The lower bound effective datetime or cut label (inclusive) from which to retrieve the data. There is no lower bound if this is not specified. (required)

  • to_effective_at (str) – The upper bound effective datetime or cut label (inclusive) from which to retrieve the data. There is no upper bound if this is not specified. (required)

  • effective_at (str) – The valuation (pricing) effective datetime or cut label (inclusive) at which to evaluate the cashflows. This determines whether cashflows are evaluated in a historic or forward looking context and will, for certain models, affect where data is looked up. For example, on a swap if the effectiveAt is in the middle of the window, cashflows before it will be historic and resets assumed to exist where if the effectiveAt is before the start of the range they are forward looking and will be expectations assuming the model supports that. There is evidently a presumption here about availability of data and that the effectiveAt is realistically on or before the real-world today. (required)

  • as_at (datetime) – The asAt datetime at which to retrieve the portfolio. Defaults to returning the latest version of each transaction if not specified.

  • filter (str) – Expression to filter the result set. For example, to return only transactions with a transaction type of ‘Buy’, specify “type eq ‘Buy’”. For more information about filtering LUSID results, see https://support.lusid.com/knowledgebase/article/KA-01914.

  • recipe_id_scope (str) – The scope of the given recipeId

  • recipe_id_code (str) – The code of the given recipeID

  • exclude_unsettled_trades (bool) – If absent or set to false, cashflows will returned based on trade date - more specifically, cashflows from any unsettled trades will be included in the results. If set to true, unsettled trades will be excluded from the result set.

  • async_req (bool, optional) – Whether to execute the request asynchronously.

  • _preload_content (bool, optional) – if False, the ApiResponse.data will be set to none and raw_data will store the HTTP response body without reading/decoding. Default is True.

  • _return_http_data_only (bool, optional) – response data instead of ApiResponse object with status code, headers, etc

  • _request_timeout – timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts.

  • _request_auth (dict, optional) – set to override the auth_settings for an a single request; this effectively ignores the authentication in the spec for a single request.

Returns:

Returns the result object. If the method is called asynchronously, returns the request thread.

Return type:

tuple(ResourceListOfPortfolioCashLadder, status_code(int), headers(HTTPHeaderDict))

get_portfolio_cash_statement(scope, code, from_effective_at, to_effective_at, as_at=None, filter=None, recipe_id_scope=None, recipe_id_code=None, async_req=None, **kwargs)[source]

GetPortfolioCashStatement: Get portfolio cash statement # noqa: E501

Get a cash statement for a transaction portfolio. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True

>>> thread = api.get_portfolio_cash_statement(scope, code, from_effective_at, to_effective_at, as_at, filter, recipe_id_scope, recipe_id_code, async_req=True)
>>> result = thread.get()
Parameters:
  • scope (str) – The scope of the transaction portfolio. (required)

  • code (str) – The code of the transaction portfolio. Together with the scope this uniquely identifies the portfolio. (required)

  • from_effective_at (str) – The lower bound effective datetime or cut label (inclusive) from which to retrieve the data. There is no lower bound if this is not specified. (required)

  • to_effective_at (str) – The upper bound effective datetime or cut label (inclusive) from which to retrieve the data. There is no upper bound if this is not specified. (required)

  • as_at (datetime) – The asAt datetime at which to retrieve the portfolio. Defaults to returning the latest version of each transaction if not specified.

  • filter (str) – Expression to filter the result set. For example, to return only transactions with a transaction type of ‘Buy’, specify “type eq ‘Buy’”. For more information about filtering LUSID results, see https://support.lusid.com/knowledgebase/article/KA-01914.

  • recipe_id_scope (str) – The scope of the given recipeId

  • recipe_id_code (str) – The code of the given recipeID

  • async_req (bool, optional) – Whether to execute the request asynchronously.

  • _request_timeout – timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts.

Returns:

Returns the result object. If the method is called asynchronously, returns the request thread.

Return type:

ResourceListOfPortfolioCashFlow

get_portfolio_cash_statement_with_http_info(scope, code, from_effective_at, to_effective_at, as_at=None, filter=None, recipe_id_scope=None, recipe_id_code=None, **kwargs)[source]

GetPortfolioCashStatement: Get portfolio cash statement # noqa: E501

Get a cash statement for a transaction portfolio. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True

>>> thread = api.get_portfolio_cash_statement_with_http_info(scope, code, from_effective_at, to_effective_at, as_at, filter, recipe_id_scope, recipe_id_code, async_req=True)
>>> result = thread.get()
Parameters:
  • scope (str) – The scope of the transaction portfolio. (required)

  • code (str) – The code of the transaction portfolio. Together with the scope this uniquely identifies the portfolio. (required)

  • from_effective_at (str) – The lower bound effective datetime or cut label (inclusive) from which to retrieve the data. There is no lower bound if this is not specified. (required)

  • to_effective_at (str) – The upper bound effective datetime or cut label (inclusive) from which to retrieve the data. There is no upper bound if this is not specified. (required)

  • as_at (datetime) – The asAt datetime at which to retrieve the portfolio. Defaults to returning the latest version of each transaction if not specified.

  • filter (str) – Expression to filter the result set. For example, to return only transactions with a transaction type of ‘Buy’, specify “type eq ‘Buy’”. For more information about filtering LUSID results, see https://support.lusid.com/knowledgebase/article/KA-01914.

  • recipe_id_scope (str) – The scope of the given recipeId

  • recipe_id_code (str) – The code of the given recipeID

  • async_req (bool, optional) – Whether to execute the request asynchronously.

  • _preload_content (bool, optional) – if False, the ApiResponse.data will be set to none and raw_data will store the HTTP response body without reading/decoding. Default is True.

  • _return_http_data_only (bool, optional) – response data instead of ApiResponse object with status code, headers, etc

  • _request_timeout – timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts.

  • _request_auth (dict, optional) – set to override the auth_settings for an a single request; this effectively ignores the authentication in the spec for a single request.

Returns:

Returns the result object. If the method is called asynchronously, returns the request thread.

Return type:

tuple(ResourceListOfPortfolioCashFlow, status_code(int), headers(HTTPHeaderDict))

get_transaction_history(scope, code, transaction_id, as_at=None, async_req=None, **kwargs)[source]

[EARLY ACCESS] GetTransactionHistory: Get the history of a transaction # noqa: E501

Get all of the changes that have happened to a transaction. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True

>>> thread = api.get_transaction_history(scope, code, transaction_id, as_at, async_req=True)
>>> result = thread.get()
Parameters:
  • scope (str) – The scope of the transaction portfolio. (required)

  • code (str) – The code of the transaction portfolio. Together with the scope this uniquely identifies the transaction portfolio. (required)

  • transaction_id (str) – The unique ID of the transaction to create or update. (required)

  • as_at (datetime) – The asAt datetime at which to retrieve the history of the transaction. Defaults to return the latest version if not specified.

  • async_req (bool, optional) – Whether to execute the request asynchronously.

  • _request_timeout – timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts.

Returns:

Returns the result object. If the method is called asynchronously, returns the request thread.

Return type:

ResourceListOfChangeHistory

get_transaction_history_with_http_info(scope, code, transaction_id, as_at=None, **kwargs)[source]

[EARLY ACCESS] GetTransactionHistory: Get the history of a transaction # noqa: E501

Get all of the changes that have happened to a transaction. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True

>>> thread = api.get_transaction_history_with_http_info(scope, code, transaction_id, as_at, async_req=True)
>>> result = thread.get()
Parameters:
  • scope (str) – The scope of the transaction portfolio. (required)

  • code (str) – The code of the transaction portfolio. Together with the scope this uniquely identifies the transaction portfolio. (required)

  • transaction_id (str) – The unique ID of the transaction to create or update. (required)

  • as_at (datetime) – The asAt datetime at which to retrieve the history of the transaction. Defaults to return the latest version if not specified.

  • async_req (bool, optional) – Whether to execute the request asynchronously.

  • _preload_content (bool, optional) – if False, the ApiResponse.data will be set to none and raw_data will store the HTTP response body without reading/decoding. Default is True.

  • _return_http_data_only (bool, optional) – response data instead of ApiResponse object with status code, headers, etc

  • _request_timeout – timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts.

  • _request_auth (dict, optional) – set to override the auth_settings for an a single request; this effectively ignores the authentication in the spec for a single request.

Returns:

Returns the result object. If the method is called asynchronously, returns the request thread.

Return type:

tuple(ResourceListOfChangeHistory, status_code(int), headers(HTTPHeaderDict))

get_transactions(scope, code, from_transaction_date=None, to_transaction_date=None, as_at=None, filter=None, property_keys=None, page=None, limit=None, show_cancelled_transactions=None, sort_by=None, async_req=None, **kwargs)[source]

GetTransactions: Get transactions # noqa: E501

Retrieve all the transactions that occurred during a particular time interval. If the portfolio is a derived transaction portfolio, the transactions returned are the union set of all transactions of the parent (and any grandparents, etc.) as well as those of the derived transaction portfolio itself. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True

>>> thread = api.get_transactions(scope, code, from_transaction_date, to_transaction_date, as_at, filter, property_keys, page, limit, show_cancelled_transactions, sort_by, async_req=True)
>>> result = thread.get()
Parameters:
  • scope (str) – The scope of the transaction portfolio. (required)

  • code (str) – The code of the transaction portfolio. Together with the scope this uniquely identifies the transaction portfolio. (required)

  • from_transaction_date (str) – The lower bound effective datetime or cut label (inclusive) from which to retrieve transactions. There is no lower bound if this is not specified.

  • to_transaction_date (str) – The upper bound effective datetime or cut label (inclusive) from which to retrieve transactions. There is no upper bound if this is not specified.

  • as_at (datetime) – The asAt datetime at which to retrieve transactions. Defaults to returning the latest version of each transaction if not specified.

  • filter (str) – Expression with which to filter the result set. For example, to return only transactions with a transaction type of ‘Buy’, specify “type eq ‘Buy’” For more information about filtering LUSID results, see https://support.lusid.com/knowledgebase/article/KA-01914.

  • property_keys (List[str]) – A list of property keys from the ‘Instrument’, ‘Transaction’, “LegalEntity” or “CustodianAccount” domain to decorate onto transactions. These must have the format {domain}/{scope}/{code}, for example ‘Instrument/system/Name’ or ‘Transaction/strategy/quantsignal’.

  • page (str) – The pagination token to use to continue listing transactions from a previous call to GetTransactions.

  • limit (int) – When paginating, limit the number of returned results to this many. The current behaviour is to return all transactions if possible, but this will change to defaulting to 1000 if not specified in the future. It is recommended to populate this field to enable pagination.

  • show_cancelled_transactions (bool) – Option to specify whether or not to include cancelled transactions, including previous versions of transactions which have since been amended. Defaults to False if not specified.

  • sort_by (List[str]) – A list of field names or properties to sort by, each suffixed by “ ASC” or “ DESC”.

  • async_req (bool, optional) – Whether to execute the request asynchronously.

  • _request_timeout – timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts.

Returns:

Returns the result object. If the method is called asynchronously, returns the request thread.

Return type:

VersionedResourceListOfTransaction

get_transactions_with_http_info(scope, code, from_transaction_date=None, to_transaction_date=None, as_at=None, filter=None, property_keys=None, page=None, limit=None, show_cancelled_transactions=None, sort_by=None, **kwargs)[source]

GetTransactions: Get transactions # noqa: E501

Retrieve all the transactions that occurred during a particular time interval. If the portfolio is a derived transaction portfolio, the transactions returned are the union set of all transactions of the parent (and any grandparents, etc.) as well as those of the derived transaction portfolio itself. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True

>>> thread = api.get_transactions_with_http_info(scope, code, from_transaction_date, to_transaction_date, as_at, filter, property_keys, page, limit, show_cancelled_transactions, sort_by, async_req=True)
>>> result = thread.get()
Parameters:
  • scope (str) – The scope of the transaction portfolio. (required)

  • code (str) – The code of the transaction portfolio. Together with the scope this uniquely identifies the transaction portfolio. (required)

  • from_transaction_date (str) – The lower bound effective datetime or cut label (inclusive) from which to retrieve transactions. There is no lower bound if this is not specified.

  • to_transaction_date (str) – The upper bound effective datetime or cut label (inclusive) from which to retrieve transactions. There is no upper bound if this is not specified.

  • as_at (datetime) – The asAt datetime at which to retrieve transactions. Defaults to returning the latest version of each transaction if not specified.

  • filter (str) – Expression with which to filter the result set. For example, to return only transactions with a transaction type of ‘Buy’, specify “type eq ‘Buy’” For more information about filtering LUSID results, see https://support.lusid.com/knowledgebase/article/KA-01914.

  • property_keys (List[str]) – A list of property keys from the ‘Instrument’, ‘Transaction’, “LegalEntity” or “CustodianAccount” domain to decorate onto transactions. These must have the format {domain}/{scope}/{code}, for example ‘Instrument/system/Name’ or ‘Transaction/strategy/quantsignal’.

  • page (str) – The pagination token to use to continue listing transactions from a previous call to GetTransactions.

  • limit (int) – When paginating, limit the number of returned results to this many. The current behaviour is to return all transactions if possible, but this will change to defaulting to 1000 if not specified in the future. It is recommended to populate this field to enable pagination.

  • show_cancelled_transactions (bool) – Option to specify whether or not to include cancelled transactions, including previous versions of transactions which have since been amended. Defaults to False if not specified.

  • sort_by (List[str]) – A list of field names or properties to sort by, each suffixed by “ ASC” or “ DESC”.

  • async_req (bool, optional) – Whether to execute the request asynchronously.

  • _preload_content (bool, optional) – if False, the ApiResponse.data will be set to none and raw_data will store the HTTP response body without reading/decoding. Default is True.

  • _return_http_data_only (bool, optional) – response data instead of ApiResponse object with status code, headers, etc

  • _request_timeout – timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts.

  • _request_auth (dict, optional) – set to override the auth_settings for an a single request; this effectively ignores the authentication in the spec for a single request.

Returns:

Returns the result object. If the method is called asynchronously, returns the request thread.

Return type:

tuple(VersionedResourceListOfTransaction, status_code(int), headers(HTTPHeaderDict))

get_upsertable_portfolio_cash_flows(scope, code, effective_at=None, window_start=None, window_end=None, as_at=None, filter=None, recipe_id_scope=None, recipe_id_code=None, exclude_unsettled_trades=None, async_req=None, **kwargs)[source]

[BETA] GetUpsertablePortfolioCashFlows: Get upsertable portfolio cash flows. # noqa: E501

Get the set of cash flows that occur in a window for the given portfolio instruments as a set of upsertable transactions (DTOs). Note that grouping can affect the quantity of information returned; where a holding is an amalgamation of one or more (e.g. cash) instruments, a unique transaction identifier will not be available. The same may go for diagnostic information (e.g. multiple sources of an aggregate cash amount on a date that is not split out. Grouping at the transaction and instrument level is recommended for those seeking to attribute individual flows. In essence this is identical to the ‘GetCashFlows’ endpoint but returns the cash flows as a set of transactions suitable for directly putting back into LUSID. There are a couple of important points: (1) Internally it can not be fully known where the user wishes to insert these transactions, e.g. portfolio and movement type. These are therefore defaulted to a sensible option; the user will likely need to change these. (2) Similarly, knowledge of any properties the user might wish to add to a transaction are unknown and consequently left empty. (3) The transaction id that is added is simply a concatenation of the original transaction id, instrument id and payment date and direction. The user can happily override this. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True

>>> thread = api.get_upsertable_portfolio_cash_flows(scope, code, effective_at, window_start, window_end, as_at, filter, recipe_id_scope, recipe_id_code, exclude_unsettled_trades, async_req=True)
>>> result = thread.get()
Parameters:
  • scope (str) – The scope of the transaction portfolio. (required)

  • code (str) – The code of the transaction portfolio. Together with the scope this uniquely identifies the portfolio. (required)

  • effective_at (str) – The valuation (pricing) effective datetime or cut label (inclusive) at which to evaluate the cashflows. This determines whether cashflows are evaluated in a historic or forward looking context and will, for certain models, affect where data is looked up. For example, on a swap if the effectiveAt is in the middle of the window, cashflows before it will be historic and resets assumed to exist where if the effectiveAt is before the start of the range they are forward looking and will be expectations assuming the model supports that. There is evidently a presumption here about availability of data and that the effectiveAt is realistically on or before the real-world today.

  • window_start (str) – The lower bound effective datetime or cut label (inclusive) from which to retrieve the cashflows. There is no lower bound if this is not specified. i.e. uses minimum date-time

  • window_end (str) – The upper bound effective datetime or cut label (inclusive) from which to retrieve the cashflows. The upper bound defaults to ‘max date’ if it is not specified

  • as_at (datetime) – The asAt datetime at which to retrieve the portfolio. Defaults to return the latest version of each transaction if not specified.

  • filter (str) – Expression to filter the result set. For example, to return only transactions with a transaction type of ‘Buy’, specify “type eq ‘Buy’”. For more information about filtering LUSID results, see https://support.lusid.com/knowledgebase/article/KA-01914.

  • recipe_id_scope (str) – The scope of the given recipeId

  • recipe_id_code (str) – The code of the given recipeID

  • exclude_unsettled_trades (bool) – If absent or set to true, unsettled trades will be excluded from the result set. If set to false, cashflows will returned based on trade date - more specifically, cashflows from any unsettled trades will be included in the results.

  • async_req (bool, optional) – Whether to execute the request asynchronously.

  • _request_timeout – timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts.

Returns:

Returns the result object. If the method is called asynchronously, returns the request thread.

Return type:

ResourceListOfTransaction

get_upsertable_portfolio_cash_flows_with_http_info(scope, code, effective_at=None, window_start=None, window_end=None, as_at=None, filter=None, recipe_id_scope=None, recipe_id_code=None, exclude_unsettled_trades=None, **kwargs)[source]

[BETA] GetUpsertablePortfolioCashFlows: Get upsertable portfolio cash flows. # noqa: E501

Get the set of cash flows that occur in a window for the given portfolio instruments as a set of upsertable transactions (DTOs). Note that grouping can affect the quantity of information returned; where a holding is an amalgamation of one or more (e.g. cash) instruments, a unique transaction identifier will not be available. The same may go for diagnostic information (e.g. multiple sources of an aggregate cash amount on a date that is not split out. Grouping at the transaction and instrument level is recommended for those seeking to attribute individual flows. In essence this is identical to the ‘GetCashFlows’ endpoint but returns the cash flows as a set of transactions suitable for directly putting back into LUSID. There are a couple of important points: (1) Internally it can not be fully known where the user wishes to insert these transactions, e.g. portfolio and movement type. These are therefore defaulted to a sensible option; the user will likely need to change these. (2) Similarly, knowledge of any properties the user might wish to add to a transaction are unknown and consequently left empty. (3) The transaction id that is added is simply a concatenation of the original transaction id, instrument id and payment date and direction. The user can happily override this. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True

>>> thread = api.get_upsertable_portfolio_cash_flows_with_http_info(scope, code, effective_at, window_start, window_end, as_at, filter, recipe_id_scope, recipe_id_code, exclude_unsettled_trades, async_req=True)
>>> result = thread.get()
Parameters:
  • scope (str) – The scope of the transaction portfolio. (required)

  • code (str) – The code of the transaction portfolio. Together with the scope this uniquely identifies the portfolio. (required)

  • effective_at (str) – The valuation (pricing) effective datetime or cut label (inclusive) at which to evaluate the cashflows. This determines whether cashflows are evaluated in a historic or forward looking context and will, for certain models, affect where data is looked up. For example, on a swap if the effectiveAt is in the middle of the window, cashflows before it will be historic and resets assumed to exist where if the effectiveAt is before the start of the range they are forward looking and will be expectations assuming the model supports that. There is evidently a presumption here about availability of data and that the effectiveAt is realistically on or before the real-world today.

  • window_start (str) – The lower bound effective datetime or cut label (inclusive) from which to retrieve the cashflows. There is no lower bound if this is not specified. i.e. uses minimum date-time

  • window_end (str) – The upper bound effective datetime or cut label (inclusive) from which to retrieve the cashflows. The upper bound defaults to ‘max date’ if it is not specified

  • as_at (datetime) – The asAt datetime at which to retrieve the portfolio. Defaults to return the latest version of each transaction if not specified.

  • filter (str) – Expression to filter the result set. For example, to return only transactions with a transaction type of ‘Buy’, specify “type eq ‘Buy’”. For more information about filtering LUSID results, see https://support.lusid.com/knowledgebase/article/KA-01914.

  • recipe_id_scope (str) – The scope of the given recipeId

  • recipe_id_code (str) – The code of the given recipeID

  • exclude_unsettled_trades (bool) – If absent or set to true, unsettled trades will be excluded from the result set. If set to false, cashflows will returned based on trade date - more specifically, cashflows from any unsettled trades will be included in the results.

  • async_req (bool, optional) – Whether to execute the request asynchronously.

  • _preload_content (bool, optional) – if False, the ApiResponse.data will be set to none and raw_data will store the HTTP response body without reading/decoding. Default is True.

  • _return_http_data_only (bool, optional) – response data instead of ApiResponse object with status code, headers, etc

  • _request_timeout – timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts.

  • _request_auth (dict, optional) – set to override the auth_settings for an a single request; this effectively ignores the authentication in the spec for a single request.

Returns:

Returns the result object. If the method is called asynchronously, returns the request thread.

Return type:

tuple(ResourceListOfTransaction, status_code(int), headers(HTTPHeaderDict))

list_custodian_accounts(scope, code, effective_at=None, as_at=None, page=None, limit=None, filter=None, property_keys=None, async_req=None, **kwargs)[source]

[EXPERIMENTAL] ListCustodianAccounts: List Custodian Accounts # noqa: E501

List the custodian accounts in a Transaction Portfolios # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True

>>> thread = api.list_custodian_accounts(scope, code, effective_at, as_at, page, limit, filter, property_keys, async_req=True)
>>> result = thread.get()
Parameters:
  • scope (str) – The scope of the Transaction Portfolio. (required)

  • code (str) – The code of the Transaction Portfolio. Together with the scope this uniquely identifies the Transaction Portfolios. (required)

  • effective_at (str) – The effective datetime or cut label at which to list the TimeVariant properties decorated on Custodian Accounts. Defaults to the current LUSID system datetime if not specified.

  • as_at (datetime) – The asAt datetime at which to retrieve the instrument. Defaults to returning the latest version if not specified.

  • page (str) – The pagination token to use to continue listing custodian accounts; this value is returned from the previous call. If a pagination token is provided, the filter, effectiveAt and asAt fields must not have changed since the original request.

  • limit (int) – When paginating, limit the results to this number. Defaults to 100 if not specified.

  • filter (str) – Expression to filter the results. For example, to filter on the Custodian Account type, specify “code eq ‘001’”. For more information about filtering results, see https://support.lusid.com/knowledgebase/article/KA-01914.

  • property_keys (List[str]) – A list of property keys from the ‘CustodianAccount’ domain to decorate onto the Custodian Account. These must have the format {domain}/{scope}/{code}, for example ‘CustodianAccount/system/Name’.

  • async_req (bool, optional) – Whether to execute the request asynchronously.

  • _request_timeout – timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts.

Returns:

Returns the result object. If the method is called asynchronously, returns the request thread.

Return type:

PagedResourceListOfCustodianAccount

list_custodian_accounts_with_http_info(scope, code, effective_at=None, as_at=None, page=None, limit=None, filter=None, property_keys=None, **kwargs)[source]

[EXPERIMENTAL] ListCustodianAccounts: List Custodian Accounts # noqa: E501

List the custodian accounts in a Transaction Portfolios # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True

>>> thread = api.list_custodian_accounts_with_http_info(scope, code, effective_at, as_at, page, limit, filter, property_keys, async_req=True)
>>> result = thread.get()
Parameters:
  • scope (str) – The scope of the Transaction Portfolio. (required)

  • code (str) – The code of the Transaction Portfolio. Together with the scope this uniquely identifies the Transaction Portfolios. (required)

  • effective_at (str) – The effective datetime or cut label at which to list the TimeVariant properties decorated on Custodian Accounts. Defaults to the current LUSID system datetime if not specified.

  • as_at (datetime) – The asAt datetime at which to retrieve the instrument. Defaults to returning the latest version if not specified.

  • page (str) – The pagination token to use to continue listing custodian accounts; this value is returned from the previous call. If a pagination token is provided, the filter, effectiveAt and asAt fields must not have changed since the original request.

  • limit (int) – When paginating, limit the results to this number. Defaults to 100 if not specified.

  • filter (str) – Expression to filter the results. For example, to filter on the Custodian Account type, specify “code eq ‘001’”. For more information about filtering results, see https://support.lusid.com/knowledgebase/article/KA-01914.

  • property_keys (List[str]) – A list of property keys from the ‘CustodianAccount’ domain to decorate onto the Custodian Account. These must have the format {domain}/{scope}/{code}, for example ‘CustodianAccount/system/Name’.

  • async_req (bool, optional) – Whether to execute the request asynchronously.

  • _preload_content (bool, optional) – if False, the ApiResponse.data will be set to none and raw_data will store the HTTP response body without reading/decoding. Default is True.

  • _return_http_data_only (bool, optional) – response data instead of ApiResponse object with status code, headers, etc

  • _request_timeout – timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts.

  • _request_auth (dict, optional) – set to override the auth_settings for an a single request; this effectively ignores the authentication in the spec for a single request.

Returns:

Returns the result object. If the method is called asynchronously, returns the request thread.

Return type:

tuple(PagedResourceListOfCustodianAccount, status_code(int), headers(HTTPHeaderDict))

list_holdings_adjustments(scope, code, from_effective_at=None, to_effective_at=None, as_at=None, async_req=None, **kwargs)[source]

ListHoldingsAdjustments: List holdings adjustments # noqa: E501

List the holdings adjustments made to the specified transaction portfolio over a specified interval of effective time. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True

>>> thread = api.list_holdings_adjustments(scope, code, from_effective_at, to_effective_at, as_at, async_req=True)
>>> result = thread.get()
Parameters:
  • scope (str) – The scope of the transaction portfolio. (required)

  • code (str) – The code of the transaction portfolio. Together with the scope this uniquely identifies the transaction portfolio. (required)

  • from_effective_at (str) – The lower bound effective datetime or cut label (inclusive) from which to retrieve the holdings adjustments. There is no lower bound if this is not specified.

  • to_effective_at (str) – The upper bound effective datetime or cut label (inclusive) from which to retrieve the holdings adjustments. There is no upper bound if this is not specified.

  • as_at (datetime) – The asAt datetime at which to retrieve the holdings adjustments. Defaults to return the latest version of each holding adjustment if not specified.

  • async_req (bool, optional) – Whether to execute the request asynchronously.

  • _request_timeout – timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts.

Returns:

Returns the result object. If the method is called asynchronously, returns the request thread.

Return type:

ResourceListOfHoldingsAdjustmentHeader

list_holdings_adjustments_with_http_info(scope, code, from_effective_at=None, to_effective_at=None, as_at=None, **kwargs)[source]

ListHoldingsAdjustments: List holdings adjustments # noqa: E501

List the holdings adjustments made to the specified transaction portfolio over a specified interval of effective time. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True

>>> thread = api.list_holdings_adjustments_with_http_info(scope, code, from_effective_at, to_effective_at, as_at, async_req=True)
>>> result = thread.get()
Parameters:
  • scope (str) – The scope of the transaction portfolio. (required)

  • code (str) – The code of the transaction portfolio. Together with the scope this uniquely identifies the transaction portfolio. (required)

  • from_effective_at (str) – The lower bound effective datetime or cut label (inclusive) from which to retrieve the holdings adjustments. There is no lower bound if this is not specified.

  • to_effective_at (str) – The upper bound effective datetime or cut label (inclusive) from which to retrieve the holdings adjustments. There is no upper bound if this is not specified.

  • as_at (datetime) – The asAt datetime at which to retrieve the holdings adjustments. Defaults to return the latest version of each holding adjustment if not specified.

  • async_req (bool, optional) – Whether to execute the request asynchronously.

  • _preload_content (bool, optional) – if False, the ApiResponse.data will be set to none and raw_data will store the HTTP response body without reading/decoding. Default is True.

  • _return_http_data_only (bool, optional) – response data instead of ApiResponse object with status code, headers, etc

  • _request_timeout – timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts.

  • _request_auth (dict, optional) – set to override the auth_settings for an a single request; this effectively ignores the authentication in the spec for a single request.

Returns:

Returns the result object. If the method is called asynchronously, returns the request thread.

Return type:

tuple(ResourceListOfHoldingsAdjustmentHeader, status_code(int), headers(HTTPHeaderDict))

patch_portfolio_details(scope, code, operation, effective_at=None, async_req=None, **kwargs)[source]

[EARLY ACCESS] PatchPortfolioDetails: Patch portfolio details # noqa: E501

Create or update certain details for a particular transaction portfolio. The behaviour is defined by the JSON Patch specification. Note that not all elements of a transaction portfolio definition are modifiable once it has been created due to the potential implications for data already stored. Currently supported properties are: SubHoldingKeys, BaseCurrency, AmortisationMethod # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True

>>> thread = api.patch_portfolio_details(scope, code, operation, effective_at, async_req=True)
>>> result = thread.get()
Parameters:
  • scope (str) – The scope of the transaction portfolio. (required)

  • code (str) – The code of the transaction portfolio. Together with the scope this uniquely identifies the transaction portfolio. (required)

  • operation (List[Operation]) – The patch document. (required)

  • effective_at (str) – The effective datetime or cut label at which the updated or inserted details should become valid. Defaults to the current LUSID system datetime if not specified. Note that this will affect all bitemporal entities in the request, but will not be used for any perpetual entities.

  • async_req (bool, optional) – Whether to execute the request asynchronously.

  • _request_timeout – timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts.

Returns:

Returns the result object. If the method is called asynchronously, returns the request thread.

Return type:

PortfolioDetails

patch_portfolio_details_with_http_info(scope, code, operation, effective_at=None, **kwargs)[source]

[EARLY ACCESS] PatchPortfolioDetails: Patch portfolio details # noqa: E501

Create or update certain details for a particular transaction portfolio. The behaviour is defined by the JSON Patch specification. Note that not all elements of a transaction portfolio definition are modifiable once it has been created due to the potential implications for data already stored. Currently supported properties are: SubHoldingKeys, BaseCurrency, AmortisationMethod # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True

>>> thread = api.patch_portfolio_details_with_http_info(scope, code, operation, effective_at, async_req=True)
>>> result = thread.get()
Parameters:
  • scope (str) – The scope of the transaction portfolio. (required)

  • code (str) – The code of the transaction portfolio. Together with the scope this uniquely identifies the transaction portfolio. (required)

  • operation (List[Operation]) – The patch document. (required)

  • effective_at (str) – The effective datetime or cut label at which the updated or inserted details should become valid. Defaults to the current LUSID system datetime if not specified. Note that this will affect all bitemporal entities in the request, but will not be used for any perpetual entities.

  • async_req (bool, optional) – Whether to execute the request asynchronously.

  • _preload_content (bool, optional) – if False, the ApiResponse.data will be set to none and raw_data will store the HTTP response body without reading/decoding. Default is True.

  • _return_http_data_only (bool, optional) – response data instead of ApiResponse object with status code, headers, etc

  • _request_timeout – timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts.

  • _request_auth (dict, optional) – set to override the auth_settings for an a single request; this effectively ignores the authentication in the spec for a single request.

Returns:

Returns the result object. If the method is called asynchronously, returns the request thread.

Return type:

tuple(PortfolioDetails, status_code(int), headers(HTTPHeaderDict))

resolve_instrument(scope, code, instrument_identifier_type, instrument_identifier_value, from_effective_at=None, re_resolve=None, request_body=None, async_req=None, **kwargs)[source]

[EARLY ACCESS] ResolveInstrument: Resolve instrument # noqa: E501

Try to resolve the instrument for transaction and holdings for a given instrument identifier and a specified period of time. Also update the instrument identifiers with the given instrument identifiers collection. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True

>>> thread = api.resolve_instrument(scope, code, instrument_identifier_type, instrument_identifier_value, from_effective_at, re_resolve, request_body, async_req=True)
>>> result = thread.get()
Parameters:
  • scope (str) – The scope of the transaction portfolio. (required)

  • code (str) – The code of the transaction portfolio. Together with the scope this uniquely identifies the transaction portfolio. (required)

  • instrument_identifier_type (str) – The instrument identifier type. (required)

  • instrument_identifier_value (str) – The value for the given instrument identifier. (required)

  • from_effective_at (str) – The lower bound effective datetime or cut label (inclusive) from which to retrieve the data. There is no lower bound if this is not specified.

  • re_resolve (bool) – When set to true, instrument resolution will be attempted for all transactions and holdings for the given identifier and date range. When set to false (default behaviour), instrument resolution will only be attempted for those transactions and holdings that were previously unresolved.

  • request_body (Dict[str, str]) – The dictionary with the instrument identifiers to be updated on the transaction and holdings.

  • async_req (bool, optional) – Whether to execute the request asynchronously.

  • _request_timeout – timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts.

Returns:

Returns the result object. If the method is called asynchronously, returns the request thread.

Return type:

UpsertPortfolioTransactionsResponse

resolve_instrument_with_http_info(scope, code, instrument_identifier_type, instrument_identifier_value, from_effective_at=None, re_resolve=None, request_body=None, **kwargs)[source]

[EARLY ACCESS] ResolveInstrument: Resolve instrument # noqa: E501

Try to resolve the instrument for transaction and holdings for a given instrument identifier and a specified period of time. Also update the instrument identifiers with the given instrument identifiers collection. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True

>>> thread = api.resolve_instrument_with_http_info(scope, code, instrument_identifier_type, instrument_identifier_value, from_effective_at, re_resolve, request_body, async_req=True)
>>> result = thread.get()
Parameters:
  • scope (str) – The scope of the transaction portfolio. (required)

  • code (str) – The code of the transaction portfolio. Together with the scope this uniquely identifies the transaction portfolio. (required)

  • instrument_identifier_type (str) – The instrument identifier type. (required)

  • instrument_identifier_value (str) – The value for the given instrument identifier. (required)

  • from_effective_at (str) – The lower bound effective datetime or cut label (inclusive) from which to retrieve the data. There is no lower bound if this is not specified.

  • re_resolve (bool) – When set to true, instrument resolution will be attempted for all transactions and holdings for the given identifier and date range. When set to false (default behaviour), instrument resolution will only be attempted for those transactions and holdings that were previously unresolved.

  • request_body (Dict[str, str]) – The dictionary with the instrument identifiers to be updated on the transaction and holdings.

  • async_req (bool, optional) – Whether to execute the request asynchronously.

  • _preload_content (bool, optional) – if False, the ApiResponse.data will be set to none and raw_data will store the HTTP response body without reading/decoding. Default is True.

  • _return_http_data_only (bool, optional) – response data instead of ApiResponse object with status code, headers, etc

  • _request_timeout – timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts.

  • _request_auth (dict, optional) – set to override the auth_settings for an a single request; this effectively ignores the authentication in the spec for a single request.

Returns:

Returns the result object. If the method is called asynchronously, returns the request thread.

Return type:

tuple(UpsertPortfolioTransactionsResponse, status_code(int), headers(HTTPHeaderDict))

set_holdings(scope, code, effective_at, adjust_holding_request, reconciliation_methods=None, async_req=None, **kwargs)[source]

SetHoldings: Set holdings # noqa: E501

Set the holdings of the specified transaction portfolio to the provided targets. LUSID will automatically construct adjustment transactions to ensure that the entire set of holdings for the transaction portfolio are always set to the provided targets for the specified effective datetime. Read more about the difference between adjusting and setting holdings here https://support.lusid.com/how-do-i-adjust-my-holdings. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True

>>> thread = api.set_holdings(scope, code, effective_at, adjust_holding_request, reconciliation_methods, async_req=True)
>>> result = thread.get()
Parameters:
  • scope (str) – The scope of the transaction portfolio. (required)

  • code (str) – The code of the transaction portfolio. Together with the scope this uniquely identifies the transaction portfolio. (required)

  • effective_at (str) – The effective datetime or cut label at which the holdings should be set to the provided targets. (required)

  • adjust_holding_request (List[AdjustHoldingRequest]) – The complete set of target holdings for the transaction portfolio. (required)

  • reconciliation_methods (List[str]) – Optional parameter for specifying a reconciliation method: e.g. FxForward.

  • async_req (bool, optional) – Whether to execute the request asynchronously.

  • _request_timeout – timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts.

Returns:

Returns the result object. If the method is called asynchronously, returns the request thread.

Return type:

AdjustHolding

set_holdings_with_http_info(scope, code, effective_at, adjust_holding_request, reconciliation_methods=None, **kwargs)[source]

SetHoldings: Set holdings # noqa: E501

Set the holdings of the specified transaction portfolio to the provided targets. LUSID will automatically construct adjustment transactions to ensure that the entire set of holdings for the transaction portfolio are always set to the provided targets for the specified effective datetime. Read more about the difference between adjusting and setting holdings here https://support.lusid.com/how-do-i-adjust-my-holdings. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True

>>> thread = api.set_holdings_with_http_info(scope, code, effective_at, adjust_holding_request, reconciliation_methods, async_req=True)
>>> result = thread.get()
Parameters:
  • scope (str) – The scope of the transaction portfolio. (required)

  • code (str) – The code of the transaction portfolio. Together with the scope this uniquely identifies the transaction portfolio. (required)

  • effective_at (str) – The effective datetime or cut label at which the holdings should be set to the provided targets. (required)

  • adjust_holding_request (List[AdjustHoldingRequest]) – The complete set of target holdings for the transaction portfolio. (required)

  • reconciliation_methods (List[str]) – Optional parameter for specifying a reconciliation method: e.g. FxForward.

  • async_req (bool, optional) – Whether to execute the request asynchronously.

  • _preload_content (bool, optional) – if False, the ApiResponse.data will be set to none and raw_data will store the HTTP response body without reading/decoding. Default is True.

  • _return_http_data_only (bool, optional) – response data instead of ApiResponse object with status code, headers, etc

  • _request_timeout – timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts.

  • _request_auth (dict, optional) – set to override the auth_settings for an a single request; this effectively ignores the authentication in the spec for a single request.

Returns:

Returns the result object. If the method is called asynchronously, returns the request thread.

Return type:

tuple(AdjustHolding, status_code(int), headers(HTTPHeaderDict))

upsert_custodian_accounts(scope, code, custodian_account_request, async_req=None, **kwargs)[source]

[EXPERIMENTAL] UpsertCustodianAccounts: Upsert Custodian Accounts # noqa: E501

Create or update Custodian Accounts in the Transaction Portfolios. A Custodian Account will be updated if it already exists and created if it does not. The batch limit per request is 2,000. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True

>>> thread = api.upsert_custodian_accounts(scope, code, custodian_account_request, async_req=True)
>>> result = thread.get()
Parameters:
  • scope (str) – The scope of the Transaction Portfolio. (required)

  • code (str) – The code of the Transaction Portfolio. Together with the scope this uniquely identifies the Transaction Portfolios. (required)

  • custodian_account_request (List[CustodianAccountRequest]) – A list of Custodian Accounts to be created or updated. (required)

  • async_req (bool, optional) – Whether to execute the request asynchronously.

  • _request_timeout – timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts.

Returns:

Returns the result object. If the method is called asynchronously, returns the request thread.

Return type:

CustodianAccountsUpsertResponse

upsert_custodian_accounts_properties(scope, code, custodian_account_scope, custodian_account_code, request_body=None, async_req=None, **kwargs)[source]

[EXPERIMENTAL] UpsertCustodianAccountsProperties: Upsert custodian accounts properties # noqa: E501

Update or insert one or more properties onto a single custodian account. A property will be updated if it already exists and inserted if it does not. All properties must be of the domain ‘CustodianAccount’. Upserting a property that exists for a Transaction Portfolios, with a null value, will delete the instance of the property for that group. Properties have an <i>effectiveFrom</i> datetime for which the property is valid, and an <i>effectiveUntil</i> datetime until which the property is valid. Not supplying an <i>effectiveUntil</i> datetime results in the property being valid indefinitely, or until the next <i>effectiveFrom</i> datetime of the property. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True

>>> thread = api.upsert_custodian_accounts_properties(scope, code, custodian_account_scope, custodian_account_code, request_body, async_req=True)
>>> result = thread.get()
Parameters:
  • scope (str) – The scope of the Transaction Portfolios to update or insert the properties onto. (required)

  • code (str) – The code of the Transaction Portfolios to update or insert the properties onto. Together with the scope this uniquely identifies the Transaction Portfolios. (required)

  • custodian_account_scope (str) – The scope of the Custodian Account to update or insert the properties onto. (required)

  • custodian_account_code (str) – The unique ID of the custodian account to create or update properties for. (required)

  • request_body (Dict[str, ModelProperty]) – The properties to be updated or inserted onto the Transaction Portfolio. Each property in the request must be keyed by its unique property key. This has the format {domain}/{scope}/{code} e.g. “CustodianAccount/Manager/Id”.

  • async_req (bool, optional) – Whether to execute the request asynchronously.

  • _request_timeout – timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts.

Returns:

Returns the result object. If the method is called asynchronously, returns the request thread.

Return type:

CustodianAccountProperties

upsert_custodian_accounts_properties_with_http_info(scope, code, custodian_account_scope, custodian_account_code, request_body=None, **kwargs)[source]

[EXPERIMENTAL] UpsertCustodianAccountsProperties: Upsert custodian accounts properties # noqa: E501

Update or insert one or more properties onto a single custodian account. A property will be updated if it already exists and inserted if it does not. All properties must be of the domain ‘CustodianAccount’. Upserting a property that exists for a Transaction Portfolios, with a null value, will delete the instance of the property for that group. Properties have an <i>effectiveFrom</i> datetime for which the property is valid, and an <i>effectiveUntil</i> datetime until which the property is valid. Not supplying an <i>effectiveUntil</i> datetime results in the property being valid indefinitely, or until the next <i>effectiveFrom</i> datetime of the property. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True

>>> thread = api.upsert_custodian_accounts_properties_with_http_info(scope, code, custodian_account_scope, custodian_account_code, request_body, async_req=True)
>>> result = thread.get()
Parameters:
  • scope (str) – The scope of the Transaction Portfolios to update or insert the properties onto. (required)

  • code (str) – The code of the Transaction Portfolios to update or insert the properties onto. Together with the scope this uniquely identifies the Transaction Portfolios. (required)

  • custodian_account_scope (str) – The scope of the Custodian Account to update or insert the properties onto. (required)

  • custodian_account_code (str) – The unique ID of the custodian account to create or update properties for. (required)

  • request_body (Dict[str, ModelProperty]) – The properties to be updated or inserted onto the Transaction Portfolio. Each property in the request must be keyed by its unique property key. This has the format {domain}/{scope}/{code} e.g. “CustodianAccount/Manager/Id”.

  • async_req (bool, optional) – Whether to execute the request asynchronously.

  • _preload_content (bool, optional) – if False, the ApiResponse.data will be set to none and raw_data will store the HTTP response body without reading/decoding. Default is True.

  • _return_http_data_only (bool, optional) – response data instead of ApiResponse object with status code, headers, etc

  • _request_timeout – timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts.

  • _request_auth (dict, optional) – set to override the auth_settings for an a single request; this effectively ignores the authentication in the spec for a single request.

Returns:

Returns the result object. If the method is called asynchronously, returns the request thread.

Return type:

tuple(CustodianAccountProperties, status_code(int), headers(HTTPHeaderDict))

upsert_custodian_accounts_with_http_info(scope, code, custodian_account_request, **kwargs)[source]

[EXPERIMENTAL] UpsertCustodianAccounts: Upsert Custodian Accounts # noqa: E501

Create or update Custodian Accounts in the Transaction Portfolios. A Custodian Account will be updated if it already exists and created if it does not. The batch limit per request is 2,000. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True

>>> thread = api.upsert_custodian_accounts_with_http_info(scope, code, custodian_account_request, async_req=True)
>>> result = thread.get()
Parameters:
  • scope (str) – The scope of the Transaction Portfolio. (required)

  • code (str) – The code of the Transaction Portfolio. Together with the scope this uniquely identifies the Transaction Portfolios. (required)

  • custodian_account_request (List[CustodianAccountRequest]) – A list of Custodian Accounts to be created or updated. (required)

  • async_req (bool, optional) – Whether to execute the request asynchronously.

  • _preload_content (bool, optional) – if False, the ApiResponse.data will be set to none and raw_data will store the HTTP response body without reading/decoding. Default is True.

  • _return_http_data_only (bool, optional) – response data instead of ApiResponse object with status code, headers, etc

  • _request_timeout – timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts.

  • _request_auth (dict, optional) – set to override the auth_settings for an a single request; this effectively ignores the authentication in the spec for a single request.

Returns:

Returns the result object. If the method is called asynchronously, returns the request thread.

Return type:

tuple(CustodianAccountsUpsertResponse, status_code(int), headers(HTTPHeaderDict))

upsert_portfolio_details(scope, code, create_portfolio_details, effective_at=None, async_req=None, **kwargs)[source]

UpsertPortfolioDetails: Upsert portfolio details # noqa: E501

Create or update certain details for a particular transaction portfolio. The details are updated if they already exist, and inserted if they do not. Note that not all elements of a transaction portfolio definition are modifiable once it has been created due to the potential implications for data already stored. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True

>>> thread = api.upsert_portfolio_details(scope, code, create_portfolio_details, effective_at, async_req=True)
>>> result = thread.get()
Parameters:
  • scope (str) – The scope of the transaction portfolio. (required)

  • code (str) – The code of the transaction portfolio. Together with the scope this uniquely identifies the transaction portfolio. (required)

  • create_portfolio_details (CreatePortfolioDetails) – The details to create or update for the specified transaction portfolio. (required)

  • effective_at (str) – The effective datetime or cut label at which the updated or inserted details should become valid. Defaults to the current LUSID system datetime if not specified.

  • async_req (bool, optional) – Whether to execute the request asynchronously.

  • _request_timeout – timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts.

Returns:

Returns the result object. If the method is called asynchronously, returns the request thread.

Return type:

PortfolioDetails

upsert_portfolio_details_with_http_info(scope, code, create_portfolio_details, effective_at=None, **kwargs)[source]

UpsertPortfolioDetails: Upsert portfolio details # noqa: E501

Create or update certain details for a particular transaction portfolio. The details are updated if they already exist, and inserted if they do not. Note that not all elements of a transaction portfolio definition are modifiable once it has been created due to the potential implications for data already stored. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True

>>> thread = api.upsert_portfolio_details_with_http_info(scope, code, create_portfolio_details, effective_at, async_req=True)
>>> result = thread.get()
Parameters:
  • scope (str) – The scope of the transaction portfolio. (required)

  • code (str) – The code of the transaction portfolio. Together with the scope this uniquely identifies the transaction portfolio. (required)

  • create_portfolio_details (CreatePortfolioDetails) – The details to create or update for the specified transaction portfolio. (required)

  • effective_at (str) – The effective datetime or cut label at which the updated or inserted details should become valid. Defaults to the current LUSID system datetime if not specified.

  • async_req (bool, optional) – Whether to execute the request asynchronously.

  • _preload_content (bool, optional) – if False, the ApiResponse.data will be set to none and raw_data will store the HTTP response body without reading/decoding. Default is True.

  • _return_http_data_only (bool, optional) – response data instead of ApiResponse object with status code, headers, etc

  • _request_timeout – timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts.

  • _request_auth (dict, optional) – set to override the auth_settings for an a single request; this effectively ignores the authentication in the spec for a single request.

Returns:

Returns the result object. If the method is called asynchronously, returns the request thread.

Return type:

tuple(PortfolioDetails, status_code(int), headers(HTTPHeaderDict))

upsert_transaction_properties(scope, code, transaction_id, request_body, async_req=None, **kwargs)[source]

UpsertTransactionProperties: Upsert transaction properties # noqa: E501

Create or update one or more transaction properties for a single transaction in the transaction portfolio. Each property will be updated if it already exists and created if it does not. Both transaction and portfolio must exist at the time when properties are created or updated. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True

>>> thread = api.upsert_transaction_properties(scope, code, transaction_id, request_body, async_req=True)
>>> result = thread.get()
Parameters:
  • scope (str) – The scope of the transaction portfolio. (required)

  • code (str) – The code of the transaction portfolio. Together with the scope this uniquely identifies the transaction portfolio. (required)

  • transaction_id (str) – The unique ID of the transaction to create or update properties for. (required)

  • request_body (Dict[str, PerpetualProperty]) – The properties and their associated values to create or update. (required)

  • async_req (bool, optional) – Whether to execute the request asynchronously.

  • _request_timeout – timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts.

Returns:

Returns the result object. If the method is called asynchronously, returns the request thread.

Return type:

UpsertTransactionPropertiesResponse

upsert_transaction_properties_with_http_info(scope, code, transaction_id, request_body, **kwargs)[source]

UpsertTransactionProperties: Upsert transaction properties # noqa: E501

Create or update one or more transaction properties for a single transaction in the transaction portfolio. Each property will be updated if it already exists and created if it does not. Both transaction and portfolio must exist at the time when properties are created or updated. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True

>>> thread = api.upsert_transaction_properties_with_http_info(scope, code, transaction_id, request_body, async_req=True)
>>> result = thread.get()
Parameters:
  • scope (str) – The scope of the transaction portfolio. (required)

  • code (str) – The code of the transaction portfolio. Together with the scope this uniquely identifies the transaction portfolio. (required)

  • transaction_id (str) – The unique ID of the transaction to create or update properties for. (required)

  • request_body (Dict[str, PerpetualProperty]) – The properties and their associated values to create or update. (required)

  • async_req (bool, optional) – Whether to execute the request asynchronously.

  • _preload_content (bool, optional) – if False, the ApiResponse.data will be set to none and raw_data will store the HTTP response body without reading/decoding. Default is True.

  • _return_http_data_only (bool, optional) – response data instead of ApiResponse object with status code, headers, etc

  • _request_timeout – timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts.

  • _request_auth (dict, optional) – set to override the auth_settings for an a single request; this effectively ignores the authentication in the spec for a single request.

Returns:

Returns the result object. If the method is called asynchronously, returns the request thread.

Return type:

tuple(UpsertTransactionPropertiesResponse, status_code(int), headers(HTTPHeaderDict))

upsert_transactions(scope, code, transaction_request, preserve_properties=None, async_req=None, **kwargs)[source]

UpsertTransactions: Upsert transactions # noqa: E501

Create or update transactions in the transaction portfolio. A transaction will be updated if it already exists and created if it does not. The maximum number of transactions that this method can upsert per request is 10,000. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True

>>> thread = api.upsert_transactions(scope, code, transaction_request, preserve_properties, async_req=True)
>>> result = thread.get()
Parameters:
  • scope (str) – The scope of the transaction portfolio. (required)

  • code (str) – The code of the transaction portfolio. Together with the scope this uniquely identifies the transaction portfolio. (required)

  • transaction_request (List[TransactionRequest]) – A list of transactions to be created or updated. (required)

  • preserve_properties (bool) – If set to false, the entire property set will be overwritten by the provided properties. If not specified or set to true, only the properties provided will be updated.

  • async_req (bool, optional) – Whether to execute the request asynchronously.

  • _request_timeout – timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts.

Returns:

Returns the result object. If the method is called asynchronously, returns the request thread.

Return type:

UpsertPortfolioTransactionsResponse

upsert_transactions_with_http_info(scope, code, transaction_request, preserve_properties=None, **kwargs)[source]

UpsertTransactions: Upsert transactions # noqa: E501

Create or update transactions in the transaction portfolio. A transaction will be updated if it already exists and created if it does not. The maximum number of transactions that this method can upsert per request is 10,000. # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True

>>> thread = api.upsert_transactions_with_http_info(scope, code, transaction_request, preserve_properties, async_req=True)
>>> result = thread.get()
Parameters:
  • scope (str) – The scope of the transaction portfolio. (required)

  • code (str) – The code of the transaction portfolio. Together with the scope this uniquely identifies the transaction portfolio. (required)

  • transaction_request (List[TransactionRequest]) – A list of transactions to be created or updated. (required)

  • preserve_properties (bool) – If set to false, the entire property set will be overwritten by the provided properties. If not specified or set to true, only the properties provided will be updated.

  • async_req (bool, optional) – Whether to execute the request asynchronously.

  • _preload_content (bool, optional) – if False, the ApiResponse.data will be set to none and raw_data will store the HTTP response body without reading/decoding. Default is True.

  • _return_http_data_only (bool, optional) – response data instead of ApiResponse object with status code, headers, etc

  • _request_timeout – timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts.

  • _request_auth (dict, optional) – set to override the auth_settings for an a single request; this effectively ignores the authentication in the spec for a single request.

Returns:

Returns the result object. If the method is called asynchronously, returns the request thread.

Return type:

tuple(UpsertPortfolioTransactionsResponse, status_code(int), headers(HTTPHeaderDict))