Skip to content

LiveAlgorithmApiSettingsWrapper

QuantConnect.Api.LiveAlgorithmApiSettingsWrapper

LiveAlgorithmApiSettingsWrapper(
    project_id: int,
    compile_id: str,
    node_id: str,
    settings: Dictionary[str, Object],
    version: str = "-1",
    data_providers: Dictionary[str, Object] = None,
    parameters: Dictionary[str, str] = None,
    notification: Dictionary[str, List[str]] = None,
)

Bases: Object

Helper class to put BaseLiveAlgorithmSettings in proper format.

Constructor for LiveAlgorithmApiSettingsWrapper

Parameters:

Name Type Description Default
project_id int

Id of project from QuantConnect

required
compile_id str

Id of compilation of project from QuantConnect

required
node_id str

Server type to run live Algorithm

required
settings Dictionary[str, Object]

Dictionary with brokerage specific settings. Each brokerage requires certain specific credentials in order to process the given orders. Each key in this dictionary represents a required field/credential to provide to the brokerage API and its value represents the value of that field. For example: "brokerageSettings: { "id": "Binance", "binance-api-secret": "123ABC", "binance-api-key": "ABC123"}. It is worth saying, that this dictionary must always contain an entry whose key is "id" and its value is the name of the brokerage (see Brokerages.BrokerageName)

required
version str

The version identifier

'-1'
data_providers Dictionary[str, Object]

Dictionary with data providers credentials. Each data provider requires certain credentials in order to retrieve data from their API. Each key in this dictionary describes a data provider name and its corresponding value is another dictionary with the required key-value pairs of credential names and values. For example: "data_providers: {InteractiveBrokersBrokerage : { "id": 12345, "environement" : "paper", "username": "testUsername", "password": "testPassword"}}"

None
parameters Dictionary[str, str]

Dictionary to specify the parameters for the live algorithm

None
notification Dictionary[str, List[str]]

Dictionary with the lists of events and targets

None

version_id

version_id: str

-1 is master

project_id

project_id: int

Project id for the live instance

compile_id

compile_id: str

Compile Id for the live algorithm

node_id

node_id: str

Id of the node being used to run live algorithm

signature

signature: str

Signature of the live algorithm

automatic_redeploy

automatic_redeploy: bool

True to enable Automatic Re-Deploy of the live algorithm, false otherwise

brokerage

brokerage: Dictionary[str, Object]

The API expects the settings as part of a brokerage object

data_providers

data_providers: Dictionary[str, Object]

Dictionary with the data providers and their corresponding credentials

parameters

parameters: Dictionary[str, str]

Dictionary with the parameters to be used in the live algorithm

notification

notification: Dictionary[str, List[str]]

Dictionary with the lists of events and targets