Session Service

Session Service

Session calls are used to ingest or retrieve runtime data from Graff. Every running robot saves data against a session, and the Session calls allow a user to retrieve data across all sessions.

Interacting with Sessions

Structures

A summary response for a single session.

source

A list of session response summaries.

source

The structure used for detailed session requests.

source

The structure used for detailed session responses.

source

Functions

GraffSDK.getSessionsFunction.
getSessions(config, robotId)

Gets all sessions for the current robot. Return: A vector of sessions for the current robot.

source
getSessions(config)

Gets all sessions for the current robot. Return: A vector of sessions for the current robot.

source
isSessionExisting(config, robotId, sessionId)

Return: Returns true if the session exists already.

source
isSessionExisting(config)

Return: Returns true if the session exists already.

source
GraffSDK.getSessionFunction.
getSession(config, robotId, sessionId)

Get a specific session given a user ID, robot ID, and session ID. Return: The session details for the provided user ID, robot ID, and session ID.

source
getSession(config)

Get a specific session given a user ID, robot ID, and session ID. Return: The session details for the provided user ID, robot ID, and session ID.

source
deleteSession(config, robotId, sessionId)

Delete a specific session given a user ID, robot ID, and session ID. Return: Nothing if success, error if failed.

source
deleteSession(config)

Delete a specific session given a user ID, robot ID, and session ID. Return: Nothing if success, error if failed.

source
GraffSDK.addSessionFunction.
addSession(config, robotId, session)

Create a session in Synchrony and associate it with the given robot+user. Return: Returns the created session.

source
addSession(config, session)

Create a session in Synchrony and associate it with the given robot+user. Return: Returns the created session.

source

Getting Graphs - Getting Session Nodes

Structures

The structure used to briefly describe a node in a response.

source

The structure used to briefly describe a set of nodes in a response.

source

The structure describing a complete node in a response.

source

Functions

GraffSDK.getNodesFunction.
getNodes(config, robotId, sessionId)

Gets all nodes for a given session. Return: A vector of nodes for a given robot.

source
getNodes(config)

Gets all nodes for a given session. Return: A vector of nodes for a given robot.

source
GraffSDK.getNodeFunction.
getNode(config, robotId, sessionId, nodeIdOrLabel)

Gets a node's details by either its ID or name. Return: A node's details.

source
getNode(config, nodeIdOrLabel)

Gets a node's details by either its ID or name. Return: A node's details.

source

Building Graphs - Adding Nodes/Variables/Factors

Structures

NodeResponse
NodesResponse
NodeDetailsResponse
AddOdometryRequest
AddOdometryResponse
VariableRequest
VariableResponse
DistributionRequest
BearingRangeRequest
FactorBody
FactorRequest

Functions

GraffSDK.addVariableFunction.
addVariable(config, robotId, sessionId, variableRequest)

Create a variable in Synchrony. Return: Returns the ID+label of the created variable.

source
addVariable(config, variableRequest)

Create a variable in Synchrony. Return: Returns the ID+label of the created variable.

source
GraffSDK.addFactorFunction.
addFactor(config, robotId, sessionId, factorRequest)

Create a factor in Synchrony. Return: Returns the ID+label of the created factor.

source
addFactor(config, factorRequest)

Create a factor in Synchrony. Return: Returns the ID+label of the created factor.

source
addBearingRangeFactor(config, robotId, sessionId, bearingRangeRequest)

Create a variable in Synchrony and associate it with the given robot+user. Return: Returns ID+label of the created factor.

source
addBearingRangeFactor(config, bearingRangeRequest)

Create a variable in Synchrony and associate it with the given robot+user. Return: Returns ID+label of the created factor.

source
addOdometryMeasurement(config, robotId, sessionId, addOdoRequest)

Create a session in Synchrony and associate it with the given robot+user. Return: Returns the added odometry information.

source
addOdometryMeasurement(config, addOdoRequest)

Create a session in Synchrony and associate it with the given robot+user. Return: Returns the added odometry information.

source
GraffSDK.putReadyFunction.
putReady(config, robotId, sessionId, isReady)

Set the ready status for a session.

source
putReady(config, isReady)

Set the ready status for a session.

source

Working with Node Data

Structures

Body of a request for creating or updating a data element.

source

Summary of data entry returned from request.

source

Complete data element response (including data).

source

Functions

getDataEntries(config, robotId, sessionId, node)

Get data entries associated with a node. Return: Summary of all data associated with a node.

source
getDataEntries(config, node)

Get data entries associated with a node. Return: Summary of all data associated with a node.

source
getDataElement(config, robotId, sessionId, node, bigDataKey)

Get data elment associated with a node. Return: Full data element associated with the specified node.

source
getDataElement(config, node, bigDataKey)

Get data elment associated with a node. Return: Full data element associated with the specified node.

source
getRawDataElement(config, robotId, sessionId, node, bigDataKey)

Get data elment associated with a node. Return: Full data element associated with the specified node.

source
getRawDataElement(config, node, bigDataKey)

Get data elment associated with a node. Return: Full data element associated with the specified node.

source
addDataElement(config, robotId, sessionId, node, bigDataElement)

Add a data element associated with a node. Return: Nothing if succeed, error if failed.

source
addDataElement(config, node, bigDataElement)

Add a data element associated with a node. Return: Nothing if succeed, error if failed.

source
updateDataElement(config, robotId, sessionId, node, bigDataElement)

Update a data element associated with a node. Return: Nothing if succeed, error if failed.

source
updateDataElement(config, node, bigDataElement)

Update a data element associated with a node. Return: Nothing if succeed, error if failed.

source
addOrUpdateDataElement(config, robotId, sessionId, node, dataElement)

Add or update a data element associated with a node. Will check if the key exists, if so it updates, otherwise it adds. Return: Nothing if succeed, error if failed.

source
deleteDataElement(config, robotId, sessionId, node, dataId)

Delete a data element associated with a node. Return: Nothing if succeed, error if failed.

source
deleteDataElement(config, node, dataId)

Delete a data element associated with a node. Return: Nothing if succeed, error if failed.

source