Global

Type Definitions


Acl

Type:
  • object
Properties:
Name Type Description
group AclGroup

Group Access Control List

owner string

User ID of owner of portfolio

user AclGroup

What's this for?

Source:

AclGroup

Type:
  • object
Properties:
Name Type Description
editors Array.<string>

Array of user ids of editors

portfolioAdmins Array.<string>

Array of user ids of portfolio administrators

viewers Array.<string>

Array of user ids of viewers

Source:

CategoryConfig

Type:
  • object
Properties:
Name Type Description
AppliesTo string
IsMultiSelect boolean
CategoryName string

e.g. Region

CategoryEntries array.<string>

e.g US, Asia, Europe

Source:

CategoryConfigPromise

Type:
  • Promise
Source:

CategoryConfigPromiseCallbackError(message)

This callback is called when the categoriesConfigFor response fails

Parameters:
Name Type Description
message string

base64 encoded error message

Source:

CategoryConfigPromiseCallbackSuccess(categoryConfigs)

This callback is called when the categoriesConfigFor response succeeds

Parameters:
Name Type Description
categoryConfigs Array.<CategoryConfig>

array of CategoryConfig objectsj

Source:

CategoryConfigSavePromise

Type:
  • Promise
Source:

CategoryConfigSavePromiseCallbackSuccess(statusMessage)

This callback is called when the saveCategoryConfig response succeeds

Parameters:
Name Type Description
statusMessage string

status of saveCategoryConfig ( new or existing )

Source:

CompareUncData

Type:
  • object
Properties:
Name Type Description
highlightedNode Array.<Array.<CompareUncOutputData>>

This is a nested array. First, it has as many elements as there are children. Each element is an array of outputs, one for each Tornado ValueMetricKey.

siblingNode Array.<Array.<CompareUncOutputData>>

This is a nested array. First, it has as many elements as there are children. Each element is an array of outputs, one for each Tornado ValueMetricKey. An empty array is returned if no sibling has been selected.

nodeName string

Node name of highlighted node

shadowNodeName string

Node name of sibling node. This is null if no sibling has been selected.

Source:

CompareUncOutputData

Type:
  • object
Properties:
Name Type Description
Display string

Full display describing the output

Units string

Units of the output

Mean number

The mean value of the combined uncertainty bar of this output in the Tornado

NodeName string

Name of the child

Summary Array.<number>

The low (0), medium (1) and high (2) values of this output based on the combined uncertainty bar in the Tornado.

Source:

CompareValueChildData

Type:
  • object
Properties:
Name Type Description
childLeafNames Array.<string>

A list of names of all children immediately below the selected node

compareValueData Array.<object>

A list of values of all children immediately below the selected node. The values are picked from the template (portfolio or platformPortfolio) based on the Keys parameter (an array of output keys) for the COMPARE_VALUE command.

nodeName string

Name of the selected node

Source:

CompareValueData

Type:
  • object
Properties:
Name Type Description
commandJSON object

This has attributes that setup the chart display

highlightedNode CompareValueChildData

This is the appropriate value data in the node that has been selected

siblingNode CompareValueChildData

This is the appropriate value data in the sibling node that has been selected. It will be null if no sibling has been selected.

Source:

DeleteUserPromise

Type:
  • Promise
Source:

DeleteUserPromiseCallbackError(message)

This callback is called when the DeleteUserPromise
response fails

Parameters:
Name Type Description
message string

plaintext message

Source:

DeleteUserPromiseCallbackSuccess(message)

This callback is called when the DeleteUserPromise
response succeeds

Parameters:
Name Type Description
message string

plaintext message

Source:

Input

Type:
  • object
Properties:
Name Type Description
Key string

The key of this input

Type string

The type of this input (SCALAR|DISTRIBUTION|TABLE)

Units string

The units of this input

Display string

The display prompt of this input

Description string

The description of this input

Constraint string

The constraint placed on this input (double|integer|year|date|text)

Val string

The value of this input

Inherited boolean

Is this an inherited input (shared variable)?

InputType string

Is this data local to the node or overridden? (LOCAL|OVERRIDE)

isLeaf number

If this node is a leaf, this is set to 1 otherwise 0

CellLink string

The link to the Excel cell

Source:

InputKeyValPair

Type:
  • object
Properties:
Name Type Description
Key string

the key of the input, eg startYear or discountRate

Val string

the value of the input eg 0.89

Source:

ListUserPromise

Type:
  • Promise
Source:

ListUserPromiseCallbackError(message)

This callback is called when the ListUserPromise
response fails

Parameters:
Name Type Description
message string

plaintext message

Source:

ListUserPromiseCallbackSuccess(userlist)

This callback is called when the ListUserPromise
response succeeds

Parameters:
Name Type Description
userlist Array.<object>

List of user objects.

Source:

Type:
  • object
Properties:
Name Type Description
nodeAttribute string

This has identifiers like "r" or "rw" to specify if this node is editable.

nodeID string

The node for which the inputs have been fetched

inputs Array.<Input>

The inputs that have been found

selectedInputKey string

what is this?

targetDS string

The dataset ID. Why is it called "target"?

templateID string

The ID of the template associated with this node

user string

The name of the user who has made the request

Source:

Type:
  • object
Properties:
Name Type Description
Command string

The command to be invoked by this action

displayText string

The display for this menu item

menuID string

The unique key for this menu item

nodeID string

The node ID for from this menu item has been fetched

isOutput boolean

Is this command an output command? TABLE_INPUT and INPUT_SCREEN are input commands, and all else are output commands.

level number

What is this?

parameters object

These specify what needs to go into the command. They differ based on the command.

A string

Legacy Javascript code injection. Ignore when writing your applications.

Source:

ModifyUserPromise

Type:
  • Promise
Source:

ModifyUserPromiseCallbackError(message)

This callback is called when the ModifyUserPromise
response fails

Parameters:
Name Type Description
message string

plaintext message

Source:

ModifyUserPromiseCallbackSuccess(message)

This callback is called when the ModifyUserPromise
response succeeds

Parameters:
Name Type Description
message string

plaintext message

Source:

NewUserPromise

Type:
  • Promise
Source:

NewUserPromiseCallbackError(message)

This callback is called when the NewUserPromise
response fails

Parameters:
Name Type Description
message string

plaintext message

Source:

NewUserPromiseCallbackSuccess(message)

This callback is called when the NewUserPromise
response succeeds

Parameters:
Name Type Description
message string

plaintext message

Source:

Node

Type:
  • object
Properties:
Name Type Argument Description
name string

Name of this node

_id string

ID of this node

_rev string

Revision number of this node

data string

A pointer to the data node of the portfolio

treeID string

The name of the tree to which this node belongs

children Array.<string>

An array of child node IDs under this node

commands Array.<string>

An array of templates that apply to this node. Portfolio nodes tend not to have commands, so this array is likely 0 for such nodes. If there is a template, then only the first item in this array would be populated. This has been kept an array just in case the design evolves to support multiple templates for a node.

isPlatform boolean

Is the current node a platform node? This is always false for portfolio nodes.

acl Acl <optional>

The access control list information for this portfolio. This attribute is only present if the node is a root (portfolio) node.

Source:

PromiseActionCallbackError(err)

This callback is called when the result fails to load.

Parameters:
Name Type Description
err Error

The error that occurred while loading inputs.

Source:

PromiseActionCallbackSuccess(ret)

This callback is called when the result is loaded.

Parameters:
Name Type Description
ret CompareValueData | CompareUncData

An object that differs based on the command that was executed

Source:

PromiseActionMenu

Type:
  • Promise
Source:

PromiseActionMenuCallbackError(err)

This callback is called when the result fails to load.

Parameters:
Name Type Description
err Error

The error that occurred while loading inputs.

Source:

PromiseActionMenuCallbackSuccess(menu)

This callback is called when the result is loaded.

Parameters:
Name Type Description
menu Object

An object that contains the menu items

Properties
Name Type Description
menuItems Object

The menu items for the node

Properties
Name Type Description
Actions Array.<MenuObject>

The menu items under the "Actions" section

Management Array.<MenuObject>

The menu items under the "Management" section

Source:

PromiseActionResults

Type:
  • Promise
Source:

PromiseAuthenticate

Type:
  • Promise
Source:

PromiseAuthenticateCallbackError(err)

This callback is called when the result fails to load.

Parameters:
Name Type Description
err Error

The error that occurred while loading the result.

Source:

PromiseAuthenticateCallbackSuccess(ret)

This callback is called when the result is loaded.

Parameters:
Name Type Description
ret UserInfo

The result is loaded.

Source:

PromiseInputs

Type:
  • Promise
Source:

PromiseInputsCallbackError(err)

This callback is called when the result fails to load.

Parameters:
Name Type Description
err Error

The error that occurred while loading inputs.

Source:

PromiseInputsCallbackSuccess(ret)

This callback is called when the result is loaded.

Parameters:
Name Type Description
ret MenuItems

A collection of inputs matching the keys at the node

Source:

PromiseNodeCallbackError(err)

This callback is called when the result fails to load.

Parameters:
Name Type Description
err Error

The error that occurred while reading node.

Source:

PromiseNodeCallbackSuccess(node)

This callback is called when the node is loaded.

Parameters:
Name Type Description
node Node

The node object

Source:

PromiseNodeResults

Type:
  • Promise
Source:

PromisePasteStatus

Type:
  • Promise
Source:

PromisePasteStatusCallbackError(status, statusText, message)

