Read Live Algorithm

Live Algorithm Statistics

Introduction

If a ReadLiveAlgorithmRequest is provided details on a live algorithm are returned. If a ListLiveAlgorithmsRequest is passed get a list of live running algorithms.

Request

Dynamic arguement to specify whether seeking single project or list response. The /live/read API accepts requests in the following format:

ReadLiveAlgorithmRequest Model - Request to read out a single algorithm.
projectId integer
Id of the project to read.
deployId string
Specific instance Id to read.
Example
{
  "projectId": 0,
  "deployId": "string"
}

Responses

The /live/read API provides a response in the following format:

200 Success

LiveAlgorithmResults Model - Details a live algorithm from the live/read API endpoint.
message string
Error message.
status string
Indicates the status of the algorihtm, i.e. 'Running', 'Stopped'.
deployId string
Algorithm deployment ID.
cloneId int
The snapshot project ID for cloning the live development's source code.
launched string
Date the live algorithm was launched.
stopped string
Date the live algorithm was stopped.
brokerage string
Brokerage used in the live algorithm.
securityTypes string
Security types present in the live algorithm.
projectName string
Name of the project the live algorithm is in.
dataCenter string
Name of the data center where the algorithm is physically located.
public bool
Indicates if the algorithm is being live shared.
files ProjectFile Array
Files present in the project in which the algorithm is.
runtimeStatistics RuntimeStatistics object
Runtime banner/updating statistics in the title banner of the live algorithm GUI. It can be empty if the algorithm is not running.
charts ChartSummary object
Chart updates for the live algorithm since the last result packet.
success boolean
Indicate if the API request was successful.
errors string Array
List of errors with the API call.
Example
{
  "message": "string",
  "status": "string",
  "deployId": "string",
  "cloneId": ,
  "launched": "string",
  "stopped": "string",
  "brokerage": "string",
  "securityTypes": "string",
  "projectName": "string",
  "dataCenter": "string",
  "public": ,
  "files": [
    {
      "id": ,
      "projectId": ,
      "name": "string",
      "content": "string",
      "modified": "2021-11-26T15:18:27.693Z",
      "open": true,
      "isLibrary": true
    }
  ],
  "runtimeStatistics": {
    "Equity": "$100.00",
    "Fees": "-$100.00",
    "Holdings": "$100.00",
    "Net Profit": "$100.00",
    "Probabilistic Sharpe Ratio": "50.00%",
    "Return": "50.00%",
    "Unrealized": "$100.00",
    "Volume": "$100.00"
  },
  "charts": {
    "name": "string"
  },
  "success": true,
  "errors": [
    "string"
  ]
}
ProjectFile Model - File for a project.
id int
ID of the project file. This can also be null.
projectId int
ID of the project.
name string
Name of a project file.
content string
Contents of the project file.
modified string($date-time)
DateTime project file was modified.
open boolean
Indicates if the project file is open or not.
isLibrary boolean
Indicates if the project file is a library or not. It's always false in live/read and backtest/read.
Example
{
  "id": ,
  "projectId": ,
  "name": "string",
  "content": "string",
  "modified": "2021-11-26T15:18:27.693Z",
  "open": true,
  "isLibrary": true
}
RuntimeStatistics Model
Equity string
example: $100.00

Total portfolio value.
Fees string
example: -$100.00

Transaction fee.
Holdings string
example: $100.00

Equity value of security holdings.
Net Profit string
example: $100.00

Net profit.
Probabilistic Sharpe Ratio string
example: 50.00%

Probabilistic Sharpe Ratio.
Return string
example: 50.00%

Return.
Unrealized string
example: $100.00

Unrealized profit/loss.
Volume string
example: $100.00

Total transaction volume.
Example
{
  "Equity": "$100.00",
  "Fees": "-$100.00",
  "Holdings": "$100.00",
  "Net Profit": "$100.00",
  "Probabilistic Sharpe Ratio": "50.00%",
  "Return": "50.00%",
  "Unrealized": "$100.00",
  "Volume": "$100.00"
}
ChartSummary Model - Contains the names of all charts
name string
Name of the Chart.
Example
{
  "name": "string"
}

401 Authentication Error

UnauthorizedError Model - Unauthorized response from the API. Key is missing, invalid, or timestamp is too old for hash.
www_authenticate string
Header

You can also see our Videos. You can also get in touch with us via Discord.

Did you find this page helpful?

Contribute to the documentation: