Merge pull request #2770 from PLuv/portfolio-management

Portfolio management
This commit is contained in:
Luis Fernando Molina authored and GitHub committed 2021-11-29 05:11:44 -04:00
commit f916a40ebb
293 files changed
+86008 -20729

No files matched your search

+1 -1
View File
@@ -27,7 +27,7 @@ jobs:
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
tag_name: ${{ steps.vars.outputs.tag }}.${{ steps.date.outputs.date }}
tag_name: ${{ steps.vars.outputs.tag }}-${{ steps.date.outputs.date }}
release_name: Superalgos-Beta-v${{ steps.vars.outputs.tag }} Snapshot ${{ steps.date.outputs.date }}
keep_num: 5
keep_tags: false
+1 -1
View File
@@ -64,7 +64,7 @@ exports.newDesktopRoot = function newDesktopRoot() {
}
for (let i = 0; i < SA.secrets.array.length; i++) {
let secret = SA.secrets.array[i]
SA.secrets.map.set (secret.signingAccountChildCodeName, secret)
SA.secrets.map.set (secret.nodeCodeName, secret)
}
run()
+1 -1
View File
@@ -3,7 +3,7 @@ WORKDIR /app
COPY . .
RUN apk add --no-cache --virtual .build-deps make g++ \
&& apk add --no-cache python3 \
&& if [ "$(uname -m)" = "x86_64" ]; then node setup noShortcuts tensorflow; else node setup noShortcuts; fi \
&& npm ci \
&& mkdir -p ./Platform/My-Data-Storage ./Platform/My-Log-Files ./Platform/My-Workspaces \
&& addgroup superalgos \
&& adduser --disabled-password --no-create-home --ingroup superalgos superalgos \
+1
View File
@@ -28,6 +28,7 @@ exports.newEnvironment = function () {
PATH_TO_DESKTOP: './Desktop',
PATH_TO_DEFAULT_WORKSPACE: path.join(basePath, './Projects/Foundations/Plugins/Workspaces'),
PATH_TO_MY_WORKSPACES: path.join(basePath, './Platform/My-Workspaces'),
PATH_TO_SECRETS: path.join(basePath, './My-Secrets'),
PATH_TO_FONTS: path.join(basePath, './Platform/WebServer/Fonts'),
DESKTOP_APP_SIGNING_ACCOUNT: 'Social-Trading-Desktop-App-1',
DESKTOP_APP_MAX_OUTGOING_PEERS: 1,
+14 -14
View File
@@ -1,7 +1,7 @@
const path = require("path");
const fs = require("fs");
const { exec, execSync } = require("child_process");
const os = require("os");
const os = require("os");
// Get the name of the main directory
let cwd = __dirname;
@@ -21,7 +21,7 @@ if (os.platform() == "win32") {
// Place Shortcuts using powershell
for (let dir of shortcutPaths) {
let command = `$ws = New-Object -ComObject WScript.Shell; $s = $ws.CreateShortcut("${dir}"); $S.TargetPath = "${target}"; $S.IconLocation = "${icon}"; $S.Save()`;
exec( command,
{
shell: "powershell.exe",
@@ -52,12 +52,12 @@ if (os.platform() == "win32") {
let icon = path.join( __dirname,"..", "/Projects/Foundations/Icons/superalgos.png");
// Create .desktop shortcut file
fs.writeFileSync( `${name}.desktop`,
fs.writeFileSync( `${name}.desktop`,
`[Desktop Entry]
Type=Application
Encoding=UTF-8
Name=${name}
Comment=Launch Shortcut for Superalgos
Comment=Launch Shortcut for Superalgos
Path=${__dirname}
Exec=gnome-terminal -e ${__dirname}/launch-linux-mac.sh
Terminal=true
@@ -87,20 +87,20 @@ if (os.platform() == "win32") {
});
} else {
console.log( "Automatic shortcut creation is not yet supported on your flavor of linux. If you would like to see this feature add, message @harrellbm on telegram or discord to ask how you can help!")
console.log( "Automatic shortcut creation is not yet supported on your flavor of linux. If you would like to see this feature add, message @harrellbm on telegram or discord to ask how you can help!")
}
// Mac Shortcuts
} else if (os.platform() == "darwin") {
const icon = path.join( __dirname,"/superalgos.ico");
const createShortcutCommand = `chmod +x ${name}.command & cp ${name}.command ~/Desktop/${name}.command`
const installFileIconcommand = `npm install fileicon`;
const installFileIconcommand = `npm install -g fileicon`;
const changeIconCommand = `./node_modules/fileicon/bin/fileicon set ~/Desktop/${name}.command ./Launch-Scripts/superalgos.ico`
const unInstallFileIconcommand = `npm uninstall fileicon`;
const unInstallFileIconcommand = `npm uninstall -g fileicon`;
try {
// Create .desktop shortcut file
fs.writeFileSync( `${name}.command`,
fs.writeFileSync( `${name}.command`,
`#!/bin/sh
cd ${__dirname}
cd ..
@@ -113,14 +113,14 @@ if (os.platform() == "win32") {
// Remove temporary .command file
fs.unlinkSync( `${name}.command` )
//Install fileicon utility
//Install fileicon utility
execSync(installFileIconcommand, {stdio: 'inherit', timeout: 30000});
//change Icon
execSync(changeIconCommand, {stdio: 'inherit', timeout: 30000});
//Un-Install fileicon utility
//Un-Install fileicon utility
execSync(unInstallFileIconcommand, {stdio: 'inherit', timeout: 30000});
} catch (error) {
console.log('');
@@ -135,4 +135,4 @@ if (os.platform() == "win32") {
// Misc Operating System
} else {
console.log("Automatic shortcut creation is not currently supported on your operating system. If you would like to see your operating system added please reachout on discord or telegram to let the devs know.")
}
}
+1 -1
View File
@@ -62,7 +62,7 @@ exports.newNetworkRoot = function newNetworkRoot() {
}
for (let i = 0; i < SA.secrets.array.length; i++) {
let secret = SA.secrets.array[i]
SA.secrets.map.set(secret.signingAccountChildCodeName, secret)
SA.secrets.map.set(secret.nodeCodeName, secret)
}
NT.app = require('./Network/NetwokNode.js').newNetworkNode()
+17
View File
@@ -0,0 +1,17 @@
{
// Use IntelliSense to learn about possible attributes.
// Hover to view descriptions of existing attributes.
// For more information, visit: https://go.microsoft.com/fwlink/?linkid=830387
"version": "0.2.0",
"configurations": [
{
"type": "node",
"request": "launch",
"name": "Launch Program",
"skipFiles": [
"<node_internals>/**"
],
"program": "${workspaceFolder}\\..\\PlatformRoot.js"
}
]
}
+26
View File
@@ -0,0 +1,26 @@
{
"files.exclude": {
"**/Data-Storage": true,
"**/Log-Files": true,
"**/node_modules": true,
"**/My-Social-Trading-Data": true,
"**/My-Network-Nodes-Data": true,
"**/My-Workspaces": true,
"**/My-Secrets": true,
"**/My-Data-Storage": true,
"**/My-Log-Files": true,
},
"search.exclude": {
"**/Data-Storage": true,
"**/Log-Files": true,
"**/node_modules": true,
"**/My-Social-Trading-Data": true,
"**/My-Network-Nodes-Data": true,
"**/My-Workspaces": true,
"**/My-Secrets": true,
"**/My-Data-Storage": true,
"**/My-Log-Files": true,
},
"search.maintainFileSearchCache": true,
"editor.mouseWheelZoom": true
}
+46
View File
@@ -4,6 +4,7 @@ exports.newGithubServer = function newGithubServer() {
getGithubStars: getGithubStars,
getGithubWatchers: getGithubWatchers,
getGithubForks: getGithubForks,
createGithubFork: createGithubFork,
mergePullRequests: mergePullRequests,
initialize: initialize,
finalize: finalize,
@@ -162,6 +163,46 @@ exports.newGithubServer = function newGithubServer() {
}
}
async function createGithubFork(token) {
try {
token = unescape(token)
await doGithub()
async function doGithub() {
try {
const { Octokit } = SA.nodeModules.octokit
const octokit = new Octokit({
auth: token,
userAgent: 'Superalgos ' + SA.version
})
await octokit.repos.createFork({
owner: 'Superalgos',
repo: 'Superalgos'
})
} catch (err) {
if (err === undefined) { return }
console.log('[ERROR] Github Server -> createGithubFork -> doGithub -> err.stack = ' + err.stack)
}
}
} catch (err) {
console.log('[ERROR] Github Server -> createGithubFork -> Method call produced an error.')
console.log('[ERROR] Github Server -> createGithubFork -> err.stack = ' + err.stack)
console.log('[ERROR] Github Server -> createGithubFork -> repository = ' + repository)
console.log('[ERROR] Github Server -> createGithubFork -> username = ' + username)
console.log('[ERROR] Github Server -> createGithubFork -> token starts with = ' + token.substring(0, 10) + '...')
console.log('[ERROR] Github Server -> createGithubFork -> token ends with = ' + '...' + token.substring(token.length - 10))
let error = {
result: 'Fail Because',
message: err.message,
stack: err.stack
}
return error
}
}
async function mergeGithubPullRequests(commitMessage, username, token) {
try {
commitMessage = unescape(commitMessage)
@@ -323,6 +364,11 @@ exports.newGithubServer = function newGithubServer() {
if (await validateUserProfileBlockchainAccountDoesNotBelongtoAnotherUserProfile() === false) { continue }
if (await validateUserProfileSigningAccountsDoesNotBelongtoAnotherUserProfile() === false) { continue }
/*
TODO: We need to check before merging a User Profile that none of id of the node of the profile hierearchy exists at any other
User Profile already at the repository, to avoid atacts of users highjacking references of other user profiles.
*/
if (await mergePullRequest() === false) {
console.log('[WARN] Github Server -> mergeGithubPullRequests -> Merge Failed -> Pull Request "' + pullRequest.title + '" not merged because Github could not merge it. -> mergeResponse.message = ' + mergeResponse.data.message)
} else {
+200 -136
View File
@@ -139,7 +139,7 @@ exports.newHttpInterface = function newHttpInterface() {
return
}
default: {
SA.projects.foundations.utilities.httpResponses.respondWithContent(JSON.stringify({error: 'Method ' + params.method + ' is invalid.'}), httpResponse)
SA.projects.foundations.utilities.httpResponses.respondWithContent(JSON.stringify({ error: 'Method ' + params.method + ' is invalid.' }), httpResponse)
}
}
} catch (err) {
@@ -325,6 +325,42 @@ exports.newHttpInterface = function newHttpInterface() {
}
}
break
case 'Secrets': {
switch (requestPath[2]) { // switch by command
case 'Save-Secrets-File': {
SA.projects.foundations.utilities.httpRequests.getRequestBody(httpRequest, httpResponse, processRequest)
async function processRequest(body) {
try {
let filePath = global.env.PATH_TO_SECRETS + '/'
let fileName = "Secrets.json"
createNewDir(filePath)
SA.nodeModules.fs.writeFileSync(filePath + '/' + fileName, body)
console.log('[SUCCESS] ' + filePath + '/' + fileName + ' created.')
SA.projects.foundations.utilities.httpResponses.respondWithContent(JSON.stringify(global.DEFAULT_OK_RESPONSE), httpResponse)
} catch (err) {
console.log('[ERROR] httpInterface -> Secrets -> Save-Secrets-File -> Method call produced an error.')
console.log('[ERROR] httpInterface -> Secrets -> Save-Secrets-File -> err.stack = ' + err.stack)
console.log('[ERROR] httpInterface -> Secrets -> Save-Secrets-File -> Params Received = ' + body)
let error = {
result: 'Fail Because',
message: err.message,
stack: err.stack
}
SA.projects.foundations.utilities.httpResponses.respondWithContent(JSON.stringify(error), httpResponse)
}
}
break
}
}
}
break
case 'Docs': {
switch (requestPath[2]) { // switch by command
case 'Save-Node-Schema': {
@@ -633,16 +669,6 @@ exports.newHttpInterface = function newHttpInterface() {
}
}
}
function createNewDir(path) {
try {
fs.mkdirSync(path, {recursive: true})
} catch (err) {
if (err.message.indexOf('file already exists') < 0) {
throw (err)
}
}
}
}
return noErrorsDuringSaving
@@ -697,7 +723,7 @@ exports.newHttpInterface = function newHttpInterface() {
contribute()
async function contribute() {
const {lookpath} = SA.nodeModules.lookpath
const { lookpath } = SA.nodeModules.lookpath
const gitpath = await lookpath('git')
if (gitpath === undefined) {
console.log('[ERROR] `git` not installed.')
@@ -768,7 +794,7 @@ exports.newHttpInterface = function newHttpInterface() {
async function doGithub() {
const {Octokit} = SA.nodeModules.octokit
const { Octokit } = SA.nodeModules.octokit
const octokit = new Octokit({
auth: token,
@@ -832,7 +858,7 @@ exports.newHttpInterface = function newHttpInterface() {
update()
async function update() {
const {lookpath} = SA.nodeModules.lookpath
const { lookpath } = SA.nodeModules.lookpath
const gitpath = await lookpath('git');
if (gitpath === undefined) {
console.log('[ERROR] `git` not installed.')
@@ -873,11 +899,11 @@ exports.newHttpInterface = function newHttpInterface() {
let message
try {
message = await git.pull('https://github.com/Superalgos/Superalgos', currentBranch)
return {message: message}
return { message: message }
} catch (err) {
console.log('[ERROR] Error updating ' + currentBranch)
console.log(err.stack)
return {error: err}
return { error: err }
}
}
@@ -903,7 +929,7 @@ exports.newHttpInterface = function newHttpInterface() {
checkout()
async function checkout() {
const {lookpath} = SA.nodeModules.lookpath
const { lookpath } = SA.nodeModules.lookpath
const gitpath = await lookpath('git');
if (gitpath === undefined) {
console.log('[ERROR] `git` not installed.')
@@ -1001,7 +1027,7 @@ exports.newHttpInterface = function newHttpInterface() {
branch()
async function branch() {
const {lookpath} = SA.nodeModules.lookpath
const { lookpath } = SA.nodeModules.lookpath
const gitpath = await lookpath('git');
if (gitpath === undefined) {
console.log('[ERROR] `git` not installed.')
@@ -1135,7 +1161,7 @@ exports.newHttpInterface = function newHttpInterface() {
try {
console.log('fixSchemas...' + allAppSchemas.length)
let projects = SA.projects.foundations.utilities.filesAndDirectories.getDirectories(global.env.PATH_TO_PROJECTS)
const fs = SA.nodeModules.fs
//const fs = SA.nodeModules.fs
let needFixing = 0
for (let i = 0; i < allAppSchemas.length; i++) {
let schemaDocument = allAppSchemas[i]
@@ -1183,13 +1209,13 @@ exports.newHttpInterface = function newHttpInterface() {
}
}
if (wasUpdated === true) {
let fileContent = JSON.stringify(schemaDocument, undefined, 4)
let filePath = allAppSchemasFilePaths[i]
//if (wasUpdated === true) {
//let fileContent = JSON.stringify(schemaDocument, undefined, 4)
//let filePath = allAppSchemasFilePaths[i]
//console.log('Saving File at ' + filePath)
//console.log(fileContent)
//fs.writeFileSync(filePath, fileContent)
}
//}
}
} catch (err) {
console.log(err.stack)
@@ -1286,6 +1312,15 @@ exports.newHttpInterface = function newHttpInterface() {
SA.projects.foundations.utilities.httpResponses.respondWithContent(JSON.stringify(serverResponse), httpResponse)
return
}
case 'createGithubFork': {
let serverResponse = await PL.servers.GITHUB_SERVER.createGithubFork(
params.token
)
SA.projects.foundations.utilities.httpResponses.respondWithContent(JSON.stringify(serverResponse), httpResponse)
return
}
case 'mergePullRequests': {
let serverResponse = await PL.servers.GITHUB_SERVER.mergePullRequests(
@@ -1318,8 +1353,21 @@ exports.newHttpInterface = function newHttpInterface() {
let error
await checkFork()
await updateUser()
async function checkFork() {
let serverResponse = await PL.servers.GITHUB_SERVER.createGithubFork(
params.token
)
SA.projects.foundations.utilities.httpResponses.respondWithContent(JSON.stringify(serverResponse), httpResponse)
if(error != undefined) {
console.log('[ERROR] httpInterface -> Gov -> createFork -> You already have a fork. Good for you!')
}
}
async function updateUser() {
await doGithubUser()
@@ -1343,7 +1391,7 @@ exports.newHttpInterface = function newHttpInterface() {
async function doGithubUser() {
const {Octokit} = SA.nodeModules.octokit
const { Octokit } = SA.nodeModules.octokit
const octokit = new Octokit({
auth: token,
@@ -1353,8 +1401,14 @@ exports.newHttpInterface = function newHttpInterface() {
const repo = 'Superalgos'
const owner = 'Superalgos'
const head = username + ':' + contributionsBranch
const base = currentBranch
const title = 'Contribution: ' + mess
//const base = currentBranch
let base = undefined
if (process.env.SA_MODE === 'gitDisable') {
base = 'develop'
} else {
base = currentBranch
}
const title = 'Governance: ' + mess
const path = 'Projects/Governance/Plugins/User-Profiles/' + username + '.json';
const sha = await getSHA(path);
@@ -1429,11 +1483,11 @@ exports.newHttpInterface = function newHttpInterface() {
async function getSHA(path) {
let sha = ''
const {graphql} = SA.nodeModules.graphql
const { graphql } = SA.nodeModules.graphql
try {
const {repository} = await graphql(
const { repository } = await graphql(
'{ ' +
' repository(name: "SuperAlgos", owner: "' + username + '") {' +
' object(expression: "develop:' + path + '") {' +
@@ -1518,7 +1572,7 @@ exports.newHttpInterface = function newHttpInterface() {
return
}
default: {
SA.projects.foundations.utilities.httpResponses.respondWithContent(JSON.stringify({error: 'Method ' + params.method + ' is invalid.'}), httpResponse)
SA.projects.foundations.utilities.httpResponses.respondWithContent(JSON.stringify({ error: 'Method ' + params.method + ' is invalid.' }), httpResponse)
}
}
} catch (err) {
@@ -1549,132 +1603,132 @@ exports.newHttpInterface = function newHttpInterface() {
}
break
case 'Images': // This means the Images folder.
{
let path = global.env.PATH_TO_PLATFORM + '/WebServer/Images/' + requestPath[2]
{
let path = global.env.PATH_TO_PLATFORM + '/WebServer/Images/' + requestPath[2]
if (requestPath[3] !== undefined) {
path = path + '/' + requestPath[3]
if (requestPath[3] !== undefined) {
path = path + '/' + requestPath[3]
}
if (requestPath[4] !== undefined) {
path = path + '/' + requestPath[4]
}
if (requestPath[5] !== undefined) {
path = path + '/' + requestPath[5]
}
path = unescape(path)
SA.projects.foundations.utilities.httpResponses.respondWithImage(path, httpResponse)
}
if (requestPath[4] !== undefined) {
path = path + '/' + requestPath[4]
}
if (requestPath[5] !== undefined) {
path = path + '/' + requestPath[5]
}
path = unescape(path)
SA.projects.foundations.utilities.httpResponses.respondWithImage(path, httpResponse)
}
break
case 'Icons': // This means the Icons folder under Projects.
{
let path = global.env.PATH_TO_PROJECTS + '/' + requestPath[2] + '/Icons'
{
let path = global.env.PATH_TO_PROJECTS + '/' + requestPath[2] + '/Icons'
if (requestPath[3] !== undefined) {
path = path + '/' + requestPath[3]
if (requestPath[3] !== undefined) {
path = path + '/' + requestPath[3]
}
if (requestPath[4] !== undefined) {
path = path + '/' + requestPath[4]
}
if (requestPath[5] !== undefined) {
path = path + '/' + requestPath[5]
}
path = unescape(path)
SA.projects.foundations.utilities.httpResponses.respondWithImage(path, httpResponse)
}
if (requestPath[4] !== undefined) {
path = path + '/' + requestPath[4]
}
if (requestPath[5] !== undefined) {
path = path + '/' + requestPath[5]
}
path = unescape(path)
SA.projects.foundations.utilities.httpResponses.respondWithImage(path, httpResponse)
}
break
case 'GIFs': // This means the GIFs folder under Projects.
{
let path = global.env.PATH_TO_PROJECTS + '/' + requestPath[2] + '/GIFs'
{
let path = global.env.PATH_TO_PROJECTS + '/' + requestPath[2] + '/GIFs'
if (requestPath[3] !== undefined) {
path = path + '/' + requestPath[3]
if (requestPath[3] !== undefined) {
path = path + '/' + requestPath[3]
}
if (requestPath[4] !== undefined) {
path = path + '/' + requestPath[4]
}
if (requestPath[5] !== undefined) {
path = path + '/' + requestPath[5]
}
path = unescape(path)
SA.projects.foundations.utilities.httpResponses.respondWithImage(path, httpResponse)
}
if (requestPath[4] !== undefined) {
path = path + '/' + requestPath[4]
}
if (requestPath[5] !== undefined) {
path = path + '/' + requestPath[5]
}
path = unescape(path)
SA.projects.foundations.utilities.httpResponses.respondWithImage(path, httpResponse)
}
break
case 'PNGs': // This means the PNGs folder under Projects.
{
let path = global.env.PATH_TO_PROJECTS + '/' + requestPath[2] + '/PNGs'
{
let path = global.env.PATH_TO_PROJECTS + '/' + requestPath[2] + '/PNGs'
if (requestPath[3] !== undefined) {
path = path + '/' + requestPath[3]
if (requestPath[3] !== undefined) {
path = path + '/' + requestPath[3]
}
if (requestPath[4] !== undefined) {
path = path + '/' + requestPath[4]
}
if (requestPath[5] !== undefined) {
path = path + '/' + requestPath[5]
}
path = unescape(path)
SA.projects.foundations.utilities.httpResponses.respondWithImage(path, httpResponse)
}
if (requestPath[4] !== undefined) {
path = path + '/' + requestPath[4]
}
if (requestPath[5] !== undefined) {
path = path + '/' + requestPath[5]
}
path = unescape(path)
SA.projects.foundations.utilities.httpResponses.respondWithImage(path, httpResponse)
}
break
case 'WebServer': // This means the WebServer folder.
{
SA.projects.foundations.utilities.httpResponses.respondWithFile(global.env.PATH_TO_PLATFORM + '/WebServer/' + requestPath[2], httpResponse)
}
{
SA.projects.foundations.utilities.httpResponses.respondWithFile(global.env.PATH_TO_PLATFORM + '/WebServer/' + requestPath[2], httpResponse)
}
break
case 'externalScripts': // This means the WebServer folder.
{
// This allows to have sub-folders in externalScripts
let fullPath = ''
for (let i = 2; i < requestPath.length; i++) {
fullPath += requestPath[i]
if (i !== requestPath.length - 1) {
fullPath += '/'
{
// This allows to have sub-folders in externalScripts
let fullPath = ''
for (let i = 2; i < requestPath.length; i++) {
fullPath += requestPath[i]
if (i !== requestPath.length - 1) {
fullPath += '/'
}
}
/**
* Sometimes libs will call fonts/images etc. by themselves thus we should have a filter for file type to respond with the correct content and headers, but from the externalScripts folder
* This code should be improved when needed with specific file types
*/
let requestedFileExtension = requestPath[requestPath.length - 1].split('.').pop()
switch (requestedFileExtension) {
case 'otf':
case 'ttf':
case 'eot':
case 'woff':
case 'woff2':
SA.projects.foundations.utilities.httpResponses.respondWithFont(global.env.PATH_TO_PLATFORM + '/WebServer/externalScripts/' + fullPath, httpResponse)
break
default:
SA.projects.foundations.utilities.httpResponses.respondWithFile(global.env.PATH_TO_PLATFORM + '/WebServer/externalScripts/' + fullPath, httpResponse)
}
}
/**
* Sometimes libs will call fonts/images etc. by themselves thus we should have a filter for file type to respond with the correct content and headers, but from the externalScripts folder
* This code should be improved when needed with specific file types
*/
let requestedFileExtension = requestPath[requestPath.length - 1].split('.').pop()
switch (requestedFileExtension) {
case 'otf':
case 'ttf':
case 'eot':
case 'woff':
case 'woff2':
SA.projects.foundations.utilities.httpResponses.respondWithFont(global.env.PATH_TO_PLATFORM + '/WebServer/externalScripts/' + fullPath, httpResponse)
break
default:
SA.projects.foundations.utilities.httpResponses.respondWithFile(global.env.PATH_TO_PLATFORM + '/WebServer/externalScripts/' + fullPath, httpResponse)
}
}
break
case 'Plotters': // This means the plotter folder, not to be confused with the Plotters script!
{
let project = requestPath[2]
let dataMine = requestPath[3]
let codeName = requestPath[4]
let moduleName = requestPath[5]
let filePath = global.env.PATH_TO_PROJECTS + '/' + project + '/' + 'Bots-Plotters-Code' + '/' + dataMine + '/plotters/' + codeName + '/' + moduleName
SA.projects.foundations.utilities.httpResponses.respondWithFile(filePath, httpResponse)
}
{
let project = requestPath[2]
let dataMine = requestPath[3]
let codeName = requestPath[4]
let moduleName = requestPath[5]
let filePath = global.env.PATH_TO_PROJECTS + '/' + project + '/' + 'Bots-Plotters-Code' + '/' + dataMine + '/plotters/' + codeName + '/' + moduleName
SA.projects.foundations.utilities.httpResponses.respondWithFile(filePath, httpResponse)
}
break
case 'ChartLayers': {
SA.projects.foundations.utilities.httpResponses.respondWithFile(global.env.PATH_TO_PLATFORM + '/UI/' + endpointOrFile + '/' + requestPath[2], httpResponse)
@@ -1872,8 +1926,8 @@ exports.newHttpInterface = function newHttpInterface() {
fileName
)
.then(response => {
SA.projects.foundations.utilities.httpResponses.respondWithContent(response, httpResponse)
}
SA.projects.foundations.utilities.httpResponses.respondWithContent(response, httpResponse)
}
)
.catch(err => {
let error = {
@@ -2053,7 +2107,7 @@ exports.newHttpInterface = function newHttpInterface() {
/* Create Dir if it does not exist */
if (!fs.existsSync(dir)) {
fs.mkdirSync(dir, {recursive: true});
fs.mkdirSync(dir, { recursive: true });
}
fs.writeFile(filePath, fileContent, onFileWritten)
@@ -2197,4 +2251,14 @@ exports.newHttpInterface = function newHttpInterface() {
}
}
}
function createNewDir(path) {
try {
SA.nodeModules.fs.mkdirSync(path, { recursive: true })
} catch (err) {
if (err.message.indexOf('file already exists') < 0) {
throw (err)
}
}
}
}
Binary file not shown.

After

Width:  |  Height:  |  Size: 9.7 KiB

+17 -1
View File
@@ -42,6 +42,15 @@
try {
drawSplashText()
loadSuperalgos()
window.api.receive('fromMaster', (data) => {
if(data.newUser){
UI.projects.foundations.spaces.designSpace.workspace.replaceWorkspaceByLoadingOne(data.newUser[0], data.newUser[1])
}else if(data.submit){
UI.projects.governance.spaces.reportsSpace.commandInterface.command = data.submit[0]
UI.projects.governance.spaces.reportsSpace.commandInterface.detectCommands()
//const element = document.getElementsByClassName("governance-filter-input")[0]
}
})
} catch (err) {
console.log("[ERROR] UI can not be started. Please check that WebServer is running.", err);
}
@@ -66,6 +75,13 @@
function drawSplashText() {
const splashTextArray = [
{
"splashTextLine1Html": '<span class="credits-red">Every month, 10M SA tokens, with a market value of more than 500,000 USD are distributed between everyone contributing to the project during that month. </span>'
,
"splashTextLine2Html": 'In October 2021 we counted around 50 contributors, with an average mining reward of 10,000 USD for each one. Contributing to Superalgos now is like mining Bitcoin in 2010 where there were no more than 50 people mining it. Ask the community moderators how to join a team an participate in the next distribution.'
,
"splashTextLine3Html": ''
} /*,
{
"splashTextLine1Html": '<span class="credits-red">Superalgos is open source, forever free for everyone, and is constantly improving thanks to the involvement of contributors!</span>'
,
@@ -107,7 +123,7 @@
"splashTextLine2Html": 'Look around, find something that is missing and start coding! If you need help, ask in the chat groups to find a mentor!'
,
"splashTextLine3Html": 'Follow our motto: Just code it!'
}
} */
]
let arrayIndex = Math.trunc(Math.random() * splashTextArray.length)
File diff suppressed because it is too large. Load diff
@@ -17,7 +17,7 @@
"situations": [
{
"type": "Situation",
"name": "EMA crossover",
"name": "Crossover",
"project": "Foundations",
"conditions": [
{
@@ -27,17 +27,17 @@
"javascriptCode": {
"type": "Javascript Code",
"name": "New Javascript Code",
"code": "chart.at01hs.EMA.previous.ema1 < chart.at01hs.EMA.previous.ema2",
"code": "chart.at01hs.EMA.ema1 > chart.at01hs.EMA.ema2 && chart.at01hs.EMA.previous.ema1 < chart.at01hs.EMA.previous.ema2",
"project": "Foundations",
"id": "c4e9205d-5729-4c06-92ab-6c48ca195f9b",
"id": "eac8aa9b-2ead-4376-8ea2-aaf1a276c568",
"savedPayload": {
"position": {
"x": 29767.05237465183,
"y": 30529.07127139445
"x": 30145.01097090622,
"y": 29906.8528149571
},
"targetPosition": {
"x": 30066.6412350782,
"y": 30513.370484521565
"x": 30357.143005262184,
"y": 30118.984849313063
},
"floatingObject": {
"isPinned": false,
@@ -52,71 +52,15 @@
}
}
},
"id": "3a2d3669-04fb-43dc-9f4f-1fc14643dec3",
"id": "9d9ff49e-cb3b-4f2c-a562-3d33beb8fe32",
"savedPayload": {
"position": {
"x": 30066.6412350782,
"y": 30513.370484521565
"x": 30357.143005262184,
"y": 30118.984849313063
},
"targetPosition": {
"x": 30366.230095504572,
"y": 30497.669697648682
},
"floatingObject": {
"isPinned": false,
"isFrozen": false,
"isCollapsed": false,
"angleToParent": 2,
"distanceToParent": 3,
"arrangementStyle": 0
},
"uiObject": {
"isRunning": false
}
}
},
{
"type": "Condition",
"name": "Crossover",
"code": "chart.at24hs.Fisher.begin > chart.at24hs.Fisher.begin",
"project": "Foundations",
"javascriptCode": {
"type": "Javascript Code",
"name": "New Javascript Code",
"code": "chart.at01hs.EMA.ema1 > chart.at01hs.EMA.ema2",
"project": "Foundations",
"id": "b7f0dd1f-4d65-417a-b815-0fe0b138229e",
"savedPayload": {
"position": {
"x": 30039.446674495557,
"y": 29994.46735688143
},
"targetPosition": {
"x": 30202.838385000065,
"y": 30246.068527265055
},
"floatingObject": {
"isPinned": false,
"isFrozen": false,
"isCollapsed": false,
"angleToParent": 2,
"distanceToParent": 3,
"arrangementStyle": 0
},
"uiObject": {
"isRunning": false
}
}
},
"id": "8dbc8bd5-b3a9-48b5-945b-881bf38b216b",
"savedPayload": {
"position": {
"x": 30202.838385000065,
"y": 30246.068527265055
},
"targetPosition": {
"x": 30366.230095504572,
"y": 30497.669697648682
"x": 30569.275039618147,
"y": 30331.116883669027
},
"floatingObject": {
"isPinned": false,
@@ -132,7 +76,7 @@
}
}
],
"id": "66bd082e-2824-46c5-9791-d650ca28276d",
"id": "567cfdbe-b067-4990-9611-dbfba9b9a793",
"savedPayload": {
"position": {
"x": 30569.275039618147,
@@ -145,7 +89,7 @@
"floatingObject": {
"isPinned": false,
"isFrozen": false,
"isCollapsed": true,
"isCollapsed": false,
"angleToParent": 2,
"distanceToParent": 3,
"arrangementStyle": 0
@@ -157,7 +101,7 @@
}
],
"announcements": [],
"id": "e6cb0b5d-da60-4cf1-9d0a-cce48aacdfdb",
"id": "fc232171-151c-471b-a0b8-6ad2f7cb6adf",
"savedPayload": {
"position": {
"x": 30781.40707397411,
@@ -186,7 +130,7 @@
"situations": [
{
"type": "Situation",
"name": "EMA Crossunder",
"name": "Crossunder",
"project": "Foundations",
"conditions": [
{
@@ -195,17 +139,17 @@
"project": "Foundations",
"javascriptCode": {
"type": "Javascript Code",
"code": "chart.at01hs.EMA.ema1 < chart.at01hs.EMA.ema2",
"code": "chart.at01hs.EMA.ema1 < chart.at01hs.EMA.ema2 && chart.at01hs.EMA.previous.ema1 > chart.at01hs.EMA.previous.ema2",
"project": "Foundations",
"id": "b4730ec2-fbc3-4b6c-b36e-71f1d4a5816e",
"id": "f47f7cc3-395f-4a45-9e6e-21f02a522e3a",
"savedPayload": {
"position": {
"x": 30128.535252952344,
"y": 30074.683073224664
"x": 30993.539108330075,
"y": 29555.380952380954
},
"targetPosition": {
"x": 30421.979533172485,
"y": 30137.05658046999
"x": 30993.539108330075,
"y": 29855.380952380954
},
"floatingObject": {
"isPinned": false,
@@ -220,70 +164,15 @@
}
}
},
"id": "7dde214e-8ecf-4541-bdab-9768c8236f65",
"id": "13378aa9-2623-4f2b-a300-158a35bf46d6",
"savedPayload": {
"position": {
"x": 30421.979533172485,
"y": 30137.05658046999
"x": 30993.539108330075,
"y": 29855.380952380954
},
"targetPosition": {
"x": 30715.423813392626,
"y": 30199.43008771532
},
"floatingObject": {
"isPinned": false,
"isFrozen": false,
"isCollapsed": false,
"angleToParent": 1,
"distanceToParent": 3,
"arrangementStyle": 0
},
"uiObject": {
"isRunning": false
}
}
},
{
"type": "Condition",
"name": "New Condition",
"project": "Foundations",
"javascriptCode": {
"type": "Javascript Code",
"name": "New Javascript Code",
"code": "chart.at01hs.EMA.previous.ema1 > chart.at01hs.EMA.previous.ema2",
"project": "Foundations",
"id": "82a1f178-10f4-4d9f-a41c-56f6e0cab768",
"savedPayload": {
"position": {
"x": 31116.902177207943,
"y": 29753.543192428882
},
"targetPosition": {
"x": 30916.162995300285,
"y": 29976.4866400721
},
"floatingObject": {
"isPinned": false,
"isFrozen": false,
"isCollapsed": false,
"angleToParent": 1,
"distanceToParent": 3,
"arrangementStyle": 0
},
"uiObject": {
"isRunning": false
}
}
},
"id": "f5c13131-c464-4510-9648-38be2d1905a5",
"savedPayload": {
"position": {
"x": 30916.162995300285,
"y": 29976.4866400721
},
"targetPosition": {
"x": 30715.423813392626,
"y": 30199.43008771532
"x": 30993.539108330075,
"y": 30155.380952380954
},
"floatingObject": {
"isPinned": false,
@@ -299,7 +188,7 @@
}
}
],
"id": "7f57d1a7-6c2f-4483-a3cc-2c04cb187cf3",
"id": "2f91ed82-f85d-4b30-b255-465382b39a6f",
"savedPayload": {
"position": {
"x": 30993.539108330075,
@@ -312,7 +201,7 @@
"floatingObject": {
"isPinned": false,
"isFrozen": false,
"isCollapsed": true,
"isCollapsed": false,
"angleToParent": 3,
"distanceToParent": 3,
"arrangementStyle": 0
@@ -324,7 +213,7 @@
}
],
"announcements": [],
"id": "b2e64101-d51b-4c7b-9cd7-11df40ec6169",
"id": "0e26f382-b651-4f73-98a3-90e154012560",
"savedPayload": {
"position": {
"x": 30993.539108330075,
@@ -365,7 +254,7 @@
"name": "New Javascript Code",
"code": "true",
"project": "Foundations",
"id": "108efe9b-0e78-4650-95fa-5f47ea4566c3",
"id": "b88c81e8-4f12-46bc-9d3f-2be795784a46",
"savedPayload": {
"position": {
"x": 31445.622609705046,
@@ -388,7 +277,7 @@
}
}
},
"id": "5c513fb3-8787-41ba-87e9-09e2611b26ae",
"id": "8a94a57d-7752-4eb7-ac6c-587af40cef77",
"savedPayload": {
"position": {
"x": 31309.425459783182,
@@ -412,7 +301,7 @@
}
}
],
"id": "7be78fed-0640-4023-910b-b1404f16bd3a",
"id": "ef049a10-10d0-4cd0-8174-b114c669860b",
"savedPayload": {
"position": {
"x": 31173.22830986132,
@@ -437,7 +326,7 @@
}
],
"announcements": [],
"id": "09472203-67ee-4eba-ac2f-1f3cb48226df",
"id": "6f7e0b1f-883b-4e9f-a997-4e531da4eb41",
"savedPayload": {
"position": {
"x": 31205.67114268604,
@@ -461,7 +350,7 @@
}
},
"announcements": [],
"id": "e4f2b5cb-2cb8-4619-9de3-c066aaa1a214",
"id": "829fe6d9-f8e8-44a7-8175-a884132e7497",
"savedPayload": {
"position": {
"x": 30993.539108330075,
@@ -502,7 +391,7 @@
"name": "Entry Target Rate",
"code": "tradingEngine.tradingCurrent.tradingEpisode.candle.close.value",
"project": "Foundations",
"id": "f8736b16-edde-45a2-b565-49673a3d524e",
"id": "3c57e8dc-6924-48b4-8275-3345e2535577",
"savedPayload": {
"position": {
"x": 31853.346729465407,
@@ -525,7 +414,7 @@
}
}
},
"id": "db001dc4-af5f-4059-a17c-0ce7c5583f78",
"id": "934af723-db70-4eb3-bc63-1439c7669173",
"savedPayload": {
"position": {
"x": 31703.346729465407,
@@ -557,7 +446,7 @@
"name": "Target Size in Quoted Asset",
"code": "tradingEngine.tradingCurrent.tradingEpisode.episodeQuotedAsset.balance.value\n",
"project": "Foundations",
"id": "c45c5654-232e-4ebe-a0eb-8103901a3fb6",
"id": "801ccf6e-6b49-4433-8f3d-f6217c6caab7",
"savedPayload": {
"position": {
"x": 32153.346729465407,
@@ -580,7 +469,7 @@
}
}
},
"id": "726c5b24-7420-4496-84fb-9ada5054e1b3",
"id": "40607c04-0955-4e90-9367-d4a26806833a",
"savedPayload": {
"position": {
"x": 31853.346729465407,
@@ -603,7 +492,7 @@
}
}
},
"id": "1350ac22-df5a-422e-bce3-771e15a3c75f",
"id": "298964cc-3b37-4019-b576-6f9a96b1dacd",
"savedPayload": {
"position": {
"x": 31553.346729465407,
@@ -640,7 +529,7 @@
{
"type": "Market Buy Order",
"name": "New Market Buy Order",
"config": "{\n\"percentageOfAlgorithmSize\": 100, \n\"spawnMultipleOrders\": false \n}",
"config": "{\n\"percentageOfAlgorithmSize\": 20, \n\"spawnMultipleOrders\": true \n}",
"project": "Foundations",
"createOrderEvent": {
"type": "Create Order Event",
@@ -659,9 +548,9 @@
"javascriptCode": {
"type": "Javascript Code",
"name": "New Javascript Code",
"code": "chart.at01hs.WEMAsignal.signal > 0.5 && chart.at01hs.WEMAsignal.signal >= chart.at01hs.WEMAsignal.previous.signal",
"code": "chart.at01hs.WEMAsignal.signal >= 0.5 ",
"project": "Foundations",
"id": "8596b4b4-d567-4c5d-868e-65e6688c5e70",
"id": "05bd7461-7d39-4620-ad3e-62ca086103c7",
"savedPayload": {
"position": {
"x": 33112.1924562774,
@@ -684,7 +573,7 @@
}
}
},
"id": "71d536ee-8221-4903-981e-03e98374cbb8",
"id": "8b212c49-db16-4604-ab38-c75386fe0ae8",
"savedPayload": {
"position": {
"x": 32852.38483514207,
@@ -708,7 +597,7 @@
}
}
],
"id": "cc73b406-6cb8-45cd-9173-4565e2355337",
"id": "602edc66-1cda-4517-80b0-8b70b8e837cd",
"savedPayload": {
"position": {
"x": 32592.57721400674,
@@ -733,7 +622,7 @@
}
],
"announcements": [],
"id": "4874e11f-9b13-4da0-ba2f-a48b6e50ab89",
"id": "c155e10a-1cc7-48e6-b1f0-a8bd33f39710",
"savedPayload": {
"position": {
"x": 32332.769592871406,
@@ -756,7 +645,7 @@
}
}
},
"id": "321a9446-757c-4f6b-bd08-b251cc5743dc",
"id": "9790e36e-c011-420a-b37b-02411270d505",
"savedPayload": {
"position": {
"x": 32072.961971736073,
@@ -814,7 +703,7 @@
"marketSellOrders": [],
"limitBuyOrders": [],
"limitSellOrders": [],
"id": "9b82b9ad-205e-4bea-82ca-c51ba13e8a31",
"id": "bca241c1-d104-4f57-82cf-910871e45362",
"savedPayload": {
"position": {
"x": 31813.15435060074,
@@ -839,7 +728,7 @@
}
}
],
"id": "ccf4976a-236f-4856-9061-bde952db5e57",
"id": "66b8730e-850a-4a29-a205-5a81725e93b7",
"savedPayload": {
"position": {
"x": 31553.346729465407,
@@ -863,7 +752,7 @@
}
},
"announcements": [],
"id": "2b77a85e-6bb5-4c68-997c-c9fce2b84388",
"id": "9059702a-8b3a-47e2-a0a6-c2bd0e4397a8",
"savedPayload": {
"position": {
"x": 31293.539108330075,
@@ -903,7 +792,7 @@
"name": "Target Rate Formula",
"code": "tradingEngine.tradingCurrent.tradingEpisode.candle.close.value",
"project": "Foundations",
"id": "08cd7f3b-d747-44c5-a69e-99303464414f",
"id": "699d2c78-c689-4b1c-baad-43256bdfa585",
"savedPayload": {
"position": {
"x": 31663.15435060074,
@@ -926,7 +815,7 @@
}
}
},
"id": "10599ce9-11ac-4093-b633-fd8b9665d991",
"id": "fe062d57-7da6-4773-bfec-5809514f3c66",
"savedPayload": {
"position": {
"x": 31403.346729465407,
@@ -958,7 +847,7 @@
"name": "New Formula",
"code": "tradingEngine.tradingCurrent.tradingEpisode.episodeBaseAsset.balance.value",
"project": "Foundations",
"id": "50bc8bac-b0e4-462c-85c1-3767a4e5076f",
"id": "20b4c043-a62c-458c-b0dd-9d9f0fe8e5a9",
"savedPayload": {
"position": {
"x": 31143.539108330075,
@@ -981,7 +870,7 @@
}
}
},
"id": "ba2f4863-486a-4215-a8dd-dac6b357c439",
"id": "c89cb5c4-d81c-4232-8086-c3fcfc1b2c48",
"savedPayload": {
"position": {
"x": 31143.539108330075,
@@ -1004,7 +893,7 @@
}
}
},
"id": "aedbcfb2-3a10-4f76-ad0f-67d6952d6cb7",
"id": "558b4a55-7cbd-4794-a3ad-009015aca2f3",
"savedPayload": {
"position": {
"x": 31143.539108330075,
@@ -1041,7 +930,7 @@
{
"type": "Market Sell Order",
"name": "New Market Sell Order",
"config": "{\n\"percentageOfAlgorithmSize\": 100, \n\"spawnMultipleOrders\": false \n}",
"config": "{\n\"percentageOfAlgorithmSize\": 20, \n\"spawnMultipleOrders\": true \n}",
"project": "Foundations",
"createOrderEvent": {
"type": "Create Order Event",
@@ -1060,9 +949,9 @@
"javascriptCode": {
"type": "Javascript Code",
"name": "New Javascript Code",
"code": "chart.at01hs.WEMAsignal.previous.signal >= 0.5 && chart.at01hs.WEMAsignal.signal < 0.5",
"code": "chart.at01hs.WEMAsignal.signal < 0.5",
"project": "Foundations",
"id": "d129d107-2206-4230-adaf-4976981c397d",
"id": "e1fe9c08-832a-4411-9a46-19dad548583e",
"savedPayload": {
"position": {
"x": 30626.476248922347,
@@ -1085,7 +974,7 @@
}
}
},
"id": "197420ae-f425-41ac-b4b4-d10a61c964ba",
"id": "ad126cf6-3be8-431c-9221-d23ed5a9b318",
"savedPayload": {
"position": {
"x": 30548.83053539159,
@@ -1109,7 +998,7 @@
}
}
],
"id": "f1ba99a2-6819-44b5-9087-a24855b4b48a",
"id": "e801551a-f69e-4433-bcf4-070b750fa909",
"savedPayload": {
"position": {
"x": 30471.184821860832,
@@ -1144,9 +1033,9 @@
"javascriptCode": {
"type": "Javascript Code",
"name": "New Javascript Code",
"code": "tradingEngine.tradingCurrent.tradingEpisode.candle.close.value >= tradingEngine.tradingCurrent.position.entryTargetRate.value * 1.30",
"code": "tradingEngine.tradingCurrent.tradingEpisode.candle.close.value >= tradingEngine.tradingCurrent.position.entryTargetRate.value * 1.17",
"project": "Foundations",
"id": "67ae2544-d4ec-4fcd-beaa-6768984bbf48",
"id": "f6578611-b4d5-4cb8-84a5-af567b367c55",
"savedPayload": {
"position": {
"x": 29943.539108330075,
@@ -1169,7 +1058,7 @@
}
}
},
"id": "03b9f164-f638-41c7-ad06-94cfeca007e7",
"id": "ed0fb6c0-acf8-402f-9b62-21f9f6a2d204",
"savedPayload": {
"position": {
"x": 30093.539108330075,
@@ -1193,7 +1082,7 @@
}
}
],
"id": "3a2b7b7d-36a4-42d4-9147-4112115c53f7",
"id": "9f1e5745-3edc-4c75-96a7-806c90146778",
"savedPayload": {
"position": {
"x": 30243.539108330075,
@@ -1230,7 +1119,7 @@
"name": "New Javascript Code",
"code": "tradingEngine.tradingCurrent.tradingEpisode.candle.close.value < 0.99 * tradingEngine.tradingCurrent.position.entryTargetRate.value",
"project": "Foundations",
"id": "2b58539e-d6c9-4c81-aa81-d0f6d762f8f8",
"id": "49d2a48c-caab-4ce6-9430-809c9f68345d",
"savedPayload": {
"position": {
"x": 29524.20586466991,
@@ -1253,7 +1142,7 @@
}
}
},
"id": "55eb23dc-b9c8-4ed3-be4b-cceee33097ce",
"id": "caaf0c1e-4faa-439c-b80e-53ffa2774540",
"savedPayload": {
"position": {
"x": 29813.983612556633,
@@ -1277,7 +1166,7 @@
}
}
],
"id": "ce8433b3-1764-477d-b7fe-cb37c3e21f6c",
"id": "e8fe9bbc-b9d8-4177-b291-e1e88952ea07",
"savedPayload": {
"position": {
"x": 30103.761360443354,
@@ -1302,7 +1191,7 @@
}
],
"announcements": [],
"id": "7d35f880-508f-4de0-b8b4-1779fd3f85d0",
"id": "fd3e6184-de9d-440d-8d1b-cc0f68f227bf",
"savedPayload": {
"position": {
"x": 30393.539108330075,
@@ -1325,7 +1214,7 @@
}
}
},
"id": "208a3dfa-fd43-4d88-97e9-cd72b9b7cf13",
"id": "bacbbd95-ce0d-49de-9991-4820ea678296",
"savedPayload": {
"position": {
"x": 30543.539108330075,
@@ -1382,7 +1271,7 @@
],
"limitBuyOrders": [],
"limitSellOrders": [],
"id": "e628be12-6c65-4c84-87f1-93b9743e3ff3",
"id": "abf3b874-e889-4735-bb49-6e3cf7b0dbd1",
"savedPayload": {
"position": {
"x": 30693.539108330075,
@@ -1406,7 +1295,7 @@
}
}
],
"id": "e05fc323-fde9-4b43-9559-fb88abf5f3e3",
"id": "d070d00a-5728-4ff7-8763-95e52e7eee86",
"savedPayload": {
"position": {
"x": 30843.539108330075,
@@ -1430,7 +1319,7 @@
}
},
"announcements": [],
"id": "be7862dd-f241-4b73-9faf-ca0fb9bee6b7",
"id": "392a1c94-23e2-45ac-bc59-f10284ec2f16",
"savedPayload": {
"position": {
"x": 30993.539108330075,
@@ -1453,7 +1342,7 @@
}
}
},
"id": "85ed96f4-8744-43ce-a7ca-d7277f3e8183",
"id": "889d297a-c62d-4fcb-b7bc-1e6526111891",
"savedPayload": {
"position": {
"x": 30993.539108330075,
@@ -1466,7 +1355,7 @@
"floatingObject": {
"isPinned": false,
"isFrozen": false,
"isCollapsed": true,
"isCollapsed": false,
"angleToParent": 1,
"distanceToParent": 3,
"arrangementStyle": 0
@@ -1477,7 +1366,7 @@
}
}
],
"id": "e9a1f6f4-7f43-4355-921e-a4f24375de5f",
"id": "9e13804e-0aca-4773-960a-fbe37184f0c6",
"savedPayload": {
"position": {
"x": 30693.539108330075,
@@ -150,7 +150,7 @@ exports.newAlgorithmicTradingBotModulesSnapshots = function(processIndex) {
}
/* Now we go down through all this node children */
let schemaDocument = TS.projects.foundations.globals.taskConstants.APP_SCHEMA_MAP.get(node.project + '-' + node.type)
let schemaDocument = SA.projects.foundations.globals.schemas.APP_SCHEMA_MAP.get(node.project + '-' + node.type)
if (schemaDocument === undefined) { return }
if (schemaDocument.childrenNodesProperties !== undefined) {
@@ -112,7 +112,7 @@ exports.newAlgorithmicTradingBotModulesTradingEngine = function (processIndex) {
destinationNode.value = originNode.value
/* Now we go down through all the children of the origin node, assuming the destination node has the same children structure*/
let schemaDocument = TS.projects.foundations.globals.taskConstants.APP_SCHEMA_MAP.get(originNode.project + '-' + originNode.type)
let schemaDocument = SA.projects.foundations.globals.schemas.APP_SCHEMA_MAP.get(originNode.project + '-' + originNode.type)
if (schemaDocument === undefined) { return }
if (schemaDocument.childrenNodesProperties !== undefined) {
@@ -151,7 +151,7 @@ exports.newAlgorithmicTradingBotModulesTradingEngine = function (processIndex) {
nodesMap.set(node.id, node)
/* Now we go down through all this node children */
let schemaDocument = TS.projects.foundations.globals.taskConstants.APP_SCHEMA_MAP.get(node.project + '-' + node.type)
let schemaDocument = SA.projects.foundations.globals.schemas.APP_SCHEMA_MAP.get(node.project + '-' + node.type)
if (schemaDocument === undefined) { return }
if (schemaDocument.childrenNodesProperties !== undefined) {
@@ -194,7 +194,7 @@ exports.newAlgorithmicTradingBotModulesTradingEngine = function (processIndex) {
}
/* Now we go down through all this node children */
let schemaDocument = TS.projects.foundations.globals.taskConstants.APP_SCHEMA_MAP.get(node.project + '-' + node.type)
let schemaDocument = SA.projects.foundations.globals.schemas.APP_SCHEMA_MAP.get(node.project + '-' + node.type)
if (schemaDocument === undefined) { return }
if (schemaDocument.childrenNodesProperties !== undefined) {
@@ -31,7 +31,7 @@ exports.newAlgorithmicTradingBotModulesTradingOutput = function (processIndex) {
/* Preparing everything for the Simulation */
let tradingSimulationModuleObject = TS.projects.algorithmicTrading.botModules.tradingSimulation.newAlgorithmicTradingBotModulesTradingSimulation(processIndex)
let outputDatasets = TS.projects.visualScripting.utilities.nodeFunctions.nodeBranchToArray(TS.projects.foundations.globals.taskConstants.TASK_NODE.bot.processes[processIndex].referenceParent.processOutput, 'Output Dataset')
let outputDatasets = SA.projects.visualScripting.utilities.nodeFunctions.nodeBranchToArray(TS.projects.foundations.globals.taskConstants.TASK_NODE.bot.processes[processIndex].referenceParent.processOutput, 'Output Dataset')
let outputDatasetsMap = new Map()
await TS.projects.foundations.functionLibraries.outputManagementFunctions.readFiles(
@@ -37,7 +37,7 @@ exports.newAlgorithmicTradingBotModulesTradingRecords = function (processIndex)
we have a pointer to the node that have the information we need to extract.
Later, based on the product record definition we will extract each individual value.
*/
let outputDatasets = TS.projects.visualScripting.utilities.nodeFunctions.nodeBranchToArray(TS.projects.foundations.globals.taskConstants.TASK_NODE.bot.processes[processIndex].referenceParent.processOutput, 'Output Dataset')
let outputDatasets = SA.projects.visualScripting.utilities.nodeFunctions.nodeBranchToArray(TS.projects.foundations.globals.taskConstants.TASK_NODE.bot.processes[processIndex].referenceParent.processOutput, 'Output Dataset')
for (let i = 0; i < outputDatasets.length; i++) {
let outputDatasetNode = outputDatasets[i]
@@ -372,8 +372,8 @@ exports.newAlgorithmicTradingBotModulesTradingSimulation = function (processInde
}
function positionChart(chart) {
let dataDependencies = TS.projects.visualScripting.utilities.nodeFunctions.nodeBranchToArray(TS.projects.foundations.globals.taskConstants.TASK_NODE.bot.processes[processIndex].referenceParent.processDependencies, 'Data Dependency')
dataDependencies = TS.projects.visualScripting.utilities.nodeFunctions.filterOutNodeWihtoutReferenceParentFromNodeArray(dataDependencies)
let dataDependencies = SA.projects.visualScripting.utilities.nodeFunctions.nodeBranchToArray(TS.projects.foundations.globals.taskConstants.TASK_NODE.bot.processes[processIndex].referenceParent.processDependencies, 'Data Dependency')
dataDependencies = SA.projects.visualScripting.utilities.nodeFunctions.filterOutNodeWihtoutReferenceParentFromNodeArray(dataDependencies)
/* Finding the Current Element on Daily Files */
if (TS.projects.foundations.globals.processVariables.VARIABLES_BY_PROCESS_INDEX_MAP.get(processIndex).TRADING_PROCESSING_DAILY_FILES) {
@@ -272,7 +272,7 @@ exports.newAlgorithmicTradingBotModulesTradingSystem = function (processIndex) {
}
/* Now we go down through all this node children */
let schemaDocument = TS.projects.foundations.globals.taskConstants.APP_SCHEMA_MAP.get(node.project + '-' + node.type)
let schemaDocument = SA.projects.foundations.globals.schemas.APP_SCHEMA_MAP.get(node.project + '-' + node.type)
if (schemaDocument === undefined) { return }
if (schemaDocument.childrenNodesProperties !== undefined) {
@@ -0,0 +1,45 @@
/* PMCommunicationModule - Trading Bot's Version.
* Fascilitates communications between the Portfolio Manager and its managed sessions.
* Session Key naming convention: name + type + id
*/
exports.newPMCommunicationModule_Trading = function (callerId) {
const MODULE_NAME = 'PM Communication Module - Trading';
moduleObj = {
beginListening: beginListening,
getQuoteAssetBalance: getQuoteAssetBalance
}
const SESSION_ID = callerId;
return moduleObj;
/* Listeners Section: */
function beginListening() {
TS.projects.foundations.globals.taskConstants.EVENT_SERVER_CLIENT_MODULE_OBJECT.listenToEvent(
SESSION_ID,
'Quote Asset Balance Reply',
undefined,
SESSION_ID,
undefined,
gotQuoteAssetBalance)
}
/* eventsCallBack Section: */
function getQuoteAssetBalance() {
TS.projects.foundations.globals.taskConstants.EVENT_SERVER_CLIENT_MODULE_OBJECT.raiseEvent(
SESSION_ID,
'Quote Asset Balance',
undefined
)
}
function gotQuoteAssetBalance() {
let ret = arguments[0].event;
console.log("Quote Asset Balance=>" + ret);
}
}
@@ -47,6 +47,9 @@
TS.projects.foundations.globals.taskVariables.SESSION_MAP.set(
TS.projects.foundations.globals.processVariables.VARIABLES_BY_PROCESS_INDEX_MAP.get(processIndex).SESSION_KEY,
TS.projects.foundations.globals.processVariables.VARIABLES_BY_PROCESS_INDEX_MAP.get(processIndex).SESSION_KEY)
/* We will store the PMCommunicationModule Object: */
TS.projects.foundations.globals.processVariables.PM_COMMUNICATION_MODULE = TS.projects.algorithmicTrading.botModules.PMCommunicationModule_Trading.newPMCommunicationModule_Trading(VARIABLES_BY_PROCESS_INDEX.SESSION_KEY);
/* Listen to event to start or stop the session. */
TS.projects.foundations.globals.taskConstants.EVENT_SERVER_CLIENT_MODULE_OBJECT.listenToEvent(
@@ -512,6 +515,7 @@
}
function startBackTesting(message) {
return true
}
@@ -580,6 +584,9 @@
}
function startLiveTrading() {
// Testing:
TS.projects.foundations.globals.processVariables.PM_COMMUNICATION_MODULE.beginListening();
TS.projects.foundations.globals.processVariables.PM_COMMUNICATION_MODULE.getQuoteAssetBalance();
return checkKey()
}
@@ -1,13 +1,13 @@
function newAlgorithmicTradingFunctionLibraryTradingSessionFunctions() {
let thisObject = {
syncronizeSessionWithBackEnd: syncronizeSessionWithBackEnd,
synchronizeSessionWithBackEnd: synchronizeSessionWithBackEnd,
runSession: runSession,
stopSession: stopSession
}
return thisObject
function syncronizeSessionWithBackEnd(node) {
function synchronizeSessionWithBackEnd(node) {
let validationsResult = validations(node)
if (validationsResult === undefined) {
/* If something fails at validations we just quit. */
File diff suppressed because it is too large. Load diff
File diff suppressed because it is too large. Load diff
File diff suppressed because it is too large. Load diff
@@ -201,7 +201,7 @@ exports.newDataMiningBotModulesFetchingProcess = function (processIndex) {
if (recordProperty.apiResponseFieldReference !== undefined) {
if (recordProperty.apiResponseFieldReference.referenceParent !== undefined) {
let apiResponseField = recordProperty.apiResponseFieldReference.referenceParent
let endpointNodeFound = TS.projects.visualScripting.utilities.nodeFunctions.findNodeInNodeMesh(apiResponseField, 'API Endpoint')
let endpointNodeFound = SA.projects.visualScripting.utilities.nodeFunctions.findNodeInNodeMesh(apiResponseField, 'API Endpoint')
/*
Every Record Property with an apiResponseFieldReference must be on the path
to a certain endpoint.
@@ -52,13 +52,13 @@
}
/* The first phase here is about checking that we have everything we need at the definition level. */
let dataDependencies = TS.projects.visualScripting.utilities.nodeFunctions.nodeBranchToArray(
let dataDependencies = SA.projects.visualScripting.utilities.nodeFunctions.nodeBranchToArray(
TS.projects.foundations.globals.taskConstants.TASK_NODE.bot.processes[processIndex].referenceParent.processDependencies, 'Data Dependency'
)
if (TS.projects.foundations.functionLibraries.singleMarketFunctions.validateDataDependencies(processIndex, dataDependencies, callBackFunction) !== true) { return }
let outputDatasets = TS.projects.visualScripting.utilities.nodeFunctions.nodeBranchToArray(
let outputDatasets = SA.projects.visualScripting.utilities.nodeFunctions.nodeBranchToArray(
TS.projects.foundations.globals.taskConstants.TASK_NODE.bot.processes[processIndex].referenceParent.processOutput, 'Output Dataset'
)
if (TS.projects.foundations.functionLibraries.singleMarketFunctions.validateOutputDatasets(processIndex, outputDatasets, callBackFunction) !== true) { return }
@@ -138,9 +138,9 @@
contextSummary.dataset = outputDatasetNode.referenceParent.config.codeName
contextSummary.product = outputDatasetNode.referenceParent.parentNode.config.codeName
let botNode = TS.projects.visualScripting.utilities.nodeFunctions.findNodeInNodeMesh(outputDatasetNode, 'Indicator Bot')
let botNode = SA.projects.visualScripting.utilities.nodeFunctions.findNodeInNodeMesh(outputDatasetNode, 'Indicator Bot')
contextSummary.bot = botNode.config.codeName
let dataMineNode = TS.projects.visualScripting.utilities.nodeFunctions.findNodeInNodeMesh(outputDatasetNode, 'Data Mine')
let dataMineNode = SA.projects.visualScripting.utilities.nodeFunctions.findNodeInNodeMesh(outputDatasetNode, 'Data Mine')
contextSummary.dataMine = dataMineNode.config.codeName
contextSummary.mineType = dataMineNode.type.replace(' ', '-')
contextSummary.project = dataMineNode.project
@@ -513,7 +513,7 @@
}
function writeDataRanges(callBack) {
let outputDatasets = TS.projects.visualScripting.utilities.nodeFunctions.nodeBranchToArray(
let outputDatasets = SA.projects.visualScripting.utilities.nodeFunctions.nodeBranchToArray(
TS.projects.foundations.globals.taskConstants.TASK_NODE.bot.processes[processIndex].referenceParent.processOutput, 'Output Dataset')
let outputDatasetIndex = -1;
controlLoop()
@@ -151,7 +151,7 @@
function writeTimeFramesFiles(callBack) {
let outputDatasets =
TS.projects.visualScripting.utilities.nodeFunctions.nodeBranchToArray(TS.projects.foundations.globals.taskConstants.TASK_NODE.bot.processes[processIndex].referenceParent.processOutput, 'Output Dataset')
SA.projects.visualScripting.utilities.nodeFunctions.nodeBranchToArray(TS.projects.foundations.globals.taskConstants.TASK_NODE.bot.processes[processIndex].referenceParent.processOutput, 'Output Dataset')
let outputDatasetIndex = -1;
controlLoop()
@@ -119,16 +119,17 @@
},
{
"style": "Subtitle",
"text": "Custom Shortcuts"
"text": "Custom Shortcuts to Nodes",
"updated": 1637691249937
},
{
"style": "Include",
"text": "Foundations->Topic->Keyboard Shortcuts to Nodes->Custom Node Shortcuts",
"updated": 1637691223240
},
{
"style": "List",
"text": "It is also possible to set a custom shortcut to any node you would like. Simply hover over a node and hit Ctrl + Alt + your preferred key to assign the shortcut.",
"updated": 1634909920250
},
{
"style": "Note",
"text": "A more detailed walk through can be found here: Keyboard Shortcuts to Nodes"
"text": "It is also possible to set a custom shortcut to any node you would like. Simply hover over a node and hit Ctrl + Alt + your preferred key to assign the shortcut."
},
{
"style": "Subtitle",
@@ -676,7 +676,7 @@ function newFoundationsDocsDocumentPage() {
}
case 'Tutorial': {
orderedTutorialPageIndexArray = UI.projects.education.utilities.docs.buildOrderedPageIndex(
UI.projects.education.spaces.docsSpace.currentDocumentBeingRendered.project,
project,
'Tutorial',
chapterName
)
@@ -141,6 +141,12 @@ function newFoundationsDocsFooter() {
}
HTML = HTML + '"></a>'
HTML = HTML + '<a href="#" onClick="UI.projects.education.spaces.docsSpace.changeLanguage(\'EL\')"><img src="Images/Languages/EL.png" title="Greek" class="docs-footer-language'
if (languageCode === 'EL') {
HTML = HTML + '-selected'
}
HTML = HTML + '"></a>'
HTML = HTML + '</div>'
HTML = HTML + '<div class="docs-footer-cell">'
@@ -52,6 +52,10 @@ function newEducationUtilitiesLanguages() {
languageLabel = 'Arabic'
break
}
case 'EL': {
languageLabel = 'Greek'
break
}
}
return languageLabel
}
Binary file not shown.

After

Width:  |  Height:  |  Size: 13 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 13 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 13 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 13 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 13 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 13 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 13 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 7.3 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 5.7 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 13 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 13 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 13 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 13 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 13 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 13 KiB

File diff suppressed because it is too large. Load diff
@@ -0,0 +1,8 @@
exports.newFoundationsGlobalsSchemas = function () {
let thisObject = {
APP_SCHEMA_MAP: new Map()
}
return thisObject
}
@@ -9,6 +9,16 @@
"actionProject": "Visual-Scripting",
"relatedUiObjectProject": "Foundations"
},
{
"action": "Add UI Object",
"label": "Add Cancel Order Portfolio Event",
"disableIfPropertyIsDefined": true,
"propertyToCheckFor": "cancelOrderPMEvent",
"relatedUiObject": "Cancel Order PM Event",
"actionFunction": "payload.executeAction",
"relatedUiObjectProject": "Foundations",
"actionProject": "Visual-Scripting"
},
{
"action": "Add UI Object",
"label": "Add Announcement",
@@ -40,6 +50,11 @@
"childType": "Situation",
"autoAdd": true
},
{
"name": "cancelOrderPMEvent",
"type": "node",
"childType": "Cancel Order PM Event"
},
{
"name": "announcements",
"type": "array",
@@ -0,0 +1,29 @@
{
"type": "Cancel Order PM Event",
"menuItems": [
{
"action": "Delete UI Object",
"actionProject": "Visual-Scripting",
"askConfirmation": true,
"confirmationLabel": "Confirm to Delete",
"label": "Delete",
"iconPathOn": "delete-entity",
"iconPathOff": "delete-entity",
"actionFunction": "payload.executeAction"
}
],
"addLeftIcons": true,
"initialValues": {
"config": "{}"
},
"editors": {
"config": true
},
"level": 4,
"attachingRules": {
"compatibleTypes": "->Cancel Order Event->"
},
"childrenNodesProperties": [
],
"propertyNameAtParent": "cancelOrderPMEvent"
}
@@ -9,6 +9,16 @@
"actionProject": "Visual-Scripting",
"relatedUiObjectProject": "Foundations"
},
{
"action": "Add UI Object",
"label": "Add Close Stage Portfolio Event",
"disableIfPropertyIsDefined": true,
"propertyToCheckFor": "closeStagePMEvent",
"relatedUiObject": "Close Stage PM Event",
"actionFunction": "payload.executeAction",
"relatedUiObjectProject": "Foundations",
"actionProject": "Visual-Scripting"
},
{
"action": "Add UI Object",
"label": "Add Announcement",
@@ -40,6 +50,11 @@
"childType": "Situation",
"autoAdd": true
},
{
"name": "closeStagePMEvent",
"type": "node",
"childType": "Close Stage PM Event"
},
{
"name": "announcements",
"type": "array",
@@ -1,5 +1,5 @@
{
"type": "Signing Accounts",
"type": "Close Stage PM Event",
"menuItems": [
{
"action": "Delete UI Object",
@@ -13,17 +13,17 @@
}
],
"addLeftIcons": true,
"initialValues": {
"config": "{}"
},
"editors": {
"config": true
},
"level": 2,
"attachingRules": {
"compatibleTypes": "->User Profile->"
"compatibleTypes": "->Close Stage Event->"
},
"propertyNameAtParent": "signingAccounts",
"childrenNodesProperties": [
{
"name": "signingAccounts",
"type": "array",
"childType": "Signing Account",
"autoAdd": false
}
]
],
"propertyNameAtParent": "closeStagePMEvent"
}
@@ -9,6 +9,16 @@
"actionProject": "Visual-Scripting",
"relatedUiObjectProject": "Foundations"
},
{
"action": "Add UI Object",
"label": "Add Create Order Portfolio Event",
"disableIfPropertyIsDefined": true,
"propertyToCheckFor": "createOrderPMEvent",
"relatedUiObject": "Create Order PM Event",
"actionFunction": "payload.executeAction",
"relatedUiObjectProject": "Foundations",
"actionProject": "Visual-Scripting"
},
{
"action": "Add UI Object",
"label": "Add Announcement",
@@ -40,6 +50,11 @@
"childType": "Situation",
"autoAdd": true
},
{
"name": "createOrderPMEvent",
"type": "node",
"childType": "Create Order PM Event"
},
{
"name": "announcements",
"type": "array",
@@ -0,0 +1,29 @@
{
"type": "Create Order PM Event",
"menuItems": [
{
"action": "Delete UI Object",
"actionProject": "Visual-Scripting",
"askConfirmation": true,
"confirmationLabel": "Confirm to Delete",
"label": "Delete",
"iconPathOn": "delete-entity",
"iconPathOff": "delete-entity",
"actionFunction": "payload.executeAction"
}
],
"addLeftIcons": true,
"initialValues": {
"config": "{}"
},
"editors": {
"config": true
},
"level": 2,
"attachingRules": {
"compatibleTypes": "->Create Order Event->"
},
"childrenNodesProperties": [
],
"propertyNameAtParent": "createOrderPMEvent"
}
@@ -18,7 +18,7 @@
"addLeftIcons": true,
"level": 4,
"attachingRules": {
"compatibleTypes": "->Task->"
"compatibleTypes": "->Task->Portfolio Task->"
},
"referencingRules": {
"compatibleTypes": "->Exchange Account Key->"
@@ -0,0 +1,29 @@
{
"type": "Managed Stop Loss PM Formula",
"menuItems": [
{
"action": "Delete UI Object",
"actionProject": "Visual-Scripting",
"askConfirmation": true,
"confirmationLabel": "Confirm to Delete",
"label": "Delete",
"iconPathOn": "delete-entity",
"iconPathOff": "delete-entity",
"actionFunction": "payload.executeAction"
}
],
"addLeftIcons": true,
"initialValues": {
"config": "{}"
},
"editors": {
"config": true
},
"level": 4,
"attachingRules": {
"compatibleTypes": "->Managed Stop Loss->"
},
"childrenNodesProperties": [
],
"propertyNameAtParent": "managedStopLossPMFormula"
}
@@ -9,6 +9,16 @@
"actionProject": "Visual-Scripting",
"relatedUiObjectProject": "Foundations"
},
{
"action": "Add UI Object",
"label": "Add Manged SL Portfolio Formula",
"disableIfPropertyIsDefined": true,
"propertyToCheckFor": "managedStopLossPMFormula",
"relatedUiObject": "Managed Stop Loss PM Formula",
"actionFunction": "payload.executeAction",
"relatedUiObjectProject": "Foundations",
"actionProject": "Visual-Scripting"
},
{
"action": "Delete UI Object",
"actionProject": "Visual-Scripting",
@@ -31,6 +41,11 @@
"type": "array",
"childType": "Phase",
"autoAdd": true
},
{
"name": "managedStopLossPMFormula",
"type": "node",
"childType": "Managed Stop Loss PM Formula"
}
],
"propertyNameAtParent": "managedStopLoss"
@@ -0,0 +1,29 @@
{
"type": "Managed Take Profit PM Formula",
"menuItems": [
{
"action": "Delete UI Object",
"actionProject": "Visual-Scripting",
"askConfirmation": true,
"confirmationLabel": "Confirm to Delete",
"label": "Delete",
"iconPathOn": "delete-entity",
"iconPathOff": "delete-entity",
"actionFunction": "payload.executeAction"
}
],
"addLeftIcons": true,
"initialValues": {
"config": "{}"
},
"editors": {
"config": true
},
"level": 4,
"attachingRules": {
"compatibleTypes": "->Managed Take Profit->"
},
"childrenNodesProperties": [
],
"propertyNameAtParent": "managedTakeProfitPMFormula"
}
@@ -9,6 +9,16 @@
"actionProject": "Visual-Scripting",
"relatedUiObjectProject": "Foundations"
},
{
"action": "Add UI Object",
"label": "Add Manged TP Portfolio Formula",
"disableIfPropertyIsDefined": true,
"propertyToCheckFor": "managedTakeProfitPMFormula",
"relatedUiObject": "Managed Take Profit PM Formula",
"actionFunction": "payload.executeAction",
"relatedUiObjectProject": "Foundations",
"actionProject": "Visual-Scripting"
},
{
"action": "Delete UI Object",
"actionProject": "Visual-Scripting",
@@ -31,6 +41,11 @@
"type": "array",
"childType": "Phase",
"autoAdd": true
},
{
"name": "managedTakeProfitPMFormula",
"type": "node",
"childType": "Managed Take Profit PM Formula"
}
],
"propertyNameAtParent": "managedTakeProfit"
@@ -43,7 +43,7 @@
"addLeftIcons": true,
"level": 2,
"attachingRules": {
"compatibleTypes": "->Task->"
"compatibleTypes": "->Portfolio Task->"
},
"childrenNodesProperties": [
{
@@ -9,6 +9,16 @@
"actionProject": "Visual-Scripting",
"relatedUiObjectProject": "Foundations"
},
{
"action": "Add UI Object",
"label": "Add Move Phase Portfolio Event",
"disableIfPropertyIsDefined": true,
"propertyToCheckFor": "moveToPhasePMEvent",
"relatedUiObject": "Move To Phase PM Event",
"actionFunction": "payload.executeAction",
"relatedUiObjectProject": "Foundations",
"actionProject": "Visual-Scripting"
},
{
"action": "Add UI Object",
"label": "Add Announcement",
@@ -43,6 +53,11 @@
"childType": "Situation",
"autoAdd": true
},
{
"name": "moveToPhasePMEvent",
"type": "node",
"childType": "Move To Phase PM Event"
},
{
"name": "announcements",
"type": "array",
@@ -0,0 +1,29 @@
{
"type": "Move To Phase PM Event",
"menuItems": [
{
"action": "Delete UI Object",
"actionProject": "Visual-Scripting",
"askConfirmation": true,
"confirmationLabel": "Confirm to Delete",
"label": "Delete",
"iconPathOn": "delete-entity",
"iconPathOff": "delete-entity",
"actionFunction": "payload.executeAction"
}
],
"addLeftIcons": true,
"initialValues": {
"config": "{}"
},
"editors": {
"config": true
},
"level": 4,
"attachingRules": {
"compatibleTypes": "->Move To Phase Event->"
},
"childrenNodesProperties": [
],
"propertyNameAtParent": "moveToPhasePMEvent"
}
@@ -9,6 +9,16 @@
"actionProject": "Visual-Scripting",
"relatedUiObjectProject": "Foundations"
},
{
"action": "Add UI Object",
"label": "Add Next Phase Portfolio Event",
"disableIfPropertyIsDefined": true,
"propertyToCheckFor": "nextPhasePMEvent",
"relatedUiObject": "Next Phase PM Event",
"actionFunction": "payload.executeAction",
"relatedUiObjectProject": "Foundations",
"actionProject": "Visual-Scripting"
},
{
"action": "Add UI Object",
"label": "Add Announcement",
@@ -40,6 +50,11 @@
"childType": "Situation",
"autoAdd": true
},
{
"name": "nextPhasePMEvent",
"type": "node",
"childType": "Next Phase PM Event"
},
{
"name": "announcements",
"type": "array",
@@ -0,0 +1,29 @@
{
"type": "Next Phase PM Event",
"menuItems": [
{
"action": "Delete UI Object",
"actionProject": "Visual-Scripting",
"askConfirmation": true,
"confirmationLabel": "Confirm to Delete",
"label": "Delete",
"iconPathOn": "delete-entity",
"iconPathOff": "delete-entity",
"actionFunction": "payload.executeAction"
}
],
"addLeftIcons": true,
"initialValues": {
"config": "{}"
},
"editors": {
"config": true
},
"level": 4,
"attachingRules": {
"compatibleTypes": "->Next Phase Event->"
},
"childrenNodesProperties": [
],
"propertyNameAtParent": "nextPhasePMEvent"
}
@@ -0,0 +1,29 @@
{
"type": "Order Rate PM Formula",
"menuItems": [
{
"action": "Delete UI Object",
"actionProject": "Visual-Scripting",
"askConfirmation": true,
"confirmationLabel": "Confirm to Delete",
"label": "Delete",
"iconPathOn": "delete-entity",
"iconPathOff": "delete-entity",
"actionFunction": "payload.executeAction"
}
],
"addLeftIcons": true,
"initialValues": {
"config": "{}"
},
"editors": {
"config": true
},
"level": 4,
"attachingRules": {
"compatibleTypes": "->Order Rate->"
},
"childrenNodesProperties": [
],
"propertyNameAtParent": "orderRatePMFormula"
}
@@ -11,6 +11,16 @@
"actionProject": "Visual-Scripting",
"relatedUiObjectProject": "Foundations"
},
{
"action": "Add UI Object",
"label": "Add Order Rate Portfolio Formula",
"disableIfPropertyIsDefined": true,
"propertyToCheckFor": "orderRatePMFormula",
"relatedUiObject": "Order Rate PM Formula",
"actionFunction": "payload.executeAction",
"relatedUiObjectProject": "Foundations",
"actionProject": "Visual-Scripting"
},
{
"action": "Delete UI Object",
"actionProject": "Visual-Scripting",
@@ -33,6 +43,11 @@
"type": "node",
"childType": "Formula",
"autoAdd": true
},
{
"name": "orderRatePMFormula",
"type": "node",
"childType": "Order Rate PM Formula"
}
],
"propertyNameAtParent": "orderRate"
@@ -23,7 +23,7 @@
"addLeftIcons": true,
"level": 3,
"attachingRules": {
"compatibleTypes": "->Task->"
"compatibleTypes": "->Portfolio Task->"
},
"childrenNodesProperties": [
{
@@ -24,7 +24,7 @@
{
"action": "Add UI Object",
"label": "Add Task Manager",
"relatedUiObject": "Task Manager",
"relatedUiObject": "Portfolio Task Manager",
"actionFunction": "payload.executeAction",
"actionProject": "Visual-Scripting",
"relatedUiObjectProject": "Foundations"
@@ -35,7 +35,7 @@
"askConfirmation": true,
"confirmationLabel": "Confirm to Proceed",
"workDoneLabel": "Done",
"relatedUiObject": "Task",
"relatedUiObject": "Portfolio Task",
"actionFunction": "payload.executeAction",
"relatedUiObjectProject": "Foundations"
},
@@ -66,9 +66,9 @@
"propertyNameAtParent": "portfolioMineTasks",
"childrenNodesProperties": [
{
"name": "taskManagers",
"name": "portfolioTaskManagers",
"type": "array",
"childType": "Task Manager",
"childType": "Portfolio Task Manager",
"monitorChildrenRunning": true
}
]
@@ -0,0 +1,58 @@
{
"type": "Portfolio Task Manager",
"menuItems": [
{
"action": "Run All Tasks",
"label": "Run All Tasks",
"askConfirmation": true,
"confirmationLabel": "Confirm to Run",
"workDoneLabel": "Run Request Sent",
"iconPathOn": "run",
"iconPathOff": "run",
"actionFunction": "payload.executeAction"
},
{
"action": "Stop All Tasks",
"label": "Stop All Tasks",
"askConfirmation": true,
"confirmationLabel": "Confirm to Stop",
"workDoneLabel": "Stop Request Sent",
"iconPathOn": "stop",
"iconPathOff": "stop",
"actionFunction": "payload.executeAction"
},
{
"action": "Add UI Object",
"label": "Add Portfolio Task",
"relatedUiObject": "Portfolio Task",
"actionFunction": "payload.executeAction",
"actionProject": "Visual-Scripting",
"relatedUiObjectProject": "Foundations"
},
{
"action": "Delete UI Object",
"actionProject": "Visual-Scripting",
"askConfirmation": true,
"confirmationLabel": "Confirm to Delete",
"label": "Delete",
"iconPathOn": "delete-entity",
"iconPathOff": "delete-entity",
"actionFunction": "payload.executeAction"
}
],
"addLeftIcons": true,
"level": 2,
"attachingRules": {
"compatibleTypes": "Portfolio Mine Tasks->"
},
"childrenNodesProperties": [
{
"name": "portfolioTasks",
"type": "array",
"childType": "Portfolio Task",
"autoAdd": false,
"monitorChildrenRunning": true
}
],
"propertyNameAtParent": "portfolioTaskManagers"
}
@@ -0,0 +1,95 @@
{
"type": "Portfolio Task",
"menuItems": [
{
"action": "Run Task",
"label": "Run",
"workingLabel": "Stop",
"workDoneLabel": "Task Running",
"workFailedLabel": "Task Cannot be Run",
"secondaryAction": "Stop Task",
"secondaryLabel": "Stop",
"secondaryWorkingLabel": "Stopping...",
"secondaryWorkDoneLabel": "Task Stopped",
"secondaryWorkFailedLabel": "Task Cannot be Stopped",
"secondaryIcon": "stop",
"iconPathOn": "run",
"iconPathOff": "run",
"actionFunction": "payload.executeAction"
},
{
"action": "Debug Task",
"label": "Debug",
"workingLabel": "Debugging",
"workDoneLabel": "Debug Request Sent",
"workFailedLabel": "Task Cannot be Debugged",
"iconPathOn": "status-dependency",
"iconPathOff": "status-dependency",
"actionFunction": "payload.executeAction"
},
{
"action": "Add UI Object",
"disableIfPropertyIsDefined": true,
"propertyToCheckFor": "bot",
"label": "Add Portfolio Bot Instance",
"relatedUiObject": "Portfolio Bot Instance",
"actionFunction": "payload.executeAction",
"actionProject": "Visual-Scripting",
"relatedUiObjectProject": "Foundations"
},
{
"action": "Add UI Object",
"disableIfPropertyIsDefined": true,
"propertyToCheckFor": "keyReference",
"label": "Add Key Reference",
"relatedUiObject": "Key Reference",
"actionFunction": "payload.executeAction",
"actionProject": "Visual-Scripting",
"relatedUiObjectProject": "Foundations"
},
{
"action": "Add UI Object",
"disableIfPropertyIsDefined": true,
"propertyToCheckFor": "managedTasks",
"label": "Add Managed Tasks",
"relatedUiObject": "Managed Tasks",
"actionFunction": "payload.executeAction",
"actionProject": "Visual-Scripting",
"relatedUiObjectProject": "Foundations"
},
{
"action": "Delete UI Object",
"actionProject": "Visual-Scripting",
"askConfirmation": true,
"confirmationLabel": "Confirm to Delete",
"label": "Delete",
"iconPathOn": "delete-entity",
"iconPathOff": "delete-entity",
"actionFunction": "payload.executeAction"
}
],
"isTitleAllwaysVisible": true,
"addLeftIcons": true,
"level": 0,
"attachingRules": {
"compatibleTypes": "->Portfolio Task Manager->"
},
"childrenNodesProperties": [
{
"name": "bot",
"type": "node",
"childType": "Portfolio Bot Instance"
},
{
"name": "keyReference",
"type": "node",
"childType": "Key Reference"
},
{
"name": "managedTasks",
"type": "node",
"childType": "Managed Tasks"
}
],
"propertyNameAtParent": "portfolioTasks"
}
@@ -9,6 +9,16 @@
"actionProject": "Visual-Scripting",
"relatedUiObjectProject": "Foundations"
},
{
"action": "Add UI Object",
"label": "Add Take Position Portfolio Event",
"disableIfPropertyIsDefined": true,
"propertyToCheckFor": "takePositionPMEvent",
"relatedUiObject": "Take Position PM Event",
"actionFunction": "payload.executeAction",
"relatedUiObjectProject": "Foundations",
"actionProject": "Visual-Scripting"
},
{
"action": "Add UI Object",
"label": "Add Announcement",
@@ -40,6 +50,11 @@
"childType": "Situation",
"autoAdd": true
},
{
"name": "takePositionPMEvent",
"type": "node",
"childType": "Take Position PM Event"
},
{
"name": "announcements",
"type": "array",
@@ -0,0 +1,29 @@
{
"type": "Take Position PM Event",
"menuItems": [
{
"action": "Delete UI Object",
"actionProject": "Visual-Scripting",
"askConfirmation": true,
"confirmationLabel": "Confirm to Delete",
"label": "Delete",
"iconPathOn": "delete-entity",
"iconPathOff": "delete-entity",
"actionFunction": "payload.executeAction"
}
],
"addLeftIcons": true,
"initialValues": {
"config": "{}"
},
"editors": {
"config": true
},
"level": 2,
"attachingRules": {
"compatibleTypes": "->Take Position Event->"
},
"childrenNodesProperties": [
],
"propertyNameAtParent": "takePositionPMEvent"
}
@@ -0,0 +1,29 @@
{
"type": "Target Rate PM Formula",
"menuItems": [
{
"action": "Delete UI Object",
"actionProject": "Visual-Scripting",
"askConfirmation": true,
"confirmationLabel": "Confirm to Delete",
"label": "Delete",
"iconPathOn": "delete-entity",
"iconPathOff": "delete-entity",
"actionFunction": "payload.executeAction"
}
],
"addLeftIcons": true,
"initialValues": {
"config": "{}"
},
"editors": {
"config": true
},
"level": 4,
"attachingRules": {
"compatibleTypes": "->Target Rate->"
},
"childrenNodesProperties": [
],
"propertyNameAtParent": "targetRatePMFormula"
}
@@ -11,6 +11,16 @@
"actionProject": "Visual-Scripting",
"relatedUiObjectProject": "Foundations"
},
{
"action": "Add UI Object",
"label": "Add Target Rate Portfolio Formula",
"disableIfPropertyIsDefined": true,
"propertyToCheckFor": "targetRatePMFormula",
"relatedUiObject": "Target Rate PM Formula",
"actionFunction": "payload.executeAction",
"relatedUiObjectProject": "Foundations",
"actionProject": "Visual-Scripting"
},
{
"action": "Delete UI Object",
"actionProject": "Visual-Scripting",
@@ -33,6 +43,11 @@
"type": "node",
"childType": "Formula",
"autoAdd": true
},
{
"name": "targetRatePMFormula",
"type": "node",
"childType": "Target Rate PM Formula"
}
],
"propertyNameAtParent": "targetRate"
@@ -0,0 +1,29 @@
{
"type": "Target Size In Base Asset PM Formula",
"menuItems": [
{
"action": "Delete UI Object",
"actionProject": "Visual-Scripting",
"askConfirmation": true,
"confirmationLabel": "Confirm to Delete",
"label": "Delete",
"iconPathOn": "delete-entity",
"iconPathOff": "delete-entity",
"actionFunction": "payload.executeAction"
}
],
"addLeftIcons": true,
"initialValues": {
"config": "{}"
},
"editors": {
"config": true
},
"level": 4,
"attachingRules": {
"compatibleTypes": "->Target Size In Base Asset->"
},
"childrenNodesProperties": [
],
"propertyNameAtParent": "targetSizeInBaseAssetPMFormula"
}
@@ -11,6 +11,16 @@
"actionProject": "Visual-Scripting",
"relatedUiObjectProject": "Foundations"
},
{
"action": "Add UI Object",
"label": "Add Target Base Size Portfolio Formula",
"disableIfPropertyIsDefined": true,
"propertyToCheckFor": "targetSizeInBaseAssetPMFormula",
"relatedUiObject": "Target Size In Base Asset PM Formula",
"actionFunction": "payload.executeAction",
"relatedUiObjectProject": "Foundations",
"actionProject": "Visual-Scripting"
},
{
"action": "Delete UI Object",
"actionProject": "Visual-Scripting",
@@ -33,6 +43,11 @@
"type": "node",
"childType": "Formula",
"autoAdd": true
},
{
"name": "targetSizeInBaseAssetPMFormula",
"type": "node",
"childType": "Target Size In Base Asset PM Formula"
}
],
"propertyNameAtParent": "targetSizeInBaseAsset"
@@ -0,0 +1,29 @@
{
"type": "Target Size In Quoted Asset PM Formula",
"menuItems": [
{
"action": "Delete UI Object",
"actionProject": "Visual-Scripting",
"askConfirmation": true,
"confirmationLabel": "Confirm to Delete",
"label": "Delete",
"iconPathOn": "delete-entity",
"iconPathOff": "delete-entity",
"actionFunction": "payload.executeAction"
}
],
"addLeftIcons": true,
"initialValues": {
"config": "{}"
},
"editors": {
"config": true
},
"level": 4,
"attachingRules": {
"compatibleTypes": "->Target Size In Quoted Asset->"
},
"childrenNodesProperties": [
],
"propertyNameAtParent": "targetSizeInQuotedAssetPMFormula"
}
@@ -11,6 +11,16 @@
"actionProject": "Visual-Scripting",
"relatedUiObjectProject": "Foundations"
},
{
"action": "Add UI Object",
"label": "Add Target Quoted Size Portfolio Formula",
"disableIfPropertyIsDefined": true,
"propertyToCheckFor": "targetSizeInQuotedAssetPMFormula",
"relatedUiObject": "Target Size In Quoted Asset PM Formula",
"actionFunction": "payload.executeAction",
"relatedUiObjectProject": "Foundations",
"actionProject": "Visual-Scripting"
},
{
"action": "Delete UI Object",
"actionProject": "Visual-Scripting",
@@ -33,6 +43,11 @@
"type": "node",
"childType": "Formula",
"autoAdd": true
},
{
"name": "targetSizeInQuotedAssetPMFormula",
"type": "node",
"childType": "Target Size In Quoted Asset PM Formula"
}
],
"propertyNameAtParent": "targetSizeInQuotedAsset"
@@ -67,16 +67,6 @@
"actionProject": "Visual-Scripting",
"relatedUiObjectProject": "Foundations"
},
{
"action": "Add UI Object",
"disableIfPropertyIsDefined": true,
"propertyToCheckFor": "bot",
"label": "Add Portfolio Bot Instance",
"relatedUiObject": "Portfolio Bot Instance",
"actionFunction": "payload.executeAction",
"actionProject": "Visual-Scripting",
"relatedUiObjectProject": "Foundations"
},
{
"action": "Add UI Object",
"disableIfPropertyIsDefined": true,
@@ -97,16 +87,6 @@
"actionProject": "Visual-Scripting",
"relatedUiObjectProject": "Foundations"
},
{
"action": "Add UI Object",
"disableIfPropertyIsDefined": true,
"propertyToCheckFor": "managedTasks",
"label": "Add Managed Tasks",
"relatedUiObject": "Managed Tasks",
"actionFunction": "payload.executeAction",
"actionProject": "Visual-Scripting",
"relatedUiObjectProject": "Foundations"
},
{
"action": "Delete UI Object",
"actionProject": "Visual-Scripting",
@@ -130,11 +110,6 @@
"type": "node",
"childType": "Trading Bot Instance"
},
{
"name": "bot",
"type": "node",
"childType": "Portfolio Bot Instance"
},
{
"name": "bot",
"type": "node",
@@ -159,11 +134,6 @@
"name": "keyReference",
"type": "node",
"childType": "Key Reference"
},
{
"name": "managedTasks",
"type": "node",
"childType": "Managed Tasks"
}
],
"propertyNameAtParent": "tasks"
@@ -35,6 +35,11 @@
"type": "node",
"childType": "Trading Session Reference"
},
{
"name": "portfolioSessionReferences",
"type": "node",
"childType": "Portfolio Session Reference"
},
{
"name": "timeMachines",
"type": "node",
@@ -20,7 +20,7 @@
"compatibleTypes": "->Template Script->"
},
"referencingRules": {
"compatibleTypes": "->Dashboard->Data Mines Data->Trading Mines Data->Data Tasks->Testing Trading Tasks->Production Trading Tasks->"
"compatibleTypes": "->Dashboard->Data Mines Data->Trading Mines Data->Data Tasks->Testing Trading Tasks->Production Trading Tasks->Portfolio Mines Data->Production Portfolio Tasks->"
},
"childrenNodesProperties": []
}
@@ -9,6 +9,16 @@
"actionProject": "Visual-Scripting",
"relatedUiObjectProject": "Foundations"
},
{
"action": "Add UI Object",
"actionProject": "Visual-Scripting",
"disableIfPropertyIsDefined": true,
"propertyToCheckFor": "socialTradingBotReference",
"actionFunction": "payload.executeAction",
"label": "Add Social Trading Bot Reference",
"relatedUiObject": "Social Trading Bot Reference",
"relatedUiObjectProject": "Governance"
},
{
"action": "Delete UI Object",
"actionProject": "Visual-Scripting",
@@ -31,6 +41,12 @@
"type": "array",
"childType": "Trading Process Instance",
"autoAdd": false
},
{
"name": "socialTradingBotReference",
"type": "node",
"childType": "Social Trading Bot Reference",
"autoAdd": false
}
],
"propertyNameAtParent": "bot"
@@ -3,7 +3,7 @@
"menuItems": [
{
"action": "Delete UI Object",
"actionProject": "Visual-Scripting",
"actionProject": "Visual-Scripting",
"askConfirmation": true,
"confirmationLabel": "Confirm to Delete",
"label": "Delete",
@@ -9,6 +9,16 @@
"actionProject": "Visual-Scripting",
"relatedUiObjectProject": "Foundations"
},
{
"action": "Add UI Object",
"label": "Add Trigger Off Portfolio Event",
"disableIfPropertyIsDefined": true,
"propertyToCheckFor": "triggerOffPMEvent",
"relatedUiObject": "Trigger Off PM Event",
"actionFunction": "payload.executeAction",
"relatedUiObjectProject": "Foundations",
"actionProject": "Visual-Scripting"
},
{
"action": "Add UI Object",
"label": "Add Announcement",
@@ -40,6 +50,11 @@
"childType": "Situation",
"autoAdd": true
},
{
"name": "triggerOffPMEvent",
"type": "node",
"childType": "Trigger Off PM Event"
},
{
"name": "announcements",
"type": "array",
@@ -0,0 +1,29 @@
{
"type": "Trigger Off PM Event",
"menuItems": [
{
"action": "Delete UI Object",
"actionProject": "Visual-Scripting",
"askConfirmation": true,
"confirmationLabel": "Confirm to Delete",
"label": "Delete",
"iconPathOn": "delete-entity",
"iconPathOff": "delete-entity",
"actionFunction": "payload.executeAction"
}
],
"addLeftIcons": true,
"initialValues": {
"config": "{}"
},
"editors": {
"config": true
},
"level": 2,
"attachingRules": {
"compatibleTypes": "->Trigger Off Event->"
},
"childrenNodesProperties": [
],
"propertyNameAtParent": "triggerOffPMEvent"
}
@@ -9,6 +9,16 @@
"actionProject": "Visual-Scripting",
"relatedUiObjectProject": "Foundations"
},
{
"action": "Add UI Object",
"label": "Add Trigger On Portfolio Event",
"disableIfPropertyIsDefined": true,
"propertyToCheckFor": "triggerOnPMEvent",
"relatedUiObject": "Trigger On PM Event",
"actionFunction": "payload.executeAction",
"relatedUiObjectProject": "Foundations",
"actionProject": "Visual-Scripting"
},
{
"action": "Add UI Object",
"label": "Add Announcement",
@@ -40,6 +50,11 @@
"childType": "Situation",
"autoAdd": true
},
{
"name": "triggerOnPMEvent",
"type": "node",
"childType": "Trigger On PM Event"
},
{
"name": "announcements",
"type": "array",
@@ -0,0 +1,29 @@
{
"type": "Trigger On PM Event",
"menuItems": [
{
"action": "Delete UI Object",
"actionProject": "Visual-Scripting",
"askConfirmation": true,
"confirmationLabel": "Confirm to Delete",
"label": "Delete",
"iconPathOn": "delete-entity",
"iconPathOff": "delete-entity",
"actionFunction": "payload.executeAction"
}
],
"addLeftIcons": true,
"initialValues": {
"config": "{}"
},
"editors": {
"config": true
},
"level": 2,
"attachingRules": {
"compatibleTypes": "->Trigger On Event->"
},
"childrenNodesProperties": [
],
"propertyNameAtParent": "triggerOnPMEvent"
}
@@ -39,6 +39,13 @@
"actionFunction": "payload.executeAction",
"relatedUiObjectProject": "Foundations"
},
{
"action": "Add Specified Workspace Project",
"label": "Add Specified Workspace Project",
"relatedUiObject": "Workspace",
"actionFunction": "payload.executeAction",
"relatedUiObjectProject": "Foundations"
},
{
"action": "Check For Missing References",
"label": "Check For Missing References",
@@ -58,7 +65,8 @@
"config": "{\"docsLanguage\": \"EN\"}"
},
"editors": {
"config": true
"config": true,
"list": true
},
"isTitleAllwaysVisible": true,
"addLeftIcons": false,
@@ -138,6 +138,11 @@
"style": "Chapter",
"text": "XI->Foundations->Tutorial->Setting Up a New Chart->This tutorial walks through the basic inner workings of the Charting Space to help you learn how to create your own custom charts.",
"updated": 1621991930816
},
{
"style": "Chapter",
"text": "XII->Governance->Tutorial->Creating Your User Profile Tutorial->This tutorial covers everything you need to know about adding a user profile within the Superalgos Governance system.",
"updated": 1637591853047
}
]
}
@@ -102,12 +102,8 @@
},
{
"style": "Chapter",
"text": "XVII->Foundations->Topic->Contributing to Foundations->Superalgos is a Community project. Everything you build with Superalgos is susceptible to be contributed to the project. Contributing to the project earns you Superalgos (SA) tokens! This chapter covers how you may contribute some of the intelligence you build for yourself, and also how you may get involved with the project at a deeper level.",
"text": "XVII->Foundations->Topic->Contributing to Superalgos->Superalgos is a Community project. Everything you build with Superalgos is susceptible to be contributed to the project. Contributing to the project earns you Superalgos (SA) tokens! This chapter covers how you may contribute some of the intelligence you build for yourself, and also how you may get involved with the project at a deeper level.",
"updated": 1617708229948
},
{
"style": "Text",
"text": ""
}
]
}
@@ -216,6 +216,14 @@
}
]
},
{
"style": "Subtitle",
"text": "Token Distrabution Superalgos"
},
{
"style": "List",
"text": "Creating Your User Profile Tutorial"
},
{
"style": "Text",
"text": ""
@@ -2,13 +2,27 @@
"type": "Node JS Javsacript",
"definition": {
"text": "A Task in Superalgos runs in Node JS, which means that the Conditions and Formulas you write at your Trading System must comply with Javascript for Node JS syntax. ",
"updated": 1611323749488
"updated": 1611323749488,
"translations": [
{
"language": "DE",
"text": "Eine Task in Superalgos läuft in Node JS, was bedeutet, dass die Bedingungen und Formeln, die Sie in Ihrem Trading System schreiben, der Syntax von Javascript für Node JS entsprechen müssen.",
"updated": 1637416496544
}
]
},
"paragraphs": [
{
"style": "Text",
"text": "The same is true for properties values in configs. They need to be valid data types of Javascript for Node JS.",
"updated": 1611323797820
"updated": 1611323797820,
"translations": [
{
"language": "DE",
"text": "Das Gleiche gilt für propertie values in den Configs. Sie müssen gültige Datentypen von Javascript für Node JS sein.",
"updated": 1637416588142
}
]
}
]
}
@@ -1,8 +1,8 @@
{
"type": "Superalgos Project",
"definition": {
"text": "The Superalgos Project is the open Community, together with it's body of work.",
"updated": 1630235520885
"text": "The Superalgos Project is the open Community, together with its body of work.",
"updated": 1637684804458
},
"paragraphs": [
{
@@ -2,22 +2,50 @@
"type": "API Endpoint",
"definition": {
"text": "Endpoints are important aspects of interacting with server-side web APIs, as they specify where resources can be accessed. Usually the access is via a URL to which HTTP requests are posted. Once these requests are posted correctly, the API will respond with the requested data.",
"updated": 1622854645690
"updated": 1622854645690,
"translations": [
{
"language": "DE",
"text": "Endpoints sind wichtige Aspekte der Interaktion mit serverseitigen Web-APIs, da sie angeben, wo auf Ressourcen zugegriffen werden kann. Normalerweise erfolgt der Zugriff über eine URL, an die HTTP-Anforderungen gesendet werden. Sobald diese Anfragen korrekt übermittelt wurden, antwortet die API mit den angeforderten Daten.",
"updated": 1637406311302
}
]
},
"paragraphs": [
{
"style": "Subtitle",
"text": "How to Use an Endpoint Node",
"updated": 1622854703461
"updated": 1622854703461,
"translations": [
{
"language": "DE",
"text": "So verwenden sie Endpoint Node`s:",
"updated": 1637406356154
}
]
},
{
"style": "Text",
"text": "Read the docs of the API you are trying to map, and identify which endpoints they support. From there you can choose which endpoint holds the information you are interested in and begin to map it. For a detailed description of how to do this, please read the following description. In addition please see the API Map page as well as the Data Mining topic for other important concepts surrounding setting up an api map. ",
"updated": 1622855071509
"updated": 1622855071509,
"translations": [
{
"language": "DE",
"text": "Lesen Sie die Dokumentation der API, die Sie abbilden möchten, und stellen Sie fest, welche endpoints sie unterstützt. Von dort aus können Sie wählen, welcher Endpunkt die Informationen enthält, an denen Sie interessiert sind, und damit beginnen, diese zuzuordnen (mapping). Eine detaillierte Beschreibung der Vorgehensweise finden Sie in der folgenden Beschreibung. Darüber hinaus finden Sie auf der Seite API-Map und im Data Mining topic weitere wichtige Konzepte zur Einrichtung einer API-Map.",
"updated": 1637406471296
}
]
},
{
"style": "Note",
"text": "The first page of the Data Mining topic is Data Mining - Introduction."
"text": "The first page of the Data Mining topic is Data Mining - Introduction.",
"translations": [
{
"language": "DE",
"text": "Die erste Seite des Themas Data Mining lautet: Data Mining - Introduction.",
"updated": 1637406539017
}
]
},
{
"style": "Include",
@@ -27,15 +55,36 @@
{
"style": "Title",
"text": "API Endpoint Configuration",
"updated": 1622895671396
"updated": 1622895671396,
"translations": [
{
"language": "DE",
"text": "API Endpoint Konfiguration",
"updated": 1637406560957
}
]
},
{
"style": "Subtitle",
"text": "Properties"
"text": "Properties",
"translations": [
{
"language": "DE",
"text": "Properties/Eigenschaften:",
"updated": 1637406584743
}
]
},
{
"style": "List",
"text": "codeName: Define the endpoint this branch of the map will handle."
"text": "codeName: Define the endpoint this branch of the map will handle.",
"translations": [
{
"language": "DE",
"text": "codeName: Definieren Sie den endpoint, den dieser branch der Map behandeln soll.",
"updated": 1637406633445
}
]
}
]
}
@@ -8,6 +8,11 @@
"language": "ES",
"text": "Un API Map representa el mapeo de una API para que pueda ser consumida por bots dentro de Superalgos. API Maps Son creados por los usuarios y compartidos como Plugins para que cualquier otro miembro de la comunidad pueda usarlos con sus bots.",
"updated": 1628046227514
},
{
"language": "DE",
"text": "Eine API-Map stellt das Mapping einer API dar, so dass sie von Bots innerhalb von Superalgos genutzt werden kann. API Maps werden von Nutzern erstellt und als Plugins geteilt, so dass jedes andere Community-Mitglied sie mit seinen Bots nutzen kann.",
"updated": 1637407347172
}
]
},
@@ -15,40 +20,96 @@
{
"style": "Text",
"text": "The way to create an API Map is to read the API's documentation for each endpoint as well as the Data Mining Topic. These sources will provide you with all the information you need to make a successful API Map.",
"updated": 1622847308932
"updated": 1622847308932,
"translations": [
{
"language": "DE",
"text": "Um eine API-Map zu erstellen, sollten Sie die API-Dokumentation für jeden Endpunkt sowie das Data Mining Topic lesen. Diese Quellen liefern Ihnen alle Informationen, die Sie für die Erstellung einer erfolgreichen API-Map benötigen.",
"updated": 1637407413755
}
]
},
{
"style": "Text",
"text": "The basic way you can think about an API Map is as a representation of the URL link needed to request information from the API as well as the layout of the data returned by the API. This means that an API Map hold all the information needed to request data and decipher the data once it is returned.",
"updated": 1622847337343
"updated": 1622847337343,
"translations": [
{
"language": "DE",
"text": "Grundsätzlich kann man sich eine API-Map als eine Darstellung des URL-Links vorstellen, der für die Anforderung (request) von Informationen von der API benötigt wird, sowie als das Layout der von der API zurückgegebenen Daten. Das bedeutet, dass eine API-Map alle Informationen enthält, die zum Anfordern von Daten und zum Entschlüsseln der zurückgegebenen Daten erforderlich sind.",
"updated": 1637407595202
}
]
},
{
"style": "Title",
"text": "How are API Maps used?",
"updated": 1622847013897
"updated": 1622847013897,
"translations": [
{
"language": "DE",
"text": "Wie werden API Maps verwendet?",
"updated": 1637407620683
}
]
},
{
"style": "Text",
"text": "API Maps are used by API Data Fetcher Bots to request and save the data from an API. In order to do this a user needs to set up a task to run the bot. This set up is done automatically as part of the Install Market procedure if both an API Map and its data mine is detected within the Worksapce. From within that Task, a reference to the API Map is established.",
"updated": 1622847596702
"updated": 1622847596702,
"translations": [
{
"language": "DE",
"text": "API Maps werden von API Data Fetcher Bots verwendet, um Daten von einer API anzufordern und zu speichern. Dazu muss der Benutzer eine Task zur Ausführung des Bots einrichten. Diese Einrichtung erfolgt automatisch als Teil des Install Market-Verfahrens, wenn sowohl eine API Map als auch die zugehörige Datamine im Workspace erkannt werden. In dieser Task wird ein Verweis (reference) auf die API-Map eingerichtet.",
"updated": 1637407784736
}
]
},
{
"style": "Text",
"text": "When the Task is run, the UI will send to the Task Server all the definitions inside the API Map so that the API Data Fetcher Bot can use them to connect to the API Server, fetch data from it, and correctly interpret the responses."
"text": "When the Task is run, the UI will send to the Task Server all the definitions inside the API Map so that the API Data Fetcher Bot can use them to connect to the API Server, fetch data from it, and correctly interpret the responses.",
"translations": [
{
"language": "DE",
"text": "When the Task is run, the UI will send to the Task Server all the definitions inside the API Map so that the API Data Fetcher Bot can use them to connect to the API Server, fetch data from it, and correctly interpret the responses. Wenn die Task ausgeführt wird, sendet die UI (Benutzeroberfläche) alle Definitionen in der API Map an den Task Server, damit der API Data Fetcher Bot sie verwenden kann, um eine Verbindung zum API Server herzustellen, Daten von ihm abzurufen und die Antworten korrekt zu interpretieren.",
"updated": 1637407893809
}
]
},
{
"style": "Title",
"text": "How to Read an API Request URL",
"updated": 1622847733042
"updated": 1622847733042,
"translations": [
{
"language": "DE",
"text": "Wie man eine \"API Request URL\" liest:",
"updated": 1637407947758
}
]
},
{
"style": "Text",
"text": "The API you are trying to map should have it's API Endpoints documented. If not, check any examples they may provide for how to request the data and see if there are inner folders below the main folder of the API Enpoint. Each one of these folders are an API Path Parameter that needs to be defined.",
"updated": 1622847657548
"updated": 1622847657548,
"translations": [
{
"language": "DE",
"text": "Die API, die Sie abbilden (mappen) möchten, sollte über eine Dokumentation ihrer API Endpoints verfügen. Wenn dies nicht der Fall ist, prüfen Sie alle Beispiele, die sie für die Abfrage der Daten bereitstellen, und sehen Sie nach, ob es innere Ordner unterhalb des Hauptordners des API Endpoints gibt. Jeder dieser Ordner ist ein API Path Parameter, der definiert werden muss.",
"updated": 1637408139914
}
]
},
{
"style": "Text",
"text": "Here are some examples of API request URLs:"
"text": "Here are some examples of API request URLs:",
"translations": [
{
"language": "DE",
"text": "Hier sind einige Beispiele für API request URLs:",
"updated": 1637408182777
}
]
},
{
"style": "Javascript",
@@ -61,15 +122,37 @@
},
{
"style": "Subtitle",
"text": "Sections of an API Request URL"
"text": "Sections of an API Request URL",
"translations": [
{
"language": "DE",
"text": "Abschnitte einer API Request URL:",
"updated": 1637408214715
}
]
},
{
"style": "Text",
"text": "Let's break down one of these URLs and identify each part of it."
"text": "Let's break down one of these URLs and identify each part of it.",
"translations": [
{
"language": "DE",
"text": "Lassen Sie uns eine dieser URLs aufschlüsseln und jeden Teil davon identifizieren.",
"updated": 1637408255353
}
]
},
{
"style": "List",
"text": "Internet Protocol: This is the section on the very front of almost any internet link you will see."
"text": "Internet Protocol: This is the section at the beginning of almost any internet link you will see.",
"updated": 1637408357293,
"translations": [
{
"language": "DE",
"text": "Internet Protocol: Dieser Teil steht am Anfang fast jedes Internet-Links, den Sie sehen werden.",
"updated": 1637408455485
}
]
},
{
"style": "Javascript",
@@ -78,11 +161,25 @@
{
"style": "Note",
"text": "You define this using the protocol config property in the main API Map node.",
"updated": 1622847750228
"updated": 1622847750228,
"translations": [
{
"language": "DE",
"text": "Sie definieren dies über die Eigenschaft protocol config in der main API Map node.",
"updated": 1637408526085
}
]
},
{
"style": "List",
"text": "Root Domain Name: This is the section of the URL that is before the first backslash:"
"text": "Root Domain Name: This is the section of the URL that is before the first backslash:",
"translations": [
{
"language": "DE",
"text": "Root Domain Name: Dies ist der Teil der URL, der vor dem ersten Backslash steht:",
"updated": 1637408573940
}
]
},
{
"style": "Javascript",
@@ -91,11 +188,25 @@
{
"style": "Note",
"text": "You define this using the hostName config property in the main API Map node.",
"updated": 1622847770913
"updated": 1622847770913,
"translations": [
{
"language": "DE",
"text": "Sie definieren dies über die hostName config property in der main API Map node.",
"updated": 1637408669762
}
]
},
{
"style": "List",
"text": "API Path: This is the section that defines the main path to the API:"
"text": "API Path: This is the section that defines the main path to the API:",
"translations": [
{
"language": "DE",
"text": "API Path: Dies ist der Abschnitt, der den Hauptpfad zur API definiert:",
"updated": 1637408725011
}
]
},
{
"style": "Javascript",
@@ -104,25 +215,60 @@
{
"style": "Note",
"text": "You define this using the path config property in the main API Map node.",
"updated": 1622847800732
"updated": 1622847800732,
"translations": [
{
"language": "DE",
"text": "Sie definieren dies über die path config property in der main API Map node.",
"updated": 1637408876286
}
]
},
{
"style": "List",
"text": "API Version Number: This is the section that defines the API version to which you are making requests."
"text": "API Version Number: This is the section that defines the API version to which you are making requests.",
"translations": [
{
"language": "DE",
"text": "API Version Number: In diesem Abschnitt wird die API-Version definiert, an die Sie Anfragen stellen.",
"updated": 1637408824379
}
]
},
{
"style": "Javascript",
"text": " v1"
"text": " v1",
"translations": [
{
"language": "DE",
"text": "v1",
"updated": 1637408808732
}
]
},
{
"style": "Note",
"text": "You define this using the codeName config property in the API Version node.",
"updated": 1622847982153
"updated": 1622847982153,
"translations": [
{
"language": "DE",
"text": "Hinweis: Sie definieren dies über die codeName config property in der API Version node.",
"updated": 1637408939849
}
]
},
{
"style": "List",
"text": "API Endpoint: This is the section that tells the API what kind of data you wish to request.",
"updated": 1622847877226
"updated": 1622847877226,
"translations": [
{
"language": "DE",
"text": "API Endpoint: In diesem Abschnitt wird der API mitgeteilt, welche Art von Daten Sie anfordern möchten.",
"updated": 1637414433995
}
]
},
{
"style": "Javascript",
@@ -131,12 +277,26 @@
{
"style": "Note",
"text": "You define this using the config codeName property of the API Endpoint node.",
"updated": 1622847959761
"updated": 1622847959761,
"translations": [
{
"language": "DE",
"text": "Sie definieren dies über die config codeName property des API-Endpoint node.",
"updated": 1637414475525
}
]
},
{
"style": "List",
"text": "Path Parameters: These are the remaning sections of the path before the question mark they further narrow down what data you wish to request from the API. In this case we want to receive data about bitcoin:",
"updated": 1622848189591
"updated": 1622848189591,
"translations": [
{
"language": "DE",
"text": "Path Parameters: Dies sind die verbleibenden Abschnitte des Pfads vor dem Fragezeichen. Sie grenzen die Daten, die Sie von der API anfordern möchten, weiter ein. In diesem Fall möchten wir Daten über Bitcoin erhalten:",
"updated": 1637414552491
}
]
},
{
"style": "Javascript",
@@ -145,12 +305,26 @@
{
"style": "Note",
"text": "You define each of these using the codeName config property in the API Path Parameter node.",
"updated": 1622848212517
"updated": 1622848212517,
"translations": [
{
"language": "DE",
"text": "Sie definieren jedes dieser Elemente über die codeName config property in der API Path Parameter node.",
"updated": 1637414615962
}
]
},
{
"style": "List",
"text": "Query Parameters: These are all the sections after the question mark. They are often used to pair down the amount of data returned by the API so that you only receive what you are interested in:",
"updated": 1622848284105
"updated": 1622848284105,
"translations": [
{
"language": "DE",
"text": "Query Parameters: Dies sind alle Abschnitte nach dem Fragezeichen. Sie werden häufig verwendet, um die von der API zurückgegebene Datenmenge zu reduzieren, damit Sie nur die Daten erhalten, an denen Sie interessiert sind:",
"updated": 1637414650342
}
]
},
{
"style": "Javascript",
@@ -158,7 +332,14 @@
},
{
"style": "Note",
"text": "You define these using the codeName and value config properties of the API Query Parameter node."
"text": "You define these using the codeName and value config properties of the API Query Parameter node.",
"translations": [
{
"language": "DE",
"text": "Sie definieren diese über die codeName und value config property der API Query Parameter node.",
"updated": 1637414687252
}
]
},
{
"style": "Include",
@@ -173,7 +354,14 @@
{
"style": "Title",
"text": "API Map Configuration",
"updated": 1622895474056
"updated": 1622895474056,
"translations": [
{
"language": "DE",
"text": "API Map Konfiguration:",
"updated": 1637414725997
}
]
},
{
"style": "Subtitle",
@@ -182,36 +370,85 @@
{
"style": "List",
"text": "codeName: this must be the same codename as the Data Mine codename in order for the Install New Market procedure to link them properly at the API Map Reference node.",
"updated": 1622895563618
"updated": 1622895563618,
"translations": [
{
"language": "DE",
"text": "Dies muss derselbe Codename sein wie der Codename der Data Mine, damit die Prozedur Install New Market sie ordnungsgemäß mit der API Map Reference node verknüpfen kann.",
"updated": 1637414868207
}
]
},
{
"style": "List",
"text": "protocol: the protocol to be used to access the API. For now either http or https.",
"updated": 1622895574503
"updated": 1622895574503,
"translations": [
{
"language": "DE",
"text": "protocol: das Protokoll, das für den Zugriff auf die API verwendet werden soll. Im Moment entweder http oder https.",
"updated": 1637415023731
}
]
},
{
"style": "List",
"text": "portNumber: the port at which the API server is listening.",
"updated": 1622895581034
"updated": 1622895581034,
"translations": [
{
"language": "DE",
"text": "portNumber: der Port, an dem der API-Server lauscht.",
"updated": 1637415047128
}
]
},
{
"style": "List",
"text": "hostName: the domain name or IP address of the API server.",
"updated": 1622895586641
"updated": 1622895586641,
"translations": [
{
"language": "DE",
"text": "hostName: der Domain Name oder die IP-Adresse des API Servers.",
"updated": 1637415198987
}
]
},
{
"style": "List",
"text": "path: the URL path to where the API is located within the remote server.",
"updated": 1622895592146
"updated": 1622895592146,
"translations": [
{
"language": "DE",
"text": "path: der URL Pfad zu dem Ort, an dem sich die API auf dem entfernten Server befindet.",
"updated": 1637415193838
}
]
},
{
"style": "List",
"text": "millisecondsBetweenCalls: [Optional] the number of milliseconds to wait before calling the remote host. This is particuary useful if there is pagination, so that there is a delay before requesting each page.",
"updated": 1622863477228
"updated": 1622863477228,
"translations": [
{
"language": "DE",
"text": "millisecondsBetweenCalls: [Optional] Die Anzahl der Millisekunden, die vor dem Aufruf des entfernten Hosts gewartet wird. Dies ist besonders nützlich, wenn es eine Paginierung gibt, so dass es eine Verzögerung gibt, bevor jede Seite angefordert wird.",
"updated": 1637415663997
}
]
},
{
"style": "Text",
"text": "Here is an example API Map config:"
"text": "Here is an example API Map config:",
"translations": [
{
"language": "DE",
"text": "Hier ein Beispiel für eine API Map config:",
"updated": 1637415687389
}
]
},
{
"style": "Json",
@@ -7,6 +7,11 @@
"language": "ES",
"text": "El close stage se ocupa de las definiciones que componen la lógica para cerrar una posición, incluida la tasa y el tamaño objetivo, y la ejecución de la orden.",
"updated": 1624460574874
},
{
"language": "RU",
"text": "Статия закрытия имеет дело с определениями, которые составляют логику закрытия позиции, включая целевую ставку и размер, а также исполнение ордера.",
"updated": 1637757567864
}
]
},
@@ -7,6 +7,11 @@
"language": "ES",
"text": "Conditions son reglas dentro de una situación. Cuando todas las condiciones de una situación se validan como verdaderas, la situación también se valida y se activa el evento asociado.",
"updated": 1624459710047
},
{
"language": "RU",
"text": "Условия - это правила внутри ситуации. Когда все условия в ситуации проверяются на истинность, ситуация также проверяется, и запускается соответствующее событие.\n",
"updated": 1637756827569
}
]
},
Loaded 100 of 293 files, more files were not shown because too many files have changed in this diff. Show more