This callback is called when the Paste Node fails

Parameters:
Name Type Description
status Number

http status code, e.g. 500

statusText string

http status text, e.g. 'INTERNAL SERVER ERROR'

message string

e.g. incorrect _id 'ERROR PasteNode Exception ('_id')'

Source:

PromisePasteStatusCallbackSuccess(status, message)

This callback is called when the Paste Node succeeds

Parameters:
Name Type Description
status Number

0=success non-zero=failure

message string

e.g. 'pasted data'

Source:

PromisePortfolios

Type:
  • Promise
Source:

PromisePortfoliosCallbackError(err)

This callback is called when the result fails to load.

Parameters:
Name Type Description
err Error

The error that occurred while loading portfolios.

Source:

PromisePortfoliosCallbackSuccess(ret)

This callback is called when the result is loaded.

Parameters:
Name Type Description
ret Array.<Node>

A collection of root (or portfolio) nodes that the user is allowed to access.

Source:

PromiseTemplates

Type:
  • Promise
Source:

PromiseTemplatesCallbackTemplateError(err)

This callback is called when the result fails to load.

Parameters:
Name Type Description
err Error

The error that occurred while loading the result.

Source:

PromiseTemplatesCallbackTemplateSuccess(ret)

This callback is called when the result is loaded.

Parameters:
Name Type Description
ret Array.<Template>

The result is loaded.

Source:

PromiseTree

Type:
  • Promise
Source:

PromiseTreeCallbackError(message)

This callback is called when the treeFor response fails

Parameters:
Name Type Description
message string

base64 encoded error message

Source:

PromiseTreeCallbackSuccess(nodes)

This callback is called when the treeFor response succeeds

Parameters:
Name Type Description
nodes Array.<Node>

tree structure of Nodes

Source:

SaveTagsPromise

Type:
  • Promise
Source:

SaveTagsPromisePromiseCallbackSuccess(statusMessage)

This callback is called when the saveTags response succeeds

Parameters:
Name Type Description
statusMessage string

status of saveTags

Source:

SaveTagsPromisePromiseCallbackSuccess(statusMessage)

This callback is called when the saveTags response fails

Parameters:
Name Type Description
statusMessage string

error message

Source:

SaveUserProfilePromise

Type:
  • Promise
Source:

SaveUserProfilePromiseCallbackError(message)

This callback is called when the SaveUserProfilePromise
response fails

Parameters:
Name Type Description
message string

plaintext message

Source:

SaveUserProfilePromiseCallbackSuccess(message)

This callback is called when the SaveUserProfilePromise
response succeeds

Parameters:
Name Type Description
message string

plaintext message

Source:

ShortUrl

Type:
  • object
Properties:
Name Type Description
_id string

short url code e.g. JwijDXE

_rev string

internal document revision ( ignore )

url string

long url

byPassLogin boolean
urlLinkName string

e.g. Report 2016 PMF submission

csum string

checksum of the long url used for duplicate prevention ( ignore )

CategoryEntries array.<string>

e.g US, Asia, Europe

Source:

ShortUrlPromise

Type:
  • Promise
Source:

ShortUrlPromiseCallbackError(message)

This callback is called when the ShortUrlPromise response fails

Parameters:
Name Type Description
message string

base64 encoded error message

Source:

ShortUrlPromiseeCallbackSuccess(ShortUrl)

This callback is called when the ShortUrlPromise response succeeds

Parameters:
Name Type Description
ShortUrl Array.<ShortUrl>

a ShortUrl object

Source:

TagSet

Type:
  • Array.<String>
Source:
Example
//First element in the array is the node ID
//Second element in the array is a comma delimited string of 1 or more CategoryName:CategoryItemName, all is required
["b8652f5d935cf2e22e8e5d01de065d5d","all, Region:Africa, Funded:No, CropType:legumes"]

Template

Type:
  • object
Properties:
Name Type Argument Description
name string

Name of this template

hasPlatform string

Does this template have a platform capability?

info object <optional>

Information about this template

Properties
Name Type Argument Description
Creator string <optional>

Name of the creator of this template

CreatorLink string <optional>

Link to the template creator's website

Description string <optional>

Description of this template

Email string <optional>

Email id of template creator

Source:

UserInfo

Type:
  • object
Properties:
Name Type Description
uid string

User ID generated from server

Source:

UserProfileByIdPromise

Type:
  • Promise
Source:

UserProfileByIdPromiseCallbackError(message)

This callback is called when the UserProfileByIdPromise
response fails

Parameters:
Name Type Description
message string

plaintext message

Source:

UserProfileByIdPromiseCallbackSuccess(userInfo)

This callback is called when the UserProfileByIdPromise
response succeeds

Parameters:
Name Type Description
userInfo object

A user object with all property
except password

Source: