NAV

Nucleus  Proton  Electron

curl java javascript php python ruby

Introduction

Authentication Base URL

https://[sandbox][api].hydrogenplatform.com/authorization/v1

Nucleus Base URL

https://[sandbox][api].hydrogenplatform.com/nucleus/v1

The Nucleus API provides the data model for Hydrogen no-code applications. This includes the base functionality to authenticate, onboard clients and accounts, and store and process data which all other APIs in Hydrogen will utilize.

All Hydrogen APIs are built on REST principles, with resource oriented URLs and HTTP response codes. All API responses are returned in JSON format. Additional features of the API include filtering, pagination, and data caching.

Run in Postman

Authentication

API Authentication

After successful registration of your application, you will be provided a client_id and client_secret which will be used to identify your application when calling any Hydrogen API.

We require all API calls to be made over HTTPS connections.

OAuth 2.0 Authorization

Hydrogen uses OAuth 2.0 to facilitate authorization on the API, an industry standard framework for authorization. Two standard type of flows are supported:

  1. Client Credentials
  2. Resource Owner Password Credentials

Client Credentials

The Client Credentials authorization flow consists of exchanging a client_id and client_secret for an access_token to be provided when making calls to the Hydrogen API. This type of authorization is used for the application to access resources about itself rather than a user.

Example Request

curl -X POST -H "Authorization: Basic <Base64 encoded client_id:client_secret>" \
"https://[sandbox][api].hydrogenplatform.com/authorization/v1/oauth/token?grant_type=client_credentials"
from __future__ import print_function
import time
import proton_api
from proton_api.rest import ApiException
from pprint import pprint

# Configure OAuth2 access token for authorization: oauth2
configuration = proton_api.Configuration()

# create an instance of the API class
api_instance = proton_api.AuthApi(proton_api.ApiClient(configuration))

api_token_response = api_instance.create_using_post_client_credentials("MYCLIENTID", "MYPASSWORD")
print(api_token_response.access_token)
configuration.access_token = api_token_response.access_token
require 'nucleus_api'
NucleusApi.configure do |config|
 config.create_client_credential("CLIENT_ID", "CLIENT_SECRET");
end
import com.hydrogen.nucleus.ApiException;
import com.hydrogen.nucleus.AuthApiClient;

# Create an instance of the Auth Api Client class
AuthApiClient authApiClient = new AuthApiClient();
try {
    authApiClient.createClientCredential("MYCLIENTID","MYCLIENTSECRET");
} catch (ApiException e) {
    e.printStackTrace();
}
var HydrogenNucleusApi = require('hydrogen_nucleus_api');
var defaultClient = HydrogenNucleusApi.ApiClient.instance;
# Configure OAuth2 access token for authorization: oauth2
var oauth2 = defaultClient.authentications['oauth2'];
# Create an instance of the Auth API class
var api = new HydrogenNucleusApi.AuthApi();

# Callback function definition
var tokenGenerationCallback = function (error, data, response) {
    if (error) {
        console.error(error);
        process.exit(1);
    } else {
        console.log(response.request.method + ' : ' + response.request.url + '\n' + 'Output: ' + JSON.stringify(data, null, '\t') + '\n');
        oauth2.accessToken = data.access_token;
    }
};

# Token Generation for grant_type = client_credentials
api.createUsingPostClientCredentials({
    'grant_type': 'client_credentials',
    'client_id': 'MYCLIENTID',
    'client_secret': 'MYCLIENTSECRET'
}, tokenGenerationCallback);
require_once('../vendor/autoload.php');

use com\hydrogen\nucleus\ApiException;
use com\hydrogen\nucleus\AuthApiClient;

try {
    $config =
        AuthApiClient::getDefaultConfiguration()
            ->createClientCredential("MYCLIENTID", "MYCLIENTSECRET");
} catch (ApiException $e) {
    print_r($e);
}

Example Response

{
  "access_token": "eyJhbGciOiJSUzI1NiIsInR5cCI6IkpXVCJ9.eyJzY29wZSI6WyJ4Il0sImV4cCI6MTU4NjQ3OTcxNCwiYXV0aG9yaXRpZXMiOlsiUk9MRV9TVVBFUl9BRE1JTiJdLCJqdGkiOiIwNDMzZjA1Ni00NWQyLTQ0MjYtODliNi01MjMwMTNiZjdhOGEiLCJjbGllbnRfaWQiOiJUZXN0VXNlciIsImFwcHMiOiJudWNsZXVzLHByb3RvbixlbGVjdHJvbixoeWRybyxpb24saW50ZWdyYXRpb24ifQ.oJHd6pIu2f6zwP4jGe-MIRK0FVCC-82EVrld5kbJoRYtvs_27KM0xZm-VfkfKN8q5qnKyqfWUyS4ptoDhg4UWVuJ3st9Gp6k_EWDFTGVQmxtsn4Sc_c3VTjpW39ZDTQAoGFH4T6yOaIr5FYQaBN17kAt2_ELEyrXwvGG3BVVG-pX3nFnu98meYIoq7pQt-1EMKIOMLWuillO5FuVYgJpy1LFfVIrdlbWKtKB3HTGpKw5oVqa7L978jRBM94WZU2pRGabYBQs4Tzs-qaEdPGF2VuOMKIPj1GTxeFg6pB8e1oyEaC1o-p_-qG3H0Vm0RFKBDoBq8nEnf_U8pHaJ7Ta6w",
  "token_type": "bearer",
  "expires_in": 86400,
  "scope": "create read update delete",
  "limits": {"total_limit":10000},
  "apps": "nucleus,proton",
  "jti": "ea4289b3-72b8-43e3-bab3-f54159a997dd"
}

All subsequent API calls will then be made like the following example. Replace <access_token> after Bearer with the access_token received above:

curl -X GET -H "Authorization: Bearer <access_token>" \
"https://[sandbox][api].hydrogenplatform.com/nucleus/v1/account"

The client credentials flow is used by your application to obtain permission to act on its own behalf. A call will be made to our OAuth server to exchange your client_id, client_secret, and grant_type=client_credentials for an access_token, which can then be used to make calls to Hydrogen on behalf of the application.

HTTP REQUEST

POST https://[sandbox][api].hydrogenplatform.com/authorization/v1/oauth/token?grant_type=client_credentials

ARGUMENTS

Parameter Type Required Description
client_id string required Application id for identification, which will be given to you when you are onboarded
client_secret string required Application secret, which will be given to you only once when you are onboarded. Please keep this in a safe place
grant_type string required Must be set to client_credentials

RESPONSE

Field Description
access_token JWT token that will be used for all subsequent API calls as a Bearer token in the header
expires_in When the token expires in seconds and will need to be called again. Default is 86400 or 24 hours.
token_type Always will be bearer
scope The scope your user has been granted in the application
limits Total API call limits assigned to your tenant
apps APIs to which the user has access. Possible values include nucleus, proton, electron, component
jti Unique identifier for the JWT token

Resource Owner Password Credentials

The Resource Owner Password Credentials authorization flow consists of exchanging a username and password specific to a user in addition to your client_id and client_secret for an access_token, to be provided when making calls to the Hydrogen API. This type of authorization validates the username and password of a user and is used for the application to access resources about a user.

Example Request

curl -X POST -H "Authorization: Basic <Base64 encoded client_id:client_secret>" \
"https://[sandbox][api].hydrogenplatform.com/authorization/v1/oauth/token?grant_type=password&username={username}&password={password}"
from __future__ import print_function
import time
import nucleus_api
from nucleus_api.rest import ApiException
from pprint import pprint

# Configure OAuth2 access token for authorization: oauth2
configuration = nucleus_api.Configuration()

# create an instance of the API class
api_instance = nucleus_api.AuthApi(nucleus_api.ApiClient(configuration))

# Fetch and set access token with client_id, client_secret, username, password
api_token_response = api_instance.api_instance.create_using_post_password_credentials("MYCLIENTID","MYCLIENTSECRET", "MYUSERNAME", "MYPASSWORD" )
print(api_token_response.access_token)
configuration.access_token = api_token_response.access_token
require 'nucleus_api'
NucleusApi.configure do |config|
 config.create_password_credential("CLIENT_ID", "CLIENT_SECRET", "USERNAME", "PASSWORD");
end
import com.hydrogen.nucleus.ApiException;
import com.hydrogen.nucleus.AuthApiClient;

# Create an instance of the Auth Api Client class
AuthApiClient authApiClient = new AuthApiClient();
try {
    authApiClient.createPasswordCredential("MYCLIENTID","MYCLIENTSECRET","MYUSERNAME", "MYPASSWORD");
} catch (ApiException e) {
    e.printStackTrace();
}
var HydrogenNucleusApi = require('hydrogen_nucleus_api');
var defaultClient = HydrogenNucleusApi.ApiClient.instance;
# Configure OAuth2 access token for authorization: oauth2
var oauth2 = defaultClient.authentications['oauth2'];
# Create an instance of the Auth API class
var api = new HydrogenNucleusApi.AuthApi();

# Callback function definition
var tokenGenerationCallback = function (error, data, response) {
    if (error) {
        console.error(error);
        process.exit(1);
    } else {
        console.log(response.request.method + ' : ' + response.request.url + '\n' + 'Output: ' + JSON.stringify(data, null, '\t') + '\n');
        oauth2.accessToken = data.access_token;
    }
};

# Token Generation for grant_type = password
api.createUsingPostPassword({
    'grant_type': 'password',
    'username' : 'MYUSERNAME',
    'password' : 'MYPASSWORD',
    'client_id': 'MYCLIENTID',
    'client_secret': 'MYCLIENTSECRET'
}, tokenGenerationCallback);
require_once('../vendor/autoload.php');

use com\hydrogen\nucleus\ApiException;
use com\hydrogen\nucleus\AuthApiClient;

try {
  $config =
        AuthApiClient::
        getDefaultConfiguration()->createPasswordCredential(
            "MYCLIENTID","MYCLIENTSECRET"
            ,"MYUSERNAME", "MYPASSWORD"
        );
} catch (ApiException $e) {
    print_r($e);
}

Example Response

{
  "access_token": "eyJhbGciOiJSUzI1NiIsInR5cCI6IkpXVCJ9.eyJzY29wZSI6WyJ4Il0sImV4cCI6MTU4NjQ3OTcxNCwiYXV0aG9yaXRpZXMiOlsiUk9MRV9TVVBFUl9BRE1JTiJdLCJqdGkiOiIwNDMzZjA1Ni00NWQyLTQ0MjYtODliNi01MjMwMTNiZjdhOGEiLCJjbGllbnRfaWQiOiJUZXN0VXNlciIsImFwcHMiOiJudWNsZXVzLHByb3RvbixlbGVjdHJvbixoeWRybyxpb24saW50ZWdyYXRpb24ifQ.oJHd6pIu2f6zwP4jGe-MIRK0FVCC-82EVrld5kbJoRYtvs_27KM0xZm-VfkfKN8q5qnKyqfWUyS4ptoDhg4UWVuJ3st9Gp6k_EWDFTGVQmxtsn4Sc_c3VTjpW39ZDTQAoGFH4T6yOaIr5FYQaBN17kAt2_ELEyrXwvGG3BVVG-pX3nFnu98meYIoq7pQt-1EMKIOMLWuillO5FuVYgJpy1LFfVIrdlbWKtKB3HTGpKw5oVqa7L978jRBM94WZU2pRGabYBQs4Tzs-qaEdPGF2VuOMKIPj1GTxeFg6pB8e1oyEaC1o-p_-qG3H0Vm0RFKBDoBq8nEnf_U8pHaJ7Ta6w",
  "refresh_token": "eyJhbGciOiJSUzI1NiIsInR5cCI6IkpXVCJ9.eyJ1c2VyX25hbWUiOiJib3J5YS5pdmNoZW5rb0BtYWlsLnJ1Iiwic2NvcGUiOlsieCJdLCJhdGkiOiJkZDMxODJiZS0wYmNlLTQ0Y2MtOTM5Yi03YzAzMmRlOTExNmYiLCJleHAiOjE2MDk3MDY1NDAsImF1dGhvcml0aWVzIjpbIlJPTEVfQ0xJRU5UIl0sImp0aSI6ImQzMGFmM2JiLWQ4OTUtNDAxZi1iODFkLTBiOTEyNThjOWIzOCIsImxpbWl0cyI6eyJ0b3RhbF9saW1pdCI6MTAwMDAwfSwiY2xpZW50X2lkIjoiVGVzdFVzZXIiLCJhcHBzIjoibnVjbGV1cyxwcm90b24sZWxlY3Ryb24saHlkcm8saW9uLGludGVncmF0aW9uIn0.Ei-AgWolKsDzxyNZlTLuVc89VhdE1BRf1YeXutdGGqYDW3WLT1LUfa288tsfBs0PEELrCVtKwks7-BcRirtuxLWTuojoLyEJTGtRdtezxLo5QozQF2x-vFGcIs9YJo-SdbPTcUWdPI5ZgsaLVIDL0Q68gFl9DIH-VYSIGpBhpgiqPbvRmlnK2NnDS73ufILleNmexZcTmWgUy6yRVZyEAZ5-lQKKWNL8S69Ij0ZuURkJqvHtPluIw-8yVB_A3EtwU_E2b5tAV6BCK3QWxHSQKhwe5ZL9rRdm-QPfWeSvQGfqhAFkF27xk47Khw93pB6el49aXdYz11e-DQybJG1hAA",
  "token_type": "bearer",
  "expires_in": 86400,
  "scope": "create read update delete",
  "limits": {"total_limit":10000},
  "apps": "nucleus,proton,electron",
  "jti": "6118a6c2-92fd-450f-ae1d-198150c0b579"
}

All subsequent API calls will then be made like the following example. Replace <access_token> after Bearer with the access_token received above:

curl -X GET -H "Authorization: Bearer <access_token>" \
"https://[sandbox][api].hydrogenplatform.com/nucleus/v1/account"

The resource owner password credentials flow, or password credentials flow, is used to identify specific users and act according to their permissions. A call will be made to our OAuth server to exchange your client_id and client_secret as well as the user’s username and password, and grant_type=password for a user-specific access_token, which can then be used to make calls to Hydrogen APIs.


HTTP REQUEST

POST https://[sandbox][api].hydrogenplatform.com/authorization/v1/oauth/token?grant_type=password&username={username}&password={password}

ARGUMENTS

Parameter Type Required Description
client_id string required Application id for identification, which will be given to you when you are onboarded
client_secret string required Application secret, which will be given to you only once when you are onboarded. Please keep this in a safe place
username string required User’s unique username for the application
password string required User’s unique password for the application
grant_type string required Must be set to password

RESPONSE

Field Description
access_token JWT access token that will be used for all subsequent API calls as a Bearer token in the header
refresh_token Exchange a refresh_token for an access_token when the access_token has expired. This allows you to continue to have a valid access_token without further interaction with the user.
expires_in When the token expires in seconds and will need to be called again. Default is 86400 or 24 hours.
token_type Always will be bearer
scope N/A - this is embedded in the access_token returned
limits Total API call limits assigned to your tenant
apps APIs to which the user has access. Possible values include nucleus, proton, electron, component
jti Unique identifier for the JWT token

Custom Client Token

The Custom Client Token flow consists of exchanging a signed payload with a private key in addition to your client_id and client_secret for an access_token, to be provided when making calls to the Hydrogen API. This JWT token exchange follows standards set by IETF for OAuth 2.0 Token Exchange. This type of authorization validates a user’s permission to access their data, while allowing you to maintain the login credentials for the user. It should be used if you already have a web or mobile app with a user credentialing system. You will only need to map the username for the user in the Nucleus Client service below, and not the password. If you do not have or need this capability, Hydrogen will store all user details, and you will use the Resource Owner Password Credentials OAuth flow instead.

Example Request

curl -X POST -H "Authorization: Basic <Base64 encoded client_id:client_secret>" \
-H "Client-Token: Bearer <signed token payload>" \
"https://[sandbox][api].hydrogenplatform.com/authorization/v1/client-token"
from __future__ import print_function
import time
import nucleus_api
from nucleus_api.rest import ApiException
from pprint import pprint

# Configure OAuth2 access token for authorization: oauth2
configuration = nucleus_api.Configuration()

# create an instance of the API class
api_instance = nucleus_api.AuthApi(nucleus_api.ApiClient(configuration))

# Fetch and set access token with client_id, client_secret, client_token
api_token_response = api_instance.create_client_token_credentials("client_id", "client_secret", "client_token");
print(api_token_response.access_token)
configuration.access_token = api_token_response.access_token
configuration.access_token = api_token_response.access_token
require 'nucleus_api'
NucleusApi.configure do |config|
 config.create_client_token_credential("CLIENT_ID", "CLIENT_SECRET", "CLIENT_TOKEN")
end
import com.hydrogen.nucleus.ApiException;
import com.hydrogen.nucleus.AuthApiClient;

# Create an instance of the Auth Api Client class
AuthApiClient authApiClient = new AuthApiClient();
try {
    authApiClient.createClientTokenCredential("CLIENT_ID", "CLIENT_SECRET", "CLIENT_TOKEN");
} catch (ApiException e) {
    e.printStackTrace();
}
var HydrogenNucleusApi = require('hydrogen_nucleus_api');
var defaultClient = HydrogenNucleusApi.ApiClient.instance;
# Configure OAuth2 access token for authorization: oauth2
var oauth2 = defaultClient.authentications['oauth2'];
# Create an instance of the Auth API class
var api = new HydrogenNucleusApi.AuthApi();

# Callback function definition
var tokenGenerationCallback = function (error, data, response) {
    if (error) {
        console.error(error);
        process.exit(1);
    } else {
        console.log(response.request.method + ' : ' + response.request.url + '\n' + 'Output: ' + JSON.stringify(data, null, '\t') + '\n');
        oauth2.accessToken = data.access_token;
    }
};

//Token Generation using client token
api.createUsingPostClientTokenCredentials({
    'client_id': 'MYCLIENTID',
    'client_secret': 'MYCLIENTSECRET',
    'client_token' : 'CLIENT_TOKEN'
}, tokenGenerationCallback);
require_once('../vendor/autoload.php');

use com\hydrogen\nucleus\ApiException;
use com\hydrogen\nucleus\AuthApiClient;

try {
  $config =
        AuthApiClient::
        getDefaultConfiguration()->createClientTokenCredential("MYCLIENTID",
        "MYCLIENTSECRET", "CLIENT_TOKEN");
} catch (ApiException $e) {
    print_r($e);
}

Example Response

{
  "access_token": "eyJhbGciOiJSUzI1NiIsInR5cCI6IkpXVCJ9.eyJ1c2VyX25hbWUiOiJvazIiLCJleHAiOjE2MDA5MzAyODAsImF1dGhvcml0aWVzIjpbIlJPTEVfQURNSU4iLCJST0xFX0FCQyIsIlJPTEVfQ0xJRU5UIl0sImp0aSI6ImZiNzQ5OTUwLWRhMzctNGViNS04NTEzLWJmZjQ1YWNkOTkwOSIsImxpbWl0cyI6e30sImNsaWVudF9pZCI6IkludGVncmF0aW9uVGVzdCIsImFwcHMiOiJudWNsZXVzLHByb3RvbixlbGVjdHJvbixoeWRybyxwbGFzbWEsaW9uLG1vbGVjdWxlLGludGVncmF0aW9uIn0.TRYTtaB_E4DAPlrt9mWpHsx6_XO3sKLlNaqAMir71uzO1HI-03RdF3ecDLraMRAiXMVqt150MOZnrtu5YOlpCYXUiwa8RBp9ofaMa4NOrYjpRmqq5c7rvZ1ZzvbG7olg8ivNCLzde4pjeCYi25mOZ3A-AGSnUQqn4URBjzr3CJo4MQb_DNWY2ns2MEm2Hm76O_7CiBKCSD2AfccLGC8CFzDnlnuTE40RYE1-6roHlN4yqop3vmiZ6UquqwLjnweQhYKWL7WUqYwapOZmIu_TyC8IEJl1csrJhMh9FExtaxY50ABldCzWeXEJzR1oX8NEZ2kyio1_w9COGsCs2qr61w",
    "token_type": "bearer",
    "expires_in": 86399,
    "user_name": "[email protected]",
    "limits": {},
    "authorities": [
        "ROLE_ADMIN",
        "ROLE_ABC",
        "ROLE_CLIENT"
    ],
    "apps": "nucleus,proton",
    "jti": "fb749950-da37-4eb5-8513-bff45acd9909"
}

All subsequent API calls will then be made like the following example. Replace <access_token> after Bearer with the access_token received above:

curl -X GET -H "Authorization: Bearer <access_token>" \
"https://[sandbox][api].hydrogenplatform.com/nucleus/v1/account"


HTTP REQUEST

POST https://[sandbox][api].hydrogenplatform.com/authorization/v1/client-token

SETUP

Please follow the steps below to create your custom JWT token:

  1. Create your public/private key pair. We ONLY accept a key in 2048 bit PKCS#8 encoded format. Recommended site for creation: https://travistidwell.com/jsencrypt/demo/
  2. Store the private key that is created in your application securely
  3. Login to the Hydrogen dev portal and upload the public key that is created under “API Access” in the settings dropdown on the top right.

TOKEN CREATION

Sign the following payload using your private key. See example code for the language of your choice in the right panel.

{
    ”sub”: “insert your Nucleus Client username“,
    ”iss”: “insert your OAuth credentials client_id“,
    ”exp”: The epoch time the token expires,
    ”iat”: The epoch time the token is issued
}

Algorithm and token type
{
    ”typ”: “JWT”,
    ”alg”: “RS512”
}

After signing the payload you can now submit the payload as a Basic header, along with a Basic Base64 encoded client_id and client_secret. The response should now give you the same access_token that you can use to call all subsequent Hydrogen APIs for this user.

Example payload encryption code

pip3 install -r requirements.txt
Requirements.txt file
PyJWT==1.7.1
cryptography==2.7
cffi>=1.8
pycparser>=2.06
six>=1.4.1
asn1crypto>=0.21.0

import jwt
import time

def generateToken(privateKey, issuer, subject):

    currentTime = int(time.time())

    payload = {}
    payload['iat'] = currentTime
    payload['exp'] = currentTime + 1800
    payload['iss'] = issuer
    payload['sub'] = subject

    # RS512 requires $ pip install cryptography
    encoded_jwt = jwt.encode(payload, privateKey, algorithm='RS512')
    return encoded_jwt

if __name__ == '__main__':

    privateKey = "<PRIVATE KEY>"
    issuer = "<OAuth client_id>"
    subject = "<Client user_name>"
    print(generateToken(privateKey, issuer, subject).decode("utf-8"))
Dependency:

gem install jwt

require 'jwt'
require 'optparse'

key = "<PRIVATE KEY>"

begin
  rsa_private_key = OpenSSL::PKey::RSA.new key
rescue Errno::ENOENT => e
  puts "Caught the exception: #{e}"
  puts usage
  exit -1
end

current_time = Time.now.to_i

payload = {}
payload['iss'] = '<OAuth client_id>'
payload['iat'] = current_time
payload['exp'] = current_time + 1800
payload['sub'] = '<Client user_name>'

token = JWT.encode payload, rsa_private_key, 'RS512', { typ: 'JWT' }

puts token
Dependency:

<dependency>
        <groupId>io.fusionauth</groupId>
        <artifactId>fusionauth-jwt</artifactId>
        <version>3.1.3</version>
</dependency>

import io.fusionauth.jwt.Signer;
import io.fusionauth.jwt.domain.JWT;
import io.fusionauth.jwt.rsa.RSASigner;

import java.time.ZoneOffset;
import java.time.ZonedDateTime;

public class GenerateToken {

    public String generateToken(String privateKey, String issuer, String subject) {
        Signer signer = RSASigner.newSHA512Signer(privateKey);
        JWT jwt = new JWT().setIssuer(issuer)
                .setSubject(subject)
                .setIssuedAt(ZonedDateTime.now(ZoneOffset.UTC))
                .setExpiration(ZonedDateTime.now(ZoneOffset.UTC).plusMinutes(30));

        String encodedJWT = JWT.getEncoder().encode(jwt, signer);
        return encodedJWT;
    }

    public static void main(String[] args) {
         GenerateToken generateToken = new GenerateToken();

         String privateKey = "<PRIVATE KEY>";

         String issuer = "<OAuth client_id>";
         String subject = "<Client user_name>";

        System.out.println(generateToken.generateToken(privateKey, issuer, subject));

    }
}
Dependency

"dependencies": {
"jsonwebtoken": "^8.5.1"
}
const jwt = require('jsonwebtoken')

function generateToken(privateKey, issuer, subject) {

    const currentTime =  Math.floor(Date.now() / 1000);

    const signOptions = {
        algorithm: "RS512"
    };

    let payload = {};

    payload.iss = issuer
    payload.iat = currentTime;
    payload.exp = currentTime + 1800;
    payload.sub = subject;

    return token = jwt.sign(payload, privateKey, signOptions);
}

module.exports = generateToken

if (require.main === module) {

    const privateKey = "<PRIVATE KEY>"
    const issuer = "<OAuth client_id>"
    const subject = "<Client user_name>"

    console.log(generateToken(privateKey, issuer, subject))
}
Dependency
composer require firebase/php-jwt

<?php

require __DIR__ . '/vendor/autoload.php';

use \Firebase\JWT\JWT;

function generate($privateKey, $issuer, $subject) {

    $time = time();

    $key = $privateKey;

    $payload = array(
        "iss" => $issuer,
        "iat" => $time,
        "exp" => $time + 1800,
        "sub" => $subject
    );

    return $jwt = JWT::encode($payload, $key, 'RS512');
}

if (basename(__FILE__) == $_SERVER['SCRIPT_FILENAME']) {

    $privateKey = "<PRIVATE KEY>";
    $issuer = "<OAuth client_id>";
    $subject = "<Client user_name>" ;

    try {
        echo generate($privateKey,$issuer,$subject) . "\n";
    } catch (Exception $e) {
        echo $e->getMessage() . ".\n";
    }
}

RESPONSE

Field Description
access_token JWT access token that will be used for all subsequent API calls as a Bearer token in the header
expires_in When the token expires in seconds and will need to be called again. Default is 86400 or 24 hours.
token_type Always will be bearer
user_name Admin username for the client that has been authenticated
scope N/A - this is embedded in the access_token returned
limits Total API call limits assigned to your tenant
apps APIs to which the user has access. Possible values include nucleus, proton, electron, component
jti Unique identifier for the JWT token

Token Refresh

An access_token will need to be refreshed to continue being authorized for the app. Access tokens are short lived: 24 hours.

The Client Credentials grant type doesn’t return a refresh_token. When your access_token expires, the app has to simply request a new token which will invalidate the previous token. The token can be deserialized to determine how much longer it is valid.

The Password grant type does return a refresh_token, which can be used with the request and parameters below, to exchange for a new access_token when it expires. Once you get a new refresh_token in the response, you can replace the old one.

HTTP REQUEST

POST https://[sandbox][api].hydrogenplatform.com/authorization/v1/oauth/token?grant_type=refresh_token

ARGUMENTS

Parameter Type Required Description
refresh_token string required Refresh token stored in the original user authentication
client_id string required Application id for identification, which will be given to you when you are onboarded
client_secret string required Application secret, which will be given to you only once when you are onboarded. Please keep this in a safe place
grant_type string required Must be set to refresh_token

Fields

IDs

All Object IDs are represented in universally unique identifier (UUID) format. A UUID is a string of 32 alphanumeric characters in the format 8-4-4-4-12. An example would be efa289b2-3565-42e6-850b-8dad25727e99. Object IDs do not need to be specified. When using the POST method to create a new object, the ID will be returned as part of the response in the field id:

STRINGS

All strings are limited to 255 characters unless otherwise noted.

DATES

All dates are represented in ISO 8601 format YYYY-MM-DD. An example would be 2018-01-10.

TIMESTAMPS

All object responses will include a create_date and update_date in timestamp format. All timestamps are represented in ISO 8601 format YYYY-MM-DDThh:mm:ssTZD. The “T” appears before the time element and the TZD before the time zone. An example would be 2018-01-10T16:00:30+01:00.

BOOLEANS

All booleans can be submitted as true, "true", false, or "false". All other values will be rejected and throw a 400 error.

IS_ACTIVE

Most objects have an is_active field that can be utilized to make data inactive. When the is_active boolean is set to “false”, you will not be able to utilize the object in a POST or PUT request. You can think of this feature as a “soft delete” or archival of data. If you wish to permanently delete data, you can utilize the DELETE method in each entity.

NULL

All optional fields are set to null unless a default value is set. To null an optional field that has a value, you may do the following:

CURRENCY CODES

All currency codes are represented in ISO 4217 format, such as “USD” or “EUR”. Data that is stored in multiple currencies will not automatically be converted to a base currency, unless you have subscribed to our premium internationalization add-on. With this add-on, you may convert data in the following endpoints to a base of USD, EUR, GBP, CHF, AUD, and CAD, by passing the currency_conversion parameter:

Errors

ERROR CODES

Code Description
400 Bad Request
401 Unauthorized. Occurs when you are using an invalid or expired access token.
403 Forbidden. The request was valid but you are not authorized to access the resource.
404 Not Found. Occurs when you are requesting a resource which doesn’t exist such as an incorrect URL, incorrect ID, or empty result.
429 Too Many Requests. Exceeded the rate limit set. Currently, there is no rate limit on the APIs.
500 Internal Server Error.
503 Service Unavailable. If the API is down for maintenance you will see this error.


STATUS CODES

Code Description
200 Ok. The request was successful.
204 No Content. The request was successful but there is no additional content to send in the response body. This will occur on a successful DELETE.

Versioning

The Nucleus API is currently in major version 1.0. All features which are not backwards compatible will be pushed as a major version release. Features that we consider to be backwards compatible include the following:

Changelog

Date Change Description
2022-01-20 update Added the following optional fields: password and authorities to Client. Removed Admin Client.
2021-08-20 update Added the following optional fields: client_group to Card Spending Controls; group to Client. Changed client_id to optional in Card Spending Controls for tenant level controls, and added mid and mcc as possible values for control_scope
2021-04-15 addition Created new entities for Institution, Cardholder Overview
2021-04-15 update Added the following optional fields: interest_rate, apr, apr, credit_limit, death_benefit, minimum_payment, last_payment, last_payment_date, next_payment_date, maturity_date to Aggregation Account
2020-12-30 addition Created new entities for Invoice, Invoice Payment, Contact, Customer Revenue, Financial Statement, Reason Code, Household, Household Activity, Card Activity, Business, Business Activity, Card Spending Controls, Merchants Resource, Merchants Categories Resource, Merchant Category Codes Resource, Account Categories Resource.
2020-12-30 update Added the following optional fields: check, is_fee, is_cleansed, is_disputed, metadata, merchant_category_code to Portfolio Transaction; is_manual, is_cash to Aggregation Account; transfer_speed, receiving_bank_link_id, receiving_account_id, receiving_portfolio_id to Funding; fulfillment to Card; business_id to Client and Document; employee and business_owner as valid “client_type” in Client; brokers, image, description to Security; is_verfied to Stage;
2020-10-02 update Added the following optional fields: is_converted, is_closed to State; status to Account, Client, Portfolio; is_recurring to Portfolio Transaction; is_sent to Notification Client; last_run_date to Notification Setting; Client is_verified, Document is_verified, Bank Link is_link_verified to Webhooks
2020-06-30 addition Added Idempotency to all POST requests by passing in a unique Idempotency-Key in the Request Header
2020-06-30 update Added the following optional fields: is_reloadable, prepaid_amount, portfolio_id to Card; card_id to Funding; asset_size_pending to Portfolio Asset Size
2020-04-06 update Added the ability to roundup from an internal account in addition to held away accounts in Roundup Setting. Added the following optional fields: card_program_id to Card; cost_basis and currency_code to Portfolio Holding; currency_code to Funding, Deposit, Withdrawal, and Transfer; currency_code, date_available, and balance to Portfolio Transaction.
2020-04-06 addition Created new entities for Risk Profile, Client Status, Portfolio Goal, Card Program, Question, and Answer. Added the ability to Bulk POST, PUT, and DELETE any entity.
2020-03-27 addition Created new resources for Country, State, Currency and Statistic
2020-03-27 update Added the following optional fields: is_default boolean to Bank Link; is_account, is_client, and is_active booleans to Stage; is_primary boolean and card_image to Card; is_business and is_investment booleans to Aggregation Account; is_recurring boolean and investment.value to Aggregation Account Transaction; cusip and isin to Security, discretionary to Account; is_subledger to Portfolio; asset_size_available to Portfolio Asset Size; is_active and is_verified booleans to the Document entity; threshold_type, feature_id and frequency_unit to the Notification entity; threshold_value to the Notification Setting entity; notification_image and is_read to the Notification Client entity.
2020-02-26 update Added the following optional fields to Client: total_net_worth, liquid_net_worth, suffix, employment, firm_name, identification_number_type, country_of_citizenship, citizenship_status, image, address.is_primary. Added “prepaid” as an acceptable card_type and card_network as an optional field to Card.
2019-12-19 addition Created new aggregate data views for Account, Client, Portfolio, Goal, Allocation, Aggregation Account, and Advisors. Created new orchestrations for Roundup, Overflow, and Decision Tree. Created new Insurance entities for Coverage, Discount, and Quote.
2019-12-19 update Added the following optional fields: image to Goal; total_expense_ratio to Security; tooltip to Questions and Answers objects in Questionnaire; portfolio_id to Funding, Deposit, and Withdrawal; application_id to Client Response; account_number to Account; bank_link_id to Aggregation Account; metadata to Benchmark and Security; node_map to Financial Offer; is_active to Budget, Account, Financial Offer, Decision Tree, Questionnaire, and Portfolio; doc_number, doc_image_front, doc_image_back, issue_date, expiry_date, state_of_issue, country_of_issue to Document entity to support KYC integrations.
2019-12-19 addition Added new entities for Audit Log, Application, Notification, and Tracking.
2019-11-04 update Added cash and location maps to Aggregation Account Transaction, gender field to Client, and holding_date field to Aggregation Account Holding.
2019-08-22 update Added ability to link a client_id to a Bank Link and aggregation_accounts to a Budget.
2019-07-11 addition Created new entities for Aggregation Account Transaction, Aggregation Account Holding, Budget, and Financial Offer.
2019-07-11 update Added total_earnings stat to Performance and metadata to remaining services.
2019-06-30 update Added is_sent to Notification Client and last_run_date to Notification Setting entities.
2019-03-06 addition Implemented Access Control List (ACL) framework to permission user-specific access to endpoints and data records. Framework includes Authorities, Permission Types, Resource Owner Password Credentials, and User Administration service.
2018-11-30 addition Created new entities for Aggregation Account, Aggregation Account Balance, Score, Client-Hydro, and Goal Track.
2018-11-30 update Added new optional fields to the Client, Bank Link, Withdrawal, and Questionnaire entities. Added new optional fields to the document entity.
2018-09-07 addition Created two new orchestration endpoints to subscribe an Account to an allocation and to change the composition of a Model.
2018-09-07 update Added new optional fields goal_amount, accumulation_horizon, decumulation_horizon, client_id, is_active to the Goal entity.

Pagination

Example Request

curl -X GET -H "Authorization: Bearer <access_token>" \
"https://[sandbox][api].hydrogenplatform.com/nucleus/v1/account?
    page=0&size=10&order_by=id&ascending=true"

Example Response

{
    "content": [
    ],
    "first": true,
    "last": false,
    "number_of_elements": 10,
    "total_elements": 29,
    "total_pages": 3,
    "size": 10,
    "number": 0,
    "sort": [
        {
            "direction": "ASC",
            "property": "id",
            "ignore_case": false,
            "null_handling": "NATIVE",
            "ascending": true,
            "descending": false
        }
]

For API resources that return a large volume of results you may use pagination. When using these “List all” API methods, rather than returning a large list of results, the results will be paginated by default. Please note that pagination is not available on some API resources, specified in the description of the resource.

ARGUMENTS

Parameter Type Description
page
optional
integer Page number for the page that should be returned as the starting page. For example, if this is specified as 0, then the first page of the results will be shown, if it is set as 3 then the third page of the results will be shown, and so on. The default is 0.
size
optional
integer The number or records to be included per page. The default is 25. There is no max value.
order_by
optional
string The field in the response body to order the list by. Default is update_date.
ascending
optional
boolean If true, order the results in ascending order. For an alphabetical result this would be A-Z. If false, order the results in descending order. For an alphabetical result this would be Z-A. Default is false which would order by descending.

Filters

Example Requests

Filter the Account object to pull back all accounts that are a specified account type:

/account?filter=account_type==e4f07fc6-1020-43b8-a1ce-18031671e8e0

Filter the Account object to pull back all accounts that are assigned to a specified goal, which is an object embedded in Account:

/account?filter=goals.goal_id==f87fd7e1-b73d-40b1-9747-74e2b421dd94

Filter all accounts that are assigned to a specified goal, AND are a specified account type:

/account?filter=goals.goal_id==47608aa1-a0f5-4d1b-957a-9dc58da9193f
;account_type==553b8534-c406-4ded-9045-5ee6007c5d91

Every field within an object using the GET method can be filtered except for fields stored under metadata. Filtering is especially useful for calls that return many different fields.

A filter query may consist of one or more logical comparisons:

AND: ; or and
OR: , or or

To group multiple OR statements together, you must add () at the beginning and end of the list of statements

/account?filter=(account_type==553b8534-c406-4ded-9045-5ee6007c5d91,account_type==87e4991b-e2a2-4c14-a3e6-407cbcb01cdf,account_type==b00b6eea-8ab1-4d5a-9c84-4c958d795680);goals.goal_id==47608aa1-a0f5-4d1b-957a-9dc58da9193f

Comparison operators may consist of the following:

Like: =like=
Equal to: ==
Not equal to: !=
Less than: =lt= or <
Less than or equal to: =le= or <=
Greater than: =gt= or >
Greater than or equal to: =ge= or >=
Is Null: =isnull=true or =isnull=false
In: =in=
Not in: =out=

The basic construct for a filtering query is as follows:

/<endpoint>?filter=query

To filter using a simple one word field within an object, the query would be as follows:

/<endpoint>?filter=fieldname==fieldvalue

To filter using a field with multiple words, add quotes to the query string. The query would be as follows:

/<endpoint>?filter=fieldname=="fieldvalue fieldvalue"

To filter using a field with multiple words and any potential special characters, add quotes and URL encode the query string. The query would be as follows:

/<endpoint>?filter=fieldname=="field%40value%20field%25value"

To filter using a field within an embedded object, the query would be as follows:

/<endpoint>?filter=objectname.fieldname==fieldvalue

To filter using the =like= operator, you may include an asterisk * as a wildcard before or after the value (same functionality as % in SQL):

/<endpoint>?filter=fieldname=like=*fieldvalue or /<endpoint>?filter=fieldname=like=*fieldvalue* or /<endpoint>?filter=fieldname=like=fieldvalue* or /<endpoint>?filter=fieldname=like=fieldvalue*fieldvalue

To filter using the =in= or =out= options, include a series of comma-separated values wrapped in parentheses, with no spaces between values. The query would be as follows:

/<endpoint>?filter=fieldname=in=(fieldvalue,fieldvalue,fieldvalue)

Metadata

Many objects support optional metadata fields, as denoted in the documentation. Metadata is intended to allow developers to extend our API and store custom information that is relevant to their business. Some examples may include:

Metadata may consist of any key-value pair you define such as “Age”:”35” or “City”:”New York”

All metadata that is entered will be returned in the JSON and may consist of up to 255 alphanumeric, string, integer, and boolean characters for each key and each value.

When updating the metadata using any of the PUT endpoints, you should provide both the details you wish to maintain as well as the details you wish to update.

Webhooks

Webhook Management

Hydrogen Atom offers webhooks that you may subscribe to and consume 20+ events. Webhooks are useful for building your own alerts service for an application, triggering back office processes, or simply being informed when a new record is created or updated.

Field Type Description
id UUID The id of the webhook
url string The url you want to receive the payloads to
secret string Auto generated base64 encoded salt used to hash and verify the sender of the payload. You may either store for each webhook subscription or call the endpoint to retrieve it.
atom_service array The array of Atom services for a webhook to notify
is_active boolean Indicates if this webhook is active
secondary_id string Alternate id that can be used to identify the webhook such as an internal id
create_date timestamp Timestamp for the date and time that the webhook was created
update_date timestamp Timestamp for the date and time that the webhook was last updated

Depending on your atom_service settings, Atom will send a payload to the url of your choice. The list of all available atom_service values is as follows:

Atom Service Description
client POST /client
client_verified PUT /client - Update is_verified on request
client_status POST /client_status
client_response POST /client_response
account_status POST /account_status
card POST /card
card_status PUT /card - Update status on card
portfolio_asset_size POST /portfolio_asset_size
portfolio_transaction POST /portfolio_transaction
portfolio_transaction_status PUT /portfolio_transaction - Update status on transaction
portfolio_holding POST /portfolio_holding
aggregation_account POST /aggregation_account
aggregation_account_balance POST /aggregation_account_balance
aggregation_account_transaction POST /aggregation_account_transaction
aggregation_account_transaction_status PUT /aggregation_account_transaction - Update status on transaction
aggregation_account_holding POST /aggregation_account_holding
order_track POST /order_track
bank_link_verified PUT /bank_link - Update is_link_verified on request
funding POST /funding
funding_status PUT /funding - Update funding_status on request
budget POST /budget
document POST /document
document_verified PUT /document - Update is_verified on request
notification_client POST /notification_client
audit_log POST /audit_log
support_ticket POST /support_ticket
feature_track POST /feature_track

List all webhooks

Example Request

curl -X GET -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/webhook"
api_instance = nucleus_api.WebhookApi(nucleus_api.ApiClient(configuration))
try:
    api_response = api_instance.get_webhook_all_using_get()
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_webhook_all_using_get: %s\n" % e)
WebhookApi apiInstance = new WebhookApi();
        try {
            PageWebhook List = apiInstance.getWebhookAllUsingGet(true, null, null, 0, 2);
            System.out.println(List);
        } catch (ApiException e) {
            System.err.println("Exception when calling getWebhookAllUsingGet");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\WebhookApi(
    new GuzzleHttp\Client(),
    $config);
$ascending = false; // bool | ascending
$filter = null; // string | filter
$order_by = null; // string | order_by
$page = 0; // int | page
$size = 10; // int | size

try {
    $webhooklist = $apiInstance->getWebhookAllUsingGet($ascending, $filter, $order_by, $page, $size);
    print_r($webhooklist);
} catch (Exception $e) {
    echo 'Exception when calling WebhookApi->getWebhookAllUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::WebhookApi.new
opts = {
    ascending: false, # BOOLEAN | ascending
    filter: null, # String | filter
    order_by: null, # String | order_by
    page: 0, # Integer | page
    size: 25 # Integer | size
}

begin
  webhooklist = api_instance.get_webhook_all_using_get(opts)
  p webhooklist
rescue NucleusApi::ApiError => e
  puts "Exception when calling WebhookApi->get_webhook_all_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.WebhookApi();
var opts = {
    'ascending': false, // Boolean | ascending
    // 'filter': "", // String | filter
    'orderBy': "update_date", // String | order_by
    'page': 0, // Number | page
    'size': 25 // Number | size
};

var webhooklist = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.getWebhookAllUsingGet(opts, webhooklist)

Example Response

{
  "content": [
    {
        "id": "0bd304f4-9996-4676-9c59-dedf486a7f72",
        "url": "https://www.hydrogenplatform.com/callback/client",
        "secret": "cDMzZjNhMGYyZjdhYjk0OTQxY2QwODE4ZDc3aGY5NDhjZGExMDU2Mg==",
        "is_active": true,
        "atom_service": [
            "client",
            "client_status",
            "client_response"
        ],
        "secondary_id": null,
        "create_date": "2019-11-14T16:34:49.000+0000",
        "update_date": "2019-11-14T18:52:44.000+0000"
    },
    {
        "id": "1f6f3345-737a-400f-b5b8-bdb15382f803",
        "url": "https://www.hydrogenplatform.com/callback/budget",
        "secret":"cTMzZjNiMGYyZjlhYjk0OTQxY2QwODE4ZDc5aHQ5NDVjcmExMDU2Mg==",
        "is_active": true,
        "atom_service": ["budget"],
        "secondary_id": null,
        "create_date": "2019-11-14T17:20:21.000+0000",
        "update_date": "2019-11-14T18:52:44.000+0000"
    }
  ],
  "total_pages": 1,
  "total_elements": 2,
  "last": true,
  "first": true,
  "sort": [
    {
      "direction": "ASC",
      "property": "create_date",
      "ignore_case": false,
      "null_handling": "NATIVE",
      "ascending": true,
      "descending": false
    }
  ],
  "number_of_elements": 2,
  "size": 25,
  "number": 0
}

Get information for all webhooks defined for your tenant.

HTTP REQUEST

GET /webhook

Create a webhook

Example Request

curl -X POST -H "Authorization: Bearer <access_token>" \
    -H "Content-Type: application/json" \
    -d '{
            "url": "https://www.hydrogenplatform.com/callback/budget",
            "atom_service": ["budget"]
        }' "https://[sandbox][api].hydrogenplatform.com/atom/v1/webhook"
api_instance = nucleus_api.WebhookApi(nucleus_api.ApiClient(configuration))
# #Create WebHook
atom_service = "card"
webhook = nucleus_api.Webhook(url="https://www.hydrogenplatform.com/docs/nucleus/v1/#Introduction", atom_service=[atom_service])
try:
    api_response = api_instance.create_webhook_using_post(webhook)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling create_webhook_using_post: %s\n" % e)
WebhookApi apiInstance = new WebhookApi();
        //Create a Webhook
        Webhook webHook = new Webhook();
        webHook.setUrl("https://www.hydrogenplatform.com/docs/nucleus/v1/#Introduction");
        List<Webhook.AtomServiceEnum> atom = new ArrayList<>();
        atom.add(Webhook.AtomServiceEnum.fromValue("budget"));
        webHook.setAtomService(atom);

        try {
            Webhook result = apiInstance.createWebhookUsingPost(webHook);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling createWebhookUsingPost");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\WebhookApi(
    new GuzzleHttp\Client(),
    $config);
//Create Webhook
$webhook = new \com\hydrogen\nucleus\Model\Webhook();


try {
    $webhook->setUrl("https://www.hydrogenplatform.com/docs/nucleus/v1/#Introduction");
    $webhook->setAtomService(["budget"]);
    $result = $apiInstance->createWebhookUsingPost($webhook);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->createWebhookUsingPost: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::WebhookApi.new
#Create Webhoook
webhook = NucleusApi::Webhook.new

begin
  webhook.url = "https://www.hydrogenplatform.com/docs/nucleus/v1/#Introduction"
  webhook.atom_service = "budget"
  result = api_instance.create_webhook_using_post(webhook)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->create_webhook_using_post: #{e}"
end
var apiInstance = new HydrogenNucleusApi.WebhookApi();
//Create a Webhook
var webhook = new AtomServiceEnum.Webhook();
webhook.url = 'https://www.hydrogenplatform.com/docs/nucleus/v1/#Introduction';
var atom = new AtomServiceEnum.AtomServiceEnum('{"feature_track"}');
webhook.atom_service = [atom];



var newwebhook = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.createWebhookUsingPost(webhook, newwebhook)

Example Response

{
    "id": "1f6f3345-737a-400f-b5b8-bdb15382f803",
    "url": "https://www.hydrogenplatform.com/callback/budget",
    "secret":"cTMzZjNiMGYyZjlhYjk0OTQxY2QwODE4ZDc5aHQ5NDVjcmExMDU2Mg==",
    "is_active": true,
    "atom_service": ["budget"],
    "secondary_id": null,
    "update_date": "2019-11-14T17:20:21.000+0000",
    "create_date": "2019-11-14T17:20:21.000+0000"
}

One active webhook is allowed for each atom_service. If there already is an active webhook at the time of creating a new active webhook, the old webhook needs to be deactivated.

HTTP REQUEST

POST /webhook

ARGUMENTS

Parameter Type Required Description
url string required The url you want to receive the payloads to. Only http:// or https:// urls allowed
atom_service array required The array of Atom services for a webhook to notify
is_active boolean optional Indicates if this webhook is active. Defaults to true
secondary_id string optional Alternate id that can be used to identify the webhook such as an internal id

Retrieve a webhook

Example Request

curl -X GET -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/atom/v1/webhook/1f6f3345-737a-400f-b5b8-bdb15382f803"
api_instance = nucleus_api.WebhookApi(nucleus_api.ApiClient(configuration))
try:
    api_response = api_instance.get_webhook_using_get("7e2d43c7-b52e-4333-9b10-fb6b9b0f7606")
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_webhook_using_get: %s\n" % e)
WebhookApi apiInstance = new WebhookApi();
        try {
            Webhook responseWebhook = apiInstance.getWebhookUsingGet(UUID.fromString("390b8afb-fcb0-4df7-a910-0b5f3305e23a"));
            System.out.println(responseWebhook);
        } catch (ApiException e) {
            System.err.println("Exception when calling getWebhookUsingGet");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\WebhookApi(
    new GuzzleHttp\Client(),
    $config);
$webhook_id = "390b8afb-fcb0-4df7-a910-0b5f3305e23a"; // string | UUID webhook_id

try {
    $webhook = $apiInstance->getWebhookUsingGet($webhook_id);
    print_r($webhook);
} catch (Exception $e) {
    echo 'Exception when calling WebhookApi->getWebhookUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::WebhookApi.new
webhook_id = '390b8afb-fcb0-4df7-a910-0b5f3305e23a' # String | UUID webhook_id


begin
  webhook = api_instance.get_webhook_using_get(webhook_id)
  p webhook
rescue NucleusApi::ApiError => e
  puts "Exception when calling WebhookApi->get_webhook_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.WebhookApi();
var webhookID = "390b8afb-fcb0-4df7-a910-0b5f3305e23a";

var opts = {
    'currencyConversion': null, // String | USD
};

var webhook = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.getWebhookUsingGet(webhookID, webhook)

Example Response

{
    "id": "1f6f3345-737a-400f-b5b8-bdb15382f803",
    "url": "https://www.hydrogenplatform.com/callback/budget",
    "secret":"cTMzZjNiMGYyZjlhYjk0OTQxY2QwODE4ZDc5aHQ5NDVjcmExMDU2Mg==",
    "is_active": true,
    "atom_service": ["budget"],
    "secondary_id": null,
    "create_date": "2019-11-14T17:20:21.000+0000",
    "update_date": "2019-11-14T17:20:21.000+0000"
}

Retrieve the information for a specific webhook. The webhook_id must be provided. The endpoint returns the webhook_id and the details for the webhook specified.

HTTP REQUEST

GET /webhook/{webhook_id}

Update a webhook

Example Request

curl -X PUT -H "Authorization: Bearer <access_token>" \
    -H "Content-Type: application/json" \
    -d '{
            "is_active": false
        }' "https://[sandbox][api].hydrogenplatform.com/atom/v1/webhook/1f6f3345-737a-400f-b5b8-bdb15382f803"
api_instance = nucleus_api.WebhookApi(nucleus_api.ApiClient(configuration))
# #Update Webhook
webhook_update = {'is_active': 'true'}
webhook_id = 'c2fd7003-f094-42f5-8e33-4934c8be3373'
try:
    api_response = api_instance.update_webhook_using_put(webhook_update, webhook_id)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling update_webhook_using_put: %s\n" % e)
WebhookApi apiInstance = new WebhookApi();
        //Update a Webhook
        Map map = new HashMap();
        map.put("secondary_id", "null");

        try {
            Webhook response = apiInstance.updateWebhookUsingPut(map, UUID.fromString("c03f5437-58ee-478a-a403-cd8e5bc1d8d4"));
            System.out.println(response);
        } catch (ApiException e) {
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\WebhookApi(
    new GuzzleHttp\Client(),
    $config);
//Update Webhoook
$wwebhook_update = new stdClass();
$webhook_id = "4cd9bac7-364d-4a8d-806f-ce4656864f19";

try {
    $wwebhook_update->is_active = "true";
    $result = $apiInstance->updateWebhookUsingPut($wwebhook_update, $webhook_id);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->updateWebhookUsingPut: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::WebhookApi.new
#Update Webhook
webhook_update = {"atom_service" => 'budget'}
webhook_id = '0fba4bf3-f04e-4df8-ae79-e1c15924261c'
begin
  result = api_instance.update_webhook_using_put(webhook_update, webhook_id)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->update_webhook_using_put: #{e}"
end
var apiInstance = new HydrogenNucleusApi.WebhookApi();
// //Update Webhook
var apiInstance = new HydrogenNucleusApi.WebhookApi();
var callback = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
var webhookupdate = new HydrogenNucleusApi.Webhook();
var webhookid = '4cd9bac7-364d-4a8d-806f-ce4656864f19';

webhookupdate.is_active = "true";
apiInstance.updateWebhookUsingPut(webhookupdate, webhookid, callback)

Example Response

{
    "id": "1f6f3345-737a-400f-b5b8-bdb15382f803",
    "url": "https://www.hydrogenplatform.com/callback/budget",
    "secret":"cTMzZjNiMGYyZjlhYjk0OTQxY2QwODE4ZDc5aHQ5NDVjcmExMDU2Mg==",
    "is_active": false,
    "atom_service": ["budget"],
    "secondary_id": null,
    "create_date": "2019-11-14T17:20:21.000+0000",
    "update_date": "2019-11-14T18:52:44.000+0000"
}

Update a webhook for your tenant. The webhook_id must be provided. To obtain the appropriate webhook_id, use the GET /webhook endpoint to view all of the webhooks for your tenant and their current information.

HTTP REQUEST

PUT /webhook/{webhook_id}

Delete a webhook

Example Request

curl -X DELETE -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/webhook/1f6f3345-737a-400f-b5b8-bdb15382f803"
api_instance = nucleus_api.WebhookApi(nucleus_api.ApiClient(configuration))
# # # #Delete a Webhook
webhook1_id = '20aca348-2074-422f-b481-47a405ded448'
try:
    api_instance.delete_webhook_using_delete(webhook1_id)
except ApiException as e:
    print("Exception when calling delete_webhook_using_delete: %s\n" % e)
WebhookApi apiInstance = new WebhookApi();
        //Delete a Webhook
        try {
            Webhook deleteresponse = apiInstance.deleteWebhookUsingDelete(UUID.fromString("20aca348-2074-422f-b481-47a405ded448"));
            System.out.println(deleteresponse);
        } catch (ApiException e) {
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\WebhookApi(
    new GuzzleHttp\Client(),
    $config);
//Delete Webhook
$webhook_did = "72ad48ad-f1af-4301-8b69-5d0af8b053f3"; // string | UUID account_id

try {
    $apiInstance->deleteWebhookUsingDelete($webhook_did);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->deleteWebhookUsingDelete: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::WebhookApi.new
#Delete Webhook
webhook1_id = '72ad48ad-f1af-4301-8b69-5d0af8b053f3'
begin
  result = api_instance.delete_webhook_using_delete(webhook1_id)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->delete_webhook_using_delete: #{e}"
end
var apiInstance = new HydrogenNucleusApi.WebhookApi();
// // // //Delete a Webhook
var webhookidd = "78ed5ded-d097-4537-b172-e2d00c5b4224";


var deletewebhook = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully.');
    }
};
apiInstance.deleteWebhookUsingDelete(webhookidd, deletewebhook)

Response (204 No Content)

Permanently delete a webhook for your tenant. The webhook_id must be provided. To obtain the appropriate webhook_id, use the GET /webhook endpoint to view all of the webhooks for your tenant. This deletes the webhook_id and the details for the webhook record.

HTTP REQUEST

DELETE /webhook/{webhook_id}

Webhook Security

Example Header Payload

{
    "content-length": "621",
    "accept": "application/json, application/*+json",
    "x-hydrogen-signature": "headers=date content-type content-length content,algorithm=HMAC_SHA_256,signature=YTE3ZjdjZGQ0NDc4MDQ5NmZiOGMyNDg0MzliZWI0MDhkNjU4OGVhZTkxMDM1ZTE4Y2M2MmYxZTM3OWNlODFlMg==",
    "x-hydrogen-service": "portfolio_transaction",
    "date": "2020-03-30 16:41:15",
    "content-type": "application/json",
    "user-agent": "Java/1.8.0_242"
}

Example Hashing

Hash using the SHA-256 algorithm with your secret key created for the service. Take the result and Base64 encode and then compare to the signature in the header

2020-03-30 16:41:15 application/json 621 {
    "id": "099961da-7f41-4309-950f-2b51689a0033",
    "create_date": "2018-01-01T9:00:03.000+0000",
    "update_date": "2018-01-05T21:56:03.000+0000",
    "date": "2018-01-02T00:00:00.000+0000",
    "date_available": null,
    "is_read": false,
    "price": 1,
    "quantity": 9000,
    "currency_code": null,
    "amount": null,
    "balance": null,
    "merchant": null,
    "category": null,
    "subcategory": null,
    "description": null,
    "memo": null,
    "status": null,
    "location": {},
    "security_id": "9679fd84-f6d5-44f9-bba9-a5fcb1b8b028",
    "transaction_code_id": "a65929b6-b0a9-46e5-858a-121f0b10f4fb",
    "portfolio_id": "647c54c3-b649-477e-8cc7-eee56a120dd3",
    "account_id": "647c54c3-b649-477e-8cc7-eee56a120dd3",
    "model_id": "feb846da-a06d-402e-a3bb-abc7260f7138"
}

To securely receive the webhook payload you should verify that the request was made by Hydrogen.

The headers of every payload will include a x-hydrogen-signature that includes a Base64 encoded signature of the following data which has been HMAC SHA-256 hashed using the secret for the webhook:

date content-type content-length content

Each field should be separated by a space. The content will be the json payload of the response body that gets posted.

Using the secret that was received when the webhook was created above, you will then create a Hash-based message authentication code (HMAC) with the SHA-256 algorithm. The result can then be Base64 encoded and compared to the signature in the header. If the two match then you have successfully verified the validity of the webhook.

Idempotency

Example Request

curl -X POST -H "Authorization: Bearer <access_token>" \
    -H "Content-Type: application/json" \
  -H "Idempotency-Key: 099961da-7f41-4309-950f-2b51689a0033" \
    -d '{
          "email": "[email protected]",
          "username": "[email protected]",
          "client_type": "individual",
          "first_name": "John",
          "last_name": "Doe"
      }' "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/client"

An API request is idempotent if it has the same result no matter how many times it is tried. Hydrogen supports idempotency to allow requests to be retried without risk of the operation being performed multiple times. This is useful for requests that involve critical such as payments or account creation to protect against network outages and you are unsure if a previous request had been processed successfully. If you ever have any doubt, always submit the request again with the same idempotency key in the request header to make sure you don’t duplicate the data.

To submit an idempotent request, simply submit any POST request with an Idempotency-Key in the Request Header. If you retry the same request body and endpoint with the Idempotency-Key you will receive a cached version of the original response if it was successfully submitted the first time.

To create a unique Idempotency-Key please one of the libraries below to generate a unique UUID in the language of your choice:

Language Function
C# Guid.NewGuid
Java UUID.randomUUID
Node uuid
PHP uniqid
Python uuid Python 2 / Python 3
Ruby SecureRandom.uuid

Bulk

Bulk POST, PUT, and DELETE data on any entity up to 100 entries at a time. Requests will be sent into a messaging queue and processed asynchronously so you may still perform other processes while this is occurring. You will be able to receive a status report of the bulk operation via a separate service explained below.

Bulk Create

Example Request

curl -X POST -H "Authorization: Bearer <access_token>" \
    -H "Content-Type: application/json" \
    -d '{
        [
          {
            "security_id":"832712b9-3b84-46c6-8a6b-1765697269b4",
            "price":10.20,
            "date": "2019-12-01"
          },
          {
            "security_id":"832712b9-3b84-46c6-8a6b-1765697269b4",
            "price":10.22,
            "date": "2020-01-01"
          },
          {
            "security_id":"832712b9-3b84-46c6-8a6b-1765697269b4",
            "price":10.21,
            "date": "2020-02-01"
          },
          {
            "security_id":"832712b9-3b84-46c6-8a6b-1765697269b4",
            "price":10.23,
            "date": "2020-03-01"
          },
          {
            "security_id":"832712b9-3b84-46c6-8a6b-1765697269b4",
            "price":10.25,
            "date": "2020-04-01"
          }
        ]
      }' "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/bulk/security_price"

Example Response

{
    "id": "356dddbc-cfe5-469c-8988-46afe85651f9",
    "create_date": "2020-04-05T15:20:27.301+0000",
    "update_date": "2020-04-05T15:20:27.301+0000",
    "status": "Not Started"
}

Perform a bulk POST operation on a set of data. The fields required by the entity to create the data must be provided. Each payload should be comma separated. The endpoint returns the status and the id which can be used to retrieve the status of the request.

HTTP REQUEST

POST /bulk/{entity}

Bulk Update

Example Request

curl -X PUT -H "Authorization: Bearer <access_token>" \
    -H "Content-Type: application/json" \
    -d '{
        [
          {
            "id": "78ba9652-3125-4bf4-ba0d-3f95955e9fc4",
            "price": 10.30
          },
          {
            "id": "b2b04268-bc31-4ddc-8b1e-2736c106ed38",
            "price": 10.40
          },
          {
            "id": "ada79898-a59c-4ec7-a77c-bc8a66340feb",
            "price": 10.50
          },
          {
            "id": "f49ae877-c7e9-43f2-95f5-34f79d0cdb78",
            "price": 10.60
          }
        ]
      }' "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/bulk/security_price"

Example Response

{
    "id": "a16038ef-5fa9-4d6f-bc4c-1c2f40914d3a",
    "create_date": "2020-04-05T19:52:27.301+0530",
    "update_date": "2020-04-05T19:52:27.301+0530",
    "status": "Not Started"
}

Perform a bulk PUT operation on a set of data. The unique id of each record that you wish to update must be provided in the body. To obtain the appropriate id, use the GET /{entity} endpoint to view all available ids and their current information. The details to be updated must also be provided. The endpoint returns the status and the id which can be used to retrieve the status of the request.

HTTP REQUEST

PUT /bulk/{entity}

Bulk Delete

Example Request

curl -X DELETE -H "Authorization: Bearer <access_token>" \
    -H "Content-Type: application/json" \
    -d '{
        [
          {
            "id": "78ba9652-3125-4bf4-ba0d-3f95955e9fc4"
          },
          {
              "id": "b2b04268-bc31-4ddc-8b1e-2736c106ed38"
          },
          {
              "id": "ada79898-a59c-4ec7-a77c-bc8a66340feb"
          },
          {
              "id": "f49ae877-c7e9-43f2-95f5-34f79d0cdb78"
          }
        ]
      }' "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/bulk/security_price"

Example Response

{
    "id": "5bfe10bf-416b-4e46-ab76-514a61ae83fc",
    "create_date": "2020-04-05T19:52:27.301+0530",
    "update_date": "2020-04-05T19:52:27.301+0530",
    "status": "Not Started"
}

Perform a bulk DELETE operation on a set of data. The unique id of each record that you wish to update must be provided in the body. To obtain the appropriate id, use the GET /{entity} endpoint to view all available ids and their current information. The endpoint returns the status and the id which can be used to retrieve the status of the request.

HTTP REQUEST

DELETE /bulk/{entity}

Bulk Status

Example Request

curl -X GET -H "Authorization: Bearer ce77358c-1e00-4e75-8deb-bd35c4ad8e65" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/bulk/status/356dddbc-cfe5-469c-8988-46afe85651f9"
api_instance = nucleus_api.BulkApi(nucleus_api.ApiClient(configuration))
try:
    api_response = api_instance.get_bulk_status_using_get("2954893a-a7d2-4048-858d-941c2411d264")
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_bulk_status_using_get: %s\n" % e)
BulkApi apiInstance = new BulkApi();
        try {
            BulkTransactionVO responseBulk = apiInstance.getBulkStatusUsingGet(UUID.fromString("2954893a-a7d2-4048-858d-941c2411d264"));
            System.out.println(responseBulk);
        } catch (ApiException e) {
            System.err.println("Exception when calling getBulkStatusUsingGet");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\BulkApi(
    new GuzzleHttp\Client(),
    $config);
$id = "2954893a-a7d2-4048-858d-941c2411d264"; // string | UUID Bulk Transaction Id

try {
    $bulkstatus = $apiInstance->getBulkStatusUsingGet($id);
    print_r($bulkstatus);
} catch (Exception $e) {
    echo 'Exception when calling BulkApi->getBulkStatusUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::BulkApi.new
id = '2954893a-a7d2-4048-858d-941c2411d264' # String | UUID Bulk Transaction Id
begin
  result = api_instance.get_bulk_status_using_get(id)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling BulkApi->get_bulk_status_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.BulkApi();
var bulkId = "2954893a-a7d2-4048-858d-941c2411d264";

var bulkstatus = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.getBulkStatusUsingGet(bulkId, bulkstatus)

Example Response (Complete - Success)

{
    "id": "5bfe10bf-416b-4e46-ab76-514a61ae83fc",
    "status": "Complete",
    "success": [
        {
            "id": "78ba9652-3125-4bf4-ba0d-3f95955e9fc4",
            "status_code": 204
        },
        {
            "id": "f49ae877-c7e9-43f2-95f5-34f79d0cdb78",
            "status_code": 204
        },
        {
            "id": "b2b04268-bc31-4ddc-8b1e-2736c106ed38",
            "status_code": 204
        },
        {
            "id": "ada79898-a59c-4ec7-a77c-bc8a66340feb",
            "status_code": 204
        }
    ],
    "error": []
}

Example Response (Complete - Error)

{
    "id": "356dddbc-cfe5-469c-8988-46afe85651f9",
    "status": "Complete",
    "success": [],
    "error": [
        {
            "security_id": "832712b9-3b84-46c6-8a6b-1765697269b4",
            "price": 10.20,
            "error_message": "The following field is required and missing data:date.",
            "status_code": 400
        },
        {
            "security_id": "832712b9-3b84-46c6-8a6b-1765697269b4",
            "price": 10.23,
            "error_message": "The following field is required and missing data:date.",
            "status_code": 400
        },
        {
            "security_id": "832712b9-3b84-46c6-8a6b-1765697269b4",
            "price": 10.21,
            "error_message": "The following field is required and missing data:date.",
            "status_code": 400
        }
    ]
}

Example Response (Not Started)

{
    "id": "8c3c23a8-78a1-46ce-8afa-3751ec72110a",
    "status": "Not Started",
    "progress": "0 of 50 processed."
}

Example Response (In Progress)

{
    "id": "8c3c23a8-78a1-46ce-8afa-3751ec72110a",
    "status": "In Progress",
    "progress": "25 of 50 processed."
}

Get the status of a bulk operation. The unique bulk_id must be provided along with the entity that the bulk operation was submitted for. To obtain the appropriate bulk_id, please save the id that you receive in the response after performing the bulk request.

HTTP REQUEST

GET /bulk/status/{bulk_id}

General

Account

Account Management

Accounts are created below clients to represent an account on your firm’s platform, such as a bank account. One or more portfolios can be created below an account and map to models. Accounts will subscribe to an allocation for investment accounts. This will determine the composition of the portfolios and models below the account. Generally, an account will subscribe to an allocation for each goal that is associated with the account. An account may also be associated with one or more goals.

Field Type Description
id UUID The id for the account
name string Name of the account
account_type_id UUID The id of the account type for the account. Account types are defined by your firm
account_number string Account number for the account. Differs from the id for the account which is auto generated.
managed boolean Indicates if the account is managed by a 3rd party such as an advisor or self-directed by the client. Defaults to true, or that it’s managed
discretionary boolean Indicates if the account is discretionary or non-discretionary. A discretionary account gives a 3rd party such as an advisor access to perform transactions in an account with no permission, while a non-discretionary account requires permission for every transaction. Defaults to true, or that it’s discretionary account
clients map List of clients associated with the account and their association type as well as signature data
      client_id UUID The id of a client associated with the account
      client_account_association_type string The role of the client as it relates to the account defined by your firm. Roles may be joint, owner, trustee, viewer, or admin. Automatically grants the FULL_AUTHORITY permission type to clients mapped to the account with the client_account_association_type of owner, joint, trustee or admin and the INQUIRY_ACCESS permission type to clients mapped to the account with the client_account_association_type of viewer
      signature_data longtext Stored signature for the client on the account such as a Base30 or Base64 string
goals map List of goals mapped to the account with information such as target amount and horizon. You may also store goals data under the goal entity, which is recommended if a goal can be assigned to multiple accounts. This map only stores goals attributes, to assign an account to a goal use the account-allocation service.
      goal_id UUID The id of a goal mapped to the account
      goal_amount double Monetary amount provided by the client as the target amount to be reached within the goal horizon. May be used in conjunction with the Proton API.
      accumulation_horizon double Time horizon of the goal during the accumulation phase, in years. May be used in conjunction with the Proton API.
      decumulation_horizon double Time horizon of the goal during the decumulation phase, in years. If the goal is an accumulation goal, then this can be 0 or omitted entirely. May be used in conjunction with the Proton API.
currency_code string Alphabetic currency code for the base currency of the account, limited to 3 characters. See currency codes
status string Status of the account such as “Registered” or “Active”
is_active boolean Indicates if the account is active. Defaults to true which indicates that it is currently active.
metadata map Custom information associated with the entity in the format key:value
See Metadata
secondary_id string Alternate id that can be used to identify the object such as an internal id
create_date timestamp Timestamp for the date and time that the record was created
update_date timestamp Timestamp for the date and time that the record was last updated

List all accounts

Example Request

curl -X GET -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/account"
api_instance = nucleus_api.AccountApi(nucleus_api.ApiClient(configuration))
# List all Account
try:
    api_response = api_instance.get_account_all_using_get()
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_account_all_using_get: %s\n" % e)
AccountApi apiInstance = new AccountApi();
        try {
            PageAccount List = apiInstance.getAccountAllUsingGet(true, null, null, 1, 10);
            System.out.println(List);
        } catch (ApiException e) {
            System.err.println("Exception when calling getAccountAllUsingGet");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\AccountApi(
    new GuzzleHttp\Client(),
    $config
);
$ascending = false; // bool | ascending
$filter = null; // string | filter
$order_by = null; // string | order_by
$page = 0; // int | page
$size = 10; // int | size

try {
    $accountlist = $apiInstance->getAccountAllUsingGet($ascending, $filter, $order_by, $page, $size);
    print_r($accountlist);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->getAccountAllUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::AccountApi.new
  #List all accounts
  resultlist = api_instance.get_account_all_using_get(opts)
  p resultlist
rescue NucleusApi::ApiError => e
  puts "Exception when calling AccountApi->get_account_all_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.AccountApi();
var opts = {
    'ascending': false, // Boolean | ascending
    // 'filter': "", // String | filter
    'orderBy': "update_date", // String | order_by
    'page': 0, // Number | page
    'size': 25 // Number | size
};

var accountlist = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.getAccountAllUsingGet(opts, accountlist);

Example Response

{
    "content": [
        {
            "id": "099961da-7f41-4309-950f-2b51689a0033",
            "create_date": "2017-01-03T00:00:00.000+0000",
            "update_date": "2017-01-05T00:00:00.000+0000",
            "secondary_id": "7289243787238",
            "managed": true,
            "discretionary": true,
            "name": "Joint Investment Account",
            "account_type_id": "647c54c3-b649-477e-8cc7-eee56a120dd3",
            "account_number": null,
            "clients": [
                {
                    "client_id": "099961da-7f41-4309-950f-2b51689a0033",
                    "client_account_association_type": "joint"
                }
            ],
            "goals": [
                {
                    "goal_id": "099961da-7f41-4309-950f-2b51689a0033",
                    "goal_amount": 200000,
                    "accumulation_horizon": 35,
                    "decumulation_horizon": 25
                }
            ],
            "currency_code": "USD",
            "status": null,
            "is_active": true,
            "metadata": {}
        },
        {
            "id": "107516c3-9035-4811-af7c-501be5a1fe26",
            "create_date": "2017-02-14T00:00:00.000+0000",
            "update_date": "2017-02-15T09:00:00.000+0000",
            "secondary_id": null,
            "managed": false,
            "discretionary": true,
            "name": "Goals Account",
            "account_type_id": "39770e8d-890d-485b-822e-5a1578f26d47",
            "account_number": null,
            "clients": [
                {
                    "client_id": "107516c3-9035-4811-af7c-501be5a1fe26",
                    "client_account_association_type": "owner"
                }
            ],
            "goals": [
                {
                    "goal_id": "647c54c3-b649-477e-8cc7-eee56a120dd3",
                    "goal_amount": 40000,
                    "accumulation_horizon": 10,
                }
            ],
            "status": null,
            "is_active": true,
            "metadata": {}
        }
    ],
    "last": false,
    "total_pages": 1,
    "total_elements": 2,
    "sort": [
        {
            "direction": "DESC",
            "property": "updateDate",
            "ignore_case": false,
            "null_handling": "NATIVE",
            "descending": true,
            "ascending": false
        }
    ],
    "first": true,
    "number_of_elements": 2,
    "size": 25,
    "number": 0
}

Get information for all accounts for all clients defined for your tenant. You can filter using a unique client_id to view the accounts for a client. To identify the appropriate client_id, use the GET /client endpoint to see all clients defined for your tenant. Note that the information for the clients associated with the account, the goals information, and the metadata information are stored as nested objects within the account object.

HTTP REQUEST

GET /account

Create an account

Example Request

curl -X POST -H "Authorization: Bearer <access_token>" \
-H "Content-Type: application/json" \
-d '{
      "secondary_id": "7289243787238",
      "name": "Investment Account 60",
      "account_type_id": "eb3d7f60-a133-4ca9-815f-3677bcdc23a3",
      "clients": [
        {
            "client_id": "199a8c08-cdd5-4c8c-8abf-535447cea11b",
            "client_account_association_type": "owner"
        }
      ],
      "goals": [
        {
            "goal_id": "647c54c3-b649-477e-8cc7-eee56a120dd3",
            "goal_amount": 100000,
            "accumulation_horizon": 15
        }
      ]
    }' "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/account"
api_instance = nucleus_api.AccountApi(nucleus_api.ApiClient(configuration))
# # Create a Account
account = nucleus_api.Account(account_type_id="4bc96fae-be89-4fa7-bbb8-08eb0d43db94", name="new Account");
try:
    api_response = api_instance.create_account_using_post(account);
    pprint(api_response)
except ApiException as e:
    print("create_account_using_post: %s\n" % e)
AccountApi apiInstance = new AccountApi();
        Account createAccount = new Account();
        createAccount.setName("Ab Corp");
        createAccount.accountTypeId(UUID.fromString("de61ee3d-b14d-4646-814d-6629a8627934"));

        try {
            Account result = apiInstance.createAccountUsingPost(createAccount);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling createAccountUsingPost");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\AccountApi(
    new GuzzleHttp\Client(),
    $config
);
//Create Account
$account = new \com\hydrogen\nucleus\Model\Account();

try {
    $account->setName("ABC");
    $account->setAccountTypeId("de61ee3d-b14d-4646-814d-6629a8627934");
    $result = $apiInstance->createAccountUsingPost($account);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->createAccountUsingPost: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::AccountApi.new
#Create Account
account = NucleusApi::Account.new

begin
  account.name = "AB Corp"
  account.account_type_id = "de61ee3d-b14d-4646-814d-6629a8627934"
  result = api_instance.create_account_using_post(account)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling FinancialStatementApi->create_account_using_post: #{e}"
end
var apiInstance = new HydrogenNucleusApi.AccountApi();
var account1 = new HydrogenNucleusApi.Account();// SpendingControl | spendingControl

account1.name = "New Account";
account1.account_type_id = 'de61ee3d-b14d-4646-814d-6629a8627934';


var accountnew = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.createAccountUsingPost(account1, accountnew);

Example Response

{
    "id": "199a8c08-cdd5-4c8c-8abf-535447cea11b",
    "create_date": "2017-03-01T00:00:00.000+0000",
    "secondary_id": "7289243787238",
    "managed": true,
    "discretionary": true,
    "name": "Investment Account 60",
    "account_type_id": "eb3d7f60-a133-4ca9-815f-3677bcdc23a3",
    "account_number": null,
    "clients": [
        {
            "client_id": "199a8c08-cdd5-4c8c-8abf-535447cea11b",
            "client_account_association_type": "owner"
        }
    ],
    "goals": [
        {
            "goal_id": "647c54c3-b649-477e-8cc7-eee56a120dd3",
            "goal_amount": 100000,
            "accumulation_horizon": 15
        }
    ],
    "status": null,
    "is_active": true,
    "metadata": {}
}

Create an account under a client. In order to create an account, the client must have already registered and the client_id must be provided. To identify the appropriate client_id, use the GET /client endpoint to see all clients for your tenant. The client can be an internal user. The endpoint returns an account_id that can then be mapped to other entities such as goal, allocation, and portfolio or used to create funding requests.

HTTP REQUEST

POST /account

ARGUMENTS

Parameter Type Required Description
name string required Name of the account
account_type_id UUID required The id of the account type for the account. Account types are defined by your firm
account_number string optional Account number for the account. Differs from the id for the account which is auto generated.
managed boolean optional Indicates if the account is managed by a 3rd party such as an advisor or self-directed by the client. Defaults to true, or that it’s managed
discretionary boolean optional Indicates if the account is discretionary or non-discretionary. A discretionary account gives a 3rd party such as an advisor access to perform transactions in an account with no permission, while a non-discretionary account requires permission for every transaction. Defaults to true, or that it’s discretionary account
clients map optional List of clients associated with the account and their association type as well as signature data
      client_id UUID required The id of a client associated with the account
      client_account_association_type string required The role of the client as it relates to the account defined by your firm. Roles may be joint, owner, trustee, viewer, or admin. Automatically grants the FULL_AUTHORITY permission type to clients mapped to the account with the client_account_association_type of owner, joint, trustee or admin and the INQUIRY_ACCESS permission type to clients mapped to the account with the client_account_association_type of viewer
      signature_data longtext optional Stored signature for the client on the account such as a Base30 or Base64 string
goals map optional List of goals mapped to the account with information such as target amount and horizon. You may also store goals data under the goal entity, which is recommended if a goal can be assigned to multiple accounts. This map only stores goals attributes, to assign an account to a goal use the account-allocation service.
      goal_id UUID required The id of a goal mapped to the account
      goal_amount double optional Monetary amount provided by the client as the target amount to be reached within the goal horizon. May be used in conjunction with the Proton API. Option to also store under the goal entity
      accumulation_horizon double optional Time horizon of the goal during the accumulation phase, in years. May be used in conjunction with the Proton API. Option to also store under the goal entity
      decumulation_horizon double optional Time horizon of the goal during the decumulation phase, in years. If the goal is an accumulation goal, then this can be 0 or omitted entirely. May be used in conjunction with the Proton API. Option to also store under the goal entity
currency_code string optional Alphabetic currency code for the base currency of the account, limited to 3 characters. See currency codes
status string optional Status of the account such as “Registered” or “Active”
is_active boolean optional Indicates if the account is active. Defaults to true which indicates that it is currently active.
metadata map optional Custom information associated with the account in the format key:value
See Metadata
secondary_id string optional Alternate id that can be used to identify the object such as an internal id

Subscribe an account

Example Request

curl -X POST -H "Authorization: Bearer <access_token>" \
    -H "Content-Type: application/json" \
    -d ' {
            "current_weight" : "50",
            "strategic_weight": "50",
            "date": "2018-06-28",
            "allocation_id": "cb831ad5-18d0-48b3-9d8e-8db318b51895",
            "goal_id": "a65929b6-b0a9-46e5-858a-121f0b10f4fb"
         }' "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/account/dbebf51f-d325-4cdd-b043-78958e29bdce/subscribe"
api_instance = nucleus_api.AccountApi(nucleus_api.ApiClient(configuration))
# # Subscribe an Account
accountSubscribe = nucleus_api.AccountAllocationMapping(_date="2020-10-10", current_weight= "30", strategic_weight= "40")
account_id = '88bc6be8-58b2-43c5-9dc2-081ea88a3b78'
try:
    api_response = api_instance.subscribe_account_using_post(accountSubscribe, account_id)
    pprint(api_response)
except ApiException as e:
    print("subscribe_account_using_post: %s\n" % e)
AccountApi apiInstance = new AccountApi();
        //Subscribe an Account
        AccountAllocationMapping subscribe = new AccountAllocationMapping();
        subscribe.accountId(UUID.fromString("88bc6be8-58b2-43c5-9dc2-081ea88a3b78"));
        subscribe.allocationId(UUID.fromString("d5529e8d-03d6-452e-9372-f3af8275dab5"));
        subscribe.date(startdate);
        subscribe.currentWeight(0.88);
        subscribe.strategicWeight(0.99);

        try {
            List<Portfolio> result = apiInstance.subscribeAccountUsingPost(UUID.fromString("88bc6be8-58b2-43c5-9dc2-081ea88a3b78"), subscribe);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling subscribeAccountUsingPost");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\AccountApi(
    new GuzzleHttp\Client(),
    $config
);
//Subscribe ACcount
$account_subscribe = new \com\hydrogen\nucleus\Model\AccountAllocationMapping();
$account_id = "e06fcffd-f92d-4fa0-b230-e8dceb6a2e91";

try {
    $account_subscribe->setAllocationId('d5529e8d-03d6-452e-9372-f3af8275dab5');
    $account_subscribe->setDate("2020-10-10");
    $account_subscribe->setStrategicWeight("20");
    $account_subscribe->setCurrentWeight("30");
    $result = $apiInstance->subscribeAccountUsingPost($account_id, $account_subscribe);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->subscribeAccountUsingPost: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::AccountApi.new
#Subscribe Account
subscription = NucleusApi::AccountAllocationMapping.new
account_id = "88bc6be8-58b2-43c5-9dc2-081ea88a3b78"

begin
  subscription.account_id = "88bc6be8-58b2-43c5-9dc2-081ea88a3b78"
  subscription.allocation_id = "d5529e8d-03d6-452e-9372-f3af8275dab5"
  subscription.current_weight = "30"
  subscription.strategic_weight = "40"
  subscription.date = "2020-10-10"
  result = api_instance.subscribe_account_using_post(subscription, account_id)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->create_account_type_using_post: #{e}"
end
var apiInstance = new HydrogenNucleusApi.AccountApi();
//Subscribe Account

var accountsubscribe = new HydrogenNucleusApi.AccountAllocationMapping();
accountsubscribe.account_id = '88bc6be8-58b2-43c5-9dc2-081ea88a3b78';
accountsubscribe.allocation_id = 'd5529e8d-03d6-452e-9372-f3af8275dab5';
accountsubscribe.date = "2020-10-10";
accountsubscribe.current_weight = "20";
accountsubscribe.strategic_weight = "10";


var accountsubscribenew = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.subscribeAccountUsingPost(accountsubscribe, accountsubscribenew)

Example Response

{
    "id": "199a8c08-cdd5-4c8c-8abf-535447cea11b",
    "create_date": "2017-03-01T00:00:00.000+0000",
    "secondary_id": "7289243787238",
    "managed": true,
    "discretionary": true,
    "name": "Investment Account 60",
    "account_type_id": "eb3d7f60-a133-4ca9-815f-3677bcdc23a3",
    "account_number": null,
    "clients": [
        {
            "client_id": "199a8c08-cdd5-4c8c-8abf-535447cea11b",
            "client_account_association_type": "owner"
        }
    ],
    "goals": [
        {
            "goal_id": "647c54c3-b649-477e-8cc7-eee56a120dd3",
            "goal_amount": 100000,
            "accumulation_horizon": 15
        }
    ],
    "status": null,
    "is_active": true,
    "metadata": {}
}

Example Response

[
    {
        "id": "ab70c3e0-beec-4165-b08e-eef78e3f3962",
        "create_date": "2018-06-28T18:17:23.579+0000",
        "update_date": "2018-06-28T18:17:23.579+0000",
        "description": "High Income Stock",
        "name": "High-Income Stock",
        "percentage": 25,
        "account_id": "dbebf51f-d325-4cdd-b043-78958e29bdce",
        "model_id": "62fd0a9f-4bac-4b1d-94d2-2c5ea2adca3d",
        "metadata": {}
    },
    {
        "id": "54c97821-910c-4199-9f8d-7ba94a56a80d",
        "create_date": "2018-06-28T18:17:23.579+0000",
        "update_date": "2018-06-28T18:17:23.579+0000",
        "description": "Tactical Industrial Stock",
        "name": "Industrial Stocks",
        "percentage": 25,
        "account_id": "dbebf51f-d325-4cdd-b043-78958e29bdce",
        "model_id": "778b8996-6579-46d9-86ce-a097f189ac7f",
        "metadata": {}
    },
    {
        "id": "d206b198-960a-4e8c-a9e3-83958b5ccb96",
        "create_date": "2018-06-28T18:17:23.579+0000",
        "update_date": "2018-06-28T18:17:23.579+0000",
        "description": "Dynamic ESG Nasdaq Stock",
        "name": "Concentrated Aggressive SRI Core",
        "percentage": 50,
        "account_id": "dbebf51f-d325-4cdd-b043-78958e29bdce",
        "model_id": "88d8f74a-0959-410c-8d01-09cf8f7fe55d",
        "metadata": {}
    }
]

After creating an account, you may create portfolios for the account to track a client’s investment, savings, or insurance products. The composition of each portfolio is determined by the models in each allocation that the portfolio is subscribed to. This endpoint combines the following three actions into one workflow:

1) Create a relationship between an account and an allocation
2) Retrieve the allocation’s model composition
3) Create portfolios for the account that subscribe to models in the allocation

The endpoint takes in an account_id in the URL and the same parameters as the POST /account_allocation endpoint and returns ids for the portfolios created. The details for the portfolios such as the name and description are taken from the corresponding model.

HTTP REQUEST

POST /account/{account_id}/subscribe

ARGUMENTS

Parameter Type Required Description
current_weight double required Current percentage of the account’s total value that should be directed towards the allocation; ex. 20 representing 20%. The current weights for all allocations below an account must add up to 100. If the allocation is the only one, enter 100
strategic_weight double required Strategic percentage of the account’s total value that should be directed towards the allocation; ex. 20 representing 20%. The strategic weights for all allocations below an account must add up to 100. If the allocation is the only one, enter 100
date date required Date of the account-allocation mapping used for historical tracking
allocation_id UUID required The id of the allocation that is part of the account-allocation mapping
goal_id UUID optional The id of the goal that is associated with this account-allocation mapping

RESPONSE

Field Type Description
id UUID The id of the portfolio
name string Name of the portfolio such as “Stock”
account_id UUID The id of the account to which the portfolio belongs
model_id UUID The id of the model to which the portfolio subscribes
percentage double Weight of the portfolio as a percentage of an account based on the weight of the portfolio’s model within the account’s allocation; ex. 20 representing 20%. If the account only has one portfolio input 100
description string Description for the portfolio such as “Stock Portfolio”
metadata map Custom information associated with the portfolio in the format key:value. See Metadata
secondary_id string Alternate id that can be used to identify the object such as an internal id
create_date timestamp Timestamp for the date and time that the record was created
update_date timestamp Timestamp for the date and time that the record was last updated

Retrieve an account

Example Request

curl -X GET -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/account/199a8c08-cdd5-4c8c-8abf-535447cea11b"
api_instance = nucleus_api.AccountApi(nucleus_api.ApiClient(configuration))
try:
    api_response = api_instance.get_account_using_get("39c8aff8-ee6b-4e6e-9968-df04709dfb00")
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_account_using_get: %s\n" % e)
AccountApi apiInstance = new AccountApi();
try {
            Account accountresponse = apiInstance.getAccountUsingGet(UUID.fromString("2a13b913-1aa0-4e86-ac35-a6932307dcb8"));
            System.out.println(accountresponse);
        } catch (ApiException e) {
            System.err.println("Exception when calling getAccountUsingGet");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\AccountApi(
    new GuzzleHttp\Client(),
    $config
);
$account_id = "2a13b913-1aa0-4e86-ac35-a6932307dcb8";

try {
    $account = $apiInstance->getAccountUsingGet($account_id);
    print_r($account);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->getAccountUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::AccountApi.new
account_id = '2a13b913-1aa0-4e86-ac35-a6932307dcb8' # String | UUID account_id
begin
  #Retrieve an account
  result = api_instance.get_account_using_get(account_id)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling AccountApi->get_account_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.AccountApi();
var accountId = "88bc6be8-58b2-43c5-9dc2-081ea88a3b78";


var account = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.getAccountUsingGet(accountId, account)

Example Response

{
    "id": "199a8c08-cdd5-4c8c-8abf-535447cea11b",
    "create_date": "2017-03-01T00:00:00.000+0000",
    "update_date": "2018-01-05T00:00:00.000+0000",
    "managed": true,
    "discretionary": true,
    "name": "Investment Account 60",
    "account_type_id": "eb3d7f60-a133-4ca9-815f-3677bcdc23a3",
    "account_number": null,
    "clients": [
        {
            "client_id": "199a8c08-cdd5-4c8c-8abf-535447cea11b",
            "client_account_association_type": "owner"
        }
    ],
    "goals": [
        {
            "goal_id": "647c54c3-b649-477e-8cc7-eee56a120dd3",
            "goal_amount": 100000,
            "accumulation_horizon": 15
        }
    ],
    "status": null,
    "is_active": true,
    "metadata": {}
}

Retrieve the information for a specific account associated with a client. The unique account_id must be provided. The endpoint returns the account_id and details for the account specified. Note that the information for the clients associated with the account, the goals information, and the metadata information are stored as nested objects within the account object.

HTTP REQUEST

GET /account/{account_id}

Update an account

Example Request

curl -X PUT -H "Authorization: Bearer <access_token>" \
-H "Content-Type: application/json" \
-d '{
      "name": "Investment Account 60",
      "account_type_id": "eb3d7f60-a133-4ca9-815f-3677bcdc23a3",
      "clients": [
        {
            "client_id": "199a8c08-cdd5-4c8c-8abf-535447cea11b",
            "client_account_association_type": "owner"
        }
      ],
      "goals": [
        {
            "goal_id": "647c54c3-b649-477e-8cc7-eee56a120dd3",
            "goal_amount": 100000,
            "accumulation_horizon": 15
        }
      ]
    }' "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/account/199a8c08-cdd5-4c8c-8abf-535447cea11b"
api_instance = nucleus_api.AccountApi(nucleus_api.ApiClient(configuration))
# Update Account
account_update = {'name': 'New Name'} # object | spending_control
account_id = 'a85769ac-3567-45d3-91d3-2970b85c5bd7' # str | UUID spending_control_id

try:
    api_response = api_instance.update_account_using_put(account_update, account_id);
    pprint(api_response)
except ApiException as e:
    print("Exception when calling update_account_using_put: %s\n" % e)
AccountApi apiInstance = new AccountApi();
        //Update Account
        Map map = new HashMap();
        map.put("name", "Major Account");

        try {
            Account response = apiInstance.updateAccountUsingPut(map, UUID.fromString("d5144cbb-64c8-4f4e-9ee2-28a07b003dc3"));
            System.out.println(response);
        } catch (ApiException e) {
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\AccountApi(
    new GuzzleHttp\Client(),
    $config
);
//Update Account
$account_update = new stdClass();
$account_id = "e06fcffd-f92d-4fa0-b230-e8dceb6a2e91";

try {
    $account_update->name = "New";
    $result = $apiInstance->updateAccountUsingPut($account_update, $account_id);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->updateAccountUsingPut: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::AccountApi.new
#Update FAccount

account_update = {"name" => 'ABc'}
account_id = 'a6324427-597a-4c8e-88ed-4e640944f4c5'
begin
  result = api_instance.update_account_using_put(account_update, account_id)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling FinancialStatementApi->update_account_using_put: #{e}"
end
var apiInstance = new HydrogenNucleusApi.AccountApi();
//Update Account
var apiInstance = new HydrogenNucleusApi.AccountApi();
var callback = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
var account = new HydrogenNucleusApi.Account();
var accountId = "c8300543-952e-4e0e-a996-f162e9d50796";

account.currency_code = 'INR';
apiInstance.updateAccountUsingPut(account, accountId, callback)

Example Response

{
    "id": "199a8c08-cdd5-4c8c-8abf-535447cea11b",
    "create_date": "2017-03-01T00:00:00.000+0000",
    "update_date": "2018-01-05T00:00:00.000+0000",
    "managed": true,
    "discretionary": true,
    "name": "Investment Account 60",
    "account_type_id": "eb3d7f60-a133-4ca9-815f-3677bcdc23a3",
    "account_number": null,
    "clients": [
        {
            "client_id": "199a8c08-cdd5-4c8c-8abf-535447cea11b",
            "client_account_association_type": "owner"
        }
    ],
    "goals": [
        {
            "goal_id": "647c54c3-b649-477e-8cc7-eee56a120dd3",
            "goal_amount": 100000,
            "accumulation_horizon": 15
        }
    ],
    "status": null,
    "is_active": true,
    "metadata": {}
}

Update the information for an account. The unique account_id must be provided. To obtain the appropriate account_id, use the GET /account endpoint to view all accounts defined for your tenant and their current information. The details to be updated must also be provided. The endpoint returns the account_id and the details for the account. If you wish to mark the account as closed without permanently deleting it, use this endpoint to update the managed field to false.

HTTP REQUEST

PUT /account/{account_id}

Delete an account

Example Request

curl -X DELETE -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/account/199a8c08-cdd5-4c8c-8abf-535447cea11b"
api_instance = nucleus_api.AccountApi(nucleus_api.ApiClient(configuration))
# Delete a Account
account_id = '5dec562e-d228-498c-866d-7d7596cd39fd'
try:
    api_instance.delete_account_using_delete(account_id)
except ApiException as e:
    print("Exception when calling delete_account_using_delete: %s\n" % e)
AccountApi apiInstance = new AccountApi();
//       // Delete Account
//        UUID accountId = UUID.fromString("c9866c39-0946-4dc0-b402-1f04a076c99c"); // UUID | UUID account_id
//        try {
//            apiInstance.deleteAccountUsingDelete(accountId);
//        } catch (ApiException e) {
//            System.err.println("Exception when calling AccountApi#deleteAccountUsingDelete");
//            e.printStackTrace();
//        }
$apiInstance = new com\hydrogen\nucleus\Api\AccountApi(
    new GuzzleHttp\Client(),
    $config
);
//Delete Account
$account_did = "6d8a6df9-9ffc-42aa-8bbb-d86b9c6df361"; // string | UUID account_id

try {
    $apiInstance->deleteAccountUsingDelete($account_did);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->deleteAccountUsingDelete: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::AccountApi.new
#Delete Account
account1_id = '536633ff-f0bd-4ead-a1ae-b60c751aef58'
begin
  result = api_instance.delete_account_using_delete(account1_id)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling FinancialStatementApi->delete_account_using_delete: #{e}"
end
var apiInstance = new HydrogenNucleusApi.AccountApi();
//Delete a Account
var accountid1 = "7c6f8aee-f116-4fc5-b78f-337dda3fb230"; // String | spending_control_id


var deleteaccount = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully.');
    }
};
apiInstance.deleteAccountUsingDelete(accountid1, deleteaccount)

Response (204 No Content)

Permanently delete an account under a client. The unique account_id must be provided. To obtain the appropriate account_id, use the GET /account endpoint to view all accounts defined for your tenant. This deletes the account_id and all account record information. If you wish to mark the account as closed without permanently deleting it, use the PUT /account endpoint to update the managed field to false.

HTTP REQUEST

DELETE /account/{account_id}

Account Allocation

Accounts can subscribe to one or more allocations, which can be tracked over time. An account may also optionally map to a goal for goals based investing applications. The account-allocation mapping indicates what percentage of an account’s funds should be directed towards an allocation.

Field Type Description
id UUID The id for the account-allocation mapping
allocation_id UUID The id of the allocation that is part of the account-allocation mapping
current_weight double Current percentage of the account’s total value that should be directed towards the allocation; ex. 20 representing 20%. The current weights for all allocations assigned to an account must add up to 100 on a given date. If the allocation is the only one, enter 100.
strategic_weight double Strategic percentage of the account’s total value that should be directed towards the allocation; ex. 20 representing 20%. The strategic weights for all allocations assigned to an account must add up to 100 on a given date. If the allocation is the only one, enter 100, which is the recommended option. Please check with your back office if you are able to hold multiple allocations within an account.
account_id UUID The id of the account that is part of the account-allocation mapping
date date Date of the account-allocation mapping used for historical tracking
goal_id UUID The id of the goal that is associated with this account-allocation mapping for goals based investing applications. Goals may also be assigned and tracked via portfolios under the account, which is recommended for banking or non 1:1 relationships.

List all account allocations

Example Request

curl -X GET -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/account_allocation"
api_instance = nucleus_api.AccountApi(nucleus_api.ApiClient(configuration))
try:
    api_response = api_instance.get_account_allocation_mapping_all_using_get()
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_account_allocation_mapping_all_using_get: %s\n" % e)
AccountApi apiInstance = new AccountApi();
        try {
            PageAccountAllocationMapping List = apiInstance.getAccountAllocationMappingAllUsingGet(true, null, null, 1, 10);
            System.out.println(List);
        } catch (ApiException e) {
            System.err.println("Exception when calling getAccountAllocationMappingAllUsingGet");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\AccountApi(
    new GuzzleHttp\Client(),
    $config
);
$ascending = false; // bool | ascending
$filter = null; // string | filter
$order_by = null; // string | order_by
$page = 0; // int | page
$size = 10; // int | size

try {
    $accountallocationlist = $apiInstance->getAccountAllocationMappingAllUsingGet($ascending, $filter, $order_by, $page, $size);
    print_r($accountallocationlist);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->getAccountAllocationMappingAllUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::AccountApi.new
opts = {
    ascending: false, # BOOLEAN | ascending
    filter: null, # String | filter
    order_by: null, # String | order_by
    page: 0, # Integer | page
    size: 25 # Integer | size
}

begin
  #List all account allocations
  allocationlist = api_instance.get_account_allocation_mapping_all_using_get(opts)
  p allocationlist
rescue NucleusApi::ApiError => e
  puts "Exception when calling AccountApi->get_account_allocation_mapping_all_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.AccountApi();
var opts = {
    'ascending': false, // Boolean | ascending
    // 'filter': "", // String | filter
    'orderBy': "update_date", // String | order_by
    'page': 0, // Number | page
    'size': 25 // Number | size
};

var accountallocationlist = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};

apiInstance.getAccountAllocationMappingAllUsingGet(opts, accountallocationlist)

Example Response

{
    "content": [
        {
            "id": "000183ac-2288-4564-a76b-119f4694be98",
            "current_weight": 100,
            "date": "2016-01-01",
            "strategic_weight": 100,
            "allocation_id": "7d0ae4cc-94f6-4fde-88e5-507888f9f6c6",
            "goal_id": "647c54c3-b649-477e-8cc7-eee56a120dd3",
            "account_id": "dbebf51f-d325-4cdd-b043-78958e29bdce"
        },
        {
            "id": "0007b32a-5765-48d6-afd0-2d990818bced",
            "current_weight": 50,
            "date": "2017-01-01",
            "strategic_weight": 50,
            "allocation_id": "88eed960-dad5-4954-a4ba-bd120b0e8dfb",
            "goal_id": "2a7a6cb7-ef71-4fe8-9169-2678f3799657",
            "account_id": "1dfb2510-486b-47d7-89b3-c48a24c0e584"
        },
        {
            "id": "000bca42-8461-4248-a5ff-a5d1f5716e27",
            "current_weight": 50,
            "date": "2017-01-01",
            "strategic_weight": 50,
            "allocation_id": "39770e8d-890d-485b-822e-5a1578f26d47",
            "goal_id": "2a7a6cb7-ef71-4fe8-9169-2678f3799657",
            "account_id": "1dfb2510-486b-47d7-89b3-c48a24c0e584"
        }
    ],
    "last": false,
    "total_pages": 1,
    "total_elements": 3,
    "sort": [
        {
            "direction": "DESC",
            "property": "updateDate",
            "ignore_case": false,
            "null_handling": "NATIVE",
            "descending": true,
            "ascending": false
        }
    ],
    "first": true,
    "number_of_elements": 3,
    "size": 25,
    "number": 0
}

Get information for all account-allocation mappings for all accounts defined for your tenant. You can filter using a unique account_id to view the allocations mapping to an account. To identify the appropriate account_id, use the GET /account endpoint to see all accounts defined for your tenant.

HTTP REQUEST

GET /account_allocation

Create an account allocation

Example Request

curl -X POST -H "Authorization: Bearer <access_token>" \
-H "Content-Type: application/json" \
-d '{
      "current_weight": 100,
      "date": "2016-01-01",
      "strategic_weight": 100,
      "allocation_id": "7d0ae4cc-94f6-4fde-88e5-507888f9f6c6",
      "goal_id": "647c54c3-b649-477e-8cc7-eee56a120dd3",
      "account_id": "dbebf51f-d325-4cdd-b043-78958e29bdce"
   }' "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/000183ac-2288-4564-a76b-119f4694be98"
api_instance = nucleus_api.AccountApi(nucleus_api.ApiClient(configuration))
# Create a AccountAllocation
accountAllocation = nucleus_api.AccountAllocationMapping(current_weight=100, strategic_weight=100, _date="2020-10-10", allocation_id="d5529e8d-03d6-452e-9372-f3af8275dab5", account_id="88bc6be8-58b2-43c5-9dc2-081ea88a3b78")
try:
    api_response = api_instance.create_account_allocation_mapping_using_post(accountAllocation);
    pprint(api_response)
except ApiException as e:
    print("create_account_allocation_mapping_using_post: %s\n" % e)
AccountApi apiInstance = new AccountApi();
        //Create a New Account Allocation
        AccountAllocationMapping  createallocation = new AccountAllocationMapping();
        createallocation.currentWeight(100.0);
        createallocation.strategicWeight(50.0);
        createallocation.date(startdate);
        createallocation.allocationId(UUID.fromString("d5529e8d-03d6-452e-9372-f3af8275dab5"));
        createallocation.accountId(UUID.fromString("88bc6be8-58b2-43c5-9dc2-081ea88a3b78"));



        try {
            AccountAllocationMapping result = apiInstance.createAccountAllocationMappingUsingPost(createallocation);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling createAccountAllocationMappingUsingPost");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\AccountApi(
    new GuzzleHttp\Client(),
    $config
);
//Create Account Allocation
$account_allocation = new \com\hydrogen\nucleus\Model\AccountAllocationMapping();

try {
    $account_allocation->setAllocationId("d5529e8d-03d6-452e-9372-f3af8275dab5");
    $account_allocation->setAccountId("88bc6be8-58b2-43c5-9dc2-081ea88a3b78");
    $account_allocation->setCurrentWeight("20");
    $account_allocation->setStrategicWeight("30");
    $account_allocation->setDate("2020-10-10");
    $result = $apiInstance->createAccountAllocationMappingUsingPost($account_allocation);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->createAccountAllocationMappingUsingPost: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::AccountApi.new
#Create Account Allocation
account_allocation = NucleusApi::AccountAllocationMapping.new

begin
  account_allocation.account_id = "88bc6be8-58b2-43c5-9dc2-081ea88a3b78"
  account_allocation.allocation_id = "d5529e8d-03d6-452e-9372-f3af8275dab5"
  account_allocation.current_weight = "20"
  account_allocation.strategic_weight = "40"
  account_allocation.date = "2020-10-10"
  result = api_instance.create_account_allocation_mapping_using_post(account_allocation)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->create_account_allocation_mapping_using_post: #{e}"
end
var apiInstance = new HydrogenNucleusApi.AccountApi();
//Create Account Allocation
var accountallocation1 = new HydrogenNucleusApi.AccountAllocationMapping();
accountallocation1.current_weight = "20";
accountallocation1.strategic_weight = "30";
accountallocation1.date = "2020-10-18";
accountallocation1.allocation_id = 'd5529e8d-03d6-452e-9372-f3af8275dab5';
accountallocation1.account_id = '88bc6be8-58b2-43c5-9dc2-081ea88a3b78';



var accountallocation = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.createAccountAllocationMappingUsingPost(accountallocation1, accountallocation)

Example Response

{
    "id": "000183ac-2288-4564-a76b-119f4694be98",
    "current_weight": 100,
    "date": "2016-01-01",
    "strategic_weight": 100,
    "allocation_id": "7d0ae4cc-94f6-4fde-88e5-507888f9f6c6",
    "goal_id": "647c54c3-b649-477e-8cc7-eee56a120dd3",
    "account_id": "dbebf51f-d325-4cdd-b043-78958e29bdce"
}

Create an account-allocation mapping for an account. This indicates how much of the account’s funds should be directed towards the allocation specified. The account_id and the allocation_id must be provided. To obtain the appropriate account_id use the GET /account endpoint to view all accounts for your tenant. To obtain the appropriate allocation_id use the GET /allocation endpoint to view all allocations defined by your firm. The endpoint returns an account_allocation_id used to manage the account-allocation mapping.

HTTP REQUEST

POST /account_allocation

ARGUMENTS

Parameter Type Required Description
allocation_id UUID required The id of the allocation that is part of the account-allocation mapping
current_weight double required Current percentage of the account’s total value that should be directed towards the allocation; ex. 20 representing 20%. The current weights for all allocations below an account must add up to 100 on a given date. If the allocation is the only one, enter 100
strategic_weight double required Strategic percentage of the account’s total value that should be directed towards the allocation; ex. 20 representing 20%. The strategic weights for all allocations below an account must add up to 100 on a given date. If the allocation is the only one, enter 100, which is recommended. Please check with your back office if you are able to hold multiple allocations within an account.
account_id UUID required The id of the account that is part of the account-allocation mapping
date date required Date of the account-allocation mapping used for historical tracking
goal_id UUID optional The id of the goal that is associated with this account-allocation mapping for goals based investing applications. Goals may also be assigned and tracked via portfolios under the account, which is recommended for banking or non 1:1 relationships.

Retrieve an account allocation

Example Request

curl -X GET -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/account_allocation/000183ac-2288-4564-a76b-119f4694be98"
api_instance = nucleus_api.AccountApi(nucleus_api.ApiClient(configuration))
try:
    api_response = api_instance.get_account_allocation_mapping_using_get("5e632ae9-7800-40a8-8de1-e88377a5699e")
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_account_allocation_mapping_using_get: %s\n" % e)
AccountApi apiInstance = new AccountApi();
        try {
            AccountAllocationMapping allocationResponse = apiInstance.getAccountAllocationMappingUsingGet(UUID.fromString("c3ef99f8-247c-4fc6-b998-9deef235a450"));
            System.out.println(allocationResponse);
        } catch (ApiException e) {
            System.err.println("Exception when calling getAccountAllocationMappingUsingGet");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\AccountApi(
    new GuzzleHttp\Client(),
    $config
);
$account_allocation_id = "c3ef99f8-247c-4fc6-b998-9deef235a450";

try {
    $allocation = $apiInstance->getAccountAllocationMappingUsingGet($account_allocation_id);
    print_r($allocation);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->getAccountAllocationMappingUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::AccountApi.new
account_allocation_id = 'c3ef99f8-247c-4fc6-b998-9deef235a450' # String | UUID account_allocation_id
begin
  #Retrieve an account allocation
  allocation = api_instance.get_account_allocation_mapping_using_get(account_allocation_id)
  p allocation
rescue NucleusApi::ApiError => e
  puts "Exception when calling AccountApi->get_account_allocation_mapping_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.AccountApi();
var accountAllocationID = "0b88309f-bc45-4bd2-b819-3d33e43061f7";


var accountallocationrtrv = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.getAccountAllocationMappingUsingGet(accountAllocationID, accountallocationrtrv)

Example Response

{
    "id": "000183ac-2288-4564-a76b-119f4694be98",
    "current_weight": 100,
    "date": "2016-01-01",
    "strategic_weight": 100,
    "allocation_id": "7d0ae4cc-94f6-4fde-88e5-507888f9f6c6",
    "goal_id": "647c54c3-b649-477e-8cc7-eee56a120dd3",
    "account_id": "dbebf51f-d325-4cdd-b043-78958e29bdce"
}

Retrieve the information for a specific account-allocation mapping for an account. The unique account_allocation_id must be provided. The endpoint returns the account_allocation_id and details for the account-allocation mapping specified.

HTTP REQUEST

GET /account_allocation/{account_allocation_id}

Update an account allocation

Example Request

curl -X PUT -H "Authorization: Bearer <access_token>" \
-H "Content-Type: application/json" \
-d '{
        "current_weight": 100,
        "date": "2016-01-01",
        "strategic_weight": 100,
        "allocation_id": "7d0ae4cc-94f6-4fde-88e5-507888f9f6c6",
        "goal_id": "647c54c3-b649-477e-8cc7-eee56a120dd3",
        "account_id": "dbebf51f-d325-4cdd-b043-78958e29bdce"
    }' "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/account_allocation/000183ac-2288-4564-a76b-119f4694be9"
api_instance = nucleus_api.AccountApi(nucleus_api.ApiClient(configuration))
# Update AccountAllocation
allocation_update = {'current_weight': '200'} # object | spending_control
allocation_id = '6806ed5e-8e16-47cc-bda9-79aabea3ae27' # str | UUID spending_control_id

try:
    api_response = api_instance.update_account_allocation_mapping_using_put(allocation_update, allocation_id);
    pprint(api_response)
except ApiException as e:
    print("Exception when calling update_account_allocation_mapping_using_put: %s\n" % e)
AccountApi apiInstance = new AccountApi();
//        //Update Account Allocation
        Map map1 = new HashMap();
        map.put("current_weight", "0.88");

        try {
            AccountAllocationMapping response = apiInstance.updateAccountAllocationMappingUsingPut(UUID.fromString("6806ed5e-8e16-47cc-bda9-79aabea3ae27"), map1);
            System.out.println(response);
        } catch (ApiException e) {
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\AccountApi(
    new GuzzleHttp\Client(),
    $config
);
//Update Account Allocation
$account_allocation_update = new stdClass();
$account_allocation_id = "a2daaa18-4b65-4d6d-a46c-fbf72997a378";

try {
    $account_allocation_update->strategic_weight = "30";
    $result = $apiInstance->updateAccountAllocationMappingUsingPut($account_allocation_update, $account_allocation_id);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->updateAccountAllocationMappingUsingPut: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::AccountApi.new
#Update Account Allocation
account_allocation_update = {"date" => '2020-10-10'}
account_allocation_id = '2ae81803-73e4-4d92-a4b4-f43d4ea3cbe0'
begin
  result = api_instance.update_account_allocation_mapping_using_put(account_allocation_update, account_allocation_id)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->update_account_allocation_mapping_using_put: #{e}"
end
var apiInstance = new HydrogenNucleusApi.AccountApi();
var accountallocation1 = new HydrogenNucleusApi.AccountAllocationMapping();
//Update AccountAllocation
var apiInstance = new HydrogenNucleusApi.AccountApi();
var callback = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
var accountallocation = new HydrogenNucleusApi.AccountAllocationMapping();
var accountallocationId = "24c5ff36-a8fa-47ea-b1de-d9444b1ee067";

accountallocation.current_weight = '20';
apiInstance.updateAccountAllocationMappingUsingPut(accountallocation, accountallocationId, callback)

Example Response

{
    "id": "000183ac-2288-4564-a76b-119f4694be98",
    "current_weight": 100,
    "date": "2016-01-01",
    "strategic_weight": 100,
    "allocation_id": "7d0ae4cc-94f6-4fde-88e5-507888f9f6c6",
    "goal_id": "647c54c3-b649-477e-8cc7-eee56a120dd3",
    "account_id": "dbebf51f-d325-4cdd-b043-78958e29bdce"
}

Update the information for an account-allocation mapping. The unique account_allocation_id must be provided. To obtain the appropriate account_allocation_id, use the GET /account_allocation endpoint to view all account-allocation mappings and their current information. The details to be updated must also be provided. The endpoint returns the account_allocation_id and the details for the account-allocation mapping.

HTTP REQUEST

PUT /account_allocation/{account_allocation_id}

Delete an account allocation

Example Request

curl -X DELETE -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/account_allocation/000183ac-2288-4564-a76b-119f4694be9"
api_instance = nucleus_api.AccountApi(nucleus_api.ApiClient(configuration))

# Delete a AccountAllocation
allocation_id = 'a7432c0a-34fd-4b18-b8e4-8ebbf990fa93'
try:
    api_instance.delete_account_allocation_mapping_using_delete(allocation_id)
except ApiException as e:
    print("Exception when delete_account_allocation_mapping_using_delete: %s\n" % e)
AccountApi apiInstance = new AccountApi();
        //Delete Account Allocation
        try {
            AccountAllocationMapping deleteresponse = apiInstance.deleteAccountAllocationMappingUsingDelete(UUID.fromString("28255d3d-e80b-4752-8aed-7de8551fc623"));
            System.out.println(deleteresponse);
        } catch (ApiException e) {
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\AccountApi(
    new GuzzleHttp\Client(),
    $config
);
//Delete Account Allocation
$account_allocation_did = "a8463372-6887-4f72-b54c-e6799925a265"; // string | UUID account_id

try {
    $apiInstance->deleteAccountAllocationMappingUsingDelete($account_allocation_did);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->deleteAccountAllocationMappingUsingDelete: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::AccountApi.new
#Delete Account Allocation
accountallocation1_id = 'a8463372-6887-4f72-b54c-e6799925a265'
begin
  result = api_instance.delete_account_allocation_mapping_using_delete(accountallocation1_id)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->delete_account_allocation_mapping_using_delete: #{e}"
end
var apiInstance = new HydrogenNucleusApi.AccountApi();
var accountallocation1 = new HydrogenNucleusApi.AccountAllocationMapping();
//Delete a AccountAllocation
var accountidallocation1 = "2d4d825a-2962-4e8d-a606-b22aa8e08bc2"; // String | spending_control_id


var deleteaccountallocation = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully.');
    }
};
apiInstance.deleteAccountAllocationMappingUsingDelete(accountidallocation1, deleteaccountallocation)

Response (204 No Content)

Permanently delete an account-allocation mapping for an account. The unique account_allocation_id must be provided. To obtain the appropriate account_allocation_id, use the GET /account_allocation endpoint to view all account-allocation mappings. This deletes the account_allocation_id and the association between an account and an allocation.

HTTP REQUEST

DELETE /account_allocation/{account_allocation_id}

Account Activity

List all account asset sizes

Example Request

curl -X GET -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/account/50b4d384-986d-4892-a30a-bc4c146d25a9/asset_size"
api_instance = nucleus_api.AccountApi(nucleus_api.ApiClient(configuration))
try:
    api_response = api_instance.get_account_asset_size_all_using_get()
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_account_asset_size_all_using_get: %s\n" % e)
AccountApi apiInstance = new AccountApi();
        try {
            PageVAccountAssetSize List = apiInstance.getAccountAssetSizeAllUsingGet(true, null, null, 0, 10);
            System.out.println(List);
        } catch (ApiException e) {
            System.err.println("Exception when calling getAccountAssetSizeAllUsingGet");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\AccountApi(
    new GuzzleHttp\Client(),
    $config
);
$account_id = "ff16ee08-7dd0-44e5-8bfa-6647c3d638e6"; // string | Account Id
$end_date = new \DateTime("2020-08-14"); // \DateTime | end date
$exclude_subledger = false; // bool | exclude_subledger
$get_latest = true; // bool | true or false
$sort_type = null; // string | Quarter (Q), Monthly (M) , Annually (Y), Daily (D) --caps matter, codes in ()
$start_date = new \DateTime("2020-05-06"); // \DateTime | start date

try {
    $acccountasset = $apiInstance->getAccountAssetSizeAggAllUsingGet($account_id, $end_date, $exclude_subledger, $get_latest, $sort_type, $start_date);
    print_r($acccountasset);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->getAccountAssetSizeAggAllUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::AccountApi.new
opts = {
    ascending: false, # BOOLEAN | ascending
    filter: null, # String | filter
    order_by: null, # String | order_by
    page: 0, # Integer | page
    size: 25 # Integer | size
}

begin
  #List all account asset sizes
  accountasset = api_instance.get_account_asset_size_all_using_get(opts)
  p accountasset
rescue NucleusApi::ApiError => e
  puts "Exception when calling AccountApi->get_account_asset_size_all_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.AccountApi();
var opts = {
    'ascending': true, // Boolean | ascending
    // 'filter': "", // String | filter
    'orderBy': null, // String | order_by
    'page': 0, // Number | page
    'size': 10 // Number | size
};

var accountaassetsize = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};

apiInstance.getAccountAssetSizeAllUsingGet(opts, accountaassetsize)

Example Response

[
  {
    "date": "2018-02-03",
    "currency_code": "USD",
    "value": 20000,
    "value_available": null,
    "value_pending": null,
    "cash_flow": 0
  },
  {
    "date": "2018-02-10",
    "currency_code": "USD",
    "value": 20543,
    "value_available": null,
    "value_pending": null,
    "cash_flow": 500
  }
]

Get a list of asset sizes by date for an account. Asset size records are created at the portfolio level and aggregated to yield the account asset size(s). The unique account_id must be provided. To obtain the appropriate account_id, use the GET /account endpoint to view the accounts defined for your tenant. The endpoint returns a list of asset sizes by date for the account. Additional parameters available to narrow down what is returned include date range, only obtaining the latest record, and sorting by different units of time (eg. annually, quarterly, monthly, daily).

HTTP REQUEST

GET /account/{account_id}/asset_size

ARGUMENTS

Parameter Type Required Description
get_latest boolean optional Retrieve only the latest asset size. Defaults to false if not set
sort_type string optional Sort the asset sizes by D Daily, M Monthly, Q Quarterly, Y Yearly. Defaults to D Daily if not set. Must be capital letters
start_date date optional Start date for the data. Defaults to the first date if not set
end_date date optional End date for the data. Defaults to the last date if not set
exclude_subledger boolean optional If set to “true”, excludes portfolios under accounts where is_subledger = “true” to not double count assets of subaccounts. Defaults to “false” which includes all portfolios under an account.
currency_conversion string optional Alphabetic currency code for the currency to convert all monetary values to. Value may be USD, GBP, EUR, AUD, CAD. Only available in enterprise plan.

RESPONSE

Field Type Description
date date Date for the asset size record. Displays the latest record if more than one entry exists for the given date.
currency_code string Alphabetic currency code for the asset size. See currency codes
value double Monetary value of the account on the particular date
value_available double Available monetary value of the account on the particular date
value_pending double Pending monetary value of the account on the particular date
cash_flow double Amount added to the account or withdrawn from the account since the last asset size date. Value is used for performance calculations. Value may be positive or negative.

List all account holdings

Example Request

curl -X GET -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/account/50b4d384-986d-4892-a30a-bc4c146d25a9/holding"
api_instance = nucleus_api.AccountApi(nucleus_api.ApiClient(configuration))
try:
    api_response = api_instance.get_portfolio_holding_agg_all_using_get("73260a17-5a7a-4025-a60a-6a78284b1416")
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_portfolio_holding_agg_all_using_get: %s\n" % e)
AccountApi apiInstance = new AccountApi();
        try {
            Object holdingAggAllUsingGet = apiInstance.getPortfolioHoldingAggAllUsingGet(UUID.fromString("ff16ee08-7dd0-44e5-8bfa-6647c3d638e6"),null, enddate, true, startdate);
            System.out.println(holdingAggAllUsingGet);
        } catch (ApiException e) {
            System.err.println("Exception when calling getPortfolioHoldingAggAllUsingGet");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\AccountApi(
    new GuzzleHttp\Client(),
    $config
);
$account_id = "ff16ee08-7dd0-44e5-8bfa-6647c3d638e6"; // string | UUID account_id
$end_date = "2020-08-14"; // string | end date
$get_latest = true; // bool | true or false
$start_date = "2020-05-06"; // string | start date

try {
    $accountholding = $apiInstance->getPortfolioHoldingAggAllUsingGet($account_id, $end_date, $get_latest, $start_date);
    print_r($accountholding);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->getPortfolioHoldingAggAllUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::AccountApi.new
opts = {
    currency_conversion: null, # String | USD
    end_date: Date.parse('2013-10-20'), # Date | end date
    get_latest: true, # BOOLEAN | true or false
    start_date: Date.parse('2013-10-20') # Date | start date
}

begin
  #List all account holdings
  holding = api_instance.get_portfolio_holding_agg_all_using_get(account_id, opts)
  p holding
rescue NucleusApi::ApiError => e
  puts "Exception when calling AccountApi->get_portfolio_holding_agg_all_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.AccountApi();
var accountId = "11c28dade-8679-4df5-9b9d-c508d04fcb0c"; // String | UUID account_id

var opts = {
    'currencyConversion': null, // String | USD
    'endDate': new Date("2013-10-20"), // Date | end date
    'getLatest': true, // Boolean | true or false
    'startDate': new Date("2013-10-20") // Date | start date
};

var accountholding = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' + data);
    }
};
apiInstance.getPortfolioHoldingAggAllUsingGet(accountId, opts, accountholding)

Example Response

{
  "content": [
    {
      "date": "2018-02-03",
      "security_id": "d6496a5a-a17e-4682-8c8e-7933ce6ca3c6",
      "weight": 10,
      "currency_code": "USD",
      "amount": 2000,
      "cost_basis": null,
      "shares": 20
    },
    {
      "date": "2018-02-03",
      "security_id": "24c3f327-20ac-4302-8330-6cf19de9a353",
      "weight": 2,
      "currency_code": "USD",
      "amount": 400,
      "cost_basis": null,
      "shares": 40
    },
    {
      "date": "2018-02-03",
      "security_id": "cc5a6c52-32a5-4cd8-98db-4541c9b29add",
      "weight": 30,
      "currency_code": "USD",
      "amount": 6000,
      "cost_basis": null,
      "shares": 6
    },
    {
      "date": "2018-02-03",
      "security_id": "3c416c11-1e43-4031-bc0a-e9dc3677f15a",
      "weight": 30,
      "currency_code": "USD",
      "amount": 6000,
      "cost_basis": null,
      "shares": 60
    },
    {
      "date": "2018-02-03",
      "security_id": "59add370-01cf-42a0-bee8-ad75065df603",
      "weight": 28,
      "currency_code": "USD",
      "amount": 5600,
      "cost_basis": null,
      "shares": 50
    }
  ],
  "total_pages": 1,
  "total_elements": 5,
  "last": true,
  "sort": [
    {
        "direction": "DESC",
        "property": "id",
        "ignore_case": false,
        "null_handling": "NATIVE",
        "descending": true,
        "ascending": false
    }
  ],
  "first": true,
  "number_of_elements": 5,
  "size": 25,
  "number": 5
}

Get information for all the securities that are currently being held by an account. Holding records are created at a portfolio level and aggregated to show the holdings of the account. The unique account_id must be provided. To obtain the appropriate account_id, use the GET /account endpoint to view the accounts defined for your tenant. The endpoint returns a list of security_ids and details for each security holding.

HTTP REQUEST

GET /account/{account_id}/holding

ARGUMENTS

Parameter Type Required Description
start_date date optional Start date for the data. Defaults to the first date if not set
end_date date optional End date for the data. Defaults to the last date if not set
get_latest boolean optional Retrieve only the latest asset size. Defaults to false if not set
currency_conversion string optional Alphabetic currency code for the currency to convert all monetary values to. Value may be USD, GBP, EUR, AUD, CAD. Only available in enterprise plan.

RESPONSE

Field Type Description
date date Date for the security holding. Displays the latest record if more than one entry exists for the given date.
security_id UUID The id for the security included in the holding record
weight double The weight of the security as a percentage of the account’s total monetary value; ex. 20 representing 20%
currency_code string Alphabetic currency code for the amount. See currency codes
amount double Monetary value of the shares in the holding record
cost_basis double Monetary value that the security was originally purchased for, used for tax purposes
shares double Number of shares in the holding record

List all account transactions

Example Request

curl -X GET -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/account/50b4d384-986d-4892-a30a-bc4c146d25a9/transaction"
api_instance = nucleus_api.AccountApi(nucleus_api.ApiClient(configuration))
try:
    api_response = api_instance.get_portfolio_transaction_agg_all_using_get("73260a17-5a7a-4025-a60a-6a78284b1416")
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_portfolio_transaction_agg_all_using_get: %s\n" % e)
AccountApi apiInstance = new AccountApi();
        try {
            PagePortfolioTransaction List = apiInstance.getPortfolioTransactionAggAllUsingGet(UUID.fromString("ff16ee08-7dd0-44e5-8bfa-6647c3d638e6"), true, null, enddate, null, 0, 10, startdate);
            System.out.println(List);
        } catch (ApiException e) {
            System.err.println("Exception when calling getPortfolioTransactionAggAllUsingGet");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\AccountApi(
    new GuzzleHttp\Client(),
    $config
);
$ascending = false; // bool | ascending
$end_date = new \DateTime("2020-08-14"); // \DateTime | end_date
$order_by = null; // string | order_by
$page = 0; // int | page
$size = 10; // int | size
$start_date = new \DateTime("2020-05-06"); // \DateTime | start_date

try {
    $accounttransaction = $apiInstance->getPortfolioTransactionAggAllUsingGet($account_id, $ascending, $end_date, $order_by, $page, $size, $start_date);
    print_r($accounttransaction);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->getPortfolioTransactionAggAllUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::AccountApi.new
opts = {
    ascending: false, # BOOLEAN | ascending
    currency_conversion: null, # String | USD
    end_date: Date.parse('2013-10-20'), # Date | end date
    order_by: 'update_date', # String | order_by
    page: 0, # Integer | page
    size: 25, # Integer | size
    start_date: Date.parse('2013-10-20') # Date | start date
}

begin
  #List all account transactions
  transaction = api_instance.get_portfolio_transaction_agg_all_using_get(account_id, opts)
  p transaction
rescue NucleusApi::ApiError => e
  puts "Exception when calling AccountApi->get_portfolio_transaction_agg_all_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.AccountApi();
var accountId = "11c28dade-8679-4df5-9b9d-c508d04fcb0c";

var opts = {
    'ascending': true, // Boolean | ascending
    // 'filter': "", // String | filter
    'orderBy': null, // String | order_by
    'page': 0, // Number | page
    'size': 10 // Number | size
};

var accounttransaction = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};

apiInstance.getPortfolioTransactionAggAllUsingGet(accountId, opts, accounttransaction)

Example Response

{
  "content": [
    {
      "id": "50b4d384-986d-4892-a30a-bc4c146d25a9",
      "date": "2018-01-31T00:00:00.000+0000",
      "date_available": null,
      "is_recurring": false,
      "is_cleansed": false,
      "is_disputed": false,
      "is_read": true,
      "portfolio_id": "c193de6e-564d-4b2d-893d-0307e92279b7",
      "model_id": "19ef73a9-8dd9-4df0-970e-c3f57c6f8d38",
      "price": 432.2,
      "quantity": 0.5,
      "currency_code": null,
      "amount": null,
      "balance": null,
      "merchant_id": null,
      "mid": null,
      "merchant": null,
      "merchant_category_code": null,
      "transaction_category_id": null,
      "category": null,
      "subcategory": null,
      "description": null,
      "memo": null,
      "status": null,
      "check": {},
      "funding_id": null,
      "security_id": "088c1dc6-6750-411d-8679-dfeeaa7241e3",
      "transaction_code_id": "f5af397b-7d22-433f-b01e-8202184a6386",
      "create_date": "2018-01-25T09:00:00.000+0000",
      "update_date": "2018-02-15T09:00:00.000+0000"
    },
    {
      "id": "97c771ac-64b7-461e-a5b3-7d93169dc58b",
      "date": "2018-01-31T00:00:00.000+0000",
      "date_available": null,
      "is_recurring": false,
      "is_disputed": false,
      "is_cleansed": false,
      "is_read": true,
      "portfolio_id": "c193de6e-564d-4b2d-893d-0307e92279b7",
      "model_id": "19ef73a9-8dd9-4df0-970e-c3f57c6f8d38",
      "price": 132.2,
      "quantity": 4,
      "currency_code": null,
      "amount": null,
      "balance": null,
      "merchant_id": null,
      "mid": null,
      "merchant": null,
      "merchant_category_code": null,
      "transaction_category_id": null,
      "category": null,
      "subcategory": null,
      "description": null,
      "memo": null,
      "status": null,
      "location": {},
      "check": {},
      "funding_id": null,
      "security_id": "59add370-01cf-42a0-bee8-ad75065df603",
      "transaction_code_id": "f5af397b-7d22-433f-b01e-8202184a6386",
      "create_date": "2018-01-25T09:00:00.000+0000",
      "update_date": "2018-02-15T09:00:00.000+0000"
    }
  ],
  "total_pages": 1,
  "total_elements": 2,
  "last": true,
  "sort": [
    {
        "direction": "DESC",
        "property": "id",
        "ignore_case": false,
        "null_handling": "NATIVE",
        "descending": true,
        "ascending": false
    }
  ],
  "first": true,
  "number_of_elements": 2,
  "size": 25,
  "number": 2
}

Get the information for all transactions for an account. Transaction records are created at a portfolio level and all transactions for each portfolio below an account are returned to show the account’s transaction activity. The unique account_id must be provided. To obtain the appropriate account_id, use the GET /account endpoint to view the accounts defined for your tenant. The endpoint returns a list of transaction_ids and details for each transaction.

HTTP REQUEST

GET /account/{account_id}/transaction

ARGUMENTS

Parameter Type Required Description
start_date date optional Start date for the data. Defaults to the first date if not set
end_date date optional End date for the data. Defaults to the last date if not set
currency_conversion string optional Alphabetic currency code for the currency to convert all monetary values to. Value may be USD, GBP, EUR, AUD, CAD. Only available in enterprise plan.

RESPONSE

Field Type Description
id UUID The id for the transaction record
date timestamp Timestamp when the transaction occurred
date_available timestamp Timestamp when the transaction becomes available
is_cleansed boolean Indicates if the transaction has been cleansed by a data cleansing engine. Defaults to false which indicates that it has not been cleansed
is_read boolean Indicates if the transaction has been read. Defaults to false which indicates that it has not been read
is_recurring boolean Indicates if the transaction is recurring such as a subscription. Defaults to false which indicates that it is not recurring
is_disputed boolean Indicates if the transaction is disputed by the client. Defaults to false which indicates that it is not disputed
portfolio_id UUID The id of the portfolio that the transaction record relates to
funding_id UUID The id of the funding request that the transaction record relates to
model_id UUID The id of the model to which the portfolio that the transaction falls under subscribes
price double Price at which security was bought or sold included in the transaction
quantity double Quantity of shares of the security purchased
currency_code string Alphabetic currency code for the amount. See currency codes
amount double Amount of the transaction
balance double Updated balance of the portfolio as a result of the transaction
merchant_id UUID ID of the merchant resource for the transaction
mid string Acquirer ID of the merchant (MID) for the transaction
merchant string The merchant for the transaction such as the merchant posted for a credit or debit card charge
merchant_category_code string The MCC Code for the merchant as identified by the card network
transaction_category_id string ID of the category resource for the transaction
category string Category of the transaction
subcategory string Subcategory of the transaction
description string Description of the transaction
memo string Memo attached to the transaction
status string Status of the transaction
location map Location where the transaction occurred
      address_line1 string Primary information for the street address, such as the street and building number
      address_line2 string Secondary information for the street address, such as a suite or apartment number
      city string City for the address
      state string State, province, or sub-country region for the address
      postalcode string Alphanumeric postal code or zip code for the address
      country string Country for the address using the ISO ALPHA-2 Code. See country codes
      latitude double Latitude of the location where the transaction occurred
      longitude double Longitude of the location where the transaction occurred
check map Check associated with the banking transaction
      check_number string Number on the check such as “1234”
      check_amount double Monetary amount of the check
      check_images map Image(s) of the scanned check(s)
            image_url string URL where the image can be displayed
            image_type string Type of image for the check such as “png” or “jpeg”
security_id UUID The id of the security included in the transaction
transaction_code_id UUID The id referring to the transaction code, defined by your firm
secondary_id string Alternate id that can be used to identify the object such as an internal id
create_date timestamp Timestamp for the date and time that the transaction record was created
update_date timestamp Timestamp for the date and time that the transaction record was last updated

Get aggregate account data

Aggregates account data for a given account. This includes data on the clients that are associated to the account, account asset size & holdings, allocations associated with the account, and latest deposits & withdrawals. This view is useful when constructing account dashboards.

Field Type Description
account_id UUID The id of the account
account_name string Name of the account
account_type_id UUID The id of the account type for the account. Account types are defined by your firm
account_type_name string Name of the account type
account_asset_size double Latest account asset size
account_asset_size_date date Date of the account_asset_size record
clients array List of client(s)
      client_id UUID The id of the client
      client_first_name string First name of the client
      client_last_name string Last name of the client
      client_account_association string The role of the client as it relates to the account
deposits array Array of deposits for the account. Returns only the latest 3 records
      deposit_id UUID ID of the deposit record
      deposit_amount double Amount of the deposit
      deposit_received_date timestamp Date and time that the deposit was received into the account
      deposit_direction string Label to indicate the direction of the transaction such as “Incoming” or “Outgoing”
withdrawals array Array of withdrawals made from the client’s account. Returns only the latest 3 records
      withdrawal_id UUID ID of the withdrawal record
      withdrawal_amount double Amount that was withdrawn
      withdrawal_date date Date the withdrawal was made
      withdrawal_direction string Label to indicate the direction of the transaction such as “Incoming” or “Outgoing”
allocations array List of latest allocation(s) associated with the account
      allocations_id UUID ID of the allocation that is part of the account-allocation mapping
      allocation_name string Name of the allocation
      allocation_description string Description of the allocation
      allocation_category string Category of the allocation
      allocation_secondary_id UUID Alternate ID of the allocation
      account_allocation_id UUID ID of the account-allocation mapping
      account_allocation_date UUID Date of the account-allocation mapping
account_holdings array List of latest holdings(s) associated with the account
      date date Date for the security holding
      security_id UUID The id for the security included in the holding record
      weight double The weight of the security as a percentage of the account’s total monetary value; ex. 20 representing 20%
      amount double Monetary value of the shares in the holding record
      shares double Number of shares in the holding record

HTTP REQUEST

GET /account/{account_id}/account_overview

Example Request

curl -X GET -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/account/6f4a3f64-5bba-4bbf-8fe6-6815db272dc8/account_overview"
api_instance = nucleus_api.AccountApi(nucleus_api.ApiClient(configuration))
try:
    api_response = api_instance.get_account_overview_using_get("73260a17-5a7a-4025-a60a-6a78284b1416")
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_account_overview_using_get: %s\n" % e)
AccountApi apiInstance = new AccountApi();
       try {
            Object accountoverview =apiInstance.getAccountOverviewUsingGet(UUID.fromString("ff16ee08-7dd0-44e5-8bfa-6647c3d638e6"), true, null);
            System.out.println(accountoverview);
        } catch (ApiException e) {
            System.err.println("Exception when calling getAccountOverviewUsingGet");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\AccountApi(
    new GuzzleHttp\Client(),
    $config
);
$account_id = "ff16ee08-7dd0-44e5-8bfa-6647c3d638e6"; // string | UUID account_id
$ascending = false; // bool | ascending
$order_by = null; // string | order_by

try {
    $accountoverview = $apiInstance->getAccountOverviewUsingGet($account_id, $ascending, $order_by);
    print_r($accountoverview);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->getAccountOverviewUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::AccountApi.new
account_id = 'account_id_example' # String | UUID account_id

opts = {
    ascending: false, # BOOLEAN | ascending
    order_by: null # String | order_by
}

begin
  #List all Account overview
  accountoverview = api_instance.get_account_overview_using_get(account_id, opts)
  p accountoverview
rescue NucleusApi::ApiError => e
  puts "Exception when calling AccountApi->get_account_overview_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.AccountApi();
var opts = {
    'ascending': true, // Boolean | ascending
    // 'filter': "", // String | filter
    'orderBy': null, // String | order_by
    'page': 0, // Number | page
    'size': 10 // Number | size
};

var accountoverview = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};

apiInstance.getAccountOverviewUsingGet("73260a17-5a7a-4025-a60a-6a78284b1416", opts, accountoverview)

Example Response

{
    "client_id": "0797efda-cf8b-4661-9cb4-d1e8966a3dcd",
    "client_first_name": "Oscar",
    "client_last_name": "Martinez",
    "client_asset_size_date": "2019-09-13",
    "client_asset_size": 362242.82649700006,
    "accounts": [
        {
            "account_id": "4d7efcea-2f85-4442-8268-c0c1e82ca618",
            "account_name": "Investment",
            "account_type": "Investment",
            "account_secondary_id": "Test Data",
            "account_asset_size": 38725.07924,
            "account_asset_size_date": "2019-09-13",
            "account_created_date": "2019-09-26T22:31:16.000+0000",
            "account_updated_date": "2019-09-26T22:31:16.000+0000"
        },
        {
            "account_id": "6f4a3f64-5bba-4bbf-8fe6-6815db272dc8",
            "account_name": "Saving Account",
            "account_type": "Saving",
            "account_secondary_id": "Test Data",
            "account_asset_size": 37117.77597,
            "account_asset_size_date": "2019-09-13",
            "account_created_date": "2019-09-26T22:31:17.000+0000",
            "account_updated_date": "2019-09-26T22:31:17.000+0000"
        },
        {
            "account_id": "7ed09992-89ad-4a27-9bc2-a313cf28d234",
            "account_name": "Investment",
            "account_type": "Investment",
            "account_secondary_id": "Test Data",
            "account_asset_size": 51989.83748,
            "account_asset_size_date": "2019-09-13",
            "account_created_date": "2019-09-26T22:31:15.000+0000",
            "account_updated_date": "2019-09-26T22:31:15.000+0000"
        }
    ],
    "deposits": [
        {
            "deposit_id": "3eb0c7a7-63a5-4f6f-a3c9-52f470fcf636",
            "deposit_amount": 9000.0,
            "deposit_account_id": "f450e1f9-ee02-44a2-b947-d7bcb4ee07f1",
            "deposit_account_name": "Investment",
            "deposit_received_date": "2019-01-25T00:00:00.000+0000",
            "deposit_direction": "Inbound"
        },
        {
            "deposit_id": "52b28035-deed-4dba-99ba-503bd1f0c1c9",
            "deposit_amount": 5000.0,
            "deposit_account_id": "f450e1f9-ee02-44a2-b947-d7bcb4ee07f1",
            "deposit_account_name": "Investment",
            "deposit_received_date": "2017-08-30T00:00:00.000+0000",
            "deposit_direction": "Inbound"
        },
        {
            "deposit_id": "89dde3ae-4aa1-4088-880b-f7f1e63a8bc9",
            "deposit_amount": 1000.0,
            "deposit_account_id": "f450e1f9-ee02-44a2-b947-d7bcb4ee07f1",
            "deposit_account_name": "Investment",
            "deposit_received_date": "2019-08-27T00:00:00.000+0000",
            "deposit_direction": "Inbound"
        }
    ],
    "withdrawals": [
        {
            "withdrawal_id": "64b79ec3-cd92-4dc9-92b6-c2bb0c59f8fe",
            "withdrawal_amount": 1000.0,
            "withdrawal_account_id": "4d7efcea-2f85-4442-8268-c0c1e82ca618",
            "withdrawal_account_name": "Investment",
            "withdrawal_date": "2019-08-30",
            "withdrawal_direction": "Outgoing"
        },
        {
            "withdrawal_id": "fb00abc4-f3fe-494a-a830-3a373ce2b8ab",
            "withdrawal_amount": 1000.0,
            "withdrawal_account_id": "f450e1f9-ee02-44a2-b947-d7bcb4ee07f1",
            "withdrawal_account_name": "Investment",
            "withdrawal_date": "2019-09-05",
            "withdrawal_direction": "Outgoing"
        },
        {
            "withdrawal_id": "3c0d9edc-df6e-40ab-9107-e631c51d56de",
            "withdrawal_amount": 500.0,
            "withdrawal_account_id": "7ed09992-89ad-4a27-9bc2-a313cf28d234",
            "withdrawal_account_name": "Investment",
            "withdrawal_date": "2017-04-26",
            "withdrawal_direction": "Outgoing"
        }
    ],
    "allocations": [],
    "account_holdings": []
}

Account Type

Accounts are assigned an account type based on the legal construct of the account. Examples include a “Roth IRA”, “ISA”, or “Revocable Trust.” Account types can be custom set by your firm based on those you accept.

Field Type Description
id UUID The id for the specific account type
name string Name of the account type such as Taxable or Joint
short_name string Abbreviated name for the account type
category string Category grouping that the account type falls under
subcategory string Subcategory grouping under the category that the account type falls under
code string Code defined by your firm for the specific account type
is_active boolean Indicates if his account type is active. Defaults to true which indicates it is active and available to be assigned to accounts
is_taxable boolean Indicates if this account type is taxable. Defaults to true which indicates it is taxable
is_asset boolean Indicates if this account type is an asset. Defaults to true which indicates it is an asset
is_cash boolean Indicates if this account type is cash. Defaults to true which indicates it is cash
is_business boolean Indicates if this account type is for a business. Defaults to false which indicates it is not for a business account
is_investment boolean Indicates if this account type is for an investment account. Defaults to false which indicates it is not for an investment account
metadata map Custom information associated with the entity in the format key:value
See Metadata
secondary_id string Alternate id that can be used to identify the object such as an internal id
create_date timestamp Timestamp for the date and time that the record was created
update_date timestamp Timestamp for the date and time that the record was last updated

List all account types

Example Request

curl -X GET -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/account_type"
api_instance = nucleus_api.AccountApi(nucleus_api.ApiClient(configuration))
try:
    api_response = api_instance.get_account_type_all_using_get()
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_account_type_all_using_get: %s\n" % e)
AccountApi apiInstance = new AccountApi();
        try {
            PageAccountType List = apiInstance.getAccountTypeAllUsingGet(true, null, null, 0, 10);
            System.out.println(List);
        } catch (ApiException e) {
            System.err.println("Exception when calling getAccountTypeAllUsingGet");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\AccountApi(
    new GuzzleHttp\Client(),
    $config
);
$ascending = false; // bool | ascending
$filter = null; // string | filter
$order_by = null; // string | order_by
$page = 0; //int | page
$size = 10; //int | size

try {
    $accounttypelist = $apiInstance->getAccountTypeAllUsingGet($ascending, $filter, $order_by, $page, $size);
    print_r($accounttypelist);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->getAccountTypeAllUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::AccountApi.new
opts = {
    ascending: false, # BOOLEAN | ascending
    filter: null, # String | filter
    order_by: null, # String | order_by
    page: 0, # Integer | page
    size: 25 # Integer | size
}

begin
  #List all account types
  accounttypelist = api_instance.get_account_type_all_using_get(opts)
  p accounttypelist
rescue NucleusApi::ApiError => e
  puts "Exception when calling AccountApi->get_account_type_all_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.AccountApi();
var opts = {
    'ascending': true, // Boolean | ascending
    // 'filter': "", // String | filter
    'orderBy': null, // String | order_by
    'page': 0, // Number | page
    'size': 10 // Number | size
};

var accountypelist = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};

apiInstance.getAccountTypeAllUsingGet(opts, accountypelist)

Example Response

{
    "content": [
        {
            "id": "50d76212-0fcd-4d36-8633-e4a52cbcb79f",
            "create_date": "2018-04-13T14:24:43.000+0000",
            "update_date": "2018-04-13T14:24:43.000+0000",
            "category": "Custodial",
            "code": "101",
            "is_active": true,
            "is_taxable": true,
            "is_asset": true,
            "is_cash": true,
            "is_business": true,
            "is_investment": true,
            "name": "Custodial",
            "short_name": "CUST",
            "metadata": {}
        },
        {
            "id": "cb94ee79-1ef4-4d67-9611-97a739523aeb",
            "create_date": "2018-04-13T14:24:43.000+0000",
            "update_date": "2018-04-13T14:24:43.000+0000",
            "category": "Retirement",
            "code": "102",
            "is_active": true,
            "is_taxable": false,
            "is_asset": true,
            "is_cash": true,
            "is_business": true,
            "is_investment": true,
            "name": "Retirement",
            "short_name": "RETIR",
            "metadata": {}
        },
        {
            "id": "f80b5555-7503-4a28-bc4b-d05d62e0e733",
            "create_date": "2018-04-13T14:24:43.000+0000",
            "update_date": "2018-04-13T14:24:43.000+0000",
            "category": "Taxable",
            "code": "103",
            "is_active": true,
            "is_taxable": true,
            "is_asset": true,
            "is_cash": true,
            "is_business": true,
            "is_investment": true,
            "name": "Taxable",
            "short_name": "TXB",
            "metadata": {}
        }
    ],
    "last": false,
    "total_pages": 1,
    "total_elements": 3,
    "sort": [
        {
            "direction": "DESC",
            "property": "updateDate",
            "ignore_case": false,
            "null_handling": "NATIVE",
            "descending": true,
            "ascending": false
        }
    ],
    "first": true,
    "number_of_elements": 3,
    "size": 25,
    "number": 0
}

List all account types defined for your tenant. Use this endpoint to determine which account_type_id to assign to a new account.

HTTP REQUEST

GET /account_type

Create an account type

Example Request

curl -X POST -H "Authorization: Bearer 7f137375-c63b-49fb-84eb-5abbd3b780a3" \
-H "Content-Type: application/json" \
-d '{
        "category": "Taxable",
        "code": "103",
        "is_taxable": true,
        "name": "Taxable",
        "short_name": "TXB"
    }' "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/account_type"
api_instance = nucleus_api.AccountApi(nucleus_api.ApiClient(configuration))
# Create a AccountType
accountType = nucleus_api.AccountType(name="new type", code="One")
try:
    api_response = api_instance.create_account_type_using_post(accountType);
    pprint(api_response)
except ApiException as e:
    print("create_account_type_using_post: %s\n" % e)
AccountApi apiInstance = new AccountApi();
        //Create a New Account Type
        AccountType type = new AccountType();
        type.code("checking_personal");
        type.name("Checking Account - Personal");
        try {
            AccountType result = apiInstance.createAccountTypeUsingPost(type);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling createAccountTypeUsingPost");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\AccountApi(
    new GuzzleHttp\Client(),
    $config
);
//Create Account Type
$account_type = new \com\hydrogen\nucleus\Model\AccountType();

try {
    $account_type->setName("Checking Account - Personal");
    $account_type->setCode("Checking_Personal");
    $result = $apiInstance->createAccountTypeUsingPost($account_type);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->createAccountTypeUsingPost: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::AccountApi.new
#Create Account Type
account_type = NucleusApi::AccountType.new

begin
  account_type.name = "New"
  account_type.code = "BAC"
  result = api_instance.create_account_type_using_post(account_type)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->create_account_type_using_post: #{e}"
end
var apiInstance = new HydrogenNucleusApi.AccountApi();
//Create Account Type
var accounttype = new HydrogenNucleusApi.AccountType();
accounttype.code = "checking_personal";
accounttype.name = "Checking Account - Personal";

var accounttypenew = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.createAccountTypeUsingPost(accounttype, accounttypenew)

Example Response

{
    "id": "f80b5555-7503-4a28-bc4b-d05d62e0e733",
    "create_date": "2018-04-13T14:24:43.000+0000",
    "category": "Taxable",
    "code": "103",
    "is_taxable": true,
    "is_asset": true,
    "is_cash": true,
    "is_business": true,
    "is_investment": true,
    "is_active": true,
    "name": "Taxable",
    "short_name": "TXB",
    "metadata": {}
}

Create a new account type for your tenant. The name must be provided and it will default to active. The create_date will default to the current date. The endpoint returns the account_type_id used to manage the account type and to map the account type to an account.

HTTP REQUEST

POST /account_type

ARGUMENTS

Parameter Type Required Description
name string required Name of the account type such as “Taxable” or “Joint”
short_name string optional Abbreviated name for the account type
category string optional Category grouping that the account type falls under
subcategory string optional Subcategory grouping under the category that the account type falls under
code string optional Code defined by your firm for the account type
is_taxable boolean optional Indicates if this account type is taxable. Defaults to true which indicates it is taxable
is_asset boolean optional Indicates if this account type is an asset. Defaults to true which indicates it is an asset
is_cash boolean optional Indicates if this account type is cash. Defaults to true which indicates it is cash
is_business boolean optional Indicates if this account type is for a business. Defaults to false which indicates it is not for a business account
is_investment boolean optional Indicates if this account type is for an investment account. Defaults to false which indicates it is not for an investment account
is_active boolean optional Indicates if this account type is active. Defaults to true which indicates it is active and available to be assigned to accounts
metadata map optional Custom information associated with the entity in the format key:value
See Metadata
secondary_id string optional Alternate id that can be used to identify the object such as an internal id

Retrieve an account type

Example Request

curl -X GET -H "Authorization: Bearer 7f137375-c63b-49fb-84eb-5abbd3b780a3" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/account_type/cf80b5555-7503-4a28-bc4b-d05d62e0e733"
api_instance = nucleus_api.AccountApi(nucleus_api.ApiClient(configuration))
try:
    api_response = api_instance.get_account_type_using_get("39197961-c928-48de-8e39-a70a2cf367f9")
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_account_type_using_get: %s\n" % e)
AccountApi apiInstance = new AccountApi();
        try {
            AccountType responseType =apiInstance.getAccountTypeUsingGet(UUID.fromString("e46a78a7-3fe0-4502-a5ec-e42660bab4b5"));
            System.out.println(responseType);
        } catch (ApiException e) {
            System.err.println("Exception when calling getAccountTypeUsingGet");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\AccountApi(
    new GuzzleHttp\Client(),
    $config
);
$account_type_id1 = "e46a78a7-3fe0-4502-a5ec-e42660bab4b5";

try {
    $accounttype = $apiInstance->getAccountTypeUsingGet($account_type_id1);
    print_r($accounttype);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->getAccountTypeUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::AccountApi.new
account_type_id = 'e46a78a7-3fe0-4502-a5ec-e42660bab4b5' # String | UUID account_type_id
begin
  #Get an Account Type
  accounttype = api_instance.get_account_type_using_get(account_type_id)
  p accounttype
rescue NucleusApi::ApiError => e
  puts "Exception when calling AccountApi->get_account_type_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.AccountApi();
var accounttypeID = "e46a78a7-3fe0-4502-a5ec-e42660bab4b5";


var accounttype = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.getAccountTypeUsingGet("e46a78a7-3fe0-4502-a5ec-e42660bab4b5", "e46a78a7-3fe0-4502-a5ec-e42660bab4b5", accounttype)

Example Response

{
    "id": "f80b5555-7503-4a28-bc4b-d05d62e0e733",
    "create_date": "2018-04-13T14:24:43.000+0000",
    "update_date": "2018-04-13T14:24:43.000+0000",
    "category": "Taxable",
    "code": "103",
    "is_active": true,
    "is_taxable": true,
    "is_asset": true,
    "is_cash": true,
    "is_business": true,
    "is_investment": true,
    "short_name": "TXB",
    "name": "Taxable",
    "metadata": {}
}

Retrieve the information for an account type defined for your tenant. The unique account_type_id must be provided. The endpoint returns the account_type_id and the details for the account type specified.

HTTP REQUEST

GET /account_type/{account_type_id}

Update an account type

Example Request

curl -X PUT -H "Authorization: Bearer 7f137375-c63b-49fb-84eb-5abbd3b780a3" \
-H "Content-Type: application/json" \
-d '{
        "category": "Taxable",
        "code": "103",
        "is_active": true,
        "is_taxable": true,
        "short_name": "TXB",
        "name": "Taxable"
    }' "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/account_type/f80b5555-7503-4a28-bc4b-d05d62e0e733"
api_instance = nucleus_api.AccountApi(nucleus_api.ApiClient(configuration))
# # Update AccountType
type_update = {'name': 'New Name'}
type_id = 'ebfbcce2-318d-402b-ab8f-172c40793549'

try:
    api_response = api_instance.update_account_type_using_put(type_update, type_id);
    pprint(api_response)
except ApiException as e:
    print("Exception when calling update_account_type_using_put: %s\n" % e)
AccountApi apiInstance = new AccountApi();
        //Update Account Type
        Map map2 = new HashMap();
        map.put("name", "Annual Primary");

        try {
            AccountType response = apiInstance.updateAccountTypeUsingPut(map2, UUID.fromString("38994e5e-c27e-49f8-a639-7ee1a82c3133"));
            System.out.println(response);
        } catch (ApiException e) {
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\AccountApi(
    new GuzzleHttp\Client(),
    $config
);
//Update Account Type
$account_type_update = new stdClass();
$account_type_id = "4bc96fae-be89-4fa7-bbb8-08eb0d43db94";

try {
    $account_type_update->code = "new";
    $result = $apiInstance->updateAccountTypeUsingPut($account_type_update, $account_type_id);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->updateAccountTypeUsingPut: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::AccountApi.new
#Update Account Type
account_type_update = {"code" => 'FULL_AUTHORITY'}
account_type_id = '5b42e953-ef6d-405a-a225-94da84149b23'
begin
  result = api_instance.update_account_type_using_put(account_type_update, account_type_id)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->update_account_type_using_put: #{e}"
end
var apiInstance = new HydrogenNucleusApi.AccountApi();
// Update Accounyt Type
var apiInstance = new HydrogenNucleusApi.AccountApi();
var callback = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
var accounttype = new HydrogenNucleusApi.AccountType();
var accounttypeId = "ebfbcce2-318d-402b-ab8f-172c40793549";

accounttype.code = 'Three';
apiInstance.updateAccountTypeUsingPut(accounttype, accounttypeId, callback)

Example Response

{
    "id": "f80b5555-7503-4a28-bc4b-d05d62e0e733",
    "create_date": "2018-04-13T14:24:43.000+0000",
    "update_date": "2018-04-13T14:24:43.000+0000",
    "category": "Taxable",
    "code": "103",
    "is_active": true,
    "is_taxable": true,
    "is_asset": true,
    "is_cash": true,
    "is_business": true,
    "is_investment": true,
    "short_name": "TXB",
    "name": "Taxable",
    "metadata": {}
}

Update the information for a possible account type defined for your tenant. The unique account_type_id must be provided. To identify the appropriate account_type_id, use the GET /account_type endpoint to view all account types defined for your tenant and their current information. The details to be updated must also be provided. The endpoint returns the information for the account_type_id including the updated details. Use this endpoint to mark an account type as inactive instead of deleting it permanently using the DELETE /account_type/{account_type_id} endpoint.

HTTP REQUEST

PUT /account_type/{account_type_id}

Delete an account type

Example Request

curl -X DELETE -H "Authorization: Bearer 7f137375-c63b-49fb-84eb-5abbd3b780a3" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/account_type/f80b5555-7503-4a28-bc4b-d05d62e0e733"
api_instance = nucleus_api.AccountApi(nucleus_api.ApiClient(configuration))
# Delete a AccountType
type_id = 'a89dbd1f-fda9-43b1-baa2-e6b92f7030cc'
try:
    api_instance.delete_account_type_using_delete(type_id)
except ApiException as e:
    print("Exception when delete_account_type_using_delete: %s\n" % e)
AccountApi apiInstance = new AccountApi();
        //Delete Account Type
        try {
            AccountType deleteresponse = apiInstance.deleteAccountTypeUsingDelete(UUID.fromString("476d70b7-fbff-4293-8321-0c8123e3d3e1"));
            System.out.println(deleteresponse);
        } catch (ApiException e) {
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\AccountApi(
    new GuzzleHttp\Client(),
    $config
);
//Delete Account Type
$account_type_did = "5b42e953-ef6d-405a-a225-94da84149b23"; // string | UUID account_id

try {
    $apiInstance->deleteAccountTypeUsingDelete($account_type_did);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->deleteAccountTypeUsingDelete: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::AccountApi.new
#Delete Account Type
accounttype1_id = 'c2ca63f3-7c4f-4d32-97a7-5dc72fd76710'
begin
  result = api_instance.delete_account_type_using_delete(accounttype1_id)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->delete_account_type_using_delete: #{e}"
end
var apiInstance = new HydrogenNucleusApi.AccountApi();
//Delete a AccountType
var accounttype1 = "5b42e953-ef6d-405a-a225-94da84149b23";


var deleteaccounttype = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully.');
    }
};
apiInstance.deleteAccountTypeUsingDelete(accounttype1, deleteaccounttype)

Response (204 No Content)

Permanently delete a possible account type defined for your tenant. The unique account_type_id must be provided. To identify the appropriate account_type_id, use the GET /account_type endpoint to view all account types defined for your tenant. This permanently deletes the account_type_id and associated information. To mark the account type as inactive without permanently deleting it, use the PUT /account_type/{account_type_id} endpoint to change the indicator for whether or not the account type is active to show that it is inactive.

HTTP REQUEST

DELETE /account_type/{account_type_id}

Account Status

Account statuses correspond to a stage_id and reflects the different stages that an account flows through along a user journey, useful for sign-up funnels. See the Stage section for stage_id.

Field Type Description
id UUID The id for the specific account status record for the account_id provided
account_id UUID The id of the account to which the status belongs
status string Status of the account such as “Signed Up” or “Awaiting Payment”
stage_id UUID Refers to the stage the client is in.
Useful for sign-up funnels
comments string Comments for the client regarding the status of their account
metadata map Custom information associated with the entity in the format key:value
See Metadata
secondary_id string Alternate id that can be used to identify the object such as an internal id
create_date timestamp Timestamp for the date and time that the record was created
update_date timestamp Timestamp for the date and time that the record was last updated

List all account statuses

Example Request

curl -X GET -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/account_status"
api_instance = nucleus_api.AccountApi(nucleus_api.ApiClient(configuration))
try:
    api_response = api_instance.get_account_status_all_using_get()
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_account_status_all_using_get: %s\n" % e)
AccountApi apiInstance = new AccountApi();
        try {
            PageAccountStatus List = apiInstance.getAccountStatusAllUsingGet(true, null, null, 0, 10);
            System.out.println(List);
        } catch (ApiException e) {
            System.err.println("Exception when calling getAccountStatusAllUsingGet");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\AccountApi(
    new GuzzleHttp\Client(),
    $config
);
$ascending = false; // bool | ascending
$filter = null; // string | filter
$order_by = null; // string | order_by
$page = 0; // int | page
$size = 10; // int | size

try {
    $accountstatus = $apiInstance->getAccountStatusAllUsingGet($ascending, $filter, $order_by, $page, $size);
    print_r($accountstatus);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->getAccountStatusAllUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::AccountApi.new
opts = {
    ascending: false, # BOOLEAN | ascending
    filter: null, # String | filter
    order_by: null, # String | order_by
    page: 0, # Integer | page
    size: 25 # Integer | size
}

begin
  #List all account statuses
  statuslist = api_instance.get_account_status_all_using_get(opts)
  p statuslist
rescue NucleusApi::ApiError => e
  puts "Exception when calling AccountApi->get_account_status_all_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.AccountApi();
var opts = {
    'ascending': true, // Boolean | ascending
    // 'filter': "", // String | filter
    'orderBy': null, // String | order_by
    'page': 0, // Number | page
    'size': 10 // Number | size
};

var accountstatuslist = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.getAccountStatusAllUsingGet(opts, accountstatuslist )

Example Response

{
    "content": [
        {
            "id": "6db4a470-a00c-40bb-a325-067d0bdb3ddc",
            "create_date": "2018-02-08T16:59:27.000+0000",
            "update_date": "2018-02-08T16:59:27.000+0000",
            "comments": "Invested",
            "status": "Complete",
            "stage_id": "e995d4c1-f989-4733-9867-713966ac9856",
            "account_id": "1d7e1aad-3c79-49fe-bbb9-bd5e239ae1e7",
            "metadata": {}
        },
        {
            "id": "013380bf-7f17-44c1-93c5-892a7ed3498c",
            "create_date": "2017-04-07T00:00:00.000+0000",
            "update_date": "2018-02-08T16:59:27.000+0000",
            "comments": null,
            "status": "Invested",
            "stage_id": "1d7e1aad-3c79-49fe-bbb9-bd5e239ae1e7",
            "account_id": "21098ed9-6439-46ba-abd9-eb6cf28866fb",
            "metadata": {}
        },
        {
            "id": "01b252d3-1412-477f-8d29-6e2ff6e54c81",
            "create_date": "2017-10-05T00:00:00.000+0000",
            "update_date": "2018-02-08T16:59:27.000+0000",
            "comments": null,
            "status": "Complete",
            "stage_id": "2a7a6cb7-ef71-4fe8-9169-2678f3799657",
            "account_id": "4ff21db3-97ab-4bbd-9885-be6aec522c44",
            "metadata": {}
        }
    ],
    "last": false,
    "total_pages": 1,
    "total_elements": 3,
    "sort": [
        {
            "direction": "DESC",
            "property": "updateDate",
            "ignore_case": false,
            "null_handling": "NATIVE",
            "descending": true,
            "ascending": false
        }
    ],
    "first": true,
    "number_of_elements": 3,
    "size": 25,
    "number": 0
}

Get the account status history information for all accounts defined for your tenant. Account status corresponds to a stage_id and reflects the different stages of a user journey, useful in sign-up funnels. You can filter using a unique account_id to view the account_status records for a specific account. To obtain the appropriate account_id, use the GET /account endpoint to view all accounts defined for your tenant.

HTTP REQUEST

GET /account_status

Create an account status

Example Request

curl -X POST -H "Authorization: Bearer 7f137375-c63b-49fb-84eb-5abbd3b780a3" \
-H "Content-Type: application/json" \
-d '{
        "comments": "Invested",
        "status": "Complete",
        "stage_id": "e995d4c1-f989-4733-9867-713966ac9856",
        "account_id": "1d7e1aad-3c79-49fe-bbb9-bd5e239ae1e7"
    }' "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/account_status"
api_instance = nucleus_api.AccountApi(nucleus_api.ApiClient(configuration))
# Create a AccountStatus
accountStatus = nucleus_api.AccountStatus(account_id="d5144cbb-64c8-4f4e-9ee2-28a07b003dc3", stage_id="389cb1a4-2892-4917-8aa6-2aa70a773af8", status="Status Created")
try:
    api_response = api_instance.create_account_status_using_post(accountStatus);
    pprint(api_response)
except ApiException as e:
    print("create_account_status_using_post: %s\n" % e)
AccountApi apiInstance = new AccountApi();
        //Create a New Account Status
        AccountStatus status = new AccountStatus();
        status.stageId(UUID.fromString("389cb1a4-2892-4917-8aa6-2aa70a773af8"));
        status.accountId(UUID.fromString("d5144cbb-64c8-4f4e-9ee2-28a07b003dc3"));
        status.status("Account successfully created");
        try {
            AccountStatus result = apiInstance.createAccountStatusUsingPost(status);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling createAccountStatusUsingPost");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\AccountApi(
    new GuzzleHttp\Client(),
    $config
);
//Create Account Status
$account_status = new \com\hydrogen\nucleus\Model\AccountStatus();

try {
    $account_status->setAccountId("d5144cbb-64c8-4f4e-9ee2-28a07b003dc3");
    $account_status->setStageId("389cb1a4-2892-4917-8aa6-2aa70a773af8");
    $account_status->setStatus("New");
    $result = $apiInstance->createAccountStatusUsingPost($account_status);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->createAccountStatusUsingPost: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::AccountApi.new
#Create Account Status
account_status = NucleusApi::AccountStatus.new

begin
  account_status.account_id = "d5144cbb-64c8-4f4e-9ee2-28a07b003dc3"
  account_status.stage_id = "389cb1a4-2892-4917-8aa6-2aa70a773af8"
  account_status.status = "New"
  result = api_instance.create_account_status_using_post(account_status)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->create_account_status_using_post: #{e}"
end
var apiInstance = new HydrogenNucleusApi.AccountApi();
//Create Account Status
var accountstatus = new HydrogenNucleusApi.AccountStatus();
accountstatus.account_id = '5e5aa0e3-4cd0-4d2f-b5c5-2625a3b87f0a';
accountstatus.stage_id = '389cb1a4-2892-4917-8aa6-2aa70a773af8';
accountstatus.status = "New status";

var accountstatusnew = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.createAccountStatusUsingPost(accountstatus, accountstatusnew)

Example Response

{
    "id": "6db4a470-a00c-40bb-a325-067d0bdb3ddc",
    "create_date": "2018-02-08T16:59:27.000+0000",
    "comments": "Invested",
    "status": "Complete",
    "stage_id": "e995d4c1-f989-4733-9867-713966ac9856",
    "account_id": "1d7e1aad-3c79-49fe-bbb9-bd5e239ae1e7",
    "metadata": {}
}

Create an account status record for an account by assigning a stage_id to the account. The unique account_id and stage_id must be provided. To obtain the appropriate account_id, use the GET /account endpoint to view all accounts defined for your tenant. To obtain the appropriate stage_id, use the GET /stage endpoint to view all account stages defined for your tenant. The create_date defaults to the current date. The endpoint returns an account_status_id which represents a record in the account’s history log.

HTTP REQUEST

POST /account_status

ARGUMENTS

Parameter Type Required Description
account_id UUID required The id of the account to which the status belongs
status string required Status of the account such as “Signed Up” or “Awaiting Payment”
stage_id UUID required Refers to the stage the client is in.
Useful for sign-up funnels
comments string optional Comments for the client regarding the status of their account
metadata map optional Custom information associated with the entity in the format key:value
See Metadata
secondary_id string optional Alternate id that can be used to identify the object such as an internal id

Retrieve an account status

Example Request

curl -X GET -H "Authorization: Bearer 7f137375-c63b-49fb-84eb-5abbd3b780a3" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/account_status/6db4a470-a00c-40bb-a325-067d0bdb3ddc"
api_instance = nucleus_api.AccountApi(nucleus_api.ApiClient(configuration))
try:
    api_response = api_instance.get_account_status_using_get("7e2d43c7-b52e-4333-9b10-fb6b9b0f7606")
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_account_status_using_get: %s\n" % e)
AccountApi apiInstance = new AccountApi();
        try {
            AccountStatus responseStatus = apiInstance.getAccountStatusUsingGet(UUID.fromString("7e2d43c7-b52e-4333-9b10-fb6b9b0f7606"));
            System.out.println(responseStatus);
        } catch (ApiException e) {
            System.err.println("Exception when calling getAccountStatusUsingGet");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\AccountApi(
    new GuzzleHttp\Client(),
    $config
);
$account_status_id = "7e2d43c7-b52e-4333-9b10-fb6b9b0f7606"; // string | UUID account_status_id

try {
    $accountstatus = $apiInstance->getAccountStatusUsingGet($account_status_id);
    print_r($accountstatus);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->getAccountStatusUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::AccountApi.new
account_status_id = '7e2d43c7-b52e-4333-9b10-fb6b9b0f7606' # String | UUID account_status_id
begin
  #Retrieve an account status
  accountstatus = api_instance.get_account_status_using_get(account_status_id)
  p accountstatus
rescue NucleusApi::ApiError => e
  puts "Exception when calling AccountApi->get_account_status_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.AccountApi();
var accountstatusID = "e46a78a7-3fe0-4502-a5ec-e42660bab4b5";


var accountstatus = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.getAccountStatusUsingGet("e46a78a7-3fe0-4502-a5ec-e42660bab4b5", accountstatus)

Example Response

{
    "id": "6db4a470-a00c-40bb-a325-067d0bdb3ddc",
    "create_date": "2018-02-08T16:59:27.000+0000",
    "update_date": "2018-02-08T16:59:27.000+0000",
    "comments": "Invested",
    "status": "Complete",
    "stage_id": "e995d4c1-f989-4733-9867-713966ac9856",
    "account_id": "1d7e1aad-3c79-49fe-bbb9-bd5e239ae1e7",
    "metadata": {}
}

Retrieve the information for a specific account status record for an account. The unique account_status_id must be provided. The endpoint returns details for the account status record specified.

HTTP REQUEST

GET /account_status/{account_status_id}

Update an account status

Example Request

curl -X PUT -H "Authorization: Bearer 7f137375-c63b-49fb-84eb-5abbd3b780a3" \
-H "Content-Type: application/json" \
-d '{
        "comments": "Invested",
        "status": "Complete",
        "stage_id": "e995d4c1-f989-4733-9867-713966ac9856",
        "account_id": "1d7e1aad-3c79-49fe-bbb9-bd5e239ae1e7"
    }' "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/account_status/6db4a470-a00c-40bb-a325-067d0bdb3ddc"
api_instance = nucleus_api.AccountApi(nucleus_api.ApiClient(configuration))
# # Update AccountStatus
status_update = {'status': 'Account_Updated'}
status_id = '29c8a864-a770-4311-a237-656fd8345079'

try:
    api_response = api_instance.update_account_status_using_put(status_update, status_id);
    pprint(api_response)
except ApiException as e:
    print("Exception when calling update_account_status_using_put: %s\n" % e)
AccountApi apiInstance = new AccountApi();
        //Update Account Status
        Map map3 = new HashMap();
        map.put("status", "Account Updated");

        try {
            AccountStatus response = apiInstance.updateAccountStatusUsingPut(map3, UUID.fromString("91736ab4-7e7a-49f8-957c-2100fa652bb2"));
            System.out.println(response);
        } catch (ApiException e) {
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\AccountApi(
    new GuzzleHttp\Client(),
    $config
);
//Update Account Status
$account_status_update = new stdClass();
$account_permission_id = "1906cd8b-9f7a-4f8a-974d-ea9823fb3b8c";

try {
    $account_status_update->status = "new";
    $result = $apiInstance->updateAccountStatusUsingPut($account_status_update, $account_status_id);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->updateAccountStatusUsingPut: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::AccountApi.new
#Update Account Status
account_status_update = {"status" => 'FULL_AUTHORITY'}
account_status_id = '91736ab4-7e7a-49f8-957c-2100fa652bb2'
begin
    result = api_instance.update_account_status_using_put(account_status_update, account_status_id)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->update_account_status_using_put: #{e}"
end
var apiInstance = new HydrogenNucleusApi.AccountApi();
//Update AccountStatus
var apiInstance = new HydrogenNucleusApi.AccountApi();
var callback = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
var accountstatus = new HydrogenNucleusApi.AccountStatus();
var accountstatusId = "edbc9269-0359-4002-9fe7-affca1639756";

accountstatus.status = 'New One';
apiInstance.updateAccountStatusUsingPut(accountstatus, accountstatusId, callback)

Example Response

{
    "id": "6db4a470-a00c-40bb-a325-067d0bdb3ddc",
    "create_date": "2018-02-08T16:59:27.000+0000",
    "update_date": "2018-02-08T16:59:27.000+0000",
    "comments": "Invested",
    "status": "Complete",
    "stage_id": "e995d4c1-f989-4733-9867-713966ac9856",
    "account_id": "1d7e1aad-3c79-49fe-bbb9-bd5e239ae1e7",
    "metadata": {}
}

Update an account status record for an account. The unique account_status_id must be provided. To obtain the appropriate account_status_id, use the GET /account_status endpoint to view all account statuses for each account defined for your tenant and their current information. The details to be updated must also be provided. The endpoint returns the account_status_id with the details for the account status.

HTTP REQUEST

PUT /account_status/{account_status_id}

Delete an account status

Example Request

curl -X DELETE -H "Authorization: Bearer 7f137375-c63b-49fb-84eb-5abbd3b780a3" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/account_status/6db4a470-a00c-40bb-a325-067d0bdb3ddc"
api_instance = nucleus_api.AccountApi(nucleus_api.ApiClient(configuration))
# # Update AccountStatus
# Delete a AccountStatus
status_id = '5dc6439e-34a1-4137-88ee-bda3e19b906d'
try:
    api_instance.delete_account_status_using_delete(status_id)
except ApiException as e:
    print("Exception when delete_account_status_using_delete: %s\n" % e)
AccountApi apiInstance = new AccountApi();
        //Delete Account Status
        try {
            AccountStatus deleteresponse = apiInstance.deleteAccountStatusUsingDelete(UUID.fromString("ede34b1a-198b-47d5-9e17-60c2e27d8dc3"));
            System.out.println(deleteresponse);
        } catch (ApiException e) {
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\AccountApi(
    new GuzzleHttp\Client(),
    $config
);
//Delete Account Status
$account_status_did = "c1c05ce4-3db9-4565-9880-0e17c25dad77"; // string | UUID account_id

try {
    $apiInstance->deleteAccountStatusUsingDelete($account_status_did);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->deleteAccountStatusUsingDelete: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::AccountApi.new
#Delete Account Status
accountstatus1_id = '1906cd8b-9f7a-4f8a-974d-ea9823fb3b8c'
begin
  result = api_instance.delete_account_status_using_delete(accountstatus1_id)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->delete_account_status_using_delete: #{e}"
end
var apiInstance = new HydrogenNucleusApi.AccountApi();
//Delete a AccountStatus
var accountstatus1 = "a1d829ea-f241-4bad-b851-049308736372"; // String | spending_control_id


var deleteaccountstatus = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully.');
    }
};
apiInstance.deleteAccountStatusUsingDelete(accountstatus1, deleteaccountstatus)

Response (204 No Content)

Permanently delete an account status record from an account’s history. The account_status_id must be provided. To obtain the appropriate account_status_id, use the GET /account_status endpoint to view all account statuses for each account defined for your tenant. This deletes the account_status_id from the account’s history log table and removes the status from the account.

HTTP REQUEST

DELETE /account_status/{account_status_id}

Account Permission

The Account Permission endpoints vary slightly from other Nucleus endpoints as they are not used to manage specific objects, but rather to manage the permission type of a client to an account. All of the authorities except the ROLE_CLIENT authority can access these endpoints.

Field Type Description
account_id UUID The id of the account being granted permissions
clients array List of clients mapped to the account and their permission type
      client_id UUID The id of the client being granted permissions to the account. Must also be included in the clients.client_id field of the account
      permission_type string The permission type for the client. Available values are INQUIRY_ACCESS, LIMITED_AUTHORITY, FULL_AUTHORITY, and POWER_OF_ATTORNEY. Please view the Permission Type resource for more information on each authority. To view what endpoints each authority permissions, please see this guide

List all account permissions

Example Request

curl -X GET -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/account_permission"
api_instance = nucleus_api.AccountApi(nucleus_api.ApiClient(configuration))
try:
    api_response = api_instance.get_all_account_permission_using_get()
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_all_account_permission_using_get: %s\n" % e)
AccountApi apiInstance = new AccountApi();
        try {
            PageAccountPermissionVO List = apiInstance.getAllAccountPermissionUsingGET(true, null, null, 0, 10);
            System.out.println(List);
        } catch (ApiException e) {
            System.err.println("Exception when calling getAllAccountPermissionUsingGET");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\AccountApi(
    new GuzzleHttp\Client(),
    $config
);
$ascending = false; // bool | ascending
$filter = null; // string | filter
$order_by = null; // string | order_by
$page = 0; // int | page
$size = 10; // int | size

try {
    $accountpermissionlist = $apiInstance->getAllAccountPermissionUsingGET($ascending, $filter, $order_by, $page, $size);
    print_r($accountpermissionlist);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->getAllAccountPermissionUsingGET: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::AccountApi.new
opts = {
    ascending: false, # BOOLEAN | ascending
    filter: null, # String | filter
    order_by: null, # String | order_by
    page: 0, # Integer | page
    size: 25 # Integer | size
}

begin
  #List all account permission
  accountpermissionlist = api_instance.get_all_account_permission_using_get(opts)
  p accountpermissionlist
rescue NucleusApi::ApiError => e
  puts "Exception when calling AccountApi->get_all_account_permission_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.AccountApi();
var opts = {
    'ascending': true, // Boolean | ascending
    // 'filter': "", // String | filter
    'orderBy': null, // String | order_by
    'page': 0, // Number | page
    'size': 10 // Number | size
};

var accountpermissionlist = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};

apiInstance.getAllAccountPermissionUsingGET(opts, accountpermissionlist)

Example Response

{
    "content": [
        {
            "account_id": "6fca8ba0-d7e6-42cb-863d-a0f9f794ced5",
            "clients": [
                {
                    "permission_type": "FULL_AUTHORITY",
                    "client_id": "6e8e1cbd-c52d-4be7-a466-b00863999b2c"
                },
                {
                    "permission_type": "INQUIRY_ACCESS",
                    "client_id": "4358f699-8563-46f7-aff4-9817c30ac907"
                }
            ]
        },
        {
            "account_id": "3db529a2-bab7-4ecf-8b7f-bb738a2ed371",
            "clients": [
                {
                    "permission_type": "FULL_AUTHORITY",
                    "client_id": "4358f699-8563-46f7-aff4-9817c30ac907"
                }
            ]
        }
    ],
    "total_elements": 2,
    "total_pages": 1,
    "last": true,
    "first": true,
    "sort": [
        {
            "direction": "DESC",
            "property": "updateDate",
            "ignore_case": false,
            "null_handling": "NATIVE",
            "ascending": false,
            "descending": true
        }
    ],
    "number_of_elements": 2,
    "size": 25,
    "number": 0
}

Get the clients and permission types for all accounts defined for your tenant. Account permissions control the actions that a client can take on an account. Only clients with the authority of ROLE_SUPER_ADMIN, ROLE_ADMIN, ROLE_PORTFOLIO_MANAGER, ROLE_MARKETING_MANAGER, ROLE_OPERATIONS, ROLE_SUPPORT, or ROLE_ADVISOR can access this endpoint.

HTTP REQUEST

GET /account_permission

Retrieve an account’s permissions

Example Request

curl -X GET -H "Authorization: Bearer 7f137375-c63b-49fb-84eb-5abbd3b780a3" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/account_permission/f446662e-042d-4a65-b528-f7b8353fb67e"
api_instance = nucleus_api.AccountApi(nucleus_api.ApiClient(configuration))
try:
    api_response = api_instance.get_account_permission_using_get("b28fdb2e-845a-4042-b518-619c8fb38589")
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_account_permission_using_get: %s\n" % e)
AccountApi apiInstance = new AccountApi();
        try {
            AccountPermissionVO responsePermission = apiInstance.getAccountPermissionUsingGET(UUID.fromString("eea5c34e-6a0c-4111-8790-8056a5f87e14"));
            System.out.println(responsePermission);
        } catch (ApiException e) {
            System.err.println("Exception when calling getAccountPermissionUsingGET");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\AccountApi(
    new GuzzleHttp\Client(),
    $config
);
$accountpermission_id = "eea5c34e-6a0c-4111-8790-8056a5f87e14"; // string | account_id

try {
    $accountpermission = $apiInstance->getAccountPermissionUsingGET($accountpermission_id);
    print_r($accountpermission);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->getAccountPermissionUsingGET: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::AccountApi.new
account_id = 'eea5c34e-6a0c-4111-8790-8056a5f87e14' # String | account_id
begin
  #Get an account permission
  accountpermissiion = api_instance.get_account_permission_using_get(account_id)
  p accountpermissiion
rescue NucleusApi::ApiError => e
  puts "Exception when calling AccountApi->get_account_permission_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.AccountApi();
var accountpermissionID = "84914c2a-9a9c-4ec6-bd86-5660aedbd8df";


var accountpermission = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.getAccountPermissionUsingGET("84914c2a-9a9c-4ec6-bd86-5660aedbd8df", accountpermission)

Example Response

{
    "account_id": "f446662e-042d-4a65-b528-f7b8353fb67e",
    "clients": [
        {
            "permission_type": "LIMITED_AUTHORITY",
            "client_id": "5c13bf69-3331-417a-bce7-88f8172363b5"
        }
    ]
}

Retrieve all the clients and their permission type for a specific account. Only clients with the authority of ROLE_SUPER_ADMIN, ROLE_ADMIN, ROLE_PORTFOLIO_MANAGER, ROLE_MARKETING_MANAGER, ROLE_OPERATIONS, ROLE_SUPPORT, or ROLE_ADVISOR can access this endpoint.

HTTP REQUEST

GET /account_permission/{account_id}

Update an account’s permissions

Example Request

curl -X PUT -H "Authorization: Bearer 7f137375-c63b-49fb-84eb-5abbd3b780a3" \
-H "Content-Type: application/json" \
-d '{
        "client_id": "I5c13bf69-3331-417a-bce7-88f8172363b5",
        "permission_type": "LIMITED_AUTHORITY"
    }' "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/account_permission/f446662e-042d-4a65-b528-f7b8353fb67e"
api_instance = nucleus_api.AccountApi(nucleus_api.ApiClient(configuration))
# Update AccountPermission
permission_update = {'permission_type': 'FULL_AUTHORITY'} # object | spending_control
permission_id = '7dfaa220-d01e-4a69-9f9e-896fc1803ebe' # str | UUID spending_control_id

try:
    api_response = api_instance.update_client_account_permission_using_put(permission_update, acl_client_permission_vo="7dfaa220-d01e-4a69-9f9e-896fc1803ebe");
    pprint(api_response)
except ApiException as e:
    print("Exception when calling update_client_account_permission_using_put: %s\n" % e)
AccountApi apiInstance = new AccountApi();
       //Update Account Permission
        Map map3 = new HashMap();
        map.put("permission_type", "FULL_AUTHORITY");

        try {
            AccountPermissionVO response = apiInstance.updateClientAccountPermissionUsingPUT(UUID.fromString("d5144cbb-64c8-4f4e-9ee2-28a07b003dc3"), map3);
            System.out.println(response);
        } catch (ApiException e) {
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\AccountApi(
    new GuzzleHttp\Client(),
    $config
);
//Update Account Permission
$account_permission_update = new stdClass();
$account_permission_id = "6d8a6df9-9ffc-42aa-8bbb-d86b9c6df361";

try {
    $account_permission_update->permission_type = "full_authority";
    $result = $apiInstance->updateClientAccountPermissionUsingPUT($account_permission_update, $account_permission_id);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->updateAccountAllocationMappingUsingPut: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::AccountApi.new
#Update Account Permisiion
account_permission_update = {"permission_type" => 'FULL_AUTHORITY'}
account_permission_id = '21f7e53f-fe46-4b3b-bf47-ac47e2d25f49'
begin
  result = api_instance.update_client_account_permission_using_put(account_permission_update, account_permission_id)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->update_client_account_permission_using_put: #{e}"
end
var apiInstance = new HydrogenNucleusApi.AccountApi();
//Update AccountPermission
var apiInstance = new HydrogenNucleusApi.AccountApi();
var callback = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
var accountpermission = new HydrogenNucleusApi.AclClientPermissionVO();
var accountpId = "88bc6be8-58b2-43c5-9dc2-081ea88a3b78";

accountpermission.permission_type = 'FULL_AUTHORITY';
apiInstance.updateClientAccountPermissionUsingPUT(accountpermission, accountpId, callback)

Example Response

{
    "account_id": "f446662e-042d-4a65-b528-f7b8353fb67e",
    "clients": [
        {
            "permission_type": "LIMITED_AUTHORITY",
            "client_id": "5c13bf69-3331-417a-bce7-88f8172363b5"
        }
    ]
}

Update the permission type of a client for an account. When a client_id is included in the clients embedded object of a call to the POST /account and PUT /account/{account_id} endpoints, they will automatically be mapped to the account with a permission type based on the client_account_association_type granted to them. If you would like the user to have a different permission type, you can use this endpoint to change it. The account_id is specified in the URL, and the client_id and the updated permission type must be provided in the request body. Only clients with the authority of ROLE_SUPER_ADMIN, ROLE_ADMIN, ROLE_PORTFOLIO_MANAGER, ROLE_MARKETING_MANAGER, ROLE_OPERATIONS, ROLE_SUPPORT, or ROLE_ADVISOR can access this endpoint.

HTTP REQUEST

PUT /account_permission/{account_id}

ARGUMENTS

Parameter Type Required Description
clients array optional List of clients mapped to the account and their permission type
      client_id UUID required The id of the client being granted permissions to the account. Must also be included in the clients.client_id field of the account
      permission_type string required The permission type for the client. Available values are INQUIRY_ACCESS, LIMITED_AUTHORITY, FULL_AUTHORITY, and POWER_OF_ATTORNEY. Please view the Permission Type resource for more information on each authority. To view what endpoints each authority permissions, please see this guide

Delete an account’s permissions

Example Request

curl -X DELETE -H "Authorization: Bearer 7f137375-c63b-49fb-84eb-5abbd3b780a3" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/account_permission/f446662e-042d-4a65-b528-f7b8353fb67e"
api_instance = nucleus_api.AccountApi(nucleus_api.ApiClient(configuration))
# Delete a AccountPermission
permission_id = 'a85769ac-3567-45d3-91d3-2970b85c5bd7'
try:
    api_instance.delete_account_permission_using_delete(permission_id)
except ApiException as e:
    print("Exception when delete_account_permission_using_delete: %s\n" % e)
AccountApi apiInstance = new AccountApi();
//Delete Account Permission
        try {
            AccountPermissionVO deleteresponse = apiInstance.deleteAccountPermissionUsingDELETE(UUID.fromString("37fbe1d5-848e-4b4a-982b-de7792fce6d3"));
            System.out.println(deleteresponse);
        } catch (ApiException e) {
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\AccountApi(
    new GuzzleHttp\Client(),
    $config
);
//Delete Account Permission
$account_permission_did = "88bc6be8-58b2-43c5-9dc2-081ea88a3b78"; // string | UUID account_id

try {
    $apiInstance->deleteAccountPermissionUsingDELETE($account_allocation_did);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->deleteAccountPermissionUsingDELETE: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::AccountApi.new
#Delete Account Permission
accountpermission1_id = 'a6324427-597a-4c8e-88ed-4e640944f4c5'
begin
  result = api_instance.delete_account_permission_using_delete(accountpermission1_id)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->delete_account_permission_using_delete: #{e}"
end
var apiInstance = new HydrogenNucleusApi.AccountApi();
//Delete a AccountPermission
var accountpermission1 = "39febc7f-ce86-4815-b4cb-cca9d05ba701"; // String | spending_control_id


var deleteaccountpermission = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully.');
    }
};
apiInstance.deleteAccountPermissionUsingDELETE(accountpermission1, deleteaccountpermission)

Response (204 No Content)

Permanently delete the permissions of an account. The account_id must be provided in the URL. This removes all the clients mapped to the account and their permission types. Only clients with the authority of ROLE_SUPER_ADMIN, ROLE_ADMIN, ROLE_PORTFOLIO_MANAGER, ROLE_MARKETING_MANAGER, ROLE_OPERATIONS, ROLE_SUPPORT, or ROLE_ADVISOR can access this endpoint.

HTTP REQUEST

DELETE /account_permission/{account_id}

Business

A business represents a corporate entity where collections of clients are employed.

Field Type Description
id UUID The id of the business
legal_name string Company full legal name listed at the state registrar
dba_name string Company “Doing Business as Name” or “DBA”
legal_structure string Company legal type such as C-Corp or LLC
category string Company category
subcategory string Company subcategory
identification_number string Legal identifier such as an EIN in the US, frequently used for Know-Your-Customer (KYC) purposes. Returns as omitted in all API responses for security.
identification_number_type string Type of identification number such as an “EIN” in the US
incorporation_date date Date the company was formed in the format yyyy-mm-dd
incorporation_country string Country the company was formed in, using the ISO ALPHA-2 Code. See country codes
incorporation_state string State the company was formed in, such as “Delaware”
email string Contact email for the business in the format [email protected]
phone_number string Phone number associated with the business
website string URL of the website for the business such as https://domain.com
address map Address details for the business
      address_line1 string Primary information for the street address, such as the street and building number
      address_line2 string Secondary information for the street address, such as a suite or apartment number
      city string City for the address
      state string State, province, or sub-country region for the address
      postalcode string Alphanumeric postal code or zip code for the address
      country string Country for the address using the ISO ALPHA-2 Code. See country codes
      type string Type of address such as “billing”, “mailing”, etc. This is used to differentiate between multiple addresses provided
ownership map Ownership details for the business
      client_id UUID ID of the client
      role string Role of the client in the business such as “COO” or “Vice President”
      percent_ownership double Ownership percentage for the individual such as “40”
      is_beneficial boolean Indicates if the individual is a beneficial owner, or that they own 25% or more of the business. Defaults to false which indicates they are not beneficial.
      is_primary boolean Indicates if the individual is the primary owner, such as the principal officer, proprietor, or director in the company. Only one record may be set to true per business. Defaults to false which indicates they are not primary.
is_public boolean Indicates if the company is listed publicly on a stock exchange. Defaults to null.
ticker string If the company is public, the ticker symbol on the exchange such as “AMZN”
status string Status of the business such as “Registered” or “Active”
is_verified boolean Indicates if the identifying details provided by the business have been verified by a Know-Your-Customer (KYC) vendor. Defaults to false which indicates it is not verified
is_active boolean Indicates if the business is currently active. Defaults to true which indicates it is active
metadata map Custom information associated with the business in the format key:value. See Metadata
secondary_id string Alternate id that can be used to identify the object such as an internal id
create_date timestamp Timestamp for the date and time that the record was created
update_date timestamp Timestamp for the date and time that the record was last updated

Business Management

List all businesses

Example Request

curl -X GET -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/business"
api_instance = nucleus_api.BusinessApi(nucleus_api.ApiClient(configuration))
try:
    # List all business
    api_response = api_instance.get_business_all_using_get(ascending=ascending,  order_by=order_by, page=page, size=size)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling BusinessApi->get_business_all_using_get: %s\n" % e)
BusinessApi apiInstance = new BusinessApi();
//Get all Business
try {
    PageBusiness response = apiInstance.getBusinessAllUsingGet(true, null, null, 0, 10);
    System.out.println(response);
} catch (ApiException e) {
    System.err.println("Exception when calling getBusinessAllUsingGet");
    e.printStackTrace();
}
$apiInstance = new com\hydrogen\nucleus\Api\BusinessApi(
    new GuzzleHttp\Client(),
    $config);
//List all Business
$ascending = false; // bool | ascending
$filter = null; // string | filter
$order_by = null; // string | order_by
$page = 0; // int | page
$size = 25; // int | size

try {
    $result = $apiInstance->getBusinessAllUsingGet($ascending, $filter, $order_by, $page, $size);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling BusinessApi->getBusinessAllUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::BusinessApi.new
#Get all Business
opts = {
    ascending: false, # BOOLEAN | ascending
    filter: nil, # String | filter
    order_by: nil, # String | order_by
    page: 0, # Integer | page
    size: 25 # Integer | size
}

begin
  result = api_instance.get_business_all_using_get(opts)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling BusinessApi->get_business_all_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.BusinessApi();
//List all Business
var opts = {
    'ascending': false, // Boolean | ascending
    'filter': null, // String | filter
    'orderBy': null, // String | order_by
    'page': 0, // Number | page
    'size': 25 // Number | size
};

var businesslist = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.getBusinessAllUsingGet(opts, businesslist);

Example Response

{
    "content": [
        {
            "id": "b0c59dc7-00d3-49e6-b7c4-6bdbb6c0808b",
            "legal_name": "Pacocha and Sons",
            "dba_name": null,
            "legal_structure": "LLC",
            "category": null,
            "subcategory": null,
            "identification_number": "*** omitted ***",
            "identification_number_type": "EIN",
            "incorporation_date": null,
            "incorporation_country": null,
            "incorporation_state": null,
            "email": null,
            "phone_number": null,
            "website": null,
            "address": [
                {
                    "address_line1": "0303 Heidi Freeway",
                    "address_line2": null,
                    "type": "registered",
                    "is_primary": false,
                    "city": "Karsonburgh",
                    "state": "NY",
                    "postalcode": "98559",
                    "country": "US"
                }
            ],
            "ownership": [
                {
                    "client_id": "714e8854-45ac-427e-a05d-d784bfc27f87",
                    "role": "President",
                    "percent_ownership": null,
                    "is_beneficial": false,
                    "is_primary": true
                },
                {
                    "client_id": "02245dc8-7f43-45cd-882f-0c16961128eb",
                    "role": "Vice-President",
                    "percent_ownership": null,
                    "is_beneficial": true,
                    "is_primary": false
                }
            ],
            "is_public": null,
            "ticker": null,
            "status": null,
            "is_verified": true,
            "is_active": true,
            "metadata":{},
            "secondary_id": null,
            "create_date": "2020-12-16T09:13:51.697+0000",
            "update_date": "2020-12-16T09:22:08.170+0000"
        },
        {
            "id": "19dfd772-2e2d-456d-ac58-e4c814d8a863",
            "legal_name": "Murazik Group",
            "dba_name": null,
            "legal_structure": "Sole Proprietorship",
            "category": null,
            "subcategory": null,
            "identification_number": "*** omitted ***",
            "identification_number_type": "EIN",
            "incorporation_date": null,
            "incorporation_country": null,
            "incorporation_state": null,
            "email": null,
            "phone_number": null,
            "website": null,
            "address": [
                {
                    "address_line1": "3584 Konopelski Manors",
                    "address_line2": null,
                    "type": "registered",
                    "is_primary": false,
                    "city": "New Melvin",
                    "state": "NY",
                    "postalcode": "98850",
                    "country": "US"
                }
            ],
            "ownership": [
                {
                    "client_id": "d4ca71f6-9b43-41f1-a883-f167bc83be16",
                    "role": "Secretary",
                    "percent_ownership": null,
                    "is_beneficial": false,
                    "is_primary": true
                }
            ],
            "is_public": null,
            "ticker": null,
            "status": null,
            "is_verified": true,
            "is_active": true,
            "metadata":{},
            "secondary_id": null,
            "create_date": "2020-12-15T14:03:14.617+0000",
            "update_date": "2020-12-16T08:15:37.070+0000"
        }
    ],
    "total_elements": 2,
    "total_pages": 1,
    "last": false,
    "sort": [
        {
            "direction": "DESC",
            "property": "updateDate",
            "ignore_case": false,
            "null_handling": "NATIVE",
            "ascending": false,
            "descending": true
        }
    ],
    "first": true,
    "number_of_elements": 25,
    "size": 25,
    "number": 0
}

Get details for all businesses registered with your tenant. Note that the address information and the metadata information are nested objects within the business object.

HTTP REQUEST

GET /business

Create a business

Example Request

curl -X POST -H "Authorization: Bearer <access_token>" \
    -H "Content-Type: application/json" \
    -d '{
                "id": "b0c59dc7-00d3-49e6-b7c4-6bdbb6c0808b",
                "legal_name": "Pacocha and Sons",
                "legal_structure": "LLC",
                "identification_number": "29-984848",
                "identification_number_type": "EIN",
                "address": [
                        {
                                "address_line1": "0303 Heidi Freeway",
                                "address_line2": null,
                                "type": "registered",
                                "is_primary": false,
                                "city": "Karsonburgh",
                                "state": "NY",
                                "postalcode": "98559",
                                "country": "US"
                        }
                ],
                "ownership": [
                        {
                                "client_id": "714e8854-45ac-427e-a05d-d784bfc27f87",
                                "role": "President",
                                "percent_ownership": null,
                                "is_beneficial": false,
                                "is_primary": true
                        },
                        {
                                "client_id": "02245dc8-7f43-45cd-882f-0c16961128eb",
                                "role": "Vice-President",
                                "percent_ownership": null,
                                "is_beneficial": true,
                                "is_primary": false
                        }
                ]
      }' "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/business"
api_instance = nucleus_api.BusinessApi(nucleus_api.ApiClient(configuration))
# Create Business
business_request = nucleus_api.Business(legal_name ='user 786') # Business | businessRequest
business_request.dba_name = 'hg67'
business_request.legal_structure = 'LLC'

try:
    # Create a business
    api_response = api_instance.create_business_using_post(business_request)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling BusinessApi->create_business_using_post: %s\n" % e)
BusinessApi apiInstance = new BusinessApi();
//Create a New Business
Business createRequest = new Business();
createRequest.legalName("abc Corp");
createRequest.dbaName("one");
createRequest.legalStructure("LLC");

try {
    Business result = apiInstance.createBusinessUsingPost(createRequest);
    System.out.println(result);
} catch (ApiException e) {
    System.err.println("Exception when calling createBusinessUsingPost");
    e.printStackTrace();
}
$apiInstance = new com\hydrogen\nucleus\Api\BusinessApi(
    new GuzzleHttp\Client(),
    $config);
//Create Business
$business_request = new \com\hydrogen\nucleus\Model\Business(); // \com\hydrogen\nucleus\Model\Business | businessRequest
$business_request->setLegalName("abc_corp");
$business_request->setDbaName("ab1");
$business_request->setLegalStructure("LLC");

try {
    $result = $apiInstance->createBusinessUsingPost($business_request);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling BusinessApi->createBusinessUsingPost: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::BusinessApi.new
#Create a Business
business_request = NucleusApi::Business.new # Business | businessRequest
business_request.legal_name = "abc Corps"
business_request.dba_name = "jjj"
business_request.legal_structure = "LLP Inc."


begin
  #Create a business
  result = api_instance.create_business_using_post(business_request)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling BusinessApi->create_business_using_post: #{e}"
end
var apiInstance = new HydrogenNucleusApi.BusinessApi();
//Create Business
var businessRequest = new HydrogenNucleusApi.Business(); // Business | businessRequest

businessRequest.legal_name = 'abgc Corp';
businessRequest.dba_name = 'one';
businessRequest.legal_structure = 'LLC';


var newBusiness = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.createBusinessUsingPost(businessRequest, newBusiness);

Example Response

{
    "id": "b0c59dc7-00d3-49e6-b7c4-6bdbb6c0808b",
    "legal_name": "Pacocha and Sons",
    "dba_name": null,
    "legal_structure": "LLC",
    "category": null,
    "subcategory": null,
    "identification_number": "*** omitted ***",
    "identification_number_type": "EIN",
    "incorporation_date": null,
    "incorporation_country": null,
    "incorporation_state": null,
    "email": null,
    "phone_number": null,
    "website": null,
    "address": [
        {
            "address_line1": "0303 Heidi Freeway",
            "address_line2": null,
            "type": "registered",
            "is_primary": false,
            "city": "Karsonburgh",
            "state": "NY",
            "postalcode": "98559",
            "country": "US"
        }
    ],
    "ownership": [
        {
            "client_id": "714e8854-45ac-427e-a05d-d784bfc27f87",
            "role": "President",
            "percent_ownership": null,
            "is_beneficial": false,
            "is_primary": true
        },
        {
            "client_id": "02245dc8-7f43-45cd-882f-0c16961128eb",
            "role": "Vice-President",
            "percent_ownership": null,
            "is_beneficial": true,
            "is_primary": false
        }
    ],
    "is_public": null,
    "ticker": null,
    "status": null,
    "is_verified": true,
    "is_active": true,
    "metadata":{},
    "secondary_id": null,
    "create_date": "2020-12-16T09:13:51.697+0000",
    "update_date": "2020-12-16T09:22:08.170+0000"
}

Create a new business with your tenant. The create_date will default to the current date. The endpoint returns a unique business_id that is used to manage the specific business and referenced in other endpoints.

HTTP REQUEST

POST /business

ARGUMENTS

Parameter Type Required Description
legal_name string required Company full legal name listed at the state registrar
dba_name string optional Company “Doing Business as Name” or “DBA”
legal_structure string optional Company legal type such as C-Corp or LLC
category string optional Company category
subcategory string optional Company subcategory
identification_number string optional Legal identifier such as an EIN in the US, frequently used for Know-Your-Customer (KYC) purposes. Returns as omitted in all API responses for security.
identification_number_type string optional Type of identification number such as an “EIN” in the US
incorporation_date date optional Date the company was formed in the format yyyy-mm-dd
incorporation_country string optional Country the company was formed in, using the ISO ALPHA-2 Code. See country codes
incorporation_state string optional State the company was formed in, such as “Delaware”
email string optional Contact email for the business in the format [email protected]
phone_number string optional Phone number associated with the business
website string optional URL of the website for the business such as https://domain.com
address map optional Address details for the business
      address_line1 string required Primary information for the street address, such as the street and building number
      address_line2 string optional Secondary information for the street address, such as a suite or apartment number
      city string required City for the address
      state string required State, province, or sub-country region for the address
      postalcode string optional Alphanumeric postal code or zip code for the address
      country string required Country for the address using the ISO ALPHA-2 Code. See country codes
      type string required Type of address such as “billing”, “mailing”, etc. This is used to differentiate between multiple addresses provided
ownership map optional Ownership details for the business
      client_id UUID required ID of the client
      role string required Role of the client in the business such as “COO” or “Vice President”
      percent_ownership double optional Ownership percentage for the individual such as “40”
      is_beneficial boolean optional Indicates if the individual is a beneficial owner, or that they own 25% or more of the business. Defaults to false which indicates they are not beneficial.
      is_primary boolean optional Indicates if the individual is the primary owner, such as the principal officer, proprietor, or director in the company. Only one record may be set to true per business. Defaults to false which indicates they are not primary.
is_public boolean optional Indicates if the company is listed publicly on a stock exchange. Defaults to null.
ticker string optional If the company is public, the ticker symbol on the exchange such as “AMZN”
status string optional Status of the business such as “Registered” or “Active”
is_verified boolean optional Indicates if the identifying details provided by the business have been verified by a Know-Your-Customer (KYC) vendor. Defaults to false which indicates it is not verified
is_active boolean optional Indicates if the business is currently active. Defaults to true which indicates it is active
metadata map optional Custom information associated with the business in the format key:value. See Metadata

Retrieve a business

Retrieve the information for a business registered with your tenant. The unique business_id must be provided. The endpoint returns the business_id and the details for the business. Note that the address information and the metadata information are nested objects within the business object.

Example Request

curl -X GET -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/business/b0c59dc7-00d3-49e6-b7c4-6bdbb6c0808b"
api_instance = nucleus_api.BusinessApi(nucleus_api.ApiClient(configuration))
    # Retrieve a Business
business_id = "4a39d289-f7e2-46b2-bd28-0938f92e1d63" # str | UUID business_id

try:
    # Retrieve a business
    api_response = api_instance.get_business_using_get(business_id)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling BusinessApi->get_business_using_get: %s\n" % e)
BusinessApi apiInstance = new BusinessApi();
//Get a Business
try {
    Business response1 = apiInstance.getBusinessUsingGet(UUID.fromString("4a39d289-f7e2-46b2-bd28-0938f92e1d63"));
    System.out.println(response1);
} catch (ApiException e) {
    System.err.println("Exception when calling getBusinessUsingGet");
    e.printStackTrace();
}
$apiInstance = new com\hydrogen\nucleus\Api\BusinessApi(
    new GuzzleHttp\Client(),
    $config);
//Retrieve a Business
$business_id = "4a39d289-f7e2-46b2-bd28-0938f92e1d63"; // string | UUID business_id

try {
    $result = $apiInstance->getBusinessUsingGet($business_id);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling BusinessApi->getBusinessUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::BusinessApi.new
#Retrieve All Business
business_id = '4a39d289-f7e2-46b2-bd28-0938f92e1d63' # String | UUID business_id

begin
  #Retrieve a business
  result = api_instance.get_business_using_get(business_id)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling BusinessApi->get_business_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.BusinessApi();
//Retrieve a Business
var businessId = "79c00351-ede2-44e3-8aeb-b7871e6f391c"; // String | UUID business_id


var business = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.getBusinessUsingGet(businessId, business);

Example Response

{
    "id": "b0c59dc7-00d3-49e6-b7c4-6bdbb6c0808b",
    "legal_name": "Pacocha and Sons",
    "dba_name": null,
    "legal_structure": "LLC",
    "category": null,
    "subcategory": null,
    "identification_number": "*** omitted ***",
    "identification_number_type": "EIN",
    "incorporation_date": null,
    "incorporation_country": null,
    "incorporation_state": null,
    "email": null,
    "phone_number": null,
    "website": null,
    "address": [
        {
            "address_line1": "0303 Heidi Freeway",
            "address_line2": null,
            "type": "registered",
            "is_primary": false,
            "city": "Karsonburgh",
            "state": "NY",
            "postalcode": "98559",
            "country": "US"
        }
    ],
    "ownership": [
        {
            "client_id": "714e8854-45ac-427e-a05d-d784bfc27f87",
            "role": "President",
            "percent_ownership": null,
            "is_beneficial": false,
            "is_primary": true
        },
        {
            "client_id": "02245dc8-7f43-45cd-882f-0c16961128eb",
            "role": "Vice-President",
            "percent_ownership": null,
            "is_beneficial": true,
            "is_primary": false
        }
    ],
    "is_public": null,
    "ticker": null,
    "status": null,
    "is_verified": true,
    "is_active": true,
    "metadata":{},
    "secondary_id": null,
    "create_date": "2020-12-16T09:13:51.697+0000",
    "update_date": "2020-12-16T09:22:08.170+0000"
}

HTTP REQUEST

GET /business/{business_id}

Update a business

Example Request

curl -X PUT -H "Authorization: Bearer <access_token>" \
    -H "Content-Type: application/json" \
    -d '{
                "website": "http://pacochaandsons.com"
        }' "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/business/11291d9b-fce0-4536-b4be-311f1a35c11f"
api_instance = nucleus_api.BusinessApi(nucleus_api.ApiClient(configuration))
# Update a Business
business = {'legal_name': 'lb'} # object | business
business_id = '17539e3e-232d-4d15-8354-61276b248f1a' # str | UUID business_id

try:
    api_response = api_instance.update_business_using_put(business, business_id)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling BusinessApi->update_business_using_put: %s\n" % e)
BusinessApi apiInstance = new BusinessApi();

//Update a Business
Map map = new HashMap();
map.put("dba_name", "abc");

try {
    Business response = apiInstance.updateBusinessUsingPut(map, UUID.fromString("1125097f-a6a4-4ac9-9be4-a96a2fd48e70"));
    System.out.println(response);
} catch (ApiException e) {
    e.printStackTrace();
}
$apiInstance = new com\hydrogen\nucleus\Api\BusinessApi(
    new GuzzleHttp\Client(),
    $config);
//Update Business
$business = new \stdClass; // object | business
$business->dba_name = "abb1";
$business_id = "4a39d289-f7e2-46b2-bd28-0938f92e1d63"; // string | UUID business_id

try {
    $result = $apiInstance->updateBusinessUsingPut($business, $business_id);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling BusinessApi->updateBusinessUsingPut: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::BusinessApi.new
#Update a Business
business = {"legal_name" => 'CAD'}
business_id = '4a39d289-f7e2-46b2-bd28-0938f92e1d63' # String | UUID business_id


begin
  result = api_instance.update_business_using_put(business, business_id)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling BusinessApi->update_business_using_put: #{e}"
end
var apiInstance = new HydrogenNucleusApi.BusinessApi();
//Update Business
var businessupdates = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
var business_id = "79c00351-ede2-44e3-8aeb-b7871e6f391c";
const updateBusiness = () => {
    var api = new HydrogenNucleusApi.BusinessApi()
    var updateBusiness = new HydrogenNucleusApi.Business(); // {AccountAllocationMapping} allocRequest
    updateBusiness.dba_name = "ABC";
    // api.getAllAdminClientUsingGet({}, callback);
    apiInstance.updateBusinessUsingPut(updateBusiness, business_id, businessupdates);

Example Response

{
    "id": "b0c59dc7-00d3-49e6-b7c4-6bdbb6c0808b",
    "legal_name": "Pacocha and Sons",
    "dba_name": null,
    "legal_structure": "LLC",
    "category": null,
    "subcategory": null,
    "identification_number": "*** omitted ***",
    "identification_number_type": "EIN",
    "incorporation_date": null,
    "incorporation_country": null,
    "incorporation_state": null,
    "email": null,
    "phone_number": null,
    "website": "http://pacochaandsons.com",
    "address": [
        {
            "address_line1": "0303 Heidi Freeway",
            "address_line2": null,
            "type": "registered",
            "is_primary": false,
            "city": "Karsonburgh",
            "state": "NY",
            "postalcode": "98559",
            "country": "US"
        }
    ],
    "ownership": [
        {
            "client_id": "714e8854-45ac-427e-a05d-d784bfc27f87",
            "role": "President",
            "percent_ownership": null,
            "is_beneficial": false,
            "is_primary": true
        },
        {
            "client_id": "02245dc8-7f43-45cd-882f-0c16961128eb",
            "role": "Vice-President",
            "percent_ownership": null,
            "is_beneficial": true,
            "is_primary": false
        }
    ],
    "is_public": null,
    "ticker": null,
    "status": null,
    "is_verified": true,
    "is_active": true,
    "metadata":{},
    "secondary_id": null,
    "create_date": "2020-12-16T09:13:51.697+0000",
    "update_date": "2020-12-16T09:22:08.170+0000"
}

Update the information for a business registered with your tenant. The unique business_id must be provided. To obtain the appropriate business_id, use the GET /business endpoint to view all available business_ids registered with your tenant and their current information. The details to be updated must also be provided. The endpoint returns the business_id and the details for the business. If you wish to have the business be no longer available for further activity without permanently deleting it, use this endpoint to mark a business as inactive by changing the is_active field to false.

HTTP REQUEST

PUT /business/{business_id}

Delete a business

Example Request

curl -X DELETE -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/business/11291d9b-fce0-4536-b4be-311f1a35c11f"
api_instance = nucleus_api.BusinessApi(nucleus_api.ApiClient(configuration))
#Delete Business
business_id = '17539e3e-232d-4d15-8354-61276b248f1a' # str | UUID business_id

try:
    # Delete a business
    api_instance.delete_business_using_delete(business_id)
except ApiException as e:
    print("Exception when calling BusinessApi->delete_business_using_delete: %s\n" % e)
BusinessApi apiInstance = new BusinessApi();
//Delete a Business
try {
    Business responseDelete = apiInstance.deleteBusinessUsingDelete(UUID.fromString("74788497-df70-4883-a8e3-44d004e88e6a"));
    System.out.println(responseDelete);
} catch (ApiException e) {
    System.err.println("Exception when calling deleteBusinessUsingDelete");
    e.printStackTrace();
}
$apiInstance = new com\hydrogen\nucleus\Api\BusinessApi(
    new GuzzleHttp\Client(),
    $config);
//Delete Business
$business_id = "4a39d289-f7e2-46b2-bd28-0938f92e1d63"; // string | UUID business_id

try {
    $apiInstance->deleteBusinessUsingDelete($business_id);
} catch (Exception $e) {
    echo 'Exception when calling BusinessApi->deleteBusinessUsingDelete: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::BusinessApi.new

#Delete a Business
business_id = '4a39d289-f7e2-46b2-bd28-0938f92e1d63' # String | UUID business_id


begin
  api_instance.delete_business_using_delete(business_id)
rescue NucleusApi::ApiError => e
  puts "Exception when calling BusinessApi->delete_business_using_delete: #{e}"
end
var apiInstance = new HydrogenNucleusApi.BusinessApi();
//Delete Business
var businessId = "8ad07e2c-d2ec-4ee1-b07d-6fb5dbdc4bc0"; // String | UUID business_id


var callback = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully.');
    }
};
apiInstance.deleteBusinessUsingDelete(businessId, callback);

Response (204 No Content)

Permanently delete a business registered with your tenant. The unique business_id must be provided. To obtain the appropriate business_id, use the GET /business endpoint to view all available business_ids registered with your tenant. This deletes the business_id and all the business information associated with it. To prevent a business_id from being used for further activity without permanently deleting it, you can use the PUT /business/{business_id} endpoint to mark a business as inactive by changing the is_active field to false.

HTTP REQUEST

DELETE /business/{business_id}

Business Activity

List all business asset sizes

Example Request

curl -X GET -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/business/099961da-7f41-4309-950f-2b51689a0033/asset_size"
api_instance = nucleus_api.BusinessApi(nucleus_api.ApiClient(configuration))
#Get Business Asset Size
business_id = '17539e3e-232d-4d15-8354-61276b248f1a' # str | UUID business_id
currency_conversion = 'USD'# str | Currency Code (optional)
end_date = 'null' # date | end date (optional) (default to null)
exclude_subledger = False # bool | exclude_subledger (optional) (default to false)
get_latest = False # bool | true or false (optional)
sort_type = 'null' # str |  Quarter (Q), Monthly (M) , Annually (Y), Daily (D) --caps matter, codes in () (optional)
start_date = 'null' # date | start date (optional) (default to null)

try:
    # List all business asset sizes
    api_response = api_instance.get_business_asset_size_using_get(business_id, currency_conversion=currency_conversion, end_date=end_date, exclude_subledger=exclude_subledger, get_latest=get_latest, sort_type=sort_type, start_date=start_date)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling BusinessApi->get_business_asset_size_using_get: %s\n" % e)
BusinessApi apiInstance = new BusinessApi();
//Get Business AssetSize
try {
    List<AvailableDateDoubleVO> result = apiInstance.getBusinessAssetSizeUsingGet(UUID.fromString("4a39d289-f7e2-46b2-bd28-0938f92e1d63"), null, enddate, true, false, null, startdate);
    System.out.println(result);
} catch (ApiException e) {
    System.err.println("Exception when calling getBusinessAssetSizeUsingGet");
    e.printStackTrace();
}
$apiInstance = new com\hydrogen\nucleus\Api\BusinessApi(
    new GuzzleHttp\Client(),
    $config);
//Get Business AssetSize
$business_id = "4a39d289-f7e2-46b2-bd28-0938f92e1d63"; // string | UUID business_id
$currency_conversion = null; // string | Currency Code
$end_date = new \DateTime("2020-10-18"); // \DateTime | end date
$exclude_subledger = true; // bool | exclude_subledger
$get_latest = false; // bool | true or false
$sort_type = null; // string | Quarter (Q), Monthly (M) , Annually (Y), Daily (D) --caps matter, codes in ()
$start_date = new \DateTime("2020-10-10"); // \DateTime | start date

try {
    $result = $apiInstance->getBusinessAssetSizeUsingGet($business_id, $currency_conversion, $end_date, $exclude_subledger, $get_latest, $sort_type, $start_date);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling BusinessApi->getBusinessAssetSizeUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::BusinessApi.new
#Get Asset Size
business_id = 'business_id_example' # String | UUID business_id

opts = {
    currency_conversion: '4a39d289-f7e2-46b2-bd28-0938f92e1d63', # String | Currency Code
    end_date: Date.parse('2020-12-12'), # Date | end date
    exclude_subledger: false, # BOOLEAN | exclude_subledger
    get_latest: true, # BOOLEAN | true or false
    sort_type: nil, # String |  Quarter (Q), Monthly (M) , Annually (Y), Daily (D) --caps matter, codes in ()
    start_date: Date.parse('2020-10-12') # Date | start date
}

begin
  #List all business asset sizes
  result = api_instance.get_business_asset_size_using_get(business_id, opts)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling BusinessApi->get_business_asset_size_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.BusinessApi();
//Get Business AssetSize
var businessId = "8ad07e2c-d2ec-4ee1-b07d-6fb5dbdc4bc0"; // String | UUID business_id

var opts = {
    'currencyConversion': null, // String | Currency Code
    'endDate': new Date(2020-12-26), // Date | end date
    'excludeSubledger': false, // Boolean | exclude_subledger
    'getLatest': true, // Boolean | true or false
    'sortType': null, // String |  Quarter (Q), Monthly (M) , Annually (Y), Daily (D) --caps matter, codes in ()
    'startDate': new Date(2020-10-18) // Date | start date
};

var asset = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.getBusinessAssetSizeUsingGet(businessId, opts, asset);

Example Response

[
    {
        "date": "2018-02-03",
        "currency_code": "USD",
        "value": 20000,
        "value_available": null,
        "value_pending": null,
        "cash_flow": 0
    },
    {
        "date": "2018-02-04",
        "currency_code": "USD",
        "value": 24500,
        "value_available": null,
        "value_pending": null,
        "cash_flow": 500
    }
]

Get a list of asset sizes per date for a business. Asset size records are created at the portfolio level and aggregated to yield the client asset size(s). The unique business_id must be provided. To obtain the appropriate business_id, use the GET /business endpoint to view all available business_ids registered with your tenant. The endpoint returns a list of asset sizes by date for the business. Additional parameters available to narrow down what is returned include: a date range, only obtaining the latest record, and sorting by different units of time (e.g. annually, quarterly, monthly, daily), etc.

HTTP REQUEST

GET /business/{business_id}/asset_size

ARGUMENTS

Parameter Type Required Description
get_latest boolean optional Retrieve only the latest asset size. Defaults to false if not set
sort_type string optional Sort the asset sizes by D Daily, M Monthly, Q Quarterly, Y Yearly. Defaults to D Daily if not set. Must be capital letters
start_date date optional Start date for the data. Defaults to the first date if not set
end_date date optional End date for the data. Defaults to the last date if not set
exclude_subledger boolean optional If set to “true”, excludes portfolios under accounts where is_subledger = “true” to not double count assets of subaccounts. Defaults to “false” which includes all portfolios under an account.
currency_conversion string optional Alphabetic currency code for the currency to convert all monetary values to. Value may be USD, GBP, EUR, AUD, CAD. Only available in enterprise plan.

RESPONSE

Field Type Description
date date Date for the asset size record. Displays the latest record if more than one entry exists for the given date.
currency_code string Alphabetic currency code for the asset size. See currency codes
value double Monetary value of all the business’ accounts on the particular date
value_available double Available monetary value of the business on the particular date
value_pending double Pending monetary value of the business on the particular date
cash_flow double Amount added to the client’s accounts or withdrawn from the accounts since the last asset size date. Value is used for performance calculations. Value may be positive or negative.

List all business holdings

Example Request

curl -X GET -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/business/099961da-7f41-4309-950f-2b51689a0033/holding"
api_instance = nucleus_api.BusinessApi(nucleus_api.ApiClient(configuration))
#Get Business Holding
business_id = '17539e3e-232d-4d15-8354-61276b248f1a' # str | UUID business_id
currency_conversion = 'USD' # str | Currency Code (optional)
end_date = '2020-12-11' # str | end date - yyyy-mm-dd (optional)
get_latest = False # bool | true or false (optional)
start_date = '2020-10-11' # str | start date - yyyy-mm-dd (optional)

try:
    # List all business holdings
    api_response = api_instance.get_business_holding_using_get(business_id, currency_conversion=currency_conversion, end_date=end_date, get_latest=get_latest, start_date=start_date)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling BusinessApi->get_business_holding_using_get: %s\n" % e)
BusinessApi apiInstance = new BusinessApi();
//Get Business Holding
try {
    List<PortfolioHoldingAgg> result1 = apiInstance.getBusinessHoldingUsingGet(UUID.fromString("4a39d289-f7e2-46b2-bd28-0938f92e1d63"), true, null, "2020-10-05", null, false, null, 0, 10, "2020-04-18");
    System.out.println(result1);
} catch (ApiException e) {
    System.err.println("Exception when calling getBusinessHoldingUsingGet");
    e.printStackTrace();
}
$apiInstance = new com\hydrogen\nucleus\Api\BusinessApi(
    new GuzzleHttp\Client(),
    $config);
//Get Business Holding
$business_id = "4a39d289-f7e2-46b2-bd28-0938f92e1d63"; // string | UUID business_id
$currency_conversion = null; // string | Currency Code
$end_date = "2020-11-17"; // string | end date - yyyy-mm-dd
$get_latest = true; // bool | true or false
$start_date = "2020-10-19"; // string | start date - yyyy-mm-dd

try {
    $result = $apiInstance->getBusinessHoldingUsingGet($business_id, $currency_conversion, $end_date, $get_latest, $start_date);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling BusinessApi->getBusinessHoldingUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::BusinessApi.new
#Get Holding
business_id = '4a39d289-f7e2-46b2-bd28-0938f92e1d63' # String | UUID business_id

opts = {
    currency_conversion: nil, # String | Currency Code
    end_date: nil, # String | end date - yyyy-mm-dd
    get_latest: true, # BOOLEAN | true or false
    start_date: '2020-10-14' # String | start date - yyyy-mm-dd
}

begin
  result = api_instance.get_business_holding_using_get(business_id, opts)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling BusinessApi->get_business_holding_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.BusinessApi();
//Get Business Holding
var businessId = "8ad07e2c-d2ec-4ee1-b07d-6fb5dbdc4bc0"; // String | UUID business_id

var opts = {
    'currencyConversion': null, // String | Currency Code
    'endDate': "2020-11-11", // String | end date - yyyy-mm-dd
    'getLatest': false, // Boolean | true or false
    'startDate': "2020-10-11",// String | start date - yyyy-mm-dd
};

var holding = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.getBusinessHoldingUsingGet(businessId, opts, holding);

Example Response

{
  "content": [
        {
            "date": "2018-02-03",
            "security_id": "73b5dbcd-0a40-4526-8348-368e17c9575d",
            "weight": 10,
            "currency_code": "USD",
            "amount": 2000,
            "cost_basis": null,
            "shares": 20
        },
        {
            "date": "2018-02-03",
            "security_id": "691c2255-a1a6-451f-b772-cb262725d7e2",
            "weight": 2,
            "currency_code": "USD",
            "amount": 400,
            "cost_basis": null,
            "shares": 4
        },
        {
            "date": "2018-02-03",
            "security_id": "0283c814-db55-4470-8cd8-8b9ae945182f",
            "weight": 30,
            "currency_code": "USD",
            "amount": 6000,
            "cost_basis": null,
            "shares": 60
        },
        {
            "date": "2018-02-03",
            "security_id": "0d652520-7e6a-461d-abe8-56b956c08d2e",
            "weight": 30,
            "currency_code": "USD",
            "amount": 6000,
            "cost_basis": null,
            "shares": 70
        },
        {
            "date": "2018-02-03",
            "security_id": "c090f392-409d-459a-8054-333fe96fb877",
            "weight": 28,
            "currency_code": "USD",
            "amount": 5600,
            "cost_basis": null,
            "shares": 50
        }
    ],
    "total_pages": 1,
    "total_elements": 5,
    "last": true,
    "sort": [
        {
            "direction": "DESC",
            "property": "id",
            "ignore_case": false,
            "null_handling": "NATIVE",
            "descending": true,
            "ascending": false
        }
    ],
    "first": true,
    "number_of_elements": 5,
    "size": 25,
    "number": 5
}

Get the information for all the securities that are currently being held by a business registered with your tenant. Holding records are created at a portfolio level and aggregated to show the holdings of the business. The unique business_id must be provided. To obtain the appropriate business_id, use the GET /business endpoint to view all available business_ids registered with your tenant. The endpoint returns a list of security_ids, the security amount, the security weight and the date of the record for all securities the business holds.

HTTP REQUEST

GET /business/{business_id}/holding

ARGUMENTS

Parameter Type Required Description
start_date date optional Start date for the data. Defaults to the first date if not set
end_date date optional End date for the data. Defaults to the last date if not set
get_latest boolean optional Retrieve only the latest asset size. Defaults to false if not set
currency_conversion string Alphabetic currency code for the currency to convert all monetary values to. Value may be USD, GBP, EUR, AUD, CAD. Only available in enterprise plan.

RESPONSE

Field Type Description
date date Date for the security holding. Displays the latest record if more than one entry exists for the given date.
security_id UUID The id for the security included in the holding record
weight double The weight of the security as a percentage of the client’s total monetary value; ex. 20 representing 20%
currency_code string Alphabetic currency code for the amount. See currency codes
amount double Monetary value of the shares in the holding record
cost_basis double Monetary value that the security was originally purchased for, used for tax purposes
shares double Number of shares in the holding record

List all business transactions

Example Request

curl -X GET -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/business/099961da-7f41-4309-950f-2b51689a0033/transaction"
api_instance = nucleus_api.BusinessApi(nucleus_api.ApiClient(configuration))
#Get Business Transaction
business_id = '17539e3e-232d-4d15-8354-61276b248f1a' # str | UUID business_id
ascending = False # bool | ascending (optional) (default to false)
currency_conversion = 'USD' # str | currency_conversion (optional)
end_date = '2020-12-10' # str | end date - yyyy-mm-dd (optional)
order_by = 'null' # str | order_by (optional) (default to update_date)
page = 0 # int | page (optional) (default to 0)
size = 25 # int | size (optional) (default to 25)
start_date = '2020-10-12' # str | start date - yyyy-mm-dd (optional)

try:
    # List all business transactions
    api_response = api_instance.get_business_client_transaction_all_using_get(business_id, ascending=ascending, currency_conversion=currency_conversion, end_date=end_date, order_by=order_by, page=page, size=size, start_date=start_date)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling BusinessApi->get_business_client_transaction_all_using_get: %s\n" % e)
BusinessApi apiInstance = new BusinessApi();

//Get Business Transaction
try {
    PagePortfolioTransaction result2 = apiInstance.getBusinessClientTransactionAllUsingGet(UUID.fromString("4a39d289-f7e2-46b2-bd28-0938f92e1d63"), true, null, "2020-04-07", null, null, 0, 10, "2020-08-10");
    System.out.println(result2);
} catch (ApiException e) {
    System.err.println("Exception when calling getBusinessClientTransactionAllUsingGet");
    e.printStackTrace();
}
$apiInstance = new com\hydrogen\nucleus\Api\BusinessApi(
    new GuzzleHttp\Client(),
    $config);
//Get Business Transaction
$business_id = "4a39d289-f7e2-46b2-bd28-0938f92e1d63"; // string | UUID business_id
$ascending = false; // bool | ascending
$currency_conversion = null; // string | currency_conversion
$end_date = "2020-11-16"; // string | end date - yyyy-mm-dd
$order_by = null; // string | order_by
$page = 0; // int | page
$size = 25; // int | size
$start_date = "2020-10-15"; // string | start date - yyyy-mm-dd

try {
    $result = $apiInstance->getBusinessClientTransactionAllUsingGet($business_id, $ascending, $currency_conversion, $end_date, $order_by, $page, $size, $start_date);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling BusinessApi->getBusinessClientTransactionAllUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::BusinessApi.new
#Get Transactions
business_id = '4a39d289-f7e2-46b2-bd28-0938f92e1d63' # String | UUID business_id

opts = {
    ascending: false, # BOOLEAN | ascending
    currency_conversion: nil, # String | currency_conversion
    end_date: '2020-12-12', # String | end date - yyyy-mm-dd
    order_by: nil, # String | order_by
    page: 0, # Integer | page
    size: 25, # Integer | size
    start_date: '2020-10-14' # String | start date - yyyy-mm-dd
}

begin
  #List all business transactions
  result = api_instance.get_business_client_transaction_all_using_get(business_id, opts)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling BusinessApi->get_business_client_transaction_all_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.BusinessApi();
//Get Client Transaction
var businessId = "8ad07e2c-d2ec-4ee1-b07d-6fb5dbdc4bc0"; // String | UUID business_id

var opts = {
    'ascending': false, // Boolean | ascending
    'currencyConversion': null, // String | currency_conversion
    'endDate': "2020-12-10", // String | end date - yyyy-mm-dd
    'orderBy': null, // String | order_by
    'page': 0, // Number | page
    'size': 25, // Number | size
    'startDate': "2020-10-10" // String | start date - yyyy-mm-dd
};

var transaction = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.getBusinessClientTransactionAllUsingGet(businessId, opts, transaction);

Example Response

{
  "content": [
    {
            "id": "efa289b2-3565-42e6-850b-8dad25727e99",
            "date": "2018-01-31T00:00:00.000+0000",
            "date_available": null,
            "is_recurring": false,
            "is_cleansed": false,
            "is_disputed": false,
            "is_read": true,
            "portfolio_id": "8ec467e6-6faa-4916-b380-6af0b21a34cc",
            "model_id": "6dbadddc-41ff-4634-a145-16678b422557",
            "price": 200,
            "quantity": 2,
            "currency_code": null,
            "amount": null,
            "balance": null,
            "merchant_id": null,
            "mid": null,
            "merchant": null,
            "merchant_category_code": null,
            "category": null,
            "subcategory": null,
            "description": null,
            "memo": null,
            "status": null,
            "location": {},
            "check": {},
            "funding_id": null,
            "security_id": "691c2255-a1a6-451f-b772-cb262725d7e2",
            "transaction_code_id": "f5af397b-7d22-433f-b01e-8202184a6386",
            "create_date": "2018-02-07T19:29:37.000+0000",
            "update_date": "2018-02-012T09:00:00.000+0000"
    },
    {
            "id": "efa289b2-3565-42e6-850b-8dad25727e24",
            "date": "2018-01-31T00:00:00.000+0000",
            "date_available": null,
            "is_recurring": false,
            "is_cleansed": false,
            "is_disputed": false,
            "is_read": true,
            "portfolio_id": "8ec467e6-6faa-4916-b380-6af0b21a34cc",
            "model_id": "6dbadddc-41ff-4634-a145-16678b422557",
            "price": 1000,
            "quantity": 6,
            "currency_code": null,
            "amount": null,
            "balance": null,
            "merchant_id": null,
            "mid": null,
            "merchant": null,
            "merchant_category_code": null,
            "category": null,
            "subcategory": null,
            "description": null,
            "memo": null,
            "status": null,
            "location": {},
            "check": {},
            "funding_id": null,
            "security_id": "0d652520-7e6a-461d-abe8-56b956c08d2e",
            "transaction_code_id": "f5af397b-7d22-433f-b01e-8202184a6386",
            "create_date": "2017-08-02T04:30:25.000+0000",
            "update_date": "2017-11-18T09:00:00.000+0000"
    }
  ],
    "total_pages": 1,
    "total_elements": 2,
    "last": true,
    "sort": [
        {
            "direction": "DESC",
            "property": "id",
            "ignore_case": false,
            "null_handling": "NATIVE",
            "descending": true,
            "ascending": false
        }
    ],
    "first": true,
    "number_of_elements": 2,
    "size": 25,
    "number": 2
}

Get the information for all transactions under a business. Transaction records are created at a portfolio level and all transactions for each portfolio below the business account(s) are returned to show the business transaction activity. The unique business_id must be provided. To obtain the appropriate business_id, use the GET /business endpoint to view all available business_ids registered with your tenant. The endpoint returns a list of transaction_ids and details for each transaction.

HTTP REQUEST

GET /business/{business_id}/transaction

ARGUMENTS

Parameter Type Required Description
start_date date optional Start date for the data. Defaults to the first date if not set
end_date date optional End date for the data. Defaults to the last date if not set
currency_conversion string Alphabetic currency code for the currency to convert all monetary values to. Value may be USD, GBP, EUR, AUD, CAD. Only available in enterprise plan.

RESPONSE

Field Type Description
id UUID The id for the transaction record
date timestamp Timestamp when the transaction occurred
date_available timestamp Timestamp when the transaction becomes available
is_cleansed boolean Indicates if the transaction has been cleansed by a data cleansing engine. Defaults to false which indicates that it has not been cleansed
is_read boolean Indicates if the transaction has been read. Defaults to false which indicates that it has not been read
is_recurring boolean Indicates if the transaction is recurring such as a subscription. Defaults to false which indicates that it is not recurring
is_disputed boolean Indicates if the transaction is disputed by the client. Defaults to false which indicates that it is not disputed
portfolio_id UUID The id of the portfolio that the transaction record relates to
funding_id UUID The id of the funding request that the transaction record relates to
model_id UUID The id of the model to which the portfolio that the transaction falls under subscribes
price integer Price for the security included in the transaction at which it was sold or purchased
quantity integer Quantity of shares of the security purchased
currency_code string Alphabetic currency code for the amount. See currency codes
amount double Amount of the transaction
balance double Updated balance of the portfolio as a result of the transaction
merchant_id UUID ID of the merchant resource for the transaction
mid string Acquirer ID of the merchant (MID) for the transaction
merchant string The merchant for the transaction such as the merchant posted for a credit or debit card charge
merchant_category_code string The MCC Code for the merchant as identified by the card network
category string Category of the transaction
subcategory string Subcategory of the transaction
description string Description of the transaction
memo string Memo attached to the transaction
status string Status of the transaction
location map Location where the transaction occurred
      address_line1 string Primary information for the street address, such as the street and building number
      address_line2 string Secondary information for the street address, such as a suite or apartment number
      city string City for the address
      state string State, province, or sub-country region for the address
      postalcode string Alphanumeric postal code or zip code for the address
      country string Country for the address using the ISO ALPHA-2 Code. See country codes
      latitude double Latitude of the location where the transaction occurred
      longitude double Longitude of the location where the transaction occurred
check map Check associated with the banking transaction
      check_number string Number on the check such as “1234”
      check_amount double Monetary amount of the check
      check_images map Image(s) of the scanned check(s)
            image_url string URL where the image can be displayed
            image_type string Type of image for the check such as “png” or “jpeg”
security_id UUID The id of the security included in the transaction
transaction_code_id integer The id referring to the transaction codes defined by your business
secondary_id string Alternate id that can be used to identify the object such as an internal id
create_date timestamp Timestamp for the date and time that the record was created
update_date timestamp Timestamp for the date and time that the record was last updated

Client

Clients represent users (both internal and external) within your tenant, and are used throughout the Hydrogen platform. For example, accounts, cards, budgets are all created below clients.

Field Type Description
id UUID The id of the client
username string Username for the client used on the firm’s platform
password string User’s unique password for the application if stored with Hydrogen. All passwords should be passed as plain text and will be hashed and salted for storage using the Bcrypt algorithm. This field will not return in any responses.
authorities array The role(s) for the user. If not supplied, default is ROLE_CLIENT. Available values are ROLE_SUPER_ADMIN, ROLE_ADMIN, ROLE_PORTFOLIO_MANAGER, ROLE_MARKETING_MANAGER, ROLE_OPERATIONS, ROLE_SUPPORT, ROLE_BUSINESS_OWNER, ROLE_ADVISOR, ROLE_CLIENT. Comma separate if multiple roles exist for a user (e.g. “ROLE_ADMIN, ROLE_ADVISOR”). Please view the Authorities resource for more information on each role. To view what endpoints each role permissions, please see this guide
client_type string Defined client type for the client. Available client types are individual, firm, admin, business_owner, employee and advisor, all case sensitive
email string Contact email for the client in the format [email protected]
business_id UUID If the client belongs to a specific Business, either as an owner or employee, the id of the business
firm_name string Company name if the client_type = “firm”. Use this field if the client and the business are one in the same, usually for a sole proprietor or small business.
firm_type string Company type such as Sole-Proprietor or LLP if the client_type = “firm”
title string The title of the client such as “Mr.”, “Ms.”, “Miss”, “Mrs.”, etc.
first_name string First name or given name of the client
middle_name string Middle name of the client
last_name string Last name or surname of the client
suffix string Suffix of the client such as “Jr.” or “Sr.”
phone_number string Phone number associated with the client
date_of_birth date Date of birth of the client in the ISO 8601 format YYYY-MM-DD. Returns as omitted in all API responses for security.
identification_number string National identification number for a client such as an SSN in the US, frequently used for Know-Your-Customer (KYC) purposes. Returns as omitted in all API responses for security.
identification_number_type string Type of national identification number for a client such as an SSN, TIN, or EIN in the US
country_of_residence string The country of residence of a client, often corresponding to the country issuing the identification number provided above using the ISO ALPHA-2 Code, frequently used for Know-Your-Customer (KYC) purposes. See country codes
country_of_citizenship array The country or countries of citizenship of a client, often corresponding to the country issuing the identification number provided above using the ISO ALPHA-2 Code, frequently used for Know-Your-Customer (KYC). See country codes
citizenship_status string The client’s citizenship status such as “Citizen” or “Resident Alien” in the US
gender string The client’s gender. Available values are female, male, and other.
employment map Employment details for the client
      employment_status string Status of employment. Value may be employed, unemployed, student, retired, self_employed
      job_title string Job title of client such as “Analyst” or “Associate”
      employer string Name of employer such as “Apple” or “Walmart”
      occupation string Occupation of client such as “Medical Services” or “Education”
income integer Annual income for the client
total_net_worth integer Total net worth of the client including the value of their home(s) and any cash and non cash holdings
liquid_net_worth integer Net worth of the client that can easily be converted to cash (cash, stocks, bonds, money market funds, CDs) excluding the value of their home(s) and retirement accounts
is_verified boolean Indicates if the identifying details provided by the client have been verified by a Know-Your-Customer (KYC) vendor. Defaults to false which indicates it is not verified
hydro_id string The Hydro ID associated with the client (if applicable). Corresponds to the Client Hydro entity
address map Address details for the client
      address_line1 string Primary information for the street address, such as the street and building number
      address_line2 string Secondary information for the street address, such as a suite or apartment number
      city string City for the address
      state string State, province, or sub-country region for the address
      postalcode string Alphanumeric postal code or zip code for the address
      country string Country for the address using the ISO ALPHA-2 Code. See country codes
      type string Type of address such as “home”, “work”, “billing”, “mailing”, etc. This is used to differentiate between multiple addresses provided
      is_primary boolean Indicates if the address is the primary address for a client. Only one address may be primary for a client_id. If a user sets an address to is_primary = “true” then all other addresses for that client_id will be set to is_primary = “false.” Defaults to false which indicates the address is not primary
status string Status of the client such as “Registered” or “Active”
is_active boolean Indicates if the client is currently active. Defaults to true which indicates it is active
group array Group clients together with your own identifier such as their subscription plan, for use with spending controls and rewards
metadata map Custom information associated with the client in the format key:value. See Metadata
secondary_id string Alternate id that can be used to identify the object such as an internal id
create_date timestamp Timestamp for the date and time that the record was created
update_date timestamp Timestamp for the date and time that the record was last updated

Client Management

List all clients

Example Request

curl -X GET -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/client"
api_instance = nucleus_api.ClientApi(nucleus_api.ApiClient(configuration))
try:
    api_response = api_instance.get_client_all_using_get()
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_client_all_using_get: %s\n" % e)
ClientApi apiInstance = new ClientApi();
        try {
            PageClient List = apiInstance.getClientAllUsingGet(true, null, null, 0, 10);
            System.out.println(List);
        } catch (ApiException e) {
            System.err.println("Exception when calling getClientAllUsingGet");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\ClientApi(
    new GuzzleHttp\Client(),
    $config);
$ascending = false; // bool | ascending
$filter = null; // string | filter
$order_by = null; // string | order_by
$page = 0; // int | page
$size = 10; // int | size

try {
    $clientlist = $apiInstance->getClientAllUsingGet($ascending, $filter, $order_by, $page, $size);
    print_r($clientlist);
} catch (Exception $e) {
    echo 'Exception when calling ClientApi->getClientAllUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::ClientApi.new
opts = {
    ascending: false, # BOOLEAN | ascending
    filter: null, # String | filter
    order_by: null, # String | order_by
    page: 0, # Integer | page
    size: 25 # Integer | size
}

begin
  clientlsit = api_instance.get_client_all_using_get(opts)
  p clientlsit
rescue NucleusApi::ApiError => e
  puts "Exception when calling ClientApi->get_client_all_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.ClientApi();
var opts = {
    'ascending': false, // Boolean | ascending
    // 'filter': "", // String | filter
    'orderBy': "update_date", // String | order_by
    'page': 0, // Number | page
    'size': 25 // Number | size
};

var clientList = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.getClientAllUsingGet(opts, clientList)

Example Response

{
    "content": [
        {
            "id": "8e1799f0-4429-4939-ae84-7391cff93ba5",
            "create_date": "2019-10-09T20:51:14.000+0000",
            "update_date": "2019-10-09T20:51:14.000+0000",
            "email": "[email protected]",
            "business_id":null,
            "firm_name": null,
            "firm_type": null,
            "title": "Mr.",
            "first_name": "Jim",
            "last_name": "Halpert",
            "suffix": null,
            "date_of_birth": "**omitted**",
            "identification_number": "**omitted**",
            "identification_number_type": "SSN",
            "phone_number": "987-765-1244",
            "username": "[email protected]",
            "client_type": "individual",
            "address": [],
            "hydro_id": null,
            "country_of_residence": "US",
            "country_of_citizenship": ["US"],
            "citizenship_status": null,
            "employment": {},
            "income": null,
            "gender": "male",
            "total_net_worth": null,
            "liquid_net_worth": null,
            "is_verified": false,
            "status": null,
            "is_active": true,
            "group": null,
            "metadata": {},
            "authorities": ["ROLE_CLIENT"]
        },
        {
            "id": "8fc301c0-50ef-4803-bb0c-b1dc57ffc85a",
            "create_date": "2019-10-09T20:50:13.000+0000",
            "update_date": "2019-10-09T20:50:13.000+0000",
            "email": "[email protected]",
            "business_id":null,
            "firm_name": null,
            "firm_type": null,
            "title": "Mr.",
            "first_name": "Jim",
            "last_name": "Halpert",
            "suffix": null,
            "date_of_birth": "**omitted**",
            "identification_number": "**omitted**",
            "identification_number_type": "SSN",
            "phone_number": "987-765-1244",
            "username": "[email protected]",
            "client_type": "individual",
            "address": [],
            "hydro_id": null,
            "country_of_residence": "US",
            "country_of_citizenship": ["US"],
            "citizenship_status": null,
            "employment": {},
            "income": null,
            "gender": "male",
            "total_net_worth": null,
            "liquid_net_worth": null,
            "is_verified": false,
            "status": null,
            "is_active": true,
            "group": null,
            "metadata": {
                "median_household_income": "10000"
            },
            "authorities": ["ROLE_CLIENT"]
        },
        {
            "id": "bb8394ca-84bd-4679-ac3e-874edeef15cf",
            "create_date": "2019-10-04T15:37:31.000+0000",
            "update_date": "2019-10-04T15:37:31.000+0000",
            "business_id":null,
            "firm_name": null,
            "firm_type": null,
            "title": "Mr.",
            "first_name": "John",
            "middle_name": "Henry",
            "last_name": "Smith",
            "suffix": null,
            "date_of_birth": "**omitted**",
            "identification_number": "**omitted**",
            "identification_number_type": "SSN",
            "phone_number": null,
            "username": "[email protected]",
            "client_type": "individual",
            "address": [],
            "hydro_id": null,
            "country_of_residence": "US",
            "country_of_citizenship": ["US"],
            "citizenship_status": null,
            "employment": {},
            "income": null,
            "gender": "male",
            "total_net_worth": null,
            "liquid_net_worth": null,
            "is_verified": false,
            "status": null,
            "is_active": true,
            "group": null,
            "metadata": {},
            "authorities": ["ROLE_CLIENT"]
        }
    ],
    "total_pages": 1,
    "total_elements": 3,
    "last": false,
    "number_of_elements": 25,
    "first": true,
    "sort": [
        {
            "direction": "DESC",
            "property": "updateDate",
            "ignore_case": false,
            "null_handling": "NATIVE",
            "descending": true,
            "ascending": false
        }
    ],
    "size": 25,
    "number": 0
}

Get details for all clients registered with your tenant. Note that the address information and the metadata information are nested objects within the client object.

HTTP REQUEST

GET /client

Create a client

Example Request

curl -X POST -H "Authorization: Bearer <access_token>" \
    -H "Content-Type: application/json" \
    -d '{
          "email": "[email protected]",
          "username": "[email protected]",
          "client_type": "individual",
          "title": "Mrs.",
          "first_name": "Angela",
          "last_name": "Martin",
          "phone_number": "987-765-1244",
          "date_of_birth": "1971-12-27",
          "identification_number_type": "SSN",
          "country_of_residence": "US",
          "country_of_citizenship": ["US"],
          "gender": "female",
          "is_verified": true,
          "is_active": true,
          "metadata": {
            "median_household_income": "10000"
          }
      }' "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/client"
api_instance = nucleus_api.ClientApi(nucleus_api.ApiClient(configuration))
# # Create a Client
client_new = nucleus_api.Client(first_name="Jack", last_name="Mason", email="[email protected]", username="jmason1", client_type="individual")
try:
    api_response = api_instance.create_client_using_post(client_new)
    pprint(api_response)
except ApiException as e:
    print("create_client_using_post: %s\n" % e)
ClientApi apiInstance = new ClientApi();
        //Create a Client
        Client createclient = new Client();
        createclient.setFirstName("Onestar");
        createclient.setLastName("One");
        createclient.setEmail("[email protected]");
        createclient.setUsername("tre6656yte");
        createclient.setClientType("individual");

                try {
            Client result = apiInstance.createClientUsingPost(createclient);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling createClientUsingPost");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\ClientApi(
    new GuzzleHttp\Client(),
    $config);
$ascending = false; // bool | ascending
//Create Client
$client = new \com\hydrogen\nucleus\Model\Client();

try {
    $client->setFirstName("Mack");
    $client->setLastName("Donald");
    $client->setEmail("[email protected]");
    $client->setUsername("555g5");
    $client->setClientType("individual");
    $result = $apiInstance->createClientUsingPost($client);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->createClientUsingPost: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::ClientApi.new
#Create Client
client = NucleusApi::Client.new

begin
  client.first_name = "Andy"
  client.last_name = "Bick"
  client.email = "[email protected]"
  client.username = "6546545"
  client.client_type = "individual"
  result = api_instance.create_client_using_post(client)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->create_client_using_post: #{e}"
end
var apiInstance = new HydrogenNucleusApi.ClientApi();
//Create Client
var client = new HydrogenNucleusApi.Client();
client.first_name = "Andy";
client.last_name = "murray";
client.username = "fgdfd4";
client.email = "[email protected]";
client.client_type = "individual";



var newcllient = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.createClientUsingPost(client, newcllient)

Example Response

{
    "id": "11291d9b-fce0-4536-b4be-311f1a35c11f",
    "create_date": "2019-10-10T12:41:18.768+0000",
    "update_date": "2019-10-10T12:41:18.768+0000",
    "email": "[email protected]",
    "business_id":null,
    "firm_name": null,
    "firm_type": null,
    "title": "Mrs.",
    "first_name": "Angela",
    "last_name": "Martin",
    "suffix": null,
    "date_of_birth": "**omitted**",
    "identification_number": "**omitted**",
    "identification_number_type": "SSN",
    "phone_number": "987-765-1244",
    "username": "[email protected]",
    "password": null,
    "client_type": "individual",
    "address": [],
    "hydro_id": null,
    "country_of_residence": "US",
    "country_of_citizenship": ["US"],
    "citizenship_status": null,
    "gender": "female",
    "employment": {},
    "income": null,
    "total_net_worth": null,
    "liquid_net_worth": null,
    "is_verified": true,
    "status": null,
    "is_active": true,
    "group": null,
    "metadata": {
        "median_household_income": "10000"
    },
    "authorities": ["ROLE_CLIENT"]
}

Create a new client, or register a new user, with your tenant. The create_date will default to the current date. The endpoint returns a unique client_id that is used to manage the specific client and referenced in other endpoints.

HTTP REQUEST

POST /client

ARGUMENTS

Parameter Type Required Description
username string required Username for the client used on the firm’s platform
client_type string required Defined client type for the client. Available client types are individual, firm, admin, and advisor, all case sensitive
password string optional User’s unique password for the application if stored with Hydrogen. All passwords should be passed as plain text and will be hashed and salted for storage using the Bcrypt algorithm. This field will not return in any responses.
authorities array optional The role(s) for the user. If not supplied, default is ROLE_CLIENT. Available values are ROLE_SUPER_ADMIN, ROLE_ADMIN, ROLE_PORTFOLIO_MANAGER, ROLE_MARKETING_MANAGER, ROLE_OPERATIONS, ROLE_SUPPORT, ROLE_BUSINESS_OWNER, ROLE_ADVISOR, ROLE_CLIENT. Comma separate if multiple roles exist for a user (e.g. “ROLE_ADMIN, ROLE_ADVISOR”). Please view the Authorities resource for more information on each role. To view what endpoints each role permissions, please see this guide
email string optional Contact email for the client in the format [email protected]
business_id UUID optional If the client belongs to a specific Business, either as an owner or employee, the id of the business
firm_name string optional Company name if the client_type = “firm”. Use this field if the client and the business are one in the same, usually for a sole proprietor or small business.
firm_type string optional Company type such as C-Corp or LLC if the client_type = “firm”
title string optional The title of the client such as “Mr.”, “Ms.”, “Miss”, “Mrs.”, etc.
first_name string optional First name or given name of the client
middle_name string optional Middle name of the client
last_name string optional Last name or surname of the client
suffix string optional Suffix of the client such as “Jr.” or “Sr.”
phone_number string optional Phone number associated with the client
date_of_birth date optional Date of birth of the client in the ISO 8601 format YYYY-MM-DD. Returns as omitted in all API responses for security.
identification_number string optional National identification number for a client such as an SSN in the US, frequently used for Know-Your-Customer (KYC) purposes. Returns as omitted in all API responses for security.
identification_number_type string optional Type of national identification number for a client such as an SSN, TIN, or EIN in the US
country_of_residence string optional The country of residence of a client, often corresponding to the country issuing the identification number provided above using the ISO ALPHA-2 Code, frequently used for Know-Your-Customer (KYC) purposes. See country codes
country_of_citizenship array optional The country or countries of citizenship of a client, often corresponding to the country issuing the identification number provided above using the ISO ALPHA-2 Code, frequently used for Know-Your-Customer (KYC). See country codes
citizenship_status string optional The client’s citizenship status such as “Citizen” or “Resident Alien” in the US
gender string optional The client’s gender. Available values are female, male, and other.
employment map optional Employment details for the client
      employment_status string optional Status of employment. Value may be employed, unemployed, student, retired, self_employed
      job_title string optional Job title of client such as “Analyst” or “Associate”
      employer string optional Name of employer such as “Apple” or “Walmart”
      occupation string optional Occupation of client such as “Medical Services” or “Education”
income integer optional The total income for the client
total_net_worth integer optional Total net worth of the client including the value of their home(s) and any cash and non cash holdings
liquid_net_worth integer optional Net worth of the client that can easily be converted to cash (cash, stocks, bonds, money market funds, CDs) excluding the value of their home(s) and retirement accounts
is_verified boolean optional Indicates if the identifying details provided by the client have been verified by a Know-Your-Customer (KYC) vendor. Defaults to false which indicates it is not verified
hydro_id string optional The Hydro ID associated with the client (if applicable). Corresponds to the Client Hydro entity
address map optional Address details for the client
      address_line1 string required Primary information for the street address, such as the street and building number
      address_line2 string optional Secondary information for the street address, such as a suite or apartment number
      city string required City for the address
      state string required State, province, or sub-country region for the address
      postalcode string optional Alphanumeric postal code or zip code for the address
      country string required Country for the address using the ISO ALPHA-2 Code. See country codes
      type string required Type of address such as “home”, “work”, “billing”, “mailing”, etc. This is used to differentiate between multiple addresses provided
      is_primary boolean optional Indicates if the address is the primary address for a client. Only one address may be primary for a client_id. If a user sets an address to is_primary = “true” then all other addresses for that client_id will be set to is_primary = “false.” Defaults to false which indicates the address is not primary
status string optional Status of the client such as “Registered” or “Active”
is_active boolean optional Indicates if the client is currently active. Defaults to true which indicates it is active
group array optional Group clients together with your own identifier such as their subscription plan, for use with spending controls and rewards
metadata map optional Custom information associated with the client in the format key:value.
See Metadata
secondary_id string optional Alternate id that can be used to identify the object such as an internal id

Retrieve a client

Retrieve the information for a client registered with your tenant. The unique client_id must be provided. The endpoint returns the client_id and the details for the client. Note that the address information and the metadata information are nested objects within the client object.

Example Request

curl -X GET -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/client/11291d9b-fce0-4536-b4be-311f1a35c11f"
api_instance = nucleus_api.ClientApi(nucleus_api.ApiClient(configuration))
try:
    api_response = api_instance.get_client_using_get("474c590d-7ecf-4eab-9bd6-781096ad1621")
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_client_using_get: %s\n" % e)
ClientApi apiInstance = new ClientApi();
        try {
            Client responseClient = apiInstance.getClientUsingGet(UUID.fromString("489a13a9-aab1-42d9-a84f-1ab0d95c919c"));
            System.out.println(responseClient);
        } catch (ApiException e) {
            System.err.println("Exception when calling getClientUsingGet");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\ClientApi(
    new GuzzleHttp\Client(),
    $config);
$client_id = "489a13a9-aab1-42d9-a84f-1ab0d95c919c"; // string | UUID client_id

try {
    $client = $apiInstance->getClientUsingGet($client_id);
    print_r($client);
} catch (Exception $e) {
    echo 'Exception when calling ClientApi->getClientUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::ClientApi.new
client_id = '489a13a9-aab1-42d9-a84f-1ab0d95c919c' # String | UUID client_id

begin
  client = api_instance.get_client_using_get(client_id)
  p client
rescue NucleusApi::ApiError => e
  puts "Exception when calling ClientApi->get_client_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.ClientApi();
var clientId = "8dccec61-e85f-4a3f-a583-0a4df9ae7bd5";


var client = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.getClientUsingGet(clientId, client)

Example Response

{
    "id": "11291d9b-fce0-4536-b4be-311f1a35c11f",
    "create_date": "2019-10-10T12:41:19.000+0000",
    "update_date": "2019-10-10T12:41:19.000+0000",
    "email": "[email protected]",
    "business_id":null,
    "firm_name": null,
    "firm_type": null,
    "title": "Mrs.",
    "first_name": "Angela",
    "last_name": "Martin",
    "suffix": null,
    "date_of_birth": "**omitted**",
    "identification_number": "**omitted**",
    "identification_number_type": "SSN",
    "phone_number": "987-765-1244",
    "username": "[email protected]",
    "client_type": "individual",
    "address": [],
    "hydro_id": "10lm4nz",
    "country_of_residence": "US",
    "country_of_citizenship": ["US"],
    "citizenship_status": null,
    "gender": "female",
    "employment": {},
    "income": null,
    "total_net_worth": null,
    "liquid_net_worth": null,
    "is_verified": true,
    "status": null,
    "is_active": true,
    "group": null,
    "metadata": {
        "median_household_income": "10000"
    },
    "authorities": ["ROLE_CLIENT"]
}

HTTP REQUEST

GET /client/{client_id}

Update a client

Example Request

curl -X PUT -H "Authorization: Bearer <access_token>" \
    -H "Content-Type: application/json" \
    -d '{
          "email": "[email protected]",
          "username": "[email protected]",
          "client_type": "individual",
          "title": "Mrs.",
          "first_name": "Angela",
          "last_name": "Schrute",
          "phone_number": "987-765-1244",
          "date_of_birth": "1971-12-27",
          "identification_number_type": "SSN",
          "country_of_residence": "US",
          "gender": "female",
          "is_verified": true,
          "is_active": true,
          "metadata": {
            "median_household_income": "10000"
          },
        }' "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/client/11291d9b-fce0-4536-b4be-311f1a35c11f"
api_instance = nucleus_api.ClientApi(nucleus_api.ApiClient(configuration))
# # #Update Client
client_Update = {'gender': 'male'}
client_id = 'a05271bb-b963-4494-b6a2-b71738d23308'
try:
    api_response = api_instance.update_client_using_put(client_Update, client_id)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling update_client_using_put: %s\n" % e)
ClientApi apiInstance = new ClientApi();
        //        //Update Client
        Map map = new HashMap();
        map.put("firm_name", "ABC Corp");

        try {
            Client response = apiInstance.updateClientUsingPut(map, UUID.fromString("35158516-de7f-4955-895d-a3a3de9b21c0"));
            System.out.println(response);
        } catch (ApiException e) {
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\ClientApi(
    new GuzzleHttp\Client(),
    $config);
$ascending = false; // bool | ascending
//Update Client
$client_update = new stdClass();
$client_id = "d560e3d8-7dbb-4535-9e12-9525fa724af1";

try {
    $client_update->username = "abc44";
    $result = $apiInstance->updateClientUsingPut($client_update, $client_id);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->updateClientUsingPut: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::ClientApi.new
#Update Client
client_update = {"first_name" => 'visa'}
client_id = 'ad4c3086-c3f2-4b41-87fb-06e611c58b76'
begin
  result = api_instance.update_client_using_put(client_update, client_id)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->update_client_using_put: #{e}"
end
var apiInstance = new HydrogenNucleusApi.ClientApi();
//Update Client
var apiInstance = new HydrogenNucleusApi.ClientApi();
var callback = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
var clientupdate = new HydrogenNucleusApi.Card();
var clientid = "6442305d-0b0e-4f51-9c11-b32d7c4811bc";

clientupdate.email = "[email protected]";
apiInstance.updateClientUsingPut(clientupdate, clientid, callback)

Example Response

{
    "id": "11291d9b-fce0-4536-b4be-311f1a35c11f",
    "create_date": "2019-10-10T12:41:19.000+0000",
    "update_date": "2019-10-10T12:45:33.037+0000",
    "email": "[email protected]",
    "business_id":null,
    "firm_name": null,
    "firm_type": null,
    "title": "Mrs.",
    "first_name": "Angela",
    "last_name": "Schrute",
    "suffix": null,
    "date_of_birth": "**omitted**",
    "identification_number": "**omitted**",
    "identification_number_type": "SSN",
    "phone_number": "987-765-1244",
    "username": "[email protected]",
    "client_type": "individual",
    "address": [],
    "hydro_id": null,
    "country_of_residence": "US",
    "country_of_citizenship": ["US"],
    "citizenship_status": null,
    "gender": "other",
    "employment": {},
    "income": null,
    "total_net_worth": null,
    "liquid_net_worth": null,
    "is_verified": true,
    "status": null,
    "is_active": true,
    "group": null,
    "metadata": {
        "median_household_income": "10000"
    },
    "authorities": ["ROLE_CLIENT"]
}

Update the information for a client registered with your tenant. The unique client_id must be provided. To obtain the appropriate client_id, use the GET /client endpoint to view all available client_ids registered with your tenant and their current information. The details to be updated must also be provided. The endpoint returns the client_id and the details for the client. If you wish to have the client be no longer available for further activity without permanently deleting it, use this endpoint to mark a client as inactive by changing the is_active field to false.

HTTP REQUEST

PUT /client/{client_id}

Delete a client

Example Request

curl -X DELETE -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/client/11291d9b-fce0-4536-b4be-311f1a35c11f"
api_instance = nucleus_api.ClientApi(nucleus_api.ApiClient(configuration))
# # Delete a Client
client_id = 'c6e340ec-cc3a-4ac1-a234-a9356cf8c1a9'
try:
    api_instance.delete_client_using_delete(client_id)
except ApiException as e:
    print("Exception when delete_client_using_delete: %s\n" % e)
ClientApi apiInstance = new ClientApi();
// Delete Client
        try {
            Client deleteresponse = apiInstance.deleteClientUsingDelete(UUID.fromString("31dc26f8-95bb-4f07-bcba-27bc5a5d0e8b"));
            System.out.println(deleteresponse);
        } catch (ApiException e) {
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\ClientApi(
    new GuzzleHttp\Client(),
    $config);
$ascending = false; // bool | ascending
//Delete Client
$client_did = "9c13f576-1186-42a8-af86-fd53aa602241"; // string | UUID account_id

try {
    $apiInstance->deleteClientUsingDelete($client_did);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->deleteClientUsingDelete: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::ClientApi.new
#Delete Client
client1_id = 'b6b3ffe0-5642-40d6-a9e7-d610d27e9f0f'
begin
  result = api_instance.delete_client_using_delete(client1_id)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->delete_client_using_delete: #{e}"
end
var apiInstance = new HydrogenNucleusApi.ClientApi();
//Delete a Client
var clientdid = "d64ce0a1-9f09-43ae-b153-7f1ace1795eb";


var deleteclient = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully.');
    }
};
apiInstance.deleteClientUsingDelete(clientdid, deleteclient)

Response (204 No Content)

Permanently delete a client registered with your tenant. The unique client_id must be provided. To obtain the appropriate client_id, use the GET /client endpoint to view all available client_ids registered with your tenant. This deletes the client_id and all the client’s information associated with it. To prevent a client_id from being used for further activity without permanently deleting it, you can use the PUT /client/{client_id} endpoint to mark a client as inactive by changing the is_active field to false.

HTTP REQUEST

DELETE /client/{client_id}

Client Activity

List all client asset sizes

Example Request

curl -X GET -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/client/099961da-7f41-4309-950f-2b51689a0033/asset_size"
api_instance = nucleus_api.ClientApi(nucleus_api.ApiClient(configuration))
try:
    api_response = api_instance.get_client_asset_size_using_get("1d987750-3cbd-4720-861c-6fc6ed3d6262")
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_client_asset_size_using_get: %s\n" % e)
ClientApi apiInstance = new ClientApi();
        try {
            Object assetsize = apiInstance.getClientAssetSizeUsingGet(UUID.fromString("1d987750-3cbd-4720-861c-6fc6ed3d6262"), null, date2, true, true, null, date1);
            System.out.println(assetsize);
        } catch (ApiException e) {
            System.err.println("Exception when calling getClientAssetSizeUsingGet");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\ClientApi(
    new GuzzleHttp\Client(),
    $config);
$client_id = "489a13a9-aab1-42d9-a84f-1ab0d95c919c"; // string | UUID client_id
$currency_conversion = null; // string | Currency Code
$end_date = new \DateTime("null"); // \DateTime | end date
$exclude_subledger = false; // bool | exclude_subledger
$get_latest = true; // bool | true or false
$sort_type = null; // string | Quarter (Q), Monthly (M) , Annually (Y), Daily (D) --caps matter, codes in ()
$start_date = new \DateTime("null"); // \DateTime | start date

try {
    $assetsizeclient = $apiInstance->getClientAssetSizeUsingGet($client_id, $currency_conversion, $end_date, $exclude_subledger, $get_latest, $sort_type, $start_date);
    print_r($assetsizeclient);
} catch (Exception $e) {
    echo 'Exception when calling ClientApi->getClientAssetSizeUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::ClientApi.new
client_id = '1d987750-3cbd-4720-861c-6fc6ed3d6262' # String | UUID client_id

opts = {
    currency_conversion: null, # String | Currency Code
    end_date: Date.parse('2018-08-07'), # Date | end date
    exclude_subledger: false, # BOOLEAN | exclude_subledger
    get_latest: true, # BOOLEAN | true or false
    sort_type: null, # String |  Quarter (Q), Monthly (M) , Annually (Y), Daily (D) --caps matter, codes in ()
    start_date: Date.parse('2018-06-07') # Date | start date
}

begin
  asset = api_instance.get_client_asset_size_using_get(client_id, opts)
  p asset
rescue NucleusApi::ApiError => e
  puts "Exception when calling ClientApi->get_client_asset_size_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.ClientApi();
var clientId = "1d987750-3cbd-4720-861c-6fc6ed3d6262";

var opts = {
    'endDate': "2018-07-25",
    'startDate': "2020-09-10",
    'getLatest': true,
    'excludeSubledger': true,
    'ascending': false, // Boolean | ascending
    // 'filter': "", // String | filter
    //'orderBy': "update_date", // String | order_by
    'page': 0, // Number | page
    'size': 4 // Number | size

};
var clientassetsize = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.getClientAssetSizeUsingGet(clientId, opts)

Example Response

[
    {
        "date": "2018-02-03",
        "currency_code": "USD",
        "value": 20000,
        "value_available": null,
        "value_pending": null,
        "cash_flow": 0
    },
    {
        "date": "2018-02-04",
        "currency_code": "USD",
        "value": 24500,
        "value_available": null,
        "value_pending": null,
        "cash_flow": 500
    }
]

Get a list of asset sizes per date for a client. Asset size records are created at the portfolio level and aggregated to yield the client asset size(s). The unique client_id must be provided. To obtain the appropriate client_id, use the GET /client endpoint to view all available client_ids registered with your tenant. The endpoint returns a list of asset sizes by date for the client. Additional parameters available to narrow down what is returned include: a date range, only obtaining the latest record, and sorting by different units of time (e.g. annually, quarterly, monthly, daily), etc.

HTTP REQUEST

GET /client/{client_id}/asset_size

ARGUMENTS

Parameter Type Required Description
get_latest boolean optional Retrieve only the latest asset size. Defaults to false if not set
sort_type string optional Sort the asset sizes by D Daily, M Monthly, Q Quarterly, Y Yearly. Defaults to D Daily if not set. Must be capital letters
start_date date optional Start date for the data. Defaults to the first date if not set
end_date date optional End date for the data. Defaults to the last date if not set
exclude_subledger boolean optional If set to “true”, excludes portfolios under accounts where is_subledger = “true” to not double count assets of subaccounts. Defaults to “false” which includes all portfolios under an account.
currency_conversion string optional Alphabetic currency code for the currency to convert all monetary values to. Value may be USD, GBP, EUR, AUD, CAD. Only available in enterprise plan.

RESPONSE

Field Type Description
date date Date for the asset size record. Displays the latest record if more than one entry exists for the given date.
currency_code string Alphabetic currency code for the asset size. See currency codes
value double Monetary value of all the client’s accounts on the particular date
value_available double Available monetary value of the client on the particular date
value_pending double Pending monetary value of the client on the particular date
cash_flow double Amount added to the client’s accounts or withdrawn from the accounts since the last asset size date. Value is used for performance calculations. Value may be positive or negative.

List all client holdings

Example Request

curl -X GET -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/client/099961da-7f41-4309-950f-2b51689a0033/holding"
api_instance = nucleus_api.ClientApi(nucleus_api.ApiClient(configuration))
try:
    api_response = api_instance.get_client_holding_using_get("1d987750-3cbd-4720-861c-6fc6ed3d6262")
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_client_holding_using_get: %s\n" % e)
ClientApi apiInstance = new ClientApi();
        try {
            Object clientholding = apiInstance.getClientHoldingUsingGet(UUID.fromString("1d987750-3cbd-4720-861c-6fc6ed3d6262"), null, "2020-09-14", true, "2020-08-14");
            System.out.println(clientholding);
        } catch (ApiException e) {
            System.err.println("Exception when calling getClientHoldingUsingGet");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\ClientApi(
    new GuzzleHttp\Client(),
    $config);
$client_id = "489a13a9-aab1-42d9-a84f-1ab0d95c919c"; // string | UUID client_id
$currency_conversion = null; // string | Currency Code
$end_date = "2020-05-08"; // string | end date - yyyy-mm-dd
$get_latest = true; // bool | true or false
$start_date = "2020-08-06"; // string | start date - yyyy-mm-dd

try {
    $clientholdings = $apiInstance->getClientHoldingUsingGet($client_id, $currency_conversion, $end_date, $get_latest, $start_date);
    print_r($clientholdings);
} catch (Exception $e) {
    echo 'Exception when calling ClientApi->getClientHoldingUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::ClientApi.new
client_id = '1d987750-3cbd-4720-861c-6fc6ed3d6262' # String | UUID client_id

opts = {
    currency_conversion: null, # String | Currency Code
    end_date: '2019-01-01', # String | end date - yyyy-mm-dd
    get_latest: true, # BOOLEAN | true or false
    start_date: '2018-08-06' # String | start date - yyyy-mm-dd
}

begin
  holding = api_instance.get_client_holding_using_get(client_id, opts)
  p holding
rescue NucleusApi::ApiError => e
  puts "Exception when calling ClientApi->get_client_holding_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.ClientApi();
var clientId = "1d987750-3cbd-4720-861c-6fc6ed3d6262";

var opts = {
    'endDate': "2018-07-25",
    'startDate': "2020-09-10",
    'getLatest': true,
    'excludeSubledger': true,
    'ascending': false, // Boolean | ascending
    // 'filter': "", // String | filter
    //'orderBy': "update_date", // String | order_by
    'page': 0, // Number | page
    'size': 4 // Number | size

};
var clientholding = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.getClientHoldingUsingGet(clientId, opts, clientholding)

Example Response

{
  "content": [
        {
            "date": "2018-02-03",
            "security_id": "73b5dbcd-0a40-4526-8348-368e17c9575d",
            "weight": 10,
            "currency_code": "USD",
            "amount": 2000,
            "cost_basis": null,
            "shares": 20
        },
        {
            "date": "2018-02-03",
            "security_id": "691c2255-a1a6-451f-b772-cb262725d7e2",
            "weight": 2,
            "currency_code": "USD",
            "amount": 400,
            "cost_basis": null,
            "shares": 4
        },
        {
            "date": "2018-02-03",
            "security_id": "0283c814-db55-4470-8cd8-8b9ae945182f",
            "weight": 30,
            "currency_code": "USD",
            "amount": 6000,
            "cost_basis": null,
            "shares": 60
        },
        {
            "date": "2018-02-03",
            "security_id": "0d652520-7e6a-461d-abe8-56b956c08d2e",
            "weight": 30,
            "currency_code": "USD",
            "amount": 6000,
            "cost_basis": null,
            "shares": 70
        },
        {
            "date": "2018-02-03",
            "security_id": "c090f392-409d-459a-8054-333fe96fb877",
            "weight": 28,
            "currency_code": "USD",
            "amount": 5600,
            "cost_basis": null,
            "shares": 50
        }
    ],
  "total_pages": 1,
  "total_elements": 5,
  "last": true,
  "sort": [
    {
        "direction": "DESC",
        "property": "id",
        "ignore_case": false,
        "null_handling": "NATIVE",
        "descending": true,
        "ascending": false
    }
  ],
  "first": true,
  "number_of_elements": 5,
  "size": 25,
  "number": 5
}

Get the information for all the securities that are currently being held by a client registered with your tenant. Holding records are created at a portfolio level and aggregated to show the holdings of the client. The unique client_id must be provided. To obtain the appropriate client_id, use the GET /client endpoint to view all available client_ids registered with your tenant. The endpoint returns a list of security_ids, the security amount, the security weight and the date of the record for all securities the client holds.

HTTP REQUEST

GET /client/{client_id}/holding

ARGUMENTS

Parameter Type Required Description
start_date date optional Start date for the data. Defaults to the first date if not set
end_date date optional End date for the data. Defaults to the last date if not set
get_latest boolean optional Retrieve only the latest asset size. Defaults to false if not set
currency_conversion string optional Alphabetic currency code for the currency to convert all monetary values to. Value may be USD, GBP, EUR, AUD, CAD. Only available in enterprise plan.

RESPONSE

Field Type Description
date date Date for the security holding. Displays the latest record if more than one entry exists for the given date.
security_id UUID The id for the security included in the holding record
weight double The weight of the security as a percentage of the client’s total monetary value; ex. 20 representing 20%
currency_code string Alphabetic currency code for the amount. See currency codes
amount double Monetary value of the shares in the holding record
cost_basis double Monetary value that the security was originally purchased for, used for tax purposes
shares double Number of shares in the holding record

List all client transactions

Example Request

curl -X GET -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/client/099961da-7f41-4309-950f-2b51689a0033/transaction"
api_instance = nucleus_api.ClientApi(nucleus_api.ApiClient(configuration))
try:
    api_response = api_instance.get_client_transaction_all_using_get("1d987750-3cbd-4720-861c-6fc6ed3d6262")
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_client_transaction_using_get: %s\n" % e)
ClientApi apiInstance = new ClientApi();
        try {
            Object clienttransaction = apiInstance.getClientTransactionAllUsingGet(UUID.fromString("1d987750-3cbd-4720-861c-6fc6ed3d6262"), true, null, date2, null, 0, 10, date1);
            System.out.println(clienttransaction);
        } catch (ApiException e) {
            System.err.println("Exception when calling getClientTransactionAllUsingGet");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\ClientApi(
    new GuzzleHttp\Client(),
    $config);
$client_id = "489a13a9-aab1-42d9-a84f-1ab0d95c919c"; // string | UUID client_id
$ascending = false; // bool | ascending
$currency_conversion = null; // string | currency_conversion
$end_date = new \DateTime("2020-05-06"); // \DateTime | end_date
$order_by = null; // string | order_by
$page = 0; // int | page
$size = 10; // int | size
$start_date = new \DateTime("2020-08-06"); // \DateTime | start_date

try {
    $clienttransaction = $apiInstance->getClientTransactionAllUsingGet($client_id, $ascending, $currency_conversion, $end_date, $order_by, $page, $size, $start_date);
    print_r($clienttransaction);
} catch (Exception $e) {
    echo 'Exception when calling ClientApi->getClientTransactionAllUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::ClientApi.new
client_id = '1d987750-3cbd-4720-861c-6fc6ed3d6262' # String | UUID client_id

opts = {
    ascending: false, # BOOLEAN | ascending
    currency_conversion: null, # String | currency_conversion
    end_date: '2020-01-01', # String | end date - yyyy-mm-dd
    order_by: null, # String | order_by
    page: 0, # Integer | page
    size: 25, # Integer | size
    start_date: '2019-08-01' # String | start date - yyyy-mm-dd
}

begin
  transaction = api_instance.get_client_transaction_all_using_get(client_id, opts)
  p transaction
rescue NucleusApi::ApiError => e
  puts "Exception when calling ClientApi->get_client_transaction_all_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.ClientApi();
var clientId = "1d987750-3cbd-4720-861c-6fc6ed3d6262";

var opts = {
    'endDate': "2018-07-25",
    'startDate': "2020-09-10",
    'getLatest': true,
    'excludeSubledger': true,
    'ascending': false, // Boolean | ascending
    // 'filter': "", // String | filter
    //'orderBy': "update_date", // String | order_by
    'page': 0, // Number | page
    'size': 4 // Number | size

};
var clienttransactions = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.getClientTransactionAllUsingGet(clientId, opts, clienttransactions)

Example Response

{
  "content": [
    {
            "id": "efa289b2-3565-42e6-850b-8dad25727e99",
            "date": "2018-01-31T00:00:00.000+0000",
            "date_available": null,
            "is_recurring": false,
            "is_cleansed": false,
            "is_disputed": false,
            "is_read": true,
            "portfolio_id": "8ec467e6-6faa-4916-b380-6af0b21a34cc",
            "model_id": "6dbadddc-41ff-4634-a145-16678b422557",
            "price": 200,
            "quantity": 2,
            "currency_code": null,
            "amount": null,
            "balance": null,
            "merchant_id": null,
            "mid": null,
            "merchant": null,
            "merchant_category_code": null,
            "transaction_category_id": null,
            "category": null,
            "subcategory": null,
            "description": null,
            "memo": null,
            "status": null,
            "location": {},
            "check": {},
            "funding_id": null,
            "security_id": "691c2255-a1a6-451f-b772-cb262725d7e2",
            "transaction_code_id": "f5af397b-7d22-433f-b01e-8202184a6386",
            "create_date": "2018-02-07T19:29:37.000+0000",
            "update_date": "2018-02-012T09:00:00.000+0000"
    },
    {
            "id": "efa289b2-3565-42e6-850b-8dad25727e24",
            "date": "2018-01-31T00:00:00.000+0000",
            "date_available": null,
            "is_recurring": false,
            "is_cleansed": false,
            "is_disputed": false,
            "is_read": true,
            "portfolio_id": "8ec467e6-6faa-4916-b380-6af0b21a34cc",
            "model_id": "6dbadddc-41ff-4634-a145-16678b422557",
            "price": 1000,
            "quantity": 6,
            "currency_code": null,
            "amount": null,
            "balance": null,
            "merchant_id": null,
            "mid": null,
            "merchant": null,
            "merchant_category_code": null,
            "transaction_category_id": null,
            "category": null,
            "subcategory": null,
            "description": null,
            "memo": null,
            "status": null,
            "location": {},
            "check": {},
            "funding_id": null,
            "security_id": "0d652520-7e6a-461d-abe8-56b956c08d2e",
            "transaction_code_id": "f5af397b-7d22-433f-b01e-8202184a6386",
            "create_date": "2017-08-02T04:30:25.000+0000",
            "update_date": "2017-11-18T09:00:00.000+0000"
    }
  ],
    "total_pages": 1,
    "total_elements": 2,
    "last": true,
    "sort": [
        {
            "direction": "DESC",
            "property": "id",
            "ignore_case": false,
            "null_handling": "NATIVE",
            "descending": true,
            "ascending": false
        }
    ],
    "first": true,
    "number_of_elements": 2,
    "size": 25,
    "number": 2
}

Get the information for all transactions under a client registered with your tenant. Transaction records are created at a portfolio level and all transactions for each portfolio below the client’s account(s) are returned to show the client’s transaction activity. The unique client_id must be provided. To obtain the appropriate client_id, use the GET /client endpoint to view all available client_ids registered with your tenant. The endpoint returns a list of transaction_ids and details for each transaction.

HTTP REQUEST

GET /client/{client_id}/transaction

ARGUMENTS

Parameter Type Required Description
start_date date optional Start date for the data. Defaults to the first date if not set
end_date date optional End date for the data. Defaults to the last date if not set
currency_conversion string optional Alphabetic currency code for the currency to convert all monetary values to. Value may be USD, GBP, EUR, AUD, CAD. Only available in enterprise plan.

RESPONSE

Field Type Description
id UUID The id for the transaction record
date timestamp Timestamp when the transaction occurred
date_available timestamp Timestamp when the transaction becomes available
is_cleansed boolean Indicates if the transaction has been cleansed by a data cleansing engine. Defaults to false which indicates that it has not been cleansed
is_read boolean Indicates if the transaction has been read. Defaults to false which indicates that it has not been read
is_recurring boolean Indicates if the transaction is recurring such as a subscription. Defaults to false which indicates that it is not recurring
is_disputed boolean Indicates if the transaction is disputed by the client. Defaults to false which indicates that it is not disputed
portfolio_id UUID The id of the portfolio that the transaction record relates to
funding_id UUID The id of the funding request that the transaction record relates to
model_id UUID The id of the model to which the portfolio that the transaction falls under subscribes
price integer Price for the security included in the transaction at which it was sold or purchased
quantity integer Quantity of shares of the security purchased
currency_code string Alphabetic currency code for the amount. See currency codes
amount double Amount of the transaction
balance double Updated balance of the portfolio as a result of the transaction
merchant_id UUID ID of the merchant resource for the transaction
mid string Acquirer ID of the merchant (MID) for the transaction
merchant string The merchant for the transaction such as the merchant posted for a credit or debit card charge
merchant_category_code string The MCC Code for the merchant as identified by the card network
transaction_category_id string ID of the category resource for the transaction
category string Category of the transaction
subcategory string Subcategory of the transaction
description string Description of the transaction
memo string Memo attached to the transaction
status string Status of the transaction
location map Location where the transaction occurred
      address_line1 string Primary information for the street address, such as the street and building number
      address_line2 string Secondary information for the street address, such as a suite or apartment number
      city string City for the address
      state string State, province, or sub-country region for the address
      postalcode string Alphanumeric postal code or zip code for the address
      country string Country for the address using the ISO ALPHA-2 Code. See country codes
      latitude double Latitude of the location where the transaction occurred
      longitude double Longitude of the location where the transaction occurred
check map Check associated with the banking transaction
      check_number string Number on the check such as “1234”
      check_amount double Monetary amount of the check
      check_images map Image(s) of the scanned check(s)
            image_url string URL where the image can be displayed
            image_type string Type of image for the check such as “png” or “jpeg”
security_id UUID The id of the security included in the transaction
transaction_code_id integer The id referring to the transaction codes defined by your firm
secondary_id string Alternate id that can be used to identify the object such as an internal id
create_date timestamp Timestamp for the date and time that the record was created
update_date timestamp Timestamp for the date and time that the record was last updated

Get aggregate client data

Example Request

curl -X GET -H "Authorization: Bearer <access_token>" \
  "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/client/0797efda-cf8b-4661-9cb4-d1e8966a3dcd/account_overview"
api_instance = nucleus_api.ClientApi(nucleus_api.ApiClient(configuration))
try:
    api_response = api_instance.get_client_account_overview_using_get("1d987750-3cbd-4720-861c-6fc6ed3d6262")
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_client_account_overview_using_get: %s\n" % e)
ClientApi apiInstance = new ClientApi();
        try {
            Object accountoverview = apiInstance.getClientAccountOverviewUsingGet(UUID.fromString("489a13a9-aab1-42d9-a84f-1ab0d95c919c"), true, null);
            System.out.println(accountoverview);
        } catch (ApiException e) {
            System.err.println("Exception when calling getClientAccountOverviewUsingGet");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\ClientApi(
    new GuzzleHttp\Client(),
    $config);
$client_id = "489a13a9-aab1-42d9-a84f-1ab0d95c919c"; // string | UUID client_id
$ascending = false; // bool | ascending
$order_by = null; // string | order_by

try {
    $clientaccountoverview = $apiInstance->getClientAccountOverviewUsingGet($client_id, $ascending, $order_by);
    print_r($clientaccountoverview);
} catch (Exception $e) {
    echo 'Exception when calling ClientApi->getClientAccountOverviewUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::ClientApi.new
client_id = '489a13a9-aab1-42d9-a84f-1ab0d95c919c' # String | UUID client_id

opts = {
    ascending: false, # BOOLEAN | ascending
    order_by: null, # String | order_by
}

begin
  overview = api_instance.get_client_account_overview_using_get(client_id, opts)
  p overview
rescue NucleusApi::ApiError => e
  puts "Exception when calling ClientApi->get_client_account_overview_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.ClientApi();
var clientaccountId = "489a13a9-aab1-42d9-a84f-1ab0d95c919c"; // String | UUID client_id
var opts = {
    'ascending': false, // Boolean | ascending
    'orderBy': null, // String | order_by
};
var accountoverview = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' + data);
    }
};
apiInstance.getClientAccountOverviewUsingGet(clientaccountId, opts, accountoverview)

Example Response

{
  "client_id": "0797efda-cf8b-4661-9cb4-d1e8966a3dcd",
  "client_first_name": "Oscar",
  "client_last_name": "Martinez",
  "client_asset_size_date": "2019-09-13",
  "client_asset_size": 362242.82649700006,
  "accounts": [
    {
      "account_id": "4d7efcea-2f85-4442-8268-c0c1e82ca618",
      "account_name": "Investment",
      "account_type": "Investment",
      "account_secondary_id": "Test Data",
      "account_asset_size": 38725.07924,
      "account_asset_size_date": "2019-09-13",
      "account_created_date": "2019-09-26T22:31:16.000+0000",
      "account_updated_date": "2019-09-26T22:31:16.000+0000"
    },
    {
      "account_id": "6f4a3f64-5bba-4bbf-8fe6-6815db272dc8",
      "account_name": "Saving Account",
      "account_type": "Saving",
      "account_secondary_id": "Test Data",
      "account_asset_size": 37117.77597,
      "account_asset_size_date": "2019-09-13",
      "account_created_date": "2019-09-26T22:31:17.000+0000",
      "account_updated_date": "2019-09-26T22:31:17.000+0000"
    },
    {
      "account_id": "7ed09992-89ad-4a27-9bc2-a313cf28d234",
      "account_name": "Investment",
      "account_type": "Investment",
      "account_secondary_id": "Test Data",
      "account_asset_size": 51989.83748,
      "account_asset_size_date": "2019-09-13",
      "account_created_date": "2019-09-26T22:31:15.000+0000",
      "account_updated_date": "2019-09-26T22:31:15.000+0000"
    }
  ],
  "deposits": [
    {
      "deposit_id": "3eb0c7a7-63a5-4f6f-a3c9-52f470fcf636",
      "deposit_amount": 9000.0,
      "deposit_account_id": "f450e1f9-ee02-44a2-b947-d7bcb4ee07f1",
      "deposit_account_name": "Investment",
      "deposit_received_date": "2019-01-25T00:00:00.000+0000",
      "deposit_direction": "Inbound"
    },
    {
      "deposit_id": "52b28035-deed-4dba-99ba-503bd1f0c1c9",
      "deposit_amount": 5000.0,
      "deposit_account_id": "f450e1f9-ee02-44a2-b947-d7bcb4ee07f1",
      "deposit_account_name": "Investment",
      "deposit_received_date": "2017-08-30T00:00:00.000+0000",
      "deposit_direction": "Inbound"
    },
    {
      "deposit_id": "89dde3ae-4aa1-4088-880b-f7f1e63a8bc9",
      "deposit_amount": 1000.0,
      "deposit_account_id": "f450e1f9-ee02-44a2-b947-d7bcb4ee07f1",
      "deposit_account_name": "Investment",
      "deposit_received_date": "2019-08-27T00:00:00.000+0000",
      "deposit_direction": "Inbound"
    }
  ],
  "withdrawals": [
    {
        "withdrawal_id": "64b79ec3-cd92-4dc9-92b6-c2bb0c59f8fe",
        "withdrawal_amount": 1000.0,
        "withdrawal_account_id": "4d7efcea-2f85-4442-8268-c0c1e82ca618",
        "withdrawal_account_name": "Investment",
        "withdrawal_date": "2019-08-30",
        "withdrawal_direction": "Outgoing"
    },
    {
        "withdrawal_id": "fb00abc4-f3fe-494a-a830-3a373ce2b8ab",
        "withdrawal_amount": 1000.0,
        "withdrawal_account_id": "f450e1f9-ee02-44a2-b947-d7bcb4ee07f1",
        "withdrawal_account_name": "Investment",
        "withdrawal_date": "2019-09-05",
        "withdrawal_direction": "Outgoing"
    },
    {
        "withdrawal_id": "3c0d9edc-df6e-40ab-9107-e631c51d56de",
        "withdrawal_amount": 500.0,
        "withdrawal_account_id": "7ed09992-89ad-4a27-9bc2-a313cf28d234",
        "withdrawal_account_name": "Investment",
        "withdrawal_date": "2017-04-26",
        "withdrawal_direction": "Outgoing"
    }
  ]
}

Display the latest client and account data along with recent deposit and withdrawal activity. This view is useful when constructing client dashboards.

HTTP REQUEST

GET /client/{client_id}/account_overview

RESPONSE

Field Type Description
client_id UUID The id of the client
client_first_name string First name of the client
client_last_name string Last name of the client
client_asset_size double Total asset size of client across all accounts
client_asset_size_date date Date of the latest client_asset_size for the given client_id
accounts array List of client’s accounts
      account_id UUID The id of the account
      account_name string Name of the account
      account_type string The type of account
      account_secondary_id string The secondary_id for the account
      account_asset_size double Account asset size that has the same date as client_asset_size
      account_asset_size_date date Date of the asset_size record. Must be the same as the client_asset_size_date
      account_created_date timestamp Timestamp for the date and time the account was created
      account_update_date timestamp Timestamp for the date and time the account was last updated
deposits array Array of deposits for the client. Returns only the latest 3 records
      deposit_id UUID ID of the deposit record
      deposit_amount double Amount of the deposit
      deposit_account_id date Account ID to which the deposit was made
      deposit_account_name string Account name to which the deposit was made
      deposit_received_date timestamp Date and time that the deposit was received into the account
      deposit_direction string Label to indicate the direction of the transaction such as “Incoming” or “Outgoing”
withdrawals array Array of withdrawals made from the client’s accounts. Returns only the latest 3 records
      withdrawal_id UUID ID of the withdrawal record
      withdrawal_amount double Amount that was withdrawn
      withdrawal_account_id UUID account_id that the withdrawal was made from
      withdrawal_account_name string Account name that the withdrawal was made from
      withdrawal_date date Date the withdrawal was made
      withdrawal_direction string Label to indicate the direction of the transaction such as “Incoming” or “Outgoing”

Get aggregate advisor data

Example Request

curl -X GET -H "Authorization: Bearer <access_token>" \
  "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/client/5297nrga-cf8b-4143-9nf4-d1ekn66r5cgd/advisor_overview"
api_instance = nucleus_api.ClientApi(nucleus_api.ApiClient(configuration))
try:
    api_response = api_instance.get_client_advisor_overview_using_get("1d987750-3cbd-4720-861c-6fc6ed3d6262")
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_client_advisor_overview_using_get: %s\n" % e)
ClientApi apiInstance = new ClientApi();
        try {
            Object advisoroverview = apiInstance.getClientAdvisorOverviewUsingGet(UUID.fromString("489a13a9-aab1-42d9-a84f-1ab0d95c919c"), true);
            System.out.println(advisoroverview);
        } catch (ApiException e) {
            System.err.println("Exception when calling getClientAdvisorOverviewUsingGet");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\ClientApi(
    new GuzzleHttp\Client(),
    $config);
$client_id = "489a13a9-aab1-42d9-a84f-1ab0d95c919c"; // string | UUID client_id
$show_clients = false; // bool | show_clients

try {
    $clientadvisoroverview = $apiInstance->getClientAdvisorOverviewUsingGet($client_id, $show_clients);
    print_r($clientadvisoroverview);
} catch (Exception $e) {
    echo 'Exception when calling ClientApi->getClientAdvisorOverviewUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::ClientApi.new
client_id = '489a13a9-aab1-42d9-a84f-1ab0d95c919c' # String | UUID client_id

opts = {
    show_clients: false # BOOLEAN | show_clients
}

begin
  advisoroverview = api_instance.get_client_advisor_overview_using_get(client_id, opts)
  p advisoroverview
rescue NucleusApi::ApiError => e
  puts "Exception when calling ClientApi->get_client_advisor_overview_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.ClientApi();
var clientaccountId = "489a13a9-aab1-42d9-a84f-1ab0d95c919c"; // String | UUID client_id
var opts = {
    'ascending': false, // Boolean | ascending
    'orderBy': null, // String | order_by
};
var advisoroverview = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' + data);
    }
};
apiInstance.getClientAdvisorOverviewUsingGet(clientaccountId, opts, advisoroverview)

Example Response

{
  "total_assets_managed": 5000000,
  "total_accounts_managed": 8,
  "total_clients_managed": 4,
  "account_list": [
    {
      "account_type": "retirement",
      "assets_managed": 200000,
      "accounts_managed": 8,
      "clients_managed": 4
    },
    {
      "account_type": "savings",
      "assets_managed": 200000,
      "accounts_managed": 7,
      "clients_managed": 3
    },
    {
      "account_type": "investment",
      "assets_managed": 200000,
      "accounts_managed": 1,
      "clients_managed": 1
    }
  ],
  "client_list": [
    {
      "client_id": "818f182e-1922-40d0-8b70-d68865c8fe4d",
      "first_name": "Jane",
      "last_name": "Doe",
      "date_of_birth": "1971-07-10",
      "age": 48,
      "gender": "female",
      "income": 50000,
      "client_assets": {
        "total_assets": 250000,
        "as_of_date": "2019-07-01"
      },
      "client_account_list": [
        {
          "account_name": "account 1",
          "account_type": "retirement",
          "account_assets": 5024.57,
          "as_of_date": "2019-07-01"
        },
        {
          "account_name": "account 2",
          "account_type": "savings",
          "account_assets": 259275.41,
          "as_of_date": "2019-07-01"
        }
      ]
    },
    {
      "client_id": "23bb0389-aa37-4be5-9dc5-07f21a8f4d32",
      "first_name": "Adam",
      "last_name": "Smith",
      "date_of_birth": "1983-05-02",
      "age": 36,
      "gender": "male",
      "income": 150000,
      "client_assets": {
        "total_assets": 250000,
        "as_of_date": "2019-07-01"
      },
      "client_account_list": [
        {
          "account_name": "account 1",
          "account_type": "retirement",
          "account_assets": 5024.57,
          "as_of_date": "2019-07-01"
        },
        {
          "account_name": "account 2",
          "account_type": "savings",
          "account_assets": 259275.41,
          "as_of_date": "2019-07-01"
        }
      ]
    },
    {
      "client_id": "dd707c48-599c-4edd-8055-04682e583483",
      "first_name": "Kyle",
      "last_name": "Davis",
      "date_of_birth": "1988-05-02",
      "age": 31,
      "gender": "male",
      "income": 230000,
      "client_assets": {
        "total_assets": 250000,
        "as_of_date": "2019-07-01"
      },
      "client_account_list": [
        {
          "account_name": "account 1",
          "account_type": "retirement",
          "account_assets": 5024.57,
          "as_of_date": "2019-07-01"
        },
        {
          "account_name": "account 2",
          "account_type": "investment",
          "account_assets": 259275.41,
          "as_of_date": "2019-07-01"
        }
      ]
    },
    {
      "client_id": "b5f3abe9-bea2-4b31-9416-1080041efac2",
      "first_name": "Jason",
      "last_name": "Williams",
      "date_of_birth": "1980-05-02",
      "age": 39,
      "gender": "male",
      "income": 85000,
      "client_assets": {
        "total_assets": 250000,
        "as_of_date": "2019-07-01"
      },
      "client_account_list": [
        {
          "account_name": "account 1",
          "account_type": "retirement",
          "account_assets": 5024.57,
          "as_of_date": "2019-07-01"
        },
        {
          "account_name": "account 2",
          "account_type": "savings",
          "account_assets": 259275.41,
          "as_of_date": "2019-07-01"
        }
      ]
    }
  ]
}

Displays high-level view of all clients & accounts under the management of the advisor. This view is useful when constructing advisor dashboards.

HTTP REQUEST

GET /client/{client_id}/advisor_overview

RESPONSE

Field Type Description
total_assets_managed double The monetary value of total assets managed by the advisor
total_clients_managed integer Total number of clients managed by the advisor
total_accounts_managed integer Total number of accounts managed by the advisor
account_list array List of all the accounts managed by the advisor
      account_type string The type of account
      assets_managed double The monetary value of the assets under the account type
      clients_managed integer Total number of clients managed under the account type
      accounts_managed integer Total number of accounts managed under the account type
client_list array List of all clients managed by the advisor
      client_id UUID The ID of the client
      first_name string First name of the client
      last_name string Last name of the client
      date_of_birth date Date of birth of the client in the ISO 8601 format YYYY-MM-DD
      age integer Age of the client
      gender string The client’s gender. Available values are female, male, and other
      income double The total income for the client
      client_assets map List of client’s assets
          total_assets double The monetary value of the total assets for the client
          as_of_date date The effective date of the total_assets value
      client_account_list array(map) List of all the accounts for the client
          account_name string The name of the client’s account
          account_type string The type of account
          account_assets double The monetary value of the total assets for the account
          as_of_date date The effective date of the account_assets value

Client Response

When using questionnaires, clients’ answers to the questions are stored as client responses. For example, to customize a firm-defined goal for a client, he or she must provide some information such as his or her time horizon or goal amount. Another example is when profiling a client’s risk tolerance, a specific questionnaire might be used, where the client’s responses help determine the risk profile. Client responses are stored as answer values connected to the question in the questionnaire via an answer_id that represents an answer option to the question. Responses can be stored at a client level or an account level. The answers are often used as variables for calculations relating to a goal such as age, time horizon, risk tolerance, etc.

Field Type Description
id UUID The id of the client response
answer_id UUID The id of the answer provided to link the response to a question
answer_value string Body of the client’s response
client_id UUID The id of the client to whom the response belongs
account_id UUID In the case that the response applies to only one of a client’s accounts and not the client as a whole, the id of the account to which the response belongs
application_id string Create an identifier to group client responses within a unique application session
metadata map Custom information associated with the entity in the format key:value
See Metadata
secondary_id string Alternate id that can be used to identify the object such as an internal id
create_date timestamp Timestamp for the date and time that the record was created
update_date timestamp Timestamp for the date and time that the record was last updated

List all client responses

Example Request

curl -X GET -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/client_response"
api_instance = nucleus_api.QuestionnaireApi(nucleus_api.ApiClient(configuration))
try:
    api_response = api_instance.get_client_response_all_using_get()
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_client_response_all_using_get: %s\n" % e)
QuestionnaireApi apiInstance = new QuestionnaireApi();
        try {
            PageClientResponse List = apiInstance.getClientResponseAllUsingGet(true, null, null, 0, 10);
            System.out.println(List);
        } catch (ApiException e) {
            System.err.println("Exception when calling getClientResponseAllUsingGet");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\QuestionnaireApi(
    new GuzzleHttp\Client(),
    $config);
$ascending = false; // bool | ascending
$filter = null; // string | filter
$order_by = null; // string | order_by
$page = 0; // int | page
$size = 10; // int | size

try {
    $clientresponselist = $apiInstance->getClientResponseAllUsingGet($ascending, $filter, $order_by, $page, $size);
    print_r($clientresponselist);
} catch (Exception $e) {
    echo 'Exception when calling QuestionnaireApi->getClientResponseAllUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::QuestionnaireApi.new
opts = {
    ascending: false, # BOOLEAN | ascending
    filter: null, # String | filter
    order_by: null, # String | order_by
    page: 0, # Integer | page
    size: 25 # Integer | size
}

begin
  clientresponselist = api_instance.get_client_response_all_using_get(opts)
  p clientresponselist
rescue NucleusApi::ApiError => e
  puts "Exception when calling QuestionnaireApi->get_client_response_all_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.QuestionnaireApi();
var opts = {
    'ascending': false, // Boolean | ascending
    // 'filter': "", // String | filter
    'orderBy': "update_date", // String | order_by
    'page': 0, // Number | page
    'size': 25 // Number | size
};

var responselist = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.getClientResponseAllUsingGet(opts, responselist)

Example Response

{
  "content": [
    {
      "id": "7960419c-c098-4450-8cc5-866b7385230b",
      "create_date": "2018-02-07T19:29:37.000+0000",
      "update_date": "2018-02-12T09:00:00.000+0000",
      "client_id" : "5736e6f7-5e12-448e-830c-c1f2b9317d48",
      "account_id" : "efa289b2-3565-42e6-850b-8dad25727e99",
      "answer_id" : "cf9de92f-1c59-4188-93af-d7d5cefd0644",
      "answer_value" : "10 Years",
      "application_id": "681928573639178",
      "metadata": {}
    }
  ],
  "total_elements": 1,
  "last": true,
  "total_pages": 1,
  "sort": [
    {
      "direction": "ASC",
      "property": "id",
      "ignore_case": false,
      "null_handling": "NATIVE",
      "ascending": true,
      "descending": false
    }
  ],
  "number_of_elements": 1,
  "first": true,
  "size": 25,
  "number": 0
}

Get all the client responses for questions as part of a questionnaire defined by your firm. The option to provide a unique client_id or account_id is available to filter responses from a specific client, or responses from a specific account. To obtain the appropriate client_id, use the GET /client endpoint to view all clients defined for your tenant. To obtain the appropriate account_id, use the GET /account endpoint to view all accounts defined for your tenant.

HTTP REQUEST

GET /client_response

Create a client response

Example Request

curl -X POST -H "Authorization: Bearer <access_token>" \
    -H "Content-Type: application/json" \
    -d '{
          "client_id" : "5736e6f7-5e12-448e-830c-c1f2b9317d48",
          "account_id" : "efa289b2-3565-42e6-850b-8dad25727e99",
          "answer_id" : "cf9de92f-1c59-4188-93af-d7d5cefd0644",
          "answer_value" : "10 Years",
          "application_id": "681928573639178"
        }' "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/client_response"
api_instance = nucleus_api.ClientApi(nucleus_api.ApiClient(configuration))
# # Create a ClientResponse
client_response = nucleus_api.ClientResponse(answer_id="63eef07e-3288-4cfd-bd19-e2c91ffd938d", answer_value="One Star", account_id="a28aa11c-c492-4dc6-a634-74af6699a88c")
try:
    api_response = api_instance.create_client_response_using_post(client_response)
    pprint(api_response)
except ApiException as e:
    print("create_client_response_using_post: %s\n" % e)
ClientApi apiInstance = new ClientApi();
        //Create a Client Response
        ClientResponse response = new ClientResponse();
        response.setAnswerId(UUID.fromString("63eef07e-3288-4cfd-bd19-e2c91ffd938d"));
        response.setAnswerValue("One A");
        response.setAccountId(UUID.fromString("a28aa11c-c492-4dc6-a634-74af6699a88c"));

                try {
            ClientResponse result = apiInstance.createClientResponseUsingPost(response);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling createClientResponseUsingPost");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\ClientApi(
    new GuzzleHttp\Client(),
    $config);
$ascending = false; // bool | ascending
//Create Client Response
$client_response = new \com\hydrogen\nucleus\Model\ClientResponse();

try {
    $client_response->setAccountId("a28aa11c-c492-4dc6-a634-74af6699a88c");
    $client_response->setAnswerId("63eef07e-3288-4cfd-bd19-e2c91ffd938d");
    $client_response->setAnswerValue("New");
    $result = $apiInstance->createClientResponseUsingPost($client_response);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->createClientResponseUsingPost: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::ClientApi.new

#Create ClientResponse
clientresponse = NucleusApi::ClientResponse.new

begin
  clientresponse.answer_id = "63eef07e-3288-4cfd-bd19-e2c91ffd938d"
  clientresponse.account_id = "a28aa11c-c492-4dc6-a634-74af6699a88c"
  clientresponse.answer_value = "New"
  result = api_instance.create_client_response_using_post(clientresponse)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->create_client_response_using_post: #{e}"
end
var apiInstance = new HydrogenNucleusApi.ClientApi();
//Create ClientResponse
var clientresponse = new HydrogenNucleusApi.Client();
clientresponse.answer_id = '63eef07e-3288-4cfd-bd19-e2c91ffd938d';
clientresponse.account_id = 'a28aa11c-c492-4dc6-a634-74af6699a88c';
clientresponse.answer_value = "New";



var newcllientresponse = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.createClientResponseUsingPost(clientresponse, newcllientresponse)

Example Response

{
    "id": "7960419c-c098-4450-8cc5-866b7385230b",
    "create_date": "2018-02-07T19:29:37.000+0000",
    "client_id" : "5736e6f7-5e12-448e-830c-c1f2b9317d48",
    "account_id" : "efa289b2-3565-42e6-850b-8dad25727e99",
    "answer_id" : "cf9de92f-1c59-4188-93af-d7d5cefd0644",
    "answer_value" : "10 Years",
    "application_id": "681928573639178",
    "metadata": {}
}

Create a new client response for a question as part of a questionnaires. Must provide the answer_id, answer_value and either the client_id, account_id, or both. To obtain the appropriate answer_id, use the GET /questionnaire endpoint to view the question_id and answer_id pairs. The create_date will default to the current date. The endpoint returns a client_response_id used to manage the client’s response to the question.

HTTP REQUEST

POST /client_response

ARGUMENTS

Parameter Type Required Description
answer_id UUID required The id of the answer provided to link the response to a question
answer_value string required Body of the client’s response
client_id UUID required, conditional The id of the client to whom the response belongs. Required if an account_id is not also provided.
account_id UUID required, conditional In the case that the response applies to only one of a client’s accounts and not the client as a whole, the id of the account to which the response belongs. Required if a client_id is not also provided.
application_id string optional Create an identifier to group client responses within a unique application session
metadata map optional Custom information associated with the entity in the format key:value
See Metadata
secondary_id string optional Alternate id that can be used to identify the object such as an internal id

Retrieve a client response

Example Request

curl -X GET -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/client_response/7960419c-c098-4450-8cc5-866b7385230b"
api_instance = nucleus_api.QuestionnaireApi(nucleus_api.ApiClient(configuration))
try:
    api_response = api_instance.get_client_response_using_get("4356ba14-8e30-4aa2-ae82-48f0d2cc9573")
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_client_response_using_get: %s\n" % e)
QuestionnaireApi apiInstance = new QuestionnaireApi();
        try {
            ClientResponse response = apiInstance.getClientResponseUsingGet(UUID.fromString("ad325370-a690-4d4a-98fc-fb548214cc5e"));
            System.out.println(response);
        } catch (ApiException e) {
            System.err.println("Exception when calling getClientResponseUsingGet");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\QuestionnaireApi(
    new GuzzleHttp\Client(),
    $config);
$client_response_id = "ad325370-a690-4d4a-98fc-fb548214cc5e"; // string | UUID client_response_id

try {
    $clientresponse = $apiInstance->getClientResponseUsingGet($client_response_id);
    print_r($clientresponse);
} catch (Exception $e) {
    echo 'Exception when calling QuestionnaireApi->getClientResponseUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::QuestionnaireApi.new
client_response_id = 'ad325370-a690-4d4a-98fc-fb548214cc5e' # String | UUID client_response_id


begin
  clientresponse = api_instance.get_client_response_using_get(client_response_id)
  p clientresponse
rescue NucleusApi::ApiError => e
  puts "Exception when calling QuestionnaireApi->get_client_response_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.QuestionnaireApi();
var responseID = "ad325370-a690-4d4a-98fc-fb548214cc5e";


var response = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.getClientResponseUsingGet(responseID, response)

Example Response

{
    "id": "7960419c-c098-4450-8cc5-866b7385230b",
    "create_date": "2018-02-07T19:29:37.000+0000",
    "update_date": "2018-02-12T09:00:00.000+0000",
    "client_id" : "5736e6f7-5e12-448e-830c-c1f2b9317d48",
    "account_id" : "efa289b2-3565-42e6-850b-8dad25727e99",
    "answer_id" : "cf9de92f-1c59-4188-93af-d7d5cefd0644",
    "answer_value" : "10 Years",
    "application_id": "681928573639178",
    "metadata": {}
}

Retrieve the information for a client response for a client. The client_response_id must be provided. To obtain the appropriate client_response_id, use the GET /client_response endpoint to view all client responses firm-wide. The endpoint returns the client_response_id and details for the client response.

HTTP REQUEST

GET /client_response/{client_response_id}

Update a client response

Example Request

curl -X PUT -H "Authorization: Bearer <access_token>" \
    -H "Content-Type: application/json" \
    -d '{
            "client_id" : "5736e6f7-5e12-448e-830c-c1f2b9317d48",
            "account_id" : "efa289b2-3565-42e6-850b-8dad25727e99",
            "answer_id" : "cf9de92f-1c59-4188-93af-d7d5cefd0644",
            "answer_value" : "10 Years"
    }' "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/client_response/7960419c-c098-4450-8cc5-866b7385230b"
api_instance = nucleus_api.ClientApi(nucleus_api.ApiClient(configuration))
# # #Update ClientResponse
client_response_update = {'answer_value': 'Two'}
response_id = 'a5f538f72-9256-4c24-a45d-e6aa93c764b2'
try:
    api_response = api_instance.update_client_response_using_put(client_response_update, response_id)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling update_client_response_using_put: %s\n" % e)
ClientApi apiInstance = new ClientApi();
        ////Update ClientResponse
        Map map2 = new HashMap();
        map.put("answer_value", "Two");

        try {
            ClientResponse responsec = apiInstance.updateClientResponseUsingPut(map2, UUID.fromString("9a9c9966-3669-45c1-ae9e-09c54721506a"));
            System.out.println(responsec);
        } catch (ApiException e) {
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\ClientApi(
    new GuzzleHttp\Client(),
    $config);
$ascending = false; // bool | ascending
//Update Client Response
$client_response_update = new stdClass();
$client_response_id = "ed7b5fbb-ce3b-4bec-a9de-c11642ac38c4";

try {
    $client_response_update->answer_value = "one";
    $result = $apiInstance->updateClientResponseUsingPut($client_response_update, $client_response_id);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->updateClientResponseUsingPut: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::ClientApi.new

#Update ClientResponse
client_response_update = {"answer_value" => 'visa'}
client_response_id = '5f538f72-9256-4c24-a45d-e6aa93c764b2'
begin
  result = api_instance.update_client_response_using_put(client_response_update, client_response_id)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->update_client_response_using_put: #{e}"
end
var apiInstance = new HydrogenNucleusApi.ClientApi();
// //Update Client
var apiInstance = new HydrogenNucleusApi.ClientApi();
var callback = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
var clientresponseupdate = new HydrogenNucleusApi.Client();
var clientresponseid = "fd818fa0-0c78-4fe7-9e5d-16444e51db07";

clientresponseupdate.answer_value = "new";
apiInstance.updateClientResponseUsingPut(clientresponseupdate, clientresponseid, callback)

Example Response

{
    "id": "7960419c-c098-4450-8cc5-866b7385230b",
    "create_date": "2018-02-07T19:29:37.000+0000",
    "update_date": "2018-02-12T09:00:00.000+0000",
    "client_id": "5736e6f7-5e12-448e-830c-c1f2b9317d48",
    "account_id": "efa289b2-3565-42e6-850b-8dad25727e99",
    "answer_id": "cf9de92f-1c59-4188-93af-d7d5cefd0644",
    "answer_value": "10 Years",
    "application_id": "681928573639178",
    "metadata": {}
}

Update a client response for a client. The client_response_id must be provided. To obtain the appropriate client_response_id, use the GET /client_response endpoint to view all client responses firm-wide and their current information. The details to be updated must also be provided. The endpoint returns the client_response_id and all the details for the client response.

HTTP REQUEST

PUT /client_response/{client_response_id}

Delete a client response

Example Request

curl -X DELETE -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/client_response/7960419c-c098-4450-8cc5-866b7385230b0"
api_instance = nucleus_api.ClientApi(nucleus_api.ApiClient(configuration))
# # Delete a ClientResponse
cresponse_id = '9e739357-5633-4e87-b2f9-6202526f9981'
try:
    api_instance.delete_client_response_using_delete(cresponse_id)
except ApiException as e:
    print("Exception when delete_client_response_using_delete: %s\n" % e)
ClientApi apiInstance = new ClientApi();

        //        // Delete ClientResponse
        try {
            ClientResponse deleteresponse = apiInstance.deleteClientResponseUsingDelete(UUID.fromString("2b6d5e03-25d2-4a95-9117-50b738590e04"));
            System.out.println(deleteresponse);
        } catch (ApiException e) {
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\ClientApi(
    new GuzzleHttp\Client(),
    $config);
$ascending = false; // bool | ascending
//Delete Client Response
$client_response_did = "5f538f72-9256-4c24-a45d-e6aa93c764b2"; // string | UUID account_id

try {
    $apiInstance->deleteClientResponseUsingDelete($client_response_did);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->deleteClientResponseUsingDelete: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::ClientApi.new

#Delete ClientResponse
client_response1_id = '2b6d5e03-25d2-4a95-9117-50b738590e04'
begin
  result = api_instance.delete_client_response_using_delete(client_response1_id)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->delete_client_response_using_delete: #{e}"
end
var apiInstance = new HydrogenNucleusApi.ClientApi();
// // //Delete a Client
var clientresponsedid = "5f538f72-9256-4c24-a45d-e6aa93c764b2";


var deleteclientresponse = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully.');
    }
};
apiInstance.deleteClientResponseUsingDelete(clientresponsedid, deleteclientresponse)

Response (204 No Content)

Permanently delete a client response for a client. The client_response_id must be provided. To obtain the appropriate client_response_id, use the GET /client_response endpoint to view all client responses firm-wide. This deletes the client_response_id and the client response record.

HTTP REQUEST

DELETE /client_response/{client_response_id}

Client Status

Client statuses correspond to a stage_id and reflects the different stages that a client flows through along a user journey, useful for sign-up funnels. See the Stage section for stage_id.

Field Type Description
id UUID The id for the specific client status record for the client_id provided
client_id UUID The id of the client to which the status belongs
status string Status of the client such as “Signed Up” or “KYC Submitted”
stage_id UUID Refers to the stage the client is in.
Useful for sign-up funnels where an account is not being created.
comments string Comments for the client regarding their status
metadata map Custom information associated with the entity in the format key:value
See Metadata
secondary_id string Alternate id that can be used to identify the object such as an internal id
create_date timestamp Timestamp for the date and time that the record was created
update_date timestamp Timestamp for the date and time that the record was last updated

List all client statuses

Example Request

curl -X GET -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/client_status"
api_instance = nucleus_api.ClientApi(nucleus_api.ApiClient(configuration))
try:
    api_response = api_instance.get_client_status_all_using_get()
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_client_status_all_using_get: %s\n" % e)
ClientApi apiInstance = new ClientApi();
        try {
            PageClientStatus List = apiInstance.getClientStatusAllUsingGet(true, null, null, 0, 10);
            System.out.println(List);
        } catch (ApiException e) {
            System.err.println("Exception when calling getClientStatusAllUsingGet");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\ClientApi(
    new GuzzleHttp\Client(),
    $config);
$ascending = false; // bool | ascending
$filter = null; // string | filter
$order_by = null; // string | order_by
$page = 0; // int | page
$size = 10; // int | size

try {
    $statuslist = $apiInstance->getClientStatusAllUsingGet($ascending, $filter, $order_by, $page, $size);
    print_r($statuslist);
} catch (Exception $e) {
    echo 'Exception when calling ClientApi->getClientStatusAllUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::ClientApi.new
opts = {
    ascending: false, # BOOLEAN | ascending
    filter: null, # String | filter
    order_by: null, # String | order_by
    page: 0, # Integer | page
    size: 25 # Integer | size
}
begin
  statuslist = api_instance.get_client_status_all_using_get(opts)
  p statuslist
rescue NucleusApi::ApiError => e
  puts "Exception when calling ClientApi->get_client_status_all_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.ClientApi();
var opts = {
    'ascending': false, // Boolean | ascending
    // 'filter': "", // String | filter
    'orderBy': "update_date", // String | order_by
    'page': 0, // Number | page
    'size': 25 // Number | size
};

var clientstatuslist = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.getClientStatusAllUsingGet(opts, clientstatuslist)

Example Response

{
    "content": [
      {
            "id": "6db4a470-a00c-40bb-a325-067d0bdb3ddc",
            "create_date": "2019-02-08T16:59:27.000+0000",
            "update_date": "2019-02-08T16:59:27.000+0000",
            "comments": "Upload your passport",
            "status": "KYC Pending",
            "stage_id": "e995d4c1-f989-4733-9867-713966ac9856",
            "client_id": "1d7e1aad-3c79-49fe-bbb9-bd5e239ae1e7",
            "metadata": {}
      },
      {
            "id": "013380bf-7f17-44c1-93c5-892a7ed3498c",
            "create_date": "2019-04-07T00:00:00.000+0000",
            "update_date": "2019-05-08T16:59:27.000+0000",
            "comments": null,
            "status": "KYC Complete",
            "stage_id": "1d7e1aad-3c79-49fe-bbb9-bd5e239ae1e7",
            "client_id": "21098ed9-6439-46ba-abd9-eb6cf28866fb",
            "metadata": {}
      }
    ],
    "last": false,
    "total_pages": 1,
    "total_elements": 2,
    "sort": [
        {
            "direction": "DESC",
            "property": "updateDate",
            "ignore_case": false,
            "null_handling": "NATIVE",
            "descending": true,
            "ascending": false
        }
    ],
    "first": true,
    "number_of_elements": 2,
    "size": 25,
    "number": 0
}

Get the client status history information for all clients defined for your tenant. Client status corresponds to a stage_id and reflects the different stages of a user journey, useful in sign-up funnels. You can filter using a unique client_id to view the client_status records for a specific client. To obtain the appropriate client_id, use the GET /client endpoint to view all clients defined for your tenant.

HTTP REQUEST

GET /client_status

Create a client status

Example Request

curl -X POST -H "Authorization: Bearer 7f137375-c63b-49fb-84eb-5abbd3b780a3" \
-H "Content-Type: application/json" \
-d '{
        "status": "KYC complete",
        "stage_id": "e995d4c1-f989-4733-9867-713966ac9856",
        "account_id": "1d7e1aad-3c79-49fe-bbb9-bd5e239ae1e7"
    }' "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/client_status"
# Create a ClientStatus
client_status = nucleus_api.ClientStatus(client_id="", stage_id="", status="")
try:
    api_response = api_instance.create_client_status_using_post(client_status)
    pprint(api_response)
except ApiException as e:
    print("create_client_status_using_post: %s\n" % e)
ClientApi apiInstance = new ClientApi();
                //Create a Client Status
        ClientStatus status = new ClientStatus();
                status.setClientId(UUID.fromString("63f05f77-1851-477c-9866-88effe5aeca3"));
                status.setStageId(UUID.fromString("f154f89b-407a-4e7d-baa8-a73a97debce2"));
                status.setStatus("Passed");

        try {
            ClientStatus result = apiInstance.createClientStatusUsingPost(status);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling createClientStatusUsingPost");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\ClientApi(
    new GuzzleHttp\Client(),
    $config);
$ascending = false; // bool | ascending
//Create Client Status
$client_status = new \com\hydrogen\nucleus\Model\ClientStatus();

try {
    $client_status->setClientId("63f05f77-1851-477c-9866-88effe5aeca3");
    $client_status->setStageId("f154f89b-407a-4e7d-baa8-a73a97debce2");
    $client_status->setStatus("passed");
    $result = $apiInstance->createClientStatusUsingPost($client_status);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->createClientStatusUsingPost: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::ClientApi.new

#Create ClientStatus
clientstatus = NucleusApi::ClientStatus.new

begin
  clientstatus.client_id = "63f05f77-1851-477c-9866-88effe5aeca3"
  clientstatus.stage_id = "f154f89b-407a-4e7d-baa8-a73a97debce2"
  clientstatus.status = "New"
  result = api_instance.create_client_status_using_post(clientstatus)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->create_client_status_using_post: #{e}"
end
var apiInstance = new HydrogenNucleusApi.ClientApi();
//Create ClientStatus
var clientstatus = new HydrogenNucleusApi.Client();
clientstatus.client_id = '63f05f77-1851-477c-9866-88effe5aeca3';
clientstatus.stage_id = "f154f89b-407a-4e7d-baa8-a73a97debce2";
clientstatus.status = "New";


var newcllientstatus = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.createClientStatusUsingPost(clientstatus, newcllientstatus)

Example Response

{
    "id": "6db4a470-a00c-40bb-a325-067d0bdb3ddc",
    "create_date": "2018-02-08T16:59:27.000+0000",
    "comments": null,
    "status": "KYC Complete",
    "stage_id": "e995d4c1-f989-4733-9867-713966ac9856",
    "client_id": "1d7e1aad-3c79-49fe-bbb9-bd5e239ae1e7",
    "metadata": {}
}

Create a client status record for a client by assigning a stage_id to the client. The unique client_id and stage_id must be provided. To obtain the appropriate client_id, use the GET /client endpoint to view all clients defined for your tenant. To obtain the appropriate stage_id, use the GET /stage endpoint to view all client stages defined for your tenant. The create_date defaults to the current date. The endpoint returns an client_status_id which represents a record in the client’s history log.

HTTP REQUEST

POST /client_status

ARGUMENTS

Parameter Type Required Description
client_id UUID required The id of the client to which the status belongs
status string required Status of the client such as “Signed Up” or “KYC Submitted”
stage_id UUID required Refers to the stage the client is in.
Useful for sign-up funnels where an account is not being created.
comments string optional Comments for the client regarding their status
metadata map optional Custom information associated with the entity in the format key:value
See Metadata
secondary_id string optional Alternate id that can be used to identify the object such as an internal id

Retrieve a client status

Example Request

curl -X GET -H "Authorization: Bearer 7f137375-c63b-49fb-84eb-5abbd3b780a3" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/client_status/6db4a470-a00c-40bb-a325-067d0bdb3ddc"
api_instance = nucleus_api.ClientApi(nucleus_api.ApiClient(configuration))
try:
    api_response = api_instance.get_client_status_using_get("06ba20a1-bdb8-42b9-99f1-42dd2a3fb608")
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_client_status_using_get: %s\n" % e)
ClientApi apiInstance = new ClientApi();
        try {
            ClientStatus clientstatus = apiInstance.getClientStatusUsingGet(UUID.fromString("b70287e8-3c04-44bd-aa8d-1e3792348394"));
        } catch (ApiException e) {
            System.err.println("Exception when calling getClientStatusUsingGet");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\ClientApi(
    new GuzzleHttp\Client(),
    $config);
$client_status_id = "b70287e8-3c04-44bd-aa8d-1e3792348394"; // string | UUID client_status_id

try {
    $clientstatus = $apiInstance->getClientStatusUsingGet($client_status_id);
    print_r($clientstatus);
} catch (Exception $e) {
    echo 'Exception when calling ClientApi->getClientStatusUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::ClientApi.new
client_status_id = 'b70287e8-3c04-44bd-aa8d-1e3792348394' # String | UUID client_status_id

begin
  clientstatus = api_instance.get_client_status_using_get(client_status_id)
  p clientstatus
rescue NucleusApi::ApiError => e
  puts "Exception when calling ClientApi->get_client_status_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.ClientApi();
var clientstatusid = "b70287e8-3c04-44bd-aa8d-1e3792348394";


var clientstatus = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.getClientStatusUsingGet(clientstatusid, clientstatus)

Example Response

{
    "id": "6db4a470-a00c-40bb-a325-067d0bdb3ddc",
    "create_date": "2018-02-08T16:59:27.000+0000",
    "update_date": "2018-02-08T16:59:27.000+0000",
    "comments": "Invested",
    "status": "Complete",
    "stage_id": "e995d4c1-f989-4733-9867-713966ac9856",
    "account_id": "1d7e1aad-3c79-49fe-bbb9-bd5e239ae1e7",
    "metadata": {}
}

Retrieve the information for a specific client status record for a client. The unique client_status_id must be provided. The endpoint returns details for the client status record specified.

HTTP REQUEST

GET /client_status/{client_status_id}

Update a client status

Example Request

curl -X PUT -H "Authorization: Bearer 7f137375-c63b-49fb-84eb-5abbd3b780a3" \
-H "Content-Type: application/json" \
-d '{
        "status": "Complete",
        "stage_id": "e995d4c1-f989-4733-9867-713966ac9856",
        "client_id": "1d7e1aad-3c79-49fe-bbb9-bd5e239ae1e7"
    }' "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/client_status/6db4a470-a00c-40bb-a325-067d0bdb3ddc"
api_instance = nucleus_api.ClientApi(nucleus_api.ApiClient(configuration))
# #Update ClientStatus
client_status_update = {'status': 'New'}
status_id = '47dfb9db-9b83-4cc9-8b3d-a14d11c0e452'
try:
    api_response = api_instance.update_client_status_using_put(client_status_update, status_id)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling update_client_status_using_put: %s\n" % e)
ClientApi apiInstance = new ClientApi();
        //Update Client Status
        Map map1 = new HashMap();
        map.put("status", "Updated");

        try {
            ClientStatus response = apiInstance.updateClientStatusUsingPut(map1, UUID.fromString("fd0a39bf-390f-4319-9df1-746872d66ea2"));
            System.out.println(response);
        } catch (ApiException e) {
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\ClientApi(
    new GuzzleHttp\Client(),
    $config);
$ascending = false; // bool | ascending
//Update ClientStatus
$client_status_update = new stdClass();
$client_status_id = "8847a92e-71e3-454c-8626-3d7a601ab6d3";

try {
    $client_status_update->status = "one";
    $result = $apiInstance->updateClientStatusUsingPut($client_status_update, $client_status_id);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->updateClientStatusUsingPut: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::ClientApi.new

#Update Clientstatus
client_status_update = {"status" => 'visa'}
client_status_id = '9a2bc11a-9bed-4266-9040-0100b8eb8729'
begin
  result = api_instance.update_client_status_using_put(client_status_update, client_status_id)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->update_client_status_using_put: #{e}"
end
var apiInstance = new HydrogenNucleusApi.ClientApi();
//Update Client Status
var apiInstance = new HydrogenNucleusApi.ClientApi();
var callback = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
var clientstatusupdate = new HydrogenNucleusApi.Client();
var clientstatusid = "75982466-7bd4-45a0-a9a7-268e0fdbe4b6";

clientstatusupdate.status = "new";
apiInstance.updateClientStatusUsingPut(clientstatusupdate, clientstatusid, callback)

Example Response

{
    "id": "6db4a470-a00c-40bb-a325-067d0bdb3ddc",
    "create_date": "2018-02-08T16:59:27.000+0000",
    "update_date": "2018-02-08T16:59:27.000+0000",
    "comments": null,
    "status": "KYC in Progress",
    "stage_id": "e995d4c1-f989-4733-9867-713966ac9856",
    "client_id": "1d7e1aad-3c79-49fe-bbb9-bd5e239ae1e7",
    "metadata": {}
}

Update a client status record for a client. The unique client_status_id must be provided. To obtain the appropriate client_status_id, use the GET /client_status endpoint to view all client statuses for each client defined for your tenant and their current information. The details to be updated must also be provided. The endpoint returns the client_status_id with the details for the client status.

HTTP REQUEST

PUT /client_status/{client_status_id}

Delete a client status

Example Request

curl -X DELETE -H "Authorization: Bearer 7f137375-c63b-49fb-84eb-5abbd3b780a3" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/client_status/6db4a470-a00c-40bb-a325-067d0bdb3ddc"
api_instance = nucleus_api.ClientApi(nucleus_api.ApiClient(configuration))
# # Delete a ClientStatus
status_id = '06ba20a1-bdb8-42b9-99f1-42dd2a3fb608'
try:
    api_instance.delete_client_status_using_delete(status_id)
except ApiException as e:
    print("Exception when delete_client_status_using_delete: %s\n" % e)
ClientApi apiInstance = new ClientApi();
                // Delete ClientStatus
        try {
            ClientStatus deleteresponse = apiInstance.deleteClientStatusUsingDelete(UUID.fromString("fdd59bc0-a28e-4c0f-84d8-27dae3900ab1"));
            System.out.println(deleteresponse);
        } catch (ApiException e) {
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\ClientApi(
    new GuzzleHttp\Client(),
    $config);
$ascending = false; // bool | ascending
//Delete Client Status
$client_status_did = "def861e6-2710-482e-938d-8bbcdc3bfefa"; // string | UUID account_id

try {
    $apiInstance->deleteClientUsingDelete($client_status_did);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->deleteClientUsingDelete: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::ClientApi.new
#Delete ClientStatus
client_status1_id = 'fdd59bc0-a28e-4c0f-84d8-27dae3900ab1'
begin
  result = api_instance.delete_client_status_using_delete(client_status1_id)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->delete_client_status_using_delete: #{e}"
end
var apiInstance = new HydrogenNucleusApi.ClientApi();
// //Delete a Client
var clientstatusdid = "def861e6-2710-482e-938d-8bbcdc3bfefa";


var deleteclientstatus = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully.');
    }
};
apiInstance.deleteClientStatusUsingDelete(clientstatusid, deleteclientstatus)

Response (204 No Content)

Permanently delete a client status record from an client’s history. The client_status_id must be provided. To obtain the appropriate client_status_id, use the GET /client_status endpoint to view all client statuses for each client defined for your tenant. This deletes the client_status_id from the client’s history log table and removes the status from the client.

HTTP REQUEST

DELETE /client_status/{client_status_id}

Document

The document repository can be used to create documents for firm-wide distribution, for a specific client, or for a specific account.

Field Type Description
id UUID The id of the document
doc_name string Name or title of the document
doc_size integer Size of the document. Must be a whole number
doc_type string Type of document such as “Compliance” or “Registration”
doc_file longtext Encrypted content of the document to be stored such as a Base64 encoded string if not provided as url_path to an externally hosted link.
url_path string URL path for the document such as http://domain.com/sample.pdf
doc_number string Number or alphanumeric identifier on the document such as the driver’s license or passport number
doc_image_front longtext Encrypted content of the document’s front image such as a Base64 encoded string or the name of the file. 4mb limit
doc_image_back longtext Encrypted content of the document’s back image such as a Base64 encoded string or the name of the file. 4mb limit
issue_date date Issue date of the document in the format yyyy-mm-dd
expiry_date date Expiry date of the document in the format yyyy-mm-dd
state_of_issue string Abbreviation or full name of the document’s state of issue
country_of_issue string Country of issue for the document using the ISO ALPHA-2 Code. See Country Codes
client_id UUID In the case that the document relates to a specific Client, the id of the client
account_id UUID In the case that the document relates to a specific Account, the id of the account
business_id UUID In the case that the document relates to a specific Business, the id of the business
is_verified boolean Indicates if the identifying details on the document have been verified by a Know-Your-Customer (KYC) vendor. Defaults to false which indicates it is not verified
is_sensitive boolean Indicates if the document contains sensitive information such as PII data. Sensitive documents will return “omitted“ in the following fields: doc_file, doc_image_front, doc_image_back, doc_number. This field is only available in POST requests. Once set in the POST, you cannot change this flag, or view it in the results. Defaults to false which indicates it is not sensitive.
is_active boolean Indicates if the document is currently active. Defaults to true which indicates it is active
metadata map Custom information associated with the document in the format key:value
See Metadata
secondary_id string Alternate id that can be used to identify the object such as an internal id
create_date timestamp Timestamp for the date and time that document was created
update_date timestamp Timestamp for the date and time that the document was last updated

List all documents

Example Request

curl -X GET -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/document"
api_instance = nucleus_api.DocumentApi(nucleus_api.ApiClient(configuration))
# List all Documents
try:
    api_response = api_instance.get_document_all_using_get()
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_document_all_using_get: %s\n" % e)
DecisionTreeApi apiInstance = new DocumentApi();
        //List all Documents
        try {
            PageDocument List = apiInstance.getDocumentAllUsingGet(true, null, null, 0, 10);
            System.out.println(List);
        } catch (ApiException e) {
            System.err.println("Exception when calling getDocumentAllUsingGet");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\DocumentApi(
    new GuzzleHttp\Client(),
    $config);
//List all Document
$ascending = false; // bool | ascending
$filter = null; // string | filter
$order_by = null; // string | order_by
$page = 0; // int | page
$size = 10; // int | size

try {
    $documentlist = $apiInstance->getDocumentAllUsingGet($ascending, $filter, $order_by, $page, $size);
    print_r($documentlist);
} catch (Exception $e) {
    echo 'Exception when calling DocumentApi->getDocumentAllUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = AtomApi::DocumentApi.new
#List all Documents
opts = {
    ascending: false, # BOOLEAN | ascending
    filter: null, # String | filter
    order_by: null, # String | order_by
    page: 0, # Integer | page
    size: 25 # Integer | size
}
begin
  documentlist = api_instance.get_document_all_using_get(opts)
  p documentlist
rescue NucleusApi::ApiError => e
  puts "Exception when calling DocumentApi->get_document_all_using_get: #{e}"
end
var apiInstance = new atom_api.DocumentApi();
//List all Document

var opts = {
    'ascending': false, // Boolean | ascending
    // 'filter': "", // String | filter
    'orderBy': "update_date", // String | order_by
    'page': 0, // Number | page
    'size': 25 // Number | size
};

var documentlist = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.getDocumentAllUsingGet(opts, documentlist)

Example Response

{
  "content": [
    {
            "id": "36f9cb66-88a9-4a1f-a305-338a0f0e0a57",
            "create_date": "2018-04-12T18:47:38.000+0000",
            "update_date": "2018-04-13T09:00:00.000+0000",
            "doc_size": null,
            "url_path": "http://domain.com/screenshot.png",
            "doc_name": "Deposit Confirmation",
            "doc_type": "Confirmation screenshot",
            "doc_file": null,
            "doc_number": null,
            "doc_image_front": null,
            "doc_image_back": null,
            "issue_date": null,
            "expiry_date": null,
            "state_of_issue": null,
            "country_of_issue": null,
            "client_id": "8e1799f0-4429-4939-ae84-7391cff93ba5",
            "account_id": null,
            "business_id": null,
            "is_verified": false,
            "is_active": true,
            "secondary_id": null,
            "metadata": {}
    },
    {
            "id": "849256af-6f8a-44bc-a69f-82639cb2f1a9",
            "create_date": "2018-04-10T21:06:22.000+0000",
            "update_date": "2018-04-10T21:06:22.000+0000",
            "doc_size": null,
            "url_path": "http://domain.com/letter.pdf",
            "doc_name": "Compliance Letter",
            "doc_type": "Compliance",
            "doc_number": null,
            "doc_image_front": null,
            "doc_image_back": null,
            "issue_date": null,
            "expiry_date": null,
            "state_of_issue": null,
            "country_of_issue": null,
            "client_id": "8e1799f0-4429-4939-ae84-7391cff93ba5",
            "account_id": null,
            "business_id": null,
            "is_verified": false,
            "is_active": true,
            "secondary_id": null,
            "metadata": {}
        }
  ],
  "total_pages": 1,
  "total_elements": 2,
  "last": true,
  "first": true,
  "sort": [
      {
          "direction": "DESC",
          "property": "updateDate",
          "ignore_case": false,
          "null_handling": "NATIVE",
          "descending": true,
          "ascending": false
      }
  ],
  "number_of_elements": 2,
  "size": 25,
  "number": 0
}

Get the information for all documents defined for your tenant. You can filter using a client_id or an account_id to view the documents for a specific client or account. In this aggregate view the full content of any base64 encoded documents or images stored in doc_file, doc_image_front or doc_image_back will be truncated for optimized performance. Please query the individual document_id via GET /document/{document_id} to display the full content.

HTTP REQUEST

GET /document

Create a document

Example Request

curl -X POST -H "Authorization: Bearer <access_token>" \
    -H "Content-Type: application/json" \
    -d '{
            "doc_name": "Deposit Confirmation",
            "doc_type": "Confirmation screenshot",
            "url_path": "http://domain.com/screenshot.png"
        }' "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/document"
api_instance = nucleus_api.DocumentApi(nucleus_api.ApiClient(configuration))
# # Create a Document
doc = nucleus_api.Document(doc_name="First Doc", doc_size="100", url_path="https://www.hydrogenplatform.com", doc_type="Major", doc_number="6533", doc_image_back="image1", doc_image_front="image2")
try:
    api_response = api_instance.create_document_using_post(doc)
    pprint(api_response)
except ApiException as e:
    print("create_document_using_post: %s\n" % e)
DecisionTreeApi apiInstance = new DocumentApi();
        //Create a Document
        Document doc = new Document();
        doc.setDocName("First Doc");
        doc.setDocSize(10l);
        doc.setUrlPath("https://www.hydrogenplatform.com");
        doc.setDocType("Major");
        doc.setDocNumber("5432");
        doc.setDocImageBack("image1");
        doc.setDocImageFront("image2");

        try {
            Document result = apiInstance.createDocumentUsingPost(doc);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling createDocumentUsingPost");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\DocumentApi(
    new GuzzleHttp\Client(),
    $config);
//Create Document
$document = new \com\hydrogen\nucleus\Model\Document();

try {
    $document->setUrlPath("https://www.hydrogenplatform.com");
    $document->setDocName("New doc");
    $document->setDocSize("12");
    $document->setDocType("Text");
    $document->setDocNumber("443");
    $document->setDocImageBack("image");
    $document->setDocImageFront("image");

    $result = $apiInstance->createDocumentUsingPost($document);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->createDocumentUsingPost: ', $e->getMessage(), PHP_EOL;
}
api_instance = AtomApi::DocumentApi.new
#Create Document
docs = NucleusApi::Document.new

begin
  docs.url_path = "https://www.hydrogenplatform.com"
  docs.doc_name = "New Doc"
  docs.doc_size = "200"
  docs.doc_type = "email"
  docs.doc_number = "6645"
  docs.doc_image_back = "image"
  docs.doc_image_front = "image"
  result = api_instance.create_document_using_post(docs)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->create_document_using_post: #{e}"
end
var apiInstance = new atom_api.DocumentApi();
// //Create a Node Document
var doc = new HydrogenNucleusApi.Document();
doc.doc_name = "Abc";
doc.doc_size = "20";
doc.url_path = "https://www.hydrogenplatform.com";
doc.doc_type = "New";
doc.doc_number = "6576";
doc.doc_image_back = "itr";
doc.doc_image_front = "hk";

var newdocument = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.createDocumentUsingPost(doc, newdocument)

Example Response

{
    "id": "c4ea6c00-d0b4-4d75-9e7a-e9dd04319586",
    "create_date": "2018-04-12T18:46:12.000+0000",
    "update_date": "2018-04-13T09:00:00.000+0000",
    "doc_size": null,
    "doc_name": "Deposit Confirmation",
    "doc_type": "Confirmation screenshot",
    "url_path": "http://domain.com/screenshot.png",
    "doc_file": null,
    "doc_number": null,
    "doc_image_front": null,
    "doc_image_back": null,
    "issue_date": null,
    "expiry_date": null,
    "state_of_issue": null,
    "country_of_issue": null,
    "client_id": "8e1799f0-4429-4939-ae84-7391cff93ba5",
    "account_id": null,
    "business_id": null,
    "is_verified": false,
    "is_active": true,
    "secondary_id": null,
    "metadata": {}
}

Store a document for your tenant or users. You must either store the content of the document as a string under doc_file or provide a URL for the document under url_path. The create_date will default to the current date. The endpoint returns a document_id used to identify and manage the document.

HTTP REQUEST

POST /document

ARGUMENTS

Parameter Type Required Description
doc_name string required Name or title of the document
doc_size integer optional Size of the document. Must be a whole number
doc_type string optional Type of document such as “Compliance” or “Registration”
doc_file longtext optional Content of the document to be stored such as a Base64 encoded string if not provided as url_path to an externally hosted link
url_path string optional URL path for the document such as http://domain.com/sample.pdf
doc_number string optional Number or alphanumeric identifier on the document such as the driver’s license or passport number
doc_image_front longtext optional Encrypted content of the document’s front image such as a Base64 encoded string or the name of the file. 4mb limit
doc_image_back longtext optional Encrypted content of the document’s back image such as a Base64 encoded string or the name of the file. 4mb limit
issue_date date optional Issue date of the document in the format yyyy-mm-dd
expiry_date date optional Expiry date of the document in the format yyyy-mm-dd
state_of_issue string optional Abbreviation or full name of the document’s state of issue
country_of_issue string optional Country of issue for the document using the ISO ALPHA-2 Code. See Country Codes
client_id UUID optional In the case that the document relates to a specific Client, the id of the client
account_id UUID optional In the case that the document relates to a specific Account, the id of the account
business_id UUID optional In the case that the document relates to a specific Business, the id of the business
is_verified boolean optional Indicates if the identifying details on the document have been verified by a Know-Your-Customer (KYC) vendor. Defaults to false which indicates it is not verified
is_sensitive boolean optional Indicates if the document contains sensitive information such as PII data. Sensitive documents will return “omitted“ in the following fields: doc_file, doc_image_front, doc_image_back, doc_number. Once set in the POST, you cannot change this flag, or view it in the results. Defaults to false which indicates it is not sensitive.
is_active boolean optional Indicates if the document is currently active. Defaults to true which indicates it is active
metadata map optional Custom information associated with the document in the format key:value
See Metadata
secondary_id string optional Alternate id that can be used to identify the object such as an internal id

Retrieve a document

Example Request

curl -X GET -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/document/c4ea6c00-d0b4-4d75-9e7a-e9dd04319586"
api_instance = nucleus_api.DocumentApi(nucleus_api.ApiClient(configuration))
# Retrieve a Document
try:
    api_response = api_instance.get_document_using_get("4bd955df-ed7f-451a-9fd2-d898826683c9")
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_document_using_get: %s\n" % e)
DecisionTreeApi apiInstance = new DocumentApi();
        //Retrieve A Document
        try {
            Document responseDocument = apiInstance.getDocumentUsingGet(UUID.fromString("5432f6a8-2ec9-4d84-807c-d0778037cd46"));
            System.out.println(responseDocument);
        } catch (ApiException e) {
            System.err.println("Exception when calling getDocumentUsingGet");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\DocumentApi(
    new GuzzleHttp\Client(),
    $config);

//Retrieve a Document
$document_id = "5432f6a8-2ec9-4d84-807c-d0778037cd46"; // string | UUID document_id

try {
    $document = $apiInstance->getDocumentUsingGet($document_id);
    print_r($document);
} catch (Exception $e) {
    echo 'Exception when calling DocumentApi->getDocumentUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = AtomApi::DocumentApi.new
#Retrieve a Document
document_id = '5432f6a8-2ec9-4d84-807c-d0778037cd46' # String | UUID document_id


begin
  document = api_instance.get_document_using_get(document_id)
  p document
rescue NucleusApi::ApiError => e
  puts "Exception when calling DocumentApi->get_document_using_get: #{e}"
end
var apiInstance = new atom_api.DocumentApi();
//Retrieve an Document

var documentid = "5432f6a8-2ec9-4d84-807c-d0778037cd46";


var document = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.getDocumentUsingGet(documentid, document)

Example Response

{
    "id": "c4ea6c00-d0b4-4d75-9e7a-e9dd04319586",
    "create_date": "2018-04-12T18:46:12.000+0000",
    "update_date": "2018-04-13T09:00:00.000+0000",
    "doc_size": null,
    "doc_name": "Deposit Confirmation",
    "doc_type": "Confirmation screenshot",
    "url_path": "http://domain.com/screenshot.png",
    "doc_file": null,
    "doc_number": null,
    "doc_image_front": null,
    "doc_image_back": null,
    "issue_date": null,
    "expiry_date": null,
    "state_of_issue": null,
    "country_of_issue": null,
    "client_id": "8e1799f0-4429-4939-ae84-7391cff93ba5",
    "account_id": null,
    "business_id": null,
    "is_verified": false,
    "is_sensitive": false,
    "is_active": true,
    "secondary_id": null,
    "metadata": {}
}

Retrieve a document for your tenant. The document_id must be provided. The endpoint returns the document_id and the details for the document specified. The full content of any base64 encoded documents or images stored in doc_file, doc_image_front or doc_image_back will display in this individual view only.

HTTP REQUEST

GET /document/{document_id}

Update a document

Example Request

curl -X PUT -H "Authorization: Bearer <access_token>" \
     -H "Content-Type: application/json" \
     -d '{
                    "url_path": "http://domain.com/sample.pdf"
             }' "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/document/c4ea6c00-d0b4-4d75-9e7a-e9dd04319586"
api_instance = nucleus_api.DocumentApi(nucleus_api.ApiClient(configuration))
# # Update a Document
doc_update = {'doc_number': '76645'}
doc_id = 'fe5ca88e-9c5e-41b7-88f4-c9c985286c58'
try:
    api_response = api_instance.update_document_using_put(doc_update, doc_id)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling update_document_using_put: %s\n" % e)
DecisionTreeApi apiInstance = new DocumentApi();
        //Update a Document
        Map map = new HashMap();
        map.put("doc_name", "Updated doc");

        try {
            Document response = apiInstance.updateDocumentUsingPut(map, UUID.fromString("27b0b273-7033-4c2e-9325-c7fe9dab5cf4"));
            System.out.println(response);
        } catch (ApiException e) {
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\DocumentApi(
    new GuzzleHttp\Client(),
    $config);
//Update Document
$document_update = new stdClass();
$doocument_id = "5a274984-2b24-4a3b-8fac-832eb0a1f2e0";

try {
    $document_update->doc_type = "New";
    $result = $apiInstance->updateDocumentUsingPut($document_update, $document_id);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->updateDocumentUsingPut: ', $e->getMessage(), PHP_EOL;
}
api_instance = AtomApi::DocumentApi.new
#Update Document
doc_update = {"doc_name" => 'New'}
doc_id = 'fee504b9-81f5-4521-9916-359f04c42bdc'
begin
  result = api_instance.update_document_using_put(doc_update, doc_id)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->update_document_using_put: #{e}"
end
var apiInstance = new atom_api.DocumentApi();
//Update Docuemnt
var apiInstance = new HydrogenNucleusApi.DocumentApi();
var callback = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
var documentupdate = new HydrogenNucleusApi.Document();
var docid = '2a376645-1927-4af7-9bc9-d217aa0895b6';

documentupdate.doc_image_back = "New A";
apiInstance.updateDocumentUsingPut(documentupdate, docid, callback)

Example Response

{
    "id": "c4ea6c00-d0b4-4d75-9e7a-e9dd04319586",
    "create_date": "2018-04-12T18:46:12.000+0000",
    "update_date": "2018-04-13T09:00:00.000+0000",
    "doc_size": null,
    "doc_name": "Deposit Confirmation",
    "doc_type": "Confirmation screenshot",
    "url_path": "http://domain.com/sample.pdf",
    "doc_file": null,
    "doc_number": null,
    "doc_image_front": null,
    "doc_image_back": null,
    "issue_date": null,
    "expiry_date": null,
    "state_of_issue": null,
    "country_of_issue": null,
    "client_id": "8e1799f0-4429-4939-ae84-7391cff93ba5",
    "account_id": null,
    "business_id": null,
    "is_verified": false,
    "is_active": true,
    "secondary_id": null,
    "metadata": {}
}

Update a document for your tenant or users. The document_id must be provided. To obtain the appropriate document_id, use the GET /document endpoint to view all of the documents for your tenant and their current information. The details to be updated and the details to be maintained must also be provided. The endpoint returns the document_id and the details for the document.

HTTP REQUEST

PUT /document/{document_id}

Delete a document

Example Request

curl -X DELETE -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/document/c4ea6c00-d0b4-4d75-9e7a-e9dd04319586"
api_instance = nucleus_api.DocumentApi(nucleus_api.ApiClient(configuration))
# # # Delete a Document
docd_id = '27b0b273-7033-4c2e-9325-c7fe9dab5cf4'
try:
    api_instance.delete_document_using_delete(docd_id)
except ApiException as e:
    print("Exception when delete_document_using_delete: %s\n" % e)
DecisionTreeApi apiInstance = new DocumentApi();
        //Delete a Document
                try {
            Document deleteresponse = apiInstance.deleteDocumentUsingDelete(UUID.fromString("be99333c-dafc-4d9f-b76a-96257f27e00b"));
            System.out.println(deleteresponse);
        } catch (ApiException e) {
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\DocumentApi(
    new GuzzleHttp\Client(),
    $config);
//Delete Document
$document_did = "27b0b273-7033-4c2e-9325-c7fe9dab5cf4"; // string | UUID account_id

try {
    $apiInstance->deleteDocumentUsingDelete($document_did);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->deleteDocumentUsingDelete: ', $e->getMessage(), PHP_EOL;
}
api_instance = AtomApi::DocumentApi.new
#Delete Document
document1_id = '2a376645-1927-4af7-9bc9-d217aa0895b6'
begin
  result = api_instance.delete_document_using_delete(document1_id)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->delete_document_using_delete: #{e}"
end
var apiInstance = new atom_api.DocumentApi();
// //Delete a Document
var docidd = "27b0b273-7033-4c2e-9325-c7fe9dab5cf4";


var deletedocument = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully.');
    }
};
apiInstance.deleteDocumentUsingDelete(docidd, deletedocument)

Response (204 No Content)

Permanently delete a document for your tenant. The document_id must be provided. To obtain the appropriate document_id, use the GET /document endpoint to view all of the documents for your tenant. This deletes the document_id and the details for the document record.

HTTP REQUEST

DELETE /document/{document_id}

Funding

Bank links are established connections between a client’s account on your platform and his or her bank account. They are used to transfer funds from the bank account to the account on your platform.

Field Type Description
id UUID The id for the specific bank link
bank_account_holder string Name of the individual that owns the bank account
bank_account_number string Account number of the bank account
institution_name string Name of the institution for this bank link, e.g. HSBC
institution_id UUID ID of the institution resource for this bank link
routing string Routing number of the bank for this bank link
routing_wire string Routing number of the bank for the bank link used for wire transfers
mask string The masked version of the bank account number for this bank link
bank_account_name string Name of the bank account, e.g. Mike’s HSBC Checking
client_id UUID The id of the client to which the bank link belongs
business_id UUID The id of the business to which the bank link belongs
account_id UUID The id of the account to which the bank link belongs
currency_code string Alphabetic currency code for the base currency of the bank account linked, limited to 3 characters. See currency codes
balance string Current balance of the bank account
available_balance string Available balance of the bank account, usually taking into consideration pending transactions or available overdraft
type string Used to indicate the type of bank account for this bank link such as a ‘savings’ account
is_default boolean Indicates if the bank link is the default link for a client. Only one bank link may be default for a client_id. If a user sets a bank link to is_default = “true” then all other bank links for that client_id will be set to is_default = “false.” Defaults to false which indicates the bank link is not default
is_active boolean Indicates if the bank link is active. Defaults to true which indicates it is active
is_link_verified boolean Indicates if the bank link has been verified. Defaults to false which indicates it has not been verified
link_verified_date date Date and time that the bank link was verified
metadata map Custom information associated with the bank link in the format key:value. See Metadata
secondary_id string Alternate id that can be used to identify the object such as an internal id
create_date timestamp Timestamp for the date and time that the record was created. Defaults to the current date
update_date timestamp Timestamp for the date and time that the record was last updated

Example Request

curl -X GET -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/bank_link"
FundingApi apiInstance = new FundingApi();
        try {
            PageBankLink List = apiInstance.getBankLinkAllUsingGet(true, null, null, null, 0, 10);
            System.out.println(List);
        } catch (ApiException e) {
            System.err.println("Exception when calling getBankLinkAllUsingGet");
            e.printStackTrace();
        }
api_instance = nucleus_api.FundingApi(nucleus_api.ApiClient(configuration))
try:
    api_response = api_instance.get_bank_link_all_using_get()
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_bank_link_all_using_get: %s\n" % e)
$apiInstance = new com\hydrogen\nucleus\Api\FundingApi(
    new GuzzleHttp\Client(),
    $config);
$ascending = false; // bool | ascending
$currency_conversion = null; // string | currency_conversion
$filter = null; // string | filter
$order_by = null; // string | order_by
$page = 0; // int | page
$size = 10; // int | size

try {
    $banklinklist = $apiInstance->getBankLinkAllUsingGet($ascending, $currency_conversion, $filter, $order_by, $page, $size);
    print_r($banklinklist);
} catch (Exception $e) {
    echo 'Exception when calling FundingApi->getBankLinkAllUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::FundingApi.new
opts = {
    ascending: false, # BOOLEAN | ascending
    currency_conversion: null, # String | currency_conversion
    filter: null, # String | filter
    order_by: null, # String | order_by
    page: 0, # Integer | page
    size: 25 # Integer | size
}

begin
  banklinklist = api_instance.get_bank_link_all_using_get(opts)
  p banklinklist
rescue NucleusApi::ApiError => e
  puts "Exception when calling FundingApi->get_bank_link_all_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.FundingApi();
var opts = {
    'ascending': false, // Boolean | ascending
    // 'filter': "", // String | filter
    'orderBy': "update_date", // String | order_by
    'page': 0, // Number | page
    'size': 25 // Number | size
};

var banklinklist = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.getBankLinkAllUsingGet(opts, banklinklist)

Example Response

{
  "content":
  [
    {
      "id": "4ff21db3-97ab-4bbd-9885-be6aec522c44",
      "create_date": "2018-04-12T17:34:17.000+0000",
      "update_date": "2018-04-12T17:34:17.000+0000",
      "client_id": null,
      "business_id": null,
      "account_id": "647c54c3-b649-477e-8cc7-eee56a120dd3",
      "bank_account_holder": "Jon Linndt",
      "bank_account_name": "HSBC Checking",
      "bank_account_number": "111111",
      "mask": "xx1111",
      "institution_name": "HSBC",
      "institution_id": null,
      "routing": "111111",
      "routing_wire": "111111-22",
      "currency_code": "USD",
      "balance": "1600",
      "available_balance": "1500",
      "type": "Checking",
      "is_default": false,
      "is_active": true,
      "is_link_verified": true,
      "link_verified_date": "2018-01-01",
      "type": "Checking",
      "metadata": {}
    },
    {
      "id": "425a2f77-b24b-4d93-ba13-a7b6bd01e947",
      "create_date": "2018-04-12T17:34:17.000+0000",
      "update_date": "2018-04-12T17:34:17.000+0000",
      "client_id": null,
      "business_id": null,
      "account_id": "272d9271-be64-4eb8-a3f4-abc57ca547c2",
      "bank_account_holder": "Andrew Williams",
      "bank_account_number": "2552001002",
      "mask": "xxxxxx1002",
      "bank_account_name": "Bank 2 - Checking Account",
      "institution_name": "Bank XYZ2",
      "institution_id": null,
      "routing": "5289786002",
      "currency_code": "USD",
      "balance": "36754.04",
      "available_balance": "35754.04",
      "is_default": false,
      "is_active": true,
      "is_link_verified": true,
      "link_verified_date": "2018-02-10",
      "metadata": {}
    },
    {
      "id": "d787cf19-d11c-49f2-abf3-f5fec1b101d4",
      "create_date": "2018-04-09T20:46:14.000+0000",
      "update_date": "2018-04-09T20:46:14.000+0000",
      "client_id": null,
      "business_id": null,
      "account_id": "199a8c08-cdd5-4c8c-8abf-535447cea11b",
      "bank_account_holder": "JB Smith",
      "bank_account_number": "2552001001",
      "mask": "xxxxxx1001",
      "bank_account_name": "Bank XYZ - Checking Account1",
      "institution_name": "Bank XYZ",
      "institution_id": null,
      "routing": "5289786000",
      "routing_wire": "5289786011",
      "currency_code": "USD",
      "balance": "36760.00",
      "available_balance": "35760.00",
      "type": "Checking",
      "is_default": false,
      "is_active": true,
      "is_link_verified": true,
      "link_verified_date": "2018-02-10",
      "metadata": {}
    }
  ],
    "total_elements": 3,
    "last": true,
    "total_pages": 1,
    "first": true,
    "sort": [
        {
            "direction": "DESC",
            "property": "updateDate",
            "ignore_case": false,
            "null_handling": "NATIVE",
            "ascending": false,
            "descending": true
        }
    ],
    "number_of_elements": 16,
    "size": 25,
    "number": 0
}

Get all bank links defined for all clients defined for your tenant. The endpoint returns a list of UUIDs with details defined for each bank link. You can filter using an account_id to return the bank link(s) for a specific account.

HTTP REQUEST

GET /bank_link

Example Request

curl -X POST -H "Authorization: Bearer <access_token>" \
     -H "Content-Type: application/json" \
     -d '{
              "account_id": "647c54c3-b649-477e-8cc7-eee56a120dd3",
              "bank_account_holder": "Jon Linndt",
              "bank_account_name": "HSBC Checking",
              "bank_account_number": "111111",
              "mask": "xx1111",
              "institution_name": "HSBC",
              "routing": "111111",
              "routing_wire": "111111-22",
              "currency_code": "USD",
              "balance": "1600",
              "available_balance": "1500",
              "type": "Checking",
              "is_active": true,
              "is_link_verified": true,
              "link_verified_date": "2018-01-01"
          }' "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/bank_link"
api_instance = nucleus_api.FundingApi(nucleus_api.ApiClient(configuration))
# # # Create a BankLink
banklink = nucleus_api.BankLink(client_id="652584da-bc46-436e-9630-80c5d87b77ff", account_id="ef24a0d7-7a18-430a-857c-3b5e5582b2d1", bank_account_holder="John", bank_account_name="primary account", bank_account_number="66400085", mask="0776", routing="One", routing_wire=None, currency_code="GBP", balance="100.00", institution_name="Citi BAnk")
try:
    api_response = api_instance.create_bank_link_using_post(banklink)
    pprint(api_response)
except ApiException as e:
    print("create_bank_link_using_post: %s\n" % e)
FundingApi apiInstance = new FundingApi();
        //Create a Bank Link
        BankLink banklinknew = new BankLink();
        banklinknew.setClientId(UUID.fromString("652584da-bc46-436e-9630-80c5d87b77ff"));
        banklinknew.setAccountId(UUID.fromString("ef24a0d7-7a18-430a-857c-3b5e5582b2d1"));
        banklinknew.setBankAccountHolder("John Cena");
        banklinknew.setBankAccountName("Primary Account");
        banklinknew.setBankAccountNumber("65785457");
        banklinknew.setMask("0924");
        banklinknew.setRouting("One A");
        banklinknew.setRoutingWire(null);
        banklinknew.setCurrencyCode("USD");
        banklinknew.setBalance(500.00);

        try {
            BankLink response = apiInstance.createBankLinkUsingPost(banklinknew);
            System.out.println(response);
        } catch (ApiException e) {
            System.err.println("Exception when calling createBankLinkUsingPost");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\FundingApi(
    new GuzzleHttp\Client(),
    $config);
//Create BankLink
$banklink = new \com\hydrogen\nucleus\Model\BankLink();

try {
    $banklink->setClientId("652584da-bc46-436e-9630-80c5d87b77ff");
    $banklink->setAccountId("ef24a0d7-7a18-430a-857c-3b5e5582b2d1");
    $banklink->setBankAccountHolder("ABc");
    $banklink->setBankAccountNumber("76");
    $banklink->setBankAccountName("New");
    $banklink->setMask("6565");
    $banklink->setRouting("766");
    $banklink->setRoutingWire("654");
    $banklink->setCurrencyCode("GBP");
    $banklink->setBalance("655");
    $banklink->setInstitutionName("ABC");

    $result = $apiInstance->createBankLinkUsingPost($banklink);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->createBankLinkUsingPost: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::FundingApi.new
#Create BankLink
banklink = NucleusApi::BankLink.new

begin
  banklink.client_id = "652584da-bc46-436e-9630-80c5d87b77ff"
  banklink.account_id = "ef24a0d7-7a18-430a-857c-3b5e5582b2d1"
  banklink.bank_account_holder = "Nick"
  banklink.bank_account_name = "saving"
  banklink.bank_account_number = "7765"
  banklink.mask = "6654"
  banklink.routing = "664"
  banklink.routing_wire = "65767"
  banklink.currency_code = "USD"
  banklink.balance = "600"
  result = api_instance.create_bank_link_using_post(banklink)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->create_bank_link_using_post: #{e}"
end
var apiInstance = new HydrogenNucleusApi.FundingApi();
Create a Bank Link
var banklink = new HydrogenNucleusApi.BankLink();
banklink.client_id = '652584da-bc46-436e-9630-80c5d87b77ff';
banklink.account_id = 'ef24a0d7-7a18-430a-857c-3b5e5582b2d1';
banklink.bank_account_holder = "ABC"
banklink.bank_account_number = "68757776";
banklink.mask = "656";
banklink.routing = "767";
banklink.balance = "200";
banklink.institution_name = "New";
var newbanklink = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.createBankLinkUsingPost(banklink, newbanklink)

Example Response

{
  "id": "4ff21db3-97ab-4bbd-9885-be6aec522c44",
  "create_date": "2018-04-12T17:34:17.000+0000",
  "update_date": "2018-04-12T17:34:17.000+0000",
  "client_id": null,
  "business_id": null,
  "account_id": "647c54c3-b649-477e-8cc7-eee56a120dd3",
  "bank_account_holder": "Jon Linndt",
  "bank_account_name": "HSBC Checking",
  "bank_account_number": "111111",
  "mask": "xx1111",
  "institution_name": "HSBC",
  "institution_id": null,
  "routing": "111111",
  "routing_wire": "111111-22",
  "currency_code": "USD",
  "balance": "1600",
  "available_balance": "1500",
  "type": "Checking",
  "is_default": false,
  "is_active": true,
  "is_link_verified": true,
  "link_verified_date": "2018-01-01",
  "metadata": {}
}

Create a new bank link for an account. The unique account_id must be provided. To obtain the appropriate account_id, use the GET /account endpoint to view all the accounts defined for your tenant. The create_date will default to the current date. The endpoint returns a bank_link_id used to manage the bank link going forward.

HTTP REQUEST

POST /bank_link

ARGUMENTS

Parameter Type Required Description
bank_account_holder string required Name of the individual that owns the bank account
bank_account_number string required Account number of the bank account
institution_name string required, conditional Name of the institution for the bank link, e.g. HSBC. Either this name or the institution_id must be supplied.
institution_id UUID required, conditional ID of the institution resource for this bank link. Either this name or the institution_name must be supplied.
routing string required Routing number of the bank for the bank link
routing_wire string optional Routing number of the bank for the bank link used for wire transfers
mask string optional The masked version of the bank account number for this bank link
bank_account_name string optional Name of the bank account, e.g. Mike’s HSBC Checking
client_id UUID optional The id of the client to which the bank link belongs
business_id UUID optional The of for the business to which the bank link belongs
account_id UUID optional The id of the account to which the bank link belongs
currency_code string optional Alphabetic currency code for the base currency of the bank account linked, limited to 3 characters. See currency codes
balance string optional Current balance of the bank account
available_balance string optional Available balance of the bank account, usually taking into consideration pending transactions or available overdraft
type string optional Used to indicate the type of bank account for this bank link such as a ‘savings’ account
is_default boolean optional Indicates if the bank link is the default link for a client. Only one bank link may be default for a client_id. If a user sets a bank link to is_default = “true” then all other bank links for that client_id will be set to is_default = “false.” Defaults to false which indicates the bank link is not default
is_active boolean optional Indicates if the bank link is active. Defaults to true which indicates it is active
is_link_verified boolean optional Indicates if the bank link has been verified. Defaults to false which indicates it has not been verified
link_verified_date date optional Date and time that the bank link was verified
metadata map optional Custom information associated with the bank link in the format key:value. See Metadata
secondary_id string optional Alternate id that can be used to identify the object such as an internal id

Example Request

curl -X GET -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/bank_link/d787cf19-d11c-49f2-abf3-f5fec1b101d4"
FundingApi apiInstance = new FundingApi();
        try {
            BankLink responseBankLink = apiInstance.getBankLinkUsingGet(UUID.fromString("6d6eb20a-a331-4789-a90d-9698756e506f"), null);
            System.out.println(responseBankLink);
        } catch (ApiException e) {
            System.err.println("Exception when calling getBankLinkUsingGet");
            e.printStackTrace();
        }
api_instance = nucleus_api.FundingApi(nucleus_api.ApiClient(configuration))
try:
    api_response = api_instance.get_bank_link_using_get("8ef52bdc-e521-4c6e-b4f6-5fb889b8ba18")
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_bank_link_using_get: %s\n" % e)
$apiInstance = new com\hydrogen\nucleus\Api\FundingApi(
    new GuzzleHttp\Client(),
    $config);
$bank_link_id = "6d6eb20a-a331-4789-a90d-9698756e506f"; // string | UUID bank_link_id
$currency_conversion = null; // string | USD

try {
    $banklinklist = $apiInstance->getBankLinkUsingGet($bank_link_id, $currency_conversion);
    print_r($banklinklist);
} catch (Exception $e) {
    echo 'Exception when calling FundingApi->getBankLinkUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::FundingApi.new
bank_link_id = '6d6eb20a-a331-4789-a90d-9698756e506f' # String | UUID bank_link_id

opts = {
    currency_conversion: null, # String | USD
}

begin
  banklink = api_instance.get_bank_link_using_get(bank_link_id, opts)
  p banklink
rescue NucleusApi::ApiError => e
  puts "Exception when calling FundingApi->get_bank_link_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.FundingApi();
var banklinkID = "6d6eb20a-a331-4789-a90d-9698756e506f";

var opts = {
    'currencyConversion': null, // String | USD
};


var banklink = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.getBankLinkUsingGet(banklinkID, banklink)

Example Response

{
  "id": "4ff21db3-97ab-4bbd-9885-be6aec522c44",
  "create_date": "2018-04-12T17:34:17.000+0000",
  "update_date": "2018-04-12T17:34:17.000+0000",
  "client_id": null,
  "business_id": null,
  "account_id": "647c54c3-b649-477e-8cc7-eee56a120dd3",
  "bank_account_holder": "Jon Linndt",
  "bank_account_name": "HSBC Checking",
  "bank_account_number": "111111",
  "mask": "xx1111",
  "institution_name": "HSBC",
  "institution_id": null,
  "routing": "111111",
  "routing_wire": "111111-22",
  "currency_code": "USD",
  "balance": "1600",
  "available_balance": "1500",
  "type": "Checking",
  "is_default": false,
  "is_active": true,
  "is_link_verified": true,
  "link_verified_date": "2018-01-01",
  "metadata": {}
}

Retrieve the information for a bank link for an account. The unique bank_link_id must be provided. The endpoint returns the details for the bank link specified.

HTTP REQUEST

GET /bank_link/{bank_link_id}

Example Request

curl -X PUT -H "Authorization: Bearer <access_token>" \
     -H "Content-Type: application/json" \
     -d '{
                "account_id": "647c54c3-b649-477e-8cc7-eee56a120dd3",
                "bank_account_holder": "Jon Linndt",
                "bank_account_name": "HSBC Checking",
                "bank_account_number": "111111",
                "mask": "xx1111",
                "institution_name": "HSBC",
                "routing": "111111",
                "routing_wire": "111111-22",
                "currency_code": "USD",
                "balance": "1600",
                "available_balance": "1600",
                "type": "Checking",
                "is_active": true,
                "is_link_verified": true,
                "link_verified_date": "2018-01-01",
                "metadata": {}
           }' "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/bank_link/d787cf19-d11c-49f2-abf3-f5fec1b101d4"
api_instance = nucleus_api.FundingApi(nucleus_api.ApiClient(configuration))
# # Update a BankLink
banklink_update = {'balance': '1000'}
banklink_id = '2f5d07fd-f566-487b-accb-86ea1deb33d9'
try:
    api_response = api_instance.update_bank_link_bulk_using_put(banklink_update, banklink_id)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling update_bank_link_bulk_using_put: %s\n" % e)
FundingApi apiInstance = new FundingApi();
        //Update a BankLink
        BankLink update = new BankLink();
        update.setCurrencyCode("GBP");
        update.setBalance(100.00);

                try {
            BankLink updateResponse = apiInstance.updateBankLinkUsingPut(update, UUID.fromString("8ca49c52-babf-4a32-b721-af9a1d77ee93"));
            System.out.println(updateResponse);
        } catch (ApiException e) {
            System.err.println("Exception when calling updateBankLinkUsingPut");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\FundingApi(
    new GuzzleHttp\Client(),
    $config);
//Update BankLink
$banklink_update = new stdClass();
$banklink_id = "4954981c-2d15-4994-8a34-7f746783fbf0";

try {
    $banklink_update->bank_account_name = "BAC";
    $result = $apiInstance->updateBankLinkUsingPut($banklink_update, $banklink_id);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->updateBankLinkUsingPut: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::FundingApi.new
#Update BankLink
banklink_update = {"currency_code" => 'CAD'}
banklink_id = '1f717704-4b85-41c7-89e5-0e8f8a049ac8'
begin
  result = api_instance.update_bank_link_bulk_using_put(banklink_update, banklink_id)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->update_bank_link_bulk_using_put: #{e}"
end
var apiInstance = new HydrogenNucleusApi.FundingApi();
//Update BankLink
var apiInstance = new HydrogenNucleusApi.FundingApi();
var callback = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
var banklinkupdate = new HydrogenNucleusApi.BankLink();
var banklinkid = '84917a19-509e-443d-8a7a-2988d614e5ef';

banklinkupdate.institution_name = "New A";
apiInstance.updateBankLinkUsingPut(banklinkupdate, banklinkid, callback)

Example Response

{
  "id": "4ff21db3-97ab-4bbd-9885-be6aec522c44",
  "create_date": "2018-04-12T17:34:17.000+0000",
  "update_date": "2018-04-12T17:34:17.000+0000",
  "client_id": null,
  "business_id": null,
  "account_id": "647c54c3-b649-477e-8cc7-eee56a120dd3",
  "bank_account_holder": "Jon Linndt",
  "bank_account_name": "HSBC Checking",
  "bank_account_number": "111111",
  "mask": "xx1111",
  "institution_name": "HSBC",
  "institution_id": null,
  "routing": "111111",
  "routing_wire": "111111-22",
  "currency_code": "USD",
  "balance": "1600",
  "available_balance": "1600",
  "type": "Checking",
  "is_default": false,
  "is_active": true,
  "is_link_verified": true,
  "link_verified_date": "2018-01-01",
  "metadata": {}
}

Update the information for a bank link for an account. The unique bank_link_id must be provided. To obtain the appropriate bank_link_id, use the GET /bank_link endpoint to view all the bank links defined for your tenant and their current information. The details to be updated must also be provided. The endpoint returns the bank_link_id and all of the details for the bank link. If you wish to have a bank link be no longer available for use without permanently deleting it entirely, then use this endpoint to update the is_active field to false.

HTTP REQUEST

PUT /bank_link/{bank_link_id}

Example Request

curl -X DELETE -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/bank_link/d787cf19-d11c-49f2-abf3-f5fec1b101d4"
api_instance = nucleus_api.FundingApi(nucleus_api.ApiClient(configuration))
# # Delete a BankLink
bankl_id = '0de21665-f284-426d-a16d-300a3399f590'
try:
    api_instance.delete_bank_link_using_delete(bankl_id)
except ApiException as e:
    print("Exception when delete_bank_link_using_delete: %s\n" % e)
FundingApi apiInstance = new FundingApi();
        // Delete a BankLink
        try {
            BankLink deleteresponse = apiInstance.deleteBankLinkUsingDelete(UUID.fromString("305d4dd9-0c1e-4230-9d26-d459957ece09"));
            System.out.println(deleteresponse);
        } catch (ApiException e) {
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\FundingApi(
    new GuzzleHttp\Client(),
    $config);
//Delete bankLink
$banklink_did = "9f23be21-b960-457c-95c7-ac5f8725ab9d"; // string | UUID account_id

try {
    $apiInstance->deleteBankLinkUsingDelete($banklink_did);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->deleteBankLinkUsingDelete: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::FundingApi.new
#Delete BankLink
banklink1_id = 'd71792e1-334b-4aea-89d7-2e8d84cbfc39'
begin
  result = api_instance.delete_bank_link_using_delete(banklink1_id)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->delete_bank_link_using_delete: #{e}"
end
var apiInstance = new HydrogenNucleusApi.FundingApi();
// // //Delete a BankLink
var banklinkd = "097cad0f-30d3-4394-a219-479c185285c8";


var deletebanklink = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully.');
    }
};
apiInstance.deleteBankLinkUsingDelete(banklinkd, deletebanklink)

Response (204 No Content)

Permanently delete a bank link defined for an account. The unique bank_link_id must be provided. To obtain the appropriate bank_link_id, use the GET /bank_link endpoint to view all the bank links defined for your tenant. This will delete the bank_link_id and the associated information so that the bank link can no longer be used. If you wish to have the bank link be no longer available for use without permanently deleting it entirely, then use the PUT /bank_link/{bank_link_id} endpoint to update the is_active field to mark the bank_link_id as inactive.

HTTP REQUEST

DELETE /bank_link/{bank_link_id}

Funding Requests

Funding records represent requests to move money to/from a client’s account. All funding transactions, and transfers to/from the account will always be connected to a funding request.

Field Type Description
id UUID The id for the specific funding request
currency_code string Alphabetic currency code for the request, limited to 3 characters. See currency codes
amount double Amount that is included in the funding request
threshold_amount double Amount set for a threshold to perform the funding request, such as an auto reload
account_id UUID The id for the account that will be submitting the funding request
receiving_account_id UUID The id for the account that will be receiving the funding request
business_id UUID The id for the business that will be initiating the funding request
card_id UUID The id for the card that will be receiving the funding request
description string Description for the request, such as “Initial Funding”
bank_link_id UUID In the case that the funding request relates to a specific bank link, the id of the bank link providing the funds for the funding request
receiving_bank_link_id UUID In the case that the funding request is sending money to another bank link, the id of the bank link
transfer_id UUID In the case that the funding request relates to the transfer of an external account into the account, the id of the transfer
portfolio_id UUID In the case that the funding request relates to a specific portfolio, the id of the portfolio where the funds are moving from
receiving_portfolio_id UUID In the case that the funding request relates to a specific portfolio, the id of the portfolio where the funds are moving to
support_ticket_id UUID DEPRECATED In the case that the funding request is attached to a Support Ticket, the id of the ticket
funding_type string The type of the funding transaction. Value may be bank_transfer, wire_transfer, cash, debit_card, credit_card, card_load, check, stock_certificate, digital_wallet, money_order, account_transfer, or other
transfer_type string Type of request if a bank_transfer. Value may be push or pull
transfer_speed string Speed of request if a bank_transfer. Value may be real_time, same_day, next_day, or standard
funding_status string Status of the funding request. Value may be received, initiated, processing, declined, cancelled, or completed.
frequency_unit string Frequency of the funding request. Value may be auto, one_time, daily, weekly, monthly, quarterly, or annually
frequency integer Number of frequency_unit between each request. For example, if the frequency_unit is weekly and the frequency is 2, this means the funding request occurs every two weeks. Default is 1
start_date date The date that the funding request should start
end_date date In the case that the funding request is recurring, the date that the funding request should stop occurring
last_request_date date The last date a recurring deposit or withdrawal was made to/from an account
next_request_date date The next date a recurring deposit or withdrawal is scheduled to/from an account
is_deposit boolean Indicator if the funding request is a deposit. true indicates it is a deposit, false a withdrawal
is_active boolean Indicates if the funding request is currently active. Defaults to true which indicates it is active
metadata map Custom information associated with the funding request in the format key:value. See Metadata
secondary_id string Alternate id that can be used to identify the object such as an internal id
create_date timestamp Timestamp for the date and time that the record was created
update_date timestamp Timestamp for the date and time that the record was last updated

List all funding requests

Example Request

curl -X GET -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/funding"
FundingApi apiInstance = new FundingApi();
        try {
            PageFunding List = apiInstance.getFundingAllUsingGet(true, null, null, null, 0, 10);
            System.out.println(List);
        } catch (ApiException e) {
            System.err.println("Exception when calling getFundingAllUsingGet");
            e.printStackTrace();
        }
api_instance = nucleus_api.FundingApi(nucleus_api.ApiClient(configuration))
try:
    api_response = api_instance.get_funding_all_using_get()
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_funding_all_using_get: %s\n" % e)
$apiInstance = new com\hydrogen\nucleus\Api\FundingApi(
    new GuzzleHttp\Client(),
    $config);
$ascending = false; // bool | ascending
$currency_conversion = null; // string | currency_conversion
$filter = null; // string | filter
$order_by = null; // string | order_by
$page = 0; // int | page
$size = 10; // int | size

try {
    $fundinglist = $apiInstance->getFundingAllUsingGet($ascending, $currency_conversion, $filter, $order_by, $page, $size);
    print_r($fundinglist);
} catch (Exception $e) {
    echo 'Exception when calling FundingApi->getFundingAllUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::FundingApi.new
opts = {
    ascending: false, # BOOLEAN | ascending
    currency_conversion: null, # String | currency_conversion
    filter: null, # String | filter
    order_by: null, # String | order_by
    page: 0, # Integer | page
    size: 25 # Integer | size
}

begin
  result = api_instance.get_funding_all_using_get(opts)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling FundingApi->get_funding_all_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.FundingApi();
var opts = {
    'ascending': false, // Boolean | ascending
    // 'filter': "", // String | filter
    'orderBy': "update_date", // String | order_by
    'page': 0, // Number | page
    'size': 25 // Number | size
};

var fundinglist = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.getFundingAllUsingGet(opts, fundinglist)

Example Response

{
    "content": [
    {
        "id": "708689ce-b0fd-4062-9954-6c8dd82707cf",
        "create_date": "2018-04-12T17:30:21.000+0000",
        "update_date": "2018-04-13T17:12:46.000+0000",
        "currency_code": "USD",
        "amount": 2000,
        "threshold_amount": null,
        "account_id": "04907eaa-3f33-49be-a35b-378cdf639fba",
        "receiving_account_id": "null",
        "business_id": null,
        "card_id": null,
        "bank_link_id": null,
        "receiving_bank_link_id": null,
        "portfolio_id": null,
        "receiving_portfolio_id": null,
        "description": "recurring funding",
        "frequency_unit": "one_time",
        "start_date": "2018-01-01",
        "end_date": "2019-01-01",
        "is_active": true,
        "is_deposit": true,
        "funding_type": "bank_transfer",
        "transfer_type": "push",
        "transfer_speed": "standard",
        "funding_status": "completed",
        "frequency": 2,
        "metadata": {}
    },
    {
        "id": "43a983e7-c930-443b-a499-53767814b07d",
        "create_date": "2018-03-19T16:06:47.000+0000",
        "update_date": "2018-03-19T16:06:47.000+0000",
        "currency_code": "USD",
        "amount": 2000,
        "threshold_amount": null,
        "account_id": "fbc03484-08e8-446d-83aa-6d6cc236355e",
        "receiving_account_id": "null",
        "business_id": null,
        "card_id": null,
        "bank_link_id": null,
        "receiving_bank_link_id": null,
        "portfolio_id": null,
        "receiving_portfolio_id": null,
        "frequency_unit": "monthly",
        "support_ticket_id": null,
        "start_date": "2018-01-01",
        "is_active": true,
        "is_deposit": true,
        "funding_type": "bank_transfer",
        "transfer_type": "push",
        "transfer_speed": "standard",
        "funding_status": "completed",
        "frequency": 2,
        "metadata": {}
    },
    {
        "id": "9f5d3254-95c5-4c9d-8fad-f47c801bb888",
        "create_date": "2018-02-28T21:58:26.000+0000",
        "update_date": "2018-03-19T16:05:40.000+0000",
        "currency_code": "USD",
        "amount": 2000,
        "threshold_amount": null,
        "account_id": "fbc03484-08e8-446d-83aa-6d6cc236355e",
        "receiving_account_id": "null",
        "business_id": null,
        "card_id": null,
        "bank_link_id": null,
        "receiving_bank_link_id": null,
        "portfolio_id": null,
        "receiving_portfolio_id": null,
        "frequency_unit": "monthly",
        "start_date": "2018-01-01",
        "is_active": true,
        "is_deposit": true,
        "funding_type": "bank_transfer",
        "transfer_type": "pull",
        "transfer_speed": "standard",
        "funding_status": "completed",
        "frequency": 2,
        "metadata": {}
    }
    ],
    "last": true,
    "total_elements": 3,
    "total_pages": 1,
    "first": true,
    "sort": [
        {
            "direction": "DESC",
            "property": "updateDate",
            "ignore_case": false,
            "null_handling": "NATIVE",
            "ascending": false,
            "descending": true
        }
    ],
    "number_of_elements": 3,
    "size": 25,
    "number": 0
}

Get the information for all funding requests defined for your tenant. You can filter using an account_id to return the funding requests for a specific account. Note that the metadata information is stored as a nested object within the order record object.

HTTP REQUEST

GET /funding

Create a funding request

Example Request

curl -X POST -H "Authorization: Bearer <access_token>" \
    -H "Content-Type: application/json" \
    -d '{
            "amount": 2000,
            "currency_code": "USD",
            "account_id": "fbc03484-08e8-446d-83aa-6d6cc236355e",
            "frequency_unit": "monthly",
            "start_date": "2018-01-01",
            "is_active": true,
            "is_deposit": true,
            "funding_type": "bank_transfer",
            "transfer_type": "push",
            "transfer_speed": "standard",
            "funding_status": "completed",
            "frequency": 2
      }' "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/funding"
api_instance = nucleus_api.FundingApi(nucleus_api.ApiClient(configuration))
# # Create a Funding
funding = nucleus_api.Funding(amount="200", currency_code="GBP", receiving_account_id="aa339d0b-2f96-476a-a0db-caca07d69168", card_id="6e660df4-530e-41d4-80fa-1471f0a5e5ef", description="New", frequency_unit="one_time", start_date="2020-10-10", end_date="2020-10-15", is_active="true", is_deposit="false", funding_type="bank_transfer", funding_status="initiated", frequency="1")
try:
    api_response = api_instance.create_funding_using_post(funding)
    pprint(api_response)
except ApiException as e:
    print("create_funding_using_post: %s\n" % e)
FundingApi apiInstance = new FundingApi();
        //Create a Funding
        Funding createfunding = new Funding();
        createfunding.setAmount(100.00);
        createfunding.setCurrencyCode("USD");
        createfunding.setReceivingAccountId(UUID.fromString("aa339d0b-2f96-476a-a0db-caca07d69168"));
        createfunding.setCardId(UUID.fromString("d532512d-bef7-4319-a018-c5955408f420"));
        createfunding.setDescription("One");
        createfunding.setFrequencyUnit("one_time");
        createfunding.setStartDate(date1);
        createfunding.setEndDate(date2);
        createfunding.setIsActive(true);
        createfunding.setIsDeposit(false);
        createfunding.setFundingType("bank_transfer");
        createfunding.setFundingStatus("initiated");
        createfunding.frequency(1);

        try {
            Funding response = apiInstance.createFundingUsingPost(createfunding);
            System.out.println(response);
        } catch (ApiException e) {
            System.err.println("Exception when calling createFundingUsingPost");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\FundingApi(
    new GuzzleHttp\Client(),
    $config);
//Create Funding
$funding = new \com\hydrogen\nucleus\Model\Funding();

try {
    $funding->setReceivingAccountId("aa339d0b-2f96-476a-a0db-caca07d69168");
    $funding->setCardId("d532512d-bef7-4319-a018-c5955408f420");
    $funding->setAmount("100");
    $funding->setCurrencyCode("USD");
    $funding->setDescription("New");
    $funding->setFrequencyUnit("one_time");
    $funding->setStartDate("2020-10-10");
    $funding->setEndDate("2020-10-15");
    $funding->setIsActive("true");
    $funding->setIsDeposit("false");
    $funding->setFundingType("bank_transfer");
    $funding->setFundingStatus("initiated");
    $funding->setFrequency("1");

    $result = $apiInstance->createFundingUsingPost($funding);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->createFundingUsingPost: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::FundingApi.new
#Create Funding
funding = NucleusApi::Funding.new

begin
  funding.receiving_account_id = "aa339d0b-2f96-476a-a0db-caca07d69168"
  funding.account_id = "d532512d-bef7-4319-a018-c5955408f420"
  funding.amount = "500"
  funding.currency_code = "GBP"
  funding.description = "New"
  funding.frequency_unit = "one_time"
  funding.start_date = "2020-10-10"
  funding.end_date = "2020-10-16"
  funding.is_active = "true"
  funding.is_deposit = "true"
  funding.funding_type = "bank_transfer"
  funding.funding_status = "started"
  funding.frequency = "1"
  result = api_instance.create_funding_using_post(funding)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->create_funding_using_post: #{e}"
end
var apiInstance = new HydrogenNucleusApi.FundingApi();
Create a Funding
var funding = new HydrogenNucleusApi.Funding();
funding.receiving_account_id = 'aa339d0b-2f96-476a-a0db-caca07d69168';
funding.card_id = 'd532512d-bef7-4319-a018-c5955408f420';
funding.description = "uyt";
funding.frequency_unit = "one_time";
funding.start_date = "2020-09-10";
funding.end_date = "2020-10-10";
funding.is_active = "true";
funding.is_deposit = "true";
funding.funding_type = "bank_transfer";
funding.funding_status = "initiated";
funding.frequency = "1";

var newfunding = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.createFundingUsingPost(funding, newfunding)

Example Response

{
    "id": "9f5d3254-95c5-4c9d-8fad-f47c801bb888",
    "create_date": "2018-02-28T21:58:26.000+0000",
    "currency_code": "USD",
    "amount": 2000,
    "threshold_amount": null,
    "account_id": "fbc03484-08e8-446d-83aa-6d6cc236355e",
    "receiving_account_id": "null",
    "business_id": null,
    "card_id": null,
    "bank_link_id": null,
    "receiving_bank_link_id": null,
    "portfolio_id": null,
    "receiving_portfolio_id": null,
    "frequency_unit": "monthly",
    "start_date": "2018-01-01",
    "is_active": true,
    "is_deposit": true,
    "funding_type": "bank_transfer",
    "transfer_type": "push",
    "transfer_speed": "standard",
    "funding_status": "completed",
    "frequency": 2,
    "metadata": {}
}

Create a new funding request for an account. The unique account_id must be provided. To obtain the appropriate account_id, use the GET /account endpoint to view all the accounts defined for your tenant. The create_date will default to the current date. The endpoint returns a funding_id used to manage the funding request. Note that the metadata information is stored as a nested object within the order record object.

HTTP REQUEST

POST /funding

ARGUMENTS

Parameter Type Required Description
account_id UUID required, conditional The id for the account that will be receiving the funding request
receiving_account_id UUID required, conditional The id for the account that will be receiving the funding request
bank_link_id UUID required, conditional In the case that the funding request relates to a specific bank link, the id of the bank link providing the funds for the funding request
receiving_bank_link_id UUID required, conditional In the case that the funding request is sending money to another bank link, the id of the bank link
portfolio_id UUID required, conditional In the case that the funding request relates to a specific portfolio, the id of the portfolio where the funds are moving from
receiving_portfolio_id UUID required, conditional In the case that the funding request relates to a specific portfolio, the id of the portfolio where the funds are moving to
funding_type string required The type of the funding transaction. Value may be bank_transfer, wire_transfer, cash, debit_card, credit_card, card_load, check, stock_certificate, digital_wallet, money_order, account_transfer, or other
funding_status string required Status of the funding request. Value may be received, initiated, processing, declined, cancelled, or completed.
frequency_unit string required Frequency of the funding request. Value may be auto, one_time, daily, weekly, monthly, quarterly, or annually
is_deposit boolean required Indicates if the funding request is a deposit. true indicates it is a deposit, false a withdrawal
start_date date required The date that the funding request should start
end_date date optional In the case that the funding request is recurring, the date that the funding request should stop occurring
last_request_date date optional The last date a recurring deposit or withdrawal was made to/from an account
next_request_date date optional The next date a recurring deposit or withdrawal is scheduled to/from an account
frequency integer optional Number of frequency_unit between each request. For example, if the frequency_unit is weekly and the frequency is 2, this means the funding request occurs every two weeks. Default is 1
description string optional Description for the request, such as “Initial Funding”
currency_code string optional Alphabetic currency code for the request, limited to 3 characters. See currency codes
amount double optional Amount that is included in the funding request
threshold_amount double optional Amount set for a threshold to perform the funding request, such as an auto reload
business_id UUID optional The id for the business that will be initiating the funding request
card_id UUID optional The id for the card that will be receiving the funding request
transfer_id UUID optional In the case that the funding request relates to the transfer of an external account into the account, the id of the transfer
support_ticket_id UUID optional DEPRECATED In the case that the funding request is attached to a Support Ticket, the id of the ticket
is_active boolean optional Indicates if the funding request is currently active. Defaults to true which indicates it is active.
transfer_type string optional Type of request if a bank_transfer. Value may be push or pull
transfer_speed string optional Speed of request if a bank_transfer. Value may be real_time, same_day, next_day, or standard
metadata map optional Custom information associated with the funding request in the format key:value. See Metadata
secondary_id string optional Alternate id that can be used to identify the object such as an internal id

Retrieve a funding request

Example Request

curl -X GET -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/funding/9f5d3254-95c5-4c9d-8fad-f47c801bb888"
FundingApi apiInstance = new FundingApi();
        try {
            Funding responseFunding = apiInstance.getFundingUsingGet(UUID.fromString("7757d65d-c42f-4ff4-afeb-08885b7ff513"), null);
            System.out.println(responseFunding);
        } catch (ApiException e) {
            System.err.println("Exception when calling getFundingUsingGet");
            e.printStackTrace();
        }
api_instance = nucleus_api.FundingApi(nucleus_api.ApiClient(configuration))
try:
    api_response = api_instance.get_funding_using_get("fc935c5b-9d05-42bf-b126-f1e7cb8bfa52")
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_funding_using_get: %s\n" % e)
$apiInstance = new com\hydrogen\nucleus\Api\FundingApi(
    new GuzzleHttp\Client(),
    $config);
$funding_id = "7757d65d-c42f-4ff4-afeb-08885b7ff513"; // string | UUID funding_id
$currency_conversion = null; // string | USD

try {
    $funding = $apiInstance->getFundingUsingGet($funding_id, $currency_conversion);
    print_r($funding);
} catch (Exception $e) {
    echo 'Exception when calling FundingApi->getFundingUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::FundingApi.new
funding_id = '7757d65d-c42f-4ff4-afeb-08885b7ff513' # String | UUID funding_id

opts = {
    currency_conversion: null, # String | USD
}

begin
  funding = api_instance.get_funding_using_get(funding_id, opts)
  p funding
rescue NucleusApi::ApiError => e
  puts "Exception when calling FundingApi->get_funding_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.FundingApi();
var fundingID = "7757d65d-c42f-4ff4-afeb-08885b7ff513";

var opts = {
    'currencyConversion': null, // String | USD
};


var funding = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.getFundingUsingGet(fundingID, opts, funding)

Example Response

{
    "id": "9f5d3254-95c5-4c9d-8fad-f47c801bb888",
    "create_date": "2018-02-28T21:58:26.000+0000",
    "update_date": "2018-03-19T16:05:40.000+0000",
    "currency_code": "USD",
    "amount": 2000,
    "threshold_amount": null,
    "account_id": "fbc03484-08e8-446d-83aa-6d6cc236355e",
    "receiving_account_id": "null",
    "portfolio_id": null,
    "receiving_portfolio_id": null,
    "business_id": null,
    "card_id": null,
    "bank_link_id": null,
    "receiving_bank_link_id": null,
    "frequency_unit": "monthly",
    "start_date": "2018-01-01",
    "is_active": true,
    "is_deposit": true,
    "funding_type": "bank_transfer",
    "transfer_type": "push",
    "transfer_speed": "standard",
    "funding_status": "completed",
    "frequency": 2,
    "metadata": {}
}

Retrieve the information for a funding request for an account. The unique funding_id must be provided. The endpoint returns the details for the funding request specified.

HTTP REQUEST

GET /funding/{funding_id}

Update a funding request

Example Request

curl -X PUT -H "Authorization: Bearer <access_token>" \
     -H "Content-Type: application/json" \
     -d '{
          "amount": 2000,
          "account_id": "fbc03484-08e8-446d-83aa-6d6cc236355e",
          "frequency_unit": "monthly",
          "start_date": "2018-01-01",
          "is_active": true,
          "is_deposit": true,
          "funding_type": "bank_transfer",
      "transfer_type": "push",
          "funding_status": "completed",
          "frequency": 2
        }' "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/funding/9f5d3254-95c5-4c9d-8fad-f47c801bb888"
api_instance = nucleus_api.FundingApi(nucleus_api.ApiClient(configuration))
# # Update a Funding
funding_update = {'balance': '1000'}
funding_id = '304aa4a1-f700-44f2-bd80-ba671cb7bc13'
try:
    api_response = api_instance.update_funding_using_put(funding_update, funding_id)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling update_funding_using_put: %s\n" % e)
FundingApi apiInstance = new FundingApi();
        //Update a Funding
        Map map2 = new HashMap();
        map2.put("currency_code", "CAD");

        try {
            Funding response = apiInstance.updateFundingUsingPut(map2, UUID.fromString("4eb240c1-b364-4e36-a2bb-cc1029b61bf6"));
            System.out.println(response);
        } catch (ApiException e) {
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\FundingApi(
    new GuzzleHttp\Client(),
    $config);
//Update Funding
$funding_update = new stdClass();
$funding_id = "06846d00-e806-4cda-849f-6ee06d003f8f";

try {
    $funding_update->funding_status = "started";
    $result = $apiInstance->updateFundingUsingPut($funding_update, $funding_id);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->updateFundingUsingPut: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::FundingApi.new
#Update Funding
funding_update = {"currency_code" => 'CAD'}
funding_id = '1c02f05a-0b24-4a74-aaf9-dcea175ce6ab'
begin
  result = api_instance.update_funding_using_put(funding_update, funding_id)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->update_funding_using_put: #{e}"
end
var apiInstance = new HydrogenNucleusApi.FundingApi();
//Update Funding
var apiInstance = new HydrogenNucleusApi.FundingApi();
var callback = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
var fundingupdate = new HydrogenNucleusApi.Funding();
var fundingid = '55508201-9a8b-4d0f-aa70-2772e6ca6ee2';

fundingupdate.amount = "500";
apiInstance.updateFundingUsingPut(fundingupdate, fundingid, callback)

Example Response

{
    "id": "9f5d3254-95c5-4c9d-8fad-f47c801bb888",
    "create_date": "2018-02-28T21:58:26.000+0000",
    "update_date": "2018-03-19T16:05:40.000+0000",
    "currency_code": "USD",
    "amount": 2000,
    "threshold_amount": null,
    "account_id": "fbc03484-08e8-446d-83aa-6d6cc236355e",
    "receiving_account_id": "null",
    "portfolio_id": null,
    "receiving_portfolio_id": null,
    "business_id": null,
    "card_id": null,
    "bank_link_id": null,
    "receiving_bank_link_id": null,
    "frequency_unit": "monthly",
    "start_date": "2018-01-01",
    "is_active": true,
    "is_deposit": true,
    "funding_type": "bank_transfer",
    "transfer_type": "push",
    "transfer_speed": "standard",
    "funding_status": "completed",
    "frequency": 2,
    "metadata": {}
}

Update the information for a funding request for an account. The unique funding_id must be provided. To obtain the appropriate funding_id, use the GET /funding endpoint to view all funding requests defined for your tenant and their current information. The details to be updated must also be provided. The endpoint returns the funding_id and all of the details for the funding request. If you wish to have the funding request no longer occur without permanently deleting it entirely, then use this endpoint to update the end_date field to the date when you wish the funding request to stop occurring. You can also use this endpoint to change the is_active field to false.

HTTP REQUEST

PUT /funding/{funding_id}

Delete a funding request

Example Request

curl -X DELETE -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/funding/9f5d3254-95c5-4c9d-8fad-f47c801bb888"
api_instance = nucleus_api.FundingApi(nucleus_api.ApiClient(configuration))
# # Delete a Funding
funding_id = '1421ba03-b812-4549-b3f5-57e13601ce94'
try:
    api_instance.delete_funding_using_delete(funding_id)
except ApiException as e:
    print("Exception when delete_funding_using_delete: %s\n" % e)
FundingApi apiInstance = new FundingApi();
       // Delete a Funding
        try {
            Funding deleteresponse = apiInstance.deleteFundingUsingDelete(UUID.fromString("d155b0ed-7705-433b-a518-462881cdfa9b"));
            System.out.println(deleteresponse);
        } catch (ApiException e) {
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\FundingApi(
    new GuzzleHttp\Client(),
    $config);
//Delete Funding
$funding_did = "1c02f05a-0b24-4a74-aaf9-dcea175ce6ab"; // string | UUID account_id

try {
    $apiInstance->deleteFundingUsingDelete($funding_did);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->deleteFundingUsingDelete: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::FundingApi.new
#Delete Funding
funding1_id = 'ac102cb5-c470-4e71-b2d1-93fea0cf81f2'
begin
  result = api_instance.delete_funding_using_delete(funding1_id)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->delete_funding_using_delete: #{e}"
end
var apiInstance = new HydrogenNucleusApi.FundingApi();
// // //Delete a Funding
var fundingd = "dd4aeeb8-8e3b-4d91-9503-a171194336a0";


var deletefunding = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully.');
    }
};
apiInstance.deleteFundingUsingDelete(fundingd, deletefunding)

Response (204 No Content)

Permanently delete a funding request defined for an account. The unique funding_id must be provided. To obtain the appropriate funding_id, use the GET /funding endpoint to view all funding requests for your tenant. Deletes the funding_id and the funding request record. If you wish to have the funding request no longer occur without permanently deleting it entirely, then use the PUT /funding/{funding_id} endpoint to update the end_date field to the date when you wish the funding request to stop occurring. You can also use the PUT /funding/{funding_id} endpoint to change the is_active field to false.

HTTP REQUEST

DELETE /funding/{funding_id}

Funding Transaction

Funding transactions represent transactions related to a funding request. These may either be a deposit into an account, or a withdrawal from an account.

Field Type Description
id UUID The id for the specific funding transaction
account_id UUID The id for the account that is the destination of the transaction. Either an account_id or portfolio_id must be supplied.
portfolio_id UUID In the case that the transaction relates to a specific portfolio, the id of the portfolio where the funds are being deposited or withdrawn. Either an account_id or portfolio_id must be supplied.
currency_code string Alphabetic currency code for the request, limited to 3 characters. See currency codes
amount double Amount that is being deposited or withdrawn
is_deposit boolean Indicates if transaction is a deposit (“true”) or withdrawal (“false”)
funding_id UUID The id of the funding record that maps to this transaction
portfolio_transaction_id UUID In the case that the transaction relates to a specific portfolio, the id of the portfolio transaction
comments string Comment for the transaction such as “Funded”
type string Indicates the payment type such as “check, “wire”, etc.
fees double Any fees associated with the transaction
last_request_date timestamp In the case of recurring deposits or withdrawals, the last date and time requested
received_date timestamp Date and time that the transaction was received into the account
invested_date timestamp Date and time that the funds should be pulled from the funding request to be invested
status string Status of the transaction such as “Processing”. Use this field to track the status of the individual transaction if it is associated with a recurring Funding request
status_time_stamp timestamp Date and time that the status of the record was last updated
metadata map Custom information associated with the entity in the format key:value
See Metadata
secondary_id string Alternate id that can be used to identify the object such as an internal id
create_date timestamp Timestamp for the date and time that the record was created
update_date timestamp Timestamp for the date and time that the record was last updated

List all funding transactions

Example Request

curl -X GET -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/funding_transaction"
api_instance = nucleus_api.FundingApi(nucleus_api.ApiClient(configuration))
# List all FundingTransaction
try:
    api_response = api_instance.get_funding_transaction_all_using_get()
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_funding_transaction_all_using_get: %s\n" % e)
FundingApi apiInstance = new FundingApi();
                //List All FundingTransaction
        try {
            PageFundingTransaction List = apiInstance.getFundingTransactionAllUsingGet(true, null, null, null, 0, 10);
            System.out.println(List);
        } catch (ApiException e) {
            System.err.println("Exception when calling getFundingAllUsingGet");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\FundingApi(
    new GuzzleHttp\Client(),
    $config);
//List all FundingTransaction
$ascending = false; // bool | ascending
$currency_conversion = null; // string | currency_conversion
$filter = null; // string | filter
$order_by = null; // string | order_by
$page = 0; // int | page
$size = 10; // int | size

try {
    $fundingtransaction = $apiInstance->getFundingTransactionAllUsingGet($ascending, $currency_conversion, $filter, $order_by, $page, $size);
    print_r($fundingtransaction);
} catch (Exception $e) {
    echo 'Exception when calling FundingApi->getFundingTransactionAllUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::FundingApi.new
#List all FundingTransaction
opts = {
  ascending: false, # BOOLEAN | ascending
  currency_conversion: null, # String | currency_conversion
  filter: null, # String | filter
  order_by: null, # String | order_by
  page: 0, # Integer | page
  size: 25 # Integer | size
}

begin
  result = api_instance.get_funding_transaction_all_using_get(opts)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling FundingApi->get_funding_transaction_all_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.FundingApi();
//List all Funding Transaction

var opts = {
    'ascending': false, // Boolean | ascending
    // 'filter': "", // String | filter
    'orderBy': "update_date", // String | order_by
    'page': 0, // Number | page
    'size': 25 // Number | size
};

var fundingtrans = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.getFundingTransactionAllUsingGet(opts, fundingtrans)

Example Response

{
  "content": [
        {
            "id": "1a2bb85f-c1b4-41d5-9bf3-e23cce54b71c",
            "create_date": "2018-03-19T16:09:38.000+0000",
            "update_date": "2018-03-19T16:09:38.000+0000",
            "is_deposit": true,
            "currency_code": "USD",
            "amount": 2000,
            "funding_id": "43a983e7-c930-443b-a499-53767814b07d",
            "account_id": "fbc03484-08e8-446d-83aa-6d6cc236355e",
            "portfolio_id": null,
            "portfolio_transaction_id": null,
            "comments": "Add to 2018 IRA",
            "type": null,
            "fees": null,
            "invested_date": "2018-04-02T09:00:00.000+0000",
            "last_request_date": "2018-04-01T09:00:00.000+0000",
            "received_date": "2018-03-01T17:00:00.000+0000",
            "invested_date": null,
            "metadata": {}
        },
        {
            "id": "c1df397e-17c0-4fab-a61f-367f7ff90f57",
            "create_date": "2018-03-19T15:16:50.000+0000",
            "update_date": "2018-03-19T16:08:59.000+0000",
            "is_deposit": true,
            "currency_code": "USD",
            "amount": 2000,
            "funding_id": "43a983e7-c930-443b-a499-53767814b07d",
            "account_id": "fbc03484-08e8-446d-83aa-6d6cc236355e",
            "portfolio_id": null,
            "portfolio_transaction_id": null,
            "comments" : "Add to 2018 IRA",
            "type": null,
            "fees": null,
            "invested_date": "2018-03-02T09:00:00.000+0000",
            "last_request_date": "2018-03-01T09:00:00.000+0000",
            "received_date": "2018-03-01T17:00:00.000+0000",
            "invested_date": null,
            "metadata": {}
        },
        {
            "id": "08e5f077-0c8c-4831-a4cc-3a7a59e067d2",
            "create_date": "2018-03-19T15:16:47.000+0000",
            "update_date": "2018-03-19T15:16:47.000+0000",
            "is_deposit": true,
            "currency_code": "USD",
            "amount": 2000,
            "funding_id": "9f5d3254-95c5-4c9d-8fad-f47c801bb888",
            "account_id": "fbc03484-08e8-446d-83aa-6d6cc236355e",
            "portfolio_id": null,
            "portfolio_transaction_id": null,
            "comments" : "Add to 2018 IRA",
            "type": null,
            "fees": null,
            "invested_date": "2018-02-01T09:00:00.000+0000",
            "last_request_date": "2018-02-01T09:00:00.000+0000",
            "received_date": "2018-02-01T17:00:00.000+0000",
            "invested_date": null,
            "metadata": {}
        }
  ],
  "total_elements": 3,
  "last": true,
  "total_pages": 1,
  "first": true,
  "sort": [
      {
          "direction": "DESC",
          "property": "updateDate",
          "ignore_case": false,
          "null_handling": "NATIVE",
          "ascending": false,
          "descending": true
      }
    ],
    "number_of_elements": 4,
    "size": 25,
    "number": 0
}

Get the information for all funding transactions for all clients. The endpoint returns a list of UUIDs and details for each funding transaction. You can filter using the account_id to view funding transactions for a specific account.

HTTP REQUEST

GET /funding_transaction

Create a funding transaction

Example Request

curl -X POST -H "Authorization: Bearer <access_token>" \
    -H "Content-Type: application/json" \
    -d '{
        "is_deposit": true,
            "amount": 2000,
            "funding_id": "9f5d3254-95c5-4c9d-8fad-f47c801bb888",
            "account_id": "fbc03484-08e8-446d-83aa-6d6cc236355e",
            "comments" : "Add to 2018 IRA",
            "invested_date": "2018-02-01T09:00:00.000+0000",
            "last_request_date": "2018-02-01T09:00:00.000+0000",
            "received_date": "2018-02-01T17:00:00.000+0000"
        }' "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/funding_transaction"
api_instance = nucleus_api.FundingApi(nucleus_api.ApiClient(configuration))
# # Create a FundingTransaction
funding_transaction = nucleus_api.FundingTransaction(account_id="ae66a845-cfe1-4402-9b0a-3aed87b33e29", currency_code="CAD", amount="200", funding_id="03b07b2c-ea6f-44aa-ab7d-4f81d6daa558", is_deposit="true")
try:
    api_response = api_instance.create_funding_transaction_using_post(funding_transaction)
    pprint(api_response)
except ApiException as e:
    print("create_funding_transaction_using_post: %s\n" % e)
FundingApi apiInstance = new FundingApi();
        //Create a Funding Transaction
        FundingTransaction transactionfunding = new FundingTransaction();
        transactionfunding.setAccountId(UUID.fromString("ae66a845-cfe1-4402-9b0a-3aed87b33e29"));
        transactionfunding.setCurrencyCode("USD");
        transactionfunding.setAmount(200.00);
        transactionfunding.setFundingId(UUID.fromString("03b07b2c-ea6f-44aa-ab7d-4f81d6daa558"));
        transactionfunding.setIsDeposit(false);

                try {
            FundingTransaction result = apiInstance.createFundingTransactionUsingPost(transactionfunding);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling createFundingTransactionUsingPost");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\FundingApi(
    new GuzzleHttp\Client(),
    $config);
//Create FundingTransaction
$funding_transaction = new \com\hydrogen\nucleus\Model\FundingTransaction();

try {
    $funding_transaction->setAccountId("ae66a845-cfe1-4402-9b0a-3aed87b33e29");
    $funding_transaction->setFundingId("03b07b2c-ea6f-44aa-ab7d-4f81d6daa558");
    $funding_transaction->setCurrencyCode("USD");
    $funding_transaction->setAmount("200");
    $funding_transaction->setIsDeposit("false");

    $result = $apiInstance->createFundingTransactionUsingPost($funding_transaction);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->createFundingTransactionUsingPost: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::FundingApi.new
#Create Funding Transaction
funding_transaction = NucleusApi::FundingTransaction.new

begin
  funding_transaction.account_id = "ae66a845-cfe1-4402-9b0a-3aed87b33e29"
  funding_transaction.funding_id = "03b07b2c-ea6f-44aa-ab7d-4f81d6daa558"
  funding_transaction.currency_code = "GBP"
  funding_transaction.amount = "400"
  funding_transaction.is_deposit = "false"
  result = api_instance.create_funding_transaction_using_post(funding_transaction)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->create_funding_transaction_using_post: #{e}"
end
var apiInstance = new HydrogenNucleusApi.FundingApi();
//Create a Funding Transaction
var fundingtrans = new HydrogenNucleusApi.FundingTransaction();
fundingtrans.account_id = 'ae66a845-cfe1-4402-9b0a-3aed87b33e29';
fundingtrans.funding_id = '03b07b2c-ea6f-44aa-ab7d-4f81d6daa558';
fundingtrans.currency_code = "GBP";
fundingtrans.amount = "500";
fundingtrans.is_deposit = "true";
var newfundingtrans = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.createFundingTransactionUsingPost(fundingtrans, newfundingtrans)

Example Response

{
    "id": "08e5f077-0c8c-4831-a4cc-3a7a59e067d2",
    "create_date": "2018-03-19T15:16:47.000+0000",
    "is_deposit": true,
    "currency_code": "USD",
    "amount": 2000,
    "funding_id": "9f5d3254-95c5-4c9d-8fad-f47c801bb888",
    "account_id": "fbc03484-08e8-446d-83aa-6d6cc236355e",
    "portfolio_id": null,
    "portfolio_transaction_id": null,
    "comments" : "Add to 2018 IRA",
    "type": null,
    "fees": null,
    "invested_date": "2018-02-01T09:00:00.000+0000",
    "last_request_date": "2018-02-01T09:00:00.000+0000",
    "received_date": "2018-02-01T17:00:00.000+0000",
    "invested_date": null,
    "metadata": {}
}

Create a new funding transaction for an account. The unique account_id for the transaction must be provided. To obtain the appropriate account_id, use the GET /account endpoint to view all the accounts defined for your tenant. The create_date will default to the current date. The endpoint returns a unique funding_transaction_id used to manage the funding transaction.

HTTP REQUEST

POST /funding_transaction

ARGUMENTS

Parameter Type Required Description
account_id UUID required, conditional The id for the account that is the destination of the transaction. Either an account_id or portfolio_id must be supplied.
portfolio_id UUID required, conditional In the case that the transaction relates to a specific portfolio, the id of the portfolio where the funds are being deposited or withdrawn. Either an account_id or portfolio_id must be supplied.
currency_code string required Alphabetic currency code for the request, limited to 3 characters. See currency codes
amount double required Amount that is being deposited or withdrawn
funding_id UUID required The id of the funding record that maps to this transaction
is_deposit boolean required Indicates if transaction is a deposit (“true”) or withdrawal (“false”)
portfolio_transaction_id UUID optional In the case that the transaction relates to a specific portfolio, the id of the portfolio transaction
comments string optional Comment for the transaction such as “Funded”
last_request_date timestamp optional In the case of recurring deposits or withdrawals, the last date and time requested
received_date timestamp optional Date and time that the transaction was received into the account
invested_date timestamp optional Date and time that the funds should be pulled from the funding request to be invested
type string optional Indicates the payment type such as “check, “wire”, etc.
fees double optional Any fees associated with the transaction
status string optional Status of the transaction such as “Processing”. Use this field to track the status of the individual transaction if it is associated with a recurring Funding request
status_time_stamp timestamp optional Date and time that the record was last updated
metadata map optional Custom information associated with the entity in the format key:value
See Metadata
secondary_id string optional Alternate id that can be used to identify the object such as an internal id

Retrieve a funding transaction

Example Request

curl -X GET -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/funding_transaction/08e5f077-0c8c-4831-a4cc-3a7a59e067d2"
api_instance = nucleus_api.FundingApi(nucleus_api.ApiClient(configuration))
# Retrieve a FundingRequest
try:
    api_response = api_instance.get_funding_transaction_using_get("61fff359-6706-4465-a3ee-c1477756199c")
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_funding_transaction_using_get: %s\n" % e)
FundingApi apiInstance = new FundingApi();

                //Retrieve a Funding transaction
        try {
            FundingTransaction responseFunding = apiInstance.getFundingTransactionUsingGet(UUID.fromString("61fff359-6706-4465-a3ee-c1477756199c"), null);
            System.out.println(responseFunding);
        } catch (ApiException e) {
            System.err.println("Exception when calling getFundingTransactionUsingGet");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\FundingApi(
    new GuzzleHttp\Client(),
    $config);
//Retrieve a Funding Transaction
$funding_transfer_id = "61fff359-6706-4465-a3ee-c1477756199c"; // string | UUID external_account_transfer_id
$currency_conversion = null; // string | USD

try {
    $transfer = $apiInstance->getFundingTransactionUsingGet($funding_transfer_id, $currency_conversion);
    print_r($transfer);
} catch (Exception $e) {
    echo 'Exception when calling FundingApi->getFundingTransactionUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::FundingApi.new
#Retrieve a Funding Transaction
funding_trans_id = '2eef0616-0e78-4f0d-8a6b-a7e8634da852' # String | UUID funding_id

opts = {
  currency_conversion: null, # String | USD
}

begin
  funding = api_instance.get_funding_transaction_using_get(funding_trans_id, opts)
  p funding
rescue NucleusApi::ApiError => e
  puts "Exception when calling FundingApi->get_funding_transaction_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.FundingApi();
//Retrieve an FundingTransaction

var funding_transID = "0955402e-f8ed-4782-ae3a-eed6b7c6f55f";

var opts = {
    'currencyConversion': null, // String | USD
};


var fundingtrans = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.getFundingTransactionUsingGet(funding_transID, opts, fundingtrans)

Example Response

{
    "id": "08e5f077-0c8c-4831-a4cc-3a7a59e067d2",
    "create_date": "2018-03-19T15:16:47.000+0000",
    "update_date": "2018-03-19T15:16:47.000+0000",
    "is_deposit": true,
    "funding_id": "9f5d3254-95c5-4c9d-8fad-f47c801bb888",
    "currency_code": "USD",
    "amount": 2000,
    "account_id": "fbc03484-08e8-446d-83aa-6d6cc236355e",
    "portfolio_id": null,
    "portfolio_transaction_id": null,
    "comments" : "Add to 2018 IRA",
    "type": null,
    "fees": null,
    "invested_date": "2018-02-01T09:00:00.000+0000",
    "last_request_date": "2018-02-01T09:00:00.000+0000",
    "received_date": "2018-02-01T17:00:00.000+0000",
    "invested_date": null,
    "metadata": {}
}

Retrieve the information for a funding transaction for an account. The unique funding_transaction_id must be provided. The endpoint returns details for the funding transaction specified.

HTTP REQUEST

GET /funding_transaction/{funding_transaction_id}

Update a funding transaction

Example Request

curl -X PUT -H "Authorization: Bearer <access_token>" \
    -H "Content-Type: application/json" \
    -d '{
            "funding_id": "9f5d3254-95c5-4c9d-8fad-f47c801bb888",
            "amount": 2000,
            "account_id": "fbc03484-08e8-446d-83aa-6d6cc236355e",
            "comments" : "Add to 2018 IRA",
            "invested_date": "2018-02-01T09:00:00.000+0000",
            "last_request_date": "2018-02-01T09:00:00.000+0000",
            "received_date": "2018-02-01T17:00:00.000+0000"
        }' "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/funding_transaction/08e5f077-0c8c-4831-a4cc-3a7a59e067d2"
api_instance = nucleus_api.FundingApi(nucleus_api.ApiClient(configuration))
# # Update a FundingTransaction
funding_transaction_update = {'currency_code': 'EUR'}
funding_transaction_id = 'bc74d105-0eb7-4ed5-b261-15cd0826c73d'
try:
    api_response = api_instance.update_funding_transaction_using_put(funding_transaction_id)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling update_funding_transaction_using_put: %s\n" % e)
FundingApi apiInstance = new FundingApi();

        //Update a FundingTransaction
        Map map3 = new HashMap();
        map2.put("amount", "600");

        try {
            FundingTransaction response = apiInstance.updateFundingTransactionUsingPut(map2, UUID.fromString("0955402e-f8ed-4782-ae3a-eed6b7c6f55f"));
            System.out.println(response);
        } catch (ApiException e) {
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\FundingApi(
    new GuzzleHttp\Client(),
    $config);

//Update FundingTransaction
$fundingtrans_update = new stdClass();
$fundingtrans_id = "5f8809ff-a814-427c-91ff-6ca70de2e2d3";

try {
    $fundingtrans_update->amount = "666";
    $result = $apiInstance->updateFundingTransactionUsingPut($fundingtrans_update, $fundingtrans_id);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->updateFundingTransactionUsingPut: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::FundingApi.new
#Update FundingTransaction
funding_transaction_update = {"currency_code" => 'CAD'}
funding_transaction_id = '5f8809ff-a814-427c-91ff-6ca70de2e2d3'
begin
  result = api_instance.update_funding_transaction_using_put(funding_transaction_update, funding_transaction_id)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->update_funding_transaction_using_put: #{e}"
end
var apiInstance = new HydrogenNucleusApi.FundingApi();
//Update Funding
var apiInstance = new HydrogenNucleusApi.FundingApi();
var callback = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
var fundingtransupdate = new HydrogenNucleusApi.Funding();
var fundingtransid = 'd08094cd-31db-443c-83ea-0b11adfa22ce';

fundingtransupdate.currency_code = "GBP";
apiInstance.updateFundingTransactionUsingPut(fundingtransupdate, fundingtransid, callback)

Example Response

{
    "id": "08e5f077-0c8c-4831-a4cc-3a7a59e067d2",
    "create_date": "2018-03-19T15:16:47.000+0000",
    "update_date": "2018-03-19T15:16:47.000+0000",
    "is_deposit": true,
    "funding_id": "9f5d3254-95c5-4c9d-8fad-f47c801bb888",
    "currency_code": "USD",
    "amount": 2000,
    "account_id": "fbc03484-08e8-446d-83aa-6d6cc236355e",
    "portfolio_id": null,
    "portfolio_transaction_id": null,
    "comments" : "Add to 2018 IRA",
    "type": null,
    "fees": null,
    "invested_date": "2018-02-01T09:00:00.000+0000",
    "last_request_date": "2018-02-01T09:00:00.000+0000",
    "received_date": "2018-02-01T17:00:00.000+0000",
    "invested_date": null,
    "metadata": {}
}

Update the information for a funding transaction for an account. The unique funding_transaction_id must be provided. To obtain the appropriate funding_transaction_id, use the GET /funding_transaction endpoint to view all the bank links defined for your tenant and their current information. The details to be updated must also be provided. The endpoint returns the funding_transaction_id and all of the details for the funding transaction.

HTTP REQUEST

PUT /funding_transaction/{funding_transaction_id}

Delete a funding transaction

Example Request

curl -X DELETE -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/funding_transaction/08e5f077-0c8c-4831-a4cc-3a7a59e067d2"
api_instance = nucleus_api.FundingApi(nucleus_api.ApiClient(configuration))
# # # Delete a FundingTransaction
funding_trans_id = '746e3d85-bac2-4411-ba76-25c34e4ca6e7'
try:
    api_instance.delete_funding_transaction_using_delete(funding_trans_id)
except ApiException as e:
    print("Exception when delete_funding_transaction_using_delete: %s\n" % e)
FundingApi apiInstance = new FundingApi();

        //Delete a FundingTransaction
        try {
            FundingTransaction deleteresponse = apiInstance.deleteFundingTransactionUsingDelete(UUID.fromString("563a0759-9b20-44db-bb65-0c2d89c1c6b1"));
            System.out.println(deleteresponse);
        } catch (ApiException e) {
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\FundingApi(
    new GuzzleHttp\Client(),
    $config);
//Delete FundingTransaction
$funding_did = "ed883768-b35c-474d-bba6-c7864f4ff4a2"; // string | UUID account_id

try {
    $apiInstance->deleteFundingTransactionUsingDelete($funding_did);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->deleteFundingTransactionUsingDelete: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::FundingApi.new
#Delete Funding Transaction
funding_transaction1_id = 'ed883768-b35c-474d-bba6-c7864f4ff4a2'
begin
  result = api_instance.delete_funding_transaction_using_delete(funding_transaction1_id)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->delete_funding_transaction_using_delete: #{e}"
end
var apiInstance = new HydrogenNucleusApi.FundingApi();
// // // //Delete a FundingTransaction
var fundingtransd = "ab727815-c6e9-4d42-ab2e-ccb5d6b8b02c";


var deletefundingtrans = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully.');
    }
};
apiInstance.deleteFundingTransactionUsingDelete(fundingtransd, deletefundingtrans)

Response (204 No Content)

Permanently delete a funding transaction for an account. The unique funding_transaction_id must be provided. To obtain the appropriate funding_transaction_id, use the GET /funding_transaction endpoint to view all funding transactions defined for your tenant. This deletes the funding_transaction_id and funding transaction record.

HTTP REQUEST

DELETE /funding_transaction/{funding_transaction_id}

Transfer

External account transfer represent links between an external account (ex. an external retirement investing account such as a Roth IRA) to a client account on your firm’s platform to transfer funds or existing holdings. External account transfers are used for funding purposes similar to bank links.

Field Type Description
id UUID The id for the specific transfer
account_id UUID The id of the account to which the transfer belongs
account_holder string Name of the individual that is the owner of the external account
account_number string Account number for the external account that is the source of the funds
account_type_id UUID The id for the type of the account on your platform
firm_name string Name of the firm that previously held or holds the external account
transfer_all_cash boolean Indicator if the external account should be entirely converted to cash to be transferred.
amount double Amount that is transferred
currency_code string Alphabetic currency code for the request, limited to 3 characters. See currency codes
comment string Comment for the transfer such as “Funded”
dtc_number string Number of the Deposit Trust Company (DTC)’s that held or holds the external account usually in the case of an Individual Retirement Account (IRA) in the United States
roth_five_year integer In the case that the account is a United States Roth IRA account, the year it was opened (e.g. 2010)
status string Status of the transfer such as “Pending”
status_time_stamp timestamp Timestamp for the date and time that the status was last updated
transfer_type string Type of transfer being made. Value may be partial or full
transfer_date date Date that the transfer will be initiated. Defaults to the current date
received_date timestamp Timestamp for the date and time that the transfer was received
metadata map Custom information associated with the entity in the format key:value
See Metadata
secondary_id string Alternate id that can be used to identify the object such as an internal id
create_date timestamp Timestamp for the date and time that the record was created
update_date timestamp Timestamp for the date and time that the record was last updated

List all transfer requests

Example Request

curl -X GET -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/transfer"
FundingApi apiInstance = new FundingApi();
        try {
            PageExternalAccountTransfer List = apiInstance.getTransferAllUsingGet(true, null, null, null, 0, 10);
            System.out.println(List);
        } catch (ApiException e) {
            System.err.println("Exception when calling getTransferAllUsingGet");
            e.printStackTrace();
        }
api_instance = nucleus_api.FundingApi(nucleus_api.ApiClient(configuration))
try:
    api_response = api_instance.get_transfer_all_using_get()
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_transfer_all_using_get: %s\n" % e)
$apiInstance = new com\hydrogen\nucleus\Api\FundingApi(
    new GuzzleHttp\Client(),
    $config);
$currency_conversion = null; // string | currency_conversion
$filter = null; // string | filter
$order_by = null; // string | order_by
$page = 0; // int | page
$size = 10; // int | size

try {
    $transferlist = $apiInstance->getTransferAllUsingGet($ascending, $currency_conversion, $filter, $order_by, $page, $size);
    print_r($transferlist);
} catch (Exception $e) {
    echo 'Exception when calling FundingApi->getTransferAllUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::FundingApi.new
opts = {
    ascending: false, # BOOLEAN | ascending
    currency_conversion: null, # String | currency_conversion
    filter: null, # String | filter
    order_by: null, # String | order_by
    page: 0, # Integer | page
    size: 25 # Integer | size
}

begin
  transferlist = api_instance.get_transfer_all_using_get(opts)
  p transferlist
rescue NucleusApi::ApiError => e
  puts "Exception when calling FundingApi->get_transfer_all_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.FundingApi();
var opts = {
    'ascending': false, // Boolean | ascending
    // 'filter': "", // String | filter
    'orderBy': "update_date", // String | order_by
    'page': 0, // Number | page
    'size': 25 // Number | size
};

var transferlist = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.getTransferAllUsingGet(opts, transferlist)

Example Response

{
    "content": [
        {
            "id": "111d714c-1d1c-47cf-9cb7-760428e86c24",
            "transfer_date": "2019-03-21",
            "create_date": "2018-04-09T21:02:11.000+0000",
            "update_date": "2018-04-09T21:02:11.000+0000",
            "account_holder": "JB Smith",
            "account_number": "5889632503",
            "currency_code": "USD",
            "amount": 13000,
            "comment": "Closed down previous 401k",
            "firm_name": "Vanguard",
            "status": "Pending",
            "status_time_stamp": "2018-04-09T21:02:11.000+0000",
            "transfer_all_cash": true,
            "transfer_type": "full",
            "account_id": "099961da-7f41-4309-950f-2b51689a0033",
            "account_type_id": "647c54c3-b649-477e-8cc7-eee56a120dd3",
            "metadata": {}
        },
        {
            "id": "1b19a750-f3c6-46e7-9131-fe11f06314ea",
            "transfer_date": "2018-04-08",
            "received_date": "2018-04-09T20:52:07.000+0000",
            "create_date": "2018-04-09T20:52:07.000+0000",
            "update_date": "2018-04-09T20:52:07.000+0000",
            "account_holder": "John Smith",
            "account_number": "5889632592",
            "currency_code": "USD",
            "amount": 13000,
            "comment": "Closed down previous 401k",
            "firm_name": "Vanguard",
            "status": "Pending",
            "transfer_all_cash": true,
            "transfer_type": "full",
            "account_id": "04907eaa-3f33-49be-a35b-378cdf639fba",
            "account_type_id": "eb3d7f60-a133-4ca9-815f-3677bcdc23a3",
            "metadata": {}
        },
        {
            "id": "93197309-ff29-458a-ac9d-ad24ac2d95c9",
            "transfer_date": "2018-04-08",
            "received_date": "2018-04-09T20:29:04.000+0000",
            "create_date": "2018-04-09T20:29:04.000+0000",
            "update_date": "2018-04-09T20:29:04.000+0000",
            "account_holder": "Dan Lars",
            "account_number": "6009632590",
            "currency_code": "USD",
            "amount": 34000,
            "comment": "Closed down previous 401k",
            "firm_name": "Vanguard",
            "status": "Pending",
            "transfer_all_cash": true,
            "account_id": "107516c3-9035-4811-af7c-501be5a1fe26",
            "account_type_id": "39770e8d-890d-485b-822e-5a1578f26d47",
            "metadata": {}
        }
    ],
    "total_elements": 3,
    "last": true,
    "total_pages": 1,
    "first": true,
    "sort": [
        {
            "direction": "DESC",
            "property": "updateDate",
            "ignore_case": false,
            "null_handling": "NATIVE",
            "ascending": false,
            "descending": true
        }
    ],
    "number_of_elements": 5,
    "size": 25,
    "number": 0
}

Get the information for all external account transfers defined for your tenant. The endpoint returns a list of UUIDs and details for each external account transfer. You can filter by account_id to view external account transfers for a specific account.

HTTP REQUEST

GET /transfer

Create a transfer request

Example Request

curl -X POST -H "Authorization: Bearer <access_token>" \
  -H "Content-Type: application/json" \
  -d '{
        "account_holder": "JB Smith",
        "account_number": "5889632503",
        "currency_code": "USD",
        "amount": 13000,
        "comment": "Closed down previous 401k",
        "firm_name": "Vanguard",
        "dtc_number" : "345928204",
        "status": "Pending",
        "status_time_stamp": "2018-04-09T21:02:11.000+0000",
        "transfer_all_cash": true,
        "transfer_type": "full",
        "transfer_date": "2019-03-21",
        "account_id": "099961da-7f41-4309-950f-2b51689a0033",
        "account_type_id": "647c54c3-b649-477e-8cc7-eee56a120dd3"
     }' "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/transfer"
api_instance = nucleus_api.FundingApi(nucleus_api.ApiClient(configuration))
# Create a Transfer
transfer = nucleus_api.ExternalAccountTransfer(account_id="f94301e6-2946-4406-9959-b793ec96bea5", account_holder="one A", account_number="56548775", account_type_id="9c36f92e-89f0-4209-9d1c-6f102b5f6509", firm_name="new Firm", transfer_all_cash="false", transfer_date="2020-10-10")
try:
    api_response = api_instance.create_transfer_using_post(transfer)
    pprint(api_response)
except ApiException as e:
    print("create_transfer_using_post: %s\n" % e)
FundingApi apiInstance = new FundingApi();
        //Create a Transfer
        ExternalAccountTransfer transfer = new ExternalAccountTransfer();
        transfer.setAccountId(UUID.fromString("f94301e6-2946-4406-9959-b793ec96bea5"));
        transfer.setAccountHolder("One A");
        transfer.setAccountNumber("575866");
        transfer.setAccountTypeId(UUID.fromString("9c36f92e-89f0-4209-9d1c-6f102b5f6509"));
        transfer.setFirmName("abc");
        transfer.setTransferAllCash(false);
        transfer.setTransferDate(date1);

        try {
            ExternalAccountTransfer result = apiInstance.createTransferUsingPost(transfer);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling createTransferUsingPost");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\FundingApi(
    new GuzzleHttp\Client(),
    $config);
//Create Transfer
$transfer = new \com\hydrogen\nucleus\Model\ExternalAccountTransfer();

try {
    $transfer->setAccountId("f94301e6-2946-4406-9959-b793ec96bea5");
    $transfer->setAccountTypeId("9c36f92e-89f0-4209-9d1c-6f102b5f6509");
    $transfer->setAccountHolder("ABC");
    $transfer->setAccountNumber("654434");
    $transfer->setFirmName("ABC");
    $transfer->setTransferAllCash("false");
    $transfer->setTransferDate("2020-10-10");

    $result = $apiInstance->createTransferUsingPost($transfer);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->createTransferUsingPost: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::FundingApi.new
#Create Transfer
transfer = NucleusApi::ExternalAccountTransfer.new

begin
  transfer.account_id = "f94301e6-2946-4406-9959-b793ec96bea5"
  transfer.account_type_id = "9c36f92e-89f0-4209-9d1c-6f102b5f6509"
  transfer.account_holder = "Mike"
  transfer.account_number = "55544"
  transfer.firm_name = "ABC"
  transfer.transfer_all_cash = "true"
  transfer.transfer_date = "2020-10-10"
  result = api_instance.create_transfer_using_post(transfer)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->create_transfer_using_post: #{e}"
end
var apiInstance = new HydrogenNucleusApi.FundingApi();
//Create a Funding Transfer
var transfer = new HydrogenNucleusApi.ExternalAccountTransfer();
transfer.account_type_id = '9c36f92e-89f0-4209-9d1c-6f102b5f6509';
transfer.account_id = 'f94301e6-2946-4406-9959-b793ec96bea5';
transfer.account_holder = "ABC";
transfer.account_number = "7685675";
transfer.firm_name = "New";
transfer.transfer_all_cash = "false";
transfer.transfer_date = "2020-10-10";
var newtransfer = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.createTransferUsingPost(transfer, newtransfer)

Example Response

{
    "id": "111d714c-1d1c-47cf-9cb7-760428e86c24",
    "transfer_date": "2019-03-21",
    "create_date": "2018-04-09T21:02:11.000+0000",
    "account_holder": "JB Smith",
    "account_number": "5889632503",
    "currency_code": "USD",
    "amount": 13000,
    "comment": "Closed down previous 401k",
    "firm_name": "Vanguard",
    "dtc_number" : "345928204",
    "status": "Pending",
    "status_time_stamp": "2018-04-09T21:02:11.000+0000",
    "transfer_all_cash": true,
    "transfer_type": "full",
    "account_id": "099961da-7f41-4309-950f-2b51689a0033",
    "account_type_id": "647c54c3-b649-477e-8cc7-eee56a120dd3"
}

Create a new external account transfer for a client account. The unique account_id must be provided. To obtain the appropriate account_id, use the GET /account endpoint to view all accounts defined for your tenant. The create_date will default to the current date. The endpoint returns a unique transfer_id used to manage the funding transaction.

HTTP REQUEST

POST /transfer

ARGUMENTS

Parameter Type Required Description
account_id UUID required The id of the account to which the transfer belongs
account_holder string required Name of the individual that is the owner of the external account
account_number string required Account number for the external account that is the source of the funds
account_type_id UUID required The id for the type of the account on your platform
firm_name string required Name of the firm that previously held or holds the external account
transfer_all_cash boolean required Indicator if the external account should be entirely converted to cash to be transferred.
amount double optional Amount that is transferred
currency_code string optional Alphabetic currency code for the request, limited to 3 characters. See currency codes
comment string optional Comment for the transfer such as “Funded”
dtc_number string optional Number of the Deposit Trust Company (DTC)’s that held or holds the external account usually in the case of an Individual Retirement Account (IRA) in the United States
roth_five_year integer optional In the case that the account is a United States Roth IRA account, the year it was opened (e.g. 2010)
status string optional Status of the transfer such as “Pending”
transfer_type string optional Type of transfer being made. Value may be partial or full
transfer_date date optional Date that the transfer will be initiated. Defaults to the current date
metadata map optional Custom information associated with the entity in the format key:value
See Metadata
secondary_id string optional Alternate id that can be used to identify the object such as an internal id

Retrieve a transfer request

Example Request

curl -X GET -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/transfer/111d714c-1d1c-47cf-9cb7-760428e86c24"
FundingApi apiInstance = new FundingApi();
        try {
            ExternalAccountTransfer responseTransfer = apiInstance.getTransferUsingGet(UUID.fromString("bd881e81-11d8-469b-bb41-c5b4803a7deb"), null);
            System.out.println(responseTransfer);
        } catch (ApiException e) {
            System.err.println("Exception when calling getTransferUsingGet");
            e.printStackTrace();
        }
api_instance = nucleus_api.FundingApi(nucleus_api.ApiClient(configuration))
try:
    api_response = api_instance.get_transfer_using_get("c7adbd6d-aeca-4e37-abec-5e7ca5d4ad11")
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_transfer_using_get: %s\n" % e)
$apiInstance = new com\hydrogen\nucleus\Api\FundingApi(
    new GuzzleHttp\Client(),
    $config);
$transfer_id = "bd881e81-11d8-469b-bb41-c5b4803a7deb"; // string | UUID external_account_transfer_id
$currency_conversion = null; // string | USD

try {
    $transfer = $apiInstance->getTransferUsingGet($transfer_id, $currency_conversion);
    print_r($transfer);
} catch (Exception $e) {
    echo 'Exception when calling FundingApi->getTransferUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::FundingApi.new
transfer_id = 'bd881e81-11d8-469b-bb41-c5b4803a7deb' # String | UUID external_account_transfer_id

opts = {
    currency_conversion: null, # String | USD
}

begin
  #Retrieve a transfer request
  transfer = api_instance.get_transfer_using_get(transfer_id, opts)
  p transfer
rescue NucleusApi::ApiError => e
  puts "Exception when calling FundingApi->get_transfer_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.FundingApi();
var transferID = "bd881e81-11d8-469b-bb41-c5b4803a7deb";

var opts = {
    'currencyConversion': null, // String | USD
};


var transfer = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.getTransferUsingGet(transferID, opts, transfer)

Example Response

{
    "id": "111d714c-1d1c-47cf-9cb7-760428e86c24",
    "transfer_date": "2019-03-21",
    "create_date": "2018-04-09T21:02:11.000+0000",
    "update_date": "2018-04-09T21:02:11.000+0000",
    "account_holder": "JB Smith",
    "account_number": "5889632503",
    "currency_code": "USD",
    "amount": 13000,
    "comment": "Closed down previous 401k",
    "firm_name": "Vanguard",
    "dtc_number" : "345928204",
    "status": "Pending",
    "status_time_stamp": "2018-04-09T21:02:11.000+0000",
    "transfer_all_cash": true,
    "transfer_type": "full",
    "account_id": "099961da-7f41-4309-950f-2b51689a0033",
    "account_type_id": "647c54c3-b649-477e-8cc7-eee56a120dd3",
    "metadata": {}
}

Retrieve the information for an external account transfer for an account. The unique transfer_id must be provided. The endpoint returns the details for the external account transfer specified.

HTTP REQUEST

GET /transfer/{transfer_id}

Update a transfer request

Example Request

curl -X PUT -H "Authorization: Bearer <access_token>" \
    -H "Content-Type: application/json" \
    -d '{
            "account_holder": "JB Smith",
            "account_number": "5889632503",
            "amount": 13000,
            "comment": "Closed down previous 401k",
            "firm_name": "Vanguard",
            "dtc_number" : "345928204",
            "status": "Pending",
            "status_time_stamp": "2018-04-09T21:02:11.000+0000",
            "transfer_all_cash": true,
            "transfer_type": "full",
            "transfer_date": "2019-03-21",
            "account_id": "099961da-7f41-4309-950f-2b51689a0033",
            "account_type_id": "647c54c3-b649-477e-8cc7-eee56a120dd3"
        }' "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/transfer/111d714c-1d1c-47cf-9cb7-760428e86c24"
api_instance = nucleus_api.FundingApi(nucleus_api.ApiClient(configuration))
# # Update a Transfer
transfer_update = {'firm_name': 'FCB'}
transfer_id = '04faf321-1c69-45e7-9039-56fc1c589ab4'
try:
    api_response = api_instance.update_transfer_using_put(transfer_id)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling update_transfer_using_put: %s\n" % e)
FundingApi apiInstance = new FundingApi();
//Update Trasfer
        Map map4 = new HashMap();
        map4.put("amount", "600");

        try {
            ExternalAccountTransfer response = apiInstance.updateTransferUsingPut(map4, UUID.fromString("337c7b29-ab58-4b7e-ab28-cb49befe25c3"));
            System.out.println(response);
        } catch (ApiException e) {
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\FundingApi(
    new GuzzleHttp\Client(),
    $config);
//Update Transfer
$transfer_update = new stdClass();
$transfer_id = "00e71e2d-ccdc-4f05-b8ec-63ea9f586e3a";

try {
    $transfer_update->account_number = "554";
    $result = $apiInstance->updateTransferUsingPut($transfer_update, $transfer_id);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->updateTransferUsingPut: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::FundingApi.new

#Update Transfer
transfer_update = {"firm_name" => 'CAD'}
transfer_id = '00e71e2d-ccdc-4f05-b8ec-63ea9f586e3a'
begin
  result = api_instance.update_transfer_using_put(transfer_update, transfer_id)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->update_transfer_using_put: #{e}"
end
var apiInstance = new HydrogenNucleusApi.FundingApi();
//Update Funding
var apiInstance = new HydrogenNucleusApi.FundingApi();
var callback = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
var transferupdate = new HydrogenNucleusApi.ExternalAccountTransfer();
var transferid = '337c7b29-ab58-4b7e-ab28-cb49befe25c3';

transferupdate.currency_code = "GBP";
apiInstance.updateTransferUsingPut(transferupdate, transferid, callback)

Example Response

{
    "id": "111d714c-1d1c-47cf-9cb7-760428e86c24",
    "transfer_date": "2019-03-21",
    "create_date": "2018-04-09T21:02:11.000+0000",
    "update_date": "2018-04-09T21:02:11.000+0000",
    "account_holder": "JB Smith",
    "account_number": "5889632503",
    "currency_code": "USD",
    "amount": 13000,
    "comment": "Closed down previous 401k",
    "firm_name": "Vanguard",
    "dtc_number" : "345928204",
    "status": "Pending",
    "status_time_stamp": "2018-04-09T21:02:11.000+0000",
    "transfer_all_cash": true,
    "transfer_type": "full",
    "account_id": "099961da-7f41-4309-950f-2b51689a0033",
    "account_type_id": "647c54c3-b649-477e-8cc7-eee56a120dd3",
    "metadata": {}
}

Update the information for an external account transfer for a client account. The unique transfer_id must be provided. To obtain the appropriate transfer_id, use the GET /transfer endpoint to view all external account transfer requests defined for your tenant and their current information. The details to be updated must also be provided. The endpoint returns the transfer_id and all of the details for the external account transfer.

HTTP REQUEST

PUT /transfer/{transfer_id}

Delete a transfer request

Example Request

curl -X DELETE -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/transfer/111d714c-1d1c-47cf-9cb7-760428e86c24"
api_instance = nucleus_api.FundingApi(nucleus_api.ApiClient(configuration))
# # # Delete a Transfer
transferd_id = '0afc6642-81b5-4ea4-aae9-5a799b13030a'
try:
    api_instance.delete_transfer_using_delete(transferd_id)
except ApiException as e:
    print("Exception when delete_transfer_using_delete: %s\n" % e)
FundingApi apiInstance = new FundingApi();
        //Delete a Transfer
        try {
            ExternalAccountTransfer deleteresponse = apiInstance.deleteTransferUsingDelete(UUID.fromString("4e9277bb-ee9e-4fdc-9aca-c4818f8aabea"));
            System.out.println(deleteresponse);
        } catch (ApiException e) {
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\FundingApi(
    new GuzzleHttp\Client(),
    $config);
//Delete transfer
$transfer_did = "7e083cdc-39a3-4565-97a1-3a33f9522331"; // string | UUID account_id

try {
    $apiInstance->deleteTransferUsingDelete($transfer_did);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->deleteTransferUsingDelete: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::FundingApi.new
#Delete Transfer
transfer1_id = '7e083cdc-39a3-4565-97a1-3a33f9522331'
begin
  result = api_instance.delete_transfer_using_delete(transfer1_id)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->delete_transfer_using_delete: #{e}"
end
var apiInstance = new HydrogenNucleusApi.FundingApi();
// // // //Delete a Transfer
var transferd = "47a959b5-6554-470c-a01c-c3fb68e49fa1";


var deletetransfer = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully.');
    }
};
apiInstance.deleteTransferUsingDelete(transferd, deletetransfer)

Response (204 No Content)

Permanently delete an external account transfer from a client account. The unique transfer_id must be provided. To obtain the appropriate transfer_id, use the GET /transfer endpoint to view all external account transfer requests defined for your tenant. This deletes the transfer_id and the external account transfer record.

HTTP REQUEST

DELETE /transfer/{transfer_id}

Goal

Goal frameworks are defined firm-wide. Clients can answer a questionnaire created by your firm in order to customize their goals based upon their specific needs. Questionnaires can be assigned to multiple goals, using a questionnaire_id. Client responses to the goal questionnaire are stored and used as variables in future calculations. The progress of each client is tracked in relation to one or more goals that the client has selected. A client may have multiple goals, and each goal may belong to one or more of the client’s accounts.

Field Type Description
id UUID The id of the goal
name string Name of the goal
parent_goal_id UUID In the case that a goal is related to a broader goal, the id of the broader goal
questionnaire_id UUID The id of the group of questions that are used to customize a goal for a client
is_decumulation boolean Indicator for whether or not the goal is a decumulation goal such as saving for retirement. Default is false, indicating that the goal is an accumulation goal. May be used in conjunction with the Proton API.
type string Type of goal used to identify similar goals. Can be used to differentiate between goal templates and client-specific goals
category string Category of the goal used to group goals together. For example, different large purchase goals could have a category of ‘Major Purchase’
client_id UUID If the goal is client-specific (not used by any other client), the id of the client to which it belongs
goal_amount double If the goal is client-specific, the target monetary amount to be reached within the goal horizon. May be used in conjunction with the Proton API. If the goal is not client-specific, please store under the account entity.
accumulation_horizon double If the goal is client-specific, the time horizon of the goal during the accumulation phase, in years. May be used in conjunction with the Proton API. If the goal is not client-specific, please store under the account entity.
decumulation_horizon double If the goal is client-specific, the time horizon of the goal during the decumulation phase, in years. If the goal is an accumulation goal, then this can be 0 or omitted entirely. May be used in conjunction with the Proton API. If the goal is not client-specific, please store under the account entity.
image string Icon or image for the goal either as a URL or file name that you will link to
is_active string Indicates if the goal is active. Defaults to true which indicates it is active
metadata map Custom information associated with the goal in the format key:value. See Metadata
secondary_id string Alternate id that can be used to identify the object such as an internal id
create_date timestamp Timestamp for the date and time that the record was created
update_date timestamp Timestamp for the date and time that the record was last updated

Goal Management

List all goals

Example Request

curl -X GET -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/goal"
api_instance = nucleus_api.GoalApi(nucleus_api.ApiClient(configuration))
try:
    api_response = api_instance.get_goal_all_using_get()
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_goal_all_using_get: %s\n" % e)
GoalApi apiInstance = new GoalApi();
        try {
            PageGoal List = apiInstance.getGoalAllUsingGet(true, null, null, 0, 10);
            System.out.println(List);
        } catch (ApiException e) {
            System.err.println("Exception when calling getGoalAllUsingGet");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\GoalApi(
    new GuzzleHttp\Client(),
    $config);
$ascending = false; // bool | ascending
$filter = null; // string | filter
$order_by = null; // string | order_by
$page = 0; // int | page
$size = 10; // int | size

try {
    $goallist = $apiInstance->getGoalAllUsingGet($ascending, $filter, $order_by, $page, $size);
    print_r($goallist);
} catch (Exception $e) {
    echo 'Exception when calling GoalApi->getGoalAllUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::GoalApi.new
opts = {
    ascending: false, # BOOLEAN | ascending
    filter: null, # String | filter
    order_by: null, # String | order_by
    page: 0, # Integer | page
    size: 25 # Integer | size
}
begin
  goallist = api_instance.get_goal_all_using_get(opts)
  p goallist
rescue NucleusApi::ApiError => e
  puts "Exception when calling GoalApi->get_goal_all_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.GoalApi();
var opts = {
    'ascending': false, // Boolean | ascending
    // 'filter': "", // String | filter
    'orderBy': "update_date", // String | order_by
    'page': 0, // Number | page
    'size': 25 // Number | size
};

var goallist = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.getGoalAllUsingGet(opts, goallist)

Example Response

{
  "content": [
      {
          "id": "bab849d6-de96-4dc7-a5ea-19be45c52a4e",
          "create_date": "2018-02-07T19:29:37.000+0000",
          "update_date": "2018-02-12T09:00:00.000+0000",
          "name": "House",
          "parent_goal_id": "647c54c3-b649-477e-8cc7-eee56a120dd3",
          "questionnaire_id": "647c54c3-b649-477e-8cc7-eee56a120dd3",
          "is_decumulation": false,
          "type": "Client Goal",
          "category": "Large Purchase",
          "client_id": "184b66ff-09d8-4c0d-ad88-c7d7e8376714",
          "goal_amount": 100000,
          "accumulation_horizon": 10,
          "decumulation_horizon": 0,
          "image": null,
          "is_active": true,
          "metadata": {
              "image": "https://www.hydrogenplatform.com/images/demo/house.svg"
          }
      },
      {
          "id": "e995d4c1-f989-4733-9867-713966ac9856",
          "create_date": "2018-02-07T19:29:37.000+0000",
          "update_date": "2018-02-12T09:00:00.000+0000",
          "name": "Car",
          "parent_goal_id": "647c54c3-b649-477e-8cc7-eee56a120dd3",
          "questionnaire_id": "647c54c3-b649-477e-8cc7-eee56a120dd3",
          "is_decumulation": false,
          "type": "Client Goal",
          "client_id": "184b66ff-09d8-4c0d-ad88-c7d7e8376714",
          "category": "Large Purchase",
          "goal_amount": 10000,
          "accumulation_horizon": 5,
          "decumulation_horizon": 0,
          "image": null,
          "is_active": true,
          "metadata": {
              "image": "https://www.hydrogenplatform.com/images/demo/car-purchase.svg"
          }
      },
      {
          "id": "fbc03484-08e8-446d-83aa-6d6cc236355e",
          "create_date": "2018-02-07T19:29:37.000+0000",
          "update_date": "2018-02-12T09:00:00.000+0000",
          "name": "Vacation",
          "parent_goal_id": "647c54c3-b649-477e-8cc7-eee56a120dd3",
          "questionnaire_id": "647c54c3-b649-477e-8cc7-eee56a120dd3",
          "is_decumulation": false,
          "type": "Client Goal",
          "client_id": "184b66ff-09d8-4c0d-ad88-c7d7e8376714",
          "category": "Large Purchase",
          "goal_amount": 1000,
          "accumulation_horizon": 3,
          "image": null,
          "is_active": true,
          "metadata": {
              "image": "https://www.hydrogenplatform.com/images/demo/travel.svg"
          }
      },
  ],
  "total_pages": 1,
  "total_elements": 3,
  "last": true,
  "number_of_elements": 3,
  "first": true,
  "sort": [
      {
        "direction": "ASC",
        "property": "id",
        "ignore_case": false,
        "null_handling": "NATIVE",
        "descending": false,
        "ascending": true
      }
  ],
  "size": 25,
  "number": 0
}

Get the details for all goals defined by your firm. Note that the metadata information is stored as a nested object within the goal object.

HTTP REQUEST

GET /goal

Create a goal

Example Request

curl -X POST -H "Authorization: Bearer <access_token>" \
     -H "Content-Type: application/json" \
     -d '{
            "name": "Car",
            "parent_goal_id": "647c54c3-b649-477e-8cc7-eee56a120dd3",
            "questionnaire_id": "647c54c3-b649-477e-8cc7-eee56a120dd3",
            "is_decumulation": false,
            "type": "Client Goal",
            "category": "Large Purchase",
            "client_id": "184b66ff-09d8-4c0d-ad88-c7d7e8376714",
            "goal_amount": 100000,
            "accumulation_horizon": 10,
            "decumulation_horizon": 0,
            "metadata": {
              "image": "https://www.hydrogenplatform.com/images/demo/car-purchase.svg"
            }
      }' "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/goal"
api_instance = nucleus_api.GoalApi(nucleus_api.ApiClient(configuration))
# Create a Goal
goal = nucleus_api.Goal(name="First Goal", category="One", goal_amount="500", image=None)
try:
    api_response = api_instance.create_goal_using_post(goal)
    pprint(api_response)
except ApiException as e:
    print("create_goal_using_post: %s\n" % e)
GoalApi apiInstance = new GoalApi();
        //Create A Goal
        Goal goalone = new Goal();
        goalone.setName("Aone");
        goalone.setCategory("one");
        goalone.setGoalAmount(500.00);
        goalone.setImage(null);

        try {
            Goal result = apiInstance.createGoalUsingPost(goalone);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling createGoalUsingPost");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\GoalApi(
    new GuzzleHttp\Client(),
    $config);
//Create Goal
$goal = new \com\hydrogen\nucleus\Model\Goal();

try {
    $goal->setName("New");
    $goal->setCategory("ABC");
    $goal->setGoalAmount("700");
    $goal->setImage("Image");

    $result = $apiInstance->createGoalUsingPost($goal);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->createGoalUsingPost: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::GoalApi.new
#Create Goal
goal = NucleusApi::Goal.new

begin
  goal.name = "New"
  goal.category = "primary"
  goal.goal_amount = "800"
  goal.image = "null"
  result = api_instance.create_goal_using_post(goal)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->create_goal_using_post: #{e}"
end
var apiInstance = new HydrogenNucleusApi.GoalApi();
///Create a Goal
var goal = new HydrogenNucleusApi.Goal();
goal.name = "ANC";
goal.category = "one";
goal.goal_amount = "500";



var newgoal = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.createGoalUsingPost(goal, newgoal)

Example Response

{
    "id": "e995d4c1-f989-4733-9867-713966ac9856",
    "create_date": "2018-02-07T19:29:37.000+0000",
    "name": "Car",
    "parent_goal_id": "647c54c3-b649-477e-8cc7-eee56a120dd3",
    "questionnaire_id": "647c54c3-b649-477e-8cc7-eee56a120dd3",
    "is_decumulation": false,
    "type": "Client Goal",
    "category": "Large Purchase",
    "client_id": "184b66ff-09d8-4c0d-ad88-c7d7e8376714",
    "goal_amount": 100000,
    "accumulation_horizon": 10,
    "decumulation_horizon": 0,
    "image": null,
    "is_active": true,
    "metadata": {
        "image": "https://www.hydrogenplatform.com/images/demo/car-purchase.svg"
    }
}

Create a new goal for your tenant that clients can customize for themselves. Must provide the name for the goal and indicate whether or not the goal is a decumulation goal (or accumulation goal). The create_date will default to the current date. The endpoint returns the goal_id used to manage the goal and to map the goal to a client.

HTTP REQUEST

POST /goal

ARGUMENTS

Parameter Type Required Description
name string required Name of the goal
parent_goal_id UUID optional In the case that a goal is related to a broader goal, the id of the broader goal
questionnaire_id UUID optional The id of the group of questions that are used to customize a goal for a client
is_decumulation boolean optional Indicator if the goal is a decumulation goal such as saving for retirement. Default is false, indicating that the goal is an accumulation goal. May be used in conjunction with the Proton API.
type string optional Type of goal used to identify similar goals. Can be used to differentiate between goal templates and client-specific goals
category string optional Category of the goal used to group goals together. For example, different large purchase goals could have a category of ‘Major Purchase’
client_id UUID optional If the goal is client-specific (not used by any other client), the id of the client to which it belongs
goal_amount double optional If the goal is client-specific, the target monetary amount to be reached within the goal horizon. May be used in conjunction with the Proton API. If the goal is not client-specific, please store under the account entity.
accumulation_horizon double optional If the goal is client-specific, the time horizon of the goal during the accumulation phase, in years. May be used in conjunction with the Proton API. If the goal is not client-specific, please store under the account entity.
decumulation_horizon double optional If the goal is client-specific, the time horizon of the goal during the decumulation phase, in years. If the goal is an accumulation goal, then this can be 0 or omitted entirely. May be used in conjunction with the Proton API. If the goal is not client-specific, please store under the account entity.
image string optional Icon or image for the goal either as a URL or file name that you will link to
is_active string optional Indicates if the goal is active. Defaults to true which indicates it is active
metadata map optional Custom information associated with the goal in the format key:value. See Metadata
secondary_id string optional Alternate id that can be used to identify the object such as an internal id

Retrieve a goal

Example Request

curl -X GET -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/goal/e995d4c1-f989-4733-9867-713966ac9856"
api_instance = nucleus_api.GoalApi(nucleus_api.ApiClient(configuration))
try:
    api_response = api_instance.get_goal_using_get("51cda275-1cdd-4f44-b504-cae8188b4c63")
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_goal_using_get: %s\n" % e)
GoalApi apiInstance = new GoalApi();
        try {
            Goal responseGoal = apiInstance.getGoalUsingGet(UUID.fromString("fa50427b-30ba-4c33-8c01-831863f51dc9"));
            System.out.println(responseGoal);
        } catch (ApiException e) {
            System.err.println("Exception when calling getGoalUsingGet");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\GoalApi(
    new GuzzleHttp\Client(),
    $config);
$goal_id = "fa50427b-30ba-4c33-8c01-831863f51dc9"; // string | UUID goal_id

try {
    $goal = $apiInstance->getGoalUsingGet($goal_id);
    print_r($goal);
} catch (Exception $e) {
    echo 'Exception when calling GoalApi->getGoalUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::GoalApi.new
goal_id = 'fa50427b-30ba-4c33-8c01-831863f51dc9' # String | UUID goal_id


begin
  goal = api_instance.get_goal_using_get(goal_id)
  p goal
rescue NucleusApi::ApiError => e
  puts "Exception when calling GoalApi->get_goal_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.GoalApi();
var goalId = "fa50427b-30ba-4c33-8c01-831863f51dc9";


var goal = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.getGoalUsingGet(goalId, goal)

Example Response

{
    "id": "e995d4c1-f989-4733-9867-713966ac9856",
    "create_date": "2018-02-07T19:29:37.000+0000",
    "update_date": "2018-02-12T09:00:00.000+0000",
    "name": "Car",
    "parent_goal_id": "647c54c3-b649-477e-8cc7-eee56a120dd3",
    "questionnaire_id": "647c54c3-b649-477e-8cc7-eee56a120dd3",
    "is_decumulation": false,
    "type": "Client Goal",
    "category": "Large Purchase",
    "client_id": "184b66ff-09d8-4c0d-ad88-c7d7e8376714",
    "goal_amount": 100000,
    "accumulation_horizon": 10,
    "decumulation_horizon": 0,
    "image": null,
    "is_active": true,
    "metadata": {
        "image": "https://www.hydrogenplatform.com/images/demo/car-purchase.svg"
      }
}

Retrieve the information for a goal defined for your tenant. The goal_id must be provided. The endpoint returns the goal_id and the details for the goal specified.

HTTP REQUEST

GET /goal/{goal_id}

Update a goal

Example Request

curl -X PUT -H "Authorization: Bearer <access_token>" \
     -H "Content-Type: application/json" \
     -d '{
            "name": "Car",
            "questionnaire_id": "647c54c3-b649-477e-8cc7-eee56a120dd3",
            "type": "Goal Template",
            "category": "Large Purchase",
            "is_active": false,
            "metadata": {
                "image": "https://www.hydrogenplatform.com/images/demo/car-purchase.svg"
            }
    }' "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/goal/e995d4c1-f989-4733-9867-713966ac9856"
api_instance = nucleus_api.GoalApi(nucleus_api.ApiClient(configuration))
# # # Update a Goal
goal_update = {'firm_name': 'FCB'}
goal_id = 'f3f5b496-5d82-4226-ac6b-d2e74d64ba82'
try:
    api_response = api_instance.update_goal_using_put(goal_id, goal_update);
    pprint(api_response)
except ApiException as e:
    print("Exception when calling update_goal_using_put: %s\n" % e)
GoalApi apiInstance = new GoalApi();
//        //Update Goal
//        Map map = new HashMap();
//        map.put("goal_amount", "100.0");
//
//        try {
//            Goal response = apiInstance.updateGoalUsingPut(map, UUID.fromString("cf2179b1-6d6d-47ed-8bc7-66308f6e13ab"));
//            System.out.println(response);
//        } catch (ApiException e) {
//            e.printStackTrace();
//        }
$apiInstance = new com\hydrogen\nucleus\Api\GoalApi(
    new GuzzleHttp\Client(),
    $config);
//Update Goal
$goal_update = new stdClass();
$goal_id = "cf2179b1-6d6d-47ed-8bc7-66308f6e13ab";

try {
    $goal_update->category = "new";
    $result = $apiInstance->updateGoalUsingPut($goal_update, $goal_id);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->updateGoalUsingPut: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::GoalApi.new
#Update Goal
goal_update = {"goal_amount" => '2000'}
goal_id = 'cf2179b1-6d6d-47ed-8bc7-66308f6e13ab'
begin
  result = api_instance.update_goal_using_put(goal_update, goal_id)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->update_goal_using_put: #{e}"
end
var apiInstance = new HydrogenNucleusApi.GoalApi();
//Update Goal
var apiInstance = new HydrogenNucleusApi.GoalApi();
var callback = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
var goalupdate = new HydrogenNucleusApi.Goal();
var goalid = '2fa2f55e-0d54-47b4-9157-37c29f4168ee';

goalupdate.goal_amount = "600";
apiInstance.updateGoalUsingPut(goalupdate, goalid, callback)

Example Response

{
    "id": "e995d4c1-f989-4733-9867-713966ac9856",
    "create_date": "2018-02-07T19:29:37.000+0000",
    "update_date": "2018-02-12T09:00:00.000+0000",
    "name": "Car",
    "questionnaire_id": "647c54c3-b649-477e-8cc7-eee56a120dd3",
    "is_decumulation": false,
    "type": "Goal Template",
    "category": "Large Purchase",
    "is_active": false,
    "metadata": {
         "image": "https://www.hydrogenplatform.com/images/demo/car-purchase.svg"
    }
}

Update a goal defined for your tenant. The goal_id must be provided. To obtain the appropriate goal_id, use the GET /goal endpoint to view all goals defined for your tenant and their current information. The details to be updated must also be provided. The endpoint returns the goal_id and the details for the goal.

HTTP REQUEST

PUT /goal/{goal_id}

Delete a goal

Example Request

curl -X DELETE -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/goal/e995d4c1-f989-4733-9867-713966ac9856"
api_instance = nucleus_api.GoalApi(nucleus_api.ApiClient(configuration))
# Delete a Goal
d_goal_id = 'dfb161ff-cf53-4268-a876-2cb4d78cfc07'
try:
    api_instance.delete_goal_using_delete(d_goal_id)
except ApiException as e:
    print("Exception when delete_goal_using_delete: %s\n" % e)
GoalApi apiInstance = new GoalApi();
        //Delete a Goal
        try {
            Goal deleteresponse = apiInstance.deleteGoalUsingDelete(UUID.fromString("865bcd44-465d-48a0-beda-8ba8e5791ece"));
            System.out.println(deleteresponse);
        } catch (ApiException e) {
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\GoalApi(
    new GuzzleHttp\Client(),
    $config);

//Delete Goal
$goal_did = "4e3bd8cd-643f-45cc-99be-f87aab06d495"; // string | UUID account_id

try {
    $apiInstance->deleteGoalUsingDelete($goal_did);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->deleteGoalUsingDelete: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::GoalApi.new
#Delete Goal
goal1_id = '4e3bd8cd-643f-45cc-99be-f87aab06d495'
begin
  result = api_instance.delete_goal_using_delete(goal1_id)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->delete_goal_using_delete: #{e}"
end
var apiInstance = new HydrogenNucleusApi.GoalApi();
// // //Delete a Goal
var goaldid = "ee9382fd-0e8d-45cd-bb9f-7c928fd7a958";
var deletegoal = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully.');
    }
};
apiInstance.deleteGoalUsingDelete(goaldid, deletegoal)

Response (204 No Content)

Permanently delete a goal for your tenant. The goal_id must be provided. To obtain the appropriate goal_id, use the GET /goal endpoint to view all goals defined for your tenant. This deletes the goal_id and the goal record so that the goal can no longer be used overall.

HTTP REQUEST

DELETE /goal/{goal_id}

Goal Activity

List all goal asset sizes

Example Request

curl -X GET -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/goal/8d97c85c-8cbf-4ac1-a5df-f9d2bb6a77e0/asset_size?client_id=b4c033db-9d05-4a33-8e28-40650d454487"
api_instance = nucleus_api.GoalApi(nucleus_api.ApiClient(configuration))
try:
    api_response = api_instance.get_goal_asset_size_all_using_get("63f05f77-1851-477c-9866-88effe5aeca3", "6c6ef8fa-09d3-462b-a6a8-aafadf7f378f")
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_goal_asset_size_all_using_get: %s\n" % e)
GoalApi apiInstance = new GoalApi();
        try {
            Object assetsize = apiInstance.getGoalAssetSizeAllUsingGet(UUID.fromString("63f05f77-1851-477c-9866-88effe5aeca3"), UUID.fromString("6c6ef8fa-09d3-462b-a6a8-aafadf7f378f"), null, date2, true, true, null, date1);
            System.out.println(assetsize);
        } catch (ApiException e) {
            System.err.println("Exception when calling getGoalAssetSizeAllUsingGet");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\GoalApi(
    new GuzzleHttp\Client(),
    $config);
$client_id = "63f05f77-1851-477c-9866-88effe5aeca3"; // string | client_id
$goal_id = "6c6ef8fa-09d3-462b-a6a8-aafadf7f378f"; // string | UUID goal_id
$currency_conversion = null; // string | Currency Code
$end_date = new \DateTime("2013-10-20"); // \DateTime | end date
$get_latest = false; // bool | get_latest
$portfolio_goal = false; // bool | portfolio_goal
$sort_type = null; // string | sort_type
$start_date = new \DateTime("2013-10-20"); // \DateTime | start date

try {
    $goalasset = $apiInstance->getGoalAssetSizeAllUsingGet($client_id, $goal_id, $currency_conversion, $end_date, $get_latest, $portfolio_goal, $sort_type, $start_date);
    print_r($goalasset);
} catch (Exception $e) {
    echo 'Exception when calling GoalApi->getGoalAssetSizeAllUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::GoalApi.new
client_id = '63f05f77-1851-477c-9866-88effe5aeca3' # String | client_id
goal_id = '6c6ef8fa-09d3-462b-a6a8-aafadf7f378f' # String | UUID goal_id

opts = {
    currency_conversion: null, # String | Currency Code
    end_date: Date.parse('2013-10-20'), # Date | end date
    get_latest: false, # BOOLEAN | get_latest
    portfolio_goal: false, # BOOLEAN | portfolio_goal
    sort_type: null, # String | sort_type
    start_date: Date.parse('2013-10-20') # Date | start date
}

begin
  assetsize = api_instance.get_goal_asset_size_all_using_get(client_id, goal_id, opts)
  p assetsize
rescue NucleusApi::ApiError => e
  puts "Exception when calling GoalApi->get_goal_asset_size_all_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.GoalApi();
var clientId = "63f05f77-1851-477c-9866-88effe5aeca3"; // String | client_id

var goalId = "6c6ef8fa-09d3-462b-a6a8-aafadf7f378f"; // String | UUID goal_id

var opts = {
    'currencyConversion': null, // String | Currency Code
    'endDate': new Date("2013-10-20"), // Date | end date
    'getLatest': false, // Boolean | get_latest
    'portfolioGoal': false, // Boolean | portfolio_goal
    'sortType': null, // String | sort_type
    'startDate': new Date("2013-10-20") // Date | start date
};

var goalasset = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' + data);
    }
};
apiInstance.getGoalAssetSizeAllUsingGet(clientId, goalId, opts, goalasset)

Example Response

[
    {
        "date": "2018-02-03",
        "currency_code": "USD",
        "value": 20000,
        "value_available": null,
        "value_pending": null,
        "cash_flow": 0
    },
    {
        "date": "2018-02-04",
        "currency_code": "USD",
        "value": 24500,
        "value_available": null,
        "value_pending": null,
        "cash_flow": 500
    }
]

Get a list of asset sizes per date for a goal for a specified client. Asset size records are created at a portfolio level and aggregated to yield the goal asset sizes. Goal asset sizes are calculated by applying the goal account weights to the portfolio asset sizes of the portfolios below the accounts contributing to the goal. The goal account weights are based on the account allocation weights multiplied by the allocation composition weights for each account contributing to the goal. The unique goal_id must be provided. To obtain the appropriate goal_id, use the GET /goal endpoint to view all goals defined for your tenant. A unique client_id must also be provided to return the asset size data as it relates to a specific client. To obtain the appropriate client_id, use the GET /client endpoint to view all clients defined for your tenant. The endpoint returns a date, an amount value, and the funds added to the goal since the last asset size date, usually via deposit. Note that goal asset sizes will generally be estimates meant to be indicative of goal growth but may vary slightly from the asset sizes of the portfolios associated with the goal.

HTTP REQUEST

GET /goal/{goal_id}/asset_size?client_id={client_id}

ARGUMENTS

Parameter Type Required Description
client_id UUID required Id of the client subscribed to the goal
portfolio_goal boolean optional If you are storing goals at a portfolio level in /portfolio_goal, then set this to true. Defaults to false, which means you are storing at an account level in /account_allocation
get_latest boolean optional Retrieve only the latest asset size. Defaults to false if not set
sort_type string optional Sort the asset sizes by D Daily, M Monthly, Q Quarterly, Y Yearly. Defaults to D Daily if not set. Must be capital letters
start_date date optional Start date for the data. Defaults to the first date if not set
end_date date optional End date for the data. Defaults to the last date if not set
currency_conversion string optional Alphabetic currency code for the currency to convert all monetary values to. Value may be USD, GBP, EUR, AUD, CAD. Only available in enterprise plan.

RESPONSE

Field Type Description
date date Date for the asset size record. Displays the latest record if more than one entry exists for the given date.
currency_code string Alphabetic currency code for the asset size. See currency codes
value double Monetary value of the goal on the particular date
value_available double Available monetary value of the goal on the particular date
value_pending double Pending monetary value of the goal on the particular date
cash_flow double Amount added to the goal’s accounts or withdrawn from the accounts since the last asset size date. Value is used for performance calculations. Value may be positive or negative.

List all goal holdings

Example Request

curl -X GET -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/goal/7960419c-c098-4450-8cc5-866b7385230b/holding?client_id=b4c033db-9d05-4a33-8e28-40650d454487"
api_instance = nucleus_api.GoalApi(nucleus_api.ApiClient(configuration))
try:
    api_response = api_instance.get_goal_holding_all_using_get("9238eddd-d6d4-4369-946f-dfac53cde56b", "dc830ad9-cb6d-4556-b753-117e3ed4168c")
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_goal_holding_all_using_get: %s\n" % e)
GoalApi apiInstance = new GoalApi();
        try {
          Object goalholding = apiInstance.getGoalHoldingAllUsingGet(UUID.fromString("dc830ad9-cb6d-4556-b753-117e3ed4168c"), UUID.fromString("9238eddd-d6d4-4369-946f-dfac53cde56b"), null, date2, true, date1);
            System.out.println(goalholding);
        } catch (ApiException e) {
            System.err.println("Exception when calling getGoalHoldingAllUsingGet");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\GoalApi(
    new GuzzleHttp\Client(),
    $config);
$client_id = "63f05f77-1851-477c-9866-88effe5aeca3"; // string | client_id
$goal_id = "6c6ef8fa-09d3-462b-a6a8-aafadf7f378f"; // string | UUID goal_id
$currency_conversion = null; // string | Currency Code
$end_date = new \DateTime("2013-10-20"); // \DateTime | end date
$portfolio_goal = false; // bool | portfolio_goal
$start_date = new \DateTime("2013-10-20"); // \DateTime | start date

try {
    $goalholding = $apiInstance->getGoalHoldingAllUsingGet($client_id, $goal_id, $currency_conversion, $end_date, $portfolio_goal, $start_date);
    print_r($goalholding);
} catch (Exception $e) {
    echo 'Exception when calling GoalApi->getGoalHoldingAllUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::GoalApi.new
client_id = '63f05f77-1851-477c-9866-88effe5aeca3' # String | client_id
goal_id = '6c6ef8fa-09d3-462b-a6a8-aafadf7f378f' # String | UUID goal_id
opts = {
    currency_conversion: null, # String | Currency Code
    end_date: Date.parse('2013-10-20'), # Date | end date
    portfolio_goal: false, # BOOLEAN | portfolio_goal
    start_date: Date.parse('2013-10-20') # Date | start date
}

begin
  holdings = api_instance.get_goal_holding_all_using_get(client_id, goal_id, opts)
  p holdings
rescue NucleusApi::ApiError => e
  puts "Exception when calling GoalApi->get_goal_holding_all_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.GoalApi();
var clientId = "63f05f77-1851-477c-9866-88effe5aeca3"; // String | client_id

var goalId = "6c6ef8fa-09d3-462b-a6a8-aafadf7f378f"; // String | UUID goal_id

var opts = {
    'currencyConversion': null, // String | Currency Code
    'endDate': new Date("2013-10-20"), // Date | end date
    'getLatest': false, // Boolean | get_latest
    'portfolioGoal': false, // Boolean | portfolio_goal
    'sortType': null, // String | sort_type
    'startDate': new Date("2013-10-20") // Date | start date
};

var goalholding = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' + data);
    }
};
apiInstance.getGoalHoldingAllUsingGet(clientId, goalId, opts, goalholding)

Example Response

{
  "content": [
        {
            "date": "2018-02-03",
            "security_id": "29c3f995-bd45-4346-aea2-fd4476568d4c",
            "weight": 10,
            "currency_code": "USD",
            "amount": 2000,
            "cost_basis": null,
            "shares": 20
        },
        {
            "date": "2018-02-03",
            "security_id": "89da9660-3efe-4694-b1a7-0958a4f72f0e",
            "weight": 2,
            "currency_code": "USD",
            "amount": 400,
            "cost_basis": null,
            "shares": 40
        },
        {
            "date": "2018-02-03",
            "security_id": "8f7de7e6-3b32-42ff-97a4-d1260811b099",
            "weight": 30,
            "currency_code": "USD",
            "amount": 6000,
            "cost_basis": null,
            "shares": 6
        },
        {
            "date": "2018-02-03",
            "security_id": "b2870d61-d6e0-4a94-9c1e-7a064af13eca",
            "weight": 30,
            "currency_code": "USD",
            "amount": 6000,
            "cost_basis": null,
            "shares": 60
            },
        {
            "date": "2018-02-03",
            "security_id": "dd3e251e-90e2-4e2d-9f3a-4675be5b172f",
            "weight": 28,
            "currency_code": "USD",
            "amount": 5600,
            "cost_basis": null,
            "shares": 50
        }
    ],
    "total_pages": 1,
    "total_elements": 5,
    "last": true,
    "sort": [
        {
            "direction": "DESC",
            "property": "id",
            "ignore_case": false,
            "null_handling": "NATIVE",
            "descending": true,
            "ascending": false
        }
    ],
    "first": true,
    "number_of_elements": 5,
    "size": 25,
    "number": 5
}

Get the information for all the securities that are currently being held in portfolios associated with a particular goal. Holding records are created at a portfolio level and used to calculate the holdings of the goal. Goal holdings are calculated by applying the goal account weights to the portfolio holdings of the portfolios below the accounts contributing to the goal. The goal account weights are based on the account allocation] weights multiplied by the allocation composition] weights for each account contributing to the goal. Must provide the unique goal_id. To obtain the appropriate goal_id, use the GET /goal endpoint to view all goals defined for your tenant. Endpoint returns the security_id, the security amount, the security weight and the date of the record for all securities the client holds.

HTTP REQUEST

GET /goal/{goal_id}/holding?client_id={client_id}

ARGUMENTS

Parameter Type Required Description
client_id UUID required Id of the client subscribed to the goal
portfolio_goal boolean optional If you are storing goals at a portfolio level in /portfolio_goal, then set this to true. Defaults to false, which means you are storing at an account level in /account_allocation
start_date date optional Start date for the data. Defaults to the first date if not set
end_date date optional End date for the data. Defaults to the last date if not set
currency_conversion string optional Alphabetic currency code for the currency to convert all monetary values to. Value may be USD, GBP, EUR, AUD, CAD. Only available in enterprise plan.

RESPONSE

Field Type Description
date date Date for the security holding. Displays the latest record if more than one entry exists for the given date.
security_id UUID The id for the security included in the holding record
weight double The weight of the security as a percentage of the client goal’s total monetary value; ex. 20 representing 20%
currency_code string Alphabetic currency code for the amount. See currency codes
amount double Monetary value of the shares in the holding record
cost_basis double Monetary value that the security was originally purchased for, used for tax purposes
shares double Number of shares in the holding record

List all goal transactions

Example Request

curl -X GET -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/goal/7960419c-c098-4450-8cc5-866b7385230b/transaction?client_id=b4c033db-9d05-4a33-8e28-40650d454487"
api_instance = nucleus_api.GoalApi(nucleus_api.ApiClient(configuration))
try:
    api_response = api_instance.get_goal_transaction_all_using_get("9238eddd-d6d4-4369-946f-dfac53cde56b", "dc830ad9-cb6d-4556-b753-117e3ed4168c")
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_goal_transaction_all_using_get: %s\n" % e)
GoalApi apiInstance = new GoalApi();
        try {
            PagePortfolioTransaction List = apiInstance.getGoalTransactionAllUsingGet(UUID.fromString("dc830ad9-cb6d-4556-b753-117e3ed4168c"), UUID.fromString("9238eddd-d6d4-4369-946f-dfac53cde56b"), true, null, date2, null, 0, true, 10, date1);
            System.out.println(List);
        } catch (ApiException e) {
            System.err.println("Exception when calling getGoalTransactionAllUsingGet");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\GoalApi(
    new GuzzleHttp\Client(),
    $config);
$client_id = "63f05f77-1851-477c-9866-88effe5aeca3"; // string | client_id
$goal_id = "6c6ef8fa-09d3-462b-a6a8-aafadf7f378f"; // string | UUID goal_id
$ascending = false; // bool | ascending
$currency_conversion = null; // string | Currency Code
$end_date = new \DateTime("2013-10-20"); // \DateTime | end date
$order_by = null; // string | order_by
$page = 0; // int | page
$portfolio_goal = false; // bool | portfolio_goal
$size = 10; // int | size
$start_date = new \DateTime("2013-10-20"); // \DateTime | start date

try {
    $goaltransaction = $apiInstance->getGoalTransactionAllUsingGet($client_id, $goal_id, $ascending, $currency_conversion, $end_date, $order_by, $page, $portfolio_goal, $size, $start_date);
    print_r($goaltransaction);
} catch (Exception $e) {
    echo 'Exception when calling GoalApi->getGoalTransactionAllUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::GoalApi.new
client_id = '63f05f77-1851-477c-9866-88effe5aeca3' # String | client_id
goal_id = '6c6ef8fa-09d3-462b-a6a8-aafadf7f378f' # String | UUID goal_id

opts = {
    ascending: false, # BOOLEAN | ascending
    currency_conversion: null, # String | Currency Code
    end_date: Date.parse('2013-10-20'), # Date | end date
    order_by: null, # String | order_by
    page: 0, # Integer | page
    portfolio_goal: false, # BOOLEAN | portfolio_goal
    size: 25, # Integer | size
    start_date: Date.parse('2013-10-20') # Date | start date
}

begin
  transaction = api_instance.get_goal_transaction_all_using_get(client_id, goal_id, opts)
  p transaction
rescue NucleusApi::ApiError => e
  puts "Exception when calling GoalApi->get_goal_transaction_all_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.GoalApi();
var clientId = "63f05f77-1851-477c-9866-88effe5aeca3"; // String | client_id

var goalId = "6c6ef8fa-09d3-462b-a6a8-aafadf7f378f"; // String | UUID goal_id

var opts = {
    'currencyConversion': null, // String | Currency Code
    'endDate': new Date("2013-10-20"), // Date | end date
    'getLatest': false, // Boolean | get_latest
    'portfolioGoal': false, // Boolean | portfolio_goal
    'sortType': null, // String | sort_type
    'startDate': new Date("2013-10-20") // Date | start date
};

var goaltransaction = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' + data);
    }
};
apiInstance.getGoalTransactionAllUsingGet(clientId, goalId, opts, goaltransaction)

Example Response

{
  "content": [
    {
            "id": "5736e6f7-5e12-448e-830c-c1f2b9317d48",
            "create_date": "2018-02-07T19:29:37.000+0000",
            "update_date": "2018-02-012T09:00:00.000+0000",
            "date": "2018-01-31T00:00:00.000+0000",
            "date_available": null,
            "is_recurring": false,
            "is_cleansed": false,
            "is_disputed": false,
            "is_read": true,
            "portfolio_id": "b4c033db-9d05-4a33-8e28-40650d454487",
            "model_id": "4b61f78e-d80e-452d-8201-b1adb87f5bb4",
            "price": 432.2,
            "quantity": 0.5,
            "currency_code": null,
            "amount": null,
            "balance": null,
            "merchant_id": null,
            "mid": null,
            "merchant": null,
            "merchant_category_code": null,
            "transaction_category_id": null,
            "category": null,
            "subcategory": null,
            "description": null,
            "memo": null,
            "status": null,
            "location": {},
            "check": {},
            "funding_id": null,
            "security_id": "cf9de92f-1c59-4188-93af-d7d5cefd0644",
            "transaction_code_id": "f5af397b-7d22-433f-b01e-8202184a6386"
    },
    {
            "id": "44842cc6-37e5-44de-a799-f5c869a80726",
            "create_date": "2017-08-02T04:30:25.000+0000",
            "update_date": "2017-11-18T09:00:00.000+0000",
            "date": "2018-01-31T00:00:00.000+0000",
            "date_available": null,
            "is_recurring": false,
            "is_cleansed": false,
            "is_disputed": false,
            "is_read": true,
            "portfolio_id": "fad85772-ded2-4f12-90f7-28e68afcac6f",
            "model_id": "72ebcdfa-70c7-427b-aebb-0df000b3a0a0",
            "price": 132.2,
            "quantity": 4,
            "currency_code": null,
            "amount": null,
            "balance": null,
            "transaction_category_id": null,
            "merchant_id": null,
            "mid": null,
            "merchant": null,
            "category": null,
            "subcategory": null,
            "description": null,
            "memo": null,
            "status": null,
            "location": {},
            "check": {},
            "funding_id": null,
            "security_id": "6d413c-f195-4b83-b101-f3d65da5a637",
            "transaction_code_id": "f5af397b-7d22-433f-b01e-8202184a6386"
    }
  ],
  "total_pages": 1,
  "total_elements": 2,
  "last": true,
  "sort": [
      {
        "direction": "DESC",
        "property": "id",
        "ignore_case": false,
        "null_handling": "NATIVE",
        "descending": true,
        "ascending": false
      }
  ],
  "first": true,
  "number_of_elements": 2,
  "size": 25,
  "number": 2
}

Get the information for all transactions under portfolios associated with a particular goal. Transaction records are created at the portfolio level and all transactions for each portfolio below an account contributing to the goal are returned to show the transaction activity for the goal. Must provide the unique goal_id. To obtain the appropriate goal_id, use the GET /goal endpoint to view all goals defined for your tenant.

HTTP REQUEST

GET /goal/{goal_id}/transaction?client_id={client_id}

ARGUMENTS

Parameter Type Required Description
client_id UUID required Id of the client subscribed to the goal
portfolio_goal boolean optional If you are storing goals at a portfolio level in /portfolio_goal, then set this to true. Defaults to false, which means you are storing at an account level in /account_allocation
start_date date optional Start date for the data. Defaults to the first date if not set
end_date date optional End date for the data. Defaults to the last date if not set
currency_conversion string optional Alphabetic currency code for the currency to convert all monetary values to. Value may be USD, GBP, EUR, AUD, CAD. Only available in enterprise plan.

RESPONSE

Field Type Description
id UUID The id for the transaction record
portfolio_id UUID The id of the portfolio that the transaction record relates to
funding_id UUID The id of the funding request that the transaction record relates to
model_id UUID The id of the model to which the portfolio that the transaction falls under subscribes
security_id UUID The id of the security that was bought or sold in the transaction.
transaction_code_id UUID The id of the transaction code for the type of transaction
date timestamp Timestamp when the transaction occurred
date_available timestamp Timestamp when the transaction becomes available
price double Price at which the security was bought or sold
quantity double Quantity of units of a security that were bought or sold
currency_code string Alphabetic currency code for the amount. See currency codes
amount double Amount of the transaction
balance double Updated balance of the portfolio as a result of the transaction
merchant_id UUID ID of the merchant resource for the transaction
mid string Acquirer ID of the merchant (MID) for the transaction
merchant string The merchant for the transaction such as the merchant posted for a credit or debit card charge
merchant_category_code string The MCC Code for the merchant as identified by the card network
transaction_category_id string ID of the category resource for the transaction
category string Category of the transaction
subcategory string Subcategory of the transaction
description string Description of the transaction
memo string Memo attached to the transaction
status string Status of the transaction
location map Location where the transaction occurred
      address_line1 string Primary information for the street address, such as the street and building number
      address_line2 string Secondary information for the street address, such as a suite or apartment number
      city string City for the address
      state string State, province, or sub-country region for the address
      postalcode string Alphanumeric postal code or zip code for the address
      country string Country for the address using the ISO ALPHA-2 Code. See country codes
      latitude double Latitude of the location where the transaction occurred
      longitude double Longitude of the location where the transaction occurred
check map Check associated with the banking transaction
      check_number string Number on the check such as “1234”
      check_amount double Monetary amount of the check
      check_images map Image(s) of the scanned check(s)
            image_url string URL where the image can be displayed
            image_type string Type of image for the check such as “png” or “jpeg”
is_cleansed boolean Indicates if the transaction has been cleansed by a data cleansing engine. Defaults to false which indicates that it has not been cleansed
is_read boolean Indicates if the transaction has been read. Defaults to false which indicates that it has not been read
is_recurring boolean Indicates if the transaction is recurring such as a subscription. Defaults to false which indicates that it is not recurring
is_disputed boolean Indicates if the transaction is disputed by the client. Defaults to false which indicates that it is not disputed
secondary_id string Alternate id that can be used to identify the object such as an internal id
create_date timestamp Timestamp for the date and time that the record was created
update_date timestamp Timestamp for the date and time that the record was last updated

Get aggregate goal data

Aggregates goal metadata and asset size for a given client. This is useful for clients that have many accounts with multiple goals that are associated across accounts.

Field Type Description
client_id UUID The id of the client
client_first_name string First name of the client
client_last_name string Last name of the client
client_asset_size double Total asset size of client across all accounts
client_asset_size_date date Date of the latest client_asset_size for the given client_id
client_view_goal_data array List of goal details for the client
      goal_id UUID The id of the goal
      goal_name string Name of the goal
      goal_amount double Target monetary amount to be reached within the goal horizon
      is_decumulation boolean Indicator if the goal is a decumulation goal such as saving for retirement. Default is false, indicating that the goal is an accumulation goal
      goal_category string Category of the goal
      goal_type string Type of goal
      accumulation_horizon double Time horizon of the goal during the accumulation phase, in years
      decumulation_horizon double Time horizon of the goal during the decumulation phase, in years. If the goal is an accumulation goal, then this can be 0 or omitted entirely
      goal_create_date timestamp Timestamp for the date and time the goal was created
      goal_update_date timestamp Timestamp for the date and time the goal was last updated
      goal_asset_size_by_goal double Sum of latest asset sizes across all accounts in this goal_id for the client
      goal_asset_size_by_goal_date date Date used for the goal_asset_size_by_goal
      accounts array List of client’s accounts that are associated to this goal_id if tracked under an account
          account_id UUID The id of the account
          account_name string Name of the account
          account_type_id UUID The id of the account type
          account_type_name string Name of the account type
          goal_asset_size_by_account double Latest asset size for the account_id in this goal
          goal_asset_size_by_account_date date Date of goal_asset_size_by_account
      portfolios array List of client’s portfolios that are associated to this goal_id if tracked under a portfolio
          portfolio_id UUID The id of the portfolio
          portfolio_name string Name of the portfolio
          goal_asset_size_by_portfolio double Latest asset size for the portfolio_id in this goal
          goal_asset_size_by_portfolio_date date Date of goal_asset_size_by_portfolio

HTTP REQUEST

GET /client/{client_id}/goal_overview

Example Request

curl -X GET -H "Authorization: Bearer <access_token>" \
  "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/client/0797efda-cf8b-4661-9cb4-d1e8966a3dcd/goal_overview"
api_instance = nucleus_api.ClientApi(nucleus_api.ApiClient(configuration))
try:
    api_response = api_instance.get_client_goal_overview_using_get("2d2f4ef1-6c13-47b6-9ba2-0e26587ba2db")
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_client_goal_overview_using_get: %s\n" % e)
GoalApi apiInstance = new ClientApi();
        try {
            Object goalroverview = apiInstance.getClientGoalOverviewUsingGet(UUID.fromString("489a13a9-aab1-42d9-a84f-1ab0d95c919c"), true);
            System.out.println(goalroverview);
        } catch (ApiException e) {
            System.err.println("Exception when calling getClientAdvisorOverviewUsingGet");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\ClientApi(
    new GuzzleHttp\Client(),
    $config);
$client_id = "489a13a9-aab1-42d9-a84f-1ab0d95c919c"; // string | UUID client_id
$portfolio_goal = false; // bool | portfolio_goal

try {
    $clientgoal = $apiInstance->getClientGoalOverviewUsingGet($client_id, $portfolio_goal);
    print_r($clientgoal);
} catch (Exception $e) {
    echo 'Exception when calling ClientApi->getClientGoalOverviewUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::ClientApi.new
client_id = '489a13a9-aab1-42d9-a84f-1ab0d95c919c' # String | UUID client_id

opts = {
    portfolio_goal: false # BOOLEAN | portfolio_goal
}

begin
  goaldetails = api_instance.get_client_goal_overview_using_get(client_id, opts)
  p goaldetails
rescue NucleusApi::ApiError => e
  puts "Exception when calling ClientApi->get_client_goal_overview_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.ClientApi();
var goaloverview = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' + data);
    }
};

    var clientId = "489a13a9-aab1-42d9-a84f-1ab0d95c919c"; // String | UUID client_id
    var opts = {
        'portfolioGoal': false // Boolean | portfolio_goal
    };
    apiInstance.getClientGoalOverviewUsingGet(clientId, opts, goaloverview)

–>

Example Response

{
  "client_id": "0797efda-cf8b-4661-9cb4-d1e8966a3dcd",
  "client_first_name": "Oscar",
  "client_last_name": "Martinez",
  "client_asset_size": 88529.95191999999,
  "client_asset_size_date": "2019-09-13",
  "client_view_goal_data": [
    {
      "goal_id": "2fdafedb-c2d2-4ea5-9301-309193bbbcc7",
      "goal_name": "Retirement Saving",
      "goal_amount": null,
      "is_decumulation": true,
      "goal_category": "Retirement",
      "goal_type": "Tenant Level",
      "accumulation_horizon": null,
      "decumulation_horizon": null,
      "goal_create_date": "2019-09-26T22:31:11.000+0000",
      "goal_update_date": "2019-09-26T22:31:11.000+0000",
      "goal_asset_size_by_goal": 4426497.596,
      "goal_asset_size_by_goal_date": "2019-09-13",
      "accounts": [
        {
          "account_id": "4d7efcea-2f85-4442-8268-c0c1e82ca618",
          "account_name": "Investment",
          "account_type_id": "9d10a266-c7aa-4bb8-aa81-84e2c5291097",
          "account_type_name": "Investment",
          "goal_asset_size_by_account": 741114.543,
          "goal_asset_size_by_account_date": "2019-09-13"
        },
        {
          "account_id": "f450e1f9-ee02-44a2-b947-d7bcb4ee07f1",
          "account_name": "Investment",
          "account_type_id": "9d10a266-c7aa-4bb8-aa81-84e2c5291097",
          "account_type_name": "Investment",
          "goal_asset_size_by_account": 3685383.053,
          "goal_asset_size_by_account_date": "2019-09-13"
        }
      ]
    }
  ]
}

Goal Track

Goal track is used to store the current status of a goal at a point in time and track the progress over time. The status information stored includes the goal amount, the accumulation and decumulation horizons, the accounts participating in the goal, the current goal balance, and the metrics for whether or not the goal will be achieved such as if the goal is on track to be met. The metrics for whether or not the goal will be achieved can be obtained using the Proton API tool, but this is not required.

Field Type Description
id UUID The id for the goal track record
goal_id UUID The id of a goal to which the goal track record pertains
client_id UUID The id of a client to whom the goal for the goal track record belongs
goal_amount double Target amount for the goal
accumulation_horizon double The time horizon of the goal during the accumulation phase, in years
decumulation_horizon double The time horizon of the goal during the decumulation phase, in years
accounts array List of accounts linked to the goal
      account_id UUID The id of the account linked to the goal
current_investment double The current amount invested toward the goal
on_track boolean Indicator for whether or not the goal is on track to be met. true indicates it is on track (no default)
progress double The goal progress percentage as a decimal
goal_probability double The probability of achieving the goal with the client’s given investments
goal_achievement_score double Probability of achieving the goal in relation to the confidence target of a simulation
projection_balance double The projected balance of the goal
projection_date date The date of the projected balance of the goal
status_time_stamp datetime Date and time to which this goal track record applies, defaults to the current timestamp
metadata map Custom information associated with the goal track record in the format key:value
See Metadata
secondary_id string Alternate id that can be used to identify the object such as an internal id
create_date timestamp Timestamp for the date and time that the record was created
update_date timestamp Timestamp for the date and time that the record was last updated

List all goal track records

Example Request

curl -X GET -H "Authorization: Bearer <access_token>" \
  "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/goal_track"
api_instance = nucleus_api.GoalApi(nucleus_api.ApiClient(configuration))
try:
    api_response = api_instance.get_goal_track_all_using_get()
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_goal_track_all_using_get: %s\n" % e)
GoalApi apiInstance = new GoalApi();
        try {
            PageGoalTrack List = apiInstance.getGoalTrackAllUsingGet(true, "2020-08-25", null, true, null, 0, 10, "2020-08-01");
            System.out.println(List);
        } catch (ApiException e) {
            System.err.println("Exception when calling getGoalTrackAllUsingGet");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\GoalApi(
    new GuzzleHttp\Client(),
    $config);
$ascending = false; // bool | ascending
$end_date = "2020-05-08"; // string | end date
$filter = null; // string | filter
$get_latest = true; // bool | true or false
$order_by = null; // string | order_by
$page = 0; // int | page
$size = 10; // int | size
$start_date = "2020-08-05"; // string | start date

try {
    $goaltracklist = $apiInstance->getGoalTrackAllUsingGet($ascending, $end_date, $filter, $get_latest, $order_by, $page, $size, $start_date);
    print_r($goaltracklist);
} catch (Exception $e) {
    echo 'Exception when calling GoalApi->getGoalTrackAllUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::GoalApi.new
opts = {
    ascending: false, # BOOLEAN | ascending
    end_date: '2018-08-05', # String | end date
    filter: null, # String | filter
    get_latest: true, # BOOLEAN | true or false
    order_by: null, # String | order_by
    page: 0, # Integer | page
    size: 25, # Integer | size
    start_date: '2018-10-04' # String | start date
}

begin
  tracklist = api_instance.get_goal_track_all_using_get(opts)
  p tracklist
rescue NucleusApi::ApiError => e
  puts "Exception when calling GoalApi->get_goal_track_all_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.GoalApi();
var opts = {
    'ascending': false, // Boolean | ascending
    // 'filter': "", // String | filter
    'orderBy': "update_date", // String | order_by
    'page': 0, // Number | page
    'size': 25 // Number | size
};

var goaltracklist = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.getGoalTrackAllUsingGet(opts, goaltracklist)

Example Response

{
    "content": [
      {
        "id": "4e1c4f70-8611-44fa-bac5-f9f390c16852",
        "create_date": "2018-11-14T00:00:00.000+0000",
        "goal_id": "9a1c0a9f-c699-46a2-9710-8b2abe10526c",
        "client_id": "2035f52d-2c5b-4e07-8904-cb037bad7aff",
        "goal_amount": 15000,
        "accumulation_horizon": 12,
        "accounts": [
          {"account_id": "a2579980-71b0-4b2e-a39c-09e529d10267"},
          {"account_id": "1c28dade-8679-4df5-9b9d-c508d04fcb0c"},
        ],
        "current_investment": 5000.00,
        "on_track": true,
        "progress": 0.33333,
        "goal_probability": 0.95,
        "goal_achievement_score": 100,
        "projection_balance": "15002.34",
        "projection_date": "2030-11-20",
        "metadata": {
          "simulation_tool": "proton"
        }
      },
      {
        "id": "277591f3-e5ea-4314-961f-0a9c935223ce",
        "create_date": "2018-11-14T00:00:00.000+0000",
        "goal_id": "7db7ba7d-9bcb-420a-92b6-0e69478f0e08",
        "goal_amount": 5000,
        "accumulation_horizon": 7,
        "accounts": [
          {"account_id": "5392beff-6e2a-4fcf-92c1-024c385dae15"},
        ],
        "current_investment": "1205.51",
        "on_track": true,
        "progress": 0.241102,
        "goal_probability": 0.99,
        "projection_balance": "5100.17",
        "projection_date": "2025-11-20",
        "metadata": {
          "simulation_tool": "proton"
        }
      }
    ],
    "last": false,
    "total_pages": 1,
    "total_elements": 2,
    "sort": [
        {
            "direction": "DESC",
            "property": "updateDate",
            "ignore_case": false,
            "null_handling": "NATIVE",
            "descending": true,
            "ascending": false
        }
    ],
    "first": true,
    "number_of_elements": 2,
    "size": 25,
    "number": 0
}

Get information for all goal track records stored for your tenant. You can filter using a unique client_id, goal_id or account_id to view the goal track records for a client’s goals, a specific goal, or goals tied to an account. Use the endpoints GET /client, GET /goal or GET /account to identify the appropriate client_id, goal_id or account_id. Note that the information for the accounts associated with the goal and the metadata information are stored as nested objects within the goal track object.

HTTP REQUEST

GET /goal_track

Create a goal track record

Example Request

curl -X POST -H "Authorization: Bearer <access_token>" \
-H "Content-Type: application/json" \
-d '{
        "goal_id": "9a1c0a9f-c699-46a2-9710-8b2abe10526c",
        "client_id": "2035f52d-2c5b-4e07-8904-cb037bad7aff",
        "goal_amount": 15000,
        "accumulation_horizon": 12,
        "accounts": [
          {"account_id": "a2579980-71b0-4b2e-a39c-09e529d10267"},
          {"account_id": "1c28dade-8679-4df5-9b9d-c508d04fcb0c"}
        ],
        "current_investment": 5000.00,
        "on_track": true,
        "progress": 0.33333,
        "goal_probability": 0.95,
        "goal_achievement_score": 100,
        "projection_balance": "15002.34",
        "projection_date": "2030-11-20",
        "metadata": {
          "simulation_tool": "proton"
        }
    }' "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/goal_track"
api_instance = nucleus_api.GoalApi(nucleus_api.ApiClient(configuration))
# # Create a GoalTrack
goal_track = nucleus_api.GoalTrack(goal_id="cf2179b1-6d6d-47ed-8bc7-66308f6e13ab", status_time_stamp="2020-10-10")
try:
    api_response = api_instance.create_goal_track_using_post(goal_track)
    pprint(api_response)
except ApiException as e:
    print("create_goal_track_using_post: %s\n" % e)
GoalApi apiInstance = new GoalApi();
        //Create a Goal Track
        GoalTrack gtrack = new GoalTrack();
        gtrack.goalId(UUID.fromString("cf2179b1-6d6d-47ed-8bc7-66308f6e13ab"));

        try {
            GoalTrack result = apiInstance.createGoalTrackUsingPost(gtrack);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling createGoalTrackUsingPost");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\GoalApi(
    new GuzzleHttp\Client(),
    $config);
//Create GoalTrack
$goaltrack = new \com\hydrogen\nucleus\Model\GoalTrack();

try {
    $goaltrack->setGoalId("cf2179b1-6d6d-47ed-8bc7-66308f6e13ab");
    $result = $apiInstance->createGoalTrackUsingPost($goaltrack);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->createGoalTrackUsingPost: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::GoalApi.new
#Create GoalTrack
goal_track = NucleusApi::GoalTrack.new

begin
  goal_track.goal_id = "cf2179b1-6d6d-47ed-8bc7-66308f6e13ab"
  result = api_instance.create_goal_track_using_post(goal_track)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->create_goal_track_using_post: #{e}"
end
var apiInstance = new HydrogenNucleusApi.GoalApi();
//Create a GoalTrack
var goaltrack = new HydrogenNucleusApi.GoalTrack();
goaltrack.goal_id = "cf2179b1-6d6d-47ed-8bc7-66308f6e13ab";


var newgoal = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.createGoalTrackUsingPost(goaltrack, newgoal)

Example Response

{
  "id": "4e1c4f70-8611-44fa-bac5-f9f390c16852",
  "create_date": "2018-11-14T00:00:00.000+0000",
  "goal_id": "9a1c0a9f-c699-46a2-9710-8b2abe10526c",
  "client_id": "2035f52d-2c5b-4e07-8904-cb037bad7aff",
  "goal_amount": 15000,
  "accumulation_horizon": 12,
  "accounts": [
    {"account_id": "a2579980-71b0-4b2e-a39c-09e529d10267"},
    {"account_id": "1c28dade-8679-4df5-9b9d-c508d04fcb0c"}
  ],
  "current_investment": 5000.00,
  "on_track": true,
  "progress": 0.33333,
  "goal_probability": 0.95,
  "goal_achievement_score": 100,
  "projection_balance": "15002.34",
  "projection_date": "2030-11-20",
  "metadata": {
    "simulation_tool": "proton"
  }
}

Create a goal track record for a goal under a client. The client_id and goal_id must be provided. To obtain the appropriate client_id and goal_id, use the GET /client and GET /goal endpoint to view all clients and all goals defined for your tenant. The endpoint returns a goal_track_id that can then be used to manage the goal track record.

HTTP REQUEST

POST /goal_track

ARGUMENTS

Parameter Type Required Description
goal_id UUID required The id of a goal to which the goal track record pertains
client_id UUID optional The id of a client to whom the goal for the goal track record belongs
goal_amount double optional Target amount for the goal
accumulation_horizon double optional The time horizon of the goal during the accumulation phase, in years
decumulation_horizon double optional The time horizon of the goal during the decumulation phase, in years
accounts array optional List of accounts linked to the goal
      account_id UUID required The id of the account linked to the goal
current_investment double optional The current amount invested toward the goal
on_track boolean optional Indicator for whether or not the goal is on track to be met. true indicates it is on track (no default)
progress double optional The goal progress percentage as a decimal
goal_probability double optional The probability of achieving the goal with the client’s given investments
goal_achievement_score double optional Probability of achieving the goal in relation to the confidence target of a simulation
projection_balance double optional The projected balance of the goal
projection_date date optional The date of the projected balance of the goal
status_time_stamp datetime optional Date and time to which this goal track record applies, defaults to the current timestamp
metadata map optional Custom information associated with the goal track record in the format key:value
See Metadata
secondary_id string optional Alternate id that can be used to identify the object such as an internal id

Retrieve a goal track record

Example Request

curl -X GET -H "Authorization: Bearer <access_token>" \
  "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/goal_track/4e1c4f70-8611-44fa-bac5-f9f390c16852"
api_instance = nucleus_api.GoalApi(nucleus_api.ApiClient(configuration))
try:
    api_response = api_instance.get_goal_track_using_get("239cfdfb-5229-475f-bdfb-8ae26b749c8f")
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_goal_track_using_get: %s\n" % e)
GoalApi apiInstance = new GoalApi();
        try {
            GoalTrack responseGoalTrack = apiInstance.getGoalTrackUsingGet(UUID.fromString("0d83c1be-c967-4af7-94b2-84b34874b2d3"));
            System.out.println(responseGoalTrack);
        } catch (ApiException e) {
            System.err.println("Exception when calling getGoalTrackUsingGet");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\GoalApi(
    new GuzzleHttp\Client(),
    $config);
$goal_track_id = "0d83c1be-c967-4af7-94b2-84b34874b2d3"; // string | UUID goal_track_id

try {
    $goaltrack = $apiInstance->getGoalTrackUsingGet($goal_track_id);
    print_r($goaltrack);
} catch (Exception $e) {
    echo 'Exception when calling GoalApi->getGoalTrackUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::GoalApi.new
goal_track_id = '0d83c1be-c967-4af7-94b2-84b34874b2d3' # String | UUID goal_track_id
begin
  track = api_instance.get_goal_track_using_get(goal_track_id)
  p track
rescue NucleusApi::ApiError => e
  puts "Exception when calling GoalApi->get_goal_track_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.GoalApi();
var goaltrackId = "0d83c1be-c967-4af7-94b2-84b34874b2d3";


var goaltrack = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.getGoalTrackUsingGet(goaltrackId, goaltrack)

Example Response

{
  "id": "4e1c4f70-8611-44fa-bac5-f9f390c16852",
  "create_date": "2018-11-14T00:00:00.000+0000",
  "goal_id": "9a1c0a9f-c699-46a2-9710-8b2abe10526c",
  "client_id": "2035f52d-2c5b-4e07-8904-cb037bad7aff",
  "goal_amount": 15000,
  "accumulation_horizon": 12,
  "accounts": [
    {"account_id": "a2579980-71b0-4b2e-a39c-09e529d10267"},
    {"account_id": "1c28dade-8679-4df5-9b9d-c508d04fcb0c"}
  ],
  "current_investment": 5000.00,
  "on_track": true,
  "progress": 0.33333,
  "goal_probability": 0.95,
  "goal_achievement_score": 100,
  "projection_balance": "15002.34",
  "projection_date": "2030-11-20",
  "metadata": {
    "simulation_tool": "proton"
  }
}

Retrieve the information for a specific goal track record for a goal under a client. The unique goal_track_id must be provided. The endpoint returns the goal_track_id and details for the goal track record specified. Note that the information for the accounts associated with the goal and the metadata information are stored as nested objects within the goal track object.

HTTP REQUEST

GET /goal_track/{goal_track_id}

Update a goal track record

Example Request

curl -X PUT -H "Authorization: Bearer <access_token>" \
-H "Content-Type: application/json" \
-d '{
        "goal_id": "9a1c0a9f-c699-46a2-9710-8b2abe10526c",
        "client_id": "2035f52d-2c5b-4e07-8904-cb037bad7aff",
        "goal_amount": 15000,
        "accumulation_horizon": 12,
        "accounts": [
          {"account_id": "a2579980-71b0-4b2e-a39c-09e529d10267"},
          {"account_id": "1c28dade-8679-4df5-9b9d-c508d04fcb0c"}
        ],
        "current_investment": 5000.00,
        "on_track": true,
        "progress": 0.33333,
        "goal_probability": 0.95,
        "goal_achievement_score": 100,
        "projection_balance": "15002.34",
        "projection_date": "2030-11-20",
        "metadata": {
          "simulation_tool": "proton"
        }
    }' "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/goal_track/199a8c08-cdd5-4c8c-8abf-535447cea11b"
api_instance = nucleus_api.GoalApi(nucleus_api.ApiClient(configuration))
# # Update a GoalTrack
goal_track_update = {'goal_amount': '1000'}
goal_track_id = 'de0346dd-c97c-440a-bef9-f6ae5102f676'
try:
    api_response = api_instance.update_goal_track_using_put(goal_track_update, goal_track_id)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling update_goal_using_put: %s\n" % e)
GoalApi apiInstance = new GoalApi();
        //Update GoalTrack
        Map map = new HashMap();
        map.put("goal_amount", "100.0");

        try {
            GoalTrack response = apiInstance.updateGoalTrackUsingPut(map, UUID.fromString("329ec456-af2b-4062-8bbb-4759798d65e3"));
            System.out.println(response);
        } catch (ApiException e) {
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\GoalApi(
    new GuzzleHttp\Client(),
    $config);
//Update GoalTrack
$goaltrack_update = new stdClass();
$goaltrack_id = "329ec456-af2b-4062-8bbb-4759798d65e3";

try {
    $goaltrack_update->goal_amount = "600";
    $result = $apiInstance->updateGoalTrackUsingPut($goaltrack_update, $goaltrack_id);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->updateGoalTrackUsingPut: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::GoalApi.new
#Update GoalTrack
goal_track_update = {"goal_amount" => '2000'}
goal_track_id = '9f573090-7556-453b-881f-606993e1dfdd'
begin
  result = api_instance.update_goal_track_using_put(goal_track_update, goal_track_id)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->update_goal_track_using_put: #{e}"
end
var apiInstance = new HydrogenNucleusApi.GoalApi();
// //Update GoalTrack
var apiInstance = new HydrogenNucleusApi.GoalApi();
var callback = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
var goalupdate = new HydrogenNucleusApi.GoalTrack();
var goalid = '73a9c932-15f6-4c9e-b1fd-459920623056';

goalupdate.goal_amount = "600";
apiInstance.updateGoalUsingPut(goalupdate, goalid, callback)

Example Response

{
  "id": "4e1c4f70-8611-44fa-bac5-f9f390c16852",
  "create_date": "2018-11-14T00:00:00.000+0000",
  "update_date": "2018-11-16T00:00:00.000+0000",
  "goal_id": "9a1c0a9f-c699-46a2-9710-8b2abe10526c",
  "client_id": "2035f52d-2c5b-4e07-8904-cb037bad7aff",
  "goal_amount": 15000,
  "accumulation_horizon": 12,
  "accounts": [
    {"account_id": "a2579980-71b0-4b2e-a39c-09e529d10267"},
    {"account_id": "1c28dade-8679-4df5-9b9d-c508d04fcb0c"}
  ],
  "current_investment": 5000.00,
  "on_track": true,
  "progress": 0.33333,
  "goal_probability": 0.95,
  "goal_achievement_score": 100,
  "projection_balance": "15002.34",
  "projection_date": "2030-11-20",
  "metadata": {
    "simulation_tool": "proton"
  }
}

Update the information for a goal track record. The unique goal_track_id must be provided. To obtain the appropriate goal_track_id, use the GET /goal_track endpoint to view all goal track records stored for your tenant and their current information. The details to be updated must also be provided. The endpoint returns the goal_track_id and the details for the goal track record.

HTTP REQUEST

PUT /goal_track/{goal_track_id}

Delete a goal track record

Example Request

curl -X DELETE -H "Authorization: Bearer <access_token>" \
  "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/goal_track/199a8c08-cdd5-4c8c-8abf-535447cea11b"
api_instance = nucleus_api.GoalApi(nucleus_api.ApiClient(configuration))
# # Delete a GoalTrack
d_goaltrack_id = '0d83c1be-c967-4af7-94b2-84b34874b2d3'
try:
    api_instance.delete_goal_track_using_delete(d_goaltrack_id)
except ApiException as e:
    print("Exception when delete_goal_track_using_delete: %s\n" % e)
GoalApi apiInstance = new GoalApi();
        //Delete a GoalTrack
        try {
            GoalTrack deleteresponse = apiInstance.deleteGoalTrackUsingDelete(UUID.fromString("17c9f4fe-100c-4d62-8acf-fb19cc038f5c"));
            System.out.println(deleteresponse);
        } catch (ApiException e) {
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\GoalApi(
    new GuzzleHttp\Client(),
    $config);
//Delete GoalTrack
$goaltrack_did = "9f573090-7556-453b-881f-606993e1dfdd"; // string | UUID account_id

try {
    $apiInstance->deleteGoalTrackUsingDelete($goaltrack_did);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->deleteGoalTrackUsingDelete: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::GoalApi.new
#Delete GoalTrack
goal_track1_id = '0d83c1be-c967-4af7-94b2-84b34874b2d3'
begin
  result = api_instance.delete_goal_track_using_delete(goal_track1_id)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->delete_goal_track_using_delete: #{e}"
end
var apiInstance = new HydrogenNucleusApi.GoalApi();
// //Delete a Goal
var goaltrackdid = "0d83c1be-c967-4af7-94b2-84b34874b2d3";
var deletegoaltrack = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully.');
    }
};
apiInstance.deleteGoalTrackUsingDelete(goaltrackdid, deletegoaltrack)

Response (204 No Content)

Permanently delete an goal track record for a goal under a client. The unique goal_track_id must be provided. To obtain the appropriate goal_track_id, use the GET /goal_track endpoint to view all goal track records stored for your tenant. This deletes the goal_track_id and all goal track record information.

HTTP REQUEST

DELETE /goal_track{goal_track_id}

Household

Household Management

Aggregate clients in the same family into a household entity to view their finances across the household.

Field Type Description
id UUID The id of the household
name string The name of the household
category UUID The category of the household to link households together
subcategory UUID The subcategory of the household to link under a category
household_income double The annual income of the household
members array(map) Members of the household and their relationships to one another
      client_id UUID ID of the client member of the household
      is_primary boolean Indicates if the client is the primary member of the household. Defaults to false which indicates it’s not primary.
      client_relationships array(map) List of member relationships to the client
            client_id UUID ID of the client member of the relationship
            relationship string Relationship of the client to the client member in the household. Value may be father, mother, husband, wife, son, daughter, brother, sister, pet
is_active boolean Indicates if the household is currently active. Defaults to true which indicates it is active
metadata map Custom information associated with the household in the format key:value
See Metadata
secondary_id string Alternate id that can be used to identify the object such as an internal id
create_date timestamp Timestamp for the date and time that the record was created
update_date timestamp Timestamp for the date and time that the record was last updated

List all households

Example Request

curl -X GET -H "Authorization: Bearer <access_token>" \
  "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/household"
api_instance = nucleus_api.HouseholdApi(nucleus_api.ApiClient(configuration))
try:
    api_response = api_instance.get_household_all_using_get()
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_household_all_using_get: %s\n" % e)
HouseholdApi apiInstance = new HouseholdApi();
        try {
            PageHousehold List = apiInstance.getHouseholdAllUsingGet(true, null, null, 0, 10);
            System.out.println(List);
        } catch (ApiException e) {
            System.err.println("Exception when calling getHouseholdAllUsingGet");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\HouseholdApi(
    new GuzzleHttp\Client(),
    $config);
$ascending = false; // bool | ascending
$filter = null; // string | filter
$order_by = null; // string | order_by
$page = 0; // int | page
$size = 10; // int | size

try {
    $householdlist = $apiInstance->getHouseholdAllUsingGet($ascending, $filter, $order_by, $page, $size);
    print_r($householdlist);
} catch (Exception $e) {
    echo 'Exception when calling HouseholdApi->getHouseholdAllUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::HouseholdApi.new
opts = {
    ascending: false, # BOOLEAN | ascending
    filter: null, # String | filter
    order_by: null, # String | order_by
    page: 0, # Integer | page
    size: 25 # Integer | size
}

begin
  householdlist = api_instance.get_household_all_using_get(opts)
  p householdlist
rescue NucleusApi::ApiError => e
  puts "Exception when calling HouseholdApi->get_household_all_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.HouseholdApi();
var opts = {
    'ascending': false, // Boolean | ascending
    // 'filter': "", // String | filter
    'orderBy': "update_date", // String | order_by
    'page': 0, // Number | page
    'size': 25 // Number | size
};

var householdlist = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.getHouseholdAllUsingGet(opts, householdlist)

Example Response

{
    "content": [
        {
            "id": "1692a3c2-65b0-46a0-9a0a-66bc949f7ca1",
            "secondary_id": null,
            "create_date": "2020-01-07T20:54:33.000+0000",
            "update_date": "2020-01-07T20:54:33.000+0000",
            "name": "Young Family",
            "category": null,
            "subcategory": null,
            "household_income": null,
            "members": [
                {
                    "client_id": "87ef9136-f7e1-4ef0-8dbc-e58bf435d11c",
                    "is_primary": true,
                    "client_relationships": [
                        {
                          "client_id": "615663b9-a70e-4e5b-99ae-3b3eef20d6e9",
                          "relationship": "mother"
                        },
                        {
                          "client_id": "72a13a73-c5f6-4728-9454-bd0db32a0e3e",
                          "relationship": "wife"
                        }
                    ]
                },
                {
                    "client_id": "8e1799f0-4429-4939-ae84-7391cff93ba5",
                    "is_primary": true,
                    "client_relationships": [
                        {
                          "client_id": "bad983ab-4706-4463-a6c5-16a07e955c87",
                          "relationship": "father"
                        },
                        {
                          "client_id": "7e74b1d4-bd1c-44a1-8d25-7988a34a54ef",
                          "relationship": "husband"
                        }
                    ]
                }
            ],
            "is_active": true,
            "metadata": {}
        },
        {
          "id": "11291d9b-fce0-4536-b4be-311f1a35c11f",
          "secondary_id": null,
          "create_date": "2020-01-01T06:15:33.000+0000",
          "update_date": "2020-01-01T06:54:33.000+0000",
          "name": "Smith Family",
          "category": null,
          "subcategory": null,
          "household_income": null,
          "members": [
              {
                  "client_id": "8fc301c0-50ef-4803-bb0c-b1dc57ffc85a",
                  "is_primary": true,
                  "client_relationships": [
                      {
                        "client_id": "015fd383-5624-47ce-8f18-404f6dd2de60",
                        "relationship": "sister"
                      },
                      {
                        "client_id": "daugher",
                        "relationship": "38dbd41b-22e0-4a84-97d5-fae5a8b04589"
                      }
                  ]
              },
              {
                  "client_id": "bb8394ca-84bd-4679-ac3e-874edeef15cf",
                  "is_primary": true,
                  "client_relationships": [
                      {
                        "client_id": "34fe4744-1bfd-4356-b2f1-80fb10ae2fc0",
                        "relationship": "brother"
                      },
                      {
                        "client_id": "f28e47b8-72c9-4475-8914-68c5c6775dee",
                        "relationship": "son"
                      }
                  ]
              }
          ],
          "is_active": true,
          "metadata": {}
        }
    ],
    "last": true,
    "total_pages": 1,
    "total_elements": 1,
    "number_of_elements": 1,
    "first": true,
    "sort": [
        {
            "direction": "DESC",
            "property": "updateDate",
            "ignore_case": false,
            "null_handling": "NATIVE",
            "ascending": false,
            "descending": true
        }
    ],
    "size": 25,
    "number": 0
}

Get information for all households stored for your tenant. You can filter using one of the unique ids such as the members.client_id to view the households for a client or for another particular entity.

HTTP REQUEST

GET /household

Create a household

Example Request

curl -X POST -H "Authorization: Bearer <access_token>" \
-H "Content-Type: application/json" \
-d '{
      "name": "Young Family",
      "members": [
          {
              "client_id": "87ef9136-f7e1-4ef0-8dbc-e58bf435d11c",
              "is_primary": true,
              "client_relationships": [
                  {
                    "client_id": "615663b9-a70e-4e5b-99ae-3b3eef20d6e9",
                    "relationship": "mother"
                  },
                  {
                    "client_id": "72a13a73-c5f6-4728-9454-bd0db32a0e3e",
                    "relationship": "wife"
                  }
              ]
          },
          {
              "client_id": "8e1799f0-4429-4939-ae84-7391cff93ba5",
              "is_primary": true,
              "client_relationships": [
                  {
                    "client_id": "bad983ab-4706-4463-a6c5-16a07e955c87",
                    "relationship": "father"
                  },
                  {
                    "client_id": "7e74b1d4-bd1c-44a1-8d25-7988a34a54ef",
                    "relationship": "husband"
                  }
              ]
          }
      ]
    }' "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/household"
api_instance = nucleus_api.HouseholdApi(nucleus_api.ApiClient(configuration))
# # Create a HouseHold
clients1 = nucleus_api.ClientRelationship(client_id="9169484d-235c-47f1-a182-75227b1189f9", relationship="father")
clients2 = nucleus_api.ClientRelationship(client_id="2d7542b9-cf67-488d-881c-93dfae5e2ea9", relationship="brother")
members1 = nucleus_api.Member(client_id="e02f8acc-3977-4f0e-9436-c5b9c28dca09", is_primary="true", client_relationships=[clients1, clients2])
household = nucleus_api.Household(category=None, name="New", members=[members1])
try:
    api_response = api_instance.create_household_using_post(household)
    pprint(api_response)
except ApiException as e:
    print("create_household_using_post: %s\n" % e)
HouseholdApi apiInstance = new HouseholdApi();
        //Create a Household
        Household household = new Household();
        household.setName("New One");
        Member memberstat1 = new Member();
        memberstat1.setClientId(UUID.fromString("e02f8acc-3977-4f0e-9436-c5b9c28dca09"));
        memberstat1.setIsPrimary(false);
        ClientRelationship clientstat1 = new ClientRelationship();
        clientstat1.setClientId(UUID.fromString("9169484d-235c-47f1-a182-75227b1189f9"));
        clientstat1.setRelationship("father");
        ClientRelationship clientstat2 = new ClientRelationship();
        clientstat2.setClientId(UUID.fromString("2d7542b9-cf67-488d-881c-93dfae5e2ea9"));
        clientstat2.setRelationship("brother");
        List <ClientRelationship> data = Arrays.<ClientRelationship>asList(clientstat1, clientstat2);
        memberstat1.clientRelationships(data);
        Member memberstat2 = new Member();
        memberstat2.setClientId(UUID.fromString("903e408d-8a20-406e-9677-b8c7f0b990de"));
        memberstat2.setIsPrimary(false);
        ClientRelationship clientstat10 = new ClientRelationship();
        clientstat10.setClientId(UUID.fromString("9c32753b-09a6-4303-bed7-4d4b07c8bab8"));
        clientstat10.setRelationship("father");
        ClientRelationship clientstat20 = new ClientRelationship();
        clientstat20.setClientId(UUID.fromString("3f876310-0294-459c-83c6-678badc2b7e4"));
        clientstat20.setRelationship("brother");
        List <ClientRelationship> data1 = Arrays.<ClientRelationship>asList(clientstat10, clientstat20);
        memberstat2.clientRelationships(data1);
        List <Member> householddata = Arrays.<Member>asList(memberstat1, memberstat2);
        household.setMembers(householddata);

        try {
            Household result = apiInstance.createHouseholdUsingPost(household);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling createHouseholdUsingPost");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\HouseholdApi(
    new GuzzleHttp\Client(),
    $config);
//Create Household
$household = new \com\hydrogen\nucleus\Model\Household();
$member = new \com\hydrogen\nucleus\Model\Member();
$clientrelation = new \com\hydrogen\nucleus\Model\ClientRelationship();
$clientrelation1 = new \com\hydrogen\nucleus\Model\ClientRelationship();
try {
    $member->setClientId('e02f8acc-3977-4f0e-9436-c5b9c28dca09');
    $member->setIsPrimary("true");
    $clientrelation->setClientId("9169484d-235c-47f1-a182-75227b1189f9");
    $clientrelation->setRelationship("father");
    $clientrelation1->setClientId("2d7542b9-cf67-488d-881c-93dfae5e2ea9");
    $clientrelation1->setRelationship("brother");
    $household->setName("ABC");
    $household->setMembers([$member]);
    $result = $apiInstance->createHouseholdUsingPost($household);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->createHouseholdUsingPost: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::HouseholdApi.new
#Create Household
household = NucleusApi::Household.new
member = NucleusApi::Member.new
client1 = NucleusApi::ClientRelationship.new
client2 = NucleusApi::ClientRelationship.new

begin
  household.name = "MCC"
  member.client_id = "e02f8acc-3977-4f0e-9436-c5b9c28dca09"
  member.is_primary = "false"
  client1.client_id = "9169484d-235c-47f1-a182-75227b1189f9"
  client1.relationship = "father"
  client2.client_id = "2d7542b9-cf67-488d-881c-93dfae5e2ea9"
  client2.relationship = "brother"
  household.members = [member]
  result = api_instance.create_household_using_post(household)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->create_household_using_post: #{e}"
end
var apiInstance = new HydrogenNucleusApi.HouseholdApi();
//Create a Household
var household = new HydrogenNucleusApi.Household();
var clientrelations = new HydrogenNucleusApi.ClientRelationship();
var clientrelations1 = new HydrogenNucleusApi.ClientRelationship();
var member1 = new HydrogenNucleusApi.Member();
member1.client_id = 'e02f8acc-3977-4f0e-9436-c5b9c28dca09';
member1.is_primary = "true";
clientrelations.client_id = '9169484d-235c-47f1-a182-75227b1189f9';
clientrelations.relationship = "father";
clientrelations1.client_id = "2d7542b9-cf67-488d-881c-93dfae5e2ea9";
clientrelations1.relationship = "father";
member1.client_relationships = [clientrelations, clientrelations1];
household.category = "New One";
household.name = "new";
household.members = [member1];


var newhousehold = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.createHouseholdUsingPost(household, newhousehold)

Example Response

{
  "id": "1692a3c2-65b0-46a0-9a0a-66bc949f7ca1",
  "secondary_id": null,
  "create_date": "2020-01-07T20:54:33.000+0000",
  "update_date": "2020-01-07T20:54:33.000+0000",
  "name": "Young Family",
  "category": null,
  "subcategory": null,
  "household_income": null,
  "members": [
      {
          "client_id": "87ef9136-f7e1-4ef0-8dbc-e58bf435d11c",
          "is_primary": true,
          "client_relationships": [
              {
                "client_id": "615663b9-a70e-4e5b-99ae-3b3eef20d6e9",
                "relationship": "mother"
              },
              {
                "client_id": "72a13a73-c5f6-4728-9454-bd0db32a0e3e",
                "relationship": "wife"
              }
          ]
      },
      {
          "client_id": "8e1799f0-4429-4939-ae84-7391cff93ba5",
          "is_primary": true,
          "client_relationships": [
              {
                "client_id": "bad983ab-4706-4463-a6c5-16a07e955c87",
                "relationship": "father"
              },
              {
                "client_id": "7e74b1d4-bd1c-44a1-8d25-7988a34a54ef",
                "relationship": "husband"
              }
          ]
      }
  ],
  "is_active": true,
  "metadata": {}
}

Create a household. The endpoint returns a household_id that can then be used to manage the household.

HTTP REQUEST

POST /household

ARGUMENTS

Parameter Type Required Description
name string required The name of the household
category UUID optional The category of the household to link households together
subcategory UUID optional The subcategory of the household to link under a category
household_income double optional The annual income of the household
members array(map) required Members of the household and their relationships to one another
      client_id UUID required ID of the client member of the household
      is_primary boolean optional Indicates if the client is the primary member of the household. Defaults to false which indicates it’s not primary.
      client_relationships array(map) required List of member relationships to the client
            client_id UUID required ID of the client member of the relationship
            relationship string required Relationship of the client to the client member in the household. Value may be father, mother, husband, wife, son, daughter, brother, sister, pet
is_active boolean optional Indicates if the household is currently active. Defaults to true which indicates it is active
metadata map optional Custom information associated with the household in the format key:value
See Metadata
secondary_id string optional Alternate id that can be used to identify the object such as an internal id

Retrieve a household

Example Request

curl -X GET -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/household/1692a3c2-65b0-46a0-9a0a-66bc949f7ca1"
api_instance = nucleus_api.HouseholdApi(nucleus_api.ApiClient(configuration))
try:
    api_response = api_instance.get_household_using_get("fcb966b5-8da1-4541-a488-07e99074e37b")
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_household_using_get: %s\n" % e)
HouseholdApi apiInstance = new HouseholdApi();
        try {
            Household responseHousehold = apiInstance.getHouseholdUsingGet(UUID.fromString("6f851269-659b-4616-b860-e53e114559c2"));
            System.out.println(responseHousehold);
        } catch (ApiException e) {
            System.err.println("Exception when calling getHouseholdUsingGet");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\HouseholdApi(
    new GuzzleHttp\Client(),
    $config);
$household_id = "6f851269-659b-4616-b860-e53e114559c2"; // string | UUID household_id

try {
    $household = $apiInstance->getHouseholdUsingGet($household_id);
    print_r($household);
} catch (Exception $e) {
    echo 'Exception when calling HouseholdApi->getHouseholdUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::HouseholdApi.new
household_id = '6f851269-659b-4616-b860-e53e114559c2' # String | UUID household_id
begin
  household = api_instance.get_household_using_get(household_id)
  p household
rescue NucleusApi::ApiError => e
  puts "Exception when calling HouseholdApi->get_household_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.HouseholdApi();
var householdID = "6f851269-659b-4616-b860-e53e114559c2";

var household = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.getHouseholdUsingGet(householdID, household)

Example Response

{
  "id": "1692a3c2-65b0-46a0-9a0a-66bc949f7ca1",
  "secondary_id": null,
  "create_date": "2020-01-07T20:54:33.000+0000",
  "update_date": "2020-01-07T20:54:33.000+0000",
  "name": "Young Family",
  "category": null,
  "subcategory": null,
  "household_income": null,
  "members": [
      {
          "client_id": "87ef9136-f7e1-4ef0-8dbc-e58bf435d11c",
          "is_primary": true,
          "client_relationships": [
              {
                "client_id": "615663b9-a70e-4e5b-99ae-3b3eef20d6e9",
                "relationship": "mother"
              },
              {
                "client_id": "72a13a73-c5f6-4728-9454-bd0db32a0e3e",
                "relationship": "wife"
              }
          ]
      },
      {
          "client_id": "8e1799f0-4429-4939-ae84-7391cff93ba5",
          "is_primary": true,
          "client_relationships": [
              {
                "client_id": "bad983ab-4706-4463-a6c5-16a07e955c87",
                "relationship": "father"
              },
              {
                "client_id": "7e74b1d4-bd1c-44a1-8d25-7988a34a54ef",
                "relationship": "husband"
              }
          ]
      }
  ],
  "is_active": true,
  "metadata": {}
}

Retrieve the information for a specific household. The endpoint returns the household_id and details for the household specified.

HTTP REQUEST

GET /household/{household_id}

Update a household

Example Request

curl -X PUT -H "Authorization: Bearer <access_token>" \
-H "Content-Type: application/json" \
-d '{
      "category": "Friends"
    }' "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/household/1692a3c2-65b0-46a0-9a0a-66bc949f7ca1"
api_instance = nucleus_api.HouseholdApi(nucleus_api.ApiClient(configuration))
# # # Update a HouseHold
household_update = {'household_income': '1000'}
household_id = '2347b3d6-7e49-4a45-adc2-ff3bdd384abf'
try:
    api_response = api_instance.update_household_using_put(household_update, household_id)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling update_household_using_put: %s\n" % e)
HouseholdApi apiInstance = new HouseholdApi();
        //Update Household
        Map map = new HashMap();
        map.put("name", "New");

        try {
            Household response = apiInstance.updateHouseholdUsingPut(map, UUID.fromString("aff68a25-13f3-442a-a4f9-8a2f0d289f7c"));
            System.out.println(response);
        } catch (ApiException e) {
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\HouseholdApi(
    new GuzzleHttp\Client(),
    $config);
//Update Household
$household_update = new stdClass();
$household_id = "2347b3d6-7e49-4a45-adc2-ff3bdd384abf";

try {
    $household_update->name = "new";
    $result = $apiInstance->updateHouseholdUsingPut($household_update, $household_id);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->updateHouseholdUsingPut: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::HouseholdApi.new
#Update Household
household_update = {"category" => 'New'}
household_id = '04fefab3-4010-4661-a606-0ed3634e0c78'
begin
  result = api_instance.update_household_using_put(household_update, household_id)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->update_household_using_put: #{e}"
end
var apiInstance = new HydrogenNucleusApi.HouseholdApi();
// //Update Household
var apiInstance = new HydrogenNucleusApi.HouseholdApi();
var callback = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
var householdupdate = new HydrogenNucleusApi.Household();
var householdid = '04fefab3-4010-4661-a606-0ed3634e0c78';

householdupdate.category = "New";
apiInstance.updateHouseholdUsingPut(householdid, householdupdate, callback)

Example Response

{
  "id": "1692a3c2-65b0-46a0-9a0a-66bc949f7ca1",
  "secondary_id": null,
  "create_date": "2020-01-07T20:54:33.000+0000",
  "update_date": "2020-05-07T10:15:12.000+0000",
  "name": "Young Family",
  "category": "Friends",
  "subcategory": null,
  "household_income": null,
  "members": [
      {
          "client_id": "87ef9136-f7e1-4ef0-8dbc-e58bf435d11c",
          "is_primary": true,
          "client_relationships": [
              {
                "client_id": "615663b9-a70e-4e5b-99ae-3b3eef20d6e9",
                "relationship": "mother"
              },
              {
                "client_id": "72a13a73-c5f6-4728-9454-bd0db32a0e3e",
                "relationship": "wife"
              }
          ]
      },
      {
          "client_id": "8e1799f0-4429-4939-ae84-7391cff93ba5",
          "is_primary": true,
          "client_relationships": [
              {
                "client_id": "bad983ab-4706-4463-a6c5-16a07e955c87",
                "relationship": "father"
              },
              {
                "client_id": "7e74b1d4-bd1c-44a1-8d25-7988a34a54ef",
                "relationship": "husband"
              }
          ]
      }
  ],
  "is_active": true,
  "metadata": {}
}

Update the information for a household. The unique household_id must be provided. To obtain the appropriate household_id, use the GET /household endpoint to view all households stored for your tenant and their current information. The details to be updated must also be provided. The endpoint returns the household_id and the details for the card.

HTTP REQUEST

PUT /household/{household_id}

Delete a household

Example Request

curl -X DELETE -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/household/0233ab54-58a0-4b43-aa65-a1c32f29ad69"
api_instance = nucleus_api.HouseholdApi(nucleus_api.ApiClient(configuration))
# # # Delete a HouseHold
household1_id = '17f098af-5d9d-4263-818a-33a934e03265'
try:
    api_instance.delete_household_using_delete(household1_id)
except ApiException as e:
    print("Exception when delete_household_using_delete: %s\n" % e)
HouseholdApi apiInstance = new HouseholdApi();
        //Delete a Household
        try {
            Household deleteresponse = apiInstance.deleteHouseholdUsingDelete(UUID.fromString("8b39a62b-247c-4b72-953e-6f648f5f970d"));
            System.out.println(deleteresponse);
        } catch (ApiException e) {
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\HouseholdApi(
    new GuzzleHttp\Client(),
    $config);
//Delete HouseHold
$household_did = "04fefab3-4010-4661-a606-0ed3634e0c78"; // string | UUID account_id

try {
    $apiInstance->deleteHouseholdUsingDelete($household_did);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->deleteHouseholdUsingDelete: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::HouseholdApi.new

#Delete Household
household1_id = '17f098af-5d9d-4263-818a-33a934e03265'
begin
  result = api_instance.delete_household_using_delete(household1_id)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->delete_household_using_delete: #{e}"
end
var apiInstance = new HydrogenNucleusApi.HouseholdApi();
// //Delete a Goal
var householdidd = "17f098af-5d9d-4263-818a-33a934e03265";
var deletehousehold = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully.');
    }
};
apiInstance.deleteHouseholdUsingDelete(householdidd, deletehousehold)

Response (204 No Content)

Permanently delete a household. The unique household_id must be provided. To obtain the appropriate household_id, use the GET /household endpoint to view all households stored for your tenant. This deletes the household_id and all household record information.

HTTP REQUEST

DELETE /household/{household_id}

Household Activity

List all household asset sizes

Example Request

curl -X GET -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/household/099961da-7f41-4309-950f-2b51689a0033/asset_size"
api_instance = nucleus_api.HouseholdApi(nucleus_api.ApiClient(configuration))
# List all HouseholdClientAssetSize
try:
    api_response = api_instance.get_household_client_asset_size_using_get("fcb966b5-8da1-4541-a488-07e99074e37b")
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_household_client_asset_size_using_get: %s\n" % e)
HouseholdApi apiInstance = new HouseholdApi();
        //List HouseholdAssetSize
        try {
            Object householdasset = apiInstance.getHouseholdClientAssetSizeUsingGet(UUID.fromString("6f851269-659b-4616-b860-e53e114559c2"), null, date2, true, true, null, date1);
            System.out.println(householdasset);
        } catch (ApiException e) {
            System.err.println("Exception when calling getHouseholdClientAssetSizeUsingGet");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\HouseholdApi(
    new GuzzleHttp\Client(),
    $config);
//Get HouseholdAssetSize
$household_id = "6f851269-659b-4616-b860-e53e114559c2"; // string | UUID household_id
$currency_conversion = null; // string | USD
$end_date = new \DateTime("2020-09-14"); // \DateTime | end date
$exclude_subledger = true; // bool | true or false
$get_latest = true; // bool | true or false
$sort_type = null; // string | Quarter (Q), Monthly (M) , Annually (Y), Daily (D) --caps matter, codes in ()
$start_date = new \DateTime("2020-08-14"); // \DateTime | start date

try {
    $householdasset = $apiInstance->getHouseholdClientAssetSizeUsingGet($household_id, $currency_conversion, $end_date, $exclude_subledger, $get_latest, $sort_type, $start_date);
    print_r($householdasset);
} catch (Exception $e) {
    echo 'Exception when calling HouseholdApi->getHouseholdClientAssetSizeUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::HouseholdApi.new
#Get Household AssetSize
household_id = '6f851269-659b-4616-b860-e53e114559c2' # String | UUID household_id

opts = {
    currency_conversion: null, # String | USD
    end_date: Date.parse('2020-01-08'), # Date | end date
    exclude_subledger: true, # BOOLEAN | true or false
    get_latest: true, # BOOLEAN | true or false
    sort_type: null, # String |  Quarter (Q), Monthly (M) , Annually (Y), Daily (D) --caps matter, codes in ()
    start_date: Date.parse('2019-08-23') # Date | start date
}

begin
  assetsize = api_instance.get_household_client_asset_size_using_get(household_id, opts)
  p assetsize
rescue NucleusApi::ApiError => e
  puts "Exception when calling HouseholdApi->get_household_client_asset_size_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.HouseholdApi();
//List all Householdassetsize

var householdId = "6f851269-659b-4616-b860-e53e114559c2";
var opts = {
    'currencyConversion': null, // String | USD
    'endDate': new Date("2018-11-03"), // Date | end date
    'excludeSubledger': true, // Boolean | true or false
    'getLatest': true, // Boolean | true or false
    'sortType': null, // String |  Quarter (Q), Monthly (M) , Annually (Y), Daily (D) --caps matter, codes in ()
    'startDate': new Date("2018-08-01") // Date | start date
};

var asset = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' + data);
    }
};
apiInstance.getHouseholdClientAssetSizeUsingGet(householdId, opts, asset)

Example Response

[
  {
    "date": "2018-02-03",
    "currency_code": "USD",
    "value": 20000,
    "value_available": null,
    "value_pending": null,
    "cash_flow": 0
  },
  {
    "date": "2018-02-04",
    "currency_code": "USD",
    "value": 24500,
    "value_available": null,
    "value_pending": null,
    "cash_flow": 500
  }
]

Get a list of asset sizes per date for a household. Asset size records are created at the portfolio level and aggregated to yield the household asset size(s). The unique household_id must be provided. To obtain the appropriate household_id, use the GET /household endpoint to view all available household_ids registered with your tenant. The endpoint returns a list of asset sizes by date for the household.

HTTP REQUEST

GET /household/{household_id}/asset_size

ARGUMENTS

Parameter Type Required Description
get_latest boolean optional Retrieve only the latest asset size. Defaults to false if not set
sort_type string optional Sort the asset sizes by D Daily, M Monthly, Q Quarterly, Y Yearly. Defaults to D Daily if not set. Must be capital letters
start_date date optional Start date for the data. Defaults to the first date if not set
end_date date optional End date for the data. Defaults to the last date if not set
exclude_subledger boolean optional If set to “true”, excludes portfolios under accounts where is_subledger = “true” to not double count assets of subaccounts. Defaults to “false” which includes all portfolios under an account.
currency_conversion string optional Alphabetic currency code for the currency to convert all monetary values to. Value may be USD, GBP, EUR, AUD, CAD. Only available in enterprise plan.

RESPONSE

Field Type Description
date date Date for the asset size record. Displays the latest record if more than one entry exists for the given date.
currency_code string Alphabetic currency code for the asset size. See currency codes
value double Monetary value of all the household’s accounts on the particular date
value_available double Available monetary value of the household on the particular date
value_pending double Pending monetary value of the household on the particular date
cash_flow double Amount added to the household’s accounts or withdrawn from the accounts since the last asset size date. Value is used for performance calculations. Value may be positive or negative.

List all household holdings

Example Request

curl -X GET -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/household/099961da-7f41-4309-950f-2b51689a0033/holding"
api_instance = nucleus_api.HouseholdApi(nucleus_api.ApiClient(configuration))
# List all HouseholdClientHolding
try:
    api_response = api_instance.get_household_client_holding_using_get("fcb966b5-8da1-4541-a488-07e99074e37b")
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_household_client_holding_using_get: %s\n" % e)
HouseholdApi apiInstance = new HouseholdApi();
        //List HouseholdHolding
        try {
            Object householdholding = apiInstance.getHouseholdClientHoldingUsingGet(UUID.fromString("6f851269-659b-4616-b860-e53e114559c2"), null, date2, true, date1);
            System.out.println(householdholding);
        } catch (ApiException e) {
            System.err.println("Exception when calling getHouseholdClientHoldingUsingGet");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\HouseholdApi(
    new GuzzleHttp\Client(),
    $config);
//GetHouseholdHolding
$household_id = "6f851269-659b-4616-b860-e53e114559c2"; // string | UUID household_id
$currency_conversion = null; // string | USD
$end_date = new \DateTime("2020-09-14"); // \DateTime | end date - yyyy-mm-dd
$get_latest = true; // bool | true or false
$start_date = new \DateTime("2020-08-14"); // \DateTime | start date - yyyy-mm-dd

try {
    $householdholding = $apiInstance->getHouseholdClientHoldingUsingGet($household_id, $currency_conversion, $end_date, $get_latest, $start_date);
    print_r($householdholding);
} catch (Exception $e) {
    echo 'Exception when calling HouseholdApi->getHouseholdClientHoldingUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::HouseholdApi.new
#Get all Holdings
household_id = '6f851269-659b-4616-b860-e53e114559c2' # String | UUID household_id

opts = {
    currency_conversion: null, # String | USD
    end_date: Date.parse('2013-10-20'), # Date | end date - yyyy-mm-dd
    get_latest: true, # BOOLEAN | true or false
    start_date: Date.parse('2013-10-20') # Date | start date - yyyy-mm-dd
}

begin
  holding = api_instance.get_household_client_holding_using_get(household_id, opts)
  p holding
rescue NucleusApi::ApiError => e
  puts "Exception when calling HouseholdApi->get_household_client_holding_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.HouseholdApi();
var householdId = "6f851269-659b-4616-b860-e53e114559c2";
var opts = {
    'currencyConversion': null, // String | USD
    'endDate': new Date("2018-11-03"), // Date | end date
    'excludeSubledger': true, // Boolean | true or false
    'getLatest': true, // Boolean | true or false
    'sortType': null, // String |  Quarter (Q), Monthly (M) , Annually (Y), Daily (D) --caps matter, codes in ()
    'startDate': new Date("2018-08-01") // Date | start date
};

var holding = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' + data);
    }
};
apiInstance.getHouseholdClientHoldingUsingGet(householdId, opts, holding)

Example Response

{
  "id": "1692a3c2-65b0-46a0-9a0a-66bc949f7ca1",
  "secondary_id": null,
  "create_date": "2020-01-07T20:54:33.000+0000",
  "update_date": "2020-05-07T10:15:12.000+0000",
  "name": "Young Family",
  "category": "Friends",
  "subcategory": null,
  "household_income": null,
  "members": [
      {
          "client_id": "87ef9136-f7e1-4ef0-8dbc-e58bf435d11c",
          "is_primary": true,
          "client_relationships": [
              {
                "client_id": "615663b9-a70e-4e5b-99ae-3b3eef20d6e9",
                "relationship": "mother"
              },
              {
                "client_id": "72a13a73-c5f6-4728-9454-bd0db32a0e3e",
                "relationship": "wife"
              }
          ]
      },
      {
          "client_id": "8e1799f0-4429-4939-ae84-7391cff93ba5",
          "is_primary": true,
          "client_relationships": [
              {
                "client_id": "bad983ab-4706-4463-a6c5-16a07e955c87",
                "relationship": "father"
              },
              {
                "client_id": "7e74b1d4-bd1c-44a1-8d25-7988a34a54ef",
                "relationship": "husband"
              }
          ]
      }
  ],
  "is_active": true,
  "metadata": {}
}

Update the information for a household. The unique household_id must be provided. To obtain the appropriate household_id, use the GET /household endpoint to view all households stored for your tenant and their current information. The details to be updated must also be provided. The endpoint returns the household_id and the details for the card.

HTTP REQUEST

PUT /household/{household_id}

Delete a household

Example Request

curl -X DELETE -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/household/0233ab54-58a0-4b43-aa65-a1c32f29ad69"
api_instance = nucleus_api.HouseholdApi(nucleus_api.ApiClient(configuration))
# # # Delete a HouseHold
household1_id = '17f098af-5d9d-4263-818a-33a934e03265'
try:
    api_instance.delete_household_using_delete(household1_id)
except ApiException as e:
    print("Exception when delete_household_using_delete: %s\n" % e)
HouseholdApi apiInstance = new HouseholdApi();
        //Delete a Household
        try {
            Household deleteresponse = apiInstance.deleteHouseholdUsingDelete(UUID.fromString("8b39a62b-247c-4b72-953e-6f648f5f970d"));
            System.out.println(deleteresponse);
        } catch (ApiException e) {
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\HouseholdApi(
    new GuzzleHttp\Client(),
    $config);
//Delete HouseHold
$household_did = "04fefab3-4010-4661-a606-0ed3634e0c78"; // string | UUID account_id

try {
    $apiInstance->deleteHouseholdUsingDelete($household_did);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->deleteHouseholdUsingDelete: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::HouseholdApi.new

#Delete Household
household1_id = '17f098af-5d9d-4263-818a-33a934e03265'
begin
  result = api_instance.delete_household_using_delete(household1_id)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->delete_household_using_delete: #{e}"
end
var apiInstance = new HydrogenNucleusApi.HouseholdApi();
// //Delete a Goal
var householdidd = "17f098af-5d9d-4263-818a-33a934e03265";
var deletehousehold = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully.');
    }
};
apiInstance.deleteHouseholdUsingDelete(householdidd, deletehousehold)

Example Response

{
  "content": [
    {
      "date": "2018-02-03",
      "security_id": "73b5dbcd-0a40-4526-8348-368e17c9575d",
      "weight": 10,
      "currency_code": "USD",
      "amount": 2000,
      "cost_basis": null,
      "shares": 20
    },
    {
      "date": "2018-02-03",
      "security_id": "691c2255-a1a6-451f-b772-cb262725d7e2",
      "weight": 2,
      "currency_code": "USD",
      "amount": 400,
      "cost_basis": null,
      "shares": 4
    },
    {
      "date": "2018-02-03",
      "security_id": "0283c814-db55-4470-8cd8-8b9ae945182f",
      "weight": 30,
      "currency_code": "USD",
      "amount": 6000,
      "cost_basis": null,
      "shares": 60
    },
    {
      "date": "2018-02-03",
      "security_id": "0d652520-7e6a-461d-abe8-56b956c08d2e",
      "weight": 30,
      "currency_code": "USD",
      "amount": 6000,
      "cost_basis": null,
      "shares": 70
    },
    {
      "date": "2018-02-03",
      "security_id": "c090f392-409d-459a-8054-333fe96fb877",
      "weight": 28,
      "currency_code": "USD",
      "amount": 5600,
      "cost_basis": null,
      "shares": 50
    }
  ],
    "total_pages": 1,
    "total_elements": 5,
    "last": true,
    "sort": [
        {
            "direction": "DESC",
            "property": "id",
            "ignore_case": false,
            "null_handling": "NATIVE",
            "descending": true,
            "ascending": false
        }
    ],
    "first": true,
    "number_of_elements": 5,
    "size": 25,
    "number": 5
}

Get the information for all the securities that are currently being held by a household registered with your tenant. Holding records are created at a portfolio level and aggregated to show the holdings of the household. The unique household_id must be provided. To obtain the appropriate household_id, use the GET /household endpoint to view all available household_ids registered with your tenant. The endpoint returns a list of security_ids, the security amount, the security weight and the date of the record for all securities the household holds.

HTTP REQUEST

GET /household/{household_id}/holding

ARGUMENTS

Parameter Type Required Description
start_date date optional Start date for the data. Defaults to the first date if not set
end_date date optional End date for the data. Defaults to the last date if not set
get_latest boolean optional Retrieve only the latest asset size. Defaults to false if not set
currency_conversion string optional Alphabetic currency code for the currency to convert all monetary values to. Value may be USD, GBP, EUR, AUD, CAD. Only available in enterprise plan.

RESPONSE

Field Type Description
date date Date for the security holding. Displays the latest record if more than one entry exists for the given date.
security_id UUID The id for the security included in the holding record
weight double The weight of the security as a percentage of the household’s total monetary value; ex. 20 representing 20%
currency_code string Alphabetic currency code for the amount. See currency codes
amount double Monetary value of the shares in the holding record
cost_basis double Monetary value that the security was originally purchased for, used for tax purposes
shares double Number of shares in the holding record

List all household transactions

Example Request

curl -X GET -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/household/099961da-7f41-4309-950f-2b51689a0033/transaction"
api_instance = nucleus_api.HouseholdApi(nucleus_api.ApiClient(configuration))
# List all HouseholdClientTransactions
try:
    api_response = api_instance.get_household_client_transaction_using_get("fcb966b5-8da1-4541-a488-07e99074e37b")
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_household_client_transaction_using_get: %s\n" % e)
HouseholdApi apiInstance = new HouseholdApi();
        //List Householdtransaction
        try {
            Object householtransaction = apiInstance.getHouseholdClientTransactionUsingGet(UUID.fromString("6f851269-659b-4616-b860-e53e114559c2"), true, null, date2, null, 0, 10, date1);
            System.out.println(householtransaction);
        } catch (ApiException e) {
            System.err.println("Exception when calling getHouseholdClientHoldingUsingGet");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\HouseholdApi(
    new GuzzleHttp\Client(),
    $config);
//Get HouseholdTransaction
$household_id = "6f851269-659b-4616-b860-e53e114559c2"; // string | UUID household_id
$ascending = false; // bool | ascending
$currency_conversion = null; // string | USD
$end_date = new \DateTime("2020-09-14"); // \DateTime | end date
$order_by = null; // string | order_by
$page = 0; // int | page
$size = 10; // int | size
$start_date = new \DateTime("2020-08-14"); // \DateTime | start date

try {
    $householdtransaction = $apiInstance->getHouseholdClientTransactionUsingGet($household_id, $ascending, $currency_conversion, $end_date, $order_by, $page, $size, $start_date);
    print_r($householdtransaction);
} catch (Exception $e) {
    echo 'Exception when calling HouseholdApi->getHouseholdClientTransactionUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::HouseholdApi.new

#Get all Transactions
household_id = '6f851269-659b-4616-b860-e53e114559c2' # String | UUID household_id

opts = {
    ascending: false, # BOOLEAN | ascending
    currency_conversion: null, # String | USD
    end_date: Date.parse('2013-10-20'), # Date | end date
    order_by: null, # String | order_by
    page: 0, # Integer | page
    size: 25, # Integer | size
    start_date: Date.parse('2013-10-20') # Date | start date
}

begin
  transaction = api_instance.get_household_client_transaction_using_get(household_id, opts)
  p transaction
rescue NucleusApi::ApiError => e
  puts "Exception when calling HouseholdApi->get_household_client_transaction_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.HouseholdApi();
//List all Transactions


var householdId = "6f851269-659b-4616-b860-e53e114559c2";
var opts = {
    'currencyConversion': null, // String | USD
    'endDate': new Date("2018-11-03"), // Date | end date
    'excludeSubledger': true, // Boolean | true or false
    'getLatest': true, // Boolean | true or false
    'sortType': null, // String |  Quarter (Q), Monthly (M) , Annually (Y), Daily (D) --caps matter, codes in ()
    'startDate': new Date("2018-08-01") // Date | start date
};

var transactions = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' + data);
    }
};
apiInstance.getHouseholdClientTransactionUsingGet(householdId, opts, transactions)

Example Response

{
  "content": [
    {
      "id": "efa289b2-3565-42e6-850b-8dad25727e99",
      "date": "2018-01-31T00:00:00.000+0000",
      "date_available": null,
      "is_recurring": false,
      "is_cleansed": false,
      "is_disputed": false,
      "is_read": true,
      "portfolio_id": "8ec467e6-6faa-4916-b380-6af0b21a34cc",
      "model_id": "6dbadddc-41ff-4634-a145-16678b422557",
      "price": 200,
      "quantity": 2,
      "currency_code": null,
      "amount": null,
      "balance": null,
      "merchant_id": null,
      "mid": null,
      "merchant": null,
      "merchant_category_code": null,
      "transaction_category_id": null,
      "category": null,
      "subcategory": null,
      "description": null,
      "memo": null,
      "status": null,
      "location": {},
      "check": {},
      "funding_id": null,
      "security_id": "691c2255-a1a6-451f-b772-cb262725d7e2",
      "transaction_code_id": "f5af397b-7d22-433f-b01e-8202184a6386",
      "create_date": "2018-02-07T19:29:37.000+0000",
      "update_date": "2018-02-012T09:00:00.000+0000"
    },
    {
      "id": "efa289b2-3565-42e6-850b-8dad25727e24",
      "date": "2018-01-31T00:00:00.000+0000",
      "date_available": null,
      "is_recurring": false,
      "is_cleansed": false,
      "is_disputed": false,
      "is_read": true,
      "portfolio_id": "8ec467e6-6faa-4916-b380-6af0b21a34cc",
      "model_id": "6dbadddc-41ff-4634-a145-16678b422557",
      "price": 1000,
      "quantity": 6,
      "currency_code": null,
      "amount": null,
      "balance": null,
      "merchant_id": null,
      "mid": null,
      "merchant": null,
      "merchant_category_code": null,
      "transaction_category_id": null,
      "category": null,
      "subcategory": null,
      "description": null,
      "memo": null,
      "status": null,
      "location": {},
      "check": {},
      "funding_id": null,
      "security_id": "0d652520-7e6a-461d-abe8-56b956c08d2e",
      "transaction_code_id": "f5af397b-7d22-433f-b01e-8202184a6386",
      "create_date": "2017-08-02T04:30:25.000+0000",
      "update_date": "2017-11-18T09:00:00.000+0000"
    }
  ],
    "total_pages": 1,
    "total_elements": 2,
    "last": true,
    "sort": [
        {
            "direction": "DESC",
            "property": "id",
            "ignore_case": false,
            "null_handling": "NATIVE",
            "descending": true,
            "ascending": false
        }
    ],
    "first": true,
    "number_of_elements": 2,
    "size": 25,
    "number": 2
}

Get the information for all transactions under a household registered with your tenant. Transaction records are created at a portfolio level and all transactions for each portfolio below the household’s account(s) are returned to show the household’s transaction activity. The unique household_id must be provided. To obtain the appropriate household_id, use the GET /household endpoint to view all available household_ids registered with your tenant. The endpoint returns a list of transaction_ids and details for each transaction.

HTTP REQUEST

GET /household/{household_id}/transaction

ARGUMENTS

Parameter Type Required Description
start_date date optional Start date for the data. Defaults to the first date if not set
end_date date optional End date for the data. Defaults to the last date if not set
currency_conversion string optional Alphabetic currency code for the currency to convert all monetary values to. Value may be USD, GBP, EUR, AUD, CAD. Only available in enterprise plan.

RESPONSE

Field Type Description
id UUID The id for the transaction record
date timestamp Timestamp when the transaction occurred
date_available timestamp Timestamp when the transaction becomes available
is_cleansed boolean Indicates if the transaction has been cleansed by a data cleansing engine. Defaults to false which indicates that it has not been cleansed
is_read boolean Indicates if the transaction has been read. Defaults to false which indicates that it has not been read
is_recurring boolean Indicates if the transaction is recurring such as a subscription. Defaults to false which indicates that it is not recurring
is_disputed boolean Indicates if the transaction is disputed by the client. Defaults to false which indicates that it is not disputed
portfolio_id UUID The id of the portfolio that the transaction record relates to
funding_id UUID The id of the funding request that the transaction record relates to
model_id UUID The id of the model to which the portfolio that the transaction falls under subscribes
price integer Price for the security included in the transaction at which it was sold or purchased
quantity integer Quantity of shares of the security purchased
currency_code string Alphabetic currency code for the amount. See currency codes
amount double Amount of the transaction
balance double Updated balance of the portfolio as a result of the transaction
merchant_id UUID ID of the merchant resource for the transaction
mid string Acquirer ID of the merchant (MID) for the transaction
merchant string The merchant for the transaction such as the merchant posted for a credit or debit card charge
merchant_category_code string The MCC Code for the merchant as identified by the card network
transaction_category_id string ID of the category resource for the transaction
category string Category of the transaction
subcategory string Subcategory of the transaction
description string Description of the transaction
memo string Memo attached to the transaction
status string Status of the transaction
location map Location where the transaction occurred
      address_line1 string Primary information for the street address, such as the street and building number
      address_line2 string Secondary information for the street address, such as a suite or apartment number
      city string City for the address
      state string State, province, or sub-country region for the address
      postalcode string Alphanumeric postal code or zip code for the address
      country string Country for the address using the ISO ALPHA-2 Code. See country codes
      latitude double Latitude of the location where the transaction occurred
      longitude double Longitude of the location where the transaction occurred
check map Check associated with the banking transaction
      check_number string Number on the check such as “1234”
      check_amount double Monetary amount of the check
      check_images map Image(s) of the scanned check(s)
            image_url string URL where the image can be displayed
            image_type string Type of image for the check such as “png” or “jpeg”
security_id UUID The id of the security included in the transaction
transaction_code_id integer The id referring to the transaction codes defined by your firm
secondary_id string Alternate id that can be used to identify the object such as an internal id
create_date timestamp Timestamp for the date and time that the record was created
update_date timestamp Timestamp for the date and time that the record was last updated

Portfolio

Portfolio Management

Portfolios are created under accounts and hold securities for investment accounts or cash for banking/savings accounts. Every account must have at least one portfolio if you wish to track holdings, balances, and transactions. A portfolio subscribes to a model to determine the composition of the portfolio. An account may have one of more portfolios, but the weights of all the portfolios must add up to 100%.

Field Type Description
id UUID The id of the portfolio
name string Name of the portfolio such as “Stock”
account_id UUID The id of the account to which the portfolio belongs
model_id UUID The id of the model to which the portfolio subscribes
percentage double Weight of the portfolio as a percentage of an account based on the weight of the portfolio’s model within the account’s allocation; ex. 20 representing 20%. If the account only has one portfolio input 100
account_number string Account number for the portfolio if the portfolio represents a subledger under a master account. Differs from the id for the portfolio which is auto generated.
description string Description for the portfolio such as “Stock Portfolio”
currency_code string Alphabetic currency code for the base currency of the portfolio, limited to 3 characters. See currency codes
is_subledger boolean Indicates if the portfolio represents a subledger or subaccount under a master account for a banking account. Defaults to false which indicates that it is not a subledger
status string Status of the portfolio such as “Registered” or “Active”
is_active boolean Indicates if the portfolio is active. Defaults to true which indicates that it is currently active
metadata map Custom information associated with the portfolio in the format key:value. See Metadata
secondary_id string Alternate id that can be used to identify the object such as an internal id
create_date timestamp Timestamp for the date and time that the record was created
update_date timestamp Timestamp for the date and time that the record was last updated

List all portfolios

Example Request

curl -X GET -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/portfolio"
api_instance = nucleus_api.PortfolioApi(nucleus_api.ApiClient(configuration))
try:
    api_response = api_instance.get_portfolio_all_using_get()
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_portfolio_all_using_get: %s\n" % e)
PortfolioApi apiInstance = new PortfolioApi();
        try {
            PagePortfolio List = apiInstance.getPortfolioAllUsingGet(true, null, null, 0, 10);
            System.out.println(List);
        } catch (ApiException e) {
            System.err.println("Exception when calling getPortfolioAllUsingGet");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\PortfolioApi(
    new GuzzleHttp\Client(),
    $config);
$ascending = false; // bool | ascending
$filter = null; // string | filter
$order_by = null; // string | order_by
$page = 0; // int | page
$size = 10; // int | size

try {
    $portfoliolist = $apiInstance->getPortfolioAllUsingGet($ascending, $filter, $order_by, $page, $size);
    print_r($portfoliolist);
} catch (Exception $e) {
    echo 'Exception when calling PortfolioApi->getPortfolioAllUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::PortfolioApi.new
opts = {
    ascending: false, # BOOLEAN | ascending
    filter: null, # String | filter
    order_by: null, # String | order_by
    page: 0, # Integer | page
    size: 25 # Integer | size
}

begin
  portfoliolist = api_instance.get_portfolio_all_using_get(opts)
  p portfoliolist
rescue NucleusApi::ApiError => e
  puts "Exception when calling PortfolioApi->get_portfolio_all_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.PortfolioApi();
var opts = {
    'ascending': false, // Boolean | ascending
    // 'filter': "", // String | filter
    'orderBy': "update_date", // String | order_by
    'page': 0, // Number | page
    'size': 25 // Number | size
};

var portfoliolist = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.getPortfolioAllUsingGet(opts, portfoliolist)

Example Response

{
    "content": [
        {
            "id": "04907eaa-3f33-49be-a35b-378cdf639fba",
            "create_date": "2018-01-01T21:56:03.000+0000",
            "update_date": "2018-01-15T21:56:03.000+0000",
            "description": "Portfolio 93 - Retirement Goal 1",
            "name": "Portfolio 93",
            "percentage": 100,
            "account_id": "04907eaa-3f33-49be-a35b-378cdf639fba",
            "model_id": "d5e3daf8-1ebf-4654-ac7a-2685502ec387",
            "account_number": null,
            "is_subledger": false,
            "status": null,
            "is_active": true,
            "metadata": {},
            "currency_code": "USD"
        },
        {
            "id": "099961da-7f41-4309-950f-2b51689a0033",
            "create_date": "2018-01-01T21:56:03.000+0000",
            "update_date": "2018-01-15T21:56:03.000+0000",
            "description": "Portfolio 10 - Major Purchase Goal 1",
            "name": "Portfolio 10",
            "percentage": 100,
            "account_id": "099961da-7f41-4309-950f-2b51689a0033",
            "model_id": "f68508c6-e23b-482e-b4f3-b449964eb08a",
            "account_number": null,
            "is_subledger": false,
            "status": null,
            "is_active": true,
            "metadata": {},
            "currency_code": "USD"
        }
    ],
    "last": false,
    "total_pages": 1,
    "total_elements": 2,
    "sort": [
        {
            "direction": "DESC",
            "property": "updateDate",
            "ignore_case": false,
            "null_handling": "NATIVE",
            "descending": true,
            "ascending": false
        }
    ],
    "first": true,
    "number_of_elements": 2,
    "size": 25,
    "number": 0
}

Get the information for all portfolios assigned to all of your firm’s accounts. Note that the metadata is stored as a nested object within the portfolio object.

HTTP REQUEST

GET /portfolio

Create a portfolio

Example Request

curl -X POST -H "Authorization: Bearer <access_token>" \
    -H "Content-Type: application/json" \
    -d '{
            "description": "Portfolio 93 - Retirement Goal 1",
            "name": "Portfolio 93",
            "percentage": 100,
            "account_id": "04907eaa-3f33-49be-a35b-378cdf639fba",
            "model_id": "d5e3daf8-1ebf-4654-ac7a-2685502ec387"
      }' "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/portfolio"
api_instance = nucleus_api.PortfolioApi(nucleus_api.ApiClient(configuration))
# # Create a Portfolio
portfolio = nucleus_api.Portfolio(name="New", account_id="39febc7f-ce86-4815-b4cb-cca9d05ba701", percentage="100")
try:
    api_response = api_instance.create_portfolio_using_post(portfolio)
    pprint(api_response)
except ApiException as e:
    print("create_portfolio_using_post: %s\n" % e)
PortfolioApi apiInstance = new PortfolioApi();
        //Create a Portfolio
        Portfolio portfolio = new Portfolio();
        portfolio.setName("Andy");
        portfolio.setAccountId(UUID.fromString("39febc7f-ce86-4815-b4cb-cca9d05ba701"));
        portfolio.setPercentage(30.0);

                try {
            Portfolio result = apiInstance.createPortfolioUsingPost(portfolio);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling createPortfolioUsingPost");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\PortfolioApi(
    new GuzzleHttp\Client(),
    $config);
//Create Portfolio
$portfolio = new \com\hydrogen\nucleus\Model\Portfolio();

try {
    $portfolio->setAccountId("39febc7f-ce86-4815-b4cb-cca9d05ba701");
    $portfolio->setName("ABC");
    $portfolio->setPercentage("30");
    $result = $apiInstance->createPortfolioUsingPost($portfolio);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->createPortfolioUsingPost: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::PortfolioApi.new
#Create Portfolio
portfolio = NucleusApi::Portfolio.new

begin
  portfolio.account_id = "39febc7f-ce86-4815-b4cb-cca9d05ba701"
  portfolio.name = "ANdy"
  portfolio.percentage = "100"
  result = api_instance.create_portfolio_using_post(portfolio)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->create_portfolio_using_post: #{e}"
end
var apiInstance = new HydrogenNucleusApi.PortfolioApi();
//Create a Portfolio
var portfolio = new HydrogenNucleusApi.Portfolio();
portfolio.account_id = '39febc7f-ce86-4815-b4cb-cca9d05ba701';
portfolio.name = "AN";
portfolio.percentage = "10";


var newportfolio = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.createPortfolioUsingPost(portfolio, newportfolio)

Example Response

{
  "id": "04907eaa-3f33-49be-a35b-378cdf639fba",
  "create_date": "2018-01-01T21:56:03.000+0000",
  "description": "Portfolio 93 - Retirement Goal 1",
  "name": "Portfolio 93",
  "percentage": 100,
  "account_id": "04907eaa-3f33-49be-a35b-378cdf639fba",
  "model_id": "d5e3daf8-1ebf-4654-ac7a-2685502ec387",
  "account_number": null,
  "is_subledger": false,
  "status": null,
  "is_active": true,
  "metadata": {}
}

Create a new portfolio for an account. The account_id that the portfolio belongs to and the model_id to which the portfolio subscribes must be provided. To obtain the appropriate account_id, use the GET /account endpoint to view all accounts defined for your tenant. To obtain the appropriate model_id, use the GET /model endpoint to view all the models defined for your tenant. The create_date will default to the current date. The endpoint returns a portfolio_id used to manage the portfolio.

HTTP REQUEST

POST /portfolio

ARGUMENTS

Parameter Type Required Description
name string required Name of the portfolio such as “Stock”
account_id UUID required The id of the account to which the portfolio belongs
percentage double required Weight of the portfolio as a percentage of an account based on the weight of the portfolio’s model within the account’s allocation; ex. 20 representing 20%. If the account only has one portfolio input 100
model_id UUID optional The id of the model to which the portfolio subscribes
account_number string optional Account number for the portfolio if the portfolio represents a subledger under a master account. Differs from the id for the portfolio which is auto generated.
description string optional Description for the portfolio such as “Stock Portfolio”
currency_code string optional Alphabetic currency code for the base currency of the portfolio, limited to 3 characters. See currency codes
is_subledger boolean optional Indicates if the portfolio represents a subledger or subaccount under a master account for a banking account. Defaults to false which indicates that it is not a subledger
status string optional Status of the portfolio such as “Registered” or “Active”
is_active boolean optional Indicates if the portfolio is active. Defaults to true which indicates that it is currently active
metadata map optional Custom information associated with the portfolio in the format key:value. See Metadata
secondary_id string optional Alternate id that can be used to identify the object such as an internal id

Retrieve a portfolio

Example Request

curl -X GET -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/portfolio/04907eaa-3f33-49be-a35b-378cdf639fba"
api_instance = nucleus_api.PortfolioApi(nucleus_api.ApiClient(configuration))
try:
    api_response = api_instance.get_portfolio_using_get("f2bec1bf-a472-4b85-864b-5de85f0ba525")
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_portfolio_using_get: %s\n" % e)
PortfolioApi apiInstance = new PortfolioApi();
        try {
            Portfolio responsePortfolio = apiInstance.getPortfolioUsingGet(UUID.fromString("e87bbceb-70e0-4822-b8e6-93bf7a51cd57"));
            System.out.println(responsePortfolio);
        } catch (ApiException e) {
            System.err.println("Exception when calling getPortfolioUsingGet");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\PortfolioApi(
    new GuzzleHttp\Client(),
    $config);
$portfolio_id = "e87bbceb-70e0-4822-b8e6-93bf7a51cd57"; // string | UUID portfolio_id

try {
    $portfolio = $apiInstance->getPortfolioUsingGet($portfolio_id);
    print_r($portfolio);
} catch (Exception $e) {
    echo 'Exception when calling PortfolioApi->getPortfolioUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::PortfolioApi.new
portfolio_id = 'e87bbceb-70e0-4822-b8e6-93bf7a51cd57' # String | UUID portfolio_id
begin
  #Retrieve a portfolio
  portfolio = api_instance.get_portfolio_using_get(portfolio_id)
  p portfolio
rescue NucleusApi::ApiError => e
  puts "Exception when calling PortfolioApi->get_portfolio_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.PortfolioApi();
var portfolioID = "e87bbceb-70e0-4822-b8e6-93bf7a51cd57";

var opts = {
    'currencyConversion': null, // String | USD
};

var portfolio = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.getPortfolioUsingGet(portfolioID, portfolio)

Example Response

{
  "id": "04907eaa-3f33-49be-a35b-378cdf639fba",
  "create_date": "2018-01-01T21:56:03.000+0000",
  "update_date": "2018-01-15T21:56:03.000+0000",
  "description": "Portfolio 93 - Retirement Goal 1",
  "name": "Portfolio 93",
  "percentage": 100,
  "account_id": "04907eaa-3f33-49be-a35b-378cdf639fba",
  "model_id": "d5e3daf8-1ebf-4654-ac7a-2685502ec387",
  "account_number": null,
  "is_subledger": false,
  "status": null,
  "is_active": true,
  "metadata": {}
}

Retrieve a portfolio for an account. The portfolio_id must be provided. The endpoint returns the portfolio_id and the details for the portfolio specified.

HTTP REQUEST

GET /portfolio/{portfolio_id}

Update a portfolio

Example Request

curl -X PUT -H "Authorization: Bearer <access_token>" \
    -H "Content-Type: application/json" \
    -d '{
          "description": "Test Portfolio 1 Retirement",
          "name": "Test Portfolio 1",
          "percentage": 100,
          "account_id": "e281137e-748d-4f45-aaf1-ec91b90d7fe4",
          "model_id": "17b0323c-5a69-4d1e-a7b7-98c6d423148f",
          "metadata": {}
      }' "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/portfolio/04907eaa-3f33-49be-a35b-378cdf639fba"
api_instance = nucleus_api.PortfolioApi(nucleus_api.ApiClient(configuration))
# # # Update a Portfolio
portfolio_update = {'currency_code': 'GBP'}
portfolio_id = '8e2a3acc-f01b-4b92-8823-0d2f03e1f94b'
try:
    api_response = api_instance.update_portfolio_using_put(portfolio_update, portfolio_id)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling update_portfolio_using_put: %s\n" % e)
PortfolioApi apiInstance = new PortfolioApi();
          //Update a Portfolio
        Map map = new HashMap();
        map.put("percentage", "40");

        try {
            Portfolio response = apiInstance.updatePortfolioUsingPut(map, UUID.fromString("d2de48cb-f25d-4277-b29d-ade138d1832e"));
            System.out.println(response);
        } catch (ApiException e) {
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\PortfolioApi(
    new GuzzleHttp\Client(),
    $config);
//Update Portfolio
$portfolio_update = new stdClass();
$portfolio_id = "7e2a7ebb-0647-47a9-8b8c-03843c464750";

try {
    $portfolio_update->percentage = "50";
    $result = $apiInstance->updatePortfolioUsingPut($portfolio_update, $portfolio_id);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->updatePortfolioUsingPut: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::PortfolioApi.new
#Update Portfolio
portfolio_update = {"name" => 'USD'}
portfolio_id = 'c8890677-e8b7-45d7-b843-6d103e1658e3'
begin
  result = api_instance.update_portfolio_using_put(portfolio_update, portfolio_id)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->update_portfolio_using_put: #{e}"
end
var apiInstance = new HydrogenNucleusApi.PortfolioApi();
//Update Portfolio
var apiInstance = new HydrogenNucleusApi.PortfolioApi();
var callback = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
var portfolioupdate = new HydrogenNucleusApi.Portfolio();
var portid = '02dd93a9-3ea0-40d4-8061-5a6bffd9ce99';

portfolioupdate.currency_code = "USD";
apiInstance.updatePortfolioUsingPut(portfolioupdate, portid, callback)

Example Response

{
  "id": "04907eaa-3f33-49be-a35b-378cdf639fba",
  "create_date": "2018-01-01T21:56:03.000+0000",
  "update_date": "2018-01-15T21:56:03.000+0000",
  "description": "Portfolio 93 - Retirement Goal 1",
  "name": "Portfolio 93",
  "percentage": 100,
  "account_id": "04907eaa-3f33-49be-a35b-378cdf639fba",
  "model_id": "d5e3daf8-1ebf-4654-ac7a-2685502ec387",
  "account_number": null,
  "is_subledger": false,
  "status": null,
  "is_active": true,
  "metadata": {}
}

Update a portfolio for an account. The portfolio_id must be provided. To obtain the appropriate portfolio_id, use the GET /portfolio endpoint to view all portfolios firm-wide and their current information. The details to be updated must also be provided. The endpoint returns the portfolio_id and the details for the portfolio.

HTTP REQUEST

PUT /portfolio/{portfolio_id}

Delete a portfolio

Example Request

curl -X DELETE -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/portfolio/04907eaa-3f33-49be-a35b-378cdf639fba"
api_instance = nucleus_api.PortfolioApi(nucleus_api.ApiClient(configuration))
# # Delete a Portfolio
portfoilo1_id = '298257c3-4010-4ee7-9c1c-233a9eb85aee'
try:
    api_instance.delete_portfolio_using_delete(portfoilo1_id)
except ApiException as e:
    print("Exception when delete_portfolio_using_delete: %s\n" % e)
PortfolioApi apiInstance = new PortfolioApi();

        //Delete a Portfolio
        try {
            Portfolio deleteresponse = apiInstance.deletePortfolioUsingDelete(UUID.fromString("49826337-2a05-4a10-a4ca-55743ffe54b4"));
            System.out.println(deleteresponse);
        } catch (ApiException e) {
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\PortfolioApi(
    new GuzzleHttp\Client(),
    $config);
//Delete Portfolio
$portfolio_did = "03313070-ee0b-4a13-b438-9c99f128ff61"; // string | UUID account_id

try {
    $apiInstance->deletePortfolioUsingDelete($portfolio_did);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->deletePortfolioUsingDelete: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::PortfolioApi.new

#Delete Portfolio
portfolio1_id = '1b460630-0e3f-48cb-a161-c133e7d621fe'
begin
  result = api_instance.delete_portfolio_using_delete(portfolio1_id)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->delete_portfolio_using_delete: #{e}"
end
var apiInstance = new HydrogenNucleusApi.PortfolioApi();
// //Delete a Portfolio
var portassetdid = "4e67302c-d6a4-454e-8dca-0982836e1953";


var deleteportfolioasset = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully.');
    }
};
apiInstance.deletePortfolioAssetSizeUsingDelete(portassetdid, deleteportfolioasset)

Response (204 No Content)

Permanently delete a portfolio for an account. The portfolio_id must be provided. To obtain the appropriate portfolio_id, use the GET /portfolio endpoint to view all portfolios firm-wide. This deletes the portfolio_id and removes the portfolio record from the account entirely.

HTTP REQUEST

DELETE /portfolio/{portfolio_id}

Portfolio Asset Sizes

Portfolio asset sizes represent the total monetary value or balance of the portfolio, including negative values. Asset sizes are used to track the progression of the portfolio. Asset size records are created at a portfolio level and aggregated at an account, client, and goal level.

Field Type Description
id UUID The id of the portfolio asset size record
date timestamp Timestamp for this asset size record
asset_size double Monetary value of the portfolio on a particular date, such as the current “balance” of a bank account or investment account. Value may be negative or positive
asset_size_available double Available monetary value of the portfolio on a particular date. This most often corresponds to the “available balance” of a bank account. Value may be be negative or positive
asset_size_pending double Pending monetary value of the portfolio on a particular date. This most often corresponds to the “pending balance” of a bank account. Value may be be negative or positive
cash_flow double Net monetary value that has flowed in or out of the portfolio since the last asset size date, usually via deposits or withdrawals. Can be negative or positive
portfolio_id UUID The id of the portfolio that the asset size record corresponds to
model_id UUID The id of the model to which the portfolio subscribes. Derived from the portfolio
account_id UUID The id of the account that the portfolio corresponds to. Derived from the portfolio
currency_code string Alphabetic currency code for the base currency of the assets, limited to 3 characters. See currency codes
secondary_id string Alternate id that can be used to identify the object such as an internal id
create_date timestamp Timestamp for the date and time that the record was created
update_date timestamp Timestamp for the date and time that the record was last updated

List all portfolio asset sizes

Example Request

curl -X GET -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/portfolio_asset_size"
api_instance = nucleus_api.PortfolioApi(nucleus_api.ApiClient(configuration))
try:
    api_response = api_instance.get_portfolio_asset_size_all_using_get()
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_portfolio_asset_size_all_using_get: %s\n" % e)
PortfolioApi apiInstance = new PortfolioApi();
        try {
            PagePortfolioAssetSizeLog List = apiInstance.getPortfolioAssetSizeAllUsingGet(true, null, null, null, 0, 10);
            System.out.println(List);
        } catch (ApiException e) {
            System.err.println("Exception when calling getPortfolioAssetSizeAllUsingGet");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\PortfolioApi(
    new GuzzleHttp\Client(),
    $config);
$ascending = false; // bool | ascending
$currency_conversion = null; // string | currency_conversion
$filter = null; // string | filter
$order_by = null; // string | order_by
$page = 0; // int | page
$size = 10; // int | size

try {
    $portfolioassetsizelist = $apiInstance->getPortfolioAssetSizeAllUsingGet($ascending, $currency_conversion, $filter, $order_by, $page, $size);
    print_r($portfolioassetsizelist);
} catch (Exception $e) {
    echo 'Exception when calling PortfolioApi->getPortfolioAssetSizeAllUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::PortfolioApi.new
opts = {
    ascending: false, # BOOLEAN | ascending
    currency_conversion: null, # String | currency_conversion
    filter: null, # String | filter
    order_by: null, # String | order_by
    page: 0, # Integer | page
    size: 25 # Integer | size
}

begin
  assetsizelist = api_instance.get_portfolio_asset_size_all_using_get(opts)
  p assetsizelist
rescue NucleusApi::ApiError => e
  puts "Exception when calling PortfolioApi->get_portfolio_asset_size_all_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.PortfolioApi();
var opts = {
    'ascending': false, // Boolean | ascending
    'currencyConversion': null, // String | currency_conversion
    'filter': null, // String | filter
    'orderBy': null, // String | order_by
    'page': 0, // Number | page
    'size': 25 // Number | size
};

var portfolioassetlist = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};

apiInstance.getPortfolioAssetSizeAllUsingGet(opts, portfolioassetlist)

Example Response

{
    "content": [
        {
            "id": "01b252d3-1412-477f-8d29-6e2ff6e54c81",
            "create_date": "2018-02-02T9:00:03.000+0000",
            "update_date": "2018-02-02T21:56:03.000+0000",
            "cash_flow": -50,
            "asset_size": 89160,
            "asset_size_available": null,
            "asset_size_pending": null,
            "date": "2018-02-02T00:00:00.000+0000",
            "account_id": "fbc03484-08e8-446d-83aa-6d6cc236355e",
            "portfolio_id": "fbc03484-08e8-446d-83aa-6d6cc236355e",
            "model_id": "9875ce25-82fe-4db5-90b2-2e0fa1f8791d",
            "currency_code": "USD"
        },
        {
            "id": "63ffef5e-1962-477a-9803-bc6a334d142c",
            "create_date": "2018-01-26T9:00:03.000+0000",
            "update_date": "2018-01-26T21:56:03.000+0000",
            "cash_flow": 100,
            "asset_size": 88250,
            "asset_size_available": null,
            "asset_size_pending": null,
            "date": "2018-01-25T00:00:00.000+0000",
            "account_id": "fbc03484-08e8-446d-83aa-6d6cc236355e",
            "portfolio_id": "fbc03484-08e8-446d-83aa-6d6cc236355e",
            "model_id": "9875ce25-82fe-4db5-90b2-2e0fa1f8791d",
            "currency_code": "USD"
        },
        {
            "id": "013380bf-7f17-44c1-93c5-892a7ed3498c",
            "create_date": "2018-01-22T9:00:03.000+0000",
            "update_date": "2018-01-22T21:56:03.000+0000",
            "cash_flow": 0,
            "asset_size": 39050,
            "asset_size_available": null,
            "asset_size_pending": null,
            "date": "2018-01-22T00:00:00.000+0000",
            "account_id": "eb3d7f60-a133-4ca9-815f-3677bcdc23a3",
            "portfolio_id": "eb3d7f60-a133-4ca9-815f-3677bcdc23a3",
            "model_id": "4ff21db3-97ab-4bbd-9885-be6aec522c44",
            "currency_code": "USD"
        }
    ],
    "last": false,
    "total_pages": 3,
    "total_elements": 3,
    "sort": [
        {
            "direction": "DESC",
            "property": "updateDate",
            "ignore_case": false,
            "null_handling": "NATIVE",
            "descending": true,
            "ascending": false
        }
    ],
    "first": true,
    "number_of_elements": 3,
    "size": 25,
    "number": 0
}

Get a list of asset sizes per date for all portfolios defined for your tenant. The endpoint returns a list of portfolio_asset_size_ids and the details for each asset size. You can filter using a portfolio_id to view the asset size records for a specific portfolio. To obtain the appropriate portfolio_id use the GET /portfolio endpoint to view portfolios firm-wide.

HTTP REQUEST

GET /portfolio_asset_size

Create a portfolio asset size

Example Request

curl -X POST -H "Authorization: Bearer <access_token>" \
     -H "Content-Type: application/json" \
     -d '{
          "cash_flow": -50,
          "asset_size": 89160,
          "date": "2018-02-02",
          "portfolio_id": "fbc03484-08e8-446d-83aa-6d6cc236355e"
      }' "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/portfolio_asset_size"
api_instance = nucleus_api.PortfolioApi(nucleus_api.ApiClient(configuration))
# # Create a PortfolioAssetSize
portfolio_asset = nucleus_api.PortfolioAssetSizeLog(_date="2020-10-10", asset_size="100", cash_flow="300", portfolio_id="b44d84ad-b1b2-463e-9ba8-b20523dd3e7a", account_id="ae66a845-cfe1-4402-9b0a-3aed87b33e29", model_id="b65c005a-f62f-4b0e-9528-b47f343fa049")
try:
    api_response = api_instance.create_portfolio_asset_size_using_post(portfolio_asset)
    pprint(api_response)
except ApiException as e:
    print("create_portfolio_asset_size_using_post: %s\n" % e)
PortfolioApi apiInstance = new PortfolioApi();
        //Create Portfolio Asset Size
        PortfolioAssetSizeLog assetsize = new PortfolioAssetSizeLog();
        assetsize.setDate(odt);
        assetsize.setAssetSize(300.00);
        assetsize.setCashFlow(2000.0);
        assetsize.setPortfolioId(UUID.fromString("b44d84ad-b1b2-463e-9ba8-b20523dd3e7a"));

                        try {
            PortfolioAssetSizeLog result = apiInstance.createPortfolioAssetSizeUsingPost(assetsize);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling createPortfolioAssetSizeUsingPost");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\PortfolioApi(
    new GuzzleHttp\Client(),
    $config);
//Create PortfolioAsset
$portfolio_asset = new \com\hydrogen\nucleus\Model\PortfolioAssetSizeLog();

try {
    $portfolio_asset->setPortfolioId('b44d84ad-b1b2-463e-9ba8-b20523dd3e7a');
    $portfolio_asset->setDate("2020-10-10");
    $portfolio_asset->setAssetSize("200");
    $portfolio_asset->setCashFlow("300");
    $result = $apiInstance->createPortfolioAssetSizeUsingPost($portfolio_asset);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->createPortfolioAssetSizeUsingPost: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::PortfolioApi.new

#Create Portfolio Asset Size
portfolio_asset = NucleusApi::PortfolioAssetSizeLog.new

begin
  portfolio_asset.portfolio_id = "b44d84ad-b1b2-463e-9ba8-b20523dd3e7a"
  portfolio_asset.date = "2020-10-10"
  portfolio_asset.asset_size = "300"
  portfolio_asset.cash_flow = "400"
  result = api_instance.create_portfolio_asset_size_using_post(portfolio_asset)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->create_portfolio_asset_size_using_post: #{e}"
end
var apiInstance = new HydrogenNucleusApi.PortfolioApi();
//Create a PortfolioAsetSize
var portfolioasset = new HydrogenNucleusApi.PortfolioAssetSizeLog();
portfolioasset.portfolio_id = 'b44d84ad-b1b2-463e-9ba8-b20523dd3e7a';
portfolioasset.cash_flow = "300";
portfolioasset.asset_size = "30";
portfolioasset.date = "2020-11-10";


var newportfolioasset = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.createPortfolioAssetSizeUsingPost(portfolioasset, newportfolioasset)

Example Response

{
  "id": "01b252d3-1412-477f-8d29-6e2ff6e54c81",
  "create_date": "2018-02-02T9:00:03.000+0000",
  "cash_flow": -50,
  "asset_size": 89160,
  "asset_size_available": null,
  "asset_size_pending": null,
  "date": "2018-02-02T00:00:00.000+0000",
  "account_id": "fbc03484-08e8-446d-83aa-6d6cc236355e",
  "portfolio_id": "fbc03484-08e8-446d-83aa-6d6cc236355e",
  "model_id": "9875ce25-82fe-4db5-90b2-2e0fa1f8791d"
}

Create a new asset size record for a portfolio. The unique portfolio_id must be provided, which will automatically pass in the model_id and account_id assigned to the portfolio. To obtain the appropriate portfolio_id, use the GET /portfolio endpoint to view all the portfolios defined for your tenant. The endpoint returns a portfolio_asset_size_id id used to manage the asset size record.

HTTP REQUEST

POST /portfolio_asset_size

ARGUMENTS

Parameter Type Required Description
date timestamp required Timestamp for this asset size record
asset_size double required Monetary value of the portfolio on a particular date, such as the current “balance” of a bank account or investment account. Value may be negative or positive
asset_size_available double optional Available monetary value of the portfolio on a particular date. This most often corresponds to the “available balance” of a bank account. Value may be be negative or positive
asset_size_pending double optional Pending monetary value of the portfolio on a particular date. This most often corresponds to the “pending balance” of a bank account. Value may be be negative or positive
cash_flow double required Net monetary value that has flowed in or out of the portfolio since the last asset size date, usually via deposits or withdrawals. Can be negative or positive.
portfolio_id UUID required The id of the portfolio that the asset size record corresponds to
currency_code string optional Alphabetic currency code for the base currency of the assets, limited to 3 characters. See currency codes
secondary_id string optional Alternate id that can be used to identify the object such as an internal id

Retrieve a portfolio asset size

Example Request

curl -X GET -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/portfolio_asset_size/01b252d3-1412-477f-8d29-6e2ff6e54c81"
api_instance = nucleus_api.PortfolioApi(nucleus_api.ApiClient(configuration))
try:
    api_response = api_instance.get_portfolio_asset_size_using_get("ccd4c432-a660-4c9c-8d81-ecb2b9cb845a")
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_portfolio_asset_size_using_get: %s\n" % e)
PortfolioApi apiInstance = new PortfolioApi();
        try {
            PortfolioAssetSizeLog responseAssetSize = apiInstance.getPortfolioAssetSizeUsingGet(UUID.fromString("96093f31-bab2-4c0e-a71b-f5925d9b2ef1"), null);
            System.out.println(responseAssetSize);
        } catch (ApiException e) {
            System.err.println("Exception when calling getPortfolioAssetSizeUsingGet");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\PortfolioApi(
    new GuzzleHttp\Client(),
    $config);
$portfolio_asset_size_id = "96093f31-bab2-4c0e-a71b-f5925d9b2ef1"; // string | portfolio_asset_size_id
$currency_conversion = null; // string | currency_conversion

try {
    $portfolioassetsize = $apiInstance->getPortfolioAssetSizeUsingGet($portfolio_asset_size_id, $currency_conversion);
    print_r($portfolioassetsize);
} catch (Exception $e) {
    echo 'Exception when calling PortfolioApi->getPortfolioAssetSizeUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::PortfolioApi.new
portfolio_asset_size_id = '96093f31-bab2-4c0e-a71b-f5925d9b2ef1' # String | portfolio_asset_size_id

opts = {
    currency_conversion: null, # String | currency_conversion
}

begin
  assetsize = api_instance.get_portfolio_asset_size_using_get(portfolio_asset_size_id, opts)
  p assetsize
rescue NucleusApi::ApiError => e
  puts "Exception when calling PortfolioApi->get_portfolio_asset_size_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.PortfolioApi();
var portfolioassetSizeID = "96093f31-bab2-4c0e-a71b-f5925d9b2ef1";

var opts = {
    'currencyConversion': null, // String | USD
};

var portfolioasset = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.getPortfolioAssetSizeUsingGet(portfolioassetSizeID, opts, portfolioasset)

Example Response

{
  "id": "01b252d3-1412-477f-8d29-6e2ff6e54c81",
  "create_date": "2018-02-02T9:00:03.000+0000",
  "update_date": "2018-02-02T21:56:03.000+0000",
  "cash_flow": -50,
  "asset_size": 89160,
  "asset_size_available": null,
  "asset_size_pending": null,
  "date": "2018-02-02T00:00:00.000+0000",
  "account_id": "fbc03484-08e8-446d-83aa-6d6cc236355e",
  "portfolio_id": "fbc03484-08e8-446d-83aa-6d6cc236355e",
  "model_id": "9875ce25-82fe-4db5-90b2-2e0fa1f8791d"
}

Retrieve the information for a portfolio asset size record. The portfolio_asset_size_id must be provided. The endpoint returns the portfolio_asset_size_id and the details for the portfolio asset size record specified.

HTTP REQUEST

GET /portfolio_asset_size/{portfolio_asset_size_id}

Update a portfolio asset size

Example Request

curl -X PUT -H "Authorization: Bearer <access_token>" \
     -H "Content-Type: application/json" \
     -d '{
            "cash_flow": -50,
            "asset_size": 89160,
            "date": "2018-02-02",
            "portfolio_id": "fbc03484-08e8-446d-83aa-6d6cc236355e"
        }' "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/portfolio_asset_size/01b252d3-1412-477f-8d29-6e2ff6e54c81"
api_instance = nucleus_api.PortfolioApi(nucleus_api.ApiClient(configuration))
# # # Update a PortfolioAssetSize
portfolio_asset_update = {'currency_code': 'GBP'}
portfolio_asset_id = 'a2f57cdf-db19-4ec1-b4be-a133bfbc2832'
try:
    api_response = api_instance.update_portfolio_asset_size_using_put(portfolio_asset_update, portfolio_asset_id)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling update_portfolio_asset_size_using_put: %s\n" % e)
PortfolioApi apiInstance = new PortfolioApi();
        //Update a Portfolio AssetSize
        Map map1 = new HashMap();
        map1.put("cash_flow", "3000");

        try {
            PortfolioAssetSizeLog response = apiInstance.updatePortfolioAssetSizeUsingPut(map1, UUID.fromString("490367a5-cc20-4126-838b-0fd7e83810bc"));
            System.out.println(response);
        } catch (ApiException e) {
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\PortfolioApi(
    new GuzzleHttp\Client(),
    $config);
//Update Portfolio Asset
$portfolio_asset_update = new stdClass();
$portfolio_asset_id = "490367a5-cc20-4126-838b-0fd7e83810bc";

try {
    $portfolio_asset_update->cash_flow = "400";
    $result = $apiInstance->updatePortfolioAssetSizeUsingPut($portfolio_asset_update, $portfolio_asset_id);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->updatePortfolioAssetSizeUsingPut: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::PortfolioApi.new
#Update Portfolio AssetSIze
portfolio_asset_update = {"currency_code" => 'USD'}
portfolio_asset_id = '5de9d2e5-061c-4e7f-a76b-5520cc64dbd7'
begin
  result = api_instance.update_portfolio_asset_size_using_put(portfolio_asset_update, portfolio_asset_id)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->update_portfolio_asset_size_using_put: #{e}"
end
var apiInstance = new HydrogenNucleusApi.PortfolioApi();
//Create a PortfolioAsetSize
var portfolioasset = new HydrogenNucleusApi.PortfolioAssetSizeLog();
//Update PortfolioAsset
var apiInstance = new HydrogenNucleusApi.PortfolioApi();
var callback = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
var portfolioassetupdate = new HydrogenNucleusApi.PortfolioAssetSizeLog();
var portassetid = '0fdaddd5-24ba-4e89-92e4-b1ae3514b7d5';

portfolioassetupdate.currency_code = "USD";
apiInstance.updatePortfolioAssetSizeUsingPut(portfolioassetupdate, portassetid, callback)

Example Response

{
  "id": "01b252d3-1412-477f-8d29-6e2ff6e54c81",
  "create_date": "2018-02-02T9:00:03.000+0000",
  "update_date": "2018-02-02T21:56:03.000+0000",
  "cash_flow": -50,
  "asset_size": 89160,
  "asset_size_available": null,
  "asset_size_pending": null,
  "date": "2018-02-02T00:00:00.000+0000",
  "account_id": "fbc03484-08e8-446d-83aa-6d6cc236355e",
  "portfolio_id": "fbc03484-08e8-446d-83aa-6d6cc236355e",
  "model_id": "9875ce25-82fe-4db5-90b2-2e0fa1f8791d"
}

Update the information for a portfolio asset size record. The portfolio_asset_size_id must be provided. To obtain the appropriate portfolio_asset_size_id use the GET /portfolio_asset_size endpoint to view all portfolio asset size records and their current information. The details to be updated must also be provided. The endpoint returns the portfolio_asset_size_id and the details for the portfolio asset size record.

HTTP REQUEST

PUT /portfolio_asset_size/{portfolio_asset_size_id}

Delete a portfolio asset size

Example Request

curl -X DELETE -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/portfolio_asset_size/01b252d3-1412-477f-8d29-6e2ff6e54c81"
api_instance = nucleus_api.PortfolioApi(nucleus_api.ApiClient(configuration))
# # # Delete a PortfolioAssetSize
portfoiloasset1_id = '14e4e3a8-78cf-46d2-bb99-bb79358c8aeb'
try:
    api_instance.delete_portfolio_asset_size_using_delete(portfoiloasset1_id)
except ApiException as e:
    print("Exception when delete_portfolio_asset_size_using_delete: %s\n" % e)
PortfolioApi apiInstance = new PortfolioApi();
        //Delete a PortfolioAssetSize
        try {
            PortfolioAssetSizeLog deleteresponse = apiInstance.deletePortfolioAssetSizeUsingDelete(UUID.fromString("415153f3-e4b7-47db-8ba0-aa85569d41ad"));
            System.out.println(deleteresponse);
        } catch (ApiException e) {
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\PortfolioApi(
    new GuzzleHttp\Client(),
    $config);
// //Delete a Portfolio
var portassetdid = "4e67302c-d6a4-454e-8dca-0982836e1953";


var deleteportfolioasset = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully.');
    }
};
apiInstance.deletePortfolioAssetSizeUsingDelete(portassetdid, deleteportfolioasset)
api_instance = NucleusApi::PortfolioApi.new

#Delete Portfolio Asset
portfolio_asset1_id = 'cb92ada8-2c57-4d94-a217-b34a0d83cb0f'
begin
  result = api_instance.delete_portfolio_asset_size_using_delete(portfolio_asset1_id)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->delete_portfolio_asset_size_using_delete: #{e}"
end
var apiInstance = new HydrogenNucleusApi.PortfolioApi();
//Create a PortfolioAsetSize
var portfolioasset = new HydrogenNucleusApi.PortfolioAssetSizeLog();
//Update PortfolioAsset
var apiInstance = new HydrogenNucleusApi.PortfolioApi();
var callback = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
var portfolioassetupdate = new HydrogenNucleusApi.PortfolioAssetSizeLog();
var portassetid = '0fdaddd5-24ba-4e89-92e4-b1ae3514b7d5';

portfolioassetupdate.currency_code = "USD";
apiInstance.updatePortfolioAssetSizeUsingPut(portfolioassetupdate, portassetid, callback)

Response (204 No Content)

Permanently delete a portfolio asset size record. The portfolio_asset_size_id must be provided. To obtain the appropriate portfolio_asset_size_id use the GET /portfolio_asset_size endpoint to view all portfolio asset size records. This deletes the portfolio_asset_size_id and the details of the portfolio asset size record from the portfolio.

HTTP REQUEST

DELETE /portfolio_asset_size/{portfolio_asset_size_id}

Portfolio Holdings

Holding records represent the securities that are held in a portfolio for a particular date for an investment account. Holding records are created at the portfolio level and aggregated at an account, client, and goal level.

Field Type Description
id UUID The id of the security holding record
date timestamp Timestamp for this security holding record
portfolio_id UUID The id of the portfolio to which the holding record belongs
security_id UUID The id of the security included in the holding record
shares double The quantity of shares of the security being held
currency_code string Alphabetic currency code for the holding, limited to 3 characters. See currency codes
amount double Total monetary value of the security being held. Used to calculate weights
cost_basis double Monetary value that the security was originally purchased for, used for tax purposes
weight double Weight of the holding as a percentage of a portfolio’s total monetary value; ex. 20 representing 20%. If the security is the only one, enter 100
model_id UUID The id of the model to which the portfolio subscribes. Derived from the portfolio
account_id UUID The id of the account that the portfolio falls under. Derived from the portfolio
secondary_id string Alternate id that can be used to identify the object such as an internal id
create_date timestamp Timestamp for the date and time that the holding record was created
update_date timestamp Timestamp for the date and time that the holding record was last updated

List all portfolio holdings

Example Request

curl -X GET -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/portfolio_holding"
api_instance = nucleus_api.PortfolioApi(nucleus_api.ApiClient(configuration))
try:
    api_response = api_instance.get_portfolio_holding_all_using_get()
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_portfolio_holding_all_using_get: %s\n" % e)
PortfolioApi apiInstance = new PortfolioApi();
        try {
            PagePortfolioHoldingLog List = apiInstance.getPortfolioHoldingAllUsingGet(true, null, null, null, 0, 10);
            System.out.println(List);
        } catch (ApiException e) {
            System.err.println("Exception when calling getPortfolioHoldingAllUsingGet");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\PortfolioApi(
    new GuzzleHttp\Client(),
    $config);
$ascending = false; // bool | ascending
$currency_conversion = null; // string | currency_conversion
$filter = null; // string | filter
$order_by = null; // string | order_by
$page = 0; // int | page
$size = 10; // int | size

try {
    $portfolioholdinglist = $apiInstance->getPortfolioHoldingAllUsingGet($ascending, $currency_conversion, $filter, $order_by, $page, $size);
    print_r($portfolioholdinglist);
} catch (Exception $e) {
    echo 'Exception when calling PortfolioApi->getPortfolioHoldingAllUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::PortfolioApi.new
opts = {
    ascending: false, # BOOLEAN | ascending
    currency_conversion: null, # String | currency_conversion
    filter: null, # String | filter
    order_by: null, # String | order_by
    page: 0, # Integer | page
    size: 25 # Integer | size
}

begin
  holdinglist = api_instance.get_portfolio_holding_all_using_get(opts)
  p holdinglist
rescue NucleusApi::ApiError => e
  puts "Exception when calling PortfolioApi->get_portfolio_holding_all_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.PortfolioApi();
var opts = {
    'ascending': false, // Boolean | ascending
    'currencyConversion': null, // String | currency_conversion
    'filter': null, // String | filter
    'orderBy': null, // String | order_by
    'page': 0, // Number | page
    'size': 25 // Number | size
};

var portfolioholdinglist = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};

apiInstance.getPortfolioHoldingAllUsingGet(opts, portfolioholdinglist)

Example Response

{
    "content": [
        {
            "id": "099961da-7f41-4309-950f-2b51689a0033",
            "create_date": "2018-02-03T9:00:03.000+0000",
            "update_date": "2018-02-03T21:56:03.000+0000",
            "currency_code": "USD",
            "amount": 1000,
            "cost_basis": null,
            "shares": 12,
            "date": "2018-02-03T00:00:00.000+0000",
            "weight": 10,
            "security_id": "bd409fc9-10ba-4a01-ac32-955d835a1954",
            "portfolio_id": "647c54c3-b649-477e-8cc7-eee56a120dd3",
            "account_id": "647c54c3-b649-477e-8cc7-eee56a120dd3",
            "model_id": "feb846da-a06d-402e-a3bb-abc7260f7138"
        },
        {
            "id": "107516c3-9035-4811-af7c-501be5a1fe26",
            "create_date": "2018-02-03T9:00:03.000+0000",
            "update_date": "2018-02-03T21:56:03.000+0000",
            "currency_code": "USD",
            "amount": 32400,
            "cost_basis": null,
            "shares": 45,
            "date": "2018-02-03T00:00:00.000+0000",
            "weight": 54,
            "security_id": "1cec111a-4d06-45dc-a7e5-b7673461adcf",
            "portfolio_id": "2a7a6cb7-ef71-4fe8-9169-2678f3799657",
            "account_id": "2a7a6cb7-ef71-4fe8-9169-2678f3799657",
            "model_id": "ed3399b4-4a57-4b5d-9083-790b2a47d3d1"
        },
        {
            "id": "199a8c08-cdd5-4c8c-8abf-535447cea11b",
            "create_date": "2018-02-03T9:00:03.000+0000",
            "update_date": "2018-02-03T21:56:03.000+0000",
            "currency_code": "USD",
            "amount": 15200,
            "cost_basis": null,
            "shares": 123,
            "date": "2018-02-03T00:00:00.000+0000",
            "weight": 19,
            "security_id": "cd9128c8-8a79-4b7f-9ba7-b58fc0e629e4",
            "portfolio_id": "e995d4c1-f989-4733-9867-713966ac9856",
            "account_id": "e995d4c1-f989-4733-9867-713966ac9856",
            "model_id": "eb3d7f60-a133-4ca9-815f-3677bcdc23a3"
        }
    ],
    "last": false,
    "total_pages": 1,
    "total_elements": 3,
    "sort": [
        {
            "direction": "DESC",
            "property": "updateDate",
            "ignore_case": false,
            "null_handling": "NATIVE",
            "descending": true,
            "ascending": false
        }
    ],
    "first": true,
    "number_of_elements": 3,
    "size": 25,
    "number": 0
}

Get the information for all holding records for all portfolios defined for your tenant. The endpoint returns a list of portfolio_holding_ids and the details for each holding record. You can filter using a portfolio_id to view the holding records for a specific portfolio. You can also provide a date range to view the holding records on dates within the range. To obtain the appropriate portfolio_id use the GET /portfolio endpoint to view portfolios firm-wide.

HTTP REQUEST

GET /portfolio_holding

Create a portfolio holding

Example Request

curl -X POST -H "Authorization: Bearer <access_token>" \
    -H "Content-Type: application/json" \
    -d '{
            "currency_code": "USD",
            "amount": 1000,
            "shares": 12,
            "date": "2018-02-03",
            "weight": 10,
            "security_id": "bd409fc9-10ba-4a01-ac32-955d835a1954",
            "portfolio_id": "647c54c3-b649-477e-8cc7-eee56a120dd3"
        }' "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/portfolio_holding"
api_instance = nucleus_api.PortfolioApi(nucleus_api.ApiClient(configuration))

# Create a PortfolioHolding
portfolio_holding = nucleus_api.PortfolioHoldingLog(_date="2020-10-10", shares="30", security_id="07e814e2-2a41-47b8-aa4d-71afc7550dfa", portfolio_id="7923f20a-0424-4edb-9992-eada1054b12b", account_id="034dffd8-6b72-4611-b26a-5a593e152939", model_id='86bcab43-2e7a-43ec-9ee8-4eb8321a7d34')
try:
    api_response = api_instance.create_portfolio_holding_using_post(portfolio_holding)
    pprint(api_response)
except ApiException as e:
    print("create_portfolio_holding_using_post: %s\n" % e)
PortfolioApi apiInstance = new PortfolioApi();
        //Create a Portfolio Holding
        PortfolioHoldingLog holding = new PortfolioHoldingLog();
        holding.setDate(odt);
        holding.setPortfolioId(UUID.fromString("7923f20a-0424-4edb-9992-eada1054b12b"));
        holding.setSecurityId(UUID.fromString("07e814e2-2a41-47b8-aa4d-71afc7550dfa"));
        holding.setShares(20.0);

        try {
            PortfolioHoldingLog response = apiInstance.createPortfolioHoldingUsingPost(holding);
            System.out.println(response);
        } catch (ApiException e) {
            System.err.println("Exception when calling createPortfolioHoldingUsingPost");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\PortfolioApi(
    new GuzzleHttp\Client(),
    $config);
//Create Portfolio Holding
$portfolio_holding = new \com\hydrogen\nucleus\Model\PortfolioHoldingLog();

try {
    $portfolio_holding->setPortfolioId("7923f20a-0424-4edb-9992-eada1054b12b");
    $portfolio_holding->setSecurityId("07e814e2-2a41-47b8-aa4d-71afc7550dfa");
    $portfolio_holding->setDate("2020-10-10");
    $portfolio_holding->setShares("300");
    $result = $apiInstance->createPortfolioHoldingUsingPost($portfolio_holding);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->createPortfolioHoldingUsingPost: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::PortfolioApi.new
#Create Portfolio Holding
portfolio_holding = NucleusApi::PortfolioHoldingLog.new

begin
  portfolio_holding.portfolio_id = "7923f20a-0424-4edb-9992-eada1054b12b"
  portfolio_holding.security_id = "07e814e2-2a41-47b8-aa4d-71afc7550dfa"
  portfolio_holding.shares = "30"
  result = api_instance.create_portfolio_holding_using_post(portfolio_holding)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->create_portfolio_holding_using_post: #{e}"
end
var apiInstance = new HydrogenNucleusApi.PortfolioApi();
//Create a PortfolioHolding
var portfolioholding = new HydrogenNucleusApi.PortfolioHoldingLog();
portfolioholding.portfolio_id = '7923f20a-0424-4edb-9992-eada1054b12b';
portfolioholding.security_id = '07e814e2-2a41-47b8-aa4d-71afc7550dfa';
portfolioholding.date = "2020-10-18";
portfolioholding.shares = "20";



var newportfolioholding = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.createPortfolioHoldingUsingPost(portfolioholding, newportfolioholding)

Example Response

{
  "id": "099961da-7f41-4309-950f-2b51689a0033",
  "create_date": "2018-02-03T9:00:03.000+0000",
  "currency_code": "USD",
  "amount": 1000,
  "cost_basis": null,
  "shares": 12,
  "date": "2018-02-03T00:00:00.000+0000",
  "weight": 10,
  "security_id": "bd409fc9-10ba-4a01-ac32-955d835a1954",
  "portfolio_id": "647c54c3-b649-477e-8cc7-eee56a120dd3",
  "account_id": "647c54c3-b649-477e-8cc7-eee56a120dd3",
  "model_id": "feb846da-a06d-402e-a3bb-abc7260f7138"
}

Create a new holding record for a portfolio. The unique portfolio_id must be provided, which will automatically pass in the model_id and account_id assigned to the portfolio. To obtain the appropriate portfolio_id, use the GET /portfolio endpoint to view all the portfolios defined for your tenant. In addition, even though amount is optional, it is recommended to provide a value for amount based on the shares and security price to calculate accurate weights when aggregating at a client, account, or goal level. The endpoint returns a portfolio_holding_id used to manage the holding record.

HTTP REQUEST

POST /portfolio_holding

ARGUMENTS

Parameter Type Required Description
date date required Date for this security holding record
portfolio_id UUID required The id of the portfolio to which the holding record belongs
security_id UUID required The id of the security included in the holding record
shares double required The quantity of shares of the security being held
currency_code string optional Alphabetic currency code for the holding, limited to 3 characters. See currency codes
amount double optional Total monetary value of the security being held. Used to calculate weights
weight integer optional Weight of the holding as a percentage of a portfolio’s total monetary value; ex. 20 representing 20%. If the security is the only one, enter 100
secondary_id string optional Alternate id that can be used to identify the object such as an internal id

Retrieve a portfolio holding

Example Request

curl -X GET -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/portfolio_holding/099961da-7f41-4309-950f-2b51689a0033"
api_instance = nucleus_api.PortfolioApi(nucleus_api.ApiClient(configuration))
try:
    api_response = api_instance.get_portfolio_holding_using_get("3b51d5c1-4943-4b67-ba4f-2a95d6da9258")
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_portfolio_holding_using_get: %s\n" % e)
PortfolioApi apiInstance = new PortfolioApi();
        try {
            PortfolioHoldingLog responseHolding = apiInstance.getPortfolioHoldingUsingGet(UUID.fromString("f7b85206-c93f-4119-b70e-533022a7c01a"), null);
            System.out.println(responseHolding);
        } catch (ApiException e) {
            System.err.println("Exception when calling getPortfolioHoldingUsingGet");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\PortfolioApi(
    new GuzzleHttp\Client(),
    $config);
$portfolio_holding_id = "f7b85206-c93f-4119-b70e-533022a7c01a"; // string | UUID portfolio_holding_id
$currency_conversion = null; // string | USD

try {
    $portfolioholding = $apiInstance->getPortfolioHoldingUsingGet($portfolio_holding_id, $currency_conversion);
    print_r($portfolioholding);
} catch (Exception $e) {
    echo 'Exception when calling PortfolioApi->getPortfolioHoldingUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::PortfolioApi.new
portfolio_holding_id = 'f7b85206-c93f-4119-b70e-533022a7c01a' # String | UUID portfolio_holding_id

opts = {
    currency_conversion: null, # String | USD
}

begin
  holding = api_instance.get_portfolio_holding_using_get(portfolio_holding_id, opts)
  p holding
rescue NucleusApi::ApiError => e
  puts "Exception when calling PortfolioApi->get_portfolio_holding_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.PortfolioApi();
var portfolioholdingID = "f7b85206-c93f-4119-b70e-533022a7c01a";

var opts = {
    'currencyConversion': null, // String | USD
};

var portfolioholding = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.getPortfolioHoldingUsingGet(portfolioholdingID, opts, portfolioholding)

Example Response

{
  "id": "099961da-7f41-4309-950f-2b51689a0033",
  "create_date": "2018-02-03T9:00:03.000+0000",
  "update_date": "2018-02-03T21:56:03.000+0000",
  "currency_code": "USD",
  "amount": 1000,
  "cost_basis": null,
  "shares": 12,
  "date": "2018-02-03T00:00:00.000+0000",
  "weight": 10,
  "security_id": "bd409fc9-10ba-4a01-ac32-955d835a1954",
  "portfolio_id": "647c54c3-b649-477e-8cc7-eee56a120dd3",
  "account_id": "647c54c3-b649-477e-8cc7-eee56a120dd3",
  "model_id": "feb846da-a06d-402e-a3bb-abc7260f7138"
}

Retrieve the information for a portfolio holding record. The portfolio_holding_id must be provided. The endpoint returns the portfolio_holding_id and the details for the portfolio holding record specified.

HTTP REQUEST

GET /portfolio_holding/{portfolio_holding_id}

Update a portfolio holding

Example Request

curl -X PUT -H "Authorization: Bearer <access_token>" \
    -H "Content-Type: application/json" \
    -d '{
          "amount": 1000,
          "shares": 12,
          "date": "2018-02-03",
          "weight": 10,
          "security_id": "bd409fc9-10ba-4a01-ac32-955d835a1954",
          "portfolio_id": "647c54c3-b649-477e-8cc7-eee56a120dd3"
       }' "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/portfolio_holding/099961da-7f41-4309-950f-2b51689a0033"
api_instance = nucleus_api.PortfolioApi(nucleus_api.ApiClient(configuration))

# # # Update a PortfolioHolding
portfolio_holding_update = {'currency_code': 'USD'}
portfolio_holding_id = '8c83ca0d-253f-46ae-8c62-8d2b90e1af69'
try:
    api_response = api_instance.update_portfolio_holding_using_put(portfolio_holding_update, portfolio_holding_id)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling update_portfolio_holding_using_put: %s\n" % e)
PortfolioApi apiInstance = new PortfolioApi();

        //Update a Portfolio Holding
        Map map4 = new HashMap();
        map4.put("amount", "4000");

        try {
            PortfolioHoldingLog response = apiInstance.updatePortfolioHoldingUsingPut(map4, UUID.fromString("de3bc8e4-575d-4598-98fc-220c9bb89b83"));
            System.out.println(response);
        } catch (ApiException e) {
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\PortfolioApi(
    new GuzzleHttp\Client(),
    $config);
//Update Portfolio Holding
$portfolio_holding_update = new stdClass();
$portfolio_holding_id = "2de8d16c-de37-4ed6-aa70-9d00b1e4f042";

try {
    $portfolio_holding_update->shares = "400";
    $result = $apiInstance->updatePortfolioHoldingUsingPut($portfolio_holding_update, $portfolio_holding_id);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->updatePortfolioHoldingUsingPut: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::PortfolioApi.new
#Update Portfolio Holding
portfolio_holding_update = {"shares" => '202'}
portfolio_holding_id = '8c83ca0d-253f-46ae-8c62-8d2b90e1af69'
begin
  result = api_instance.update_portfolio_holding_using_put(portfolio_holding_update, portfolio_holding_id)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->update_portfolio_holding_using_put: #{e}"
end
var apiInstance = new HydrogenNucleusApi.PortfolioApi();
//Update PortfolioHolding
var apiInstance = new HydrogenNucleusApi.PortfolioApi();
var callback = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
var portfolioholdingupdate = new HydrogenNucleusApi.PortfolioHoldingLog();
var portholdingid = '469566e9-c9d8-494a-895a-114ed4d52950';

portfolioholdingupdate.currency_code = "CAD";
apiInstance.updatePortfolioHoldingUsingPut(portfolioholdingupdate, portholdingid, callback)

Example Response

{
  "id": "099961da-7f41-4309-950f-2b51689a0033",
  "create_date": "2018-02-03T9:00:03.000+0000",
  "update_date": "2018-02-03T21:56:03.000+0000",
  "currency_code": "USD",
  "amount": 1000,
  "cost_basis": null,
  "shares": 12,
  "date": "2018-02-03T00:00:00.000+0000",
  "weight": 10,
  "security_id": "bd409fc9-10ba-4a01-ac32-955d835a1954",
  "portfolio_id": "647c54c3-b649-477e-8cc7-eee56a120dd3",
  "account_id": "647c54c3-b649-477e-8cc7-eee56a120dd3",
  "model_id": "feb846da-a06d-402e-a3bb-abc7260f7138"
}

Update the information for a portfolio holding record. The portfolio_holding_id must be provided. To obtain the appropriate portfolio_holding_id use the GET /portfolio_holding endpoint to view all portfolio holding records and their current information. The details to be updated must also be provided. The endpoint returns the portfolio_holding_id and the details for the portfolio holding record.

HTTP REQUEST

PUT /portfolio_holding/{portfolio_holding_id}

Delete a portfolio holding

Example Request

curl -X DELETE -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/portfolio_holding/099961da-7f41-4309-950f-2b51689a0033"
api_instance = nucleus_api.PortfolioApi(nucleus_api.ApiClient(configuration))

# # # # Delete a PortfolioHolding
portfolioHolding1_id = '34ffbac5-b5b0-4609-8a33-3696f69de143'
try:
    api_instance.delete_portfolio_holding_using_delete(portfolioHolding1_id)
except ApiException as e:
    print("Exception when delete_portfolio_holding_using_delete: %s\n" % e)
PortfolioApi apiInstance = new PortfolioApi();
        //Delete a PortfolioHolding
        try {
            PortfolioHoldingLog deleteresponse = apiInstance.deletePortfolioHoldingUsingDelete(UUID.fromString("34ffbac5-b5b0-4609-8a33-3696f69de143"));
            System.out.println(deleteresponse);
        } catch (ApiException e) {
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\PortfolioApi(
    new GuzzleHttp\Client(),
    $config);
//Delete Portfolio Holding
$portfolioholding_did = "8c83ca0d-253f-46ae-8c62-8d2b90e1af69"; // string | UUID account_id

try {
    $apiInstance->deletePortfolioHoldingUsingDelete($portfolioholding_did);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->deletePortfolioHoldingUsingDelete: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::PortfolioApi.new
#Delete Portfolio Holding
portfolio_holding1_id = 'de3bc8e4-575d-4598-98fc-220c9bb89b83'
begin
  result = api_instance.delete_portfolio_holding_using_delete(portfolio_holding1_id)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->delete_portfolio_holding_using_delete: #{e}"
end
var apiInstance = new HydrogenNucleusApi.PortfolioApi();
// // //Delete a PPortfolio Holding
var portholddid = "de3bc8e4-575d-4598-98fc-220c9bb89b83";


var deleteportfoliohoolding = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully.');
    }
};
apiInstance.deletePortfolioHoldingUsingDelete(portholddid, deleteportfoliohoolding)

Response (204 No Content)

Permanently delete a portfolio holding record. The portfolio_holding_id must be provided. To obtain the appropriate portfolio_holding_id use the GET /portfolio_holding endpoint to view all portfolio holding records. This deletes the portfolio_holding_id and the details of the portfolio holding record from the portfolio.

HTTP REQUEST

DELETE /portfolio_holding/{portfolio_holding_id}

Get aggregate portfolio holding data

Displays a breakdown of holding and security details for a specific portfolio.

Field Type Description
portfolio_id UUID The id of the portfolio
name string Name of the portfolio such as “Savings Account”
description string Description for the portfolio such as “Savings account for wedding”
weight double The weight of the portfolio as a percentage of an account; ex. 20 representing 20%
create_date datetime Timestamp for the date and time when the portfolio was created
update_date datetime Timestamp for the date and time when the portfolio was last updated
asset_classes array(map) Details of portfolio grouped by asset class
      name string Name of asset class
      weight double Weight as a percentage of the portfolio
      value double Value of asset class (price * shares)
      security_price_date datetime Latest date for the security price
security_classes array(map) Details of portfolio grouped by security class
      name string Name of security class
      weight double Weight as a percentage of the portfolio
      value double Value of security class (price * shares)
      security_price_date datetime Latest date for the security price
categories array(map) Details of portfolio grouped by category
      name string Name of category
      weight double Weight as a percentage of the portfolio
      value double Value of category (price * shares)
      security_price_date datetime Latest date for the security price
sectors array(map) Details of portfolio grouped by sector
      name string Name of sector
      weight double Weight as a percentage of the portfolio
      value double Value of sector (price * shares)
      security_price_date datetime Latest date for the security price
industries array(map) Details of portfolio grouped by industry
      name string Name of industry
      weight double Weight as a percentage of the portfolio
      value double Value of industry (price * shares)
      security_price_date datetime Latest date for the security price

HTTP REQUEST

GET /portfolio/{portfolio_id}/aggregate_data

Example Request

curl -X GET -H "Authorization: Bearer <access_token>" \
  "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/portfolio/0797npda-cf8b-4661-9cb4-d1e8966r5dcd/aggregate_data"
api_instance = nucleus_api.PortfolioApi(nucleus_api.ApiClient(configuration))
try:
    api_response = api_instance.get_portfolio_aggregated_data_using_get("a0a4be74-38e5-497c-9bf5-0a8a019db99b")
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_portfolio_aggregated_data_using_get: %s\n" % e)
PortfolioApi apiInstance = new PortfolioApi();
        try {
            Object portfolioaggregate = apiInstance.getPortfolioAggregatedDataUsingGet(UUID.fromString("04f5ed39-dbd5-4bfb-8d55-6e4b1796e6ed"), true, true, true, true, true);
            System.out.println(portfolioaggregate);
        } catch (ApiException e) {
            System.err.println("Exception when calling getPortfolioAggregatedDataUsingGet");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\PortfolioApi(
    new GuzzleHttp\Client(),
    $config);
$portfolio_id = "04f5ed39-dbd5-4bfb-8d55-6e4b1796e6ed"; // string | Portfolio Id
$show_asset_class = true; // bool | true or false
$show_category = true; // bool | true or false
$show_industry = true; // bool | true or false
$show_sector = true; // bool | true or false
$show_security_class = true; // bool | true or false

try {
    $portfolioaggregate = $apiInstance->getPortfolioAggregatedDataUsingGet($portfolio_id, $show_asset_class, $show_category, $show_industry, $show_sector, $show_security_class);
    print_r($portfolioaggregate);
} catch (Exception $e) {
    echo 'Exception when calling PortfolioApi->getPortfolioAggregatedDataUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::PortfolioApi.new
portfolio_id = '04f5ed39-dbd5-4bfb-8d55-6e4b1796e6ed' # String | Portfolio Id

opts = {
    show_asset_class: true, # BOOLEAN | true or false
    show_category: true, # BOOLEAN | true or false
    show_industry: true, # BOOLEAN | true or false
    show_sector: true, # BOOLEAN | true or false
    show_security_class: true # BOOLEAN | true or false
}

begin
  aggregatedata = api_instance.get_portfolio_aggregated_data_using_get(portfolio_id, opts)
  p aggregatedata
rescue NucleusApi::ApiError => e
  puts "Exception when calling PortfolioApi->get_portfolio_aggregated_data_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.PortfolioApi();
var portfolioId = "04f5ed39-dbd5-4bfb-8d55-6e4b1796e6ed"; // String | Portfolio Id

var opts = {
    'showAssetClass': true, // Boolean | true or false
    'showCategory': true, // Boolean | true or false
    'showIndustry': true, // Boolean | true or false
    'showSector': true, // Boolean | true or false
    'showSecurityClass': true // Boolean | true or false
};

var aggregatedata = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' + data);
    }
};
apiInstance.getPortfolioAggregatedDataUsingGet(portfolioId, opts, aggregatedata)

Example Response

{
  "portfolio_id": "de8cdbfe-6b51-400f-808a-7bd1e1bd7c5c",
  "name": "My son's college portfolio",
  "description": "Portfolio to start saving for my son's college",
  "weight": 50.0,
  "create_date": "2019-01-04T14:56:08.000+0000",
  "update_date": "2019-01-04T14:57:19.000+0000",
  "asset_classes": [
    {
      "name": "US Equity",
      "weight": 100,
      "value": 132053.0,
      "security_price_date": "2025-12-26T16:21:03.000+0000"
    }
  ],
  "security_classes": [
    {
      "name": "Stock",
      "weight": 0.1,
      "value": 132053.0,
      "security_price_date": "2025-12-26T16:21:03.000+0000"
    }
  ],
  "categories": [
    {
      "name": "Technology Stocks",
      "weight": 0.1,
      "value": 132053.0,
      "security_price_date": "2025-12-26T16:21:03.000+0000"
    }
  ],
  "sectors": [
    {
      "name": "Consumer Cyclical",
      "weight": 0.1,
      "value": 132053.0,
      "security_price_date": "2025-12-26T16:21:03.000+0000"
    }
  ],
  "industries": [
    {
      "name": "Internet",
      "weight": 0.1,
      "value": 132053.0,
      "security_price_date": "2025-12-26T16:21:03.000+0000"
    }
  ]
}

Portfolio Transactions

Transactions represent the buying of selling of securities in investment accounts, and debits or credits to bank accounts and credit/debit cards. Transactions are created at a portfolio level and aggregated at an account, client, and goal level. Transactions are only viewable

Field Type Description
id UUID The id of the portfolio transaction record
portfolio_id UUID The id of the portfolio that the transaction record relates to
funding_id UUID The id of the funding request that the transaction record relates to
security_id UUID The id of the security that was bought or sold in the transaction. If the portfolio is for a bank account and no security is being bought such as a money market fund, then leave empty, or optionally create a “CASH” security
transaction_code_id UUID The id of the transaction code for the type of transaction
date timestamp Timestamp when the transaction occurred
date_available timestamp Timestamp when the transaction becomes available
price double Price at which the security was bought or sold
quantity double Quantity of units of a security that were bought or sold
currency_code string Alphabetic currency code for the transaction, limited to 3 characters. See currency codes
amount double Amount of the transaction
balance double Updated balance of the portfolio as a result of the transaction
merchant_id UUID ID of the merchant resource for the transaction
mid string Acquirer ID of the merchant (MID) for the transaction
merchant string The merchant for the transaction such as the merchant posted for a credit or debit card charge
merchant_category_code string The MCC Code for the merchant as identified by the card network
transaction_category_id string ID of the category resource for the transaction
category string Category of the transaction
subcategory string Subcategory of the transaction
description string Description of the transaction
memo string Memo attached to the transaction
status string Status of the transaction
location map Location where the transaction occurred
      address_line1 string Primary information for the street address, such as the street and building number
      address_line2 string Secondary information for the street address, such as a suite or apartment number
      city string City for the address
      state string State, province, or sub-country region for the address
      postalcode string Alphanumeric postal code or zip code for the address
      country string Country for the address using the ISO ALPHA-2 Code. See country codes
      latitude double Latitude of the location where the transaction occurred
      longitude double Longitude of the location where the transaction occurred
model_id UUID The id of the model to which the portfolio subscribes. Derived from the portfolio
account_id UUID The id of the account that the portfolio falls under. Derived from the portfolio
check map Check associated with the banking transaction
      check_number string Number on the check such as “1234”
      check_amount double Monetary amount of the check
      check_images map Image(s) of the scanned check(s)
            image_url string URL where the image can be displayed
            image_type string Type of image for the check such as “png” or “jpeg”
is_cleansed boolean Indicates if the transaction has been cleansed by a data cleansing engine. Defaults to false which indicates that it has not been cleansed
is_read boolean Indicates if the transaction has been read. Defaults to false which indicates that it has not been read
is_recurring boolean Indicates if the transaction is recurring such as a subscription. Defaults to false which indicates that it is not recurring
is_disputed boolean Indicates if the transaction is disputed by the client. Defaults to false which indicates that it is not disputed
metadata map Custom information associated with the portfolio transaction in the format key:value. See Metadata
secondary_id string Alternate id that can be used to identify the object such as an internal id
create_date timestamp Timestamp for the date and time that the record was created
update_date timestamp Timestamp for the date and time that the record was last updated

List all portfolio transactions

Example Request

curl -X GET -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/portfolio_transaction"
api_instance = nucleus_api.PortfolioApi(nucleus_api.ApiClient(configuration))
try:
    api_response = api_instance.get_portfolio_transaction_all_using_get()
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_portfolio_transaction_all_using_get: %s\n" % e)
PortfolioApi apiInstance = new PortfolioApi();
        try {
            PagePortfolioTransaction List = apiInstance.getPortfolioTransactionAllUsingGet(true, null, null, null, 0, 10);
            System.out.println(List);
        } catch (ApiException e) {
            System.err.println("Exception when calling getPortfolioTransactionAllUsingGet");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\PortfolioApi(
    new GuzzleHttp\Client(),
    $config);
$ascending = false; // bool | ascending
$currency_conversion = null; // string | currency_conversion
$filter = null; // string | filter
$order_by = null; // string | order_by
$page = 0; // int | page
$size = 10; // int | size

try {
    $portfoliotransactionlist = $apiInstance->getPortfolioTransactionAllUsingGet($ascending, $currency_conversion, $filter, $order_by, $page, $size);
    print_r($portfoliotransactionlist);
} catch (Exception $e) {
    echo 'Exception when calling PortfolioApi->getPortfolioTransactionAllUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::PortfolioApi.new
opts = {
    ascending: false, # BOOLEAN | ascending
    currency_conversion: null, # String | currency_conversion
    filter: null, # String | filter
    order_by: null, # String | order_by
    page: 0, # Integer | page
    size: 25 # Integer | size
}

begin
  transactionlist = api_instance.get_portfolio_transaction_all_using_get(opts)
  p transactionlist
rescue NucleusApi::ApiError => e
  puts "Exception when calling PortfolioApi->get_portfolio_transaction_all_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.PortfolioApi();
var opts = {
    'ascending': false, // Boolean | ascending
    'currencyConversion': null, // String | currency_conversion
    'filter': null, // String | filter
    'orderBy': null, // String | order_by
    'page': 0, // Number | page
    'size': 25 // Number | size
};

var portfoliotransactionlist = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};

apiInstance.getPortfolioTransactionAllUsingGet(opts, portfoliotransactionlist)

Example Response

{
    "content": [
        {
            "id": "099961da-7f41-4309-950f-2b51689a0033",
            "create_date": "2018-01-01T9:00:03.000+0000",
            "update_date": "2018-01-05T21:56:03.000+0000",
            "date": "2018-01-02T00:00:00.000+0000",
            "date_available": null,
            "is_recurring": false,
            "is_disputed": false,
            "is_cleansed": false,
            "is_read": false,
            "price": 1,
            "quantity": 9000,
            "currency_code": null,
            "amount": null,
            "balance": null,
            "merchant_id": null,
            "mid": null,
            "merchant": null,
            "merchant_category_code": null,
            "transaction_category_id": null,
            "category": null,
            "subcategory": null,
            "description": null,
            "memo": null,
            "status": null,
            "location": {},
            "check": {},
            "funding_id": null,
            "security_id": "9679fd84-f6d5-44f9-bba9-a5fcb1b8b028",
            "transaction_code_id": "a65929b6-b0a9-46e5-858a-121f0b10f4fb",
            "portfolio_id": "647c54c3-b649-477e-8cc7-eee56a120dd3",
            "account_id": "647c54c3-b649-477e-8cc7-eee56a120dd3",
            "model_id": "feb846da-a06d-402e-a3bb-abc7260f7138",
            "metadata": {}
        },
        {
            "id": "107516c3-9035-4811-af7c-501be5a1fe26",
            "create_date": "2018-01-02T9:00:03.000+0000",
            "update_date": "2018-01-08T21:56:03.000+0000",
            "date": "2018-01-02T00:00:00.000+0000",
            "date_available": null,
            "is_recurring": false,
            "is_disputed": false,
            "is_cleansed": false,
            "is_read": false,
            "price": 60,
            "quantity": 133.33,
            "currency_code": null,
            "amount": null,
            "balance": null,
            "merchant_id": null,
            "mid": null,
            "merchant": null,
            "merchant_category_code": null,
            "transaction_category_id": null,
            "category": null,
            "subcategory": null,
            "description": null,
            "memo": null,
            "status": null,
            "location": {},
            "check": {},
            "funding_id": null,
            "security_id": "36a4b748-8a63-49a2-950f-deaa240c63d1",
            "transaction_code_id": "62fd0a9f-4bac-4b1d-94d2-2c5ea2adca3d",
            "portfolio_id": "a65929b6-b0a9-46e5-858a-121f0b10f4fb",
            "account_id": "a65929b6-b0a9-46e5-858a-121f0b10f4fb",
            "model_id": "21098ed9-6439-46ba-abd9-eb6cf28866fb",
            "metadata": {}
        },
        {
            "id": "199a8c08-cdd5-4c8c-8abf-535447cea11b",
            "create_date": "2018-01-02T9:00:03.000+0000",
            "update_date": "2018-01-08T21:56:03.000+0000",
            "date": "2018-01-02T00:00:00.000+0000",
            "date_available": null,
            "is_recurring": false,
            "is_disputed": false,
            "is_cleansed": false,
            "is_read": false,
            "price": 30,
            "quantity": 280,
            "currency_code": null,
            "amount": null,
            "balance": null,
            "merchant_id": null,
            "mid": null,
            "merchant": null,
            "merchant_category_code": null,
            "transaction_category_id": null,
            "category": null,
            "subcategory": null,
            "description": null,
            "memo": null,
            "status": null,
            "location": {},
            "check": {},
            "funding_id": null,
            "security_id": "7853af80-8d42-4bbb-bc06-00eda88a668e",
            "transaction_code_id": "62fd0a9f-4bac-4b1d-94d2-2c5ea2adca3d",
            "portfolio_id": "bab849d6-de96-4dc7-a5ea-19be45c52a4e",
            "account_id": "bab849d6-de96-4dc7-a5ea-19be45c52a4e",
            "model_id": "40a4bd78-d798-49f7-b1e8-35144c82e35e",
            "metadata": {}
        }
    ],
    "last": false,
    "total_pages": 1,
    "total_elements": 3,
    "sort": [
        {
            "direction": "DESC",
            "property": "updateDate",
            "ignore_case": false,
            "null_handling": "NATIVE",
            "descending": true,
            "ascending": false
        }
    ],
    "first": true,
    "number_of_elements": 3,
    "size": 25,
    "number": 0
}

Get the information for all transaction records for all portfolios defined for your tenant. The endpoint returns a list of portfolio_transaction_ids and the details for each transaction record. You can filter using a portfolio_id to view the transaction records for a specific portfolio. You can also provide a date range to view the transactions on the dates within that range. To obtain the appropriate portfolio_id use the GET /portfolio endpoint to view portfolios firm-wide.

HTTP REQUEST

GET /portfolio_transaction

Create a portfolio transaction

Example Request

curl -X POST -H "Authorization: Bearer <access_token>" \
    -H "Content-Type: application/json" \
    -d '{
            "date": "2018-01-02",
            "is_read": false,
            "price": 1,
            "quantity": 9000,
            "security_id": "9679fd84-f6d5-44f9-bba9-a5fcb1b8b028",
            "transaction_code_id": "a65929b6-b0a9-46e5-858a-121f0b10f4fb",
            "portfolio_id": "647c54c3-b649-477e-8cc7-eee56a120dd3"
      }' "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/portfolio_transaction"
api_instance = nucleus_api.PortfolioApi(nucleus_api.ApiClient(configuration))
# # # Create a PortfolioTransaction
check = nucleus_api.Check(check_number="5646686")
portfolio_transaction = nucleus_api.PortfolioTransaction(portfolio_id="b44d84ad-b1b2-463e-9ba8-b20523dd3e7a", _date="2020-10-10", transaction_code_id="56cd03e2-978e-4c16-a004-9564960bc4ac", account_id="ae66a845-cfe1-4402-9b0a-3aed87b33e29", model_id="b65c005a-f62f-4b0e-9528-b47f343fa049", check=check)
try:
    api_response = api_instance.create_portfolio_transaction_using_post(portfolio_transaction)
    pprint(api_response)
except ApiException as e:
    print("create_portfolio_transaction_using_post: %s\n" % e)
PortfolioApi apiInstance = new PortfolioApi();
        //Create a Portfolio Transaction
        PortfolioTransaction transaction = new PortfolioTransaction();
        transaction.setPortfolioId(UUID.fromString("b44d84ad-b1b2-463e-9ba8-b20523dd3e7a"));
        transaction.setDate(odt);
        transaction.setTransactionCodeId(UUID.fromString("56cd03e2-978e-4c16-a004-9564960bc4ac"));

        try {
            PortfolioTransaction response = apiInstance.createPortfolioTransactionUsingPost(transaction);
            System.out.println(response);
        } catch (ApiException e) {
            System.err.println("Exception when calling createPortfolioTransactionUsingPost");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\PortfolioApi(
    new GuzzleHttp\Client(),
    $config);
//Create Portfolio Transaction
$portfolio_transaction = new \com\hydrogen\nucleus\Model\PortfolioTransaction();

try {
    $portfolio_transaction->setPortfolioId("b44d84ad-b1b2-463e-9ba8-b20523dd3e7a");
    $portfolio_transaction->setDate("2020-10-10");
    $portfolio_transaction->setTransactionCodeId("56cd03e2-978e-4c16-a004-9564960bc4ac");
    $result = $apiInstance->createPortfolioTransactionUsingPost($portfolio_transaction);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->createPortfolioTransactionUsingPost: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::PortfolioApi.new
#Create Portfolio Transaction
portfolio_transaction = NucleusApi::PortfolioTransaction.new

begin
  portfolio_transaction.portfolio_id = "b44d84ad-b1b2-463e-9ba8-b20523dd3e7a"
  portfolio_transaction.transaction_code_id = "56cd03e2-978e-4c16-a004-9564960bc4ac"
  portfolio_transaction.date = '2020-10-10'
  result = api_instance.create_portfolio_transaction_using_post(portfolio_transaction)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->create_portfolio_transaction_using_post: #{e}"
end
var apiInstance = new HydrogenNucleusApi.PortfolioApi();
//Create a PortfolioTransaction
var portfoliotransaction = new HydrogenNucleusApi.PortfolioTransaction();
portfoliotransaction.portfolio_id = 'b44d84ad-b1b2-463e-9ba8-b20523dd3e7a';
portfoliotransaction.transaction_code_id = '56cd03e2-978e-4c16-a004-9564960bc4ac';
portfoliotransaction.date = "2020-10-10";



var newportfoliotransaction = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.createPortfolioTransactionUsingPost(portfoliotransaction, newportfoliotransaction)

Example Response

{
  "id": "099961da-7f41-4309-950f-2b51689a0033",
  "create_date": "2018-01-01T9:00:03.000+0000",
  "update_date": "2018-01-05T21:56:03.000+0000",
  "date": "2018-01-02T00:00:00.000+0000",
  "date_available": null,
  "is_recurring": false,
  "is_disputed": false,
  "is_cleansed": false,
  "is_read": false,
  "price": 1,
  "quantity": 9000,
  "currency_code": null,
  "amount": null,
  "balance": null,
  "merchant_id": null,
  "merchant": null,
  "merchant_category_code": null,
  "transaction_category_id": null,
  "category": null,
  "subcategory": null,
  "description": null,
  "memo": null,
  "status": null,
  "location": {},
  "check": {},
  "security_id": "9679fd84-f6d5-44f9-bba9-a5fcb1b8b028",
  "transaction_code_id": "a65929b6-b0a9-46e5-858a-121f0b10f4fb",
  "portfolio_id": "647c54c3-b649-477e-8cc7-eee56a120dd3",
  "account_id": "647c54c3-b649-477e-8cc7-eee56a120dd3",
  "model_id": "feb846da-a06d-402e-a3bb-abc7260f7138",
  "metadata": {}
}

Create a new transaction record for a portfolio. The unique portfolio_id must be provided, which will automatically pass in the model_id and account_id assigned to the portfolio. To obtain the appropriate portfolio_id, use the GET /portfolio endpoint to view all the portfolios defined for your tenant. The endpoint returns a portfolio_transaction_id used to manage the transaction record.

HTTP REQUEST

POST /portfolio_transaction

ARGUMENTS

Parameter Type Required Description
portfolio_id UUID required The id of the portfolioo that the transaction record relates to
transaction_code_id UUID required The id of the transaction code for the type of transaction
date timestamp required Timestamp when the transaction occurred
date_available timestamp optional Timestamp when the transaction becomes available
funding_id UUID optional The id of the funding request that the transaction record relates to
security_id UUID optional The id of the security that was bought or sold in the transaction. If the portfolio is for a bank account and no security is being bought such as a money market fund, then leave empty, or optionally create a “CASH” security
price double optional Price at which the security was bought or sold
quantity double optional Quantity of units of a security that were bought or sold
currency_code string optional Alphabetic currency code for the transaction, limited to 3 characters. See currency codes
amount double optional Amount of the transaction
balance double optional Updated balance of the portfolio as a result of the transaction
merchant_id UUID optional ID of the merchant resource for the transaction
merchant string optional The merchant for the transaction such as the merchant posted for a credit or debit card charge
merchant_category_code string optional The MCC Code for the merchant as identified by the card network
transaction_category_id string optional ID of the category resource for the transaction
category string optional Category of the transaction
subcategory string optional Subcategory of the transaction
description string optional Description of the transaction
memo string optional Memo attached to the transaction
status string optional Status of the transaction
location map optional Location where the transaction occurred
      address_line1 string optional Primary information for the street address, such as the street and building number
      address_line2 string optional Secondary information for the street address, such as a suite or apartment number
      city string optional City for the address
      state string optional State, province, or sub-country region for the address
      postalcode string optional Alphanumeric postal code or zip code for the address
      country string optional Country for the address using the ISO ALPHA-2 Code. See country codes
      latitude double optional Latitude of the location where the transaction occurred
      longitude double optional Longitude of the location where the transaction occurred
check map optional Check associated with the banking transaction
      check_number string required Number on the check such as “1234”
      check_amount double optional Monetary amount of the check
      check_images map optional Image(s) of the scanned check(s)
            image_url string required URL where the image can be displayed
            image_type string optional Type of image for the check such as “png” or “jpeg”
is_cleansed boolean optional Indicates if the transaction has been cleansed by a data cleansing engine. Defaults to false which indicates that it has not been cleansed
is_read boolean optional Indicates if the transaction has been read. Defaults to false which indicates that it has not been read
is_recurring boolean optional Indicates if the transaction is recurring such as a subscription. Defaults to false which indicates that it is not recurring
is_disputed boolean optional Indicates if the transaction is disputed by the client. Defaults to false which indicates that it is not disputed
metadata map optional Custom information associated with the portfolio transaction in the format key:value. See Metadata
secondary_id string optional Alternate id that can be used to identify the object such as an internal id

Retrieve a portfolio transaction

Example Request

curl -X GET -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/portfolio_transaction/099961da-7f41-4309-950f-2b51689a0033"
api_instance = nucleus_api.PortfolioApi(nucleus_api.ApiClient(configuration))
try:
    api_response = api_instance.get_portfolio_transaction_using_get("7cbaffc3-8f6c-4dda-934e-0347b3a7eafc")
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_portfolio_transaction_using_get: %s\n" % e)
PortfolioApi apiInstance = new PortfolioApi();
        try {
            PortfolioTransaction responseTransaction = apiInstance.getPortfolioTransactionUsingGet(UUID.fromString("51d4a4be-3a54-4f45-9aff-65f155a18040"), null);
            System.out.println(responseTransaction);
        } catch (ApiException e) {
            System.err.println("Exception when calling getPortfolioTransactionUsingGet");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\PortfolioApi(
    new GuzzleHttp\Client(),
    $config);
$portfolio_transaction_id = "51d4a4be-3a54-4f45-9aff-65f155a18040"; // string | UUID portfolio_transaction_id
$currency_conversion = null; // string | USD

try {
    $portfoliotransaction = $apiInstance->getPortfolioTransactionUsingGet($portfolio_transaction_id, $currency_conversion);
    print_r($portfoliotransaction);
} catch (Exception $e) {
    echo 'Exception when calling PortfolioApi->getPortfolioTransactionUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::PortfolioApi.new
portfolio_transaction_id = '51d4a4be-3a54-4f45-9aff-65f155a18040' # String | UUID portfolio_transaction_id

opts = {
    currency_conversion: null # String | USD
}

begin
  transaction = api_instance.get_portfolio_transaction_using_get(portfolio_transaction_id, opts)
  p transaction
rescue NucleusApi::ApiError => e
  puts "Exception when calling PortfolioApi->get_portfolio_transaction_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.PortfolioApi();
var portfoliotransactionID = "51d4a4be-3a54-4f45-9aff-65f155a18040";

var opts = {
    'currencyConversion': null, // String | USD
};

var portfolitransaction = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.getPortfolioTransactionUsingGet(portfoliotransactionID, opts, portfolitransaction)

Example Response

{
  "id": "099961da-7f41-4309-950f-2b51689a0033",
  "create_date": "2018-01-01T9:00:03.000+0000",
  "update_date": "2018-01-05T21:56:03.000+0000",
  "date": "2018-01-02T00:00:00.000+0000",
  "date_available": null,
  "is_recurring": false,
  "is_disputed": false,
  "is_cleansed": false,
  "is_read": false,
  "price": 1,
  "quantity": 9000,
  "currency_code": null,
  "amount": null,
  "balance": null,
  "merchant_id": null,
  "merchant": null,
  "merchant_category_code": null,
  "transaction_category_id": null,
  "category": null,
  "subcategory": null,
  "description": null,
  "memo": null,
  "status": null,
  "location": {},
  "check": {},
  "security_id": "9679fd84-f6d5-44f9-bba9-a5fcb1b8b028",
  "transaction_code_id": "a65929b6-b0a9-46e5-858a-121f0b10f4fb",
  "portfolio_id": "647c54c3-b649-477e-8cc7-eee56a120dd3",
  "account_id": "647c54c3-b649-477e-8cc7-eee56a120dd3",
  "model_id": "feb846da-a06d-402e-a3bb-abc7260f7138",
  "metadata": {}
}

Retrieve the information for a portfolio transaction record. The portfolio_transaction_id must be provided. The endpoint returns the portfolio_transaction_id and the details for the portfolio transaction record specified.

HTTP REQUEST

GET /portfolio_transaction/{portfolio_transaction_id}

Update a portfolio transaction

Example Request

curl -X PUT -H "Authorization: Bearer <access_token>" \
    -H "Content-Type: application/json" \
    -d '{
              "date": "2018-01-02",
              "is_read": false,
              "price": 1,
              "quantity": 9000,
              "security_id": "9679fd84-f6d5-44f9-bba9-a5fcb1b8b028",
              "transaction_code_id": "a65929b6-b0a9-46e5-858a-121f0b10f4fb",
              "portfolio_id": "647c54c3-b649-477e-8cc7-eee56a120dd3"
        }' "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/portfolio_transaction/099961da-7f41-4309-950f-2b51689a0033"
api_instance = nucleus_api.PortfolioApi(nucleus_api.ApiClient(configuration))
# # # Update a PortfolioTransaction
portfolio_transaction_update = {'currency_code': 'USD'}
portfolio_transaction_id = '1263d086-7374-4d48-9f2e-67b7069fcea2'
try:
    api_response = api_instance.update_portfolio_transaction_using_put(portfolio_transaction_update, portfolio_transaction_id)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling update_portfolio_transaction_using_put: %s\n" % e)
PortfolioApi apiInstance = new PortfolioApi();
        //Update a Portfolio Transaction
        Map map5 = new HashMap();
        map5.put("is_read", "true");

        try {
            PortfolioTransaction response = apiInstance.updatePortfolioTransactionUsingPut(map5, UUID.fromString("d8afa26b-74d2-4740-969e-fec2c72c7ffe"));
            System.out.println(response);
        } catch (ApiException e) {
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\PortfolioApi(
    new GuzzleHttp\Client(),
    $config);
//Update Portfolio Transaction
$portfolio_transaction_update = new stdClass();
$portfolio_transaction_id = "d8e18d0e-d9bb-4827-b1cf-f4489de83275";

try {
    $portfolio_transaction_update->date = "2020-10-10";
    $result = $apiInstance->updatePortfolioTransactionUsingPut($portfolio_transaction_update, $portfolio_transaction_id);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->updatePortfolioTransactionUsingPut: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::PortfolioApi.new
#Update Portfolio Transaction
portfolio_transaction_update = {"price" => '202'}
portfolio_transaction_id = 'a5abf725-c44b-4b3c-acfb-0dbb6b1d8ff6'
begin
  result = api_instance.update_portfolio_transaction_using_put(portfolio_transaction_update, portfolio_transaction_id)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->update_portfolio_transaction_using_put: #{e}"
end
var apiInstance = new HydrogenNucleusApi.PortfolioApi();
// //Update PortfolioTransaction
var apiInstance = new HydrogenNucleusApi.PortfolioApi();
var callback = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
var portfoliotransupdate = new HydrogenNucleusApi.PortfolioTransaction();
var porttransid = '262b7bb8-187f-4f5d-b2c8-d2e0472f3554';

portfoliotransupdate.currency_code = "CAD";
apiInstance.updatePortfolioTransactionUsingPut(portfoliotransupdate, porttransid, callback)

Example Response

{
  "id": "099961da-7f41-4309-950f-2b51689a0033",
  "create_date": "2018-01-01T9:00:03.000+0000",
  "update_date": "2018-01-05T21:56:03.000+0000",
  "date": "2018-01-02T00:00:00.000+0000",
  "date_available": null,
  "is_recurring": false,
  "is_disputed": false,
  "is_cleansed": false,
  "is_read": false,
  "price": 1,
  "quantity": 9000,
  "currency_code": null,
  "amount": null,
  "balance": null,
  "merchant_id": null,
  "merchant": null,
  "merchant_category_code": null,
  "transaction_category_id": null,
  "category": null,
  "subcategory": null,
  "description": null,
  "memo": null,
  "status": null,
  "location": {},
  "check": {},
  "security_id": "9679fd84-f6d5-44f9-bba9-a5fcb1b8b028",
  "transaction_code_id": "a65929b6-b0a9-46e5-858a-121f0b10f4fb",
  "portfolio_id": "647c54c3-b649-477e-8cc7-eee56a120dd3",
  "account_id": "647c54c3-b649-477e-8cc7-eee56a120dd3",
  "model_id": "feb846da-a06d-402e-a3bb-abc7260f7138",
  "metadata": {}
}

Update the information for a portfolio transaction record. The portfolio_transaction_id must be provided. To obtain the appropriate portfolio_transaction_id use the GET /portfolio_transaction endpoint to view all portfolio transaction records and their current information. The details to be updated must also be provided. The endpoint returns the portfolio_transaction_id and the details for the portfolio transaction record.

HTTP REQUEST

PUT /portfolio_transaction/{portfolio_transaction_id}

Delete a portfolio transaction

Example Request

curl -X DELETE -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/portfolio_transaction/099961da-7f41-4309-950f-2b51689a0033"
api_instance = nucleus_api.PortfolioApi(nucleus_api.ApiClient(configuration))
# # # Delete a PortfolioTransaction
portfolioTransaction1_id = 'ff1cb9e1-9861-48b3-9c2a-d8127aa0efef'
try:
    api_instance.delete_portfolio_transaction_using_delete(portfolioTransaction1_id)
except ApiException as e:
    print("Exception when delete_portfolio_transaction_using_delete: %s\n" % e)
PortfolioApi apiInstance = new PortfolioApi();
        //Delete a PortfolioTransaction
        try {
            PortfolioTransaction deleteresponse = apiInstance.deletePortfolioTransactionUsingDelete(UUID.fromString("dd456353-fcdd-48d2-a638-58dd007e2c52"));
            System.out.println(deleteresponse);
        } catch (ApiException e) {
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\PortfolioApi(
    new GuzzleHttp\Client(),
    $config);
//Delete Portfolio Transaction
$portfoliotransaction_did = "3758449e-ebd1-45da-8c8f-bbb191717ceb"; // string | UUID account_id

try {
    $apiInstance->deletePortfolioTransactionUsingDelete($portfoliotransaction_did);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->deletePortfolioTransactionUsingDelete: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::PortfolioApi.new

#Delete Portfolio Transaction
portfolio_transaction1_id = '7f074654-7f9d-4112-ae3f-3afb629f25b3'
begin
  result = api_instance.delete_portfolio_transaction_using_delete(portfolio_transaction1_id)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->delete_portfolio_transaction_using_delete: #{e}"
end
var apiInstance = new HydrogenNucleusApi.PortfolioApi();
// // // //Delete a PortfolioTransaction
var porttransdid = "f61945b1-4453-43cb-b080-9af34f60052f";


var deleteportfoliotrans = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully.');
    }
};
apiInstance.deletePortfolioTransactionUsingDelete(porttransdid, deleteportfoliotrans)

Response (204 No Content)

Permanently delete a portfolio transaction record. The portfolio_transaction_id must be provided. To obtain the appropriate portfolio_transaction_id use the GET /portfolio_transaction endpoint to view all portfolio transaction records. This deletes the portfolio_transaction_id and the details of the portfolio transaction record from the portfolio.

HTTP REQUEST

DELETE /portfolio_transaction/{portfolio_transaction_id}

Portfolio Commentary

Portfolio commentary is used to understand the logic behind each portfolio. Commentary may consist of rationale behind various trades conducted by your investment team such as rebalancing or strategic asset allocation changes.

Field Type Description
id UUID The id of the portfolio comment record
portfolio_id UUID The id of the portfolio that the comment belongs to
model_comment_id UUID The id of the corresponding model comment
model_id UUID The id of the model to which the portfolio subscribes. Derived from the portfolio
account_id UUID The id of the account to which the portfolio belongs. Derived from the portfolio
is_read boolean Indicates if the comment has been read. Defaults to false which indicates it has not been read
secondary_id string Alternate id that can be used to identify the object such as an internal id
create_date timestamp Timestamp for the date and time that the record was created
update_date timestamp Timestamp for the date and time that the record was last updated

List all portfolio commentary

Example Request

curl -X GET -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/portfolio_comment"
api_instance = nucleus_api.PortfolioApi(nucleus_api.ApiClient(configuration))
try:
    api_response = api_instance.get_portfolio_comment_all_using_get()
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_portfolio_comment_all_using_get: %s\n" % e)
PortfolioApi apiInstance = new PortfolioApi();
        try {
            PagePortfolioComment List = apiInstance.getPortfolioCommentAllUsingGet(true, null, null, 0, 10);
            System.out.println(List);
        } catch (ApiException e) {
            System.err.println("Exception when calling getPortfolioCommentAllUsingGet");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\PortfolioApi(
    new GuzzleHttp\Client(),
    $config);
$ascending = false; // bool | ascending
$filter = null; // string | filter
$order_by = null; // string | order_by
$page = 0; // int | page
$size = 10; // int | size

try {
    $portfoliocommentlist = $apiInstance->getPortfolioCommentAllUsingGet($ascending, $filter, $order_by, $page, $size);
    print_r($portfoliocommentlist);
} catch (Exception $e) {
    echo 'Exception when calling PortfolioApi->getPortfolioCommentAllUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::PortfolioApi.new
opts = {
    ascending: false, # BOOLEAN | ascending
    filter: null, # String | filter
    order_by: null, # String | order_by
    page: 0, # Integer | page
    size: 25 # Integer | size
}

begin
  commentlist = api_instance.get_portfolio_comment_all_using_get(opts)
  p commentlist
rescue NucleusApi::ApiError => e
  puts "Exception when calling PortfolioApi->get_portfolio_comment_all_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.PortfolioApi();
var opts = {
    'ascending': false, // Boolean | ascending
    'currencyConversion': null, // String | currency_conversion
    'filter': null, // String | filter
    'orderBy': null, // String | order_by
    'page': 0, // Number | page
    'size': 25 // Number | size
};

var portfoliocommentlist = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};

apiInstance.getPortfolioCommentAllUsingGet(opts, portfoliocommentlist)

Example Response

{
    "content": [
        {
            "id": "0d6d469e-22a9-4587-8249-bce8763d6efd",
            "create_date": "2018-01-01T19:29:37.000+0000",
            "update_date": "2018-01-15T09:00:00.000+0000",
            "is_read": false,
            "portfolio_id": "46841d3c-ac30-4011-b0a6-a0fcb313ebe3",
            "model_comment_id": "7f06b7b9-17f7-4390-afb2-1143b3ab7b",
            "model_id": "17b0323c-5a69-4d1e-a7b7-98c6d423148f",
            "account_id": "e281137e-748d-4f45-aaf1-ec91b90d7fe4"
        }
    ],
    "total_pages": 1,
    "total_elements": 1,
    "last": true,
    "sort": [
        {
            "direction": "DESC",
            "property": "id",
            "ignore_case": false,
            "null_handling": "NATIVE",
            "ascending": false,
            "descending": true
        }
    ],
    "first": true,
    "number_of_elements": 1,
    "size": 25,
    "number": 0
}

List all comments for all portfolios defined for your tenant. You can filter using a portfolio_id to view the comments for a specific portfolio. To obtain the appropriate portfolio_id, use the GET /portfolio endpoint to view all portfolios firm-wide. The endpoint returns a list of ids and the details for each portfolio comment.

HTTP REQUEST

GET /portfolio_comment

Create a portfolio commentary

Example Request

curl -X POST -H "Authorization: Bearer <access_token>" \
    -H "Content-Type: application/json" \
    -d '{
            "is_read": false,
            "portfolio_id": "46841d3c-ac30-4011-b0a6-a0fcb313ebe3",
            "model_comment_id": "7f06b7b9-17f7-4390-afb2-1143b3ab7b"
       }' "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/portfolio_comment"
api_instance = nucleus_api.PortfolioApi(nucleus_api.ApiClient(configuration))
# # # Create a PortfolioComment
# portfolio_comment = nucleus_api.PortfolioComment(portfolio_id="de8cdbfe-6b51-400f-808a-7bd1e1bd7c5c", model_id="86bcab43-2e7a-43ec-9ee8-4eb8321a7d34", model_comment_id="5cb5d61b-a7a7-4f90-a980-ce3ce0544e5d", account_id="034dffd8-6b72-4611-b26a-5a593e152939")
# try:
#     api_response = api_instance.create_portfolio_comment_using_post(portfolio_comment)
#     pprint(api_response)
# except ApiException as e:
#     print("create_portfolio_comment_using_post: %s\n" % e)
PortfolioApi apiInstance = new PortfolioApi();
        //Create a  PortfolioComment
        PortfolioComment comment = new PortfolioComment();
        comment.setPortfolioId(UUID.fromString("de8cdbfe-6b51-400f-808a-7bd1e1bd7c5c"));
        comment.setModelCommentId(UUID.fromString("5cb5d61b-a7a7-4f90-a980-ce3ce0544e5d"));
        comment.setModelId(UUID.fromString("86bcab43-2e7a-43ec-9ee8-4eb8321a7d34"));
        comment.setAccountId(UUID.fromString("034dffd8-6b72-4611-b26a-5a593e152939"));

        try {
            PortfolioComment result = apiInstance.createPortfolioCommentUsingPost(comment);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling createPortfolioCommentUsingPost");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\PortfolioApi(
    new GuzzleHttp\Client(),
    $config);
//Create Portfolio Commment
$portfolio_comment = new \com\hydrogen\nucleus\Model\PortfolioComment();

try {
    $portfolio_comment->setPortfolioId("de8cdbfe-6b51-400f-808a-7bd1e1bd7c5c");
    $portfolio_comment->setModelCommentId("5cb5d61b-a7a7-4f90-a980-ce3ce0544e5d");
    $portfolio_comment->setModelId("86bcab43-2e7a-43ec-9ee8-4eb8321a7d34");
    $portfolio_comment->setAccountId("034dffd8-6b72-4611-b26a-5a593e152939");
    $result = $apiInstance->createPortfolioCommentUsingPost($portfolio_comment);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->createPortfolioCommentUsingPost: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::PortfolioApi.new

#Create Portfolio Comment
portfolio_comment = NucleusApi::PortfolioComment.new

begin
  portfolio_comment.portfolio_id = "de8cdbfe-6b51-400f-808a-7bd1e1bd7c5c"
  portfolio_comment.model_comment_id = '5cb5d61b-a7a7-4f90-a980-ce3ce0544e5d'
  portfolio_comment.model_id = "86bcab43-2e7a-43ec-9ee8-4eb8321a7d34"
  portfolio_comment.account_id = "034dffd8-6b72-4611-b26a-5a593e152939"
  result = api_instance.create_portfolio_comment_using_post(portfolio_comment)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->create_portfolio_comment_using_post: #{e}"
end
var apiInstance = new HydrogenNucleusApi.PortfolioApi();
//Create a PortfolioComment
var portfoliocomment = new HydrogenNucleusApi.PortfolioComment();
portfoliocomment.portfolio_id = 'de8cdbfe-6b51-400f-808a-7bd1e1bd7c5c';
portfoliocomment.model_comment_id = '5cb5d61b-a7a7-4f90-a980-ce3ce0544e5d';
portfoliocomment.model_id = '86bcab43-2e7a-43ec-9ee8-4eb8321a7d34';
portfoliocomment.account_id = '034dffd8-6b72-4611-b26a-5a593e152939';


var newportfoliocomment = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.createPortfolioCommentUsingPost(portfoliocomment, newportfoliocomment)

Example Response

{
    "id": "0d6d469e-22a9-4587-8249-bce8763d6efd",
    "create_date": "2018-01-01T19:29:37.000+0000",
    "is_read": false,
    "portfolio_id": "46841d3c-ac30-4011-b0a6-a0fcb313ebe3",
    "model_comment_id": "7f06b7b9-17f7-4390-afb2-1143b3ab7b",
    "model_id": "17b0323c-5a69-4d1e-a7b7-98c6d423148f",
    "account_id": "e281137e-748d-4f45-aaf1-ec91b90d7fe4"
}

Create a new comment for a portfolio defined for your tenant. The unique portfolio_id must be provided, which will automatically pass in the model_id and account_id assigned to the portfolio. To obtain the appropriate portfolio_id, use the GET /portfolio endpoint to view all portfolios firm-wide. The corresponding model_comment_id must also be provided. To obtain the appropriate model_comment_id, use the GET /model_comment endpoint to view all model comment records defined for your tenant. The create_date will default to the current date. The endpoint returns a portfolio_comment_id used to manage the portfolio comment.

HTTP REQUEST

POST /portfolio_comment

ARGUMENTS

Parameter Type Required Description
portfolio_id string required The id of the portfolio that the comment belongs to
model_comment_id UUID required The id of the corresponding model comment
model_id UUID required The id of the model to which the portfolio subscribes. Derived from the portfolio
account_id UUID required The id of the account to which the portfolio belongs. Derived from the portfolio
is_read boolean optional Indicates if the comment has been read. Defaults to false which indicates it has not been read
secondary_id string optional Alternate id that can be used to identify the object such as an internal id

Retrieve a portfolio commentary

Example Request

curl -X GET -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/portfolio_comment/0d6d469e-22a9-4587-8249-bce8763d6efd"
api_instance = nucleus_api.PortfolioApi(nucleus_api.ApiClient(configuration))
try:
    api_response = api_instance.get_portfolio_comment_using_get("40d946f1-cc1b-4d32-947c-68e722d494d0")
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_portfolio_comment_using_get: %s\n" % e)
PortfolioApi apiInstance = new PortfolioApi();
        try {
            PortfolioComment responseComment = apiInstance.getPortfolioCommentUsingGet(UUID.fromString("8806a3ae-885b-4670-b5e8-dcd906d3e725"));
            System.out.println(responseComment);
        } catch (ApiException e) {
            System.err.println("Exception when calling getPortfolioCommentUsingGet");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\PortfolioApi(
    new GuzzleHttp\Client(),
    $config);
$portfolio_comment_id = "8806a3ae-885b-4670-b5e8-dcd906d3e725"; // string | UUID portfolio_comment_id

try {
    $portfoliocomment = $apiInstance->getPortfolioCommentUsingGet($portfolio_comment_id);
    print_r($portfoliocomment);
} catch (Exception $e) {
    echo 'Exception when calling PortfolioApi->getPortfolioCommentUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::PortfolioApi.new
portfolio_comment_id = '8806a3ae-885b-4670-b5e8-dcd906d3e725' # String | UUID portfolio_comment_id


begin
  comment = api_instance.get_portfolio_comment_using_get(portfolio_comment_id)
  p comment
rescue NucleusApi::ApiError => e
  puts "Exception when calling PortfolioApi->get_portfolio_comment_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.PortfolioApi();
var portfoliocommentID = "8806a3ae-885b-4670-b5e8-dcd906d3e725";

var opts = {
    'currencyConversion': null, // String | USD
};

var portfoliocomment = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.getPortfolioCommentUsingGet(portfoliocommentID, portfoliocomment)

Example Response

{
    "id": "0d6d469e-22a9-4587-8249-bce8763d6efd",
    "create_date": "2018-01-01T19:29:37.000+0000",
    "update_date": "2018-01-15T09:00:00.000+0000",
    "is_read": false,
    "portfolio_id": "46841d3c-ac30-4011-b0a6-a0fcb313ebe3",
    "model_comment_id": "7f06b7b9-17f7-4390-afb2-1143b3ab7b",
    "model_id": "17b0323c-5a69-4d1e-a7b7-98c6d423148f",
    "account_id": "e281137e-748d-4f45-aaf1-ec91b90d7fe4"
}

Retrieve the information for a portfolio comment. The portfolio_comment_id must be provided. The endpoint returns the portfolio_comment_id and the details for the portfolio comment specified.

HTTP REQUEST

GET /portfolio_comment/{portfolio_comment_id}

Update a portfolio commentary

Example Request

curl -X PUT -H "Authorization: Bearer <access_token>" \
    -H "Content-Type: application/json" \
    -d '{
          "is_read": false,
          "portfolio_id": "46841d3c-ac30-4011-b0a6-a0fcb313ebe3",
          "model_comment_id": "7f06b7b9-17f7-4390-afb2-1143b3ab7b"
      }' "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/portfolio_comment/0d6d469e-22a9-4587-8249-bce8763d6efd"
api_instance = nucleus_api.PortfolioApi(nucleus_api.ApiClient(configuration))
# # # Update a PortfolioComment
portfolio_comment_update = {'is_read': 'true'}
portfolio_comment_id = '54a655e9-122a-401b-af41-f1cc5ffbbfd2'
try:
    api_response = api_instance.update_portfolio_comment_using_put(portfolio_comment_update, portfolio_comment_id)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling update_portfolio_comment_using_put: %s\n" % e)
PortfolioApi apiInstance = new PortfolioApi();
        //Update a Portfolio Comment
        Map map2 = new HashMap();
        map2.put("is_read", "true");

        try {
            PortfolioComment response = apiInstance.updatePortfolioCommentUsingPut(map2, UUID.fromString("8806a3ae-885b-4670-b5e8-dcd906d3e725"));
            System.out.println(response);
        } catch (ApiException e) {
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\PortfolioApi(
    new GuzzleHttp\Client(),
    $config);

//Update Portfolio Comment
$portfolio_comment_update = new stdClass();
$portfolio_comment_id = "0985f65a-9174-4b62-bbf0-166c5b7d3b79";

try {
    $portfolio_comment_update->is_read = "false";
    $result = $apiInstance->updatePortfolioCommentUsingPut($portfolio_comment_update, $portfolio_comment_id);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->updatePortfolioCommentUsingPut: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::PortfolioApi.new

#Update Portfolio Comment
portfolio_comment_update = {"is_read" => 'false'}
portfolio_comment_id = '8806a3ae-885b-4670-b5e8-dcd906d3e725'
begin
  result = api_instance.update_portfolio_comment_using_put(portfolio_comment_update, portfolio_comment_id)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->update_portfolio_comment_using_put: #{e}"
end
var apiInstance = new HydrogenNucleusApi.PortfolioApi();
//Update PortfolioComment
var apiInstance = new HydrogenNucleusApi.PortfolioApi();
var callback = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
var portfoliocommentupdate = new HydrogenNucleusApi.PortfolioComment();
var portcommentid = '343c4c0b-5432-4fc7-88e9-d68ddc24ce72';

portfoliocommentupdate.is_read = "false";
apiInstance.updatePortfolioCommentUsingPut(portfoliocommentupdate, portcommentid, callback)

Example Response

{
    "id": "0d6d469e-22a9-4587-8249-bce8763d6efd",
    "create_date": "2018-01-01T19:29:37.000+0000",
    "update_date": "2018-01-15T09:00:00.000+0000",
    "is_read": false,
    "portfolio_id": "46841d3c-ac30-4011-b0a6-a0fcb313ebe3",
    "model_comment_id": "7f06b7b9-17f7-4390-afb2-1143b3ab7b",
    "model_id": "17b0323c-5a69-4d1e-a7b7-98c6d423148f",
    "account_id": "e281137e-748d-4f45-aaf1-ec91b90d7fe4"
}

Update the information for a portfolio comment. The portfolio_comment_id must be provided. To obtain the appropriate portfolio_comment_id, use the GET /portfolio_comment endpoint to view all the portfolio comments and their current information. The details to be updated must also be provided. The endpoint returns the portfolio_comment_id and the details for the portfolio comment.

HTTP REQUEST

PUT /portfolio_comment/{portfolio_comment_id}

Delete a portfolio commentary

Example Request

curl -X DELETE -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/portfolio_comment/0d6d469e-22a9-4587-8249-bce8763d6efd"
api_instance = nucleus_api.PortfolioApi(nucleus_api.ApiClient(configuration))
# # Delete a PortfolioComment
portfoilocomment1_id = 'f8d93b85-16cf-42eb-aeae-e0ba403b6282'
try:
    api_instance.delete_portfolio_comment_using_delete(portfoilocomment1_id)
except ApiException as e:
    print("Exception when delete_portfolio_comment_using_delete: %s\n" % e)
PortfolioApi apiInstance = new PortfolioApi();
        //Delete a PortfolioComment
        try {
            PortfolioComment deleteresponse = apiInstance.deletePortfolioCommentUsingDelete(UUID.fromString("b6532385-174c-4ed6-a601-74336b99c130"));
            System.out.println(deleteresponse);
        } catch (ApiException e) {
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\PortfolioApi(
    new GuzzleHttp\Client(),
    $config);

//Delete Portfolio Comment
$portfoliocomment_did = "eea18bce-cb6a-437d-993d-ab74604226ec"; // string | UUID account_id

try {
    $apiInstance->deletePortfolioCommentUsingDelete($portfoliocomment_did);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->deletePortfolioCommentUsingDelete: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::PortfolioApi.new
#Delete Portfolio Comment
portfolio_comment1_id = '0985f65a-9174-4b62-bbf0-166c5b7d3b79'
begin
  result = api_instance.delete_portfolio_comment_using_delete(portfolio_comment1_id)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->delete_portfolio_comment_using_delete: #{e}"
end
var apiInstance = new HydrogenNucleusApi.PortfolioApi();
// //Delete a PortfolioComment
var portcommentdid = "8806a3ae-885b-4670-b5e8-dcd906d3e725";


var deleteportfoliocomment = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully.');
    }
};
apiInstance.deletePortfolioCommentUsingDelete(portcommentdid, deleteportfoliocomment)

Response (204 No Content)

Permanently delete a portfolio comment. The portfolio_comment_id must be provided. To obtain the appropriate portfolio_comment_id, use the GET /portfolio_comment endpoint to view all the portfolio comments. This deletes the portfolio_comment_id and the portfolio comment record from the portfolio.

HTTP REQUEST

DELETE /portfolio_comment/{portfolio_comment_id}

Portfolio Goal

Assign a portfolio to a goal and track over time. This endpoint should be used if you are tracking goals at a portfolio level such as creating goals in subaccounts for a banking/savings solution. If you are tracking goals one level higher at the account level, then use the account-allocation service instead.

Field Type Description
id UUID The id of the portfolio goal record
portfolio_id UUID The id of the portfolio that the goal is for
date date The date the portfolio-goal relationship exists
goals map List of goals mapped to the portfolio with the goal and weight
      goal_id UUID The id of the goal assigned to the portfolio
      weight double The weight of the goal for the portfolio on the date specified
secondary_id string Alternate id that can be used to identify the object such as an internal id
create_date timestamp Timestamp for the date and time that the record was created
update_date timestamp Timestamp for the date and time that the record was last updated

List all portfolio goals

Example Request

curl -X GET -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/portfolio_goal"
api_instance = nucleus_api.PortfolioApi(nucleus_api.ApiClient(configuration))
try:
    api_response = api_instance.get_portfolio_goal_all_using_get()
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_portfolio_goal_all_using_get: %s\n" % e)
PortfolioApi apiInstance = new PortfolioApi();
        try {
            PagePortfolioGoal List = apiInstance.getPortfolioGoalAllUsingGet(true, null, null, 0, 5);
            System.out.println(List);
        } catch (ApiException e) {
            System.err.println("Exception when calling getPortfolioGoalAllUsingGet");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\PortfolioApi(
    new GuzzleHttp\Client(),
    $config);
$ascending = false; // bool | ascending
$filter = null; // string | filter
$order_by = null; // string | order_by
$page = 0; // int | page
$size = 10; // int | size

try {
    $portfoliogoallist = $apiInstance->getPortfolioGoalAllUsingGet($ascending, $filter, $order_by, $page, $size);
    print_r($portfoliogoallist);
} catch (Exception $e) {
    echo 'Exception when calling PortfolioApi->getPortfolioGoalAllUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::PortfolioApi.new
opts = {
    ascending: false, # BOOLEAN | ascending
    filter: null, # String | filter
    order_by: null, # String | order_by
    page: 0, # Integer | page
    size: 25 # Integer | size
}

begin
  goallist = api_instance.get_portfolio_goal_all_using_get(opts)
  p goallist
rescue NucleusApi::ApiError => e
  puts "Exception when calling PortfolioApi->get_portfolio_goal_all_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.PortfolioApi();
var opts = {
    'ascending': false, // Boolean | ascending
    'currencyConversion': null, // String | currency_conversion
    'filter': null, // String | filter
    'orderBy': null, // String | order_by
    'page': 0, // Number | page
    'size': 25 // Number | size
};

var portfolioGoallist = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};

apiInstance.getPortfolioGoalAllUsingGet(opts, portfolioGoallist)

Example Response

{
    "content": [
        {
            "id": "0d6d469e-22a9-4587-8249-bce8763d6efd",
            "portfolio_id": "46841d3c-ac30-4011-b0a6-a0fcb313ebe3",
            "date": "2019-01-02",
            "goals": [
              {
                "goal_id": "17b0323c-5a69-4d1e-a7b7-98c6d423148f",
                "weight": "100"
              }
            ],
            "secondary_id": null,
            "create_date": "2019-01-03T19:29:37.000+0000",
            "update_date": "2019-01-03T19:29:37.000+0000"
        }
    ],
    "total_pages": 1,
    "total_elements": 1,
    "last": true,
    "sort": [
        {
            "direction": "DESC",
            "property": "id",
            "ignore_case": false,
            "null_handling": "NATIVE",
            "ascending": false,
            "descending": true
        }
    ],
    "first": true,
    "number_of_elements": 1,
    "size": 25,
    "number": 0
}

List all portfolio goals defined for your tenant. You can filter using a portfolio_id to view the goals for a specific portfolio. To obtain the appropriate portfolio_id, use the GET /portfolio endpoint to view all portfolios firm-wide. The endpoint returns a list of ids and the details for each portfolio goal.

HTTP REQUEST

GET /portfolio_goal

Create a portfolio goal

Example Request

curl -X POST -H "Authorization: Bearer <access_token>" \
    -H "Content-Type: application/json" \
    -d '{
          "portfolio_id": "46841d3c-ac30-4011-b0a6-a0fcb313ebe3",
          "date": "2019-01-02",
          "goals": [
            {
              "goal_id": "17b0323c-5a69-4d1e-a7b7-98c6d423148f",
              "weight": "100"
            }
          ]
      }' "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/portfolio_goal"
api_instance = nucleus_api.PortfolioApi(nucleus_api.ApiClient(configuration))
# # Create a PortfolioGoal
map = nucleus_api.PortfolioGoalMap(goal_id="cd2ce0df-5d83-4129-8f9b-fdcf14ad16ca", weight="100")
portfolio_goal = nucleus_api.PortfolioGoal(_date="2020-10-10", portfolio_id="7923f20a-0424-4edb-9992-eada1054b12b", goals=[map])
try:
    api_response = api_instance.create_portfolio_goal_using_post(portfolio_goal)
    pprint(api_response)
except ApiException as e:
    print("create_portfolio_goal_using_post: %s\n" % e)
PortfolioApi apiInstance = new PortfolioApi();
        //Create a Portfolio Goal
        PortfolioGoal goal = new PortfolioGoal();
        goal.setPortfolioId(UUID.fromString("7923f20a-0424-4edb-9992-eada1054b12b"));
        goal.setDate(date);
        PortfolioGoalMap maps = new PortfolioGoalMap();
        maps.setGoalId(UUID.fromString("cd2ce0df-5d83-4129-8f9b-fdcf14ad16ca"));
        maps.setWeight(100.0);
        List<PortfolioGoalMap> stats = Arrays.asList(maps);
        goal.setGoals(stats);

        try {
            PortfolioGoal result = apiInstance.createPortfolioGoalUsingPost(goal);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling createPortfolioGoalUsingPost");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\PortfolioApi(
    new GuzzleHttp\Client(),
    $config);


//Create Portfolio Goal
$portfolio_goal = new \com\hydrogen\nucleus\Model\PortfolioGoal();
$maps = new \com\hydrogen\nucleus\Model\PortfolioGoalMap();

try {
    $portfolio_goal->setPortfolioId('7923f20a-0424-4edb-9992-eada1054b12b');
    $portfolio_goal->setDate("2020-10-10");
    $maps->setGoalId("cd2ce0df-5d83-4129-8f9b-fdcf14ad16ca");
    $maps->setWeight("30");
    $portfolio_goal->setGoals([$maps]);
    $result = $apiInstance->createPortfolioGoalUsingPost($portfolio_goal);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->createPortfolioGoalUsingPost: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::PortfolioApi.new
#Create Portfolio Goal
portfolio_goal = NucleusApi::PortfolioGoal.new
map = NucleusApi::PortfolioGoalMap.new

begin
  portfolio_goal.portfolio_id = "7923f20a-0424-4edb-9992-eada1054b12b"
  portfolio_goal.date = "2020-10-10"
  map.goal_id = "cd2ce0df-5d83-4129-8f9b-fdcf14ad16ca"
  map.weight = "50"
  portfolio_goal.goals = [map]
  result = api_instance.create_portfolio_goal_using_post(portfolio_goal)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->create_portfolio_goal_using_post: #{e}"
end
var apiInstance = new HydrogenNucleusApi.PortfolioApi();
//Create a PortfolioGoal
var portfoliogoal = new HydrogenNucleusApi.PortfolioGoal();
portfoliogoal.portfolio_id = '7923f20a-0424-4edb-9992-eada1054b12b';
portfoliogoal.date = "2020-06-10";
var map = new HydrogenNucleusApi.PortfolioGoalMap();
map.goal_id = 'cd2ce0df-5d83-4129-8f9b-fdcf14ad16ca';
map.weight = "100";
portfoliogoal.goals = [map];



var newportfoliogoal = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.createPortfolioGoalUsingPost(portfoliogoal, newportfoliogoal)

Example Response

{
  "id": "0d6d469e-22a9-4587-8249-bce8763d6efd",
  "portfolio_id": "46841d3c-ac30-4011-b0a6-a0fcb313ebe3",
  "date": "2019-01-02",
  "goals": [
    {
      "goal_id": "17b0323c-5a69-4d1e-a7b7-98c6d423148f",
      "weight": "100"
    }
  ],
  "secondary_id": null,
  "create_date": "2019-01-03T19:29:37.000+0000",
  "update_date": "2019-01-03T19:29:37.000+0000"
}

Create a new portfolio goal defined for your tenant. The unique portfolio_id must be provided. To obtain the appropriate portfolio_id, use the GET /portfolio endpoint to view all portfolios firm-wide. The endpoint returns a portfolio_goal_id used to manage the portfolio goal.

HTTP REQUEST

POST /portfolio_goal

ARGUMENTS

Parameter Type Required Description
portfolio_id UUID required The id of the portfolio that the goal is for
date date required The date the portfolio-goal relationship exists
goals map required List of goals mapped to the portfolio with the goal and weight
      goal_id UUID required The id of the goal assigned to the portfolio
      weight double required The weight of the goal for the portfolio on the date specified
secondary_id string optional Alternate id that can be used to identify the object such as an internal id

Retrieve a portfolio goal

Example Request

curl -X GET -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/portfolio_goal/0d6d469e-22a9-4587-8249-bce8763d6efd"
api_instance = nucleus_api.PortfolioApi(nucleus_api.ApiClient(configuration))
try:
    api_response = api_instance.get_portfolio_goal_using_get("a0a4be74-38e5-497c-9bf5-0a8a019db99b")
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_portfolio_goal_using_get: %s\n" % e)
PortfolioApi apiInstance = new PortfolioApi();
        try {
            PortfolioGoal responseGoal = apiInstance.getPortfolioGoalUsingGet(UUID.fromString("04f5ed39-dbd5-4bfb-8d55-6e4b1796e6ed"));
            System.out.println(responseGoal);
        } catch (ApiException e) {
            System.err.println("Exception when calling getPortfolioGoalUsingGet");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\PortfolioApi(
    new GuzzleHttp\Client(),
    $config);
$portfolio_goal_id = "04f5ed39-dbd5-4bfb-8d55-6e4b1796e6ed"; // string | UUID portfolio_goal_id

try {
    $portfoliogoal = $apiInstance->getPortfolioGoalUsingGet($portfolio_goal_id);
    print_r($portfoliogoal);
} catch (Exception $e) {
    echo 'Exception when calling PortfolioApi->getPortfolioGoalUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::PortfolioApi.new
portfolio_goal_id = '04f5ed39-dbd5-4bfb-8d55-6e4b1796e6ed' # String | UUID portfolio_goal_id


begin
  goal = api_instance.get_portfolio_goal_using_get(portfolio_goal_id)
  p goal
rescue NucleusApi::ApiError => e
  puts "Exception when calling PortfolioApi->get_portfolio_goal_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.PortfolioApi();
var portfoliogoalID = "04f5ed39-dbd5-4bfb-8d55-6e4b1796e6ed";

var opts = {
    'currencyConversion': null, // String | USD
};

var portfoliogoal = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.getPortfolioGoalUsingGet(portfoliogoalID, portfoliogoal)

Example Response

{
  "id": "0d6d469e-22a9-4587-8249-bce8763d6efd",
  "portfolio_id": "46841d3c-ac30-4011-b0a6-a0fcb313ebe3",
  "date": "2019-01-02",
  "goals": [
    {
     "goal_id": "17b0323c-5a69-4d1e-a7b7-98c6d423148f",
     "weight": "100"
    }
  ],
  "secondary_id": null,
  "create_date": "2019-01-03T19:29:37.000+0000",
  "update_date": "2019-01-03T19:29:37.000+0000"
}

Retrieve the information for a portfolio goal. The portfolio_goal_id must be provided. The endpoint returns the portfolio_goal_id and the details for the portfolio goal specified.

HTTP REQUEST

GET /portfolio_goal/{portfolio_goal_id}

Update a portfolio goal

Example Request

curl -X PUT -H "Authorization: Bearer <access_token>" \
    -H "Content-Type: application/json" \
    -d '{
        "goals": [
          {
            "goal_id": "e281137e-748d-4f45-aaf1-ec91b90d7fe4",
            "weight":100
          }
        ]
      }' "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/portfolio_goal/0d6d469e-22a9-4587-8249-bce8763d6efd"
api_instance = nucleus_api.PortfolioApi(nucleus_api.ApiClient(configuration))
# # # Update a PortfolioGoal
portfolio_goal_update = {'secondary_id': 'None'}
portfolio_goal_id = '3b6d473c-8bad-4d29-b558-b4c9fae593a6'
try:
    api_response = api_instance.update_portfolio_goal_using_put(portfolio_goal_update, portfolio_goal_id)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling update_portfolio_goal_using_put: %s\n" % e)
PortfolioApi apiInstance = new PortfolioApi();
        //Update a Portfolio Goal
        Map map3 = new HashMap();
        map3.put("date", "2020-05-06");

        try {
            PortfolioGoal response = apiInstance.updatePortfolioGoalUsingPut(map3, UUID.fromString("1acf9fa0-c0a4-42b9-b9b6-62d6d963aca8"));
            System.out.println(response);
        } catch (ApiException e) {
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\PortfolioApi(
    new GuzzleHttp\Client(),
    $config);


//Create Portfolio Goal
$portfolio_goal = new \com\hydrogen\nucleus\Model\PortfolioGoal();
//Update Portfolio Goal
$portfolio_goal_update = new stdClass();
$portfolio_goal_id = "3b6d473c-8bad-4d29-b558-b4c9fae593a6";

try {
    $portfolio_goal_update->date = "2020-10-10";
    $result = $apiInstance->updatePortfolioGoalUsingPut($portfolio_goal_update, $portfolio_goal_id);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->updatePortfolioGoalUsingPut: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::PortfolioApi.new
#Update Portfolio Goal
portfolio_goal_update = {"date" => '2020-10-10'}
portfolio_goal_id = '1acf9fa0-c0a4-42b9-b9b6-62d6d963aca8'
begin
  result = api_instance.update_portfolio_goal_using_put(portfolio_goal_update, portfolio_goal_id)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->update_portfolio_goal_using_put: #{e}"
end
var apiInstance = new HydrogenNucleusApi.PortfolioApi();
//Update PortfolioGoal
var apiInstance = new HydrogenNucleusApi.PortfolioApi();
var callback = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
var portfoliogoalupdate = new HydrogenNucleusApi.PortfolioGoal();
var portgoalid = '2e641b9b-535e-45f7-b227-6b4974682952';

portfoliogoalupdate.secondary_id = "null";
apiInstance.updatePortfolioGoalUsingPut(portfoliogoalupdate, portgoalid, callback)

Example Response

{
  "id": "0d6d469e-22a9-4587-8249-bce8763d6efd",
  "portfolio_id": "46841d3c-ac30-4011-b0a6-a0fcb313ebe3",
  "date": "2019-01-02",
  "goals": [
    {
     "goal_id": "e281137e-748d-4f45-aaf1-ec91b90d7fe4",
     "weight": "100"
    }
  ],
  "secondary_id": null,
  "create_date": "2019-01-03T19:29:37.000+0000",
  "update_date": "2019-01-25T17:18:25.000+0000"
}

Update the information for a portfolio goal. The portfolio_goal_id must be provided. To obtain the appropriate portfolio_goal_id, use the GET /portfolio_goal endpoint to view all the portfolio goals and their current information. The details to be updated must also be provided. The endpoint returns the portfolio_goal_id and the details for the portfolio goal.

HTTP REQUEST

PUT /portfolio_goal/{portfolio_goal_id}

Delete a portfolio goal

Example Request

curl -X DELETE -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/portfolio_goal/0d6d469e-22a9-4587-8249-bce8763d6efd"
api_instance = nucleus_api.PortfolioApi(nucleus_api.ApiClient(configuration))
# # # Delete a PortfolioGoal
portfoilogoal1_id = '6fb93dd7-da48-477e-b00f-88159b3b355d'
try:
    api_instance.delete_portfolio_goal_using_delete(portfoilogoal1_id)
except ApiException as e:
    print("Exception when delete_portfolio_goal_using_delete: %s\n" % e)
PortfolioApi apiInstance = new PortfolioApi();
        //Delete a PortfolioGoal
        try {
            PortfolioGoal deleteresponse = apiInstance.deletePortfolioGoalUsingDelete(UUID.fromString("724daa64-c5b0-403a-9b5a-75e43de672ac"));
            System.out.println(deleteresponse);
        } catch (ApiException e) {
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\PortfolioApi(
    new GuzzleHttp\Client(),
    $config);

//Delete Portfolio Goal
$portfoliogoal_did = "1acf9fa0-c0a4-42b9-b9b6-62d6d963aca8"; // string | UUID account_id

try {
    $apiInstance->deletePortfolioGoalUsingDelete($portfoliogoal_did);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->deletePortfolioGoalUsingDelete: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::PortfolioApi.new

#Delete Portfolio Goal
portfolio_goal1_id = 'd835fd5e-e464-44b4-a77a-ff90d3e98d0d'
begin
  result = api_instance.delete_portfolio_goal_using_delete(portfolio_goal1_id)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->delete_portfolio_goal_using_delete: #{e}"
end
var apiInstance = new HydrogenNucleusApi.PortfolioApi();
// // //Delete a PortfolioGoal
var portgoaldid = "1acf9fa0-c0a4-42b9-b9b6-62d6d963aca8";


var deleteportfoligoal = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully.');
    }
};
apiInstance.deletePortfolioGoalUsingDelete(portgoaldid, deleteportfoligoal)

Response (204 No Content)

Permanently delete a goal for a portfolio. The portfolio_goal_id must be provided. To obtain the appropriate portfolio_goal_id, use the GET /portfolio_goal endpoint to view all the portfolio goals. This deletes the portfolio_goal_id and the goal record from the portfolio.

HTTP REQUEST

DELETE /portfolio_goal/{portfolio_goal_id}

Utils

Common utilities that are used in multiple account and client services.

Application

Create an application to track a user’s activity within multiple apps. These could be different products within your firm or a product with multiple apps.

Field Type Description
id UUID The id of the application
name string Name of the application
description string Description for the application
device string Device that the application runs on such as “Mobile” or “Web”
metadata map Custom information associated with the application in the format key:value
See Metadata
secondary_id string Alternate id that can be used to identify the object such as an internal id
create_date timestamp Timestamp for the date and time that the application was created
update_date timestamp Timestamp for the date and time that the application was last updated

List all applications

Example Request

curl -X GET -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/application"
api_instance = nucleus_api.UtilsApi(nucleus_api.ApiClient(configuration))
# List all Applications
try:
    api_response = api_instance.get_application_all_using_get()
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_application_all_using_get: %s\n" % e)
UtilsApi apiInstance = new UtilsApi();

                //List all Application
        try {
            PageApplication List = apiInstance.getApplicationAllUsingGet(true, null, null, 0, 10);
            System.out.println(List);
        } catch (ApiException e) {
            System.err.println("Exception when calling getApplicationAllUsingGet");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\UtilsApi(
    new GuzzleHttp\Client(),
    $config);
//List all Applications
$ascending = false; // bool | ascending
$filter = null; // string | filter
$order_by = null; // string | order_by
$page = 0; // int | page
$size = 10; // int | size

try {
    $applicationlist = $apiInstance->getApplicationAllUsingGet($ascending, $filter, $order_by, $page, $size);
    print_r($applicationlist);
} catch (Exception $e) {
    echo 'Exception when calling ApplicationApi->getApplicationAllUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::UtilsApi.new
#List all Applications
opts = {
  ascending: false, # BOOLEAN | ascending
  filter: null, # String | filter
  order_by: null, # String | order_by
  page: 0, # Integer | page
  size: 25 # Integer | size
}

begin
  applicationlist = api_instance.get_application_all_using_get(opts)
  p applicationlist
rescue NucleusApi::ApiError => e
  puts "Exception when calling ApplicationApi->get_application_all_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.UtilsApi();
//List all Applications

var opts = {
    'ascending': false, // Boolean | ascending
    // 'filter': "", // String | filter
    'orderBy': "update_date", // String | order_by
    'page': 0, // Number | page
    'size': 25 // Number | size
};

var applicationlist = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.getApplicationAllUsingGet(opts, applicationlist)

Example Response

{
    "content": [
        {
            "id": "36f9cb66-88a9-4a1f-a305-338a0f0e0a57",
            "create_date": "2018-08-12T18:47:38.000+0000",
            "update_date": "2018-08-13T09:00:00.000+0000",
            "name": "PFM App Web",
            "description": "Web app to track held away accounts, cash flows, and budgets.",
            "device": "Web",
            "metadata": {}
        },
        {
            "id": "c4ea6c00-d0b4-4d75-9e7a-e9dd04319586",
            "create_date": "2018-09-12T18:46:12.000+0000",
            "update_date": "2018-09-13T09:00:00.000+0000",
            "name": "PFM App iOS",
            "description": "Mobile app to track held away accounts, cash flows, and budgets.",
            "device": "Mobile - iOS",
            "metadata": {}
        }
    ],
    "total_pages": 1,
    "total_elements": 2,
    "last": true,
    "first": true,
    "sort": [
        {
            "direction": "DESC",
            "property": "updateDate",
            "ignore_case": false,
            "null_handling": "NATIVE",
            "descending": true,
            "ascending": false
        }
    ],
    "number_of_elements": 2,
    "size": 25,
    "number": 0
}

Get all the applications defined for your firm.

HTTP REQUEST

GET /application

Create an application

Example Request

curl -X POST -H "Authorization: Bearer <access_token>" \
    -H "Content-Type: application/json" \
    -d '{
          "name": "PFM App iOS",
          "description": "Mobile app to track held away accounts, cash flows, and budgets.",
          "device": "Mobile - iOS"
        }' "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/application"
api_instance = nucleus_api.UtilsApi(nucleus_api.ApiClient(configuration))
Create Appplication
application = nucleus_api.Application(name="new")
try:
    api_response = api_instance.create_application_using_post(application)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling create_application_using_post: %s\n" % e)
UtilsApi apiInstance = new UtilsApi();
        //Create an Application
        Application app = new Application();
        app.setName("New App");

        try {
            Application result = apiInstance.createApplicationUsingPost(app);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling createApplicationUsingPost");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\UtilsApi(
    new GuzzleHttp\Client(),
    $config);
//Create Application
$application = new \com\hydrogen\nucleus\Model\Application();


try {
    $application->setName("New Appp");
    $result = $apiInstance->createApplicationUsingPost($application);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->createApplicationUsingPost: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::UtilsApi.new
#Create Application
application = NucleusApi::Application.new

begin
  application.name = "New Name"
  result = api_instance.create_application_using_post(application)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->create_application_using_post: #{e}"
end
var apiInstance = new HydrogenNucleusApi.UtilsApi();

//Create a Application
var application = new HydrogenNucleusApi.Application();
application.name = "New";

var newapplication = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.createApplicationUsingPost(application, newapplication)

Example Response

{
  "id": "c4ea6c00-d0b4-4d75-9e7a-e9dd04319586",
  "create_date": "2018-04-12T18:46:12.000+0000",
  "update_date": "2018-04-13T09:00:00.000+0000",
  "name": "PFM App iOS",
  "description": "Mobile app to track held away accounts, cash flows, and budgets.",
  "device": "Mobile - iOS",
  "metadata": {}
}

Create an application for your firm. You must enter a name for the application. The endpoint returns an application_id used to identify and manage the application.

HTTP REQUEST

POST /application

ARGUMENTS

Parameter Type Required Description
name string required Name of the application
description string optional Description for the application
device string optional Device that the application runs on such as “Mobile” or “Web”
metadata map optional Custom information associated with the application in the format key:value
See Metadata
secondary_id string optional Alternate id that can be used to identify the object such as an internal id

Retrieve an application

Example Request

curl -X GET -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/application/c4ea6c00-d0b4-4d75-9e7a-e9dd04319586"
api_instance = nucleus_api.UtilsApi(nucleus_api.ApiClient(configuration))
# Retrieve an Application
try:
    api_response = api_instance.get_application_using_get("330b4066-bb1f-4b1f-8235-ea69f2dd7977")
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_application_using_get: %s\n" % e)
UtilsApi apiInstance = new UtilsApi();
                //Retrieve a Application
        try {
            Application response  = apiInstance.getApplicationUsingGet(UUID.fromString("ab5aad70-4c4a-40ea-96d8-d176fc5c2831"));
            System.out.println(response);
        } catch (ApiException e) {
            System.err.println("Exception when calling getStageUsingGet");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\UtilsApi(
    new GuzzleHttp\Client(),
    $config);
//Retrieve an Application
$application_id = "330b4066-bb1f-4b1f-8235-ea69f2dd7977"; // string | UUID application_id

try {
    $application = $apiInstance->getApplicationUsingGet($application_id);
    print_r($application);
} catch (Exception $e) {
    echo 'Exception when calling ApplicationApi->getApplicationUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::UtilsApi.new
#Retrieve an Application
application_id = '330b4066-bb1f-4b1f-8235-ea69f2dd7977' # String | UUID application_id

begin
  application = api_instance.get_application_using_get(application_id)
  p application
rescue NucleusApi::ApiError => e
  puts "Exception when calling ApplicationApi->get_application_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.UtilsApi();
//Retrieve an Application

var applicationId = "330b4066-bb1f-4b1f-8235-ea69f2dd7977";


var application = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.getApplicationUsingGet("330b4066-bb1f-4b1f-8235-ea69f2dd7977", application)

Example Response

{
  "id": "c4ea6c00-d0b4-4d75-9e7a-e9dd04319586",
  "create_date": "2018-04-12T18:46:12.000+0000",
  "update_date": "2018-04-13T09:00:00.000+0000",
  "name": "PFM App iOS",
  "description": "Mobile app to track held away accounts, cash flows, and budgets.",
  "device": "Mobile - iOS",
  "metadata": {}
}

Retrieve an application for your firm. The application_id must be provided. The endpoint returns the application_id and the details for the application specified.

HTTP REQUEST

GET /application/{application_id}

Update an application

Example Request

curl -X PUT -H "Authorization: Bearer <access_token>" \
     -H "Content-Type: application/json" \
     -d '{
          "device": "Mobile - Android"
        }' "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/application/c4ea6c00-d0b4-4d75-9e7a-e9dd04319586"
api_instance = nucleus_api.UtilsApi(nucleus_api.ApiClient(configuration))
#Update Application
app_update = {'name': 'Application'}
app_id = '6fc10b6b-c60d-401e-8fbd-b42af6d399e0'
try:
    api_response = api_instance.update_application_using_put(app_update, app_id)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling update_application_using_put: %s\n" % e)
UtilsApi apiInstance = new UtilsApi();
        //        //Update a Application
        Map map2 = new HashMap();
        map2.put("name", "ABC");

        try {
            Application response = apiInstance.updateApplicationUsingPut(map2, UUID.fromString("330b4066-bb1f-4b1f-8235-ea69f2dd7977"));
            System.out.println(response);
        } catch (ApiException e) {
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\UtilsApi(
    new GuzzleHttp\Client(),
    $config);
//Update Application
$application_update = new stdClass();
$application_id = "330b4066-bb1f-4b1f-8235-ea69f2dd7977";

try {
    $application_update->name = "ABC";
    $result = $apiInstance->updateApplicationUsingPut($application_update, $application_id);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->updateApplicationUsingPut: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::UtilsApi.new
#Update Application
application_update = {"name" => 'ABC'}
application_id = 'd6a3cd18-4730-478b-8523-4d102c2ddee0'
begin
  result = api_instance.update_application_using_put(application_update, application_id)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->update_application_using_put: #{e}"
end
var apiInstance = new HydrogenNucleusApi.UtilsApi();
//Update Application
var apiInstance = new HydrogenNucleusApi.UtilsApi();
var callback = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
var applicationupdate = new HydrogenNucleusApi.Application();
var applicationid = 'ec7a9c79-72f5-4781-8e1d-9e09a434a031';

applicationupdate.device = "New";
apiInstance.updateApplicationUsingPut(applicationupdate, applicationid, callback)

Example Response

{
  "id": "c4ea6c00-d0b4-4d75-9e7a-e9dd04319586",
  "create_date": "2018-04-12T18:46:12.000+0000",
  "update_date": "2018-04-13T09:00:00.000+0000",
  "name": "PFM App iOS",
  "description": "Mobile app to track held away accounts, cash flows, and budgets.",
  "device": "Mobile - Android",
  "metadata": {}
}

Update an application for your firm. The application_id must be provided. To obtain the appropriate application_id, use the GET /application endpoint to view all of the applications for your firm and their current information. The details to be updated and the details to be maintained must also be provided. The endpoint returns the application_id and the details for the application.

HTTP REQUEST

PUT /application/{application_id}

Delete an application

Example Request

curl -X DELETE -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/application/c4ea6c00-d0b4-4d75-9e7a-e9dd04319586"
api_instance = nucleus_api.UtilsApi(nucleus_api.ApiClient(configuration))
# #Delete a Application
app1_id = 'd6a3cd18-4730-478b-8523-4d102c2ddee0'

try:
    api_instance.delete_application_using_delete(app1_id)
except ApiException as e:
    print("Exception when calling delete_application_using_delete: %s\n" % e)
UtilsApi apiInstance = new UtilsApi();
        //Delete a Application
        try {
            Application deleteresponse = apiInstance.deleteApplicationUsingDelete(UUID.fromString("d6a3cd18-4730-478b-8523-4d102c2ddee0"));
            System.out.println(deleteresponse);
        } catch (ApiException e) {
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\UtilsApi(
    new GuzzleHttp\Client(),
    $config);
//Delete Application
$application_did = "d6a3cd18-4730-478b-8523-4d102c2ddee0"; // string | UUID account_id

try {
    $apiInstance->deleteApplicationUsingDelete($application_did);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->deleteApplicationUsingDelete: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::UtilsApi.new

#Delete Application
application1_id = '420a049c-4a2d-4bb4-a134-074557aa03e4'
begin
  result = api_instance.delete_application_using_delete(application1_id)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->delete_application_using_delete: #{e}"
end
var apiInstance = new HydrogenNucleusApi.UtilsApi();
// // // // // //Delete a Application
var applicationidd = "942c59d0-43f1-4bbf-a89c-0dc27df60191";


var deleteapplication = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully.');
    }
};
apiInstance.deleteApplicationUsingDelete(applicationidd, deleteapplication)

Response (204 No Content)

Permanently delete an application for your firm. The application_id must be provided. To obtain the appropriate application_id, use the GET /application endpoint to view all of the applications for your firm. This deletes the application_id and the details for the application record.

HTTP REQUEST

DELETE /application/{application_id}

Audit Log

The Audit Log service allows users to cache the results of simulations for better performance and increased consistency. The following Proton services have a flag create_log that automates the storage of a log through this endpoint:

  1. Goals
    a. Accumulation Goal Allocation
    b. Accumulation Goal Recommendation
    c. Accumulation Goal Status
    d. Decumulation Goal Allocation
    e. Decumulation Goal Recommendation
    f. Decumulation Goal Status
  2. Simulations
    a. Event Study
    b. Model Backtest
    c. Monte Carlo
    d. Portfolio What-If
    e. Savings Calculator
    f. Scenario Analysis
    g. Sensitivity Analysis
    h. Variable Annuity
  3. Portfolio Construction
    a. Diversification Score
    b. Portfolio Optimization Score
  4. Personal Financial Management
    a. Financial Picture
Field Type Description
id UUID The unique id of this audit log record
request_url string URL of the service that is stored
request longtext Request body of the service that is stored
response longtext Response body of the service that is stored
client_ids array The ids of the clients which belong to this log
account_ids array The ids of the accounts which belong to this log
goal_ids array The ids of the goals which belong to this log
allocation_ids array The ids of the allocations which belong to this log
model_ids array The ids of the models which belong to this log
portfolio_ids array The ids of the portfolios which belong to this log
security_ids array The ids of the securities which belong to this log
aggregation_account_ids array The ids of the aggregation accounts which belong to this log
metadata map Custom information associated with the audit log in the format key:value
See Metadata
secondary_id string Alternate id that can be used to identify the object such as an internal id
create_date timestamp Timestamp for the date and time that the log was created
update_date timestamp Timestamp for the date and time that the log was last updated

List all audit logs

Example Request

curl -X GET -H "Authorization: Bearer <access_token>" \
  "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/audit_log"
api_instance = nucleus_api.UtilsApi(nucleus_api.ApiClient(configuration))
# List all AuditLog
try:
    api_response = api_instance.get_audit_log_all_using_get()
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_audit_log_all_using_get: %s\n" % e)
UtilsApi apiInstance = new UtilsApi();
////        //List all AuditLog
//        try {
//            PageAuditLog List = apiInstance.getAuditLogAllUsingGet(true, null, null, 0, 10);
//            System.out.println(List);
//        } catch (ApiException e) {
//            System.err.println("Exception when calling getAuditLogAllUsingGet");
//            e.printStackTrace();
//        }
$apiInstance = new com\hydrogen\nucleus\Api\UtilsApi(
    new GuzzleHttp\Client(),
    $config);
//List All AuditLogs
$ascending = false; // bool | ascending
$filter = null; // string | filter
$order_by = null; // string | order_by
$page = 0; // int | page
$size = 10; // int | size

try {
    $auditloglist = $apiInstance->getAuditLogAllUsingGet($ascending, $filter, $order_by, $page, $size);
    print_r($auditloglist);
} catch (Exception $e) {
    echo 'Exception when calling AuditLogApi->getAuditLogAllUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::UtilsApi.new

#List all AuditLog
opts = {
  ascending: false, # BOOLEAN | ascending
  filter: null, # String | filter
  order_by: null, # String | order_by
  page: 0, # Integer | page
  size: 25 # Integer | size
}

begin
  auditloglist = api_instance.get_audit_log_all_using_get(opts)
  p auditloglist
rescue NucleusApi::ApiError => e
  puts "Exception when calling AuditLogApi->get_audit_log_all_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.UtilsApi();
//List all Audits

var opts = {
    'ascending': false, // Boolean | ascending
    // 'filter': "", // String | filter
    'orderBy': "update_date", // String | order_by
    'page': 0, // Number | page
    'size': 25 // Number | size
};

var auditlist = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.getAuditLogAllUsingGet(opts, auditlist)

Example Response

{
  "content": [
      {
        "id": "a7a6446d-67dc-43a3-b065-2773461466e3",
        "request_url": "http://api.hydrogenplatform.com/savings_calculator",
        "request": "{'account_ids': ['0cf44916-2b48-4bc4-afea-ef448314a07b', 'e517f0cf-6cad-437e-a442-e482049ad29c'], 'horizon': 5, 'return_schedule': [0.02, 0.025, 0.025, 0.025, 0.03], 'horizon_frequency_interval': 'year', 'deposit_schedule': [{'deposit_amount': 100, 'deposit_frequency_interval': 'month', 'deposit_duration': 120, 'adjust_deposit_for_inflation': True}, {'deposit_amount': 2000, 'deposit_frequency_interval': 'year', 'deposit_duration': 10, 'adjust_deposit_for_inflation': True}], 'tax_rate': 0.33, 'inflation_rate': 0.02, 'create_log': True}",
        "response": "{'ending_balance': 26292.0, 'return_details': {0: {'period_earnings': 0.0, 'period_contribution': 0.0, 'period_withdrawal': 0.0, 'cumulative_earnings': 0.0, 'cumulative_contributions': 0.0, 'cumulative_withdrawals': 0.0, 'ending_balance': 8000.0}, 1: {'period_earnings': 107.2, 'period_contribution': 3264.0, 'period_withdrawal': 0.0, 'cumulative_earnings': 107.2, 'cumulative_contributions': 3264.0, 'cumulative_withdrawals': 0.0, 'ending_balance': 11371.2}, 2: {'period_earnings': 190.47, 'period_contribution': 3329.28, 'period_withdrawal': 0.0, 'cumulative_earnings': 297.67, 'cumulative_contributions': 6593.28, 'cumulative_withdrawals': 0.0, 'ending_balance': 14890.95}, 3: {'period_earnings': 249.42, 'period_contribution': 3395.87, 'period_withdrawal': 0.0, 'cumulative_earnings': 547.09, 'cumulative_contributions': 9989.15, 'cumulative_withdrawals': 0.0, 'ending_balance': 18536.24}, 4: {'period_earnings': 310.48, 'period_contribution': 3463.78, 'period_withdrawal': 0.0, 'cumulative_earnings': 857.57, 'cumulative_contributions': 13452.93, 'cumulative_withdrawals': 0.0, 'ending_balance': 22310.5}, 5: {'period_earnings': 448.44, 'period_contribution': 3533.06, 'period_withdrawal': 0.0, 'cumulative_earnings': 1306.01, 'cumulative_contributions': 16985.99, 'cumulative_withdrawals': 0.0, 'ending_balance': 26292.0}}}",
        "client_ids": [],
        "account_ids": [
            "e517f0cf-6cad-437e-a442-e482049ad29c",
            "0cf44916-2b48-4bc4-afea-ef448314a07b"
        ],
        "goal_ids": [],
        "allocation_ids": [],
        "portfolio_ids": [],
        "security_ids": [],
        "aggregation_account_ids": [],
        "model_ids": [],
        "metadata": {},
        "secondary_id": null,
        "create_date": "2019-12-30T17:31:26.000+0000",
        "update_date": "2019-12-30T17:31:26.000+0000"
      }
    ],
    "total_elements": 1,
    "last": true,
    "total_pages": 1,
    "first": true,
    "sort": [
        {
            "direction": "DESC",
            "property": "updateDate",
            "ignore_case": false,
            "null_handling": "NATIVE",
            "descending": true,
            "ascending": false
        }
    ],
    "number_of_elements": 1,
    "size": 25,
    "number": 0
}

Get all audit logs that have been saved for your firm.

HTTP REQUEST

GET /audit_log

Create an audit log

Example Request

curl -X POST -H "Authorization: Bearer <access_token>" \
    -H "Content-Type: application/json" \
    -d "{
          'request_url': 'http://api.hydrogenplatform.com/savings_calculator',
          'request': '{'account_ids': ['0cf44916-2b48-4bc4-afea-ef448314a07b', 'e517f0cf-6cad-437e-a442-e482049ad29c'], 'horizon': 5, 'return_schedule': [0.02, 0.025, 0.025, 0.025, 0.03], 'horizon_frequency_interval': 'year', 'deposit_schedule': [{'deposit_amount': 100, 'deposit_frequency_interval': 'month', 'deposit_duration': 120, 'adjust_deposit_for_inflation': True}, {'deposit_amount': 2000, 'deposit_frequency_interval': 'year', 'deposit_duration': 10, 'adjust_deposit_for_inflation': True}], 'tax_rate': 0.33, 'inflation_rate': 0.02, 'create_log': True}",
          "response": "{'ending_balance': 26292.0, 'return_details': {0: {'period_earnings': 0.0, 'period_contribution': 0.0, 'period_withdrawal': 0.0, 'cumulative_earnings': 0.0, 'cumulative_contributions': 0.0, 'cumulative_withdrawals': 0.0, 'ending_balance': 8000.0}, 1: {'period_earnings': 107.2, 'period_contribution': 3264.0, 'period_withdrawal': 0.0, 'cumulative_earnings': 107.2, 'cumulative_contributions': 3264.0, 'cumulative_withdrawals': 0.0, 'ending_balance': 11371.2}, 2: {'period_earnings': 190.47, 'period_contribution': 3329.28, 'period_withdrawal': 0.0, 'cumulative_earnings': 297.67, 'cumulative_contributions': 6593.28, 'cumulative_withdrawals': 0.0, 'ending_balance': 14890.95}, 3: {'period_earnings': 249.42, 'period_contribution': 3395.87, 'period_withdrawal': 0.0, 'cumulative_earnings': 547.09, 'cumulative_contributions': 9989.15, 'cumulative_withdrawals': 0.0, 'ending_balance': 18536.24}, 4: {'period_earnings': 310.48, 'period_contribution': 3463.78, 'period_withdrawal': 0.0, 'cumulative_earnings': 857.57, 'cumulative_contributions': 13452.93, 'cumulative_withdrawals': 0.0, 'ending_balance': 22310.5}, 5: {'period_earnings': 448.44, 'period_contribution': 3533.06, 'period_withdrawal': 0.0, 'cumulative_earnings': 1306.01, 'cumulative_contributions': 16985.99, 'cumulative_withdrawals': 0.0, 'ending_balance': 26292.0}}}''
        }" "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/audit_log"
api_instance = nucleus_api.UtilsApi(nucleus_api.ApiClient(configuration))

#Create AuditLog
audit = nucleus_api.AuditLog(request="A one", request_url="http://qa.hydrogenplatform.com/savings_calculator", response="Response")
try:
    api_response = api_instance.create_audit_log_using_post(audit)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling create_audit_log_using_post: %s\n" % e)
UtilsApi apiInstance = new UtilsApi();
        //        //Create An Auditlog

        AuditLog log = new AuditLog();
        log.setRequestUrl("http://qa.hydrogenplatform.com/savings_calculator");
        log.setRequest("Abc");
        log.setResponse("One1");

                try {
            AuditLog result = apiInstance.createAuditLogUsingPost(log);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling createAuditLogUsingPost");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\UtilsApi(
    new GuzzleHttp\Client(),
    $config);

//Create Audit Log
$auditlog = new \com\hydrogen\nucleus\Model\AuditLog();


try {
    $auditlog->setRequestUrl("http://qa.hydrogenplatform.com/savings_calculator");
    $auditlog->setRequest("One");
    $auditlog->setResponse("New");
    $result = $apiInstance->createAuditLogUsingPost($auditlog);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->createAuditLogUsingPost: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::UtilsApi.new
#Create Audit Log
auditlog = NucleusApi::AuditLog.new

begin
  auditlog.request_url  = "http://qa.hydrogenplatform.com/savings_calculator"
  auditlog.request = "New"
  auditlog.response = "One"
  result = api_instance.create_audit_log_using_post(auditlog)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->create_audit_log_using_post: #{e}"
end
var apiInstance = new HydrogenNucleusApi.UtilsApi();
//Create a Audit log
var audit = new HydrogenNucleusApi.AuditLog();
audit.request_url = "http://qa.hydrogenplatform.com/savings_calculator";
audit.request = "ABC";
audit.response = "ABC";




var newauditlog = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.createAuditLogUsingPost(audit, newauditlog)

Example Response

{
  "id": "a7a6446d-67dc-43a3-b065-2773461466e3",
  "request_url": "http://api.hydrogenplatform.com/savings_calculator",
  "request": "{'account_ids': ['0cf44916-2b48-4bc4-afea-ef448314a07b', 'e517f0cf-6cad-437e-a442-e482049ad29c'], 'horizon': 5, 'return_schedule': [0.02, 0.025, 0.025, 0.025, 0.03], 'horizon_frequency_interval': 'year', 'deposit_schedule': [{'deposit_amount': 100, 'deposit_frequency_interval': 'month', 'deposit_duration': 120, 'adjust_deposit_for_inflation': True}, {'deposit_amount': 2000, 'deposit_frequency_interval': 'year', 'deposit_duration': 10, 'adjust_deposit_for_inflation': True}], 'tax_rate': 0.33, 'inflation_rate': 0.02, 'create_log': True}",
  "response": "{'ending_balance': 26292.0, 'return_details': {0: {'period_earnings': 0.0, 'period_contribution': 0.0, 'period_withdrawal': 0.0, 'cumulative_earnings': 0.0, 'cumulative_contributions': 0.0, 'cumulative_withdrawals': 0.0, 'ending_balance': 8000.0}, 1: {'period_earnings': 107.2, 'period_contribution': 3264.0, 'period_withdrawal': 0.0, 'cumulative_earnings': 107.2, 'cumulative_contributions': 3264.0, 'cumulative_withdrawals': 0.0, 'ending_balance': 11371.2}, 2: {'period_earnings': 190.47, 'period_contribution': 3329.28, 'period_withdrawal': 0.0, 'cumulative_earnings': 297.67, 'cumulative_contributions': 6593.28, 'cumulative_withdrawals': 0.0, 'ending_balance': 14890.95}, 3: {'period_earnings': 249.42, 'period_contribution': 3395.87, 'period_withdrawal': 0.0, 'cumulative_earnings': 547.09, 'cumulative_contributions': 9989.15, 'cumulative_withdrawals': 0.0, 'ending_balance': 18536.24}, 4: {'period_earnings': 310.48, 'period_contribution': 3463.78, 'period_withdrawal': 0.0, 'cumulative_earnings': 857.57, 'cumulative_contributions': 13452.93, 'cumulative_withdrawals': 0.0, 'ending_balance': 22310.5}, 5: {'period_earnings': 448.44, 'period_contribution': 3533.06, 'period_withdrawal': 0.0, 'cumulative_earnings': 1306.01, 'cumulative_contributions': 16985.99, 'cumulative_withdrawals': 0.0, 'ending_balance': 26292.0}}}",
  "client_ids": [],
  "account_ids": [],
  "goal_ids": [],
  "allocation_ids": [],
  "portfolio_ids": [],
  "security_ids": [],
  "aggregation_account_ids": [],
  "model_ids": [],
  "metadata": {},
  "secondary_id": null,
  "create_date": "2019-12-30T17:31:26.000+0000",
  "update_date": "2019-12-30T17:31:26.000+0000"
}

Create a log to store the results of a simulation. You must provide the request_url and response. If you are caching the results of a Proton service, you can automate this by passing in the flag create_log to the Proton request.

HTTP REQUEST

POST /audit_log

ARGUMENTS

Field Type Required Description
request_url string required URL of the service that is stored
response longtext required Response body of the service that is stored
request longtext optional Request body of the service that is stored
client_ids array optional The ids of the clients which belong to this log
account_ids array optional The ids of the accounts which belong to this log
goal_ids array optional The ids of the goals which belong to this log
allocation_ids array optional The ids of the allocations which belong to this log
model_ids array optional The ids of the models which belong to this log
portfolio_ids array optional The ids of the portfolios which belong to this log
security_ids array optional The ids of the securities which belong to this log
aggregation_account_ids array optional The ids of the aggregation accounts which belong to this log
metadata map optional Custom information associated with the audit log in the format key:value
See Metadata

Retrieve an audit log

Example Request

curl -X GET -H "Authorization: Bearer <access_token>" \
  "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/audit_log/a7a6446d-67dc-43a3-b065-2773461466e3"
api_instance = nucleus_api.UtilsApi(nucleus_api.ApiClient(configuration))
# Retrieve an AuditLog
try:
    api_response = api_instance.get_audit_log_using_get("b5567541-0e65-47ec-bdaf-1d0a6fcbb0b9")
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_audit_log_using_get: %s\n" % e)
UtilsApi apiInstance = new UtilsApi();
        //Retrieve an Audit Log
                try {
            AuditLog responseAuditLog = apiInstance.getAuditLogUsingGet(UUID.fromString("8d4032e7-226c-48ce-bafd-1fa624e60898"));
            System.out.println(responseAuditLog);
        } catch (ApiException e) {
            System.err.println("Exception when calling getAuditLogUsingGet");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\UtilsApi(
    new GuzzleHttp\Client(),
    $config);

//Retrieve an Auditlog
$audit_log_id = "8d4032e7-226c-48ce-bafd-1fa624e60898"; // string | UUID audit_log_id

try {
    $auditlog = $apiInstance->getAuditLogUsingGet($audit_log_id);
    print_r($auditlog);
} catch (Exception $e) {
    echo 'Exception when calling AuditLogApi->getAuditLogUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::UtilsApi.new
# Retrieve an AuditLog
audit_log_id = '8d4032e7-226c-48ce-bafd-1fa624e60898' # String | UUID audit_log_id


begin
  #Retrieve a audit log
  auditlog = api_instance.get_audit_log_using_get(audit_log_id)
  p auditlog
rescue NucleusApi::ApiError => e
  puts "Exception when calling AuditLogApi->get_audit_log_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.UtilsApi();
//Retrieve an AuditLog
var auditLogId = "8d4032e7-226c-48ce-bafd-1fa624e60898";

var auditlog = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' + data);
    }
};

apiInstance.getAuditLogUsingGet(auditLogId, auditlog)

Example Response

{
  "id": "a7a6446d-67dc-43a3-b065-2773461466e3",
  "request_url": "http://api.hydrogenplatform.com/savings_calculator",
  "request": "{'account_ids': ['0cf44916-2b48-4bc4-afea-ef448314a07b', 'e517f0cf-6cad-437e-a442-e482049ad29c'], 'horizon': 5, 'return_schedule': [0.02, 0.025, 0.025, 0.025, 0.03], 'horizon_frequency_interval': 'year', 'deposit_schedule': [{'deposit_amount': 100, 'deposit_frequency_interval': 'month', 'deposit_duration': 120, 'adjust_deposit_for_inflation': True}, {'deposit_amount': 2000, 'deposit_frequency_interval': 'year', 'deposit_duration': 10, 'adjust_deposit_for_inflation': True}], 'tax_rate': 0.33, 'inflation_rate': 0.02, 'create_log': True}",
  "response": "{'ending_balance': 26292.0, 'return_details': {0: {'period_earnings': 0.0, 'period_contribution': 0.0, 'period_withdrawal': 0.0, 'cumulative_earnings': 0.0, 'cumulative_contributions': 0.0, 'cumulative_withdrawals': 0.0, 'ending_balance': 8000.0}, 1: {'period_earnings': 107.2, 'period_contribution': 3264.0, 'period_withdrawal': 0.0, 'cumulative_earnings': 107.2, 'cumulative_contributions': 3264.0, 'cumulative_withdrawals': 0.0, 'ending_balance': 11371.2}, 2: {'period_earnings': 190.47, 'period_contribution': 3329.28, 'period_withdrawal': 0.0, 'cumulative_earnings': 297.67, 'cumulative_contributions': 6593.28, 'cumulative_withdrawals': 0.0, 'ending_balance': 14890.95}, 3: {'period_earnings': 249.42, 'period_contribution': 3395.87, 'period_withdrawal': 0.0, 'cumulative_earnings': 547.09, 'cumulative_contributions': 9989.15, 'cumulative_withdrawals': 0.0, 'ending_balance': 18536.24}, 4: {'period_earnings': 310.48, 'period_contribution': 3463.78, 'period_withdrawal': 0.0, 'cumulative_earnings': 857.57, 'cumulative_contributions': 13452.93, 'cumulative_withdrawals': 0.0, 'ending_balance': 22310.5}, 5: {'period_earnings': 448.44, 'period_contribution': 3533.06, 'period_withdrawal': 0.0, 'cumulative_earnings': 1306.01, 'cumulative_contributions': 16985.99, 'cumulative_withdrawals': 0.0, 'ending_balance': 26292.0}}}",
  "client_ids": [],
  "account_ids": [],
  "goal_ids": [],
  "allocation_ids": [],
  "portfolio_ids": [],
  "security_ids": [],
  "aggregation_account_ids": [],
  "model_ids": [],
  "metadata": {},
  "secondary_id": null,
  "create_date": "2019-12-30T17:31:26.000+0000",
  "update_date": "2019-12-30T17:31:26.000+0000"
}

Retrieve an audit log. The audit_log_id must be provided. The endpoint returns the audit_log_id and the details for the log specified.

HTTP REQUEST

GET /audit_log/{audit_log_id}

Notification

Notification Management

Create notifications that can be subscribed to by users of your application(s).

Field Type Description
id UUID The id of the notification
name string Name of the notification
notification_type string Type of notification. Value may be in_app, push_mobile, push_web, email, sms, phone
threshold_type string Type of threshold for the notification. Value may be percentage or monetary
frequency_unit array Available frequencies that may be selected for the notification. Value may be one_time, daily, weekly, monthly, quarterly, annually
description string Description for the notification
feature_id UUID ID of the Feature this notification belongs to if you want to link to it within an app
application_id UUID ID of the Application this notification belongs to
is_active boolean Indicates if the notification is active. Defaults to true which indicates that the notification is active
metadata map Custom information associated with the notification in the format key:value
See Metadata
secondary_id string Alternate id that can be used to identify the object such as an internal id
create_date timestamp Timestamp for the date and time that the notification was created
update_date timestamp Timestamp for the date and time that the notification was last updated

List all notifications

Example Request

curl -X GET -H "Authorization: Bearer <access_token>" \
  "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/notification"
api_instance = nucleus_api.UtilsApi(nucleus_api.ApiClient(configuration))
# List all Notification
try:
    api_response = api_instance.get_notification_all_using_get()
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_notification_all_using_get: %s\n" % e)
UtilsApi apiInstance = new UtilsApi();
        //List all Notification
        try {
            PageNotification List = apiInstance.getNotificationAllUsingGet(true, null, null, 0, 10);
            System.out.println(List);
        } catch (ApiException e) {
            System.err.println("Exception when calling getNotificationAllUsingGet");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\UtilsApi(
    new GuzzleHttp\Client(),
    $config);

//List all Notifications
$ascending = false; // bool | ascending
$filter = null; // string | filter
$order_by = null; // string | order_by
$page = 0; // int | page
$size = 10; // int | size

try {
    $notificationlist = $apiInstance->getNotificationAllUsingGet($ascending, $filter, $order_by, $page, $size);
    print_r($notificationlist);
} catch (Exception $e) {
    echo 'Exception when calling NotificationApi->getNotificationAllUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::UtilsApi.new
#List all Notifications
opts = {
  ascending: false, # BOOLEAN | ascending
  filter: null, # String | filter
  order_by: null, # String | order_by
  page: 0, # Integer | page
  size: 25 # Integer | size
}

begin
  notificationlist = api_instance.get_notification_all_using_get(opts)
  p notificationlist
rescue NucleusApi::ApiError => e
  puts "Exception when calling NotificationApi->get_notification_all_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.UtilsApi();
//List all Notification
var opts = {
    'ascending': false, // Boolean | ascending
    // 'filter': "", // String | filter
    'orderBy': "update_date", // String | order_by
    'page': 0, // Number | page
    'size': 25 // Number | size
};

var notificationlist = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.getNotificationAllUsingGet(opts, notificationlist)

Example Response

{
    "content": [
        {
            "id": "36f9cb66-88a9-4a1f-a305-338a0f0e0a57",
            "create_date": "2019-08-12T18:47:38.000+0000",
            "update_date": "2019-08-13T09:00:00.000+0000",
            "name": "Company newsletter",
            "notification_type": "email",
            "threshold_type": null,
            "frequency_unit": ["monthly"],
            "description": null,
            "feature_id": null,
            "application_id": null,
            "is_active": true,
            "metadata": {},
            "secondary_id": null
        },
        {
            "id": "c4ea6c00-d0b4-4d75-9e7a-e9dd04319586",
            "create_date": "2019-09-12T18:46:12.000+0000",
            "update_date": "2019-09-13T09:00:00.000+0000",
            "name": "New trade alert",
            "notification_type": "push_mobile",
            "threshold_type": null,
            "frequency_unit": [],
            "description": null,
            "feature_id": null,
            "application_id": null,
            "is_active": true,
            "metadata": {},
            "secondary_id": null
        }
    ],
    "total_pages": 1,
    "total_elements": 2,
    "last": true,
    "first": true,
    "sort": [
        {
            "direction": "DESC",
            "property": "updateDate",
            "ignore_case": false,
            "null_handling": "NATIVE",
            "descending": true,
            "ascending": false
        }
    ],
    "number_of_elements": 2,
    "size": 25,
    "number": 0
}

Get all the notifications defined for your firm.

HTTP REQUEST

GET /notification

Create a notification

Example Request

curl -X POST -H "Authorization: Bearer <access_token>" \
    -H "Content-Type: application/json" \
    -d '{
          "name": "Company newsletter",
          "notification_type": "email"
        }' "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/notification"
api_instance = nucleus_api.UtilsApi(nucleus_api.ApiClient(configuration))
# #Create Notification
notification = nucleus_api.Notification(name="New One", notification_type="email")
try:
    api_response = api_instance.create_notification_using_post(notification)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling create_notification_using_post: %s\n" % e)
UtilsApi apiInstance = new UtilsApi();
        //Create a Notification
        Notification notification = new Notification();
        notification.setName("New Notification");
        notification.setNotificationType("email");

        try {
            Notification result = apiInstance.createNotificationUsingPost(notification);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling createNotificationUsingPost");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\UtilsApi(
    new GuzzleHttp\Client(),
    $config);

//Create Notification
$notification = new \com\hydrogen\nucleus\Model\Notification();


try {
    $notification->setName("New");
    $notification->setNotificationType("email");
    $result = $apiInstance->createNotificationUsingPost($notification);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->createNotificationUsingPost: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::UtilsApi.new
#Create Notification
notification = NucleusApi::Notification.new

begin
  notification.name = "New One"
  notification.notification_type = "email"
  result = api_instance.create_notification_using_post(notification)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->create_notification_using_post: #{e}"
end
var apiInstance = new HydrogenNucleusApi.UtilsApi();
//Create a Notification
var notification = new HydrogenNucleusApi.Notification();
notification.name = "New";
notification.notification_type = "email";

var newnotification = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.createNotificationUsingPost(notification, newnotification)

Example Response

{
  "id": "36f9cb66-88a9-4a1f-a305-338a0f0e0a57",
  "create_date": "2019-08-12T18:47:38.000+0000",
  "update_date": "2019-08-13T09:00:00.000+0000",
  "name": "Company newsletter",
  "notification_type": "email",
  "threshold_type": null,
  "frequency_unit": ["monthly"],
  "description": null,
  "feature_id": null,
  "application_id": null,
  "is_active": true,
  "metadata": {},
  "secondary_id": null
}

Create a notification for your firm. You must enter a name and notification_type for the notification. The endpoint returns a notification_id used to identify and manage the notification.

HTTP REQUEST

POST /notification

ARGUMENTS

Parameter Type Required Description
name string required Name of the notification
notification_type string required Type of notification. Value may be in_app, push_mobile, push_web, email, sms, phone
threshold_type string optional Type of threshold for the notification. Value may be percentage or monetary
frequency_unit array optional Available frequencies that may be selected for the notification. Value may be one_time, daily, weekly, monthly, quarterly, annually
description string optional Description for the notification
feature_id UUID optional ID of the Feature this notification belongs to if you want to link to it within an app
application_id UUID optional ID of the Application this notification belongs to
is_active boolean optional Indicates if the notification is active. Defaults to true which indicates that the notification is active
metadata map optional Custom information associated with the notification in the format key:value
See Metadata
secondary_id string optional Alternate id that can be used to identify the object such as an internal id

Retrieve a notification

Example Request

curl -X GET -H "Authorization: Bearer <access_token>" \
  "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/notification/c4ea6c00-d0b4-4d75-9e7a-e9dd04319586"
api_instance = nucleus_api.UtilsApi(nucleus_api.ApiClient(configuration))
# Retrieve A Notification
try:
    api_response = api_instance.get_notification_using_get("4c6b85cd-cd27-4340-9211-0c9046ce04f1")
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_notification_using_get: %s\n" % e)
UtilsApi apiInstance = new UtilsApi();
//        //Retrieve a Notification
        try {
            Notification responseNotification = apiInstance.getNotificationUsingGet(UUID.fromString("c3f37629-9129-4771-81a8-eaaf3376f9e4"));
            System.out.println(responseNotification);
        } catch (ApiException e) {
            System.err.println("Exception when calling getNotificationUsingGet");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\UtilsApi(
    new GuzzleHttp\Client(),
    $config);

//Retrieve an Notification
$notification_id = "c3f37629-9129-4771-81a8-eaaf3376f9e4"; // string | notification_id

try {
    $notification = $apiInstance->getNotificationUsingGet($notification_id);
    print_r($notification);
} catch (Exception $e) {
    echo 'Exception when calling NotificationApi->getNotificationUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::UtilsApi.new
#Retreieve a Notification
notification_id = 'c3f37629-9129-4771-81a8-eaaf3376f9e4' # String | notification_id


begin
  notification = api_instance.get_notification_using_get(notification_id)
  p notification
rescue NucleusApi::ApiError => e
  puts "Exception when calling NotificationApi->get_notification_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.UtilsApi();
//Retrieve a Notification

var notificationID = "c3f37629-9129-4771-81a8-eaaf3376f9e4";

var opts = {
    'currencyConversion': null, // String | USD
};

var notification = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.getNotificationUsingGet(notificationID, notification)

Example Response

{
  "id": "c4ea6c00-d0b4-4d75-9e7a-e9dd04319586",
  "create_date": "2019-09-12T18:46:12.000+0000",
  "update_date": "2019-09-13T09:00:00.000+0000",
  "name": "New trade alert",
  "notification_type": "push_mobile",
  "threshold_type": null,
  "frequency_unit": [],
  "description": null,
  "feature_id": null,
  "application_id": null,
  "is_active": true,
  "metadata": {},
  "secondary_id": null
}

Retrieve a notification for your firm. The notification_id must be provided. The endpoint returns the notification_id and the details for the notification specified.

HTTP REQUEST

GET /notification/{notification_id}

Update a notification

Example Request

curl -X PUT -H "Authorization: Bearer <access_token>" \
   -H "Content-Type: application/json" \
   -d '{
          "name": "Trade alert"
        }' "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/notification/c4ea6c00-d0b4-4d75-9e7a-e9dd04319586"
api_instance = nucleus_api.UtilsApi(nucleus_api.ApiClient(configuration))
# #Update Notificatiion
notification_update = {'description': 'New'}
notification_id = '3e491f50-b2dc-4c8a-bb61-463cbede9171'
try:
    api_response = api_instance.update_notification_using_put(notification_update, notification_id)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling update_notification_using_put: %s\n" % e)
UtilsApi apiInstance = new UtilsApi();
//          //Update a Notification
        Map map = new HashMap();
        map.put("description", "Notify by mail");

        try {
            Notification response = apiInstance.updateNotificationUsingPut(map, UUID.fromString("fa5036a1-abea-4f04-b627-08d5dff2da67"));
            System.out.println(response);
        } catch (ApiException e) {
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\UtilsApi(
    new GuzzleHttp\Client(),
    $config);

//Update Notification
$notification_update = new stdClass();
$notification_id = "883e6e1d-bb11-4cad-a230-72cae0bdec5d";

try {
    $notification_update->notification_type = "email";
    $result = $apiInstance->updateNotificationUsingPut($notification_update, $notification_id);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->updateNotificationUsingPut: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::UtilsApi.new
#Update Notification
notification_update = {"name" => 'ABC'}
notificaion_id = 'fa5036a1-abea-4f04-b627-08d5dff2da67'
begin
  result = api_instance.update_notification_using_put(notification_update, notificaion_id)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->update_notification_using_put: #{e}"
end
var apiInstance = new HydrogenNucleusApi.UtilsApi();
//Update FeatureTrack
var apiInstance = new HydrogenNucleusApi.UtilsApi();
var callback = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
var notificationupdate = new HydrogenNucleusApi.Notification();
var notificationid = '40b64b39-10da-4853-9e46-0606437d10fe';

notificationupdate.name = "New Name";
apiInstance.updateNotificationUsingPut(notificationupdate, notificationid, callback)

Example Response

{
  "id": "c4ea6c00-d0b4-4d75-9e7a-e9dd04319586",
  "create_date": "2019-09-12T18:46:12.000+0000",
  "update_date": "2019-09-13T09:00:00.000+0000",
  "name": "Trade alert",
  "notification_type": "push_mobile",
  "threshold_type": null,
  "frequency_unit": [],
  "description": null,
  "feature_id": null,
  "application_id": null,
  "is_active": true,
  "metadata": {},
  "secondary_id": null
}

Update a notification for your firm. The notification_id must be provided. To obtain the appropriate notification_id, use the GET /notification endpoint to view all of the notifications for your firm and their current information. The details to be updated and the details to be maintained must also be provided. The endpoint returns the notification_id and the details for the notification.

HTTP REQUEST

PUT /notification/{notification_id}

Delete a notification

Example Request

curl -X DELETE -H "Authorization: Bearer <access_token>" \
  "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/notification/c4ea6c00-d0b4-4d75-9e7a-e9dd04319586"
api_instance = nucleus_api.UtilsApi(nucleus_api.ApiClient(configuration))

//Delete Notification
$notification_did = "6c6d8f6d-b2f1-4785-8fa3-3413aafe19c3"; // string | UUID account_id

try {
    $apiInstance->deleteNotificationUsingDelete($notification_did);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->deleteNotificationUsingDelete: ', $e->getMessage(), PHP_EOL;
}
UtilsApi apiInstance = new UtilsApi();
//        //Delete a Notification
//        try {
//            Notification deleteresponse = apiInstance.deleteNotificationUsingDelete(UUID.fromString("9df8ba9c-cafa-4a18-9fe9-6a283be97430"));
//            System.out.println(deleteresponse);
//        } catch (ApiException e) {
//            e.printStackTrace();
//        }
$apiInstance = new com\hydrogen\nucleus\Api\UtilsApi(
    new GuzzleHttp\Client(),
    $config);
//Delete Notification
$notification_did = "6c6d8f6d-b2f1-4785-8fa3-3413aafe19c3"; // string | UUID account_id

try {
    $apiInstance->deleteNotificationUsingDelete($notification_did);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->deleteNotificationUsingDelete: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::UtilsApi.new
#Delete Notification
notification1_id = '883e6e1d-bb11-4cad-a230-72cae0bdec5d'
begin
  result = api_instance.delete_notification_using_delete(notification1_id)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->delete_notification_using_delete: #{e}"
end
var apiInstance = new HydrogenNucleusApi.UtilsApi();
// // // //Delete a Notification
var notificationidd = "fa5036a1-abea-4f04-b627-08d5dff2da67";


var deletenotification = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully.');
    }
};
apiInstance.deleteNotificationUsingDelete(notificationidd, deletenotification)

Response (204 No Content)

Permanently delete a notification for your firm. The notification_id must be provided. To obtain the appropriate notification_id, use the GET /notification endpoint to view all of the notifications for your firm. This deletes the notification_id and the details for the notification record.

HTTP REQUEST

DELETE /notification/{notification_id}

Notification Setting

Store notifications settings for users in your application(s).

Field Type Description
id UUID The id of the notification
client_id UUID ID of the Client this setting belongs to
notification_id UUID ID of the Notification this setting belongs to
threshold_value double Value of the threshold set by the user for the notification to be triggered. If threshold_type of the notification = “percentage” then enter the value as a whole number (e.g. 40% as 40)
frequency_unit string Frequency of the notification defined by the user. Value may be one_time, daily, weekly, monthly, quarterly, or annually
frequency integer Number of frequency_unit between each notification. For example, if the frequency_unit is weekly and the frequency is 2, this means the notification occurs every two weeks. Default is 1
last_run_date timestamp The last time a script was run to determine if the client should receive a notification
is_receive boolean Indicates if the user wishes to receive a notification. Defaults to true which indicates that the notification will be received
metadata map Custom information associated with the notification setting in the format key:value
See Metadata
secondary_id string Alternate id that can be used to identify the object such as an internal id
create_date timestamp Timestamp for the date and time that the notification setting was created
update_date timestamp Timestamp for the date and time that the notification setting was last updated

List all notification settings

Example Request

curl -X GET -H "Authorization: Bearer <access_token>" \
  "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/notification_setting"
api_instance = nucleus_api.UtilsApi(nucleus_api.ApiClient(configuration))
# List all NotificationSetting
try:
    api_response = api_instance.get_notification_setting_all_using_get()
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_notification_setting_all_using_get: %s\n" % e)
UtilsApi apiInstance = new UtilsApi();
        //List all NotificationSettings
        try {
            PageNotificationSetting List = apiInstance.getNotificationSettingAllUsingGet(true, null, null, 0, 10);
            System.out.println(List);
        } catch (ApiException e) {
            System.err.println("Exception when calling getNotificationSettingAllUsingGet");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\UtilsApi(
    new GuzzleHttp\Client(),
    $config);
//List all NotificationSettings
$ascending = false; // bool | ascending
$filter = null; // string | filter
$order_by = null; // string | order_by
$page = 0; // int | page
$size = 10; // int | size

try {
    $notificationsettinglist = $apiInstance->getNotificationSettingAllUsingGet($ascending, $filter, $order_by, $page, $size);
    print_r($notificationsettinglist);
} catch (Exception $e) {
    echo 'Exception when calling NotificationApi->getNotificationSettingAllUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::UtilsApi.new
#List all NotificationSetting
opts = {
  ascending: false, # BOOLEAN | ascending
  filter: null, # String | filter
  order_by: null, # String | order_by
  page: 0, # Integer | page
  size: 25 # Integer | size
}

begin
  settingslist = api_instance.get_notification_setting_all_using_get(opts)
  p settingslist
rescue NucleusApi::ApiError => e
  puts "Exception when calling NotificationApi->get_notification_setting_all_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.UtilsApi();
//List all Notification Settings
var opts = {
    'ascending': false, // Boolean | ascending
    // 'filter': "", // String | filter
    'orderBy': "update_date", // String | order_by
    'page': 0, // Number | page
    'size': 25 // Number | size
};

var notificationsettingslist = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.getNotificationSettingAllUsingGet(opts, notificationsettingslist)

Example Response

{
    "content": [
        {
            "id": "52u4rp55-44h6-2p4y-d193-119c1r5s7b78",
            "create_date": "2019-08-12T18:47:38.000+0000",
            "update_date": "2019-08-13T09:00:00.000+0000",
            "client_id": "46g4kw32-47g6-2v2r-m513-469ax6f2h6z23",
            "notification_id": "36f9cb66-88a9-4a1f-a305-338a0f0e0a57",
            "threshold_value": null,
            "frequency_unit": "one_time",
            "frequency": 1,
            "last_run_date": null,
            "is_receive": true,
            "metadata": {},
            "secondary_id": null
        },
        {
            "id": "21k5pe66-63f7-7j4h-w265-326b6s4n8b31",
            "create_date": "2019-09-12T18:46:12.000+0000",
            "update_date": "2019-09-13T09:00:00.000+0000",
            "client_id": "46g4kw32-47g6-2v2r-m513-469ax6f2h6z23",
            "notification_id": "c4ea6c00-d0b4-4d75-9e7a-e9dd04319586",
            "threshold_value": null,
            "frequency_unit": "one_time",
            "frequency": 1,
            "last_run_date": null,
            "is_receive": true,
            "metadata": {},
            "secondary_id": null
        }
    ],
    "total_pages": 1,
    "total_elements": 2,
    "last": true,
    "first": true,
    "sort": [
        {
            "direction": "DESC",
            "property": "updateDate",
            "ignore_case": false,
            "null_handling": "NATIVE",
            "descending": true,
            "ascending": false
        }
    ],
    "number_of_elements": 2,
    "size": 25,
    "number": 0
}

Get all the notification settings defined for client’s in your firm.

HTTP REQUEST

GET /notification_setting

Create a notification setting

Example Request

curl -X POST -H "Authorization: Bearer <access_token>" \
    -H "Content-Type: application/json" \
    -d '{
          "client_id": "46g4kw32-47g6-2v2r-m513-469ax6f2h6z23",
          "notification_id": "36f9cb66-88a9-4a1f-a305-338a0f0e0a57",
          "frequency_unit": "one_time",
          "frequency": 1,
          "is_receive": true
        }' "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/notification_setting"
api_instance = nucleus_api.UtilsApi(nucleus_api.ApiClient(configuration))
# #Create NotificationSetting
notification_setting = nucleus_api.NotificationSetting(client_id="9d567077-ed4f-4429-b991-7d9a124600f5", notification_id="d650da49-be07-4adc-965b-f9d1b137de0c")
try:
    api_response = api_instance.create_notification_setting_using_post(notification_setting)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling create_notification_setting_using_post: %s\n" % e)
UtilsApi apiInstance = new UtilsApi();
                 //Create a NotificationSetting
         NotificationSetting settingNotification = new NotificationSetting();
         settingNotification.setClientId(UUID.fromString("9d567077-ed4f-4429-b991-7d9a124600f5"));
         settingNotification.setNotificationId(UUID.fromString("d650da49-be07-4adc-965b-f9d1b137de0c"));


         try {
             NotificationSetting result = apiInstance.createNotificationSettingUsingPost(settingNotification);
             System.out.println(result);
         } catch (ApiException e) {
             System.err.println("Exception when calling createNotificationSettingUsingPost");
             e.printStackTrace();
         }
$apiInstance = new com\hydrogen\nucleus\Api\UtilsApi(
    new GuzzleHttp\Client(),
    $config);
//Create Notification Setting
$notification_setting = new \com\hydrogen\nucleus\Model\NotificationSetting();


try {
    $notification_setting->setClientId("9d567077-ed4f-4429-b991-7d9a124600f5");
    $notification_setting->setNotificationId("d650da49-be07-4adc-965b-f9d1b137de0c");
    $result = $apiInstance->createNotificationSettingUsingPost($notification_setting);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->createNotificationSettingUsingPost: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::UtilsApi.new
#Create Notification Setting
notification_setting = NucleusApi::NotificationSetting.new

begin
  notification_setting.client_id = "9d567077-ed4f-4429-b991-7d9a124600f5"
  notification_setting.notification_id = "d650da49-be07-4adc-965b-f9d1b137de0c"
  result = api_instance.create_notification_setting_using_post(notification_setting)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->create_notification_setting_using_post: #{e}"
end
var apiInstance = new HydrogenNucleusApi.UtilsApi();
//Create a Notification Setting
var notificationsetting = new HydrogenNucleusApi.NotificationSetting();
notificationsetting.client_id = '9d567077-ed4f-4429-b991-7d9a124600f5';
notificationsetting.notification_id = 'd650da49-be07-4adc-965b-f9d1b137de0c';

var newnotificationsetting = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.createNotificationSettingUsingPost(notificationsetting, newnotificationsetting)

Example Response

{
  "id": "099961da-7f41-4309-950f-2b51689a0033",
  "client_id": "46g4kw32-47g6-2v2r-m513-469ax6f2h6z23",
  "notification_id": "36f9cb66-88a9-4a1f-a305-338a0f0e0a57",
  "threshold_value": null,
  "frequency_unit": "one_time",
  "frequency": 1,
  "last_run_date": null,
  "is_receive": true,
  "metadata": {},
  "secondary_id": null
}

Create a notification setting for a client. You must enter a client_id and notification_id for the notification setting. The endpoint returns a notification_setting_id used to identify and manage the settings.

HTTP REQUEST

POST /notification_setting

ARGUMENTS

Parameter Type Required Description
client_id UUID required ID of the Client this setting belongs to
notification_id UUID required ID of the Notification this setting belongs to
threshold_value double optional Value of the threshold set by the user for the notification to be triggered. If threshold_type of the notification = “percentage” then enter the value as a whole number (e.g. 40% as 40)
frequency_unit string optional Frequency of the notification defined by the user. Value may be one_time, daily, weekly, monthly, quarterly, or annually
frequency integer optional Number of frequency_unit between each request. For example, if the frequency_unit is weekly and the frequency is 2, this means the notification occurs every two weeks. Default is 1
last_run_date timestamp optional The last time a script was run to determine if the client should receive a notification
is_receive boolean optional Indicates if the user wishes to receive a notification. Defaults to true which indicates that the notification will be received
metadata map optional Custom information associated with the notification setting in the format key:value
See Metadata
secondary_id string optional Alternate id that can be used to identify the object such as an internal id

Retrieve a notification setting

Example Request

curl -X GET -H "Authorization: Bearer <access_token>" \
  "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/notification_setting/099961da-7f41-4309-950f-2b51689a0033"
api_instance = nucleus_api.UtilsApi(nucleus_api.ApiClient(configuration))
# Retrieve A NotificationSetting
try:
    api_response = api_instance.get_notification_setting_using_get("9be9f869-cd90-46eb-8052-8e13e39c80ea")
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_notification_setting_using_get: %s\n" % e)
UtilsApi apiInstance = new UtilsApi();
//        //Retrieve a NotificationSetting
//        try {
//            NotificationSetting responseSetting = apiInstance.getNotificationSettingUsingGet(UUID.fromString("38c95e00-446c-4780-b2c9-5f58e4d76471"));
//            System.out.println(responseSetting);
//        } catch (ApiException e) {
//            System.err.println("Exception when calling getNotificationSettingUsingGet");
//            e.printStackTrace();
//        }
$apiInstance = new com\hydrogen\nucleus\Api\UtilsApi(
    new GuzzleHttp\Client(),
    $config);
//Retrieve an NotificationSetting
$notification_setting_id = "38c95e00-446c-4780-b2c9-5f58e4d76471"; // string | notification_setting_id

try {
    $notificationsetting = $apiInstance->getNotificationSettingUsingGet($notification_setting_id);
    print_r($notificationsetting);
} catch (Exception $e) {
    echo 'Exception when calling NotificationApi->getNotificationSettingUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::UtilsApi.new
#Retrieve a NotificationSetting
notification_setting_id = '38c95e00-446c-4780-b2c9-5f58e4d76471' # String | notification_setting_id


begin
  setting = api_instance.get_notification_setting_using_get(notification_setting_id)
  p setting
rescue NucleusApi::ApiError => e
  puts "Exception when calling NotificationApi->get_notification_setting_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.UtilsApi();
//Retrieve a NotificationSetting

var notificationsettingID = "38c95e00-446c-4780-b2c9-5f58e4d76471";

var opts = {
    'currencyConversion': null, // String | USD
};

var notificationsetting = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.getNotificationSettingUsingGet(notificationsettingID, notificationsetting)

Example Response

{
  "id": "099961da-7f41-4309-950f-2b51689a0033",
  "create_date": "2019-09-12T18:46:12.000+0000",
  "update_date": "2019-09-13T09:00:00.000+0000",
  "client_id": "46g4kw32-47g6-2v2r-m513-469ax6f2h6z23",
  "notification_id": "36f9cb66-88a9-4a1f-a305-338a0f0e0a57",
  "threshold_value": null,
  "frequency_unit": "one_time",
  "frequency": 1,
  "last_run_date": null,
  "is_receive": true,
  "metadata": {},
  "secondary_id": null
}

Retrieve a notification setting for your firm or a client. The notification_setting_id must be provided. The endpoint returns the notification_setting_id and the details for the notification setting specified.

HTTP REQUEST

GET /notification_setting/{notification_setting_id}

Update a notification setting

Example Request

curl -X PUT -H "Authorization: Bearer <access_token>" \
   -H "Content-Type: application/json" \
   -d '{
          "is_receive": false
        }' "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/notification_setting/099961da-7f41-4309-950f-2b51689a0033"
api_instance = nucleus_api.UtilsApi(nucleus_api.ApiClient(configuration))
# #Update NotificationSetting
notification_setting_update = {'frequency': 'daily'}
notification_setting_id = '2a674a7c-2826-4566-bf53-c316e8a54876'
try:
    api_response = api_instance.update_notification_setting_using_put(notification_setting_update, notification_setting_id)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling update_notification_setting_using_put: %s\n" % e)
UtilsApi apiInstance = new UtilsApi();
          //Update a NotificationSetting
        Map map = new HashMap();
        map.put("frequency", "null");

        try {
            NotificationSetting response = apiInstance.updateNotificationSettingUsingPut(map, UUID.fromString("ae92494a-24d7-4541-9b02-6ba728e0c839"));
            System.out.println(response);
        } catch (ApiException e) {
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\UtilsApi(
    new GuzzleHttp\Client(),
    $config);
//Update Notification Setting
$notification_setting_update = new stdClass();
$notification_setting_id = "44557c92-242f-466e-862b-796062c0dd6a";

try {
    $notification_setting_update->frequency = "2";
    $result = $apiInstance->updateNotificationSettingUsingPut($notification_setting_update, $notification_setting_id);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->updateNotificationSettingUsingPut: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::UtilsApi.new
#Update Notification Setting
notification_setting_update = {"frequency" => '2'}
notificaion_setting_id = 'ae92494a-24d7-4541-9b02-6ba728e0c839'
begin
  result = api_instance.update_notification_setting_using_put(notification_setting_update, notification_setting_id)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->update_notification_setting_using_put: #{e}"
end
var apiInstance = new HydrogenNucleusApi.UtilsApi();
//Update Notification Setting
var apiInstance = new HydrogenNucleusApi.UtilsApi();
var callback = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
var notificationsettingupdate = new HydrogenNucleusApi.NotificationSetting();
var notificationsettingid = 'aed709bf-93fa-4e83-96ae-b1c470d215dc';

notificationsettingupdate.frequency = "null";
apiInstance.updateNotificationSettingUsingPut(notificationsettingupdate, notificationsettingid, callback)

Example Response

{
  "id": "099961da-7f41-4309-950f-2b51689a0033",
  "create_date": "2019-09-12T18:46:12.000+0000",
  "update_date": "2019-09-13T09:00:00.000+0000",
  "client_id": "46g4kw32-47g6-2v2r-m513-469ax6f2h6z23",
  "notification_id": "36f9cb66-88a9-4a1f-a305-338a0f0e0a57",
  "threshold_value": null,
  "frequency_unit": "one_time",
  "frequency": 1,
  "is_receive": false,
  "last_run_date": null,
  "metadata": {},
  "secondary_id": null
}

Update a notification for your firm. The notification_setting_id must be provided. To obtain the appropriate notification_setting_id, use the GET /notification_setting endpoint to view all of the notifications for clients in your firm. The details to be updated and the details to be maintained must also be provided. The endpoint returns the notification_setting_id and the details for the notification.

HTTP REQUEST

PUT /notification_setting/{notification_setting_id}

Delete a notification setting

Example Request

curl -X DELETE -H "Authorization: Bearer <access_token>" \
  "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/notification_setting/099961da-7f41-4309-950f-2b51689a0033"
api_instance = nucleus_api.UtilsApi(nucleus_api.ApiClient(configuration))
# #Delete a NotificationSetting
notification_setting1_id = '113e8c76-0114-45cb-ba23-d6ed8c7900c9'

try:
    api_instance.delete_notification_setting_using_delete(notification_setting1_id)
except ApiException as e:
    print("Exception when calling delete_notification_setting_using_delete: %s\n" % e)
UtilsApi apiInstance = new UtilsApi();
        //Delete a NotificationSetting
        try {
            NotificationSetting deleteresponse = apiInstance.deleteNotificationSettingUsingDelete(UUID.fromString("e1f19047-89e7-4e34-8397-6056699173b0"));
            System.out.println(deleteresponse);
        } catch (ApiException e) {
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\UtilsApi(
    new GuzzleHttp\Client(),
    $config);

//Delete Notification Setting
$notification_setting_did = "113e8c76-0114-45cb-ba23-d6ed8c7900c9"; // string | UUID account_id

try {
    $apiInstance->deleteNotificationSettingUsingDelete($notification_setting_did);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->deleteNotificationSettingUsingDelete: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::UtilsApi.new
#Delete Notification Setting
notification_setting1_id = '409237df-7ed4-48b1-87d5-fbc219e2b915'
begin
  result = api_instance.delete_notification_setting_using_delete(notification_setting1_id)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->delete_notification_setting_using_delete: #{e}"
end
var apiInstance = new HydrogenNucleusApi.UtilsApi();
// // // // // //Delete a NotificationSetting
// var notificationsettingidd = "1420c7ae-6124-4b6b-8ff4-faea2e364111";
//
//
// var deletenotificationsetting = function(error, data, response) {
//     if (error) {
//         console.error(error);
//     } else {
//         console.log('API called successfully.');
//     }
// };
// apiInstance.deleteNotificationSettingUsingDelete(notificationsettingidd, deletenotificationsetting)

Response (204 No Content)

Permanently delete a notification setting for your firm. The notification_setting_id must be provided. To obtain the appropriate notification_setting_id, use the GET /notification_setting endpoint to view all of the notification settings for clients in your firm. This deletes the notification_setting_id and the details for the notification setting record.

HTTP REQUEST

DELETE /notification_setting/{notification_setting_id}

Notification Client

Store notifications that have been sent to users in your application(s).

Field Type Description
id UUID The id of the notification
client_id UUID ID of the Client this notification belongs to
notification_id UUID ID of the Notification this content belongs to
notification_content string Content of the notification that was sent to the user
notification_date timestamp Date that the notification was sent to the user
notification_image string Link to an image or icon to display for the client notification
is_sent boolean Indicates if the notification has been sent to the client. Defaults to false which indicates that the notification has not yet been sent
is_read boolean Indicates if the notification has been read by the client. Defaults to false which indicates that the notification has not yet been read
metadata map Custom information associated with the notification in the format key:value
See Metadata
secondary_id string Alternate id that can be used to identify the object such as an internal id
create_date timestamp Timestamp for the date and time that the notification was created
update_date timestamp Timestamp for the date and time that the notification was last updated

List all client notifications

Example Request

curl -X GET -H "Authorization: Bearer <access_token>" \
  "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/notification_client"
api_instance = nucleus_api.UtilsApi(nucleus_api.ApiClient(configuration))
# List all NotificationClient
try:
    api_response = api_instance.get_notification_client_all_using_get()
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_notification_client_all_using_get: %s\n" % e)
UtilsApi apiInstance = new UtilsApi();
//        //List all NotificationClient
        try {
            PageNotificationClient List = apiInstance.getNotificationClientAllUsingGet(true, null, null, 0, 10);
            System.out.println(List);
        } catch (ApiException e) {
            System.err.println("Exception when calling getNotificationClientAllUsingGet");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\UtilsApi(
    new GuzzleHttp\Client(),
    $config);

//List all NotificationClient
$ascending = false; // bool | ascending
$filter = null; // string | filter
$order_by = null; // string | order_by
$page = 0; // int | page
$size = 10; // int | size

try {
    $notificationclientlist = $apiInstance->getNotificationClientAllUsingGet($ascending, $filter, $order_by, $page, $size);
    print_r($notificationclientlist);
} catch (Exception $e) {
    echo 'Exception when calling NotificationApi->getNotificationClientAllUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::UtilsApi.new
#List all NotificationClient
opts = {
  ascending: false, # BOOLEAN | ascending
  filter: null, # String | filter
  order_by: null, # String | order_by
  page: 0, # Integer | page
  size: 25 # Integer | size
}

begin
  clientlist = api_instance.get_notification_client_all_using_get(opts)
  p clientlist
rescue NucleusApi::ApiError => e
  puts "Exception when calling NotificationApi->get_notification_client_all_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.UtilsApi();
//List all Notification Clients
var opts = {
    'ascending': false, // Boolean | ascending
    // 'filter': "", // String | filter
    'orderBy': "update_date", // String | order_by
    'page': 0, // Number | page
    'size': 25 // Number | size
};

var notificationclientlist = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.getNotificationClientAllUsingGet(opts, notificationclientlist)

Example Response

{
    "content": [
        {
            "id": "52u4rp55-44h6-2p4y-d193-119c1r5s7b78",
            "create_date": "2019-08-12T18:47:38.000+0000",
            "update_date": "2019-08-13T09:00:00.000+0000",
            "client_id": "46g4kw32-47g6-2v2r-m513-469ax6f2h6z23",
            "notification_id": "36f9cb66-88a9-4a1f-a305-338a0f0e0a57",
            "notification_content": "Monthly newsletter for August 2019 published.",
            "notification_date": "2019-08-12T18:47:38.000+0000",
            "notification_image": null,
            "is_sent": false,
            "is_read": false,
            "metadata": {},
            "secondary_id": null
        },
        {
            "id": "21k5pe66-63f7-7j4h-w265-326b6s4n8b31",
            "create_date": "2019-09-12T18:46:12.000+0000",
            "update_date": "2019-09-13T09:00:00.000+0000",
            "client_id": "46g4kw32-47g6-2v2r-m513-469ax6f2h6z23",
            "notification_id": "c4ea6c00-d0b4-4d75-9e7a-e9dd04319586",
            "notification_content": "You have a new trade for AAPL in your taxable account.",
            "notification_date": "2019-09-12T18:46:12.000+0000",
            "notification_image": null,
            "is_sent": false,
            "is_read": true,
            "metadata": {},
            "secondary_id": null
        }
    ],
    "total_pages": 1,
    "total_elements": 2,
    "last": true,
    "first": true,
    "sort": [
        {
            "direction": "DESC",
            "property": "updateDate",
            "ignore_case": false,
            "null_handling": "NATIVE",
            "descending": true,
            "ascending": false
        }
    ],
    "number_of_elements": 2,
    "size": 25,
    "number": 0
}

Get all the notification settings defined for client’s in your firm.

HTTP REQUEST

GET /notification_client

Create a client notification

Example Request

curl -X POST -H "Authorization: Bearer <access_token>" \
    -H "Content-Type: application/json" \
    -d '{
          "client_id": "46g4kw32-47g6-2v2r-m513-469ax6f2h6z23",
          "notification_id": "c4ea6c00-d0b4-4d75-9e7a-e9dd04319586",
          "notification_content": "You have a new trade for AAPL in your taxable account.",
          "notification_date": "2019-09-12T18:46:12.000+0000"
        }' "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/notification_client"
api_instance = nucleus_api.UtilsApi(nucleus_api.ApiClient(configuration))
# #Create NotificationClient
notification_client = nucleus_api.NotificationClient(client_id="63f05f77-1851-477c-9866-88effe5aeca3", notification_id="fa5036a1-abea-4f04-b627-08d5dff2da67", notification_content="new", notification_date="2020-10-10")
try:
    api_response = api_instance.create_notification_client_using_post(notification_client)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling create_notification_client_using_post: %s\n" % e)
UtilsApi apiInstance = new UtilsApi();
        //Create a NotificationClient
        NotificationClient clientNotification = new NotificationClient();
        clientNotification.setClientId(UUID.fromString("63f05f77-1851-477c-9866-88effe5aeca3"));
        clientNotification.setNotificationId(UUID.fromString("fa5036a1-abea-4f04-b627-08d5dff2da67"));
        clientNotification.setNotificationContent("New");
        clientNotification.setNotificationDate(odt);

        try {
            NotificationClient result = apiInstance.createNotificationClientUsingPost(clientNotification);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling createNotificationClientUsingPost");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\UtilsApi(
    new GuzzleHttp\Client(),
    $config);

//Create Notification Client
$notification_client = new \com\hydrogen\nucleus\Model\NotificationClient();


try {
    $notification_client->setClientId("63f05f77-1851-477c-9866-88effe5aeca3");
    $notification_client->setNotificationId("fa5036a1-abea-4f04-b627-08d5dff2da67");
    $notification_client->setNotificationContent("ABC");
    $notification_client->setNotificationDate("2020-10-10");
    $result = $apiInstance->createNotificationClientUsingPost($notification_client);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->createNotificationClientUsingPost: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::UtilsApi.new
#Create Notification Client
notification_client = NucleusApi::NotificationClient.new

begin
  notification_client.client_id = "63f05f77-1851-477c-9866-88effe5aeca3"
  notification_client.notification_id = "fa5036a1-abea-4f04-b627-08d5dff2da67"
  notification_client.notification_content = "New"
  notification_client.notification_date = "2020-10-10"
  result = api_instance.create_notification_client_using_post(notification_client)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->create_notification_client_using_post: #{e}"
end
var apiInstance = new HydrogenNucleusApi.UtilsApi();
//Create a Notification Client
var notificationclient = new HydrogenNucleusApi.NotificationClient();
notificationclient.client_id = '63f05f77-1851-477c-9866-88effe5aeca3';
notificationclient.notification_id = 'fa5036a1-abea-4f04-b627-08d5dff2da67';
notificationclient.notification_content = "New";
notificationclient.notification_date = "2020-10-10";

var newnotificationclient = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.createNotificationClientUsingPost(notificationclient, newnotificationclient)

Example Response

{
  "id": "21k5pe66-63f7-7j4h-w265-326b6s4n8b31",
  "client_id": "46g4kw32-47g6-2v2r-m513-469ax6f2h6z23",
  "notification_id": "c4ea6c00-d0b4-4d75-9e7a-e9dd04319586",
  "notification_content": "You have a new trade for AAPL in your taxable account.",
  "notification_date": "2019-09-12T18:46:12.000+0000",
  "notification_image": null,
  "is_sent": false,
  "is_read": false,
  "metadata": {},
  "secondary_id": null
}

Create a notification for a client. You must enter a client_id, notification_id, notification_content, and notification_date for the notification. The endpoint returns a notification_client_id used to identify and manage the notification.

HTTP REQUEST

POST /notification_client

ARGUMENTS

Parameter Type Required Description
client_id UUID required ID of the Client this notification belongs to
notification_id UUID required ID of the Notification this content belongs to
notification_content string required Content of the notification that was sent to the user
notification_date timestamp required Date that the notification was sent to the user
notification_image string optional Link to an image or icon to display for the client notification
is_sent boolean optional Indicates if the notification has been sent to the client. Defaults to false which indicates that the notification has not yet been sent
is_read boolean optional Indicates if the notification has been read by the client. Defaults to false which indicates that the notification has not yet been read
metadata map optional Custom information associated with the notification in the format key:value
See Metadata
secondary_id string optional Alternate id that can be used to identify the object such as an internal id

Retrieve a client notification

Example Request

curl -X GET -H "Authorization: Bearer <access_token>" \
  "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/notification_client/099961da-7f41-4309-950f-2b51689a0033"
api_instance = nucleus_api.UtilsApi(nucleus_api.ApiClient(configuration))
# Retrieve A NotificationClient
try:
    api_response = api_instance.get_notification_client_using_get("76841abc-c5a5-4ede-8c4a-583f9a14edf2")
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_notification_client_using_get: %s\n" % e)
UtilsApi apiInstance = new UtilsApi();
        //Retrieve a ClientNotification
        try {
            NotificationClient responseClient = apiInstance.getNotificationClientUsingGet(UUID.fromString("9cfc4fff-693c-4132-8976-686ec6c96883"));
            System.out.println(responseClient);
        } catch (ApiException e) {
            System.err.println("Exception when calling getNotificationClientUsingGet");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\UtilsApi(
    new GuzzleHttp\Client(),
    $config);

//Retrieve an NotificationClient
$notification_client_id = "9cfc4fff-693c-4132-8976-686ec6c96883"; // string | notification_client_id

try {
    $notificationclient = $apiInstance->getNotificationClientUsingGet($notification_client_id);
    print_r($notificationclient);
} catch (Exception $e) {
    echo 'Exception when calling NotificationApi->getNotificationClientUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::UtilsApi.new
#Retrieve a NotificationClient
notification_client_id = '9cfc4fff-693c-4132-8976-686ec6c96883' # String | notification_client_id


begin
  client = api_instance.get_notification_client_using_get(notification_client_id)
  p client
rescue NucleusApi::ApiError => e
  puts "Exception when calling NotificationApi->get_notification_client_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.UtilsApi();
//Retrieve a NotificationSClient

var notificatioIclientD = "9cfc4fff-693c-4132-8976-686ec6c96883";

var opts = {
    'currencyConversion': null, // String | USD
};

var notificationclient = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.getNotificationClientUsingGet(notificatioIclientD, notificationclient)

Example Response

{
  "id": "21k5pe66-63f7-7j4h-w265-326b6s4n8b31",
  "create_date": "2019-09-12T18:46:12.000+0000",
  "update_date": "2019-09-13T09:00:00.000+0000",
  "client_id": "46g4kw32-47g6-2v2r-m513-469ax6f2h6z23",
  "notification_id": "c4ea6c00-d0b4-4d75-9e7a-e9dd04319586",
  "notification_content": "You have a new trade for AAPL in your taxable account.",
  "notification_date": "2019-09-12T18:46:12.000+0000",
  "notification_image": null,
  "is_sent": false,
  "is_read": false,
  "metadata": {},
  "secondary_id": null
}

Retrieve a client notification. The notification_client_id must be provided. The endpoint returns the notification_client_id and the details for the client notification specified.

HTTP REQUEST

GET /notification_client/{notification_client_id}

Update a client notification

Example Request

curl -X PUT -H "Authorization: Bearer <access_token>" \
   -H "Content-Type: application/json" \
   -d '{
          "notification_content": "You have a new trade for TSLA in your taxable account."
        }' "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/notification_client/21k5pe66-63f7-7j4h-w265-326b6s4n8b31"
api_instance = nucleus_api.UtilsApi(nucleus_api.ApiClient(configuration))
# #Update NotificatiionClient
notification_client_update = {'notification_image': 'None'}
notification_client_id = 'd08085c4-862d-4d89-b3f9-7e59825f3c5c'
try:
    api_response = api_instance.update_notification_client_using_put(notification_client_update, notification_client_id)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling update_notification_client_using_put: %s\n" % e)
UtilsApi apiInstance = new UtilsApi();
//          //Update a NotificationClient
        Map map = new HashMap();
        map.put("notification_content", "notification_content");

        try {
            NotificationClient response = apiInstance.updateNotificationClientUsingPut(map, UUID.fromString("1a0ebef1-5d2e-4b9c-9347-694ed30076af"));
            System.out.println(response);
        } catch (ApiException e) {
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\UtilsApi(
    new GuzzleHttp\Client(),
    $config);
//Update Notification Client
$notification_client_update = new stdClass();
$notification_client_id = "d08085c4-862d-4d89-b3f9-7e59825f3c5c";

try {
    $notification_client_update->notification_date = "2020-10-10";
    $result = $apiInstance->updateNotificationClientUsingPut($notification_client_update, $notification_client_id);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->updateNotificationClientUsingPut: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::UtilsApi.new
#Update Notification Client
notification_client_update = {"notification_date" => '2020-10-10'}
notificaion_client_id = '1a0ebef1-5d2e-4b9c-9347-694ed30076af'
begin
  result = api_instance.update_notification_client_using_put(notification_client_update, notification_client_id)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->update_notification_client_using_put: #{e}"
end
var apiInstance = new HydrogenNucleusApi.UtilsApi();
//Update Notification Client
var apiInstance = new HydrogenNucleusApi.UtilsApi();
var callback = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
var notificationclientupdate = new HydrogenNucleusApi.NotificationClient();
var notificationclientid = 'cea20d96-6cde-4e5a-8607-76e98d98e6d4';

notificationclientupdate.is_read = "false";
apiInstance.updateNotificationClientUsingPut(notificationclientupdate, notificationclientid, callback)

Example Response

{
  "id": "21k5pe66-63f7-7j4h-w265-326b6s4n8b31",
  "create_date": "2019-09-12T18:46:12.000+0000",
  "update_date": "2019-09-13T09:00:00.000+0000",
  "client_id": "46g4kw32-47g6-2v2r-m513-469ax6f2h6z23",
  "notification_id": "c4ea6c00-d0b4-4d75-9e7a-e9dd04319586",
  "notification_content": "You have a new trade for TSLA in your taxable account.",
  "notification_date": "2019-09-12T18:46:12.000+0000",
  "notification_image": null,
  "is_sent": false,
  "is_read": false,
  "metadata": {},
  "secondary_id": null
}

Update a client notification. The notification_client_id must be provided. To obtain the appropriate notification_client_id, use the GET /notification_client endpoint to view all of the notifications for clients in your firm. The details to be updated and the details to be maintained must also be provided. The endpoint returns the notification_client_id and the details for the notification.

HTTP REQUEST

PUT /notification_client_id/{notification_client_id}

Delete a client notification

Example Request

curl -X DELETE -H "Authorization: Bearer <access_token>" \
  "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/notification_client/21k5pe66-63f7-7j4h-w265-326b6s4n8b31"
api_instance = nucleus_api.UtilsApi(nucleus_api.ApiClient(configuration))
# #Delete a NotificationClient
notification_client1_id = '02883a2b-ad7b-44bc-b8f4-94199ca92aed'

try:
    api_instance.delete_notification_client_using_delete(notification_client1_id)
except ApiException as e:
    print("Exception when calling delete_notification_client_using_delete: %s\n" % e)
UtilsApi apiInstance = new UtilsApi();

        //Delete a NotificationClient
        try {
            NotificationClient deleteresponse = apiInstance.deleteNotificationClientUsingDelete(UUID.fromString("b82b51e8-796e-4269-8a28-0437c49c6e42"));
            System.out.println(deleteresponse);
        } catch (ApiException e) {
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\UtilsApi(
    new GuzzleHttp\Client(),
    $config);
//Delete Notification Client
$notification_client_did = "409237df-7ed4-48b1-87d5-fbc219e2b915"; // string | UUID account_id

try {
    $apiInstance->deleteNotificationClientUsingDelete($notification_client_did);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->deleteNotificationClientUsingDelete: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::UtilsApi.new
#Delete Notification Client
notification_client1_id = '409237df-7ed4-48b1-87d5-fbc219e2b915'
begin
  result = api_instance.delete_notification_client_using_delete(notification_client1_id)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->delete_notification_client_using_delete: #{e}"
end
var apiInstance = new HydrogenNucleusApi.UtilsApi();
 // //Delete a NotificationClient
var notificationclientidd = "d124efca-311a-48b5-8b3d-ae2e5c2da2d7";


var deletenotificationclient = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully.');
    }
};
apiInstance.deleteNotificationClientUsingDelete(notificationclientidd, deletenotificationclient)

Response (204 No Content)

Permanently delete a client notification. The notification_client_id must be provided. To obtain the appropriate notification_client_id, use the GET /notification_client endpoint to view all of the client notifications in your firm. This deletes the notification_client_id and the details for the notification setting record.

HTTP REQUEST

DELETE /notification_client/{notification_client_id}

Reason Code

Reason codes are defined by your firm to identify . These codes should be pre-populated for your tenant before performing any reasonal related services and should match the codes that are expected by your back office. Examples of generic reasons codes include “Account Closed” or “Card Lost”.

Field Type Description
id UUID The id of the reason code
reason_code string Code that identifies the reason within your firm
reason_code_description string Short description of the reason code
reason_type string Type of reason code such as “Fraud”
category string Grouping of similar reason codes
subcategory string Sub-grouping of similar reason codes
metadata map Custom information associated with the entity in the format key:value
See Metadata
secondary_id string Alternate id that can be used to identify the object such as an internal id
create_date timestamp Timestamp for the date and time that the record was created
update_date timestamp Timestamp for the date and time that the record was last updated

List all reason codes

Example Request

curl -X GET -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/reason_code"
api_instance = nucleus_api.UtilsApi(nucleus_api.ApiClient(configuration))
try:
    api_response = api_instance.get_reason_code_all_using_get()
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_reason_code_all_using_get: %s\n" % e)
UtilsApi apiInstance = new UtilsApi();
        try {
            PageReasonCode List = apiInstance.getReasonCodeAllUsingGet(true, null, null, 0, 10);
            System.out.println(List);
        } catch (ApiException e) {
            System.err.println("Exception when calling getReasonCodeAllUsingGet");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\UtilsApi(
    new GuzzleHttp\Client(),
    $config);
$ascending = false; // bool | ascending
$filter = null; // string | filter
$order_by = null; // string | order_by
$page = 0; // int | page
$size = 10; // int | size

try {
    $reasoncodelist = $apiInstance->getReasonCodeAllUsingGet($ascending, $filter, $order_by, $page, $size);
    print_r($reasoncodelist);
} catch (Exception $e) {
    echo 'Exception when calling UtilsApi->getReasonCodeAllUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::UtilsApi.new
opts = {
    ascending: false, # BOOLEAN | ascending
    filter: null, # String | filter
    order_by: null, # String | order_by
    page: 0, # Integer | page
    size: 25 # Integer | size
}

begin
  reasoncodelist = api_instance.get_reason_code_all_using_get(opts)
  p reasoncodelist
rescue NucleusApi::ApiError => e
  puts "Exception when calling UtilsApi->get_reason_code_all_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.UtilsApi();
var opts = {
    'ascending': false, // Boolean | ascending
    // 'filter': "", // String | filter
    'orderBy': "update_date", // String | order_by
    'page': 0, // Number | page
    'size': 25 // Number | size
};

var reasoncodelist = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.getReasonCodeAllUsingGet(opts,  reasoncodelist)

Example Response

{
    "content": [
        {
            "id": "099961da-7f41-4309-950f-2b51689a0033",
            "secondary_id": null,
            "category": null,
            "subcategory": null,
            "reason_code": "lc01",
            "reason_code_description": "Lost Card",
            "reason_type": "Customer Action",
            "metadata": {}
        },
        {
            "id": "1d7e1aad-3c79-49fe-bbb9-bd5e239ae1e7",
            "secondary_id": null,
            "category": null,
            "subcategory": null,
            "reason_code": "lc02",
            "reason_code_description": "Stolen Card",
            "reason_type": "Customer Action",
            "metadata": {}
        },
        {
            "id": "2a7a6cb7-ef71-4fe8-9169-2678f3799657",
            "secondary_id": null,
            "category": null,
            "subcategory": null,
            "reason_code": "lc03",
            "reason_code_description": "Damaged Card",
            "reason_type": "Customer Action",
            "metadata": {}
        }
    ],
    "last": true,
    "total_pages": 1,
    "total_elements": 3,
    "sort": [
        {
            "direction": "DESC",
            "property": "",
            "ignore_case": false,
            "null_handling": "NATIVE",
            "descending": true,
            "ascending": false
        }
    ],
    "first": true,
    "number_of_elements": 17,
    "size": 25,
    "number": 0
}

Get the information for all reason codes defined by your firm. The endpoint returns a list of ids and details for each reason code.

HTTP REQUEST

GET /reason_code

Create a reason code

Example Request

curl -X POST -H "Authorization: Bearer <access_token>" \
     -H "Content-Type: application/json" \
     -d '{
           "reason_code": "lc01",
           "reason_code_description": "Lost Card",
           "reason_type": "Customer Action"
        }' "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/reason_code"
api_instance = nucleus_api.UtilsApi(nucleus_api.ApiClient(configuration))
# #Create ReasonCode
reason_code = nucleus_api.ReasonCode(reason_code="Secret")
try:
    api_response = api_instance.create_reason_code_using_post(reason_code)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling create_reason_code_using_post: %s\n" % e)
UtilsApi apiInstance = new UtilsApi();
        //Create a Reason Code
        ReasonCode reason = new ReasonCode();
        reason.setReasonCode("new One");

        try {
            ReasonCode result = apiInstance.createReasonCodeUsingPost(reason);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling createReasonCodeUsingPost");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\UtilsApi(
    new GuzzleHttp\Client(),
    $config);
//Create Reason code
$reason_code = new \com\hydrogen\nucleus\Model\ReasonCode();


try {
    $reason_code->setReasonCode("Neew Code");
    $result = $apiInstance->createReasonCodeUsingPost($reason_code);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->createReasonCodeUsingPost: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::UtilsApi.new
#Create Reason code
reasoncode = NucleusApi::ReasonCode.new

begin
  reasoncode.reason_code = "New"
  result = api_instance.create_reason_code_using_post(reasoncode)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->create_reason_code_using_post: #{e}"
end
var apiInstance = new HydrogenNucleusApi.UtilsApi();
//Create a Reason Code
var rcode = new HydrogenNucleusApi.ReasonCode();
rcode.reason_code = "New One";


var newreasoncode = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.createReasonCodeUsingPost(rcode, newreasoncode)

Example Response

{
    "id": "099961da-7f41-4309-950f-2b51689a0033",
    "secondary_id": null,
    "category": null,
    "subcategory": null,
    "reason_code": "lc01",
    "reason_code_description": "Lost Card",
    "reason_type": "Customer Action",
    "metadata": {}
}

Create a new reason code for your tenant. The endpoint returns a unique identifier for the reason code that can be referenced.

HTTP REQUEST

POST /reason_code

ARGUMENTS

Parameter Type Required Description
reason_code string required Code that identifies the reason within your firm
reason_code_description string optional Short description of the reason code
reason_type string optional Type of reason code such as “Fraud”
category string optional Grouping of similar reason codes
subcategory string optional Sub-grouping of similar reason codes
metadata map optional Custom information associated with the entity in the format key:value
See Metadata
secondary_id string optional Alternate id that can be used to identify the object such as an internal id

Retrieve a reason code

Example Request

curl -X GET -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/reason_code/099961da-7f41-4309-950f-2b51689a0033"
api_instance = nucleus_api.UtilsApi(nucleus_api.ApiClient(configuration))
try:
    api_response = api_instance.get_reason_code_using_get("38847afa-4cd3-4cce-b40f-c826be7b0473")
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_reason_code_using_get: %s\n" % e)
UtilsApi apiInstance = new UtilsApi();
        try {
            ReasonCode responseReasonCode = apiInstance.getReasonCodeUsingGet(UUID.fromString("38847afa-4cd3-4cce-b40f-c826be7b0473"));
            System.out.println(responseReasonCode);
        } catch (ApiException e) {
            System.err.println("Exception when calling getReasonCodeUsingGet");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\UtilsApi(
    new GuzzleHttp\Client(),
    $config);
$reason_code_id = "38847afa-4cd3-4cce-b40f-c826be7b0473"; // string | UUID reason_code_id

try {
    $reasoncode = $apiInstance->getReasonCodeUsingGet($reason_code_id);
    print_r($reasoncode);
} catch (Exception $e) {
    echo 'Exception when calling UtilsApi->getReasonCodeUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::UtilsApi.new
reason_code_id = '38847afa-4cd3-4cce-b40f-c826be7b0473' # String | UUID reason_code_id


begin
  reasoncode = api_instance.get_reason_code_using_get(reason_code_id)
  p reasoncode
rescue NucleusApi::ApiError => e
  puts "Exception when calling UtilsApi->get_reason_code_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.UtilsApi();
var reasoncodeID = "38847afa-4cd3-4cce-b40f-c826be7b0473";

var opts = {
    'currencyConversion': null, // String | USD
};

var reasoncode = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.getReasonCodeUsingGet(reasoncodeID, reasoncode)

Example Response

{
    "id": "099961da-7f41-4309-950f-2b51689a0033",
    "secondary_id": null,
    "category": null,
    "subcategory": null,
    "reason_code": "lc01",
    "reason_code_description": "Lost Card",
    "reason_type": "Customer Action",
    "metadata": {}
}

Retrieve the information for a reason code defined by your firm. The reason_code_id must be provided. The endpoint returns the details for the reason code specified.

HTTP REQUEST

GET /reason_code/{reason_code_id}

Update a reason code

Example Request

curl -X PUT -H "Authorization: Bearer <access_token>" \
     -H "Content-Type: application/json" \
     -d '{
            "reason_code": "lc01",
            "reason_code_description": "Lost Card",
            "reason_type": "Customer Action",
        }' "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/reason_code/099961da-7f41-4309-950f-2b51689a0033"
api_instance = nucleus_api.UtilsApi(nucleus_api.ApiClient(configuration))
# #Update ReasonCode
reason_code_update = {'reason_code_description': 'One'}
reason_code_id = '3def1a03-0c0c-49d8-8c23-88ef5f40bdcd'
try:
    api_response = api_instance.update_reason_code_using_put(reason_code_update, reason_code_id)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling update_reason_code_using_put: %s\n" % e)
UtilsApi apiInstance = new UtilsApi();
        //        //Update a Reasoncode
        Map map = new HashMap();
        map.put("reason_type", "new");

        try {
            ReasonCode response = apiInstance.updateReasonCodeUsingPut(map, UUID.fromString("460d6dfc-35ae-436a-9b7c-b1a02082bd7e"));
            System.out.println(response);
        } catch (ApiException e) {
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\UtilsApi(
    new GuzzleHttp\Client(),
    $config);
//Update Reason Code
$reason_code_update = new stdClass();
$reason_code_id = "460d6dfc-35ae-436a-9b7c-b1a02082bd7e";

try {
    $reason_code_update->reason_type = "ABC";
    $result = $apiInstance->updateReasonCodeUsingPut($reason_code_update, $reason_code_id);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->updateReasonCodeUsingPut: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::UtilsApi.new
#Update Reason Code
reasoncode_update = {"reason_code" => 'CAD'}
reasoncode_id = 'd85438ea-419d-48f1-8a9b-178c541f41db'
begin
  result = api_instance.update_reason_code_using_put(reasoncode_update, reasoncode_id)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->update_reason_code_using_put: #{e}"
end
var apiInstance = new HydrogenNucleusApi.UtilsApi();
//Update Reason Code
var apiInstance = new HydrogenNucleusApi.UtilsApi();
var callback = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
var reasonupdate = new HydrogenNucleusApi.ReasonCode();
var reasonid = '59544208-444f-4f5c-8f60-b6144fcee354';

reasonupdate.reason_code = "New";
apiInstance.updateReasonCodeUsingPut(reasonupdate, reasonid, callback)

Example Response

{
    "id": "099961da-7f41-4309-950f-2b51689a0033",
    "secondary_id": null,
    "category": null,
    "subcategory": null,
    "reason_code": "lc01",
    "reason_code_description": "Lost Card",
    "reason_type": "Customer Action",
    "metadata": {}
}

Update a reason code for your tenant. The reason_code_id must be provided. To obtain the appropriate reason_code_id, use the GET /reason_code endpoint to view all the reason codes defined for your tenant and their current information. The details to be updated must also be provided. The endpoint returns the reason_code_id and all details for the reason code.

HTTP REQUEST

PUT /reason_code/{reason_code_id}

Delete a reason code

Example Request

curl -X DELETE -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/reason_code/099961da-7f41-4309-950f-2b51689a0033"
api_instance = nucleus_api.UtilsApi(nucleus_api.ApiClient(configuration))
# #Delete a ReasonCode
reason_code1_id = 'dbc0ccff-5d0b-44ed-8197-49d01743d507'

try:
    api_instance.delete_reason_code_using_delete(reason_code1_id)
except ApiException as e:
    print("Exception when calling delete_reason_code_using_delete: %s\n" % e)
UtilsApi apiInstance = new UtilsApi();
        //Delete a ReasonCode
        try {
            ReasonCode deleteresponse = apiInstance.deleteReasonCodeUsingDelete(UUID.fromString("c4f34f60-d3f3-4c55-a3f1-eeab6a77a692"));
            System.out.println(deleteresponse);
        } catch (ApiException e) {
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\UtilsApi(
    new GuzzleHttp\Client(),
    $config);
//Delete Reason Code
$reason_code_did = "dbc0ccff-5d0b-44ed-8197-49d01743d507"; // string | UUID account_id

try {
    $apiInstance->deleteReasonCodeUsingDelete($reason_code_did);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->deleteNotificationSettingUsingDelete: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::UtilsApi.new
#Delete Reason Code
reasoncode1_id = '460d6dfc-35ae-436a-9b7c-b1a02082bd7e'
begin
  result = api_instance.delete_reason_code_using_delete(reasoncode1_id)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->delete_reason_code_using_delete: #{e}"
end
var apiInstance = new HydrogenNucleusApi.UtilsApi();
// //Delete a Reason code
var reasonidd = "460d6dfc-35ae-436a-9b7c-b1a02082bd7e";


var deletereasoncode = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully.');
    }
};
apiInstance.deleteReasonCodeUsingDelete(reasonidd, deletereasoncode)

Response (204 No Content)

Permanently delete a reason code for your tenant. The reason_code_id must be provided. To obtain the appropriate reason_code_id, use the GET /reason_code endpoint to view all the reason codes defined for your tenant. Deletes the reason_code_id and the reason code information so that it can no longer be assigned to order records.

HTTP REQUEST

DELETE /reason_code/{reason_code_id}

Stage

Stages indicate what point an account or client is in along a user journey. The stage is often used to provide business insights into the progression through a sign up funnel to track metrics such as drop-off, acquisition cost, and churn.

Field Type Description
id UUID The id of the account stage
name string Name or label of the stage such as Signed Up or Application Signed. Value must be unique across all stages.
category string Category of the stage to group stages together within a section of an app
description string Description of what the step along the registration process that the stage represents
order_index integer Indicator for where along the process the stage falls. Generally, the higher the order index, the further along the process
application_id UUID ID of the Application this stage belongs to
is_account boolean Indicates if the stage is for an account and used for tracking an Account Status. Defaults to false which indicates that it is not for an account
is_client boolean Indicates if the stage is for a client and used for tracking a Client Status. Defaults to false which indicates that it is not for a client
is_business boolean Indicates if the stage is for a Business. Defaults to false which indicates that it is not for a business
is_converted boolean Indicates if the stage represents a converted account or client. Defaults to false which indicates that it is not converted
is_verified boolean Indicates if the stage represents a KYC verified account or client. Defaults to false which indicates that it is not verified
is_closed boolean Indicates if the stage represents a closed account or client. Defaults to false which indicates that it is not closed
is_active boolean Indicates if the stage is active. Defaults to true which indicates that it is currently active.
metadata map Custom information associated with the entity in the format key:value
See Metadata
secondary_id string Alternate id that can be used to identify the object such as an internal id
create_date timestamp Timestamp for the date and time that the record was created
update_date timestamp Timestamp for the date and time that the record was last updated

List all stages

Example Request

curl -X GET -H "Authorization: Bearer 921c2e12-c3c3-4fe5-b8cc-2035d39ad44e" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/stage"
api_instance = nucleus_api.UtilsApi(nucleus_api.ApiClient(configuration))
try:
    api_response = api_instance.get_stage_all_using_get()
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_stage_all_using_get: %s\n" % e)
UtilsApi apiInstance = new UtilsApi();
        try {
            PageStage List = apiInstance.getStageAllUsingGet(true, null, null, 0, 10);
            System.out.println(List);
        } catch (ApiException e) {
            System.err.println("Exception when calling getStageAllUsingGet");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\UtilsApi(
    new GuzzleHttp\Client(),
    $config);
$ascending = false; // bool | ascending
$filter = null; // string | filter
$order_by = null; // string | order_by
$page = 0; // int | page
$size = 10; // int | size

try {
    $stagelist = $apiInstance->getStageAllUsingGet($ascending, $filter, $order_by, $page, $size);
    print_r($stagelist);
} catch (Exception $e) {
    echo 'Exception when calling UtilsApi->getStageAllUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::UtilsApi.new
opts = {
    ascending: false, # BOOLEAN | ascending
    filter: null, # String | filter
    order_by: null, # String | order_by
    page: 0, # Integer | page
    size: 25 # Integer | size
}

begin
  stagelist = api_instance.get_stage_all_using_get(opts)
  p stagelist
rescue NucleusApi::ApiError => e
  puts "Exception when calling UtilsApi->get_stage_all_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.UtilsApi();
var opts = {
    'ascending': false, // Boolean | ascending
    // 'filter': "", // String | filter
    'orderBy': "update_date", // String | order_by
    'page': 0, // Number | page
    'size': 25 // Number | size
};

var stagelist = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.getStageAllUsingGet(opts, stagelist)

Example Response

{
    "content": [
        {
            "id": "099961da-7f41-4309-950f-2b51689a0033",
            "create_date": "2018-02-08T16:59:27.000+0000",
            "update_date": "2018-02-08T16:59:27.000+0000",
            "name": "Started Application",
            "category": null,
            "order_index": 1,
            "application_id": "36f9cb66-88a9-4a1f-a305-338a0f0e0a57",
            "is_account": true,
            "is_client": false,
            "is_business": false,
            "is_converted": false,
            "is_verified": false,
            "is_closed": false,
            "is_active": true,
            "metadata": {},
            "secondary_id": null
        },
        {
            "id": "1d7e1aad-3c79-49fe-bbb9-bd5e239ae1e7",
            "create_date": "2018-02-08T16:59:27.000+0000",
            "update_date": "2018-02-08T16:59:27.000+0000",
            "name": "Customized Allocation",
            "category": null,
            "order_index": 2,
            "application_id": "36f9cb66-88a9-4a1f-a305-338a0f0e0a57",
            "is_account": true,
            "is_client": false,
            "is_business": false,
            "is_converted": false,
            "is_verified": false,
            "is_closed": false,
            "is_active": true,
            "metadata": {},
            "secondary_id": null
        },
        {
            "id": "2a7a6cb7-ef71-4fe8-9169-2678f3799657",
            "create_date": "2018-02-08T16:59:27.000+0000",
            "update_date": "2018-02-08T16:59:27.000+0000",
            "name": "Funding Submitted",
            "category": null,
            "order_index": 3,
            "application_id": "36f9cb66-88a9-4a1f-a305-338a0f0e0a57",
            "is_account": true,
            "is_client": false,
            "is_business": false,
            "is_converted": false,
            "is_verified": false,
            "is_closed": false,
            "is_active": true,
            "metadata": {},
            "secondary_id": null
        },
        {
            "id": "647c54c3-b649-477e-8cc7-eee56a120dd3",
            "create_date": "2018-02-08T16:59:27.000+0000",
            "update_date": "2018-02-08T16:59:27.000+0000",
            "name": "Signed Up",
            "category": null,
            "order_index": 4,
            "application_id": "36f9cb66-88a9-4a1f-a305-338a0f0e0a57",
            "is_account": true,
            "is_client": false,
            "is_business": false,
            "is_converted": false,
            "is_verified": false,
            "is_closed": false,
            "is_active": true,
            "metadata": {},
            "secondary_id": null
        },
        {
            "id": "a65929b6-b0a9-46e5-858a-121f0b10f4fb",
            "create_date": "2018-02-08T16:59:27.000+0000",
            "update_date": "2018-02-08T16:59:27.000+0000",
            "name": "Application Accepted",
            "category": null,
            "order_index": 5,
            "application_id": "36f9cb66-88a9-4a1f-a305-338a0f0e0a57",
            "is_account": true,
            "is_client": false,
            "is_business": false,
            "is_converted": false,
            "is_verified": true,
            "is_closed": false,
            "is_active": true,
            "metadata": {},
            "secondary_id": null
        },
        {
            "id": "bab849d6-de96-4dc7-a5ea-19be45c52a4e",
            "create_date": "2018-02-08T16:59:27.000+0000",
            "update_date": "2018-02-08T16:59:27.000+0000",
            "name": "Funding in Progress",
            "category": null,
            "order_index": 6,
            "application_id": "36f9cb66-88a9-4a1f-a305-338a0f0e0a57",
            "is_account": true,
            "is_client": false,
            "is_business": false,
            "is_converted": false,
            "is_verified": false,
            "is_closed": false,
            "is_active": true,
            "metadata": {},
            "secondary_id": null
        },
        {
            "id": "e995d4c1-f989-4733-9867-713966ac9856",
            "create_date": "2018-02-08T16:59:27.000+0000",
            "update_date": "2018-02-08T16:59:27.000+0000",
            "name": "Funded & Awaiting Investment",
            "category": null,
            "order_index": 7,
            "application_id": "36f9cb66-88a9-4a1f-a305-338a0f0e0a57",
            "is_account": true,
            "is_client": false,
            "is_business": false,
            "is_converted": false,
            "is_verified": false,
            "is_closed": false,
            "is_active": true,
            "metadata": {},
            "secondary_id": null
        },
        {
            "id": "eb3d7f60-a133-4ca9-815f-3677bcdc23a3",
            "create_date": "2018-02-08T16:59:27.000+0000",
            "update_date": "2018-02-08T16:59:27.000+0000",
            "name": "Application Submitted",
            "category": null,
            "order_index": 8,
            "application_id": "36f9cb66-88a9-4a1f-a305-338a0f0e0a57",
            "is_account": true,
            "is_client": false,
            "is_business": false,
            "is_converted": false,
            "is_verified": false,
            "is_closed": false,
            "is_active": true,
            "metadata": {},
            "secondary_id": null
        },
        {
            "id": "fbc03484-08e8-446d-83aa-6d6cc236355e",
            "create_date": "2018-02-08T16:59:27.000+0000",
            "update_date": "2018-02-08T16:59:27.000+0000",
            "name": "Converted",
            "category": null,
            "order_index": 9,
            "application_id": "36f9cb66-88a9-4a1f-a305-338a0f0e0a57",
            "is_account": true,
            "is_client": false,
            "is_business": false,
            "is_converted": true,
            "is_verified": false,
            "is_closed": false,
            "is_active": true,
            "metadata": {},
            "secondary_id": null
        },
        {
            "id": "feb846da-a06d-402e-a3bb-abc7260f7138",
            "create_date": "2018-02-08T16:59:27.000+0000",
            "update_date": "2018-02-08T16:59:27.000+0000",
            "name": "Closed",
            "category": null,
            "order_index": 10,
            "application_id": "36f9cb66-88a9-4a1f-a305-338a0f0e0a57",
            "is_account": true,
            "is_client": false,
            "is_business": false,
            "is_converted": false,
            "is_verified": false,
            "is_closed": true,
            "is_active": true,
            "metadata": {},
            "secondary_id": null
        }
    ],
    "last": true,
    "total_pages": 1,
    "total_elements": 10,
    "sort": [
        {
            "direction": "DESC",
            "property": "updateDate",
            "ignore_case": false,
            "null_handling": "NATIVE",
            "descending": true,
            "ascending": false
        }
    ],
    "first": true,
    "number_of_elements": 10,
    "size": 25,
    "number": 0
}

Get the information for all possible account stages defined by your firm that can be assigned to accounts.

HTTP REQUEST

GET /stage

Create a stage

Example Request

curl -X POST -H "Authorization: Bearer 921c2e12-c3c3-4fe5-b8cc-2035d39ad44e" \
    -H "Content-Type: application/json" \
    -d '{
            "name": "Signed Up",
            "order_index": 1,
                        "application_id": "36f9cb66-88a9-4a1f-a305-338a0f0e0a57",
            "is_account": true
        }' "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/stage"
api_instance = nucleus_api.UtilsApi(nucleus_api.ApiClient(configuration))
# #Create Stage
stage = nucleus_api.Stage(name="new Stage")
try:
    api_response = api_instance.create_stage_using_post(stage)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling create_stage_using_post: %s\n" % e)
UtilsApi apiInstance = new UtilsApi();
//        //Create a Stage
        Stage stage = new Stage();
        stage.setName("New Stage");

        try {
            Stage result = apiInstance.createStageUsingPost(stage);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling createStageUsingPost");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\UtilsApi(
    new GuzzleHttp\Client(),
    $config);
//Create Stage
$stage = new \com\hydrogen\nucleus\Model\Stage();


try {
    $stage->setName("New Stage");
    $result = $apiInstance->createStageUsingPost($stage);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->createStageUsingPost: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::UtilsApi.new
#Create Stage
stage = NucleusApi::Stage.new

begin
  stage.name = "New"
  result = api_instance.create_stage_using_post(stage)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->create_stage_using_post: #{e}"
end
var apiInstance = new HydrogenNucleusApi.UtilsApi();
//Create a Stage
var stage = new HydrogenNucleusApi.Stage();
stage.name = "New";


var newstage = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.createStageUsingPost(stage, newstage)

Example Response

{
    "id": "647c54c3-b649-477e-8cc7-eee56a120dd3",
    "create_date": "2018-02-08T16:59:27.000+0000",
    "name": "Signed Up",
    "category": null,
    "order_index": 1,
    "application_id": "36f9cb66-88a9-4a1f-a305-338a0f0e0a57",
    "is_account": true,
    "is_client": false,
    "is_business": false,
    "is_converted": false,
    "is_verified": false,
    "is_closed": false,
    "is_active": true,
    "metadata": {},
    "secondary_id": null
}

Create and define an account stage that can subsequently be assigned to accounts. The name and description for the account stage must be provided. The endpoint returns the stage_id used to assign the stage to accounts.

HTTP REQUEST

POST /stage

ARGUMENTS

Parameter Type Required Description
name string required Name or label of the account stage such as “Signed Up” or “Application Signed”. Value must be unique across all stages.
category string optional Category of the stage to group stages together within a section of an app
description string optional Description of what the step along the registration process that the account stage represents
order_index integer optional Indicator for where along the process the account stage falls. Generally, the higher the order index, the further along the process
application_id UUID optional ID of the Application this stage belongs to
is_account boolean optional Indicates if the stage is for an account and used for tracking an Account Status. Defaults to false which indicates that it is not for an account
is_client boolean optional Indicates if the stage is for a client and used for tracking a Client Status. Defaults to false which indicates that it is not for a client
is_active boolean optional Indicates if the stage is active. Defaults to true which indicates that it is currently active.
is_business boolean optional Indicates if the stage is for a Business. Defaults to false which indicates that it is not for a business
is_converted boolean optional Indicates if the stage represents a converted account or client. Defaults to false which indicates that it is not converted
is_verified boolean optional Indicates if the stage represents a KYC verified account or client. Defaults to false which indicates that it is not verified
is_closed boolean optional Indicates if the stage represents a closed account or client. Defaults to false which indicates that it is not closed
metadata map optional Custom information associated with the entity in the format key:value
See Metadata
secondary_id string optional Alternate id that can be used to identify the object such as an internal id

Retrieve a stage

Example Request

curl -X GET -H "Authorization: Bearer 921c2e12-c3c3-4fe5-b8cc-2035d39ad44e" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/stage/647c54c3-b649-477e-8cc7-eee56a120dd3"
api_instance = nucleus_api.UtilsApi(nucleus_api.ApiClient(configuration))
try:
    api_response = api_instance.get_stage_using_get("2c362cf2-1ec1-4619-b207-41ca458cf3c0")
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_stage_using_get: %s\n" % e)
UtilsApi apiInstance = new UtilsApi();
        try {
            Stage responseStage = apiInstance.getStageUsingGet(UUID.fromString("f3cf73fe-fb25-43ad-8884-c3cbdbe0da62"));
            System.out.println(responseStage);
        } catch (ApiException e) {
            System.err.println("Exception when calling getStageUsingGet");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\UtilsApi(
    new GuzzleHttp\Client(),
    $config);
$stage_id = "f3cf73fe-fb25-43ad-8884-c3cbdbe0da62"; // string | UUID stage_id

try {
    $stage = $apiInstance->getStageUsingGet($stage_id);
    print_r($stage);
} catch (Exception $e) {
    echo 'Exception when calling UtilsApi->getStageUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::UtilsApi.new
stage_id = 'f3cf73fe-fb25-43ad-8884-c3cbdbe0da62' # String | UUID stage_id


begin
  stage = api_instance.get_stage_using_get(stage_id)
  p stage
rescue NucleusApi::ApiError => e
  puts "Exception when calling UtilsApi->get_stage_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.UtilsApi();
var stageID = "f3cf73fe-fb25-43ad-8884-c3cbdbe0da62";

var opts = {
    'currencyConversion': null, // String | USD
};

var stage = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.getStageUsingGet(stageID, stage)

Example Response

{
    "id": "647c54c3-b649-477e-8cc7-eee56a120dd3",
    "create_date": "2018-02-08T16:59:27.000+0000",
    "update_date": "2018-02-08T16:59:27.000+0000",
    "name": "Signed Up",
    "category": null,
    "order_index": 1,
    "application_id": "36f9cb66-88a9-4a1f-a305-338a0f0e0a57",
    "is_account": true,
    "is_client": false,
    "is_business": false,
    "is_converted": false,
    "is_verified": false,
    "is_closed": false,
    "is_active": true,
    "metadata": {},
    "secondary_id": null
}

Retrieve the information for a specific account stage that can be assigned to accounts. The unique stage_id must be provided. To obtain the appropriate stage_id, use the GET /stage endpoint to view all stages defined by your firm. The endpoint returns the account stage’s description and name.

HTTP REQUEST

GET /stage/{stage_id}

Update a stage

Example Request

curl -X PUT -H "Authorization: Bearer 921c2e12-c3c3-4fe5-b8cc-2035d39ad44e" \
    -H "Content-Type: application/json" \
    -d '{
            "name": "Signed Up",
            "description": "Initial information provided and client created",
            "order_index": 1
        }' "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/stage/647c54c3-b649-477e-8cc7-eee56a120dd3"
api_instance = nucleus_api.UtilsApi(nucleus_api.ApiClient(configuration))
# #Update Stage
stage_update = {'description': 'One'}
stage_id = '73b4c998-ec31-4ea3-b261-e8f9b91e3f2f'
try:
    api_response = api_instance.update_stage_using_put(stage_update, stage_id)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling update_stage_using_put: %s\n" % e)
UtilsApi apiInstance = new UtilsApi();
        //        //Update a Stage
        Map map2 = new HashMap();
        map2.put("is_active", "false");

        try {
            Stage response = apiInstance.updateStageUsingPut(map2, UUID.fromString("5b412947-dfdf-400a-85db-f95d647398bc"));
            System.out.println(response);
        } catch (ApiException e) {
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\UtilsApi(
    new GuzzleHttp\Client(),
    $config);
//Update Stage
$stage_update = new stdClass();
$stage_id = "b2209928-5d55-4304-98c1-73024b89ec4c";

try {
    $stage_update->name = "ABC";
    $result = $apiInstance->updateStageUsingPut($stage_update, $stage_id);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->updateStageUsingPut: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::UtilsApi.new
#Update Stage
stage_update = {"name" => 'CAD'}
stage_id = '5b412947-dfdf-400a-85db-f95d647398bc'
begin
  result = api_instance.update_stage_using_put(stage_update, stage_id)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->update_stage_using_put: #{e}"
end
var apiInstance = new HydrogenNucleusApi.UtilsApi();
//Update Stage
var apiInstance = new HydrogenNucleusApi.UtilsApi();
var callback = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
var stageupdate = new HydrogenNucleusApi.Stage();
var stageid = 'cea20d96-6cde-4e5a-8607-76e98d98e6d4';

stageupdate.category = "New";
apiInstance.updateStageUsingPut(stageupdate, stageid, callback)

Example Response

{
    "id": "647c54c3-b649-477e-8cc7-eee56a120dd3",
    "create_date": "2018-02-08T16:59:27.000+0000",
    "update_date": "2018-02-08T16:59:27.000+0000",
    "name": "Signed Up",
    "category": null,
    "description": "Initial information provided and client created",
    "order_index": 1,
    "application_id": "36f9cb66-88a9-4a1f-a305-338a0f0e0a57",
    "is_account": true,
    "is_client": false,
    "is_business": false,
    "is_converted": false,
    "is_verified": false,
    "is_closed": false,
    "is_active": true,
    "metadata": {},
    "secondary_id": null
}

Update the information for an account stage. The unique stage_id must be provided. To obtain the appropriate stage_id, use the GET /stage endpoint to view all stages defined by your firm and their current information. The stage’s new description and name must also be provided. The endpoint returns the stage_id and details for the account stage.

HTTP REQUEST

PUT /stage/{stage_id}

Delete a stage

Example Request

curl -X DELETE -H "Authorization: Bearer 921c2e12-c3c3-4fe5-b8cc-2035d39ad44e" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/stage/647c54c3-b649-477e-8cc7-eee56a120dd3"
api_instance = nucleus_api.UtilsApi(nucleus_api.ApiClient(configuration))
# # #Delete a Stage
stage1_id = 'd75b256a-771c-498a-8148-c923627c2f5f'

try:
    api_instance.delete_stage_using_delete(stage1_id)
except ApiException as e:
    print("Exception when calling delete_stage_using_delete: %s\n" % e)
UtilsApi apiInstance = new UtilsApi();
        //Delete a Stage
        try {
            Stage deleteresponse = apiInstance.deleteStageUsingDelete(UUID.fromString("dffce63f-d0a9-46c5-9d9e-bd07861af4f0"));
            System.out.println(deleteresponse);
        } catch (ApiException e) {
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\UtilsApi(
    new GuzzleHttp\Client(),
    $config);
//Delete Stage
$stage_did = "405804c9-a2f8-4f97-ab3f-ca15fa3f03f5"; // string | UUID account_id

try {
    $apiInstance->deleteStageUsingDelete($stage_did);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->deleteStageUsingDelete: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::UtilsApi.new
#Delete Stage
stage1_id = 'b2209928-5d55-4304-98c1-73024b89ec4c'
begin
  result = api_instance.delete_stage_using_delete(stage1_id)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->delete_stage_using_delete: #{e}"
end
var apiInstance = new HydrogenNucleusApi.UtilsApi();
//Delete a Stage
var stageidd = "b2209928-5d55-4304-98c1-73024b89ec4c";


var deletestage = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully.');
    }
};
apiInstance.deleteStageUsingDelete(stageidd, deletestage)

Response (204 No Content)

Permanently delete an account stage. The unique stage_id must be provided. To obtain the appropriate stage_id, use the GET /stage endpoint to view all stages defined by your firm. This deletes the stage_id and the stage will no longer be able to be assigned to an account as their account status

HTTP REQUEST

DELETE /stage/{stage_id}

Transaction Code

Transaction codes are defined by your firm to identify the type of transaction for all transaction and order records. These codes should be pre-populated for your tenant before performing any transactional related services and should match the codes that are expected by your back office. Examples of generic transactions codes include “Customer Payment” or “Cash Dividend”. Transaction codes also indicate whether a record is a buy transaction or a sell transaction for investment orders.

Field Type Description
id UUID The id of the transaction code
transaction_code string Code that identifies the transaction within your firm
transaction_code_description string Short description of the transaction code
transaction_type string Type of transaction code such as “Fee” or “Deposit”
category string Grouping of similar transaction codes
subcategory string Sub-grouping of similar transaction codes
is_buy boolean Indicates if the transaction is to buy securities. Defaults to null. Used for order generation and rebalancing of investment transactions. If a non-investment transaction then ignore this field.
is_fee boolean Indicates if the transaction is a fee. Defaults to null
is_transfer boolean Indicates if the transaction is a cash transfer in or out of an account. Defaults to null
is_deposit boolean Indicates if the transaction is a deposit or withdrawal. Defaults to null
metadata map Custom information associated with the entity in the format key:value
See Metadata
secondary_id string Alternate id that can be used to identify the object such as an internal id
create_date timestamp Timestamp for the date and time that the record was created
update_date timestamp Timestamp for the date and time that the record was last updated

List all transaction codes

Example Request

curl -X GET -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/transaction_code"
api_instance = nucleus_api.UtilsApi(nucleus_api.ApiClient(configuration))
try:
    api_response = api_instance.get_transaction_code_all_using_get()
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_transaction_code_all_using_get: %s\n" % e)
UtilsApi apiInstance = new UtilsApi();
        try {
            PageTransactionCode List = apiInstance.getTransactionCodeAllUsingGet(true, null, null, 0, 10);
            System.out.println(List);
        } catch (ApiException e) {
            System.err.println("Exception when calling getTransactionCodeAllUsingGet");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\UtilsApi(
    new GuzzleHttp\Client(),
    $config);
$ascending = false; // bool | ascending
$filter = null; // string | filter
$order_by = null; // string | order_by
$page = 0; // int | page
$size = 10; // int | size

try {
    $transactioncodelist = $apiInstance->getTransactionCodeAllUsingGet($ascending, $filter, $order_by, $page, $size);
    print_r($transactioncodelist);
} catch (Exception $e) {
    echo 'Exception when calling UtilsApi->getTransactionCodeAllUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::UtilsApi.new
opts = {
    ascending: false, # BOOLEAN | ascending
    filter: null, # String | filter
    order_by: null, # String | order_by
    page: 0, # Integer | page
    size: 25 # Integer | size
}

begin
  transactioncodelist = api_instance.get_transaction_code_all_using_get(opts)
  p transactioncodelist
rescue NucleusApi::ApiError => e
  puts "Exception when calling UtilsApi->get_transaction_code_all_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.UtilsApi();
var opts = {
    'ascending': false, // Boolean | ascending
    // 'filter': "", // String | filter
    'orderBy': "update_date", // String | order_by
    'page': 0, // Number | page
    'size': 25 // Number | size
};

var transactionlist = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.getTransactionCodeAllUsingGet(opts, transactionlist)

Example Response

{
    "content": [
        {
            "id": "099961da-7f41-4309-950f-2b51689a0033",
            "transaction_code": "CR",
            "transaction_code_description": "Check Returned",
            "transaction_type": "Client Deposits",
            "category": "Deposits",
            "subcategory": "Cash",
            "is_buy": true,
            "is_fee": null,
            "is_transfer": null,
            "is_deposit": null,
            "secondary_id": null,
            "metadata": {}
        },
        {
            "id": "1d7e1aad-3c79-49fe-bbb9-bd5e239ae1e7",
            "transaction_code": "BP",
            "transaction_code_description": "Bill Pay",
            "transaction_type": "Client Deposits",
            "category": "Deposits",
            "subcategory": "Cash",
            "is_buy": true,
            "is_fee": null,
            "is_transfer": null,
            "is_deposit": null,
            "secondary_id": null,
            "metadata": {}
        },
        {
            "id": "2a7a6cb7-ef71-4fe8-9169-2678f3799657",
            "transaction_code": "WR",
            "transaction_code_description": "Wire Returned",
            "transaction_type": "Client Deposits",
            "category": "Deposits",
            "subcategory": "Cash",
            "is_buy": true,
            "is_fee": null,
            "is_transfer": null,
            "is_deposit": null,
            "secondary_id": null,
            "metadata": {}
        }
    ],
    "last": true,
    "total_pages": 1,
    "total_elements": 3,
    "sort": [
        {
            "direction": "DESC",
            "property": "",
            "ignore_case": false,
            "null_handling": "NATIVE",
            "descending": true,
            "ascending": false
        }
    ],
    "first": true,
    "number_of_elements": 17,
    "size": 25,
    "number": 0
}

Get the information for all transaction codes defined by your firm. The endpoint returns a list of ids and details for each transaction code. You can use this endpoint to determine the appropriate transaction code to use when creating a transaction record.

HTTP REQUEST

GET /transaction_code

Create a transaction code

Example Request

curl -X POST -H "Authorization: Bearer <access_token>" \
     -H "Content-Type: application/json" \
     -d '{
            "transaction_code": "CDEP-1",
            "transaction_code_description": "Check Returned",
            "category": "Deposits",
            "subcategory": "Cash",
            "is_buy": true
        }' "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/transaction_code"
api_instance = nucleus_api.UtilsApi(nucleus_api.ApiClient(configuration))
# #Create TransactionCode
transaction_code = nucleus_api.TransactionCode(transaction_code="New")
try:
    api_response = api_instance.create_transaction_code_using_post(transaction_code)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling create_transaction_code_using_post: %s\n" % e)
UtilsApi apiInstance = new UtilsApi();
        //Create a Transaction Code
        TransactionCode transaction = new TransactionCode();
        transaction.setTransactionCode("New One");

        try {
            TransactionCode result = apiInstance.createTransactionCodeUsingPost(transaction);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling createTransactionCodeUsingPost");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\UtilsApi(
    new GuzzleHttp\Client(),
    $config);
//Create Transaction Code
$transaction_code = new \com\hydrogen\nucleus\Model\TransactionCode();


try {
    $transaction_code->setTransactionCode("ABC");
    $result = $apiInstance->createTransactionCodeUsingPost($transaction_code);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->createTransactionCodeUsingPost: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::UtilsApi.new
#Create Transaction Code
transaction_code = NucleusApi::TransactionCode.new

begin
  transaction_code.category = "Email"
  result = api_instance.create_transaction_code_using_post(transaction_code)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->create_transaction_code_using_post: #{e}"
end
var apiInstance = new HydrogenNucleusApi.UtilsApi();
// //Create a Transaction code
var tcode = new HydrogenNucleusApi.TransactionCode();
tcode.transaction_code = "New One";



var newtransactioncode = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.createTransactionCodeUsingPost(tcode, newtransactioncode)

Example Response

{
    "id": "099961da-7f41-4309-950f-2b51689a0033",
    "transaction_code": "CDEP-1",
    "transaction_code_description": "Check Returned",
    "transaction_type": null,
    "category": "Deposits",
    "subcategory": "Cash",
    "is_buy": true,
    "is_fee": null,
    "is_transfer": null,
    "is_deposit": null,
    "secondary_id": null,
    "metadata": {}
}

Create a new transaction code for your tenant. You must provide the details for the transaction code, including the indicator for whether or not it represents a buy transaction which is used when carrying out orders. The endpoint returns a unique identifier for the transaction code that can be referenced when creating order records.

HTTP REQUEST

POST /transaction_code

ARGUMENTS

Parameter Type Required Description
transaction_code string required Code that identifies the transaction within your firm
transaction_code_description string optional Short description of the transaction code
transaction_type string optional Type of transaction code such as “Fee” or “Deposit”
category string optional Grouping of similar transaction codes
subcategory string optional Sub-grouping of similar transaction codes
is_buy boolean optional Indicates if the transaction is to buy securities. Defaults to null. Used for order generation and rebalancing of investment transactions. If a non-investment transaction then ignore this field.
is_fee boolean optional Indicates if the transaction is a fee. Defaults to null
is_transfer boolean optional Indicates if the transaction is a cash transfer in or out of an account. Defaults to null
is_deposit boolean optional Indicates if the transaction is a deposit or withdrawal. Defaults to null
metadata map optional Custom information associated with the entity in the format key:value
See Metadata
secondary_id string optional Alternate id that can be used to identify the object such as an internal id

Retrieve a transaction code

Example Request

curl -X GET -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/transaction_code/099961da-7f41-4309-950f-2b51689a0033"
api_instance = nucleus_api.UtilsApi(nucleus_api.ApiClient(configuration))
try:
    api_response = api_instance.get_transaction_code_using_get("6070cedc-0259-4a7c-ada9-61ac7cd27551")
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_transaction_code_using_get: %s\n" % e)
UtilsApi apiInstance = new UtilsApi();
        try {
            TransactionCode responseTransactionCode = apiInstance.getTransactionCodeUsingGet(UUID.fromString("19a5bf92-a800-4a38-8e4f-de9b05517d8c"));
            System.out.println(responseTransactionCode);
        } catch (ApiException e) {
            System.err.println("Exception when calling getTransactionCodeUsingGet");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\UtilsApi(
    new GuzzleHttp\Client(),
    $config);
$transaction_code_id = "19a5bf92-a800-4a38-8e4f-de9b05517d8c"; // string | UUID transaction_code_id

try {
    $transactioncode = $apiInstance->getTransactionCodeUsingGet($transaction_code_id);
    print_r($transactioncode);
} catch (Exception $e) {
    echo 'Exception when calling UtilsApi->getTransactionCodeUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::UtilsApi.new
transaction_code_id = '19a5bf92-a800-4a38-8e4f-de9b05517d8c' # String | UUID transaction_code_id


begin
  transactioncode = api_instance.get_transaction_code_using_get(transaction_code_id)
  p transactioncode
rescue NucleusApi::ApiError => e
  puts "Exception when calling UtilsApi->get_transaction_code_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.UtilsApi();
var transactioncodeID = "19a5bf92-a800-4a38-8e4f-de9b05517d8c";

var opts = {
    'currencyConversion': null, // String | USD
};

var transaction = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.getTransactionCodeUsingGet(transactioncodeID, transaction)

Example Response

{
    "id": "099961da-7f41-4309-950f-2b51689a0033",
    "transaction_code": "CDEP-1",
    "transaction_code_description": "Check Returned",
    "transaction_type": "Client Deposits",
    "category": "Deposits",
    "subcategory": "Cash",
    "is_buy": true,
    "is_fee": null,
    "is_transfer": null,
    "is_deposit": null,
    "secondary_id": null,
    "metadata": {}
}

Retrieve the information for a transaction code defined by your firm. The transacation_code_id must be provided. The endpoint returns the details for the transaction code specified.

HTTP REQUEST

GET /transaction_code/{transaction_code_id}

Update a transaction code

Example Request

curl -X PUT -H "Authorization: Bearer <access_token>" \
     -H "Content-Type: application/json" \
     -d '{
            "transaction_code": "CDEP-1",
            "transaction_code_description": "Check Returned",
            "transaction_type": "Check Returned",
            "category": "Deposits",
            "subcategory": "Cash",
            "is_buy": true
        }' "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/transaction_code/099961da-7f41-4309-950f-2b51689a0033"
api_instance = nucleus_api.UtilsApi(nucleus_api.ApiClient(configuration))
# #Update TransactionCode
transaction_code_update = {'is_fee': 'true'}
transaction_code_id = 'a8a64be8-6b83-4066-bd95-7497d9ca1188'
try:
    api_response = api_instance.update_transaction_code_using_put(transaction_code_update, transaction_code_id)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling update_transaction_code_using_put: %s\n" % e)
UtilsApi apiInstance = new UtilsApi();
                //Update a TransactionCode
        Map map1 = new HashMap();
        map1.put("is_deposit", "null");

        try {
            TransactionCode response = apiInstance.updateTransactionCodeUsingPut(map1, UUID.fromString("a84c34ac-7a90-414c-83ed-7deb3a08a7a4"));
            System.out.println(response);
        } catch (ApiException e) {
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\UtilsApi(
    new GuzzleHttp\Client(),
    $config);
//Update Transaction code
$tcode_update = new stdClass();
$tcode_id = "e658a046-8a66-4bfa-b990-b225fa1652c0";

try {
    $tcode_update->transaction_code = "New";
    $result = $apiInstance->updateTransactionCodeUsingPut($tcode_update, $tcode_id);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->updateTransactionCodeUsingPut: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::UtilsApi.new
#Update Transaction Code
transaction_code_update = {"category" => 'CAD'}
transaction_code_id = '81cc4f23-4717-4fad-8079-add9e6be7a9c'
begin
  result = api_instance.update_transaction_code_using_put(transaction_code_update, transaction_code_id)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->update_transaction_code_using_put: #{e}"
end
var apiInstance = new HydrogenNucleusApi.UtilsApi();
// //Update Transaction Code
var apiInstance = new HydrogenNucleusApi.UtilsApi();
var callback = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
var transactioncodeupdate = new HydrogenNucleusApi.TransactionCode();
var tcodeid = '18b2d614-912e-42bb-8479-c3854debaa39';

transactioncodeupdate.category = "New";
apiInstance.updateTransactionCodeUsingPut(transactioncodeupdate, tcodeid, callback)

Example Response

{
    "id": "099961da-7f41-4309-950f-2b51689a0033",
    "transaction_code": "CDEP-1",
    "transaction_code_description": "Check Returned",
    "transaction_type": "Client Deposits",
    "category": "Deposits",
    "subcategory": "Cash",
    "is_buy": true,
    "is_fee": null,
    "is_transfer": null,
    "is_deposit": null,
    "secondary_id": null,
    "metadata": {}
}

Update a transaction code for your tenant. The transaction_code_id must be provided. To obtain the appropriate transaction_code_id, use the GET /transaction_code endpoint to view all the transaction codes defined for your tenant and their current information. The details to be updated must also be provided. The endpoint returns the transaction_code_id and all details for the transaction code.

HTTP REQUEST

PUT /transaction_code/{transaction_code_id}

Delete a transaction code

Example Request

curl -X DELETE -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/transaction_code/099961da-7f41-4309-950f-2b51689a0033"
api_instance = nucleus_api.UtilsApi(nucleus_api.ApiClient(configuration))
# # # #Delete a Transactioncode
transaction_code1_id = '8a2d401a-f276-4317-92d2-bee047da55d7'
try:
    api_instance.delete_transaction_code_using_delete(transaction_code1_id)
except ApiException as e:
    print("Exception when calling delete_transaction_code_using_delete: %s\n" % e)
UtilsApi apiInstance = new UtilsApi();
        //Delete a transactionCode
        try {
            TransactionCode deleteresponse = apiInstance.deleteTransactionCodeUsingDelete(UUID.fromString("6216575c-c171-4982-bb81-d496573776a9"));
            System.out.println(deleteresponse);
        } catch (ApiException e) {
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\UtilsApi(
    new GuzzleHttp\Client(),
    $config);

//Delete Transaction Code
$tcode_did = "6917d21a-7d0d-48e8-aea6-cdc5ebe724e1"; // string | UUID account_id

try {
    $apiInstance->deleteTransactionCodeUsingDelete($tcode_did);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->deleteTransactionCodeUsingDelete: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::UtilsApi.new
#Delete transaction Code
transaction_code1_id = 'a8a64be8-6b83-4066-bd95-7497d9ca1188'
begin
  result = api_instance.delete_transaction_code_using_delete(transaction_code1_id)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->delete_transaction_code_using_delete: #{e}"
end
var apiInstance = new HydrogenNucleusApi.UtilsApi();
// // //Delete a TransactionCode
var tcodeidd = "6917d21a-7d0d-48e8-aea6-cdc5ebe724e1";


var deletetransactioncode = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully.');
    }
};
apiInstance.deleteTransactionCodeUsingDelete(tcodeidd, deletetransactioncode)

Response (204 No Content)

Permanently delete a transaction code for your tenant. The transaction_code_id must be provided. To obtain the appropriate transaction_code_id, use the GET /transaction_code endpoint to view all the transaction codes defined for your tenant. Deletes the transaction_code_id and the transaction code information so that it can no longer be assigned to transaction records.

HTTP REQUEST

DELETE /transaction_code/{transaction_code_id}

Tracking

Feature

Create a feature that you wish to track usage within an application. This may be an entire module, page, section, or button.

Field Type Description
id UUID The id of the application
feature_name string The name of the feature to be tracked
page_name string The name of the page or URL that the feature is displayed on
category string Category grouping that the feature falls under
subcategory string Category grouping that the feature falls under the category
application_id UUID ID of the Application this feature belongs to
is_active boolean Indicates if the feature is active. Defaults to true which indicates that the feature is active
metadata map Custom information associated with the feature in the format key:value
See Metadata
secondary_id string Alternate id that can be used to identify the object such as an internal id
create_date timestamp Timestamp for the date and time that the feature was created
update_date timestamp Timestamp for the date and time that the feature was last updated

List all features

Example Request

curl -X GET -H "Authorization: Bearer <access_token>" \
  "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/feature"
api_instance = nucleus_api.UtilsApi(nucleus_api.ApiClient(configuration))
# List all Feature
try:
    api_response = api_instance.get_feature_all_using_get()
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_feature_all_using_get: %s\n" % e)
UtilsApi apiInstance = new UtilsApi();
                //List all Feature
        try {
            PageFeature List = apiInstance.getFeatureAllUsingGet(true, null, null, 0, 10);
            System.out.println(List);
        } catch (ApiException e) {
            System.err.println("Exception when calling getFeatureAllUsingGet");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\UtilsApi(
    new GuzzleHttp\Client(),
    $config);
//List all Feature
$ascending = false; // bool | ascending
$filter = null; // string | filter
$order_by = null; // string | order_by
$page = 0; // int | page
$size = 10; // int | size

try {
    $featurelist = $apiInstance->getFeatureAllUsingGet($ascending, $filter, $order_by, $page, $size);
    print_r($featurelist);
} catch (Exception $e) {
    echo 'Exception when calling FeatureApi->getFeatureAllUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::UtilsApi.new
#List all Feature
opts = {
  ascending: false, # BOOLEAN | ascending
  filter: null, # String | filter
  order_by: null, # String | order_by
  page: 0, # Integer | page
  size: 25 # Integer | size
}

begin
  result = api_instance.get_feature_all_using_get(opts)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling FeatureApi->get_feature_all_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.UtilsApi();
//List all Feature

var opts = {
    'ascending': false, // Boolean | ascending
    // 'filter': "", // String | filter
    'orderBy': "update_date", // String | order_by
    'page': 0, // Number | page
    'size': 25 // Number | size
};

var featurelist = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.getFeatureAllUsingGet(opts, featurelist)

Example Response

{
    "content": [
        {
            "id": "18835a6c-29fb-4467-8cad-e1b91456e5a3",
            "feature_name": "Dashboard",
            "page_name": "dashboard-home",
            "category": "Overview",
            "subcategory": null,
            "application_id": null,
            "is_active": true,
            "metadata": {},
            "secondary_id": null,
            "create_date": "2019-10-29T06:43:36.000+0000",
            "update_date": "2019-10-29T07:13:41.000+0000"
        },
        {
            "id": "dc7fffb1-c39b-4181-af91-f86755b2e63b",
            "feature_name": "Investment Analytics",
            "page_name": "investment-analytics",
            "category": "Analytics",
            "subcategory": Investment,
            "application_id": null,
            "is_active": true,
            "metadata": {},
            "secondary_id": null,
            "create_date": "2019-10-29T06:43:08.000+0000",
            "update_date": "2019-10-29T06:43:08.000+0000"
        }
      ],
    "total_elements": 2,
    "last": true,
    "total_pages": 1,
    "sort": [
        {
            "direction": "DESC",
            "property": "updateDate",
            "ignore_case": false,
            "null_handling": "NATIVE",
            "descending": true,
            "ascending": false
        }
    ],
    "first": true,
    "number_of_elements": 2,
    "size": 25,
    "number": 0
}

Get all the features defined for your firm.

HTTP REQUEST

GET /feature

Create a feature

Example Request

curl -X POST -H "Authorization: Bearer <access_token>" \
    -H "Content-Type: application/json" \
    -d '{
          "feature_name": "Dashboard",
          "page_name": "dashboard-home",
          "category": "Overview"
        }' "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/feature"
api_instance = nucleus_api.UtilsApi(nucleus_api.ApiClient(configuration))
#Create Feature
feature = nucleus_api.Feature(feature_name="New Feature", category="New", page_name="One")
try:
    api_response = api_instance.create_feature_using_post(feature)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling create_feature_using_post: %s\n" % e)
UtilsApi apiInstance = new UtilsApi();
          //Create a Feature
        Feature addfeature = new Feature();
        addfeature.setFeatureName("Feature One");
        addfeature.setCategory("New");
        addfeature.setPageName("A");

        try {
            Feature result = apiInstance.createFeatureUsingPost(addfeature);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling createFeatureUsingPost");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\UtilsApi(
    new GuzzleHttp\Client(),
    $config);
//Create Feature
$feature = new \com\hydrogen\nucleus\Model\Feature();


try {
    $feature->setFeatureName("New");
    $feature->setPageName("One");
    $feature->setCategory("New");
    $result = $apiInstance->createFeatureUsingPost($feature);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->createFeatureUsingPost: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::UtilsApi.new
#Create Feature
feature = NucleusApi::Feature.new

begin
  feature.feature_name = "One"
  feature.page_name = "one"
  feature.category = "A"
  result = api_instance.create_feature_using_post(feature)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->create_feature_using_post: #{e}"
end
var apiInstance = new HydrogenNucleusApi.UtilsApi();
// //Create a Feature
var feature = new HydrogenNucleusApi.Feature();
feature.feature_name = "ABC";
feature.page_name = "New";
feature.category = "A1";



var newfeature = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.createFeatureUsingPost(feature, newfeature)

Example Response

{
  "id": "a7790d62-dcca-46de-8d7c-636d08d6835b",
  "feature_name": "Dashboard",
  "page_name": "dashboard-home",
  "category": "Overview",
  "subcategory": null,
  "application_id": null,
  "is_active": true,
  "metadata": {},
  "secondary_id": "39634861",
  "create_date": "2019-10-29T05:49:06.000+0000",
  "update_date": "2019-10-29T05:49:06.000+0000"
}

Create a feature for your firm. You must enter a feature_name for the feature. The endpoint returns a feature_id used to identify and manage the feature.

HTTP REQUEST

POST /feature

ARGUMENTS

Parameter Type Required Description
feature_name string required The name of the feature to be tracked
page_name string optional The name of the page or URL that the feature is displayed on
category string optional Category grouping that the feature falls under
subcategory string optional Category grouping that the feature falls under the category
application_id UUID optional ID of the Application this feature belongs to
is_active boolean optional Indicates if the feature is active. Defaults to true which indicates that the feature is active
metadata map optional Custom information associated with the feature in the format key:value
See Metadata
secondary_id string optional Alternate id that can be used to identify the object such as an internal id

Retrieve a feature

Example Request

curl -X GET -H "Authorization: Bearer <access_token>" \
  "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/feature/138125ed-53d9-41e9-a2b8-91c2c8575af0"
api_instance = nucleus_api.UtilsApi(nucleus_api.ApiClient(configuration))
# Retrieve a Feature
try:
    api_response = api_instance.get_feature_using_get("114f883d-de43-4d2c-b148-c764022e4f9b")
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_feature_using_get: %s\n" % e)
UtilsApi apiInstance = new UtilsApi();
        //Retrieve a Feature
        try {
            Feature responseFeature = apiInstance.getFeatureUsingGet(UUID.fromString("8523d620-e742-49ab-902f-e9d0009cbb7c"));
            System.out.println(responseFeature);
        } catch (ApiException e) {
            System.err.println("Exception when calling getFeatureUsingGet");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\UtilsApi(
    new GuzzleHttp\Client(),
    $config);
//Retrieve a Feature
$feature_id = "8523d620-e742-49ab-902f-e9d0009cbb7c"; // string | UUID feature_id

try {
    $feature = $apiInstance->getFeatureUsingGet($feature_id);
    print_r($feature);
} catch (Exception $e) {
    echo 'Exception when calling FeatureApi->getFeatureUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::UtilsApi.new
#Retrieve an Feature
feature_id = '8523d620-e742-49ab-902f-e9d0009cbb7c' # String | UUID feature_id

begin
  feature = api_instance.get_feature_using_get(feature_id)
  p feature
rescue NucleusApi::ApiError => e
  puts "Exception when calling FeatureApi->get_feature_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.UtilsApi();
//Retrieve an Feature

var featureid = "8523d620-e742-49ab-902f-e9d0009cbb7c";


var feature = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.getFeatureUsingGet(featureid, feature)

Example Response

{
  "id": "138125ed-53d9-41e9-a2b8-91c2c8575af0",
  "feature_name": "Dashboard",
  "page_name": "dashboard-home",
  "category": "Overview",
  "subcategory": null,
  "application_id": null,
  "is_active": true,
  "metadata": {},
  "secondary_id": "39634861",
  "create_date": "2019-10-18T10:02:04.000+0000",
  "update_date": "2019-10-18T10:23:48.000+0000"
}

Retrieve a feature for your firm. The feature_id must be provided. The endpoint returns the feature_id and the details for the feature specified.

HTTP REQUEST

GET /feature/{feature_id}

Update a feature

Example Request

curl -X PUT -H "Authorization: Bearer <access_token>" \
   -H "Content-Type: application/json" \
   -d '{
          "feature_name": "Account Dashboard"
        }' "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/feature/138125ed-53d9-41e9-a2b8-91c2c8575af0"
api_instance = nucleus_api.UtilsApi(nucleus_api.ApiClient(configuration))
# #Update Feature
feature_update = {'feature_name': 'Application'}
feature_id = '2ebcec8e-25ac-4624-a3dc-c64ddcec238b'
try:
    api_response = api_instance.update_feature_using_put(feature_update, feature_id)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling update_feature_using_put: %s\n" % e)
UtilsApi apiInstance = new UtilsApi();
//        //Update a Feature
        Map map = new HashMap();
        map.put("feature_name", "New ONe");

        try {
            Feature response = apiInstance.updateFeatureUsingPut(map, UUID.fromString("4f06f064-ec3e-4ea5-b3d0-b65c21aefcc9"));
            System.out.println(response);
        } catch (ApiException e) {
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\UtilsApi(
    new GuzzleHttp\Client(),
    $config);
//Update feature
$feature_update = new stdClass();
$feature_id = "90dae1d0-0858-4e2f-b7c5-379edecec5be";

try {
    $feature_update->category = "New";
    $result = $apiInstance->updateFeatureUsingPut($feature_update, $feature_id);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->updateFeatureUsingPut: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::UtilsApi.new
#Update feature
feature_update = {"category" => 'ABC'}
feature_id = '760162a7-2166-4b1c-a3a4-81271833de6a'
begin
  result = api_instance.update_feature_using_put(feature_update, feature_id)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->update_feature_using_put: #{e}"
end
var apiInstance = new HydrogenNucleusApi.UtilsApi();
// //Update Feature
var apiInstance = new HydrogenNucleusApi.UtilsApi();
var callback = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
var featureupdate = new HydrogenNucleusApi.Feature();
var featureid = 'd6c1b370-6934-40eb-acf2-e309b45101b2';

featureupdate.feature_name = "New";
apiInstance.updateFeatureUsingPut(featureupdate, featureid, callback)

Example Response

{
  "id": "138125ed-53d9-41e9-a2b8-91c2c8575af0",
  "feature_name": "Account Dashboard",
  "page_name": "dashboard-home",
  "category": "Overview",
  "subcategory": null,
  "application_id": null,
  "is_active": true,
  "metadata": {}
}

Update a feature for your firm. The feature_id must be provided. To obtain the appropriate feature_id, use the GET /feature endpoint to view all of the features for your firm and their current information. The details to be updated and the details to be maintained must also be provided. The endpoint returns the feature_id and the details for the feature.

HTTP REQUEST

PUT /feature/{feature_id}

Delete a feature

Example Request

curl -X DELETE -H "Authorization: Bearer <access_token>" \
  "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/feature/138125ed-53d9-41e9-a2b8-91c2c8575af0"
api_instance = nucleus_api.UtilsApi(nucleus_api.ApiClient(configuration))
# # #Delete a Feature
feature1_id = '55dac505-afe6-47fb-99f1-21cfd2c55a4d'

try:
    api_instance.delete_feature_using_delete(feature1_id)
except ApiException as e:
    print("Exception when calling delete_feature_using_delete: %s\n" % e)
UtilsApi apiInstance = new UtilsApi();
       //Delete a Feature
        try {
            Feature deleteresponse = apiInstance.deleteFeatureUsingDelete(UUID.fromString("d7c73e24-af17-4923-a205-e61cbba4bbbe"));
            System.out.println(deleteresponse);
        } catch (ApiException e) {
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\UtilsApi(
    new GuzzleHttp\Client(),
    $config);
//Delete Feature
$feature_did = "456563b2-fa88-48fd-ac94-94bf5805f546"; // string | UUID account_id

try {
    $apiInstance->deleteFeatureUsingDelete($feature_did);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->deleteFeatureUsingDelete: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::UtilsApi.new
#Delete Feature
feature1_id = '55dac505-afe6-47fb-99f1-21cfd2c55a4d'
begin
  result = api_instance.delete_feature_using_delete(feature1_id)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->delete_feature_using_delete: #{e}"
end
var apiInstance = new HydrogenNucleusApi.UtilsApi();
// // //Delete a Feature
var featureidd = "760162a7-2166-4b1c-a3a4-81271833de6a";


var deletefeature = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully.');
    }
};
apiInstance.deleteFeatureUsingDelete(featureidd, deletefeature)

Response (204 No Content)

Permanently delete a feature for your firm. The feature_id must be provided. To obtain the appropriate feature_id, use the GET /feature endpoint to view all of the features for your firm. This deletes the feature_id and the details for the feature record.

HTTP REQUEST

DELETE /feature/{feature_id}

Feature Track

The Feature Track service allows you to track, on an individual user basis, the usage of any feature that has been defined in the /feature ervice above by referencing its feature_id. A front end dev can link this endpoint to each feature, such that every time a user clicks on it/engages with it, a record of the feature usage is POSTed using this endpoint, by capturing the client_id and feature_id and appending the current timestamp to the request.

Field Type Description
id UUID The id of the application
feature_id string The id of the feature that was used
client_id string The id of the client who used the feature
metadata map Custom information associated with the feature track in the format key:value
See Metadata
secondary_id string Alternate id that can be used to identify the object such as an internal id
create_date timestamp Timestamp for the date and time that the feature track was created
update_date timestamp Timestamp for the date and time that the feature track was last updated

List all feature tracks

Example Request

curl -X GET -H "Authorization: Bearer <access_token>" \
  "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/feature_track"
api_instance = nucleus_api.UtilsApi(nucleus_api.ApiClient(configuration))
# List all FeatureTrack
try:
    api_response = api_instance.get_feature_track_all_using_get()
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_feature_track_all_using_get: %s\n" % e)
UtilsApi apiInstance = new UtilsApi();
        //List all FeatureTrack
        try {
            PageFeatureTrack List = apiInstance.getFeatureTrackAllUsingGet(true, null, null, 0, 10);
            System.out.println(List);
        } catch (ApiException e) {
            System.err.println("Exception when calling getFeatureTrackAllUsingGet");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\UtilsApi(
    new GuzzleHttp\Client(),
    $config);
//List all FeatureTrack
$ascending = false; // bool | ascending
$filter = null; // string | filter
$order_by = null; // string | order_by
$page = 0; // int | page
$size = 10; // int | size

try {
    $featuretracklist = $apiInstance->getFeatureTrackAllUsingGet($ascending, $filter, $order_by, $page, $size);
    print_r($featuretracklist);
} catch (Exception $e) {
    echo 'Exception when calling FeatureApi->getFeatureTrackAllUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::UtilsApi.new
#List all FeatureTrack
opts = {
  ascending: false, # BOOLEAN | ascending
  filter: null, # String | filter
  order_by: null, # String | order_by
  page: 0, # Integer | page
  size: 25 # Integer | size
}

begin
  featuretracklist = api_instance.get_feature_track_all_using_get(opts)
  p featuretracklist
rescue NucleusApi::ApiError => e
  puts "Exception when calling FeatureApi->get_feature_track_all_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.UtilsApi();
//List all FeatureTrack

var opts = {
    'ascending': false, // Boolean | ascending
    // 'filter': "", // String | filter
    'orderBy': "update_date", // String | order_by
    'page': 0, // Number | page
    'size': 25 // Number | size
};

var featuretracklist = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.getFeatureTrackAllUsingGet(opts, featuretracklist)

Example Response

{
    "content": [
        {
            "id": "097b8ca1-aca6-4c8f-a471-8a79d014c04e",
            "feature_id": "ac947838-165a-47b9-af8f-064032586c14",
            "client_id": "2d0268af-477e-4300-b971-0c19df64d254",
            "metadata": {},
            "secondary_id": null,
            "create_date": "2019-10-31T05:51:01.000+0000",
            "update_date": "2019-10-31T05:51:01.000+0000"
        },
        {
            "id": "284ef4b2-4d1b-4b4d-9db4-48cef641aec0",
            "feature_id": "a462803b-0739-4fde-b702-265196272619",
            "client_id": "2d0268af-477e-4300-b971-0c19df64d254",
            "metadata": {},
            "secondary_id": null,
            "create_date": "2019-10-31T05:31:00.000+0000",
            "update_date": "2019-10-31T05:31:00.000+0000"
        }
    ],
    "total_elements": 2,
    "last": true,
    "total_pages": 1,
    "sort": [
        {
            "direction": "DESC",
            "property": "updateDate",
            "ignore_case": false,
            "null_handling": "NATIVE",
            "descending": true,
            "ascending": false
        }
    ],
    "first": true,
    "number_of_elements": 2,
    "size": 25,
    "number": 0
}

Get all the feature track records for your firm or filter by the client_id or feature_id.

HTTP REQUEST

GET /feature_track

Create a feature track

Example Request

curl -X POST -H "Authorization: Bearer <access_token>" \
    -H "Content-Type: application/json" \
    -d '{
          "feature_id": "a462803b-0739-4fde-b702-265196272619",
          "client_id": "2d0268af-477e-4300-b971-0c19df64d254"
        }' "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/feature_track"
api_instance = nucleus_api.UtilsApi(nucleus_api.ApiClient(configuration))
# #Create FeatureTrack
feature_track = nucleus_api.FeatureTrack(client_id="1d68e4ca-77a4-4cff-b304-5bced0b41e87", feature_id="a462803b-0739-4fde-b702-265196272619")
try:
    api_response = api_instance.create_feature_track_using_post(feature_track)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling create_feature_track_using_post: %s\n" % e)
UtilsApi apiInstance = new UtilsApi();
                //Create a Feature Track

        FeatureTrack addfeaturetrack = new FeatureTrack();
        addfeaturetrack.setClientId(UUID.fromString("1d68e4ca-77a4-4cff-b304-5bced0b41e87"));
        addfeaturetrack.setFeatureId(UUID.fromString("a462803b-0739-4fde-b702-265196272619"));

                try {
            FeatureTrack result = apiInstance.createFeatureTrackUsingPost(addfeaturetrack);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling createFeatureTrackUsingPost");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\UtilsApi(
    new GuzzleHttp\Client(),
    $config);
//Create FeatureTrack
$feature_track = new \com\hydrogen\nucleus\Model\FeatureTrack();


try {
    $feature_track->setClientId("1d68e4ca-77a4-4cff-b304-5bced0b41e87");
    $feature_track->setFeatureId("a462803b-0739-4fde-b702-265196272619");
    $result = $apiInstance->createFeatureTrackUsingPost($feature_track);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->createFeatureTrackUsingPost: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::UtilsApi.new

#Create Feature Track
feature_track = NucleusApi::FeatureTrack.new

begin
  feature_track.client_id = "1d68e4ca-77a4-4cff-b304-5bced0b41e87"
  feature_track.feature_id = "1d68e4ca-77a4-4cff-b304-5bced0b41e87"
  result = api_instance.create_feature_track_using_post(feature_track)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->create_feature_track_using_post: #{e}"
end
var apiInstance = new HydrogenNucleusApi.UtilsApi();
//Create a FeatureTrack
var featuretrack = new HydrogenNucleusApi.FeatureTrack();
featuretrack.client_id = '1d68e4ca-77a4-4cff-b304-5bced0b41e87';
featuretrack.feature_id = 'a462803b-0739-4fde-b702-265196272619';

var newfeaturetrack = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.createFeatureTrackUsingPost(featuretrack, newfeaturetrack)

Example Response

{
  "id": "a7790d62-dcca-46de-8d7c-636d08d6835b",
  "feature_id": "a462803b-0739-4fde-b702-265196272619",
  "client_id": "2d0268af-477e-4300-b971-0c19df64d254",
  "metadata": {},
  "secondary_id": null,
  "create_date": "2019-10-29T05:49:06.000+0000",
  "update_date": "2019-10-29T05:49:06.000+0000"
}

Create a feature for your firm. You must enter a feature_name for the feature. The endpoint returns a feature_id used to identify and manage the feature.

HTTP REQUEST

POST /feature_track

ARGUMENTS

Parameter Type Required Description
feature_id string required The id of the feature that was used
client_id string required The id of the client who used the feature
metadata map optional Custom information associated with the feature track in the format key:value
See Metadata
secondary_id string optional Alternate id that can be used to identify the object such as an internal id

Retrieve a feature track

Example Request

curl -X GET -H "Authorization: Bearer <access_token>" \
  "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/feature_track/284ef4b2-4d1b-4b4d-9db4-48cef641aec0"
api_instance = nucleus_api.UtilsApi(nucleus_api.ApiClient(configuration))
# Retrieve a FeatureTrack
try:
    api_response = api_instance.get_feature_track_using_get("fedaf640-f248-472d-b1ef-69355b55ab51")
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_feature_track_using_get: %s\n" % e)
UtilsApi apiInstance = new UtilsApi();
//        //Retrieve a FeatureTrack
        try {
            FeatureTrack responseTrack = apiInstance.getFeatureTrackUsingGet(UUID.fromString("b4bb1164-fcd0-457a-9c5a-3c0b4dff795f"));
            System.out.println(responseTrack);
        } catch (ApiException e) {
            System.err.println("Exception when calling getFeatureTrackUsingGet");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\UtilsApi(
    new GuzzleHttp\Client(),
    $config);
//Retrieve a FeatureTrack
$feature_track_id = "b4bb1164-fcd0-457a-9c5a-3c0b4dff795f"; // string | UUID feature_track_id

try {
    $featuretrack = $apiInstance->getFeatureTrackUsingGet($feature_track_id);
    print_r($featuretrack);
} catch (Exception $e) {
    echo 'Exception when calling FeatureApi->getFeatureTrackUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::UtilsApi.new
#Retrieve a FeatureTrack
feature_track_id = 'b4bb1164-fcd0-457a-9c5a-3c0b4dff795f' # String | UUID feature_track_id


begin
  track = api_instance.get_feature_track_using_get(feature_track_id)
  p track
rescue NucleusApi::ApiError => e
  puts "Exception when calling FeatureApi->get_feature_track_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.UtilsApi();
//Retrieve an Feature Track

var featurettrackId = "b4bb1164-fcd0-457a-9c5a-3c0b4dff795f";


var featuretrack = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.getFeatureTrackUsingGet(featurettrackId, featuretrack)

Example Response

{
  "id": "284ef4b2-4d1b-4b4d-9db4-48cef641aec0",
  "feature_id": "a462803b-0739-4fde-b702-265196272619",
  "client_id": "2d0268af-477e-4300-b971-0c19df64d254",
  "metadata": {},
  "secondary_id": null,
  "create_date": "2019-10-31T05:31:00.000+0000",
  "update_date": "2019-10-31T05:31:00.000+0000"
}

Retrieve a feature track for your firm. The feature_track_id must be provided. The endpoint returns the feature_track_id and the timestamp the feature was accessed by each client_id.

HTTP REQUEST

GET /feature_track/{feature_track_id}

Update a feature track

Example Request

curl -X PUT -H "Authorization: Bearer <access_token>" \
   -H "Content-Type: application/json" \
   -d '{
          "client_id": "9m02498af-256h-8910-n727-9b36rf66h582"
        }' "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/feature_track/284ef4b2-4d1b-4b4d-9db4-48cef641aec0"
api_instance = nucleus_api.UtilsApi(nucleus_api.ApiClient(configuration))
# #Update FeatureTrack
feature_track_update = {'secondary_id': 'None'}
feature_track_id = 'ca0e2447-17cb-4576-8277-7679dc1993b4'
try:
    api_response = api_instance.update_feature_track_using_put(feature_track_update, feature_track_id)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling update_feature_track_using_put: %s\n" % e)
UtilsApi apiInstance = new UtilsApi();
        //Update a FeatureTrack
        Map map = new HashMap();
        map.put("secondary_id", "null");

        try {
            FeatureTrack response = apiInstance.updateFeatureTrackUsingPut(map, UUID.fromString("3ec8f70b-4b01-419f-bcdf-6bc82eb2b2e0"));

            System.out.println(response);
        } catch (ApiException e) {
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\UtilsApi(
    new GuzzleHttp\Client(),
    $config);
//Update feature Track
$feature_track_update = new stdClass();
$featuretrack_id = "3d6e82e1-ef61-4993-a27e-82e1ca2c4fc6";

try {
    $feature_track_update->secondary_id = "null";
    $result = $apiInstance->updateFeatureTrackUsingPut($feature_track_update, $featuretrack_id);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->updateFeatureTrackUsingPut: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::UtilsApi.new
#Update feature Track
feature_track_update = {"name" => 'ABC'}
feature_track_id = 'e95e0073-f561-4870-90d1-9ce8cc2a7790'
begin
  result = api_instance.update_feature_track_using_put(feature_track_update, feature_track_id)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->update_feature_track_using_put: #{e}"
end
var apiInstance = new HydrogenNucleusApi.UtilsApi();
// //Update FeatureTrack
var apiInstance = new HydrogenNucleusApi.UtilsApi();
var callback = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
var featuretrackupdate = new HydrogenNucleusApi.FeatureTrack();
var featuretrackid = 'd6c1b370-6934-40eb-acf2-e309b45101b2';

featureupdate.secondary_id = "null";
apiInstance.updateFeatureTrackUsingPut(featuretrackid, featuretrackupdate, callback)

Example Response

{
  "id": "284ef4b2-4d1b-4b4d-9db4-48cef641aec0",
  "feature_id": "a462803b-0739-4fde-b702-265196272619",
  "client_id": "9m02498af-256h-8910-n727-9b36rf66h582",
  "metadata": {}
}

Update a feature track for your firm. The feature_track_id must be provided. To obtain the appropriate feature_track_id, use the GET /feature_track endpoint to view all of the tracking for your firm. The details to be updated and the details to be maintained must also be provided. The endpoint returns the feature_track_id and the timestamp.

HTTP REQUEST

PUT /feature_track/{feature_track_id}

Delete a feature track

Example Request

curl -X DELETE -H "Authorization: Bearer <access_token>" \
  "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/feature_track/284ef4b2-4d1b-4b4d-9db4-48cef641aec0
api_instance = nucleus_api.UtilsApi(nucleus_api.ApiClient(configuration))
# # #Delete a FeatureTrack
featuretrack1_id = '8aa4c7e0-1286-4945-96dc-d5649397429f'

try:
    api_instance.delete_feature_track_using_delete(featuretrack1_id)
except ApiException as e:
    print("Exception when calling delete_feature_track_using_delete: %s\n" % e)
UtilsApi apiInstance = new UtilsApi();
        //Delete a FeatureTrack
        try {
            FeatureTrack deleteresponse = apiInstance.deleteFeatureTrackUsingDelete(UUID.fromString("110109ee-afd9-4457-ae4b-18e81aa9619a"));
            System.out.println(deleteresponse);
        } catch (ApiException e) {
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\UtilsApi(
    new GuzzleHttp\Client(),
    $config);
//Delete Feature Track
$featuretrack_did = "a71b347d-db0b-4ca5-ba9c-7a5595ec008c"; // string | UUID account_id

try {
    $apiInstance->deleteFeatureTrackUsingDelete($featuretrack_did);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->deleteFeatureTrackUsingDelete: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::UtilsApi.new

#Delete FeatureTrack
feature_track1_id = '3d6e82e1-ef61-4993-a27e-82e1ca2c4fc6'
begin
  result = api_instance.delete_feature_track_using_delete(feature_track1_id)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->delete_feature_track_using_delete: #{e}"
end
var apiInstance = new HydrogenNucleusApi.UtilsApi();
// // // //Delete a FeatureTrack
var featuretrackidd = "760162a7-2166-4b1c-a3a4-81271833de6a";


var deletefeaturetrack = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully.');
    }
};
apiInstance.deleteFeatureTrackUsingDelete(featuretrackidd, deletefeaturetrack)

Response (204 No Content)

Permanently delete a feature for your firm. The feature_id must be provided. To obtain the appropriate feature_id, use the GET /feature endpoint to view all of the features for your firm. This deletes the feature_id and the details for the feature record.

HTTP REQUEST

DELETE /feature_track/{feature_track_id}

Cards

Card

Card Management

Store a debit or prepaid card that has been issued through an integration.

Field Type Description
id UUID The id of the card
client_id UUID The id of the client to whom the card belongs
business_id UUID The id of the business to whom the card belongs
portfolio_id UUID The id of the portfolio under the account linked to the card. Portfolios store balances and transactions.
card_program_id UUID The id of the card program the card belongs to
card_name string Name of the card
institution_name string Name of the institution to issue the card
institution_id UUID ID of the institution resource for this card
card_holder_name string Name of the person to whom the card is issued
expiry_date date Expiration date of the card
card_type string Type of card. Value may be credit, debit, or prepaid
card_network string Card network for the card. Value may be visa, mastercard, amex, or discover
card_issuance string Type of card issuance. Value may be physical, virtual, or both
card_image string Link to an image of the card artwork with the card details
mask string Masked version of the card number
currency_code string Alphabetic currency code for the base currency of the card, limited to 3 characters
See currency codes
credit_limit double Credit limit of the card if it’s a credit card
prepaid_amount double Amount loaded on card if it’s a prepaid card
address array(map) Address details for the card
      address_line1 string Primary information for the street address, such as the street and building number
      address_line2 string Secondary information for the street address, such as a suite or apartment number
      city string City for the address
      state string State, province, or sub-country region for the address
      postalcode string Alphanumeric postal code or zip code for the address
      country string Country for the address using the ISO ALPHA-2 Code.
See country codes
      type string Type of address. Value may be mailing or billing
phone_number string Phone number associated with the card
fulfillment string Status of the fulfillment of a physical card such as “ordered” or “shipped”
status string Status of the card such as “pending”, “issued”, or “suspended”
is_primary boolean Indicates if the card is the primary card for a client. Only one card may be primary for a client_id. If a user sets a card to is_primary = “true” then all other cards for that client_id will be set to is_primary = “false.” Defaults to false which indicates the card is not primary
is_reloadable boolean Indicates if the card is reloadable. Defaults to false which indicates it is not reloadable
is_pin_set boolean Indicates if the card PIN has been set. Defaults to false which indicates it has not been set
is_active boolean Indicates if the card is currently active. Defaults to true which indicates it is active
metadata map Custom information associated with the card in the format key:value
See Metadata
secondary_id string Alternate id that can be used to identify the object such as an internal id
create_date timestamp Timestamp for the date and time that the record was created
update_date timestamp Timestamp for the date and time that the record was last updated

List all cards

Example Request

curl -X GET -H "Authorization: Bearer <access_token>" \
  "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/card"
api_instance = nucleus_api.CardApi(nucleus_api.ApiClient(configuration))
try:
    api_response = api_instance.get_card_all_using_get()
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_card_all_using_get: %s\n" % e)
CardApi apiInstance = new CardApi();
        try {
            PageCard List = apiInstance.getCardAllUsingGet(true, null, null, 1, 5);
            System.out.println(List);
        } catch (ApiException e) {
            System.err.println("Exception when calling getCardAllUsingGet");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\CardApi(
    new GuzzleHttp\Client(),
    $config);
$ascending = false; // bool | ascending
$filter = null; // string | filter
$order_by = null; // string | order_by
$page = 0; // int | page
$size = 10; // int | size

try {
    $cardlist = $apiInstance->getCardAllUsingGet($ascending, $filter, $order_by, $page, $size);
    print_r($cardlist);
} catch (Exception $e) {
    echo 'Exception when calling CardApi->getCardAllUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::CardApi.new
opts = {
    ascending: false, # BOOLEAN | ascending
    filter: null, # String | filter
    order_by: null, # String | order_by
    page: 0, # Integer | page
    size: 25 # Integer | size
}

begin
  cardlist = api_instance.get_card_all_using_get(opts)
  p cardlist
rescue NucleusApi::ApiError => e
  puts "Exception when calling CardApi->get_card_all_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.CardApi();
var opts = {
    'ascending': false, // Boolean | ascending
    // 'filter': "", // String | filter
    'orderBy': "update_date", // String | order_by
    'page': 0, // Number | page
    'size': 25 // Number | size
};

var cardlist = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.getCardAllUsingGet(opts, cardlist)

Example Response

{
    "content": [
        {
            "id": "1692a3c2-65b0-46a0-9a0a-66bc949f7ca1",
            "secondary_id": null,
            "create_date": "2020-01-07T20:54:33.000+0000",
            "update_date": "2020-01-07T20:54:33.000+0000",
            "client_id": "87ef9136-f7e1-4ef0-8dbc-e58bf435d11c",
            "business_id": null,
            "portfolio_id": "93ef9134-h7p1-5ef2-9dbc-p88bf435d22b",
            "card_program_id": null,
            "card_name": "Travel Rewards",
            "institution_name": "Citywide Bank",
            "institution_id": null,
            "card_holder_name": "Sarah Johnson",
            "expiry_date": "12/31/2030",
            "card_type": "credit",
            "card_network": "visa",
            "card_issuance": "physical",
            "card_image": null,
            "mask": "1752",
            "currency_code": "USD",
            "credit_limit": 5000.00,
            "prepaid_amount": null,
            "address": [
                {
                    "address_line1": "354 Halsted Street",
                    "address_line2": "Apt 2",
                    "city": "Chicago",
                    "state": "IL",
                    "postalcode": "60608",
                    "country": "US",
                    "type": "mailing"
                },
                {
                    "address_line1": "483 Morgan Street",
                    "address_line2": "Apt 3",
                    "city": "Chicago",
                    "state": "IL",
                    "postalcode": "60608",
                    "country": "US",
                    "type": "billing"
                }
            ],
            "phone_number": "7739462148",
            "fulfillment": null,
            "status": null,
            "is_primary": false,
            "is_reloadable": false,
            "is_pin_set": true,
            "is_active": true,
            "metadata": {}
        },
        {
            "id": "0233ab54-58a0-4b43-aa65-a1c32f29ad69",
            "secondary_id": null,
            "create_date": "2019-12-20T18:39:44.000+0000",
            "update_date": "2019-12-20T18:39:44.000+0000",
            "client_id": "87ef9136-f7e1-4ef0-8dbc-e58bf435d11c",
            "business_id": null,
            "portfolio_id": "b690fc43-9cdd-4547-b8cd-afadf6b58b2a",
            "card_program_id": null,
            "card_name": "Virtual Visa",
            "institution_name": "Citywide Bank",
            "institution_id": null,
            "card_holder_name": "John Smith",
            "expiry_date": "12/31/2025",
            "card_type": "prepaid",
            "card_network": "visa",
            "card_issuance": "virtual",
            "card_image": null,
            "mask": "6789",
            "currency_code": "USD",
            "credit_limit": null,
            "prepaid_amount": 500,
            "address": [
                {
                    "address_line1": "3 Downtown Street",
                    "address_line2": "",
                    "city": "New York",
                    "state": "NY",
                    "postalcode": "01191",
                    "country": "US",
                    "type": "billing"
                }
            ],
            "phone_number": "2123734583",
            "fulfillment": null,
            "status": null,
            "is_primary": false,
            "is_reloadable": true,
            "is_pin_set": false,
            "is_active": true,
            "metadata": {}
        }
    ],
    "last": true,
    "total_pages": 1,
    "total_elements": 2,
    "number_of_elements": 2,
    "first": true,
    "sort": [
        {
            "direction": "DESC",
            "property": "updateDate",
            "ignore_case": false,
            "null_handling": "NATIVE",
            "ascending": false,
            "descending": true
        }
    ],
    "size": 25,
    "number": 0
}

Get information for all cards stored for your tenant. You can filter using one of the unique ids such as the client_id to view the cards for a client or for another particular entity.

HTTP REQUEST

GET /card

Create a card

Example Request

curl -X POST -H "Authorization: Bearer <access_token>" \
-H "Content-Type: application/json" \
-d '{
      "client_id": "87ef9136-f7e1-4ef0-8dbc-e58bf435d11c",
      "portfolio_id": "b690fc43-9cdd-4547-b8cd-afadf6b58b2a",
      "card_name": "Travel Rewards",
      "institution_name": "Citywide Bank",
      "card_holder_name": "Sarah Johnson",
      "expiry_date": "12/31/2000",
      "card_type": "credit",
      "card_network": "visa",
      "card_issuance": "physical",
      "mask": "1752",
      "currency_code": "USD",
      "prepaid_amount": 5000.00,
      "address": [
            {
                "address_line1": "483 Morgan Street",
                "address_line2": "Apt 3",
                "city": "Chicago",
                "state": "NY",
                "postalcode": "60608",
                "country": "US",
                "type": "billing"
            },
            {
                "address_line1": "354 Halsted Street",
                "address_line2": "Apt 2",
                "city": "Chicago",
                "state": "NY",
                "postalcode": "60608",
                "country": "US",
                "type": "mailing"
            }
      ],
      "phone_number": "7739462148",
    "is_reloadable": false
    }' "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/card"
api_instance = nucleus_api.CardApi(nucleus_api.ApiClient(configuration))
# # Create a Card
card = nucleus_api.Card(client_id="19f02c69-343a-4661-91c6-4426cc90e7f9", portfolio_id="5113915a-1ada-48f1-be2e-14cc8dd59776", card_name="Visa", institution_name="Yes Bank", card_holder_name="Tom", card_type="debit", card_issuance="physical")
try:
    api_response = api_instance.create_card_using_post(card)
    pprint(api_response)
except ApiException as e:
    print("create_card_using_post: %s\n" % e)
CardApi apiInstance = new CardApi();
        //Create A Card
        Card card = new Card();
        card.setClientId(UUID.fromString("19f02c69-343a-4661-91c6-4426cc90e7f9"));
        card.setPortfolioId(UUID.fromString("5113915a-1ada-48f1-be2e-14cc8dd59776"));
        card.setCardProgramId(null);
        card.setCardName("Visa");
        card.setInstitutionName("Yes Bank");
        card.setCardHolderName("Tom Kirkman");
        card.setCardType("debit");
        card.setCardIssuance("physical");

                        try {
            Card result = apiInstance.createCardUsingPost(card);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling createCardUsingPost");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\CardApi(
    new GuzzleHttp\Client(),
    $config);
//Create Card
$card = new \com\hydrogen\nucleus\Model\Card();

try {
    $card->setClientId("19f02c69-343a-4661-91c6-4426cc90e7f9");
    $card->setPortfolioId("5113915a-1ada-48f1-be2e-14cc8dd59776");
    $card->setCardProgramId("bfc1b849-bd33-4660-b5a6-39ffa80d8c25");
    $card->setCardName("AB");
    $card->setCardHolderName("ANS");
    $card->setInstitutionName("ABS BANK");
    $card->setCardType("visa");
    $card->setCardIssuance("physical");
    $result = $apiInstance->createCardUsingPost($card);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->createCardUsingPost: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::CardApi.new
#Create Card
card = NucleusApi::Card.new

begin
  card.client_id = "19f02c69-343a-4661-91c6-4426cc90e7f9"
  card.portfolio_id = "5113915a-1ada-48f1-be2e-14cc8dd59776"
  card.card_name = "visa"
  card.card_type = "debit"
  card.institution_name = "ABC BANK"
  card.card_holder_name = "MINK"
  card.card_issuance = "physical"
  result = api_instance.create_card_using_post(card)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->create_card_using_post: #{e}"
end
var apiInstance = new HydrogenNucleusApi.CardApi();
//Create Card
var cardn = new HydrogenNucleusApi.Card();
cardn.client_id = '19f02c69-343a-4661-91c6-4426cc90e7f9';
cardn.portfolio_id = '5113915a-1ada-48f1-be2e-14cc8dd59776';
cardn.card_program_id = '781be039-fee9-4b5e-9fd8-f8ad6ceaf5c3';
cardn.card_name = "One";
cardn.institution_name = "ABC";
cardn.card_holder_name = "MESSI";
cardn.card_type = "debit";
cardn.card_issuance = "physical";

var newcard = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.createCardUsingPost(cardn, newcard)

Example Response

{
    "id": "1692a3c2-65b0-46a0-9a0a-66bc949f7ca1",
    "secondary_id": null,
    "create_date": "2020-01-07T20:54:32.000+0000",
    "update_date": "2020-01-07T20:54:32.000+0000",
    "client_id": "87ef9136-f7e1-4ef0-8dbc-e58bf435d11c",
    "business_id": null,
    "portfolio_id": "b690fc43-9cdd-4547-b8cd-afadf6b58b2a",
    "card_program_id": null,
    "card_name": "Travel Rewards",
    "institution_name": "Citywide Bank",
    "institution_id": null,
    "card_holder_name": "Sarah Johnson",
    "expiry_date": "12/31/2000",
    "card_type": "credit",
    "card_network": "visa",
    "card_issuance": "physical",
    "card_image": null,
    "mask": "1752",
    "currency_code": "USD",
    "credit_limit": null,
    "prepaid_amount": 5000.00,
    "address": [
      {
          "address_line1": "354 Halsted Street",
          "address_line2": "Apt 2",
          "city": "Chicago",
          "state": "NY",
          "postalcode": "60608",
          "country": "US",
          "type": "mailing"
      },
      {
          "address_line1": "483 Morgan Street",
          "address_line2": "Apt 3",
          "city": "Chicago",
          "state": "NY",
          "postalcode": "60608",
          "country": "US",
          "type": "billing"
      }
    ],
    "phone_number": "7739462148",
    "fulfillment": null,
    "status": null,
    "is_primary": false,
    "is_reloadable": false,
    "is_pin_set": false,
    "is_active": true,
    "metadata": {}
}

Create a card for a client. The endpoint returns a card_id that can then be used to manage the card.

HTTP REQUEST

POST /card

ARGUMENTS

Parameter Type Required Description
client_id UUID required, conditional The id of the client to whom the card belongs
business_id UUID required, conditional The id of the business to whom the card belongs
portfolio_id UUID required The id of the portfolio under the account linked to the card. Portfolios store balances and transactions.
card_name string required Name of the card
institution_name string required, conditional Name of the institution for the card, e.g. HSBC. Either this name or the institution_id must be supplied.
institution_id UUID required, conditional ID of the institution resource for this card. Either this name or the institution_name must be supplied.
card_holder_name string required Name of the person to whom the card is issued
card_type string required Type of card. Value may be credit, debit, or prepaid
card_issuance string required Type of card issuance. Value may be physical, virtual, or both
card_program_id UUID optional The id of the card program the card belongs to
card_image string optional Link to an image of the card artwork with the card details
card_network string optional Card network for the card. Value may be visa, mastercard, amex, or discover
mask string optional Masked version of the card number
expiry_date date optional Expiration date of the card
currency_code string optional Alphabetic currency code for the base currency of the card, limited to 3 characters
See currency codes
credit_limit double optional Credit limit of the card if it’s a credit card
prepaid_amount double optional Amount loaded on card if it’s a prepaid card
address array(map) optional Address details for the card
      address_line1 string required Primary information for the street address, such as the street and building number
      address_line2 string optional Secondary information for the street address, such as a suite or apartment number
      city string required City for the address
      state string required State, province, or sub-country region for the address
      postalcode string optional Alphanumeric postal code or zip code for the address
      country string required Country for the address using the ISO ALPHA-2 Code.
See country codes
      type string required Type of address. Value may be mailing or billing
phone_number string optional Phone number associated with the card
fulfillment string optional Status of the fulfillment of a physical card such as “ordered” or “shipped”
status string optional Status of the card such as pending or issued
is_primary boolean optional Indicates if the card is the primary card for a client. Only one card may be primary for a client_id. If a user sets a card to is_primary = “true” then all other cards for that client_id will be set to is_primary = “false.” Defaults to false which indicates the card is not primary
is_reloadable boolean optional Indicates if the card is reloadable. Defaults to false which indicates it is not reloadable
is_pin_set boolean optional Indicates if the card PIN has been set. Defaults to false which indicates it has not been set
is_active boolean optional Indicates if the card is currently active. Defaults to true which indicates it is active
metadata map optional Custom information associated with the card in the format key:value
See Metadata
secondary_id string optional Alternate id that can be used to identify the object such as an internal id

Retrieve a card

Example Request

curl -X GET -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/card/0233ab54-58a0-4b43-aa65-a1c32f29ad69"
api_instance = nucleus_api.CardApi(nucleus_api.ApiClient(configuration))
try:
    api_response = api_instance.get_card_using_get("a47c88a5-7e61-4419-87ec-2366170ce496")
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_card_using_get: %s\n" % e)
CardApi apiInstance = new CardApi();
        try {
            Card responseCard = apiInstance.getCardUsingGet(UUID.fromString("40d6e6e4-4695-4fe8-9f91-dbfdd96ae766"));
            System.out.println(responseCard);
        } catch (ApiException e) {
            System.err.println("Exception when calling getCardAllUsingGet");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\CardApi(
    new GuzzleHttp\Client(),
    $config);
$card_id = "40d6e6e4-4695-4fe8-9f91-dbfdd96ae766"; // string | UUID card_id

try {
    $card = $apiInstance->getCardUsingGet($card_id);
    print_r($card);
} catch (Exception $e) {
    echo 'Exception when calling CardApi->getCardUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::CardApi.new
opts = {
    ascending: false, # BOOLEAN | ascending
    filter: null, # String | filter
    order_by: null, # String | order_by
    page: 0, # Integer | page
    size: 25 # Integer | size
}

begin
  cardlist = api_instance.get_card_all_using_get(opts)
  p cardlist
rescue NucleusApi::ApiError => e
  puts "Exception when calling CardApi->get_card_all_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.CardApi();
var cardId = "2f36f818-cf18-482e-b7c7-e432b7c0511a";


var card = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.getCardUsingGet(cardId, card)

Example Response

{
    "id": "0233ab54-58a0-4b43-aa65-a1c32f29ad69",
    "secondary_id": null,
    "create_date": "2019-12-20T18:39:44.000+0000",
    "update_date": "2019-12-20T18:39:44.000+0000",
    "client_id": "87ef9136-f7e1-4ef0-8dbc-e58bf435d11c",
    "business_id": null,
    "portfolio_id": "b690fc43-9cdd-4547-b8cd-afadf6b58b2a",
    "card_program_id": null,
    "card_name": "Virtual Visa",
    "institution_name": "Citywide Bank",
    "institution_id": null,
    "card_holder_name": "John Smith",
    "expiry_date": "12/31/2025",
    "card_type": "prepaid",
    "card_network": "visa",
    "card_issuance": "virtual",
    "card_image": null,
    "mask": "6789",
    "currency_code": "USD",
    "credit_limit": null,
    "prepaid_amount": 5000.00,
    "address": [
        {
            "address_line1": "3 Downtown Street",
            "address_line2": "",
            "city": "New York",
            "state": "NY",
            "postalcode": "01191",
            "country": "US",
            "type": "billing"
        }
    ],
    "phone_number": "2123734583",
    "fulfillment": null,
    "status": null,
    "is_primary": false,
    "is_reloadable": false,
    "is_pin_set": false,
    "is_active": true,
    "metadata": {}
}

Retrieve the information for a specific card associated with a client. The endpoint returns the card_id and details for the card specified.

HTTP REQUEST

GET /card/{card_id}

Update a card

Example Request

curl -X PUT -H "Authorization: Bearer <access_token>" \
-H "Content-Type: application/json" \
-d '{
      "client_id": "87ef9136-f7e1-4ef0-8dbc-e58bf435d11c",
      "card_name": "Virtual Visa",
      "institution_name": "Citywide Bank",
      "card_holder_name": "John Smith",
      "expiry_date": "12/31/2025",
      "card_type": "debit",
      "card_network": "visa",
      "card_issuance": "virtual",
      "mask": "6789",
      "currency_code": "USD",
      "address": [
        {
            "address_line1": "3 Downtown Street",
            "address_line2": "",
            "city": "New York",
            "state": "NY",
            "postalcode": "01191",
            "country": "US",
            "type": "billing"
        }
      ],
      "phone_number": "2123734583",
      "is_active": true
    }' "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/card/0233ab54-58a0-4b43-aa65-a1c32f29ad69"
api_instance = nucleus_api.CardApi(nucleus_api.ApiClient(configuration))
# #Update Card
card_Update = {'currency_code': 'AUD'}
card_id = 'd5efa2f8-89c7-4508-bdec-49ce1b6a2d8e'
try:
    api_response = api_instance.update_card_using_put(card_Update, card_id)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling update_card_using_put: %s\n" % e)
CardApi apiInstance = new CardApi();
//Update a Card Program
        Map map = new HashMap();
        map.put("institution_name", "ABC BANK");

        try {
            Card response = apiInstance.updateCardUsingPut(map, UUID.fromString("e5079bb8-a25c-4c21-8dc0-c649ca98c024"));
            System.out.println(response);
        } catch (ApiException e) {
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\CardApi(
    new GuzzleHttp\Client(),
    $config);
//Update Card
$card_update = new stdClass();
$card_id = "51e680bb-87f3-45a4-863e-ef153c8016d5";

try {
    $card_update->card_holder_name = "max";
    $result = $apiInstance->updateCardUsingPut($card_update,  $card_id);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->updateCardUsingPut: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::CardApi.new
#Update Card
card_update = {"card_type" => 'visa'}
card_id = 'bf84ea77-7934-44c9-9d77-6911e41bb6f1'
begin
  result = api_instance.update_card_using_put(card_update, card_id)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->update_card_using_put: #{e}"
end
var apiInstance = new HydrogenNucleusApi.CardApi();
// //Update Card
var apiInstance = new HydrogenNucleusApi.CardApi();
var callback = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
var cardupdaten = new HydrogenNucleusApi.Card();
var cardid1 = "020a7549-198a-486e-baf2-baa35bb330bf";

cardupdaten.card_name = "CITI";
apiInstance.updateCardUsingPut(cardupdaten, cardid1, callback)

Example Response

{
    "id": "0233ab54-58a0-4b43-aa65-a1c32f29ad69",
    "secondary_id": null,
    "create_date": "2019-12-20T18:39:44.000+0000",
    "update_date": "2020-01-07T21:19:30.000+0000",
    "client_id": "87ef9136-f7e1-4ef0-8dbc-e58bf435d11c",
    "business_id": null,
    "portfolio_id": "b690fc43-9cdd-4547-b8cd-afadf6b58b2a",
    "card_program_id": null,
    "card_name": "Virtual Visa",
    "institution_name": "Citywide Bank",
    "institution_id": null,
    "card_holder_name": "John Smith",
    "expiry_date": "12/31/2025",
    "card_type": "prepaid",
    "card_network": "visa",
    "card_issuance": "virtual",
    "card_image": null,
    "mask": "6789",
    "currency_code": "USD",
    "credit_limit": null,
    "prepaid_amount": 500,
    "address": [
        {
            "address_line1": "3 Downtown Street",
            "address_line2": "",
            "city": "New York",
            "state": "NY",
            "postalcode": "01191",
            "country": "US",
            "type": "billing"
        }
    ],
    "phone_number": "2123734583",
    "fulfillment": null,
    "status": null,
    "is_primary": false,
    "is_reloadable": true,
    "is_pin_set": false,
    "is_active": true,
    "metadata": {}
}

Update the information for a card. The unique card_id must be provided. To obtain the appropriate card_id, use the GET /card endpoint to view all cards stored for your tenant and their current information. The details to be updated must also be provided. The endpoint returns the card_id and the details for the card.

HTTP REQUEST

PUT /card/{card_id}

Delete a card

Example Request

curl -X DELETE -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/card/0233ab54-58a0-4b43-aa65-a1c32f29ad69"
api_instance = nucleus_api.CardApi(nucleus_api.ApiClient(configuration))
# # #  # Delete a Card
cardn_id = 'cbf30a7b-44bd-46f5-be97-cb285b3e8a7f'
try:
    api_instance.delete_card_using_delete(cardn_id)
except ApiException as e:
    print("Exception when delete_card_using_delete: %s\n" % e)
CardApi apiInstance = new CardApi();
        //   Delete Card
        try {
            Card deleteresponse = apiInstance.deleteCardUsingDelete(UUID.fromString("c644984c-9107-45d2-ba3e-5d86fe2b340e"));
            System.out.println(deleteresponse);
        } catch (ApiException e) {
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\CardApi(
    new GuzzleHttp\Client(),
    $config);
//Delete Card
$card_did = "39ad1ea2-c11c-4b92-a80f-76de49fd041d"; // string | UUID account_id

try {
    $apiInstance->deleteCardUsingDelete($card_did);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->deleteCardUsingDelete: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::CardApi.new
#Delete Card
card1_id = 'dc8a9687-ba10-42d0-a231-2ef819c6d9c1'
begin
  result = api_instance.delete_card_using_delete(card1_id)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->delete_card_using_delete: #{e}"
end
var apiInstance = new HydrogenNucleusApi.CardApi();
//Delete a Card
var carddid = "c8d7209e-a93c-470a-9fea-c72aa2a5aa56";


var deletecard = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully.');
    }
};
apiInstance.deleteCardUsingDelete(carddid, deletecard)

Response (204 No Content)

Permanently delete a card. The unique card_id must be provided. To obtain the appropriate card_id, use the GET /card endpoint to view all cards stored for your tenant. This deletes the card_id and all card record information.

HTTP REQUEST

DELETE /card/{card_id}

Cardholder Overview

Aggregates the details of all cards under a tenant including the card details and latest balance. This view is useful to display a admin dashboard for cards.

Field Type Description
client_details list Details from the client_id associated with the card
      title string Title of client such as “Mr.” or “Mrs.”
      first_name string First name of client
      middle_name string Middle name of client
      last_name string Last name of client
      email string Email address of client
      status string Status of client such as “active”
      create_date timestamp Time the client was created
total_balance list Total balance of all cards for the client
      currency_code string Alphabetic currency code for the balance, limited to 3 characters. See currency codes
      total_balance float Total latest balance for all cards
      total_balance_available float Total latest available balance for all cards
card_details list Details for each card the client owns
      card_id UUID ID of the card
      card_name string Name of the card
      card_holder_name string Name of the cardholder
      card_type string Type of card such as “prepaid”
      card_network string Card network. Value may be “mastercard”, “visa”, “amex”, “discover”
      card_issuance string Type of issuance. Value may be “physical”, “virtual”
      mask integer Last 4 digits of the card PAN
      expiry_date date Date the card expires
      prepaid_amount float Amount preloaded on the card
      status string Status of the card such as “activated”
      card_balance list Latest balance for each card listed above
            currency_code string Alphabetic currency code for the balance, limited to 3 characters. See currency codes
            balance float Latest balance for the card
            balance_available float Latest available balance for the card
            balance_timestamp float Timestamp for the balance

HTTP REQUEST

GET /card/cardholder_overview

Example Request

curl -X GET -H "Authorization: Bearer <access_token>" \
  "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/card/cardholder_overview"
api_instance = nucleus_api.CardApi(nucleus_api.ApiClient(configuration))
# List all ClientCard
try:
    api_response = api_instance.get_all_client_cards_using_get()
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_all_client_cards_using_get: %s\n" % e)
CardApi apiInstance = new CardApi();
        //Get Cardholder Overview
        try {
            Object cardholderoverview = apiInstance.getAllClientCardsUsingGet(true, null, null, null, 0, 10);
            System.out.println(cardholderoverview);
        } catch (ApiException e) {
            System.err.println("Exception when calling getAllClientCardsUsingGet");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\CardApi(
    new GuzzleHttp\Client(),
    $config);
//Get CardholderOverview
//$card_id = "40d6e6e4-4695-4fe8-9f91-dbfdd96ae766"; // string | UUID card_id
$ascending = false; // bool | ascending
$currency_conversion = null; // string | USD
$end_date = new \DateTime("2013-10-20"); // \DateTime | end date
$order_by = null; // string | order_by
$page = 0; // int | page
$size = 10; // int | size
$start_date = new \DateTime("2013-10-20"); // \DateTime | start date

try {
    $cardtransaction = $apiInstance->getAllClientCardsUsingGet(true, null, null, null, 0, 10);
    print_r($cardtransaction);
} catch (Exception $e) {
    echo 'Exception when calling CardApi->getAllClientCardsUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::CardApi.new
# Get cardholder Overview

opts = {
  ascending: false, # BOOLEAN | ascending
  currency_conversion: null, # String | USD
  end_date: Date.parse('2013-10-20'), # Date | end date
  order_by: null, # String | order_by
  page: 0, # Integer | page
  size: 25, # Integer | size
  start_date: Date.parse('2013-10-20') # Date | start date
}

begin
  cardoverviw = api_instance.get_all_client_cards_using_get
  p cardoverviw
rescue NucleusApi::ApiError => e
  puts "Exception when calling CardApi->get_all_client_cards_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.CardApi();

//Get all CardHolderOverview
var overview = function(error, data, response) {
     if (error) {
         console.error(error);
     } else {
         console.log('API called successfully. Returned data: ' + data);
     }
 };
  // String | Card Id
 var opts = {
     'currencyConversion': null, // String | USD
     'endDate': new Date("2013-10-20"), // Date | end date
     'getLatest': true, // Boolean | true or false
     'sortType': null, // String |  Quarter (Q), Monthly (M) , Annually (Y), Daily (D) --caps matter, codes in ()
     'startDate': new Date("2013-10-20") // Date | start date
 };
 apiInstance.getAllClientCardsUsingGet(opts, overview)

Example Response

{
    "content": [
        {
          "client_details":
          {
            "title": null,
            "first_name": null,
            "middle_name": null,
            "last_name": null,
            "email": null,
            "status": "verified",
            "create_date": "2020-04-22T08:00:45.571+0530",
            "total_balance": [
                {
                    "currency_code": null,
                    "total_balance": 450.0,
                    "total_balance_available": 0.0
                }
              ]
            },
            "card_details": [
                {
                    "card_id": "9429d47c-f7aa-4d6c-b6d1-f8e383b28e13",
                    "card_name": "null",
                    "card_holder_name": "null",
                    "card_type": "prepaid",
                    "card_issuance": "virtual",
                    "card_network": "visa",
                    "mask": null,
                    "expiry_date": null,
                    "prepaid_amount": null,
                    "status": "null",
                    "card_balance": {
                        "currency_code": null,
                        "balance": 50.0,
                        "balance_available": null,
                        "balance_timestamp": "2020-07-19T00:00:00.000+0530"
                    }
                },
                {
                    "card_id": "fc62eac7-afb8-4e6d-accd-f740fe6c7fe1",
                    "card_name": "null",
                    "card_holder_name": "null",
                    "card_type": "prepaid",
                    "card_issuance": "virtual",
                    "card_network": "visa",
                    "mask": null,
                    "expiry_date": null,
                    "prepaid_amount": null,
                    "status": "null",
                    "card_balance": {
                        "currency_code": null,
                        "balance": 50.0,
                        "balance_available": null,
                        "balance_timestamp": "2020-07-19T00:00:00.000+0530"
                    }
                }
            ]
        }
    ],
    "total_elements": 1,
    "total_pages": 1,
    "last": true,
    "sort": [
        {
            "direction": "DESC",
            "property": "updateDate",
            "ignore_case": false,
            "null_handling": "NATIVE",
            "ascending": false,
            "descending": true
        }
    ],
    "first": true,
    "number_of_elements": 1,
    "size": 25,
    "number": 0
}

Card Activity

List all card asset sizes

Example Request

curl -X GET -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/card/099961da-7f41-4309-950f-2b51689a0033/asset_size"
api_instance = nucleus_api.CardApi(nucleus_api.ApiClient(configuration))
# List all CardAssetSize
try:
    api_response = api_instance.get_card_asset_size_agg_all_using_get("7c495184-bdbd-47fa-9e9d-5132b27678dc")
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_card_asset_size_agg_all_using_get: %s\n" % e)

CardApi apiInstance = new CardApi();
        //List All CardAssetSize
        try {
            Object cardassetsize = apiInstance.getCardAssetSizeAggAllUsingGet(UUID.fromString("40d6e6e4-4695-4fe8-9f91-dbfdd96ae766"), null, date2, true, null, date1);
            System.out.println(cardassetsize);
        } catch (ApiException e) {
            System.err.println("Exception when calling getCardAssetSizeAggAllUsingGet");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\CardApi(
    new GuzzleHttp\Client(),
    $config);
//Get CardAssetSize
$card_id = "40d6e6e4-4695-4fe8-9f91-dbfdd96ae766"; // string | Card Id
$currency_conversion = null; // string | USD
$end_date = new \DateTime("2013-10-20"); // \DateTime | end date
$get_latest = true; // bool | true or false
$sort_type = null; // string | Quarter (Q), Monthly (M) , Annually (Y), Daily (D) --caps matter, codes in ()
$start_date = new \DateTime("2013-10-20"); // \DateTime | start date

try {
    $cardassetsize = $apiInstance->getCardAssetSizeAggAllUsingGet($card_id, $currency_conversion, $end_date, $get_latest, $sort_type, $start_date);
    print_r($cardassetsize);
} catch (Exception $e) {
    echo 'Exception when calling CardApi->getCardAssetSizeAggAllUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::CardApi.new
#Get card AssetSize
card_id = '40d6e6e4-4695-4fe8-9f91-dbfdd96ae766' # String | Card Id

opts = {
    currency_conversion: null, # String | USD
    end_date: Date.parse('2013-10-20'), # Date | end date
    get_latest: true, # BOOLEAN | true or false
    sort_type: null, # String |  Quarter (Q), Monthly (M) , Annually (Y), Daily (D) --caps matter, codes in ()
    start_date: Date.parse('2013-10-20') # Date | start date
}

begin
  cardasset = api_instance.get_card_asset_size_agg_all_using_get(card_id, opts)
  p cardasset
rescue NucleusApi::ApiError => e
  puts "Exception when calling CardApi->get_card_asset_size_agg_all_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.CardApi();

//Get all CardAssetSize
var assetsize = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' + data);
    }
};
var cardId = "40d6e6e4-4695-4fe8-9f91-dbfdd96ae766"; // String | Card Id
var opts = {
    'currencyConversion': null, // String | USD
    'endDate': new Date("2013-10-20"), // Date | end date
    'getLatest': true, // Boolean | true or false
    'sortType': null, // String |  Quarter (Q), Monthly (M) , Annually (Y), Daily (D) --caps matter, codes in ()
    'startDate': new Date("2013-10-20") // Date | start date
};
apiInstance.getCardAssetSizeAggAllUsingGet(cardId, opts, assetsize)

Example Response

[
  {
    "date": "2018-02-03",
    "currency_code": "USD",
    "value": 20000,
    "value_available": null,
    "value_pending": null,
    "cash_flow": 0
  },
  {
    "date": "2018-02-04",
    "currency_code": "USD",
    "value": 24500,
    "value_available": null,
    "value_pending": null,
    "cash_flow": 500
  }
]

Get a list of asset sizes per date for a card. Asset size records are created at the portfolio level and aggregated to yield the card asset size(s). The unique card_id must be provided. To obtain the appropriate card_id, use the GET /card endpoint to view all available card_ids registered with your firm. The endpoint returns a list of asset sizes by date for the card.

HTTP REQUEST

GET /card/{card_id}/asset_size

ARGUMENTS

Parameter Type Required Description
get_latest boolean optional Retrieve only the latest asset size. Defaults to false if not set
sort_type string optional Sort the asset sizes by D Daily, M Monthly, Q Quarterly, Y Yearly. Defaults to D Daily if not set. Must be capital letters
start_date date optional Start date for the data. Defaults to the first date if not set
end_date date optional End date for the data. Defaults to the last date if not set
exclude_subledger boolean optional If set to “true”, excludes portfolios under accounts where is_subledger = “true” to not double count assets of subaccounts. Defaults to “false” which includes all portfolios under an account.
currency_conversion string optional Alphabetic currency code for the currency to convert all monetary values to. Value may be USD, GBP, EUR, AUD, CAD. Only available in enterprise plan.

RESPONSE

Field Type Description
date date Date for the asset size record. Displays the latest record if more than one entry exists for the given date.
currency_code string Alphabetic currency code for the asset size. See currency codes
value double Monetary value of all the card’s accounts on the particular date
value_available double Available monetary value of the card on the particular date
value_pending double Pending monetary value of the card on the particular date
cash_flow double Amount added to the card’s accounts or withdrawn from the accounts since the last asset size date. Value is used for performance calculations. Value may be positive or negative.

List all card transactions

Example Request

curl -X GET -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/card/099961da-7f41-4309-950f-2b51689a0033/transaction"
api_instance = nucleus_api.CardApi(nucleus_api.ApiClient(configuration))
# List all CardTransaction
try:
    api_response = api_instance.get_card_transaction_agg_all_using_get("7c495184-bdbd-47fa-9e9d-5132b27678dc")
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_card_transaction_agg_all_using_get: %s\n" % e)
CardApi apiInstance = new CardApi();
        //List CardTransactions
        try {
            Object cardtransaction = apiInstance.getCardTransactionAggAllUsingGet(UUID.fromString("40d6e6e4-4695-4fe8-9f91-dbfdd96ae766"), true, null, date2, null, 0, 10, date1);
            System.out.println(cardtransaction);
        } catch (ApiException e) {
            System.err.println("Exception when calling getCardTransactionAggAllUsingGet");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\CardApi(
    new GuzzleHttp\Client(),
    $config);
//Get CardTransactions
$card_id = "40d6e6e4-4695-4fe8-9f91-dbfdd96ae766"; // string | UUID card_id
$ascending = false; // bool | ascending
$currency_conversion = null; // string | USD
$end_date = new \DateTime("2013-10-20"); // \DateTime | end date
$order_by = null; // string | order_by
$page = 0; // int | page
$size = 10; // int | size
$start_date = new \DateTime("2013-10-20"); // \DateTime | start date

try {
    $cardtransaction = $apiInstance->getCardTransactionAggAllUsingGet($card_id, $ascending, $currency_conversion, $end_date, $order_by, $page, $size, $start_date);
    print_r($cardtransaction);
} catch (Exception $e) {
    echo 'Exception when calling CardApi->getCardTransactionAggAllUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::CardApi.new
# Get card transaction
card_id = '0d6e6e4-4695-4fe8-9f91-dbfdd96ae766' # String | UUID card_id

opts = {
    ascending: false, # BOOLEAN | ascending
    currency_conversion: null, # String | USD
    end_date: Date.parse('2013-10-20'), # Date | end date
    order_by: null, # String | order_by
    page: 0, # Integer | page
    size: 25, # Integer | size
    start_date: Date.parse('2013-10-20') # Date | start date
}

begin
  cardtransaction = api_instance.get_card_transaction_agg_all_using_get(card_id, opts)
  p cardtransaction
rescue NucleusApi::ApiError => e
  puts "Exception when calling CardApi->get_card_transaction_agg_all_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.CardApi();

//Get all CardTransactions
var transactions = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' + data);
    }
};
var cardId = "40d6e6e4-4695-4fe8-9f91-dbfdd96ae766"; // String | Card Id
var opts = {
    'currencyConversion': null, // String | USD
    'endDate': new Date("2013-10-20"), // Date | end date
    'getLatest': true, // Boolean | true or false
    'sortType': null, // String |  Quarter (Q), Monthly (M) , Annually (Y), Daily (D) --caps matter, codes in ()
    'startDate': new Date("2013-10-20") // Date | start date
};

apiInstance.getCardTransactionAggAllUsingGet(cardId, opts, transactions)

Example Response

{
  "content": [
    {
      "id": "efa289b2-3565-42e6-850b-8dad25727e99",
      "date": "2018-01-31T12:42:11.000+0000",
      "date_available": null,
      "is_recurring": false,
      "is_cleansed": true,
      "is_disputed": false,
      "is_read": true,
      "portfolio_id": "8ec467e6-6faa-4916-b380-6af0b21a34cc",
      "model_id": null,
      "price": null,
      "quantity": null,
      "currency_code": "USD",
      "amount": 8.75,
      "balance": null,
      "merchant_id": null,
      "mid": null,
      "merchant": "Starbucks",
      "merchant_category_code": null,
      "transaction_category_id": null,
      "category": "Food & Beverage",
      "subcategory": null,
      "description": null,
      "memo": null,
      "status": null,
      "location": {},
      "check": {},
      "funding_id": null,
      "security_id": null,
      "transaction_code_id": "f5af397b-7d22-433f-b01e-8202184a6386",
      "create_date": "2018-02-07T19:29:37.000+0000",
      "update_date": "2018-02-012T09:00:00.000+0000"
    },
    {
      "id": "efa289b2-3565-42e6-850b-8dad25727e24",
      "date": "2018-01-31T06:30:00.000+0000",
      "date_available": null,
      "is_recurring": false,
      "is_cleansed": false,
      "is_disputed": false,
      "is_read": true,
      "portfolio_id": "8ec467e6-6faa-4916-b380-6af0b21a34cc",
      "model_id": null,
      "price": null,
      "quantity": null,
      "currency_code": "USD",
      "amount": 12.10,
      "balance": null,
      "merchant_id": null,
      "mid": null,
      "merchant": null,
      "merchant_category_code": null,
      "transaction_category_id": null,
      "category": null,
      "subcategory": null,
      "description": "Mcdonald's #4572",
      "memo": null,
      "status": null,
      "location": {},
      "check": {},
      "funding_id": null,
      "security_id": null,
      "transaction_code_id": "f5af397b-7d22-433f-b01e-8202184a6386",
      "create_date": "2017-08-02T04:30:25.000+0000",
      "update_date": "2017-11-18T09:00:00.000+0000"
    }
  ],
    "total_pages": 1,
    "total_elements": 2,
    "last": true,
    "sort": [
        {
            "direction": "DESC",
            "property": "id",
            "ignore_case": false,
            "null_handling": "NATIVE",
            "descending": true,
            "ascending": false
        }
    ],
    "first": true,
    "number_of_elements": 2,
    "size": 25,
    "number": 2
}

Get the information for all transactions under a card registered with your firm. Transaction records are created at a portfolio level and all transactions for each portfolio below the card’s account(s) are returned to show the card’s transaction activity. The unique card_id must be provided. To obtain the appropriate card_id, use the GET /card endpoint to view all available card_ids registered with your firm. The endpoint returns a list of transaction_ids and details for each transaction.

HTTP REQUEST

GET /card/{card_id}/transaction

ARGUMENTS

Parameter Type Required Description
start_date date optional Start date for the data. Defaults to the first date if not set
end_date date optional End date for the data. Defaults to the last date if not set
currency_conversion string optional Alphabetic currency code for the currency to convert all monetary values to. Value may be USD, GBP, EUR, AUD, CAD. Only available in enterprise plan.

RESPONSE

Field Type Description
id UUID The id for the transaction record
date timestamp Timestamp when the transaction occurred
date_available timestamp Timestamp when the transaction becomes available
is_cleansed boolean Indicates if the transaction has been cleansed by a data cleansing engine. Defaults to false which indicates that it has not been cleansed
is_read boolean Indicates if the transaction has been read. Defaults to false which indicates that it has not been read
is_recurring boolean Indicates if the transaction is recurring such as a subscription. Defaults to false which indicates that it is not recurring
is_disputed boolean Indicates if the transaction is disputed by the client. Defaults to false which indicates that it is not disputed
portfolio_id UUID The id of the portfolio that the transaction record relates to
funding_id UUID The id of the funding request that the transaction record relates to
model_id UUID The id of the model to which the portfolio that the transaction falls under subscribes
price integer Price for the security included in the transaction at which it was sold or purchased
quantity integer Quantity of shares of the security purchased
currency_code string Alphabetic currency code for the amount. See currency codes
amount double Amount of the transaction
balance double Updated balance of the portfolio as a result of the transaction
merchant_id UUID ID of the merchant resource for the transaction
mid string Acquirer ID of the merchant (MID) for the transaction
merchant string The merchant for the transaction such as the merchant posted for a credit or debit card charge
merchant_category_code string The MCC Code for the merchant as identified by the card network
transaction_category_id string ID of the category resource for the transaction
category string Category of the transaction
subcategory string Subcategory of the transaction
description string Description of the transaction
memo string Memo attached to the transaction
status string Status of the transaction
location map Location where the transaction occurred
      address_line1 string Primary information for the street address, such as the street and building number
      address_line2 string Secondary information for the street address, such as a suite or apartment number
      city string City for the address
      state string State, province, or sub-country region for the address
      postalcode string Alphanumeric postal code or zip code for the address
      country string Country for the address using the ISO ALPHA-2 Code. See country codes
      latitude double Latitude of the location where the transaction occurred
      longitude double Longitude of the location where the transaction occurred
check map Check associated with the banking transaction
      check_number string Number on the check such as “1234”
      check_amount double Monetary amount of the check
      check_images map Image(s) of the scanned check(s)
            image_url string URL where the image can be displayed
            image_type string Type of image for the check such as “png” or “jpeg”
security_id UUID The id of the security included in the transaction
transaction_code_id integer The id referring to the transaction codes defined by your firm
secondary_id string Alternate id that can be used to identify the object such as an internal id
create_date timestamp Timestamp for the date and time that the record was created
update_date timestamp Timestamp for the date and time that the record was last updated

Card Program

Card programs are issued and run by a program manager who is responsible for establishing relationships with processors, sponsor banks, card networks.

Field Type Description
id UUID The id of the card program
client_id UUID The id of a client to whom the card program belongs if it’s a business on your platform
name string Name of the card program
card_network string Card network for the cards being issued in the program. Value may be visa, mastercard, amex, or discover
card_type string Type of cards being issued in the program. Value may be credit, debit, or prepaid
issuing_bank string Name of the issuing or sponsor bank on the card program
card_processor string Name of the card processor for the card program
program_manager string Name of the card program manager
code string Code used to identify the card program
description string Description of the card program
is_delegated_authority boolean Indicates if the card program is delegating authority for transaction authorizations. Defaults to false which indicates that it is active
is_active boolean Indicates if the card program is active. Defaults to true which indicates that the it is active
metadata map Custom information associated with the card program in the format key:value
See Metadata
secondary_id string Alternate id that can be used to identify the object such as an internal id
create_date timestamp Timestamp for the date and time that the record was created
update_date timestamp Timestamp for the date and time that the record was last updated

List all card programs

Example Request

curl -X GET -H "Authorization: Bearer <access_token>" \
  "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/card_program"
api_instance = nucleus_api.CardApi(nucleus_api.ApiClient(configuration))
try:
    api_response = api_instance.get_card_program_all_using_get()
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_card_program_all_using_get: %s\n" % e)
CardApi apiInstance = new CardApi();
        try {
            PageCardProgram List = apiInstance.getCardProgramAllUsingGet(true, null, null, 0, 10);
            System.out.println(List);
        } catch (ApiException e) {
            System.err.println("Exception when calling getCardProgramAllUsingGet");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\CardApi(
    new GuzzleHttp\Client(),
    $config);
$ascending = false; // bool | ascending
$filter = null; // string | filter
$order_by = null; // string | order_by
$page = 0; // int | page
$size = 10; // int | size

try {
    $cardprogramlist = $apiInstance->getCardProgramAllUsingGet($ascending, $filter, $order_by, $page, $size);
    print_r($cardprogramlist);
} catch (Exception $e) {
    echo 'Exception when calling CardApi->getCardProgramAllUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::CardApi.new
opts = {
    ascending: false, # BOOLEAN | ascending
    filter: null, # String | filter
    order_by: null, # String | order_by
    page: 0, # Integer | page
    size: 25 # Integer | size
}

begin
  cardprogramlist = api_instance.get_card_program_all_using_get(opts)
  p cardprogramlist
rescue NucleusApi::ApiError => e
  puts "Exception when calling CardApi->get_card_program_all_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.CardApi();
var opts = {
    'ascending': false, // Boolean | ascending
    // 'filter': "", // String | filter
    'orderBy': "update_date", // String | order_by
    'page': 0, // Number | page
    'size': 25 // Number | size
};

var cardprogramlist = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.getCardProgramAllUsingGet(opts, cardprogramlist)

Example Response

{
    "content": [
        {
            "id": "1692a3c2-65b0-46a0-9a0a-66bc949f7ca1",
            "secondary_id": null,
            "create_date": "2020-01-07T20:54:33.000+0000",
            "update_date": "2020-01-07T20:54:33.000+0000",
            "client_id": "87ef9136-f7e1-4ef0-8dbc-e58bf435d11c",
            "name": "E-Commerce Reloadable Program",
            "card_network": "visa",
            "card_type": "prepaid",
            "issuing_bank": "MetaBank",
            "card_processor": "Marqeta",
            "program_manager": "Marqeta",
            "code": "A89M4k28",
            "description": null,
            "is_delegated_authority": false,
            "is_active": true,
            "metadata": {}
        },
        {
            "id": "0233ab54-58a0-4b43-aa65-a1c32f29ad69",
            "secondary_id": null,
            "create_date": "2019-12-20T18:39:44.000+0000",
            "update_date": "2019-12-20T18:39:44.000+0000",
            "client_id": "87ef9136-f7e1-4ef0-8dbc-e58bf435d11c",
            "name": "Banking Program",
            "card_network": "visa",
            "card_type": "prepaid",
            "issuing_bank": "MetaBank",
            "card_processor": "Marqeta",
            "program_manager": "Marqeta",
            "code": "L43zn2659",
            "description": null,
            "is_delegated_authority": false,
            "is_active": true,
            "metadata": {}
        }
    ],
    "last": true,
    "total_pages": 1,
    "total_elements": 2,
    "number_of_elements": 2,
    "first": true,
    "sort": [
        {
            "direction": "DESC",
            "property": "updateDate",
            "ignore_case": false,
            "null_handling": "NATIVE",
            "ascending": false,
            "descending": true
        }
    ],
    "size": 25,
    "number": 0
}

Get information for all card programs stored for your tenant.

HTTP REQUEST

GET /card_program

Create a card program

Example Request

curl -X POST -H "Authorization: Bearer <access_token>" \
-H "Content-Type: application/json" \
-d '{
      "client_id": "87ef9136-f7e1-4ef0-8dbc-e58bf435d11c",
      "name": "E-Commerce Reloadable Program",
      "card_network": "visa",
      "card_type": "prepaid",
      "issuing_bank": "MetaBank",
      "card_processor": "Marqeta",
      "program_manager": "Marqeta",
      "code": "A89M4k28"
    }' "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/card_program"
api_instance = nucleus_api.CardApi(nucleus_api.ApiClient(configuration))
# Create a Card Program
card_Program = nucleus_api.CardProgram(name="New Card", card_network="visa", card_type="credit", issuing_bank="Citi Bank")
try:
    api_response = api_instance.create_card_program_using_post(card_Program)
    pprint(api_response)
except ApiException as e:
    print("create_card_program_using_post: %s\n" % e)
CardApi apiInstance = new CardApi();
        //Create a Card Program

        CardProgram programCard = new CardProgram();
        programCard.setName("Miller");
        programCard.setCardNetwork("visa");
        programCard.setCardType("credit");
        programCard.setIssuingBank("Santander");

        try {
            CardProgram result = apiInstance.createCardProgramUsingPost(programCard);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling createCardProgramUsingPost");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\CardApi(
    new GuzzleHttp\Client(),
    $config);
//Create CardProgram
$card_program = new \com\hydrogen\nucleus\Model\CardProgram();

try {
    $card_program->setCardType("visa");
    $card_program->setName("ANSC");
    $card_program->setCardNetwork("AXIS");
    $card_program->setIssuingBank("Santander");
    $result = $apiInstance->createCardProgramUsingPost($card_program);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->createCardProgramUsingPost: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::CardApi.new
#Create CardProgram
card_program = NucleusApi::CardProgram.new

begin
  card_program.name = "ABC"
  card_program.card_network = "BNC"
  card_program.card_type = "visa"
  card_program.issuing_bank = "santander"
  result = api_instance.create_card_program_using_post(card_program)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->create_card_program_using_post: #{e}"
end
var apiInstance = new HydrogenNucleusApi.CardApi();
//Create CardProgram
var card = new HydrogenNucleusApi.Card();
card.name = "AB";
card.card_network = "visa";
card.card_type = "debit";
card.issuing_bank = "Santander";


var newcard = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.createCardProgramUsingPost(card, newcard)

Example Response

{
    "id": "1692a3c2-65b0-46a0-9a0a-66bc949f7ca1",
    "secondary_id": null,
    "create_date": "2020-01-07T20:54:33.000+0000",
    "update_date": "2020-01-07T20:54:33.000+0000",
    "client_id": "87ef9136-f7e1-4ef0-8dbc-e58bf435d11c",
    "name": "E-Commerce Reloadable Program",
    "card_network": "visa",
    "card_type": "prepaid",
    "issuing_bank": "MetaBank",
    "card_processor": "Marqeta",
    "program_manager": "Marqeta",
    "code": "A89M4k28",
    "description": null,
    "is_delegated_authority": false,
    "is_active": true,
    "metadata": {}
}

Create a card program. The endpoint returns a card_program_id that can then be used to manage the program.

HTTP REQUEST

POST /card_program

ARGUMENTS

Parameter Type Required Description
name string required Name of the card program
card_network string required Card network for the cards being issued in the program. Value may be visa, mastercard, amex, or discover
card_type string required Type of cards being issued in the program. Value may be credit, debit, or prepaid
issuing_bank string required Name of the issuing or sponsor bank on the card program
card_processor string optional Name of the card processor for the card program
program_manager string optional Name of the card program manager
client_id UUID optional The id of a client to whom the card program belongs if it’s a business on your platform
code string optional Code used to identify the card program
description string optional Description of the card program
is_delegated_authority boolean optional Indicates if the card program is delegating authority for transaction authorizations. Defaults to false which indicates that it is active
is_active boolean optional Indicates if the card program is active. Defaults to true which indicates that it is active
metadata map optional Custom information associated with the card program in the format key:value
See Metadata
secondary_id string optional Alternate id that can be used to identify the object such as an internal id

Retrieve a card program

Example Request

curl -X GET -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/card_program/1692a3c2-65b0-46a0-9a0a-66bc949f7ca1"
api_instance = nucleus_api.CardApi(nucleus_api.ApiClient(configuration))
try:
    api_response = api_instance.get_card_program_using_get("9e401672-8ce2-4ffb-b63c-7e37dc8e6e5b")
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_card_program_using_get: %s\n" % e)
CardApi apiInstance = new CardApi();
        try {
            CardProgram responseProgram = apiInstance.getCardProgramUsingGet(UUID.fromString("850c5ab1-c7ce-4405-8a96-de159587d5fe"));
            System.out.println(responseProgram);
        } catch (ApiException e) {
            System.err.println("Exception when calling getCardProgramUsingGet");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\CardApi(
    new GuzzleHttp\Client(),
    $config);
$card_program_id = "850c5ab1-c7ce-4405-8a96-de159587d5fe"; // string | UUID card_program_id

try {
    $cardprogram = $apiInstance->getCardProgramUsingGet($card_program_id);
    print_r($cardprogram);
} catch (Exception $e) {
    echo 'Exception when calling CardApi->getCardProgramUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::CardApi.new
card_program_id = '850c5ab1-c7ce-4405-8a96-de159587d5fe' # String | UUID card_program_id

begin
  cardprogram = api_instance.get_card_program_using_get(card_program_id)
  p cardprogram
rescue NucleusApi::ApiError => e
  puts "Exception when calling CardApi->get_card_program_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.CardApi();
var cardprogramId = "9e401672-8ce2-4ffb-b63c-7e37dc8e6e5b";

var cardprogramm = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.getCardProgramUsingGet(cardprogramId, cardprogramm)

Example Response

{
    "id": "1692a3c2-65b0-46a0-9a0a-66bc949f7ca1",
    "secondary_id": null,
    "create_date": "2020-01-07T20:54:33.000+0000",
    "update_date": "2020-01-07T20:54:33.000+0000",
    "client_id": "87ef9136-f7e1-4ef0-8dbc-e58bf435d11c",
    "name": "E-Commerce Reloadable Program",
    "card_network": "visa",
    "card_type": "prepaid",
    "issuing_bank": "MetaBank",
    "card_processor": "Marqeta",
    "program_manager": "Marqeta",
    "code": "A89M4k28",
    "description": null,
    "is_delegated_authority": false,
    "is_active": true,
    "metadata": {}
}

Retrieve the information for a specific card program. The endpoint returns the card_program_id and details for the card program specified.

HTTP REQUEST

GET /card_program/{card_program_id}

Update a card program

Example Request

curl -X PUT -H "Authorization: Bearer <access_token>" \
-H "Content-Type: application/json" \
-d '{
      "name": "Online Reloadables"
      }' "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/card_program/1692a3c2-65b0-46a0-9a0a-66bc949f7ca1"
api_instance = nucleus_api.CardApi(nucleus_api.ApiClient(configuration))
# #Update CardProgram
program_Update = {'card_type': 'debit'}
program_id = '0450c2ab-e3a5-4344-a71e-74d47b207445'
try:
    api_response = api_instance.update_card_program_using_put(program_Update, program_id)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling update_card_program_using_put: %s\n" % e)
CardApi apiInstance = new CardApi();
        //Update a Card Program
        Map map = new HashMap();
        map.put("issuing_bank", "caixa");

        try {
            CardProgram response = apiInstance.updateCardProgramUsingPut(map, UUID.fromString("daca6ad1-9429-4ff7-93f5-e794d1ef12fb"));
            System.out.println(response);
        } catch (ApiException e) {
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\CardApi(
    new GuzzleHttp\Client(),
    $config);
//Update Card Program
$card_program_update = new stdClass();
$card_program_id = "bfc1b849-bd33-4660-b5a6-39ffa80d8c25";

try {
    $card_program_update->name = "ABC";
    $result = $apiInstance->updateCardProgramUsingPut($card_program_update, $card_program_id);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->updateCardProgramUsingPut: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::CardApi.new
#Update CardProgram
cprogram_update = {"name" => 'CAD'}
cprogram_id = 'af4bae06-30bc-4d5d-b819-ce3626bd2b20'
begin
  result = api_instance.update_card_program_using_put(cprogram_update, cprogram_id)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->update_card_program_using_put: #{e}"
end
var apiInstance = new HydrogenNucleusApi.CardApi();
//Update CardProgram
var apiInstance = new HydrogenNucleusApi.CardApi();
var callback = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
var cardprogramupdate = new HydrogenNucleusApi.Budget();
var cardprogramid = "781be039-fee9-4b5e-9fd8-f8ad6ceaf5c3";

cardprogramupdate.issuing_bank = "CITI";
apiInstance.updateCardProgramUsingPut(cardprogramupdate, cardprogramid, callback)

Example Response

{
    "id": "1692a3c2-65b0-46a0-9a0a-66bc949f7ca1",
    "secondary_id": null,
    "create_date": "2020-01-07T20:54:33.000+0000",
    "update_date": "2020-02-07T20:10:20.000+0000",
    "client_id": "87ef9136-f7e1-4ef0-8dbc-e58bf435d11c",
    "name": "Online Reloadables",
    "card_network": "visa",
    "card_type": "prepaid",
    "issuing_bank": "MetaBank",
    "card_processor": null,
    "program_manager": "Marqeta",
    "code": "A89M4k28",
    "description": null,
    "is_delegated_authority": false,
    "is_active": true,
    "metadata": {}
}

Update the information for a card program. The unique card_program_id must be provided. To obtain the appropriate card_program_id, use the GET /card_program endpoint to view all cards stored for your tenant and their current information. The details to be updated must also be provided. The endpoint returns the card_program_id and the details for the card.

HTTP REQUEST

PUT /card_program/{card_program_id}

Delete a card program

Example Request

curl -X DELETE -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/card_program/0233ab54-58a0-4b43-aa65-a1c32f29ad69"
api_instance = nucleus_api.CardApi(nucleus_api.ApiClient(configuration))
# # #  # Delete a CardProgram
cardprogram_id = 'af4bae06-30bc-4d5d-b819-ce3626bd2b20'
try:
    api_instance.delete_card_program_using_delete(cardprogram_id)
except ApiException as e:
    print("Exception when delete_card_program_using_delete: %s\n" % e)
CardApi apiInstance = new CardApi();
        //   Delete Card Program
        try {
            CardProgram deleteresponse = apiInstance.deleteCardProgramUsingDelete(UUID.fromString("a72bdc2c-8fb6-4281-9770-43deabdcbf46"));
            System.out.println(deleteresponse);
        } catch (ApiException e) {
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\CardApi(
    new GuzzleHttp\Client(),
    $config);
//Delete CardProgram
$card_program_did = "de9a2bcd-ee42-43c3-83d9-5ba3689dfbde"; // string | UUID account_id

try {
    $apiInstance->deleteCardProgramUsingDelete($card_program_did);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->deleteCardProgramUsingDelete: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::CardApi.new
#Delete Card program
cprogram1_id = 'ed7804b2-678c-4693-b21c-4df4ac3006bb'
begin
  result = api_instance.delete_card_program_using_delete(cprogram1_id)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->delete_card_program_using_delete: #{e}"
end
var apiInstance = new HydrogenNucleusApi.CardApi();
//Delete a CardProgram
var cardpid = "daca6ad1-9429-4ff7-93f5-e794d1ef12fb";


var deletecardprogram = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully.');
    }
};
apiInstance.deleteCardProgramUsingDelete(cardpid, deletecardprogram)

Response (204 No Content)

Permanently delete a card program. The unique card_program_id must be provided. To obtain the appropriate card_program_id, use the GET /card_program endpoint to view all cards stored for your tenant. This deletes the card_program_id and all card record information.

HTTP REQUEST

DELETE /card_program/{card_program_id}

Spending Control

Spending controls can be added at a client level for all cards associated with the client. These controls will restrict purchases and ATM withdrawal amounts, as well as spending within a category or at a specific merchant.

Field Type Description
id UUID The id of the spending control
client_id UUID The id of the Client to whom the control belongs. If no client_id supplied, the control will be applied to all cardholders.
currency_code string Alphabetic currency code for the control. See currency codes
control_type string Type of spending control to apply. Value may be spending_limit, transaction_limit, allow_list, deny_list
control_scope string Scope of the spending control. Value may be all, purchase, atm_withdrawal, transaction_category_id, mid, mcc
control_values array Value of the transaction_category_id, mid, or mcc
limit_value double Value of the transaction_limit or spending_limit. Must be > 0.
frequency_unit string Frequency of the control. Value may be one_time, daily, weekly, monthly, quarterly, or annually. Value may not be one_time when control_type = “transaction_limit”.
frequency integer Number of frequency_unit between each control. For example, if the frequency_unit is weekly and the frequency is 2, this means the control occurs every two weeks. Default is 1. Must be >= 1.
description string Description of the spending control
client_group string group identifier used in Client to group clients for the spending control
is_active boolean Indicates if the control is currently active. Defaults to true which indicates it is active
metadata map Custom information associated with the control in the format key:value
See Metadata
secondary_id string Alternate id that can be used to identify the object such as an internal id
create_date timestamp Timestamp for the date and time that the record was created
update_date timestamp Timestamp for the date and time that the record was last updated

List all spending controls

Example Request

curl -X GET -H "Authorization: Bearer <access_token>" \
  "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/spending_control"
api_instance = nucleus_api.SpendingControlApi(nucleus_api.ApiClient(configuration))
#List all SpendingControl
ascending = False # bool | ascending (optional) (default to false)
filter = 'nu' # str | filter (optional)
order_by = 'update_date' # str | order_by (optional) (default to update_date)
page = 0 # int | page (optional) (default to 0)
size = 25 # int | size (optional) (default to 25)

try:
    # List all Spending Control
    api_response = api_instance.get_spending_control_all_using_get(ascending=ascending, order_by=order_by, page=page, size=size)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling SpendingControlApi->get_spending_control_all_using_get: %s\n" % e)
    SpendingControlApi apiInstance = new SpendingControlApi();
    //Get all SpendingControl
    try{
    PageSpendingControl spendingResponse = apiInstance.getSpendingControlAllUsingGet(true, null, null, 0, 10);
    System.out.println(spendingResponse);
} catch (ApiException e) {
        e.printStackTrace();
    }
$apiInstance = new com\hydrogen\nucleus\Api\SpendingControlApi(
    new GuzzleHttp\Client(),
    $config);
//List all SpendingControl
$ascending = false; // bool | ascending
$filter = null; // string | filter
$order_by = null; // string | order_by
$page = 0; // int | page
$size = 25; // int | size

try {
    $result = $apiInstance->getSpendingControlAllUsingGet($ascending, $filter, $order_by, $page, $size);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling SpendingControlApi->getSpendingControlAllUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::SpendingControlApi.new
#List all Spending Control
opts = {
    ascending: false, # BOOLEAN | ascending
    filter: nil, # String | filter
    order_by: nil, # String | order_by
    page: 0, # Integer | page
    size: 25 # Integer | size
}

begin
  result = api_instance.get_spending_control_all_using_get(opts)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling SpendingControlApi->get_spending_control_all_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.SpendingControlApi();
//List all SpendingControl
var opts = {
    'ascending': false, // Boolean | ascending
    'filter': null, // String | filter
    'orderBy': null, // String | order_by
    'page': 0, // Number | page
    'size': 25 // Number | size
};

var spendinglist = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.getSpendingControlAllUsingGet(opts, spendinglist);

Example Response

{
    "content": [
      {
        "client_id": "81608d36-67f3-4e79-9906-5153d3d7dc5d",
        "currency_code": "USD",
        "control_type": "spending_limit",
        "control_scope": "transaction_category",
        "control_values": [
            "Entertainment",
            "Food & Dining",
            "Travel"
        ],
        "limit_value": 1000,
        "frequency_unit": "weekly",
        "frequency": 1,
        "description": null,
        "client_group": null,
        "is_active": true,
        "metadata":{},
        "secondary_id": null,
        "create_date": "2020-12-16T09:13:51.697+0000",
        "update_date": "2020-12-16T09:22:08.170+0000"
      },
      {
        "client_id": "81608d36-67f3-4e79-9906-5153d3d7dc5d",
        "currency_code": "USD",
        "control_type": "allow_list",
        "control_scope": "transaction_category",
        "control_values": [
            "Entertainment",
            "Food & Dining",
            "Travel"
        ],
        "limit_value": null,
        "frequency_unit": null,
        "frequency": null,
        "description": null,
        "client_group": null,
        "is_active": true,
        "metadata":{},
        "secondary_id": null,
        "create_date": "2020-12-16T09:13:51.697+0000",
        "update_date": "2020-12-16T09:22:08.170+0000"
      }
    ],
    "last": true,
    "total_pages": 1,
    "total_elements": 2,
    "number_of_elements": 2,
    "first": true,
    "sort": [
        {
            "direction": "DESC",
            "property": "updateDate",
            "ignore_case": false,
            "null_handling": "NATIVE",
            "ascending": false,
            "descending": true
        }
    ],
    "size": 25,
    "number": 0
}

Get information for all spending controls stored for your tenant. You can filter using one of the unique ids such as the client_id to view the controls for a client or for another particular entity.

HTTP REQUEST

GET /spending_control

Create a spending control

Example Request

curl -X POST -H "Authorization: Bearer <access_token>" \
-H "Content-Type: application/json" \
-d '{
        "client_id": "81608d36-67f3-4e79-9906-5153d3d7dc5d",
        "currency_code": "USD",
        "control_type": "spending_limit",
        "control_scope": "transaction_category",
        "control_values": [
            "Entertainment",
            "Food & Dining",
            "Travel"
        ],
        "limit_value": 1000,
        "frequency_unit": "weekly",
        "frequency": 1
    }' "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/spending_control"
api_instance = nucleus_api.SpendingControlApi(nucleus_api.ApiClient(configuration))
#Create Spending Control
spending_control = nucleus_api.SpendingControl(client_id='44ca12fd-bc14-48e2-b699-1c2507323970', control_scope='merchant', control_type='allow_list', currency_code='USD') # SpendingControl | spendingControl
spending_control.control_values = ['Frank & Oak']

try:
    api_response = api_instance.create_spending_control_using_post(spending_control)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling SpendingControlApi->create_spending_control_using_post: %s\n" % e)
SpendingControlApi apiInstance = new SpendingControlApi();
//Create a SpendingControl
SpendingControl spending = new SpendingControl();
spending.setClientId(UUID.fromString("652584da-bc46-436e-9630-80c5d87b77ff"));
spending.setCurrencyCode("AUD");
spending.setControlScope("transaction_category");
spending.setControlType("spending_limit");
List<String> values = new ArrayList();
values.add("Entertainment");
spending.setControlValues(values);
spending.setLimitValue(100.00);
spending.setFrequencyUnit("weekly");

try {
    SpendingControl result = apiInstance.createSpendingControlUsingPost(spending);
    System.out.println(result);
} catch (ApiException e) {
    System.err.println("Exception when calling createSpendingControlUsingPost");
    e.printStackTrace();
}
$apiInstance = new com\hydrogen\nucleus\Api\SpendingControlApi(
    new GuzzleHttp\Client(),
    $config);
//Create a Spending Control
$spending_control = new \com\hydrogen\nucleus\Model\SpendingControl(); // \com\hydrogen\nucleus\Model\SpendingControl | spendingControl

try {
    $spending_control->setClientId("310d92d9-2090-4d68-9262-147bfa22674e");
    $spending_control->setCurrencyCode("USD");
    $spending_control->setControlType("deny_list");
    $spending_control->setControlScope("merchant");
    $spending_control->setControlValues(["Transfer12"]);
    $result = $apiInstance->createSpendingControlUsingPost($spending_control);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling SpendingControlApi->createSpendingControlUsingPost: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::SpendingControlApi.new
#Create a Spending Control
spending_control = NucleusApi::SpendingControl.new # SpendingControl | spendingControl
spending_control.client_id ="9e1d585c-0b68-4341-8a50-dd53eb1a4de7"
spending_control.currency_code = "USD"
spending_control.control_scope = "merchant"
spending_control.control_type = "allow_list"
spending_control.control_values = ["Transfer12"]

begin
  result = api_instance.create_spending_control_using_post(spending_control)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling SpendingControlApi->create_spending_control_using_post: #{e}"
end
var apiInstance = new HydrogenNucleusApi.SpendingControlApi();
//Create SpendingControl

var spendingControl = new HydrogenNucleusApi.SpendingControl(); // SpendingControl | spendingControl

spendingControl.client_id = 'e1bbae4a-6e15-425f-93fd-d715fd228280';
spendingControl.currency_code = 'USD';
spendingControl.control_type = 'allow_list';
spendingControl.control_scope = 'merchant';
var hs;
hs = ["Frank & Oak"];
spendingControl.control_values = hs;


var spendingNew = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.createSpendingControlUsingPost(spendingControl, spendingNew);

Example Response

{
  "client_id": "81608d36-67f3-4e79-9906-5153d3d7dc5d",
  "currency_code": "USD",
  "control_type": "spending_limit",
  "control_scope": "transaction_category",
  "control_values": [
      "Entertainment",
      "Food & Dining",
      "Travel"
  ],
  "limit_value": 1000,
  "frequency_unit": "weekly",
  "frequency": 1,
  "description": null,
  "client_group": null,
  "is_active": true,
  "metadata":{},
  "secondary_id": null,
  "create_date": "2020-12-16T09:13:51.697+0000",
  "update_date": "2020-12-16T09:22:08.170+0000"
}

Create a spending control for a client. The endpoint returns a spending_control_id that can then be used to manage the control.

HTTP REQUEST

POST /spending_control

ARGUMENTS

Parameter Type Required Description
currency_code string required Alphabetic currency code for the control. See currency codes
control_type string required Type of spending control to apply. Value may be spending_limit, transaction_limit, allow_list, deny_list
control_scope string required Scope of the spending control. Value may be all, purchase, atm_withdrawal, transaction_category_id, mid, mcc
control_values array required Value of thetransaction_category_id, mid, or mcc
limit_value double required, conditional Value of the transaction_limit or spending_limit. Conditionally required if control_type = “transaction_limit” or “spending_limit”. Must be > 0.
frequency_unit string required, conditional Frequency of the control. Value may be one_time, daily, weekly, monthly, quarterly, or annually. Value may not be one_time when control_type = “transaction_limit”. Conditionally required if control_type = “spending_limit” or “transaction_limit”
frequency integer optional Number of frequency_unit between each control. For example, if the frequency_unit is weekly and the frequency is 2, this means the control occurs every two weeks. Default is 1. Must be >= 1.
client_id UUID optional The id of the client to whom the control belongs. If no client_id supplied, the control will be applied to all cardholders.
description string optional Description of the spending control
client_group string optional group identifier used in Client to group clients for the spending control
is_active boolean optional Indicates if the control is currently active. Defaults to true which indicates it is active
metadata map optional Custom information associated with the control in the format key:value
See Metadata
secondary_id string optional Alternate id that can be used to identify the object such as an internal id

Retrieve a spending control

Example Request

curl -X GET -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/spending_control/81608d36-67f3-4e79-9906-5153d3d7dc5d"
api_instance = nucleus_api.SpendingControlApi(nucleus_api.ApiClient(configuration))
#Retrieve Spending Control
spending_control_id = '2bcc3f4f-275d-4ae2-a5de-1a020fb59cf8' # str | spending_control_id

try:
    api_response = api_instance.get_spending_control_using_get(spending_control_id)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling SpendingControlApi->get_spending_control_using_get: %s\n" % e)
SpendingControlApi apiInstance = new SpendingControlApi();
//Retrieve a SpendingControl
try{
SpendingControl response = apiInstance.getSpendingControlUsingGet(UUID.fromString("879eb321-efa1-41d0-a29a-3ee1c4991174"));
System.out.println(response);
} catch (ApiException e) {
    e.printStackTrace();
}
$apiInstance = new com\hydrogen\nucleus\Api\SpendingControlApi(
    new GuzzleHttp\Client(),
    $config);
//Retrieve SpendingControl
$spending_control_id = "879eb321-efa1-41d0-a29a-3ee1c4991174"; // string | spending_control_id

try {
    $result = $apiInstance->getSpendingControlUsingGet($spending_control_id);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling SpendingControlApi->getSpendingControlUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::SpendingControlApi.new
#Retrieve an Spending Control
spending_control_id = '879eb321-efa1-41d0-a29a-3ee1c4991174' # String | spending_control_id


begin
  result = api_instance.get_spending_control_using_get(spending_control_id)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling SpendingControlApi->get_spending_control_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.SpendingControlApi();
//Retrieve a SpendingControl
var spendingControlId = "6c6b2fd8-fbb4-4b38-a6fe-0778818d6e97"; // String | spending_control_id


var spending = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.getSpendingControlUsingGet(spendingControlId, spending);

Example Response

{
  "client_id": "81608d36-67f3-4e79-9906-5153d3d7dc5d",
  "currency_code": "USD",
  "control_type": "spending_limit",
  "control_scope": "transaction_category",
  "control_values": [
      "Entertainment",
      "Food & Dining",
      "Travel"
  ],
  "limit_value": 1000,
  "frequency_unit": "weekly",
  "frequency": 1,
  "description": null,
  "client_group": null,
  "is_active": true,
  "metadata":{},
  "secondary_id": null,
  "create_date": "2020-12-16T09:13:51.697+0000",
  "update_date": "2020-12-16T09:22:08.170+0000"
}

Retrieve the information for a specific card control associated with a client. The endpoint returns the spending_control_id and details for the card specified.

HTTP REQUEST

GET /spending_control/{spending_control_id}

Update a spending control

Example Request

curl -X PUT -H "Authorization: Bearer <access_token>" \
-H "Content-Type: application/json" \
-d '{
      "control_values": [
        "Entertainment",
        "Food & Dining",
        "Automotive"
      ]
    }' "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/spending_control/81608d36-67f3-4e79-9906-5153d3d7dc5d"
api_instance = nucleus_api.SpendingControlApi(nucleus_api.ApiClient(configuration))
#Update Spending Control
spending_control = {'currency_code': 'GBP'} # object | spending_control
spending_control_id = '2bcc3f4f-275d-4ae2-a5de-1a020fb59cf8' # str | UUID spending_control_id

try:
    api_response = api_instance.update_spending_control_using_put(spending_control, spending_control_id)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling SpendingControlApi->update_spending_control_using_put: %s\n" % e)
SpendingControlApi apiInstance = new SpendingControlApi();
//Update A SpendingControl

Map map = new HashMap();
map.put("currency_code", "GBP");

try {
    SpendingControl response = apiInstance.updateSpendingControlUsingPut(map, UUID.fromString("683d862d-f26e-4479-a848-29a09149ee30"));
    System.out.println(response);
} catch (ApiException e) {
    e.printStackTrace();
}
$apiInstance = new com\hydrogen\nucleus\Api\SpendingControlApi(
    new GuzzleHttp\Client(),
    $config);
//Update Spending Control
$spending_control = new \stdClass; // object | spending_control
$spending_control-> currency_code ="USD";
$spending_control_id = "879eb321-efa1-41d0-a29a-3ee1c4991174"; // string | UUID spending_control_id

try {
    $result = $apiInstance->updateSpendingControlUsingPut($spending_control, $spending_control_id);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling SpendingControlApi->updateSpendingControlUsingPut: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::SpendingControlApi.new
#Update Spending Control
spending_control = {"currency_code" => 'CAD'}

spending_control_id = '879eb321-efa1-41d0-a29a-3ee1c4991174' # String | UUID spending_control_id

begin
  result = api_instance.update_spending_control_using_put(spending_control, spending_control_id)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling SpendingControlApi->update_spending_control_using_put: #{e}"
end
var apiInstance = new HydrogenNucleusApi.SpendingControlApi();
//Update SpendingControl

var spendingControlId = "9edc4ef4-412c-40a5-84d2-915f31410854"; // String | UUID spending_control_id


var updateSpending = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
const updateSpendingcontrol = () => {
    var api = new HydrogenNucleusApi.SpendingControlApi()
    var spending = new HydrogenNucleusApi.SpendingControl(); // {AccountAllocationMapping} allocRequest
    spending.currency_code = "GBP";
    apiInstance.updateSpendingControlUsingPut(spending, spendingControlId, updateSpending);
}

Example Response

{
  "client_id": "81608d36-67f3-4e79-9906-5153d3d7dc5d",
  "currency_code": "USD",
  "control_type": "spending_limit",
  "control_scope": "transaction_category",
  "control_values": [
      "Entertainment",
      "Food & Dining",
      "Automotive"
  ],
  "limit_value": 1000,
  "frequency_unit": "weekly",
  "frequency": 1,
  "description": null,
  "client_group": null,
  "is_active": true,
  "metadata":{},
  "secondary_id": null,
  "create_date": "2020-12-16T09:13:51.697+0000",
  "update_date": "2020-12-16T09:22:08.170+0000"
}

Update the information for a spending control. The unique spending_control_id must be provided. To obtain the appropriate spending_control_id, use the GET /spending_control endpoint to view all controls stored for your tenant and their current information. The details to be updated must also be provided. The endpoint returns the spending_control_id and the details for the control.

HTTP REQUEST

PUT /spending_control/{spending_control_id}

Delete a spending control

Example Request

curl -X DELETE -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/spending_control/81608d36-67f3-4e79-9906-5153d3d7dc5d"
api_instance = nucleus_api.SpendingControlApi(nucleus_api.ApiClient(configuration))
#Delete a SpendingControl
spending_control_id = '2bcc3f4f-275d-4ae2-a5de-1a020fb59cf8' # str | spending_control_id

try:
    # Delete a Spending Control
    api_instance.delete_spending_control_using_delete(spending_control_id)
except ApiException as e:
    print("Exception when calling SpendingControlApi->delete_spending_control_using_delete: %s\n" % e)
SpendingControlApi apiInstance = new SpendingControlApi();
//Delete a SpendingControl
try {
    SpendingControl deleteresponse = apiInstance.deleteSpendingControlUsingDelete(UUID.fromString("ef046ea4-4cd0-41ec-9b43-b0a16fafd805"));
    System.out.println(deleteresponse);
} catch (ApiException e) {
    e.printStackTrace();
}
$apiInstance = new com\hydrogen\nucleus\Api\SpendingControlApi(
    new GuzzleHttp\Client(),
    $config);
//Delete Spending COntrol
$spending_control_id = "879eb321-efa1-41d0-a29a-3ee1c4991174"; // string | spending_control_id

try {
    $apiInstance->deleteSpendingControlUsingDelete($spending_control_id);
} catch (Exception $e) {
    echo 'Exception when calling SpendingControlApi->deleteSpendingControlUsingDelete: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::SpendingControlApi.new
#Delete Spending Control
spending_control_id = '879eb321-efa1-41d0-a29a-3ee1c4991174' # String | spending_control_id

begin
  api_instance.delete_spending_control_using_delete(spending_control_id)
rescue NucleusApi::ApiError => e
  puts "Exception when calling SpendingControlApi->delete_spending_control_using_delete: #{e}"
end
var apiInstance = new HydrogenNucleusApi.SpendingControlApi();
//Delete a SpendingControl
var spendingControlId = "6c6b2fd8-fbb4-4b38-a6fe-0778818d6e97"; // String | spending_control_id


var deletespending = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully.');
    }
};
apiInstance.deleteSpendingControlUsingDelete(spendingControlId, deletespending);

Response (204 No Content)

Permanently delete a spending control. The unique spending_control_id must be provided. To obtain the appropriate spending_control_id, use the GET /spending_control endpoint to view all controls stored for your tenant. This deletes the spending_control_id and all control record information.

HTTP REQUEST

DELETE /spending_control/{spending_control_id}

PFM & Wealth

Aggregation Account

Aggregation Account Management

Aggregation accounts are created below clients to store the details of individual, held-away accounts. Held-away accounts are usually checking accounts, savings accounts, credit cards, mortgages, or external investment accounts that are managed by external institutions independent of your firm. Held-away account information can be captured by integrating with a third-party service which supports Account Aggregation or via manual client entry. This information can be used to provide customers with a better picture of their current financial health and gain business insights on holdings outside of the application.

Field Type Description
id UUID The id for the aggregation account
client_id UUID The id of a client to which the aggregation account belongs
business_id UUID The id of the business](#Business) to which the aggregation account belongs
account_name string The name of the held-away account for this aggregation account record
account_holder string The owner of the held-away account
institution_id UUID ID of the institution resource for this held-away account. Either this name or the institution_name must be supplied.
institution_name string Name of the institution for the held-away account, e.g. HSBC. Either this name or the institution_id must be supplied.
account_category_id UUID ID of the category resource for this held-away account
category string Category for the held-away account such as “Bank Account”
subcategory string Subcategory for the held-away account such as “Checking Account”
mask string The masked version of the account number of the held-away account for this aggregation account record
currency_code string Alphabetic currency code for the base currency of the account linked, limited to 3 characters. See currency codes
bank_link_id UUID If the held away account is also being used as a bank link, the id of the bank link
interest_rate float Percentage rate that is paid on a financial instrument
apr float Annual Percentage Rate, or how much is owed on a loan, mortgage loan, credit card account balance in one year
apy float Annual Percentage yield, or how much a bank account or savings instrument earns in one year, including compound interest
credit_limit float Limit on a credit card, or max that can be kept as a balance
death_benefit float Amount paid to a beneficiary on an insurance policy upon the death of an insured person
minimum_payment float Minimum amount owed on a loan, credit card, or mortgage
last_payment float Last payment amount on a loan, credit card, or mortgage
last_payment_date timestamp Last payment date on a loan, credit card, or mortgage
next_payment_date timestamp Next payment date on a loan, credit card, or mortgage
maturity_date timestamp Date that a loan or financial instrument matures, or expires
is_link_verified boolean A flag to represent if this held away account has been verified if also being used as a bank_link. Defaults to false which indicates it has not been verifed.
is_manual boolean Indicates if the aggregation account was added manually or by an integration vendor. Defaults to false which indicates it was not added manually
is_active boolean Indicates if the aggregation account record is active. Defaults to true which indicates it is active
metadata map Custom information associated with the aggregation account in the format key:value
See Metadata
secondary_id string Alternate id that can be used to identify the object such as an internal id
create_date timestamp Timestamp for the date and time that the record was created
update_date timestamp Timestamp for the date and time that the record was last updated

List all aggregation accounts

Example Request

curl -X GET -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/aggregation_account"
api_instance = nucleus_api.AggregationAccountApi(nucleus_api.ApiClient(configuration))
try:
    api_response = api_instance.get_aggregation_account_all_using_get()
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_aggregation_account_all_using_get: %s\n" % e)
AggregationAccountApi apiInstance = new AggregationAccountApi();
try {
            PageAggregationAccount List = apiInstance.getAggregationAccountAllUsingGet(true, null, null, 1, 5);
            System.out.println(List);
        } catch (ApiException e) {
            System.err.println("Exception when calling getAggregationAccountAllUsingGet");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\AggregationAccountApi(
    new GuzzleHttp\Client(),
    $config);
$ascending = false; // bool | ascending
$filter = null; // string | filter
$order_by = null; // string | order_by
$page = 0; // int | page
$size = 10; // int | size

try {
    $aggregationlist = $apiInstance->getAggregationAccountAllUsingGet($ascending, $filter, $order_by, $page, $size);
    print_r($aggregationlist);
} catch (Exception $e) {
    echo 'Exception when calling AggregationAccountApi->getAggregationAccountAllUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::AggregationAccountApi.new
opts = {
    ascending: false, # BOOLEAN | ascending
    filter: null, # String | filter
    order_by: null, # String | order_by
    page: 0, # Integer | page
    size: 25 # Integer | size
}

begin
  #List all aggregation accounts
  aggregationlist = api_instance.get_aggregation_account_all_using_get(opts)
  p aggregationlist
rescue NucleusApi::ApiError => e
  puts "Exception when calling AggregationAccountApi->get_aggregation_account_all_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.AggregationAccountApi();
var opts = {
    'ascending': false, // Boolean | ascending
    // 'filter': "", // String | filter
    'orderBy': "update_date", // String | order_by
    'page': 0, // Number | page
    'size': 25 // Number | size
};

var aggregationaccountlist = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.getAggregationAccountAllUsingGet(opts, aggregationaccountlist)

Example Response

{
    "content": [
        {
            "id": "f96fad3e-a8cf-4915-bc0c-da4d9693ab83",
            "create_date": "2017-01-03T00:00:00.000+0000",
            "update_date": "2017-01-05T00:00:00.000+0000",
            "client_id": "b1d2b9dc-fb9d-4ce2-b2df-eb8801127b23",
            "business_id": null,
            "account_name": "Bank Gold Checking",
            "institution_id": null,
            "institution_name": "Citywide Bank",
            "account_category_id": null,
            "category": "Bank Account",
            "subcategory": "Checking Account",
            "mask": "XXXXX8991",
            "currency_code": "USD",
            "bank_link_id": null,
            "interest_rate": null,
            "apr": null,
            "apy": null,
            "credit_limit": null,
            "death_benefit": null,
            "minimum_payment": null,
            "last_payment": null,
            "last_payment_date": null,
            "next_payment_date": null,
            "maturity_date": null,
            "is_manual": false,
            "is_active": true,
            "metadata": {}
        },
        {
            "id": "e04683e9-d1d2-4382-86f0-88092971435e",
            "create_date": "2017-01-03T00:00:00.000+0000",
            "update_date": "2017-01-05T00:00:00.000+0000",
            "client_id": "63c4690b-88c3-47f4-b3d7-d4957eea9c3c",
            "business_id": null,
            "account_name": "Priority Savings - 4455",
            "account_holder": "John Doe",
            "institution_id": null,
            "institution_name": "Citywide Bank",
            "account_category_id": null,
            "category": "Bank Account",
            "subcategory": "Savings Account",
            "mask": "XXXXX9916",
            "currency_code": "USD",
            "bank_link_id": null,
            "interest_rate": null,
            "apr": null,
            "apy": null,
            "credit_limit": null,
            "death_benefit": null,
            "minimum_payment": null,
            "last_payment": null,
            "last_payment_date": null,
            "next_payment_date": null,
            "maturity_date": null,
            "is_manual": false,
            "is_active": true,
            "metadata": {}
        }
        ],
    "last": false,
    "total_pages": 1,
    "total_elements": 2,
    "sort": [
        {
            "direction": "DESC",
            "property": "updateDate",
            "ignore_case": false,
            "null_handling": "NATIVE",
            "descending": true,
            "ascending": false
        }
    ],
    "first": true,
    "number_of_elements": 2,
    "size": 25,
    "number": 0
}

Get information for all aggregation accounts for all clients defined for your tenant. You can filter using a unique client_id to view the accounts for a client. To identify the appropriate client_id, use the GET /client endpoint to see all clients defined for your tenant. Note that the metadata information is stored as a nested object within the aggregation account object.

HTTP REQUEST

GET /aggregation_account

Create an aggregation account

Example Request

curl -X POST -H "Authorization: Bearer <access_token>" \
-H "Content-Type: application/json" \
-d '{
      "client_id": "b1d2b9dc-fb9d-4ce2-b2df-eb8801127b23",
      "account_name": "Bank Gold Checking",
      "institution_name": "Citywide Bank",
      "category": "Bank Account",
      "subcategory": "Checking Account",
      "mask": "XXXXX8991",
      "currency_code": "USD"
     }' "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/aggregation_account"
api_instance = nucleus_api.AggregationAccountApi(nucleus_api.ApiClient(configuration))
# # Create a Aggregation Account
aggregationAccount = nucleus_api.AggregationAccount(client_id="fb13e558-ae11-4976-9c77-ee6918536ad9", account_name="Primary Account", institution_name="Barcelona", category="Investment")
try:
    api_response = api_instance.create_aggregation_account_using_post(aggregationAccount)
    pprint(api_response)
except ApiException as e:
    print("create_aggregation_account_using_post: %s\n" % e)
AggregationAccountApi apiInstance = new AggregationAccountApi();
        //Create an Aggregation Account
        AggregationAccount aggregationAccount = new AggregationAccount();
        aggregationAccount.accountName("Primary Account");
        aggregationAccount.clientId(UUID.fromString("b6416638-347e-4c6a-8604-dfec04846a31"));
        aggregationAccount.institutionName("Barcelona");
        aggregationAccount.category("Investment");
        try {
            AggregationAccount result = apiInstance.createAggregationAccountUsingPost(aggregationAccount);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling createAggregationAccountUsingPost");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\AggregationAccountApi(
    new GuzzleHttp\Client(),
    $config);
//Create Aggregation Account
$aggregation_account = new \com\hydrogen\nucleus\Model\AggregationAccount();

try {
    $aggregation_account->setClientId("b6416638-347e-4c6a-8604-dfec04846a31");
    $aggregation_account->setInstitutionName("ABC");
    $aggregation_account->setAccountName("New");
    $aggregation_account->setCategory("New");

    $result = $apiInstance->createAggregationAccountUsingPost($aggregation_account);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->createAggregationAccountUsingPost: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::AggregationAccountApi.new
#Create Aggregation Account
agg_account = NucleusApi::AggregationAccount.new

begin
  agg_account.client_id = "efd3285c-7eb9-4d3e-81a1-da05350c292a"
  agg_account.institution_name = "name"
  agg_account.account_name = "NMC"
  agg_account.category = "ABC"
  result = api_instance.create_aggregation_account_using_post(agg_account)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->create_aggregation_account_using_post: #{e}"
end
var apiInstance = new HydrogenNucleusApi.AggregationAccountApi();
//Create Aggregation Account

var aggaccount = new HydrogenNucleusApi.AggregationAccount();
aggaccount.client_id = 'b6416638-347e-4c6a-8604-dfec04846a31';
aggaccount.account_name = "New Account";
aggaccount.institution_name = "Bayern";
aggaccount.category = "New";

var newaggregation = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.createAggregationAccountUsingPost(aggaccount, newaggregation)

Example Response

{
    "id": "f96fad3e-a8cf-4915-bc0c-da4d9693ab83",
    "create_date": "2017-01-03T00:00:00.000+0000",
    "client_id": "b1d2b9dc-fb9d-4ce2-b2df-eb8801127b23",
    "business_id": null,
    "account_name": "Bank Gold Checking",
    "institution_id": null,
    "institution_name": "Citywide Bank",
    "account_category_id": null,
    "category": "Bank Account",
    "subcategory": "Checking Account",
    "mask": "XXXXX8991",
    "currency_code": "USD",
    "bank_link_id": null,
    "interest_rate": null,
    "apr": null,
    "apy": null,
    "credit_limit": null,
    "death_benefit": null,
    "minimum_payment": null,
    "last_payment": null,
    "last_payment_date": null,
    "next_payment_date": null,
    "maturity_date": null,
    "is_manual": false,
    "is_active": true,
    "metadata": {}
}

Create an aggregation account under a client. In order to create an account, the client must have already registered and the client_id must be provided. To identify the appropriate client_id, use the GET /client endpoint to see all clients for your tenant. The endpoint returns an aggregation_account_id that can then be used to manage the aggregation account record and mapped to balance records for the aggregation account.

HTTP REQUEST

POST /aggregation_account

ARGUMENTS

Parameter Type Required Description
client_id UUID required, conditional The id of a client to which the aggregation account belongs. Either this id or the business_id must be supplied.
business_id UUID required, conditional The id of the business](#Business) to which the aggregation account belongs. Either this id or the client_id must be supplied.
account_name string required The name of the held-away account for this aggregation account record
institution_id UUID required, conditional ID of the institution resource for this held-away account. Either this name or the institution_name must be supplied.
institution_name string required, conditional Name of the institution for the held-away account, e.g. HSBC. Either this name or the institution_id must be supplied.
account_category_id UUID optional ID of the category resource for this held-away account
category string optional Category for the held-away account such as “Bank Account”
subcategory string optional Subcategory for the held-away account such as “Checking Account”
account_holder string optional The owner of the held-away account
mask string optional The masked version of the account number of the held-away account for this aggregation account record
currency_code string optional Alphabetic currency code for the base currency of the account linked, limited to 3 characters. See currency codes
bank_link_id UUID optional If the held away account is also being used as a bank link, the id of the bank link
interest_rate float optional Interest rate that is paid on a financial instrument
apr float optional Annual Percentage Rate, or how much is owed on a loan, mortgage loan, credit card account balance in one year
apy float optional Annual Percentage yield, or how much a bank account or savings instrument earns in one year, including compound interest
credit_limit float optional Limit on a credit card, or max that can be kept as a balance
death_benefit float optional Amount paid to a beneficiary on an insurance policy upon the death of an insured person
minimum_payment float optional Minimum amount owed on a loan, credit card, or mortgage
last_payment float optional Last payment amount on a loan, credit card, or mortgage
last_payment_date timestamp optional Last payment date on a loan, credit card, or mortgage
next_payment_date timestamp optional Next payment date on a loan, credit card, or mortgage
maturity_date timestamp optional Date that a loan or financial instrument matures, or expires
is_link_verified boolean optional A flag to represent if this held away account has been verified if also being used as a bank_link. Defaults to false which indicates it has not been verified.
is_manual boolean optional Indicates if the aggregation account was added manually or by an integration vendor. Defaults to false which indicates it was not added manually
is_active boolean optional Indicates if the aggregation account record is active. Defaults to true which indicates it is active
metadata map optional Custom information associated with the aggregation account in the format key:value
See Metadata
secondary_id string optional Alternate id that can be used to identify the object such as an internal id

Retrieve an aggregation account

Example Request

curl -X GET -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/aggregation_account/f96fad3e-a8cf-4915-bc0c-da4d9693ab83"
api_instance = nucleus_api.AggregationAccountApi(nucleus_api.ApiClient(configuration))
try:
    api_response = api_instance.get_aggregation_account_using_get("f3a029dd-d8bb-4853-8212-8da1bf00abb4")
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_aggregation_account_using_get: %s\n" % e)
AggregationAccountApi apiInstance = new AggregationAccountApi();
        AggregationAccount response = null;
        try {
            response = apiInstance.getAggregationAccountUsingGet(UUID.fromString("7dd240dd-3994-4cfc-9bf8-ddb5b63d51be"));
            System.out.println(response);
        } catch (ApiException e) {
            System.err.println("Exception when calling getAggregationAccountUsingGet");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\AggregationAccountApi(
    new GuzzleHttp\Client(),
    $config);
$aggregation_account_id = "7dd240dd-3994-4cfc-9bf8-ddb5b63d51be"; // string | UUID aggregation_account_id

try {
    $aggregationaccount = $apiInstance->getAggregationAccountUsingGet($aggregation_account_id);
    print_r($aggregationaccount);
} catch (Exception $e) {
    echo 'Exception when calling AggregationAccountApi->getAggregationAccountUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::AggregationAccountApi.new
aggregation_account_id = '7dd240dd-3994-4cfc-9bf8-ddb5b63d51be' # String | UUID aggregation_account_id
begin
  aggaccount = api_instance.get_aggregation_account_using_get(aggregation_account_id)
  p aggaccount
rescue NucleusApi::ApiError => e
  puts "Exception when calling AggregationAccountApi->get_aggregation_account_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.AggregationAccountApi();
var aggaccountId = "f90c972b-bfc3-471c-ba6b-0630be8467c0";

var aggregationaccount = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.getAggregationAccountUsingGet("f90c972b-bfc3-471c-ba6b-0630be8467c0", aggregationaccount)

Example Response

{
    "id": "f96fad3e-a8cf-4915-bc0c-da4d9693ab83",
    "create_date": "2017-01-03T00:00:00.000+0000",
    "update_date": "2017-01-05T00:00:00.000+0000",
    "client_id": "b1d2b9dc-fb9d-4ce2-b2df-eb8801127b23",
    "business_id": null,
    "account_name": "Bank Gold Checking",
    "institution_id": null,
    "institution_name": "Citywide Bank",
    "account_category_id": null,
    "category": "Bank Account",
    "subcategory": "Checking Account",
    "mask": "XXXXX8991",
    "currency_code": "USD",
    "bank_link_id": null,
    "interest_rate": null,
    "apr": null,
    "apy": null,
    "credit_limit": null,
    "death_benefit": null,
    "minimum_payment": null,
    "last_payment": null,
    "last_payment_date": null,
    "next_payment_date": null,
    "maturity_date": null,
    "is_manual": false,
    "is_active": true,
    "metadata": {}
}

Retrieve the information for a specific aggregation account associated with a client. The unique aggregation_account_id must be provided. The endpoint returns the aggregation_account_id and details for the account specified. Note that the metadata information is stored as a nested object within the aggregation account object.

HTTP REQUEST

GET /aggregation_account/{aggregation_account_id}

Update an aggregation account

Example Request

curl -X PUT -H "Authorization: Bearer <access_token>" \
-H "Content-Type: application/json" \
-d '{
      "client_id": "b1d2b9dc-fb9d-4ce2-b2df-eb8801127b23",
      "account_name": "Bank Gold Checking",
      "institution_name": "Citywide Bank",
      "category": "Bank Account",
      "subcategory": "Checking Account",
      "mask": "XXXXX8991",
      "currency_code": "USD",
      "bank_link_id": null,
      "is_asset": true,
      "is_active": true
     }' "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/aggregation_account/f96fad3e-a8cf-4915-bc0c-da4d9693ab83"
api_instance = nucleus_api.AggregationAccountApi(nucleus_api.ApiClient(configuration))
# Update AggregationAccount
aggregationAccount_update = {'account_name': 'New Account'}
aggregationAccount_id = '26dad553-21c4-4765-917e-ba06645b85a3'

try:
    api_response = api_instance.update_aggregation_account_using_put(aggregationAccount_update, aggregationAccount_id)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling update_aggregation_account_using_put: %s\n" % e)
AggregationAccountApi apiInstance = new AggregationAccountApi();
        //Update an Aggregation Account

        Map map = new HashMap();
        map.put("account_name", "First Account");

        try {
            AggregationAccount response = apiInstance.updateAggregationAccountUsingPut(map, UUID.fromString("797b8133-9885-452a-b3c3-4f0d95ada0b6"));
            System.out.println(response);
        } catch (ApiException e) {
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\AggregationAccountApi(
    new GuzzleHttp\Client(),
    $config);
//Update Aggregation Account
$aggregation_account_update = new stdClass();
$aggregation_id = "de700fb0-407f-4466-87e3-899029407cd1";

try {
    $aggregation_account_update->institution_name = "ANS";
    $result = $apiInstance->updateAggregationAccountUsingPut($aggregation_account_update, $aggregation_id);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->updateAggregationAccountUsingPut: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::AggregationAccountApi.new
#Update Agg Account
agg_account_update = {"account_name" => 'ABC'}
agg_account_id = '1c6d79e3-ac70-4ac4-822c-2f17589115a3'
begin
  result = api_instance.update_aggregation_account_using_put(agg_account_update, agg_account_id)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->update_aggregation_account_using_put: #{e}"
end
var apiInstance = new HydrogenNucleusApi.AggregationAccountApi();
//Update AggregationAccount
var apiInstance = new HydrogenNucleusApi.AggregationAccountApi();
var callback = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
var aggaccount = new HydrogenNucleusApi.AggregationAccount();
var aggaccountid = "eb29a929-cfba-4229-9836-4c007a53ae3e";

aggaccount.currency_code = 'USD';
apiInstance.updateAggregationAccountUsingPut(aggaccount, aggaccountid, callback)

Example Response

{
    "id": "f96fad3e-a8cf-4915-bc0c-da4d9693ab83",
    "create_date": "2017-01-03T00:00:00.000+0000",
    "update_date": "2017-01-06T00:00:00.000+0000",
    "client_id": "b1d2b9dc-fb9d-4ce2-b2df-eb8801127b23",
    "business_id": null,
    "account_name": "Bank Gold Checking",
    "institution_id": null,
    "institution_name": "Citywide Bank",
    "account_category_id": null,
    "category": "Bank Account",
    "subcategory": "Checking Account",
    "mask": "XXXXX8991",
    "currency_code": "USD",
    "bank_link_id": null,
    "interest_rate": null,
    "apr": null,
    "apy": null,
    "credit_limit": null,
    "death_benefit": null,
    "minimum_payment": null,
    "last_payment": null,
    "last_payment_date": null,
    "next_payment_date": null,
    "maturity_date": null,
    "is_manual": false,
    "is_active": true,
    "metadata": {}
}

Update the information for an aggregation account. The unique aggregation_account_id must be provided. To obtain the appropriate aggregation_account_id, use the GET /aggregation_account endpoint to view all aggregation accounts defined for your tenant and their current information. The details to be updated must also be provided. The endpoint returns the aggregation_account_id and the details for the aggregation account. If you wish to mark the aggregation account as no longer relevant without permanently deleting it, use this endpoint to update the is_active field to false.

HTTP REQUEST

PUT /aggregation_account/{aggregation_account_id}

Delete an aggregation account

Example Request

curl -X DELETE -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/aggregation_account/f96fad3e-a8cf-4915-bc0c-da4d9693ab83"
api_instance = nucleus_api.AggregationAccountApi(nucleus_api.ApiClient(configuration))
# # Delete a AggregationAccount
aggregation_id = ''
try:
    api_instance.delete_aggregation_account_using_delete(aggregation_id)
except ApiException as e:
    print("Exception when delete_aggregation_account_using_delete: %s\n" % e)
AggregationAccountApi apiInstance = new AggregationAccountApi();
//   Delete Aggregation Account
        try {
            AggregationAccount deleteresponse = apiInstance.deleteAggregationAccountUsingDelete(UUID.fromString("59b75f83-f4c1-45da-bd68-cf90df86ad00"));
            System.out.println(deleteresponse);
        } catch (ApiException e) {
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\AggregationAccountApi(
    new GuzzleHttp\Client(),
    $config);
//Delete AggregationAccount
$aggregation_did = "f461c309-7fc3-47e5-bbfc-ed5eb54e8b5d"; // string | UUID account_id

try {
    $apiInstance->deleteAggregationAccountUsingDelete($aggregation_did);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->deleteAggregationAccountUsingDelete: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::AggregationAccountApi.new
#Delete Agg Account
agg_account1_id = '36d60e6b-d3c3-4fdd-9d5f-d9ed1da45c2e'
begin
  result = api_instance.delete_aggregation_account_using_delete(agg_account1_id)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->delete_aggregation_account_using_delete: #{e}"
end
var apiInstance = new HydrogenNucleusApi.AggregationAccountApi();
//Delete a AggregationAccount
var aggaccount = "eb29a929-cfba-4229-9836-4c007a53ae3e";


var deleteaggregationaccount = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully.');
    }
};
apiInstance.deleteAggregationAccountUsingDelete(aggaccount, deleteaggregationaccount)

Response (204 No Content)

Permanently delete an aggregation account under a client. The unique aggregation_account_id must be provided. To obtain the appropriate aggregation_account_id, use the GET /aggregation_account endpoint to view all aggregation accounts defined for your tenant. This deletes the aggregation_account_id and all aggregation account record information. If you wish to mark the aggregation account as no longer relevant without permanently deleting it, use the PUT /aggregation_account endpoint to update the is_active field to false.

HTTP REQUEST

DELETE /aggregation_account/{aggregation_account_id}

Aggregation Account Balances

Aggregation account balances are created under aggregation accounts. This entity is intended to store the monetary balance of the held-away account represented in the aggregation account record. Balance information can be stored either once or stored over time by creating new aggregation account balance records every time the balances are updated. Held-away account balance information can be captured by integrating with a third-party service which supports Account Aggregation. This information can be used to provide customers with a better picture of their current financial health and gain business insights on holdings outside of the application.

Field Type Description
id UUID The id for the aggregation account balance record
aggregation_account_id UUID The id of the aggregation account to which the balance record belongs
currency_code string Alphabetic currency code for the currency of the balance, limited to 3 characters. See currency codes
balance string Current balance of the aggregation account
available_balance string Available balance in the aggregation account for an asset, usually taking into consideration pending transactions or available overdraft
available_credit string Available credit in the aggregation account for a liability
balance_time_stamp datetime Date and time for when the balance above applies, defaults to current timestamp
is_active boolean Indicates if the aggregation account balance record is active. Defaults to true which indicates it is active
secondary_id string Alternate id that can be used to identify the object such as an internal id
create_date timestamp Timestamp for the date and time that the record was created
update_date timestamp Timestamp for the date and time that the record was last updated

List all aggregation account balances

Example Request

curl -X GET -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/aggregation_account_balance"
api_instance = nucleus_api.AggregationAccountApi(nucleus_api.ApiClient(configuration))
try:
    api_response = api_instance.get_aggregation_account_balance_all_using_get()
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_aggregation_account_balance_all_using_get: %s\n" % e)
AggregationAccountApi apiInstance = new AggregationAccountApi();
        try {
            PageAggregationAccountBalance List = apiInstance.getAggregationAccountBalanceAllUsingGet(true, null, null, null, 0, 10);
            System.out.println(List);
        } catch (ApiException e) {
            System.err.println("Exception when calling getAggregationAccountBalanceAllUsingGet");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\AggregationAccountApi(
    new GuzzleHttp\Client(),
    $config);
$ascending = false; // bool | ascending
$currency_conversion = null; // string | currency_conversion
$filter = null; // string | filter
$order_by = null; // string | order_by
$page = 0; // int | page
$size = 10; // int | size

try {
    $aggregationbalancelist = $apiInstance->getAggregationAccountBalanceAllUsingGet($ascending, $currency_conversion, $filter, $order_by, $page, $size);
    print_r($aggregationbalancelist);
} catch (Exception $e) {
    echo 'Exception when calling AggregationAccountApi->getAggregationAccountBalanceAllUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::AggregationAccountApi.new
opts = {
    ascending: false, # BOOLEAN | ascending
    currency_conversion: null, # String | currency_conversion
    filter: null, # String | filter
    order_by: null, # String | order_by
    page: 0, # Integer | page
    size: 25 # Integer | size
}

begin
  balancelist = api_instance.get_aggregation_account_balance_all_using_get(opts)
  p balancelist
rescue NucleusApi::ApiError => e
  puts "Exception when calling AggregationAccountApi->get_aggregation_account_balance_all_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.AggregationAccountApi();
var opts = {
    'ascending': false, // Boolean | ascending
    // 'filter': "", // String | filter
    'orderBy': "update_date", // String | order_by
    'page': 0, // Number | page
    'size': 25 // Number | size
};

var aggregationaccountballancelist = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.getAggregationAccountBalanceAllUsingGet(opts, aggregationaccountballancelist)

Example Response

{
    "content": [
      {
        "id": "951d0ad2-cb3b-46b6-bd96-ba712b41b02f",
        "create_date": "2018-11-30T00:00:00.000+0000",
        "aggregation_account_id": "c6f59c0b-3407-4f6e-bcea-2dc71424847d",
        "currency_code": "USD",
        "balance": "36760.43",
        "available_balance": "35760.43",
        "available_credit": null,
        "balance_time_stamp": "2018-11-30T00:00:00.000+0000",
        "is_active": true
      },
      {
        "id": "951d0ad2-cb3b-46b6-bd96-ba712b41b02f",
        "create_date": "2018-12-01T00:00:00.000+0000",
        "aggregation_account_id": "c6f59c0b-3407-4f6e-bcea-2dc71424847d",
        "currency_code": "USD",
        "balance": "35760.43",
        "available_balance": "35760.43",
        "available_credit": null,
        "balance_time_stamp": "2018-12-01T00:00:00.000+0000",
        "is_active": true
      },
      {
        "id": "951d0ad2-cb3b-46b6-bd96-ba712b41b02f",
        "create_date": "2018-12-02T00:00:00.000+0000",
        "aggregation_account_id": "c6f59c0b-3407-4f6e-bcea-2dc71424847d",
        "currency_code": "USD",
        "balance": "35760.43",
        "available_balance": "40000.00",
        "available_credit": null,
        "balance_time_stamp": "2018-12-02T00:00:00.000+0000",
        "is_active": true
      }
    ],
    "last": false,
    "total_pages": 1,
    "total_elements": 3,
    "sort": [
        {
            "direction": "DESC",
            "property": "updateDate",
            "ignore_case": false,
            "null_handling": "NATIVE",
            "descending": true,
            "ascending": false
        }
    ],
    "first": true,
    "number_of_elements": 3,
    "size": 25,
    "number": 0
}

Get all of the balance records for all aggregation accounts defined for your tenant. You can filter using a unique aggregation_account_id to view the balance records for a specific aggregation account. To identify the appropriate aggregation_account_id, use the GET /aggregation_account endpoint to see all aggregation accounts defined for your tenant. You can also filter based on the value provided for the balance_time_stamp to see the balance records for a specific date or date range.

HTTP REQUEST

GET /aggregation_account_balance

Create an aggregation account balance

Example Request

curl -X POST -H "Authorization: Bearer <access_token>" \
-H "Content-Type: application/json" \
-d '{
      "aggregation_account_id": "c6f59c0b-3407-4f6e-bcea-2dc71424847d",
      "currency_code": "USD",
      "balance": "36760.43",
      "available_balance": "35760.43",
      "balance_time_stamp": "2018-11-30T00:00:00.000+0000"
    }' "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/aggregation_account_balance"
api_instance = nucleus_api.AggregationAccountApi(nucleus_api.ApiClient(configuration))
# # Create a Aggregation Account Balance
aggbalance = nucleus_api.AggregationAccountBalance(aggregation_account_id="3ddf08f8-8c29-4381-a362-6dbbaafa3c2e", available_credit="100.00", currency_code="USD")
aggbalance1 = nucleus_api.AggregationAccountBalance(aggregation_account_id="3ddf08f8-8c29-4381-a362-6dbbaafa3c2e", available_credit="100.00", currency_code="GBP")

try:
    api_response = api_instance.create_aggregation_account_balance_bulk_using_post([aggbalance, aggbalance1])
    pprint(api_response)
except ApiException as e:
    print("create_aggregation_account_balance_bulk_using_post: %s\n" % e)
AggregationAccountApi apiInstance = new AggregationAccountApi();
        //Create Aggregation Account Balance
        AggregationAccountBalance aggregationAccountBalance = new AggregationAccountBalance();
        aggregationAccountBalance.availableCredit(10000.00);
        aggregationAccountBalance.aggregationAccountId(UUID.fromString("3ddf08f8-8c29-4381-a362-6dbbaafa3c2e"));
        aggregationAccountBalance.currencyCode("USD");
        try {
            AggregationAccountBalance result = apiInstance.createAggregationAccountBalanceUsingPost(aggregationAccountBalance);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling createAggregationAccountBalanceUsingPost");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\AggregationAccountApi(
    new GuzzleHttp\Client(),
    $config);
//Create Aggregation Account Balance
$aggregation_account_balance = new \com\hydrogen\nucleus\Model\AggregationAccountBalance();

try {
    $aggregation_account_balance->setAggregationAccountId("3ddf08f8-8c29-4381-a362-6dbbaafa3c2e");
    $aggregation_account_balance->setAvailableCredit("200");
    $aggregation_account_balance->setCurrencyCode("USD");
    $result = $apiInstance->createAggregationAccountBalanceUsingPost($aggregation_account_balance);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->createAggregationAccountBalanceUsingPost: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::AggregationAccountApi.new
#Create Aggregation Account Balance
agg_account_balance = NucleusApi::AggregationAccountBalance.new

begin
  agg_account_balance.aggregation_account_id = "3ddf08f8-8c29-4381-a362-6dbbaafa3c2e"
  agg_account_balance.available_credit = "200"
  agg_account_balance.currency_code = "USD"
  result = api_instance.create_aggregation_account_balance_using_post(agg_account_balance)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->create_aggregation_account_balance_using_post: #{e}"
end
var apiInstance = new HydrogenNucleusApi.AggregationAccountApi();
//Create Aggregation Account Balance

var aggaccountbalance = new HydrogenNucleusApi.AggregationAccountBalance();
aggaccountbalance.aggregation_account_id = '3ddf08f8-8c29-4381-a362-6dbbaafa3c2e';
aggaccountbalance.available_credit = "100";
aggaccountbalance.currency_code = "GBP";

var newaggregationbalance = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.createAggregationAccountBalanceUsingPost(aggaccountbalance, newaggregationbalance)

Example Response

{
  "id": "951d0ad2-cb3b-46b6-bd96-ba712b41b02f",
  "create_date": "2018-12-01T00:00:00.000+0000",
  "aggregation_account_id": "c6f59c0b-3407-4f6e-bcea-2dc71424847d",
  "currency_code": "USD",
  "balance": "36760.43",
  "available_balance": "35760.43",
  "available_credit": null,
  "balance_time_stamp": "2018-11-30T00:00:00.000+0000",
  "is_active": true
}

Create a balance record under an aggregation account. The aggregation_account_id, currency_code and one of the following must be provided: balance, available_balance, or available_credit. To obtain the appropriate aggregation_account_id use the GET /aggregation_account endpoint to view all aggregation accounts for your tenant. If the values provided for balance and/or available_balance are not current, ensure the specify the timestamp for when the values apply. The endpoint returns an aggregation_account_balance_id used to manage the aggregation account record.

HTTP REQUEST

POST /aggregation_account_balance

ARGUMENTS

Parameter Type Required Description
aggregation_account_id UUID required The id of the aggregation account to which the balance record belongs
currency_code string required Alphabetic currency code for the currency of the balance, limited to 3 characters. See currency codes
balance string required, conditional Balance of the aggregation account. Required if available_balance or available_credit are not provided.
available_balance string required, conditional Available balance in the aggregation account for an asset, usually taking into consideration pending transactions or available overdraft. Required if balance or available_credit are not provided.
available_credit string required, conditional Available credit in the aggregation account for a liability. Required if balance or available_balance are not provided.
balance_time_stamp datetime optional Date and time for when the balance above applies, defaults to current timestamp
is_active boolean optional Indicates if the aggregation account balance record is active. Defaults to true which indicates it is active
secondary_id string optional Alternate id that can be used to identify the object such as an internal id

Retrieve an aggregation account balance

Example Request

curl -X GET -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/aggregation_account_balance/951d0ad2-cb3b-46b6-bd96-ba712b41b02f"
api_instance = nucleus_api.AggregationAccountApi(nucleus_api.ApiClient(configuration))
try:
    api_response = api_instance.get_aggregation_account_balance_using_get("3ced8af4-a0c9-4b64-a928-534464b3906b")
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_aggregation_account_balance_using_get: %s\n" % e)
AggregationAccountApi apiInstance = new AggregationAccountApi();
        try {
            AggregationAccountBalance responseaggregationbalance = apiInstance.getAggregationAccountBalanceUsingGet(UUID.fromString("d289c9ec-c8eb-4689-8f4a-2cad181efc3e"), null);
            System.out.println(responseaggregationbalance);
        } catch (ApiException e) {
            System.err.println("Exception when calling getAggregationAccountBalanceUsingGet");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\AggregationAccountApi(
    new GuzzleHttp\Client(),
    $config);
$aggregation_account_balance_id = "d289c9ec-c8eb-4689-8f4a-2cad181efc3e"; // string | UUID aggregation_account_balance_id
$currency_conversion = null; // string | USD

try {
    $aggregationbalance = $apiInstance->getAggregationAccountBalanceUsingGet($aggregation_account_balance_id, $currency_conversion);
    print_r($aggregationbalance);
} catch (Exception $e) {
    echo 'Exception when calling AggregationAccountApi->getAggregationAccountBalanceUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::AggregationAccountApi.new
aggregation_account_balance_id = 'd289c9ec-c8eb-4689-8f4a-2cad181efc3e' # String | UUID aggregation_account_balance_id

opts = {
    currency_conversion: null, # String | USD
}

begin
  balance = api_instance.get_aggregation_account_balance_using_get(aggregation_account_balance_id, opts)
  p balance
rescue NucleusApi::ApiError => e
  puts "Exception when calling AggregationAccountApi->get_aggregation_account_balance_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.AggregationAccountApi();
var aggaccountId = "23a2f2f2-7848-4e26-99a9-421099167be1";

var aggregationaccountbalance = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.getAggregationAccountBalanceUsingGet("23a2f2f2-7848-4e26-99a9-421099167be1", aggregationaccountbalance)

Example Response

{
  "id": "951d0ad2-cb3b-46b6-bd96-ba712b41b02f",
  "create_date": "2018-11-30T00:00:00.000+0000",
  "aggregation_account_id": "c6f59c0b-3407-4f6e-bcea-2dc71424847d",
  "currency_code": "USD",
  "balance": "36760.43",
  "available_balance": "35760.43",
  "available_credit": null,
  "balance_time_stamp": "2018-11-30T00:00:00.000+0000",
  "is_active": true
}

Retrieve the information for a specific balance record for an aggregation account. The unique aggregation_account_balance_id must be provided. The endpoint returns the aggregation_account_balance_id and details for the aggregation account balance record.

HTTP REQUEST

GET /aggregation_account_balance/{aggregation_account_balance_id}

Update an aggregation account balance

Example Request

curl -X PUT -H "Authorization: Bearer <access_token>" \
-H "Content-Type: application/json" \
-d '{
      "aggregation_account_id": "c6f59c0b-3407-4f6e-bcea-2dc71424847d",
      "currency_code": "USD",
      "balance": "35760.43",
      "available_balance": "35760.43",
      "balance_time_stamp": "2018-12-01T00:00:00.000+0000",
      "is_active": true
     }' "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/aggregation_account_balance/951d0ad2-cb3b-46b6-bd96-ba712b41b02f"
api_instance = nucleus_api.AggregationAccountApi(nucleus_api.ApiClient(configuration))
# # # Update AggregationAccountBalance
aggregationAccountBalance_update = {'currency_code': 'AUD'}
aggregationAccountBalance_id = '4a1349c7-ab3c-4d93-9cd5-63bb65514e28'

try:
    api_response = api_instance.update_aggregation_account_balance_using_put(aggregationAccountBalance_update, aggregationAccountBalance_id)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling update_aggregation_account_balance_using_put: %s\n" % e)
AggregationAccountApi apiInstance = new AggregationAccountApi();
        //Update an Aggregation Account Balance

        Map map4 = new HashMap();
        map.put("available_credit", 1000.0);

        try {
            AggregationAccountBalance responseone = apiInstance.updateAggregationAccountBalanceUsingPut(map4, UUID.fromString("39a3a181-f00c-492d-83c0-afd3f4e2c88a"));
            System.out.println(responseone);
        } catch (ApiException e) {
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\AggregationAccountApi(
    new GuzzleHttp\Client(),
    $config);

//Update Aggregation Account Balance
$aggregation_account_balance_update = new stdClass();
$aggregation_balance_id = "a44864b1-5d65-4228-8b59-a06a1c1b917e";

try {
    $aggregation_account_balance_update->currency_code = "GBP";
    $result = $apiInstance->updateAggregationAccountBalanceUsingPut($aggregation_account_balance_update, $aggregation_balance_id);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->updateAggregationAccountBalanceUsingPut: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::AggregationAccountApi.new
#Update Agg Account Balance
agg_accountbalance_update = {"currency_code" => 'CAD'}
agg_accountbalance_id = '7a4ff848-ddb6-49af-9fa9-b78c921f8a1f'
begin
  result = api_instance.update_aggregation_account_balance_using_put(agg_accountbalance_update, agg_accountbalance_id)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->update_aggregation_account_balance_using_put: #{e}"
end
var apiInstance = new HydrogenNucleusApi.AggregationAccountApi();
//Update AggregationAccountBalance
var apiInstance = new HydrogenNucleusApi.AggregationAccountApi();
var callback = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
var aggaccountbalance = new HydrogenNucleusApi.AggregationAccountBalance();
var aggaccountbalanceid = "86de72c6-07bb-4875-972c-f7335a20680e";

aggaccountbalance.currency_code = 'USD';
apiInstance.updateAggregationAccountBalanceUsingPut(aggaccountbalance, aggaccountbalanceid, callback)

Example Response

{
  "id": "951d0ad2-cb3b-46b6-bd96-ba712b41b02f",
  "create_date": "2018-11-30T00:00:00.000+0000",
  "update_date": "2018-12-01T00:00:00.000+0000",
  "aggregation_account_id": "c6f59c0b-3407-4f6e-bcea-2dc71424847d",
  "currency_code": "USD",
  "balance": "35760.43",
  "available_balance": "35760.43",
  "available_credit": null,
  "balance_time_stamp": "2018-12-01T00:00:00.000+0000",
  "is_active": true
}

Update a balance record for an aggregation account. The unique aggregation_account_balance_id must be provided. To obtain the appropriate aggregation_account_balance_id, use the GET /aggregation_account_balance endpoint to view all aggregation account balance records and their current information. The details to be updated must also be provided. The endpoint returns the aggregation_account_balance_id and the details for the aggregation account balance record. If you wish to mark the aggregation account balance record as no longer relevant without permanently deleting it, use this endpoint to update the is_active field to false.

HTTP REQUEST

PUT /aggregation_account_balance/{aggregation_account_balance_id}

Delete an aggregation account balance

Example Request

curl -X DELETE -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/aggregation_account_balance/951d0ad2-cb3b-46b6-bd96-ba712b41b02f"
api_instance = nucleus_api.AggregationAccountApi(nucleus_api.ApiClient(configuration))
# # # # Delete a AggregationAccountBalance
aggregationbalance_id = '5c7bd75b-3f0b-43eb-b7e5-f67a8bb35957'
try:
    api_instance.delete_aggregation_account_balance_using_delete(aggregationbalance_id)
except ApiException as e:
    print("Exception when delete_aggregation_account_balance_using_delete: %s\n" % e)
AggregationAccountApi apiInstance = new AggregationAccountApi();
        //   Delete Aggregation Account Balance
        try {
            AggregationAccountBalance deleteresponse = apiInstance.deleteAggregationAccountBalanceUsingDelete(UUID.fromString("3d945279-d67c-4560-9b4f-7664c0ef68d4"));
            System.out.println(deleteresponse);
        } catch (ApiException e) {
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\AggregationAccountApi(
    new GuzzleHttp\Client(),
    $config);
//Delete AggregationAccountBalance
$aggregation_balance_did = "e1eb6d1e-00bb-451b-96d2-66ecef52ece1"; // string | UUID account_id

try {
    $apiInstance->deleteAggregationAccountBalanceUsingDelete($aggregation_balance_did);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->deleteAggregationAccountBalanceUsingDelete: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::AggregationAccountApi.new
#Delete Agg Account Balance
agg_accountbalance1_id = '46eb5972-f381-4c7c-8495-1a90c615618e'
begin
  result = api_instance.delete_aggregation_account_balance_using_delete(agg_accountbalance1_id)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->delete_aggregation_account_balance_using_delete: #{e}"
end
var apiInstance = new HydrogenNucleusApi.AggregationAccountApi();
// //Delete a AggregationAccountBalance
var aggaccountbalance = "ee0f96fa-08c4-43c9-994a-5219e326655c";


var deleteaggregationaccountbalance = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully.');
    }
};
apiInstance.deleteAggregationAccountBalanceUsingDelete(aggaccountbalance, deleteaggregationaccountbalance)

Response (204 No Content)

Permanently delete a balance record for an aggregation account. The unique aggregation_account_balance_id must be provided. To obtain the appropriate aggregation_account_balance_id, use the GET /aggregation_account_balance endpoint to view all aggregation account balance records. This deletes the aggregation_account_balance_id and the details for the aggregation account balance record. If you wish to mark the aggregation account balance record as no longer relevant without permanently deleting it, use the PUT /aggregation_account_balance endpoint to update the is_active field to false.

HTTP REQUEST

DELETE /aggregation_account_balance/{aggregation_account_balance_id}

Aggregation Account Transactions

Aggregation account transactions are created under aggregation accounts. This entity is intended to store the transactions of the held-away account represented in the aggregation account record. Held-away account transaction information can be captured by integrating with a third-party service which supports Account Aggregation. This information can be used to provide customers with a better picture of their financial activity and gain business insights on spending outside of the application.

Field Type Description
id UUID The id for the aggregation account transaction record
aggregation_account_id UUID The id of the aggregation account to which the transaction record belongs
currency_code string Alphabetic currency code for the currency of the holding, limited to 3 characters. See currency codes
transaction_date timestamp The date the transaction took place
status string The status of the transaction within its lifecycle such as “Pending” or “Posted”
bank_credit map Transaction information if from a bank, debit card, or credit card transaction
       transaction_type string Type of bank or credit transaction. Value may be debit or credit
       amount double Amount of the transaction
       merchant_id UUID ID of the merchant resource for the transaction
       merchant string The merchant for the transaction such as the merchant posted for a credit card charge
       transaction_category_id UUID ID of the category resource for the transaction
       category string Category of the transaction
       subcategory string Subcategory of the transaction
       description string Description of the transaction
       memo string Memo attached to the transaction
       location map Location where the transaction occurred
             address_line1 string Primary information for the street address, such as the street and building number
             address_line2 string Secondary information for the street address, such as a suite or apartment number
             city string City for the address
             state string State, province, or sub-country region for the address
             postalcode string Alphanumeric postal code or zip code for the address
             country string Country for the address using the ISO ALPHA-2 Code. See country codes
             latitude double Latitude of the location where the transaction occurred
             longitude double Longitude of the location where the transaction occurred
investment map Transaction information if from an investment account trade
       trade_signal string Trade signal for an investment trade such as “Buy” or “Sell”
       investment_type string Type of investment transaction such as the label or category
       ticker string Ticker of the security for an investment transaction
       ticker_name string Ticker name of the security for an investment transaction
       price double Price of the security for an investment transaction
       quantity double The number of shares involved in this transaction
       value double The monetary amount involved in this transaction
       fee double Fee that is part of this transaction
       settle_date timestamp Date on which this transaction was finalized
cash map DEPRECATED- all cash transactions from aggregation integrations will be added to the bank_credit or investment maps. Transaction information if from a cash transaction such as a deposit or withdrawal
       transaction_type string Type of cash transaction. Value may be deposit, withdrawal, fee, transfer, cash, other
       amount double Amount of the cash transaction
       name string Description or label for the cash transaction
is_excluded_analysis boolean Indicates if this transaction will be excluded from any spending or income analysis done in Proton tools. Defaults to false which indicates it will not be excluded from Proton analyses
is_fee boolean Indicates if this transaction is a fee. Defaults to null
is_transfer boolean Indicates if this transaction is a cash transfer. Defaults to null
is_recurring boolean Indicates if this transaction is a recurring subscription. Defaults to false which indicates it is not recurring
secondary_id string Alternate id that can be used to identify the object such as an internal id
create_date timestamp Timestamp for the date and time that the record was created
update_date timestamp Timestamp for the date and time that the record was last updated
metadata map Custom information associated with the transaction in the format key:value
See Metadata

List all aggregation account transactions

Example Request

curl -X GET -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/aggregation_account_transaction"
api_instance = nucleus_api.AggregationAccountApi(nucleus_api.ApiClient(configuration))
try:
    api_response = api_instance.get_aggregation_account_transaction_all_using_get()
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_aggregation_account_transaction_all_using_get: %s\n" % e)
AggregationAccountApi apiInstance = new AggregationAccountApi();
        try {
            PageAggregationAccountTransaction List = apiInstance.getAggregationAccountTransactionAllUsingGet(true, null, null, null, 0, 10);
            System.out.println(List);
        } catch (ApiException e) {
            System.err.println("Exception when calling getAggregationAccountTransactionAllUsingGet");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\AggregationAccountApi(
    new GuzzleHttp\Client(),
    $config);
$ascending = false; // bool | ascending
$currency_conversion = null; // string | currency_conversion
$filter = null; // string | filter
$order_by = null; // string | order_by
$page = 0; // int | page
$size = 10; // int | size

try {
    $aggregationtransactionlist = $apiInstance->getAggregationAccountTransactionAllUsingGet($ascending, $currency_conversion, $filter, $order_by, $page, $size);
    print_r($aggregationtransactionlist);
} catch (Exception $e) {
    echo 'Exception when calling AggregationAccountApi->getAggregationAccountTransactionAllUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::AggregationAccountApi.new
opts = {
    ascending: false, # BOOLEAN | ascending
    currency_conversion: null, # String | currency_conversion
    filter: null, # String | filter
    order_by: null, # String | order_by
    page: 0, # Integer | page
    size: 25 # Integer | size
}

begin
  transactionlist = api_instance.get_aggregation_account_transaction_all_using_get(opts)
  p transactionlist
rescue NucleusApi::ApiError => e
  puts "Exception when calling AggregationAccountApi->get_aggregation_account_transaction_all_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.AggregationAccountApi();
var opts = {
    'ascending': false, // Boolean | ascending
    // 'filter': "", // String | filter
    'orderBy': "update_date", // String | order_by
    'page': 0, // Number | page
    'size': 25 // Number | size
};

var aggregationaccounttransactionlist = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.getAggregationAccountTransactionAllUsingGet(opts, aggregationaccounttransactionlist)

Example Response

{
    "content": [
        {
            "id": "7de7dfd3-11e4-4f6d-852c-028f85aa3dc8",
            "aggregation_account_id": "a5becef5-c018-43fe-b7ce-4dae58d50e18",
            "transaction_date": "2019-07-17T00:00:00.000+0000",
            "status": null,
            "bank_credit": {
                "transaction_type": "Debit",
                "amount": 4.33,
                "merchant_id": null,
                "merchant": "Starbucks",
                "transaction_category_id": null,
                "category": "Food and Drink",
                "subcategory": "Restaurants",
                "description": null,
                "memo": null,
                "location": {
                    "address_line1": "1900 Broadway",
                    "address_line2": "Floor 4",
                    "city": "New York",
                    "state": "NY",
                    "postalcode": "10023",
                    "country": "US",
                    "latitude": -73.9747115,
                    "longitude": 40.790885
                }
            },
            "investment": {},
            "cash": {},
            "metadata": {},
            "secondary_id": "rGqvy4l5VpukXm3D8qJAsQxNAAQVQqTlPz3qW",
            "create_date": "2019-10-07T16:28:14.000+0000",
            "update_date": "2019-10-09T19:15:43.000+0000",
            "currency_code": "USD",
            "is_excluded_analysis": false,
            "is_fee": null,
            "is_transfer": null,
            "is_recurring": false
        },
        {
            "id": "d9a0e9da-7cef-464c-b233-962303f77c5d",
            "aggregation_account_id": "a5becef5-c018-43fe-b7ce-4dae58d50e18",
            "transaction_date": "2019-08-16T00:00:00.000+0000",
            "status": null,
            "bank_credit": {
                "transaction_type": "Debit",
                "amount": 12.0,
                "merchant_id": null,
                "merchant": "McDonald's",
                "transaction_category_id": null,
                "category": "Food and Drink",
                "subcategory": "Restaurants",
                "description": null,
                "memo": null,
                "location": null
            },
            "investment": {},
            "cash": {},
            "metadata": {},
            "secondary_id": "dkg1aAPJVxHAbeWK4pP7hGRJzzGmGauZMpL5B",
            "create_date": "2019-10-07T16:28:14.000+0000",
            "update_date": "2019-10-07T16:28:14.000+0000",
            "currency_code": "USD",
            "is_excluded_analysis": false,
            "is_fee": null,
            "is_transfer": null,
            "is_recurring": false
        },
        {
            "id": "00c9ec15-0f11-402d-83a6-8be1c520353b",
            "aggregation_account_id": "a5becef5-c018-43fe-b7ce-4dae58d50e18",
            "transaction_date": "2019-07-18T00:00:00.000+0000",
            "status": null,
            "bank_credit": {
                "transaction_type": "Credit",
                "amount": 500.0,
                "merchant_id": null,
                "merchant": "United Airlines",
                "transaction_category_id": null,
                "category": "Travel",
                "subcategory": "Airlines and Aviation Services",
                "description": null,
                "memo": null,
                "location": null
            },
            "investment": {},
            "cash": {},
            "metadata": {},
            "secondary_id": "zGJvxEd5qkuagLk7BolmS9q3MM9X9oCo7n4JD",
            "create_date": "2019-10-07T16:28:13.000+0000",
            "update_date": "2019-10-07T16:28:13.000+0000",
            "currency_code": "USD",
            "is_excluded_analysis": false,
            "is_fee": null,
            "is_transfer": null,
            "is_recurring": false
        }
    ],
    "last": false,
    "total_pages": 1,
    "total_elements": 3,
    "sort": [
      {
          "direction": "DESC",
          "property": "updateDate",
          "ignore_case": false,
          "null_handling": "NATIVE",
          "descending": true,
          "ascending": false
      }
    ],
    "first": true,
    "number_of_elements": 2,
    "size": 25,
    "number": 0
}

Get all of the transaction records for all aggregation accounts defined for your tenant. You can filter using a unique aggregation_account_id to view the transaction records for a specific aggregation account. To identify the appropriate aggregation_account_id, use the GET /aggregation_account endpoint to see all aggregation accounts defined for your tenant. You can also filter based on the value provided for the transaction_date to see the transaction records for a specific date or date range.

HTTP REQUEST

GET /aggregation_account_transaction

Create an aggregation account transaction

Example Request

curl -X POST -H "Authorization: Bearer <access_token>" \
-H "Content-Type: application/json" \
-d '{
        "aggregation_account_id": "60bf9829-6e8e-4965-8d42-531adc7652b3",
        "transaction_date": "2019-03-28T09:11:26.000+0000",
        "investment": {
            "trade_signal": "Buy",
            "ticker": "AAPL",
            "price": 550.0,
            "quantity": 2.0,
            "ticker_name": "Apple Inc.",
            "fee": 30.0,
            "settle_date": "2019-07-02T14:46:31.000+0000"
        },
        "metadata": {},
        "currency_code": "USD",
        "is_excluded_analysis": true
    }' "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/aggregation_account_transaction"
api_instance = nucleus_api.AggregationAccountApi(nucleus_api.ApiClient(configuration))
# # Create a Aggregation Account Transaction
amnt = nucleus_api.BankCredit(amount=100, transaction_type="DEBIT")
aggtransaction = nucleus_api.AggregationAccountTransaction(aggregation_account_id="3ddf08f8-8c29-4381-a362-6dbbaafa3c2e", currency_code="USD", transaction_date="2020-10-10", bank_credit=[amnt])

try:
    api_response = api_instance.create_aggregation_account_transaction_using_post(aggtransaction)
    pprint(api_response)
except ApiException as e:
    print("create_aggregation_account_transaction_using_post: %s\n" % e)
AggregationAccountApi apiInstance = new AggregationAccountApi();
        //Create Aggregate Account Transactions
        AggregationAccountTransaction aggregationAccountTransaction = new AggregationAccountTransaction();
        aggregationAccountTransaction.setAggregationAccountId(UUID.fromString("a0ec726d-150b-4bc3-be25-840bea9e028b"));
        aggregationAccountTransaction.setCurrencyCode("USD");
        aggregationAccountTransaction.setTransactionDate(day2);
        try {
            AggregationAccountTransaction result = apiInstance.createAggregationAccountTransactionUsingPost(aggregationAccountTransaction);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling createAggregationAccountTransactionUsingPost");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\AggregationAccountApi(
    new GuzzleHttp\Client(),
    $config);
//Create Aggregation Account Transaction
$aggregation_account_transaction = new \com\hydrogen\nucleus\Model\AggregationAccountTransaction();

try {
    $aggregation_account_transaction->setAggregationAccountId("ac83c28e-3bab-48e6-b7ef-69732afa78bc");
    $aggregation_account_transaction->setTransactionDate("2020-10-10");
    $aggregation_account_transaction->setCurrencyCode("GBP");

    $result = $apiInstance->createAggregationAccountTransactionUsingPost($aggregation_account_transaction);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->createAggregationAccountTransactionUsingPost: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::AggregationAccountApi.new
#Create Aggregation Account transaction
agg_account_transaction = NucleusApi::AggregationAccountTransaction.new

begin
  agg_account_transaction.aggregation_account_id = "a0ec726d-150b-4bc3-be25-840bea9e028b"
  agg_account_transaction.transaction_date = "2020-10-10"
  agg_account_transaction.currency_code = "USD"
  result = api_instance.create_aggregation_account_transaction_using_post(agg_account_transaction)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->create_aggregation_account_transaction_using_post: #{e}"
end
var apiInstance = new HydrogenNucleusApi.AggregationAccountApi();
//Create Aggregation Account Transaction
var aggaccounttransaction = new HydrogenNucleusApi.AggregationAccountTransaction();
aggaccounttransaction.aggregation_account_id = 'a0ec726d-150b-4bc3-be25-840bea9e028b';
aggaccounttransaction.currency_code = "USD";
aggaccounttransaction.transaction_date = "2020-10-10";


var newaggregationtransaction = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.createAggregationAccountTransactionUsingPost(aggaccounttransaction, newaggregationtransaction)

Example Response

{
    "id": "67ff9d1c-ac44-4dc3-9142-d4ecbade80d4",
    "aggregation_account_id": "60bf9829-6e8e-4965-8d42-531adc7652b3",
    "transaction_date": "2019-03-28T09:11:26.000+0000",
    "status": null,
    "bank_credit": {},
    "investment": {
        "trade_signal": "Buy",
        "ticker": "AAPL",
        "price": 550.0,
        "quantity": 2.0,
        "value": null,
        "ticker_name": "Apple Inc.",
        "fee": 30.0,
        "settle_date": "2019-07-02T14:46:31.000+0000"
    },
        "metadata": {},
        "create_date": "2019-10-09T20:33:49.162+0000",
        "update_date": "2019-10-09T20:33:49.162+0000",
        "currency_code": "USD",
        "is_excluded_analysis": true,
        "is_recurring": false,
        "is_fee": null,
        "is_transfer": null
}

Create a transaction record under an aggregation account. The aggregation_account_id must be provided. To obtain the appropriate aggregation_account_id use the GET /aggregation_account endpoint to view all aggregation accounts for your tenant. The endpoint returns an aggregation_account_transaction_id used to manage the aggregation account record.

HTTP REQUEST

POST /aggregation_account_transaction

ARGUMENTS

Parameter Type Required Description
aggregation_account_id UUID required The id of the aggregation account to which the transaction record belongs
currency_code string required Alphabetic currency code for the currency of the holding, limited to 3 characters. See currency codes
transaction_date timestamp required The date the transaction took place
status string optional The status of the transaction within its lifecycle such as “Pending” or “Posted”
bank_credit map optional Transaction information if from a bank, debit card, or credit card transaction
       transaction_type string required Type of the transaction. Value may be Debit or Credit
       amount double required Amount of the transaction
       transaction_category_id UUID required, conditional ID of the category resource for the transaction. Either the transaction_category_id or category must be provided
       category string required, conditional Category of the transaction. Either the category or transaction_category_id must be provided
       subcategory string optional Subcategory of the transaction
       merchant_id UUID optional ID of the merchant resource for the transaction
       merchant string optional The merchant for the transaction such as the merchant posted for a credit card charge
       description string optional Description of the transaction
       memo string optional Memo attached to the transaction
       location map optional Location where the transaction occurred
             address_line1 string optional Primary information for the street address, such as the street and building number
             address_line2 string optional Secondary information for the street address, such as a suite or apartment number
             city string optional City for the address
             state string optional State, province, or sub-country region for the address
             postalcode string optional Alphanumeric postal code or zip code for the address
             country string optional Country for the address using the ISO ALPHA-2 Code. See country codes
             latitude double optional Latitude of the location where the transaction occurred
             longitude double optional Longitude of the location where the transaction occurred
investment map optional Transaction information if from an investment account trade
       trade_signal string required Trade signal for an investment transaction
       investment_type string required Type of investment transaction such as the label or category
       ticker string required, conditional Ticker of the security for an investment transaction. Either the ticker or ticker_name must be provided.
       ticker_name string required, conditional Ticker name of the security for an investment transaction. Either the ticker_name or ticker must be provided.
       price double required Price of the security for an investment transaction
       quantity double required The number of units involved in this transaction, as reported by the financial institution
       value double optional The monetary amount involved in this transaction
       fee double optional Fee that is part of this transaction
       settle_date timestamp optional Date on which this transaction was finalized
cash map optional DEPRECATED- all cash transactions from aggregation integrations will be added to the bank_credit or investment maps. Transaction information if from a cash transaction such as a deposit or withdrawal
       transaction_type string required Type of cash transaction. Value may be deposit, withdrawal, fee, transfer, cash, other
       amount double required* Amount of the cash transaction
       name string optional Description or label for the cash transaction
is_excluded_analysis boolean optional Indicates if this transaction will be excluded from any spending or income analysis done in Proton tools. Defaults to “false” which indicates it will not be excluded from Proton analyses
is_fee boolean optional Indicates if this transaction is a fee. Defaults to null
is_transfer boolean optional Indicates if this transaction is a cash transfer. Defaults to null
is_recurring boolean optional Indicates if this transaction is a recurring subscription. Defaults to false which indicates it is not recurring
secondary_id string optional Alternate id that can be used to identify the object such as an internal id
metadata map optional Custom information associated with the transaction in the format key:value
See Metadata

Retrieve an aggregation account transaction

Example Request

curl -X GET -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/aggregation_account_transaction/7de7dfd3-11e4-4f6d-852c-028f85aa3dc8"
api_instance = nucleus_api.AggregationAccountApi(nucleus_api.ApiClient(configuration))
try:
    api_response = api_instance.get_aggregation_account_transaction_using_get("1417c740-f8e8-42b6-a027-2c61696d5e7f")
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_aggregation_account_transaction_using_get: %s\n" % e)
AggregationAccountApi apiInstance = new AggregationAccountApi();
        AggregationAccountTransaction responseaggregationtransaction = null;
        try {
            responseaggregationtransaction = apiInstance.getAggregationAccountTransactionUsingGet(UUID.fromString("da86d7eb-be05-40e0-9d42-b61509e4c63d"), null);
            System.out.println(responseaggregationtransaction);
        } catch (ApiException e) {
            System.err.println("Exception when calling getAggregationAccountTransactionUsingGet");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\AggregationAccountApi(
    new GuzzleHttp\Client(),
    $config);
$aggregation_account_transaction_id = "da86d7eb-be05-40e0-9d42-b61509e4c63d"; // string | UUID aggregation_account_transaction_id
$currency_conversion = null; // string | USD

try {
    $aggregatetransaction = $apiInstance->getAggregationAccountTransactionUsingGet($aggregation_account_transaction_id, $currency_conversion);
    print_r($aggregatetransaction);
} catch (Exception $e) {
    echo 'Exception when calling AggregationAccountApi->getAggregationAccountTransactionUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::AggregationAccountApi.new
aggregation_account_transaction_id = 'da86d7eb-be05-40e0-9d42-b61509e4c63d' # String | UUID aggregation_account_transaction_id

opts = {
    currency_conversion: null, # String | USD
}

begin
  transaction = api_instance.get_aggregation_account_transaction_using_get(aggregation_account_transaction_id, opts)
  p transaction
rescue NucleusApi::ApiError => e
  puts "Exception when calling AggregationAccountApi->get_aggregation_account_transaction_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.AggregationAccountApi();
var aggaccounttransactionId = "0c175fcc-46e8-431d-be84-b3b1f1c4da9a";
var aggregationaccounttransaction = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.getAggregationAccountTransactionUsingGet("0c175fcc-46e8-431d-be84-b3b1f1c4da9a", aggregationaccounttransaction)

Example Response

{
    "id": "7de7dfd3-11e4-4f6d-852c-028f85aa3dc8",
    "aggregation_account_id": "a5becef5-c018-43fe-b7ce-4dae58d50e18",
    "transaction_date": "2019-07-17T00:00:00.000+0000",
    "status": null,
    "bank_credit": {
        "transaction_type": "Debit",
        "amount": 4.33,
        "merchant_id": null,
        "merchant": "Starbucks",
        "transaction_category_id": null,
        "category": "Food and Drink",
        "subcategory": "Restaurants",
        "description": null,
        "memo": null,
        "location": {
            "address_line1": "1900 Broadway",
            "address_line2": "Floor 4",
            "city": "New York",
            "state": "NY",
            "postalcode": "10023",
            "country": "US",
            "latitude": -73.9747115,
            "longitude": 40.790885
        }
    },
    "investment": {},
    "cash": {},
    "metadata": {},
    "secondary_id": "rGqvy4l5VpukXm3D8qJAsQxNAAQVQqTlPz3qW",
    "create_date": "2019-10-07T16:28:14.000+0000",
    "update_date": "2019-10-09T19:15:43.000+0000",
    "currency_code": "USD",
    "is_excluded_analysis": false,
    "is_recurring": false,
    "is_fee": null,
    "is_transfer": null
}

Retrieve the information for a specific transaction record for an aggregation account. The unique aggregation_account_transaction_id must be provided. The endpoint returns the aggregation_account_transaction_id and details for the aggregation account transaction record.

HTTP REQUEST

GET /aggregation_account_transaction/{aggregation_account_transaction_id}

Update an aggregation account transaction

Example Request

curl -X PUT -H "Authorization: Bearer <access_token>" \
    -H "Content-Type: application/json" \
    -d '{
            "bank_credit" : {
                "location": {
                    "address_line1":"1900 Broadway",
                    "address_line2": "Floor 4",
                    "city": "New York",
                    "state": "NY",
                    "postalcode": "10023",
                    "country": "US",
                    "latitude": -73.9747115,
                    "longitude": 40.790885
                }
            }
        }' "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/aggregation_account_transaction/f5d66968-2c19-4723-b547-899a696c7746"
api_instance = nucleus_api.AggregationAccountApi(nucleus_api.ApiClient(configuration))
# # # Update AggregationTransaction
aggregationAccountTransaction_update = {'currency_code': 'AUD'}
aggregationAccounttransaction_id = 'e22af662-e129-4f28-8cbe-98ae7d7a68e7'

try:
    api_response = api_instance.update_aggregation_account_transaction_using_put(aggregationAccountTransaction_update, aggregationAccounttransaction_id)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling update_aggregation_account_transaction_using_put: %s\n" % e)
AggregationAccountApi apiInstance = new AggregationAccountApi();
        //Update an Aggregation Account Transaction

        Map map5 = new HashMap();
        map.put("currency_code", "GBP");

        try {
            AggregationAccountTransaction response_agg = apiInstance.updateAggregationAccountTransactionUsingPut(map5, UUID.fromString("7ccc048d-3296-466f-8bda-c5bccbfaa37c"));
            System.out.println(response_agg);
        } catch (ApiException e) {
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\AggregationAccountApi(
    new GuzzleHttp\Client(),
    $config);
//Update Aggregation Account Transaction
$aggregation_account_transaction_update = new stdClass();
$aggregation_transaction_id = "44f27cc6-f333-4d56-85c3-e1264c9b1f21";

try {
    $aggregation_account_transaction_update->currency_code = "USD";
    $result = $apiInstance->updateAggregationAccountTransactionUsingPut($aggregation_account_transaction_update, $aggregation_transaction_id);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->updateAggregationAccountTransactionUsingPut: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::AggregationAccountApi.new
#Update Agg Account Transaction
agg_accounttransaction_update = {"currency_code" => 'CAD'}
agg_accounttransaction_id = '7021b0cf-e59a-4427-8620-8ce184c208f9'
begin
  result = api_instance.update_aggregation_account_transaction_using_put(agg_accounttransaction_update, agg_accounttransaction_id)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->update_aggregation_account_transaction_using_put: #{e}"
end
var apiInstance = new HydrogenNucleusApi.AggregationAccountApi();
//Update AggregationAccountBalance
var apiInstance = new HydrogenNucleusApi.AggregationAccountApi();
var callback = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
var aggaccounttransaction = new HydrogenNucleusApi.AggregationAccountTransaction();
var aggaccounttransactionid = "a747f4b7-3ac0-4f3f-a392-3867fd91cb67";

aggaccounttransaction.currency_code = "GBP";
apiInstance.updateAggregationAccountTransactionUsingPut(aggaccounttransaction, aggaccounttransactionid, callback)

Example Response

{
    "id": "7de7dfd3-11e4-4f6d-852c-028f85aa3dc8",
    "aggregation_account_id": "a5becef5-c018-43fe-b7ce-4dae58d50e18",
    "transaction_date": "2019-07-17T00:00:00.000+0000",
    "status": null,
    "bank_credit": {
        "transaction_type": "Debit",
        "amount": 4.33,
        "merchant_id": null,
        "merchant": "Starbucks",
        "transaction_category_id": null,
        "category": "Food and Drink",
        "subcategory": "Restaurants",
        "description": null,
        "memo": null,
        "location": {
            "address_line1": "1900 Broadway",
            "address_line2": "Floor 4",
            "city": "New York",
            "state": "NY",
            "postalcode": "10023",
            "country": "US",
            "latitude": -73.9747115,
            "longitude": 40.790885
        }
    },
    "investment": {},
    "cash": {},
    "metadata": {},
    "secondary_id": "rGqvy4l5VpukXm3D8qJAsQxNAAQVQqTlPz3qW",
    "create_date": "2019-10-07T16:28:14.000+0000",
    "update_date": "2019-10-09T19:15:42.701+0000",
    "currency_code": "USD",
    "is_excluded_analysis": false,
    "is_recurring": false,
    "is_fee": null,
    "is_transfer": null
}

Update a transaction record for an aggregation account. The unique aggregation_account_transaction_id must be provided. To obtain the appropriate aggregation_account_transaction_id, use the GET /aggregation_account_transaction endpoint to view all aggregation account transaction records and their current information. The details to be updated must also be provided. The endpoint returns the aggregation_account_transaction_id and the details for the aggregation account transaction record.

HTTP REQUEST

PUT /aggregation_account_transaction/{aggregation_account_transaction_id}

Delete an aggregation account transaction

Example Request

curl -X DELETE -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/aggregation_account_transaction/f5d66968-2c19-4723-b547-899a696c7746"
api_instance = nucleus_api.AggregationAccountApi(nucleus_api.ApiClient(configuration))
# # Delete a AggregationAccountTrasnaction
aggregationtransactionid = '443ef503-e6d6-4ec1-87d7-22be919cf44d'
try:
    api_instance.delete_aggregation_account_transaction_using_delete(aggregationtransactionid)
except ApiException as e:
    print("Exception when delete_aggregation_account_transaction_using_delete: %s\n" % e)
AggregationAccountApi apiInstance = new AggregationAccountApi();
        //   Delete Aggregation Account Transaction
        try {
            AggregationAccountTransaction deleteresponse = apiInstance.deleteAggregationAccountTransactionUsingDelete(UUID.fromString("377663f6-acc1-4769-8d46-10150b5e3544"));
            System.out.println(deleteresponse);
        } catch (ApiException e) {
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\AggregationAccountApi(
    new GuzzleHttp\Client(),
    $config);
$aggregation_transaction_did = "bf1e9863-df8e-42ef-a73e-0c4d08e2388d"; // string | UUID account_id

try {
    $apiInstance->deleteAggregationAccountTransactionUsingDelete($aggregation_transaction_did);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->deleteAggregationAccountTransactionUsingDelete: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::AggregationAccountApi.new

#Delete Agg Account transaction
agg_accounttransaction1_id = 'e23ae138-6992-4ebb-9ec5-fc6424ea25cc'
begin
  result = api_instance.delete_aggregation_account_transaction_using_delete(agg_accounttransaction1_id)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->delete_aggregation_account_transaction_using_delete: #{e}"
end
var apiInstance = new HydrogenNucleusApi.AggregationAccountApi();
// // //Delete a AggregationAccountTransaction
var aggaccounttransaction = "fbadf3ce-ebb6-43c3-8931-fcc3d731a59d";


var deleteaggregationaccounttransaction = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully.');
    }
};
apiInstance.deleteAggregationAccountTransactionUsingDelete(aggaccounttransaction, deleteaggregationaccounttransaction)

Response (204 No Content)

Permanently delete a transaction record for an aggregation account. The unique aggregation_account_transaction_id must be provided. To obtain the appropriate aggregation_account_transaction_id, use the GET /aggregation_account_transaction endpoint to view all aggregation account transaction records. This deletes the aggregation_account_transaction_id and the details for the aggregation account transaction record.

HTTP REQUEST

DELETE /aggregation_account_transaction/{aggregation_account_transaction_id}

Aggregation Account Holdings

Aggregation account holdings are created under aggregation accounts. This entity is intended to store the investment holdings of the held-away brokerage or retirement account represented in the aggregation account record. Held-away account holding information can be captured by integrating with a third-party service which supports Account Aggregation. This information can be used to provide customers with a better picture of their current investment strategy and gain business insights on investment holdings outside of the application.

Field Type Description
id UUID The id for the aggregation account holding record
aggregation_account_id UUID The unique identifier of the aggregation account the holding belongs to
currency_code string Alphabetic currency code for the currency of the holding, limited to 3 characters. See currency codes
ticker string Ticker of the security holding
ticker_name string Ticker name of the security holding
shares double Number of shares of the security holding
holding_date timestamp Date on which the security holdings are valid; gives the ability to match date and stock price together
amount double Monetary amount of the security holding
holding_type string Describes the type of security holding such as “Equity”, “Fixed Income”, “Cash” or “Mutual Fund”
asset_class string Asset class of the holding such as “US Equity” or “Fixed Income”
price double Price of the security holding
cost_basis double The original value of the asset used for tax purposes, usually the purchase price
exchange string Financial exchange the security holding is traded on such as “NYSE or “NASDAQ”
cusip string The CUSIP of the security holding, a nine-character numeric or alphanumeric code that identifies a North American financial security for clearing and trade settlement
isin string The ISIN of the security holding, a twelve-character alphanumeric code that identifies an international financial security for clearing and trade settlement
secondary_id string Alternate id that can be used to identify the object such as an internal id
create_date timestamp Timestamp for the date and time that the record was created
update_date timestamp Timestamp for the date and time that the record was last updated
metadata map Custom information associated with the holding in the format key:value
See Metadata

List all aggregation account holdings

Example Request

curl -X GET -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/aggregation_account_holding"
api_instance = nucleus_api.AggregationAccountApi(nucleus_api.ApiClient(configuration))
try:
    api_response = api_instance.get_aggregation_account_holding_all_using_get()
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_aggregation_account_holding_all_using_get: %s\n" % e)
AggregationAccountApi apiInstance = new AggregationAccountApi();
        try {
            PageAggregationAccountHolding List = apiInstance.getAggregationAccountHoldingAllUsingGet(true, null, null, null, 0, 10);
            System.out.println(List);
        } catch (ApiException e) {
            System.err.println("Exception when calling getAggregationAccountHoldingAllUsingGet");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\AggregationAccountApi(
    new GuzzleHttp\Client(),
    $config);
$ascending = false; // bool | ascending
$currency_conversion = null; // string | currency_conversion
$filter = null; // string | filter
$order_by = null; // string | order_by
$page = 0; // int | page
$size = 10; // int | size

try {
    $aggrgationholding = $apiInstance->getAggregationAccountHoldingAllUsingGet($ascending, $currency_conversion, $filter, $order_by, $page, $size);
    print_r($aggrgationholding);
} catch (Exception $e) {
    echo 'Exception when calling AggregationAccountApi->getAggregationAccountHoldingAllUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::AggregationAccountApi.new
opts = {
    ascending: false, # BOOLEAN | ascending
    currency_conversion: null, # String | currency_conversion
    filter: null, # String | filter
    order_by: null, # String | order_by
    page: 0, # Integer | page
    size: 25 # Integer | size
}

begin
  holdinglist = api_instance.get_aggregation_account_holding_all_using_get(opts)
  p holdinglist
rescue NucleusApi::ApiError => e
  puts "Exception when calling AggregationAccountApi->get_aggregation_account_holding_all_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.AggregationAccountApi();
var opts = {
    'ascending': false, // Boolean | ascending
    // 'filter': "", // String | filter
    'orderBy': "update_date", // String | order_by
    'page': 0, // Number | page
    'size': 25 // Number | size
};

var aggregationaccountholdinglist = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.getAggregationAccountHoldingAllUsingGet(opts, aggregationaccountholdinglist)

Example Response

{
    "content": [
        {
            "id": "9c5bf062-9cc3-4ded-b083-4863bc342464",
            "aggregation_account_id": "883c101b-0488-4fa1-ad6c-4eff2b6f28d4",
            "ticker": "VR",
            "ticker_name": "Vance Refrigeration",
            "shares": 100.0,
            "holding_date": "2017-03-01T00:00:00.000+0000",
            "currency_code": "USD",
            "amount": 250.0,
            "holding_type": "Equity",
            "asset_class": "US Equity",
            "price": 115.0,
            "cost_basis": 382.7,
            "exchange": "NASDAQ",
            "cusip": "23250930",
            "isin": null,
            "metadata": {},
            "create_date": "2019-10-08T12:33:21.000+0000",
            "update_date": "2019-10-08T12:38:40.000+0000"
        },
        {
            "id": "9c7abded-9b04-44f0-a64a-db1bf799f57a",
            "aggregation_account_id": "883c101b-0488-4fa1-ad6c-4eff2b6f28d4",
            "ticker": "DMPC",
            "ticker_name": "Dunder Mifflin Paper Company",
            "shares": 10.0,
            "holding_date": "2017-03-01T00:00:00.000+0000",
            "currency_code": "USD",
            "amount": 440.45,
            "holding_type": "Equity",
            "asset_class": "US Equity",
            "price": 99.99,
            "cost_basis": 382.7,
            "exchange": "NASDAQ",
            "cusip": "172062101",
            "isin": null,
            "metadata": {},
            "create_date": "2019-10-02T17:02:55.000+0000",
            "update_date": "2019-10-02T17:02:55.000+0000"
        }
    ],
    "last": true,
    "total_elements": 2,
    "total_pages": 1,
    "sort": [
        {
            "direction": "DESC",
            "property": "updateDate",
            "ignore_case": false,
            "null_handling": "NATIVE",
            "descending": true,
            "ascending": false
        }
    ],
    "first": true,
    "number_of_elements": 2,
    "size": 25,
    "number": 0
}

Get all of the holding records for all aggregation accounts defined for your tenant. You can filter using a unique aggregation_account_id to view the holding records for a specific aggregation account. To identify the appropriate aggregation_account_id, use the GET /aggregation_account endpoint to see all aggregation accounts defined for your tenant.

HTTP REQUEST

GET /aggregation_account_holding

Create an aggregation account holding

Example Request

curl -X POST -H "Authorization: Bearer <access_token>" \
-H "Content-Type: application/json" \
-d '{
      "ticker": "VR",
      "ticker_name": "Vance Refrigeration",
      "shares": 100,
      "holding_date" : "2017-03-01T00:00:00.000+0000",
      "currency_code": "USD",
      "amount": 200.50,
      "holding_type": "Equity",
      "asset_class": "US Equity",
      "price": 100.00,
      "cost_basis": 382.70,
      "exchange": "NASDAQ",
      "cusip": "23250930",
      "aggregation_account_id": "883c101b-0488-4fa1-ad6c-4eff2b6f28d4"
     }' "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/aggregation_account_holding"
api_instance = nucleus_api.AggregationAccountApi(nucleus_api.ApiClient(configuration))
# # # Create a Aggregation Account Holding
aggholding = nucleus_api.AggregationAccountHolding(aggregation_account_id="3ddf08f8-8c29-4381-a362-6dbbaafa3c2e", currency_code="USD", ticker="abc", shares="10")
aggholding1 = nucleus_api.AggregationAccountHolding(aggregation_account_id="3ddf08f8-8c29-4381-a362-6dbbaafa3c2e", ticker="gjhg", currency_code="GBP", shares="10")

try:
    api_response = api_instance.create_aggregation_account_holding_using_post(aggholding)
    pprint(api_response)
except ApiException as e:
    print("create_aggregation_account_holding_using_post: %s\n" % e)
AggregationAccountApi apiInstance = new AggregationAccountApi();
        //Create Aggregation Account Holding
        AggregationAccountHolding aggregationAccountHolding = new AggregationAccountHolding();
        aggregationAccountHolding.aggregationAccountId(UUID.fromString("ac83c28e-3bab-48e6-b7ef-69732afa78bc"));
        aggregationAccountHolding.ticker("2");
        aggregationAccountHolding.tickerName("Abc");
        aggregationAccountHolding.shares(2.0);
        aggregationAccountHolding.currencyCode("USD");
        aggregationAccountHolding.amount(100.00);
        aggregationAccountHolding.price(20.0);
        try {
            AggregationAccountHolding result = apiInstance.createAggregationAccountHoldingUsingPost(aggregationAccountHolding);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling createAggregationAccountHoldingUsingPost");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\AggregationAccountApi(
    new GuzzleHttp\Client(),
    $config);
//Create Aggregation Account Holding
$aggregation_account_holding = new \com\hydrogen\nucleus\Model\AggregationAccountHolding();

try {
    $aggregation_account_holding->setAggregationAccountId("ac83c28e-3bab-48e6-b7ef-69732afa78bc");
    $aggregation_account_holding->setTickerName("ABC");
    $aggregation_account_holding->setTicker("YT");
    $aggregation_account_holding->setShares("300");
    $aggregation_account_holding->setCurrencyCode("GBP");
    $aggregation_account_holding->setAmount("10");
    $aggregation_account_holding->setPrice("300");

    $result = $apiInstance->createAggregationAccountHoldingUsingPost($aggregation_account_holding);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->createAggregationAccountHoldingUsingPost: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::AggregationAccountApi.new

#Create Aggregation Account Holding
agg_account_holding = NucleusApi::AggregationAccountHolding.new

begin
  agg_account_holding.aggregation_account_id = "ac83c28e-3bab-48e6-b7ef-69732afa78bc"
  agg_account_holding.ticker_name = "abc"
  agg_account_holding.ticker = "AB"
  agg_account_holding.shares = "200"
  agg_account_holding.currency_code = "USD"
  agg_account_holding.amount = "200"
  agg_account_holding.price = "300"
  result = api_instance.create_aggregation_account_holding_using_post(agg_account_holding)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->create_aggregation_account_holding_using_post: #{e}"
end
var apiInstance = new HydrogenNucleusApi.AggregationAccountApi();
// //Create Aggregation Account Holding

var aggaccountholding = new HydrogenNucleusApi.AggregationAccountHolding();
aggaccountholding.aggregation_account_id = 'ac83c28e-3bab-48e6-b7ef-69732afa78bc';
aggaccountholding.ticker = "ABn";
aggaccountholding.ticker_name = "New";
aggaccountholding.shares = "50";
aggaccountholding.currency_code = "USD";
aggaccountholding.amount = "100";
aggaccountholding.price = "30";

var newaggregationholding = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.createAggregationAccountHoldingUsingPost(aggaccountholding, newaggregationholding)

Example Response

{
    "id": "9c5bf062-9cc3-4ded-b083-4863bc342464",
    "aggregation_account_id": "883c101b-0488-4fa1-ad6c-4eff2b6f28d4",
    "ticker": "VR",
    "ticker_name": "Vance Refrigeration",
    "shares": 100.0,
    "holding_date": "2017-03-01T00:00:00.000+0000",
    "currency_code": "USD",
    "amount": 200.5,
    "holding_type": "Equity",
    "asset_class": "US Equity",
    "price": 100.0,
    "cost_basis": 382.7,
    "exchange": "NASDAQ",
    "cusip": "23250930",
    "isin": null,
    "metadata": {},
    "create_date": "2019-10-08T12:33:21.375+0000",
    "update_date": "2019-10-08T12:33:21.375+0000"
}

Create a holding record under an aggregation account. The aggregation_account_id must be provided. To obtain the appropriate aggregation_account_id use the GET /aggregation_account endpoint to view all aggregation accounts for your tenant. The endpoint returns an aggregation_account_holding_id used to manage the aggregation account record.

HTTP REQUEST

POST /aggregation_account_holding

ARGUMENTS

Parameter Type Required Description
aggregation_account_id UUID required The unique identifier of the aggregation account the holding belongs to
currency_code string optional Alphabetic currency code for the currency of the holding, limited to 3 characters. See currency codes
ticker string required, conditional Ticker of the security holding. Either ticker or ticker_name must be provided.
ticker_name string required, conditional Ticker name of the security holding. Either ticker_name or ticker must be provided.
shares double required Number of shares of the security holding
holding_date timestamp optional Date on which the security holdings are valid; gives the ability to match date and stock price together
amount double optional Monetary amount of the security holding
holding_type string optional Describes the type of security holding such as “Equity”, “Fixed Income”, “Cash” or “Mutual Fund”
asset_class string optional Asset class of the holding such as “US Equity” or “Fixed Income”
price double optional Price of the security holding
cost_basis double optional The original value of the asset used for tax purposes, usually the purchase price
exchange string optional Financial exchange the security holding is traded on such as “NYSE or “NASDAQ”
cusip string optional The CUSIP of the security holding, a nine-character numeric or alphanumeric code that identifies a North American financial security for clearing and trade settlement
isin string optional The ISIN of the security holding, a twelve-character alphanumeric code that identifies an international financial security for clearing and trade settlement
secondary_id string optional Alternate id that can be used to identify the object such as an internal id
metadata map optional Custom information associated with the holding in the format key:value
See Metadata

Retrieve an aggregation account holding

Example Request

curl -X GET -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/aggregation_account_holding/9c7abded-9b04-44f0-a64a-db1bf799f57a"
api_instance = nucleus_api.AggregationAccountApi(nucleus_api.ApiClient(configuration))
try:
    api_response = api_instance.get_aggregation_account_holding_using_get("18ca9768-5d8d-4f8d-8f74-234e021eac60");
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_aggregation_account_holding_all_using_get: %s\n" % e)
AggregationAccountApi apiInstance = new AggregationAccountApi();
        try {
            AggregationAccountHolding responseaggregationholding = apiInstance.getAggregationAccountHoldingUsingGet(UUID.fromString("a5625e65-49e6-4590-9dac-4c4b1affe55f"), null);
            System.out.println(responseaggregationholding);
        } catch (ApiException e) {
            System.err.println("Exception when calling getAggregationAccountHoldingUsingGet");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\AggregationAccountApi(
    new GuzzleHttp\Client(),
    $config);
$aggregation_account_holding_id = "a5625e65-49e6-4590-9dac-4c4b1affe55f"; // string | UUID aggregation_account_holding_id
$currency_conversion = null; // string | USD

try {
    $aggregationholding = $apiInstance->getAggregationAccountHoldingUsingGet($aggregation_account_holding_id, $currency_conversion);
    print_r($aggregationholding);
} catch (Exception $e) {
    echo 'Exception when calling AggregationAccountApi->getAggregationAccountHoldingUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::AggregationAccountApi.new
aggregation_account_holding_id = 'a5625e65-49e6-4590-9dac-4c4b1affe55f' # String | UUID aggregation_account_holding_id

opts = {
    currency_conversion: null, # String | USD
}

begin
  holdings = api_instance.get_aggregation_account_holding_using_get(aggregation_account_holding_id, opts)
  p holdings
rescue NucleusApi::ApiError => e
  puts "Exception when calling AggregationAccountApi->get_aggregation_account_holding_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.AggregationAccountApi();
var aggaccounttransactionId = "ff57a386-58bd-44bf-8e2e-341cf36625df";
var aggregationaccountholding = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.getAggregationAccountHoldingUsingGet("ff57a386-58bd-44bf-8e2e-341cf36625df", aggregationaccountholding)

Example Response

{
    "id": "9c7abded-9b04-44f0-a64a-db1bf799f57a",
    "aggregation_account_id": "883c101b-0488-4fa1-ad6c-4eff2b6f28d4",
    "ticker": "DMPC",
    "ticker_name": "Dunder Mifflin Paper Company",
    "shares": 10.0,
    "holding_date": "2017-03-01T00:00:00.000+0000",
    "currency_code": "USD",
    "amount": 440.45,
    "holding_type": "Equity",
    "asset_class": "US Equity",
    "price": 99.99,
    "cost_basis": 382.7,
    "exchange": "NASDAQ",
    "cusip": "172062101",
    "isin": null,
    "metadata": {},
    "create_date": "2019-10-02T17:02:55.000+0000",
    "update_date": "2019-10-02T17:02:55.000+0000"
}

Retrieve the information for a specific holding record for an aggregation account. The unique aggregation_account_holding_id must be provided. The endpoint returns the aggregation_account_holding_id and details for the aggregation account holding record.

HTTP REQUEST

GET /aggregation_account_holding/{aggregation_account_holding_id}

Update an aggregation account holding

Example Request

curl -X PUT -H "Authorization: Bearer <access_token>" \
    -H "Content-Type: application/json" \
    -d '{
          "amount": 250.00,
          "price": 115.00
        }' "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/aggregation_account_holding/9c5bf062-9cc3-4ded-b083-4863bc342464"
api_instance = nucleus_api.AggregationAccountApi(nucleus_api.ApiClient(configuration))
# # # Update AggregationHolding
aggregationAccountHolding_update = {'currency_code': 'AUD'}
aggregationAccountHolding_id = '3fed4bb9-1bab-4e7d-a85b-2bf3a0b8a533'

try:
    api_response = api_instance.update_aggregation_account_holding_using_put(aggregationAccountHolding_update, aggregationAccountHolding_id)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling update_aggregation_account_holding_using_put: %s\n" % e)
AggregationAccountApi apiInstance = new AggregationAccountApi();
        //Update an Aggregation Account Holding

        Map map6 = new HashMap();
        map.put("shares", 150.00);

        try {
            AggregationAccountHolding response_agg1 = apiInstance.updateAggregationAccountHoldingUsingPut(map6, UUID.fromString("bd97cf39-31c3-4063-84a1-134eb86c9103"));
            System.out.println(response_agg1);
        } catch (ApiException e) {
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\AggregationAccountApi(
    new GuzzleHttp\Client(),
    $config);
//Update Aggregation Account Holding
$aggregation_account_holding_update = new stdClass();
$aggregation_holding_id = "03363abd-d449-4979-a6ec-c5550ca409c8";

try {
    $aggregation_account_holding_update->currency_code = "GBP";
    $result = $apiInstance->updateAggregationAccountHoldingUsingPut($aggregation_account_holding_update, $aggregation_holding_id);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->updateAggregationAccountHoldingUsingPut: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::AggregationAccountApi.new

#Update Agg Account Holding
agg_accountholding_update = {"currency_code" => 'CAD'}
agg_accountholding_id = '05be7096-89ff-4d1a-9434-ed0abaa9f738'
begin
  result = api_instance.update_aggregation_account_holding_using_put(agg-agg_accountholding_update, agg_accountholding_id)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->update_aggregation_account_holding_using_put: #{e}"
end
var apiInstance = new HydrogenNucleusApi.AggregationAccountApi();
//Update AggregationAccountBalance
var apiInstance = new HydrogenNucleusApi.AggregationAccountApi();
var callback = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
var aggaccountholding = new HydrogenNucleusApi.AggregationAccountHolding();
var aggaccountholdingid = "b654d0f3-5916-4204-9211-f5bcb5b98600";

aggaccountholding.ticker = 'Ne';
apiInstance.updateAggregationAccountHoldingUsingPut(aggaccountholding, aggaccountholdingid, callback)

Example Response

{
    "id": "9c5bf062-9cc3-4ded-b083-4863bc342464",
    "aggregation_account_id": "883c101b-0488-4fa1-ad6c-4eff2b6f28d4",
    "ticker": "VR",
    "ticker_name": "Vance Refrigeration",
    "shares": 100.0,
    "holding_date": "2017-03-01T00:00:00.000+0000",
    "currency_code": "USD",
    "amount": 250.0,
    "holding_type": "Equity",
    "asset_class": "US Equity",
    "price": 115.0,
    "cost_basis": 382.7,
    "exchange": "NASDAQ",
    "cusip": "23250930",
    "isin": null,
    "metadata": {},
    "create_date": "2019-10-08T12:33:21.000+0000",
    "update_date": "2019-10-08T12:38:40.371+0000"
}

Update a holding record for an aggregation account. The unique aggregation_account_holding_id must be provided. To obtain the appropriate aggregation_account_holding_id, use the GET /aggregation_account_holding endpoint to view all aggregation account holding records and their current information. The details to be updated must also be provided. The endpoint returns the aggregation_account_holding_id and the details for the aggregation account holding record.

HTTP REQUEST

PUT /aggregation_account_holding/{aggregation_account_holding_id}

Delete an aggregation account holding

Example Request

curl -X DELETE -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/aggregation_account_holding/9c5bf062-9cc3-4ded-b083-4863bc342464"
api_instance = nucleus_api.AggregationAccountApi(nucleus_api.ApiClient(configuration))
# # # # # Delete a AggregationAccountHolding
aggregationholdingid = '46e13052-ef3f-4e2f-8f47-e255e59be58d'
try:
    api_instance.delete_aggregation_account_holding_using_delete(aggregationholdingid)
except ApiException as e:
    print("Exception when delete_aggregation_account_holding_using_delete: %s\n" % e)
AggregationAccountApi apiInstance = new AggregationAccountApi();
        //   Delete Aggregation Account Holding
        try {
            AggregationAccountHolding deleteresponse = apiInstance.deleteAggregationAccountHoldingUsingDelete(UUID.fromString("faa548e6-3eab-4837-8f4e-507d34227437"));
            System.out.println(deleteresponse);
        } catch (ApiException e) {
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\AggregationAccountApi(
    new GuzzleHttp\Client(),
    $config);
//Delete AggregationAccountHolding
$aggregation_holding_did = "3fed4bb9-1bab-4e7d-a85b-2bf3a0b8a533"; // string | UUID account_id

try {
    $apiInstance->deleteAggregationAccountHoldingUsingDelete($aggregation_holding_did);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->deleteAggregationAccountHoldingUsingDelete: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::AggregationAccountApi.new

#Delete Agg Account Holding
agg_accountholding1_id = '1fd5cb91-518e-471d-bd50-294b3d7bd141'
begin
  result = api_instance.delete_aggregation_account_holding_using_delete(agg_accountholding1_id)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->delete_aggregation_account_holding_using_delete: #{e}"
end
var apiInstance = new HydrogenNucleusApi.AggregationAccountApi();
// //Delete a AggregationAccountHolding
var aggaccountholding = "03363abd-d449-4979-a6ec-c5550ca409c8";


var deleteaggregationaccountholding = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully.');
    }
};
apiInstance.deleteAggregationAccountHoldingUsingDelete(aggaccountholding, deleteaggregationaccountholding)

Response (204 No Content)

Permanently delete a holding record for an aggregation account. The unique aggregation_account_holding_id must be provided. To obtain the appropriate aggregation_account_holding_id, use the GET /aggregation_account_holding endpoint to view all aggregation account holding records. This deletes the aggregation_account_holding_id and the details for the aggregation account holding record.

HTTP REQUEST

DELETE /aggregation_account_holding/{aggregation_account_holding_id}

Aggregation Account Overview

Aggregates the details of all held-away accounts associated to a client oor business, by category, including the account details and latest balance. This view is useful to display an aggregation account dashboard for a PFM.

Field Type Description
by_category list List of aggregation account details and balances by account category
      category string Category of the aggregation account
      total_balance double Total balance of the aggregation account for the category
      total_available_balance double Total available balance of the aggregation account, usually taking into consideration pending transactions or available overdraft
      aggregation_account_details list List of the aggregation accounts that are in the category
            aggregation_account_id UUID The ID for the aggregation account
            account_name string The name of the aggregation account
            client_id UUID The ID of a client to which the aggregation account belongs
            institution_id UUID ID of the institution resource for this held-away account.
            institution_name string The name of the institution holding the aggregation account
            account_category_id UUID ID of the category resource for this held-away account
            category string Category for the aggregation account such as “Bank Account”
            subcategory string Subcategory for the aggregation account such as “Checking Account”
            currency_code string Alphabetic currency code for the base currency of the account linked, limited to 3 characters.
            is_active boolean Indicates if the aggregation account record is active.
            mask string The masked version of the full account number for the aggregation account
            balance double Latest balance of the aggregation account
            available_balance double Latest available balance of the aggregation account, usually taking into consideration pending transactions or available overdraft
            balance_time_stamp datetime Date and time for when the balance above applies
            aggregation_account_balance_id UUID The ID for the aggregation account balance record
            is_asset boolean A flag to represent if this account is an asset or liability. If false the account is categorized as a liability.
            is_manual boolean A flag to represent if this account was added manually. If true the account is synced via an aggregator.

HTTP REQUEST

Client: GET /client/{client_id}/aggregation_account_overview

Business: GET /business/{business_id}/aggregation_account_overview

Example Request

curl -X GET -H "Authorization: Bearer <access_token>" \
  "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/client/0797npda-cf8b-4151-9cb4-d1ekn66r5dcd/aggregation_account_overview"
api_instance = nucleus_api.AggregationAccountApi(nucleus_api.ApiClient(configuration))
try:
    api_response = api_instance.get_aggregation_account_overview_using_get("034e9d53-21c5-44d8-a9e6-fb2d6aa867e6")
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_aggregation_account_overview_using_get: %s\n" % e)
api_instance = nucleus_api.AggregationAccountApi(nucleus_api.ApiClient(configuration))
# # # Get an AggregationAccountOverviewUsingBalance
business_id = '4c103aa2-b9ac-4277-99d2-33f7ef7d7ce7'
try:
    api_response = api_instance.get_aggregation_account_overview_by_business_id_using_get(business_id)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_aggregation_account_overview_by_business_id_using_get: %s\n" % e)
AggregationAccountApi apiInstance = new AggregationAccountApi();
        try {
             Object aggregationAccountOverview
                    = apiInstance.getAggregationAccountOverviewUsingGet(UUID.fromString("034e9d53-21c5-44d8-a9e6-fb2d6aa867e6"), null);
            System.out.println(aggregationAccountOverview);
        } catch (ApiException e) {
            System.err.println("Exception when calling getAggregationAccountOverviewUsingGet");
            e.printStackTrace();
        }
AggregationAccountApi apiInstance = new AggregationAccountApi();
        //Get Business Overview

        try {

            Object aggregationAccountOverview  = apiInstance.getAggregationAccountOverviewByBusinessIdUsingGet(UUID.fromString("e5e6863f-1e7f-44d4-a42d-0558b280cade"), null);
            System.out.println(aggregationAccountOverview);
        } catch (ApiException e) {
            System.err.println("Exception when calling getAggregationAccountOverviewByBusinessIdUsingGet");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\AggregationAccountApi(
    new GuzzleHttp\Client(),
    $config);
$client_id = "034e9d53-21c5-44d8-a9e6-fb2d6aa867e6"; // string | UUID client_id
$currency_conversion = null; // string | USD

try {
    $aggregationoverview = $apiInstance->getAggregationAccountOverviewUsingGet($client_id, $currency_conversion);
    print_r($aggregationoverview);
} catch (Exception $e) {
    echo 'Exception when calling AggregationAccountApi->getAggregationAccountOverviewUsingGet: ', $e->getMessage(), PHP_EOL;
}
$apiInstance = new com\hydrogen\nucleus\Api\AggregationAccountApi(
    new GuzzleHttp\Client(),
    $config);
//Get AggregateAccount Overview by business
$business_id = "4c103aa2-b9ac-4277-99d2-33f7ef7d7ce7"; // string | UUID client_id
$currency_conversion = null; // string | USD

try {
    $aggregationoverview1 = $apiInstance->getAggregationAccountOverviewByBusinessIdUsingGet($business_id, $currency_conversion);
    print_r($aggregationoverview1);
} catch (Exception $e) {
    echo 'Exception when calling AggregationAccountApi->getAggregationAccountOverviewUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::AggregationAccountApi.new
client_id = '034e9d53-21c5-44d8-a9e6-fb2d6aa867e6' # String | UUID client_id

opts = {
    currency_conversion: null, # String | USD
}

begin
  overview = api_instance.get_aggregation_account_overview_using_get(client_id, opts)
  p overview
rescue NucleusApi::ApiError => e
  puts "Exception when calling AggregationAccountApi->get_aggregation_account_overview_using_get: #{e}"
end
api_instance = NucleusApi::AggregationAccountApi.new
#Get AggregationAccountOverview Using Business
business_id = '77faf004-a5da-4067-b1fa-978e9206307d' # String | UUID client_id

opts = {
  currency_conversion: null, # String | USD
}

begin
  overview = api_instance.get_aggregation_account_overview_by_business_id_using_get(business_id, opts)
  p overview
rescue NucleusApi::ApiError => e
  puts "Exception when calling AggregationAccountApi->get_aggregation_account_overview_by_business_id_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.AggregationAccountApi();
var overview = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' + data);
    }
};
var clientId = "034e9d53-21c5-44d8-a9e6-fb2d6aa867e6";

var opts = {
    'currencyConversion': null, // String | USD
};
apiInstance.getAggregationAccountOverviewUsingGet(clientId, opts, overview)
var apiInstance = new HydrogenNucleusApi.AggregationAccountApi();
// //Get AggregationOverview by business
var overview = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' + data);
    }
};
var businessId = "034e9d53-21c5-44d8-a9e6-fb2d6aa867e6";

var opts = {
    'currencyConversion': null, // String | USD
};
apiInstance.getAggregationAccountOverviewByBusinessIdUsingGet(businessId, opts, overview)

Example Response

{
    "by_category": [
        {
            "category": "Loan",
            "total_balance": 52221.2,
            "total_available_balance": 3500.5,
            "aggregation_account_details": [
                {
                    "aggregated_account_id": "e830f722-e072-4733-acbf-09ad7406a2a4",
                    "account_name": "Mortgage",
                    "client_id": "1c92f054-e4a6-4e45-b29b-567587f34c27",
                    "institution_id": null,
                    "institution_name": "Quicken Loans",
                    "account_category_id": null,
                    "category": "Loan",
                    "subcategory": "Mortgage",
                    "currency_code": "USD",
                    "is_active": true,
                    "mask": "XXXXXXX699",
                    "balance": "52221.2",
                    "available_balance": "52221.2",
                    "balance_time_stamp": "2016-12-31T00:00:00.000+0000",
                    "aggregation_account_balance_id": "591cab95-3361-466c-a102-8f006e58d3c2",
                    "is_asset": false,
                    "is_manual": false
                }
            ]
        },
        {
            "category": "Banking",
            "total_balance": 202225.28,
            "aggregated_account_details": [
                {
                    "aggregated_account_id": "1edd1a94-0b74-4675-9187-e9c85d7246cd",
                    "account_name": "Superior Saving",
                    "client_id": "1c92f054-e4a6-4e45-b29b-567587f34c27",
                    "institution_id": null,
                    "institution_name": "Barnstoup Bank",
                    "account_category_id": null,
                    "category": "Banking",
                    "subcategory": "Savings",
                    "mask": "XXXXXXX442",
                    "currency_code": "USD",
                    "is_active": true,
                    "balance": "88254.05",
                    "available_balance": "88254.05",
                    "balance_time_stamp": "2016-12-31T00:00:00.000+0000",
                    "aggregation_account_balance_id": "9cdea4ec-aef6-4125-a503-07384a299897",
                    "is_asset": true,
                    "is_manual": false
                },
                {
                    "aggregated_account_id": "a21f935e-0c18-49af-b6ae-8722ae83850a",
                    "account_name": "Superior Checking",
                    "client_id": "1c92f054-e4a6-4e45-b29b-567587f34c27",
                    "institution_id": null,
                    "institution_name": "Barnstoup Bank",
                    "account_category_id": null,
                    "category": "Banking",
                    "subcategory": "Checking",
                    "currency_code": "USD",
                    "is_active": true,
                    "mask": "XXXXXXX851",
                    "balance": "113971.23",
                    "available_balance": "113971.23",
                    "balance_time_stamp": "2016-12-31T00:00:00.000+0000",
                    "aggregation_account_balance_id": "476dbb24-e022-46e9-8367-bec2d6fc3bcc",
                    "is_asset": true,
                    "is_manual": false
                }
            ]
        },
        {
            "category": "Property",
            "total_balance": 87671.30635,
            "aggregated_account_details": [
                {
                    "aggregated_account_id": "002c59f2-5b4a-41bb-b8b3-081f771fac83",
                    "account_name": "Property valuation",
                    "client_id": "1c92f054-e4a6-4e45-b29b-567587f34c27",
                    "institution_id": null,
                    "institution_name": "Zellough",
                    "account_category_id": null,
                    "category": "Property",
                    "currency_code": "USD",
                    "is_active": true,
                    "mask": "XXXXXXX236",
                    "balance": "87671.30635",
                    "available_balance": "87671.30635",
                    "balance_time_stamp": "2016-12-31T00:00:00.000+0000",
                    "aggregation_account_balance_id": "c8e4c170-85ac-480a-8e94-1ee3dcdac3cb",
                    "is_asset": true,
                    "is_manual": false
                }
            ]
        }
    ]
}

Aggregation Account Drill-Down

Aggregates the details of one specific held-away account associated to a client, including the account details, transactions, holdings, and latest balance. This view is useful to drill down into an aggregation account from a PFM dashboard.

Field Type Description
aggregation_account_id UUID The ID of the aggregation account
aggregation_account_details map Details of the aggregation account
      institution_id UUID ID of the institution resource for this held-away account.
      institution_name string The name of the institution holding the aggregation account
      account_name string The name of the aggregation account
      account_holder string The owner of the aggregation account
      mask string The masked version of the full account number of the aggregation account
      account_category_id UUID ID of the category resource for this held-away account
      category string Category for the aggregation account such as “Bank Account”
      subcategory string Subcategory for the aggregation account such as “Checking Account”
      currency_code string Currency code for the base currency of the account linked. See Currency Codes
      is_asset boolean A flag to represent if this account is an asset or liability. Defaults to true, which indicates it is an asset. If false, this account is categorized as a liability.
      secondary_id string Alternate id that can be used to identify the account such as an internal id
      create_date timestamp Timestamp for the date and time when the record was created
      update_date timestamp Timestamp for the date and time when the record was last updated
      metadata map Custom information associated with the aggregation account in the format key:value. See Metadata
aggregation_account_balances map List of all the aggregation account balances. We currently display the latest balance only.
      aggregation_account_balance_id UUID The ID of the balance record
      balance double Current balance of the aggregation account
      available_balance double Current available balance of the aggregation account, usually taking into consideration pending transactions or available overdraft.
      balance_time_stamp datetime Date and time for when the balance above applies
      currency_code string Currency code for the base currency of the account linked. See Currency Codes
      create_date timestamp Timestamp for the date and time when the record was created
      update_date timestamp Timestamp for the date and time when the record was last updated
aggregation_account_transactions map List of all the aggregation account transactions
      aggregation_account_transaction_id UUID The ID for the aggregation account transaction record
      transaction_date timestamp The date the transaction took place
      status string The status of the transaction within its lifecycle such as “Pending” or “Posted”
      bank_credit map Transaction information if from a bank, debit card, or credit card transaction
            transaction_type string Type of bank or credit transaction. Value may be debit or credit
            amount double Amount of the transaction
            merchant_id UUID ID of the merchant resource for the transaction
            merchant string The merchant for the transaction such as the merchant posted for a credit card transaction
            transaction_category_id UUID ID of the category resource for the transaction
            category string Category of the transaction
            subcategory string Subcategory of the transaction
            description string Description of the transaction
            memo string Memo attached to the transaction
            location map Location where the transaction occurred
                address_line1 string Primary information for the street address, such as the street and building number
                address_line2 string Secondary information for the street address, such as a suite or apartment number
                city string City of the address
                state string State, province, or sub-country region for the address
                postalcode string Alphanumeric postal code or zip code for the address
                country string Country for the address using the ISO ALPHA-2 Code. See Country Codes
                latitude double Latitude of the location where the transaction occurred
                longitude double Longitude of the location where the transaction occurred
      investment map Transaction information if from an investment account trade
            trade_signal string Trade signal for an investment trade such as “Buy” or “Sell:
            ticker string Ticker of the security for an investment transaction
            ticker_name string Ticker name of the security for an investment transaction
            price double Price of the security for an investment transaction
            quantity double The number of shares involved in this transaction
            fee double Fee that is part of the transaction
            settle_date timestamp Date on which transaction was finalized
            secondary_id string Alternate id that can be used to identify the object such as an internal ID
            create_date timestamp Timestamp for the date and time when the record was created
            update_date timestamp Timestamp for the date and time when the record was last updated
            metadata map Custom information associated with the aggregation account in the format key:value. See Metadata section of the online documentation
aggregation_account_holdings array(map) List of all aggregation account holdings
      aggregation_account_holding_id UUID The ID for the aggregation account holding record
      ticker string Ticker of the security holding
      ticker_name string Ticker name of the security holding
      shares double Number of shares of the security holding
      amount double Monetary amount of the security holding
      currency_code string Currency code for the base currency of the account linked. See Currency Codes
      holding_type string Describes the type of security holding such as “Equity”, “Fixed Income”, “Cash”, “Mutual Fund”
      asset_class string Asset class of the holding such as “US Equity” or “Fixed Income”
      price double Price of the security holding
      cost_basis double The original value of the asset used for tax purposes, usually the purchase price
      exchange string Financial exchange the security holding is traded on such as “NYSE” or “NASDAQ”
      cusip string The CUSIP of the security holding, a nine-character numeric or alphanumeric code that identifies a North American financial security for clearing and trade settlement
      holding_date timestamp Date on which the security holdings are valid; gives the ability to match date and stock price together

HTTP REQUEST

GET /aggregation_account/{aggregation_account_id}/aggregate_data

Example Request

curl -X GET -H "Authorization: Bearer <access_token>" \
  "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/aggregation_account/0297npda-cf8b-4151-9nf4-d1ekn66r5ckd/aggregate_data"
api_instance = nucleus_api.AggregationAccountApi(nucleus_api.ApiClient(configuration))
try:
    api_response = api_instance.get_aggregation_account_aggregate_data_using_get("034e9d53-21c5-44d8-a9e6-fb2d6aa867e6")
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_aggregation_account_aggregate_data_using_get: %s\n" % e)
AggregationAccountApi apiInstance = new AggregationAccountApi();
        try {
            Object aggregationdata = apiInstance.getAggregationAccountAggregateDataUsingGet(UUID.fromString("55cff7a0-f7b3-464c-b59f-8756a5cc5ffd"), null);
            System.out.println(aggregationdata);
        } catch (ApiException e) {
            System.err.println("Exception when calling getAggregationAccountAggregateDataUsingGet");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\AggregationAccountApi(
    new GuzzleHttp\Client(),
    $config);
$aggregation_account_id = "55cff7a0-f7b3-464c-b59f-8756a5cc5ffd"; // string | UUID aggregation_account_id
$currency_conversion = null; // string | USD

try {
    $aggregatedata = $apiInstance->getAggregationAccountAggregateDataUsingGet($aggregation_account_id, $currency_conversion);
    print_r($aggregatedata);
} catch (Exception $e) {
    echo 'Exception when calling AggregationAccountApi->getAggregationAccountAggregateDataUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::AggregationAccountApi.new
aggregation_account_id = '55cff7a0-f7b3-464c-b59f-8756a5cc5ffd' # String | UUID aggregation_account_id

opts = {
    currency_conversion: null, # String | USD
}

begin
  aggregatedata = api_instance.get_aggregation_account_aggregate_data_using_get(aggregation_account_id, opts)
  p aggregatedata
rescue NucleusApi::ApiError => e
  puts "Exception when calling AggregationAccountApi->get_aggregation_account_aggregate_data_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.AggregationAccountApi();
var aggregationaccountaggregate = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' + JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.getAggregationAccountAggregateDataUsingGet("732ebec0-1411-4e22-9219-3076eb683741", aggregationaccountaggregate)

Example Response

    {
        "aggregation_account_id": "e52e0018-0eaf-4066-b2ff-94de667da2dc",
        "aggregation_account_details": {
            "institution_id": null,
            "institution_name": "Citywide Bank",
            "account_name": "Bank Gold Checking",
            "mask": "XXXXX8991",
            "account_category_id": null,
            "category": "Bank Account",
            "subcategory": "Checking Account",
            "currency_code": "USD",
            "create_date": "2019-10-30T06:33:51.000+0000",
            "update_date": "2019-10-30T06:33:51.000+0000",
            "metadata": {}
        },
        "aggregation_account_balances": {
            "aggregation_account_balance_id": "54fd8c7e-df7f-44d8-97d8-a864423e744c",
            "balance": "36760.43",
            "available_balance": "35760.43",
            "balance_time_stamp": "2019-11-30T00:00:00.000+0000",
            "currency_code": "USD",
            "create_date": "2019-10-30T06:45:53.000+0000",
            "update_date": "2019-10-30T06:45:53.000+0000"
        },
        "aggregation_account_transactions": [
            {
                "aggregation_account_transaction_id": "b170df9f-e609-46a3-a1c4-d49c3eb1c9c0",
                "transaction_date": "2019-10-23T00:00:00.000+0000",
                "bank_credit": {
                "transaction_type": "Debit",
                "amount": 16.32,
                "merchant_id": null,
                "merchant": "Prime Fresh*1R3I26IW3",
                "transaction_category_id": null,
                "category": "Service",
                "subcategory": "Food and Beverage",
                "description": null,
                "memo": null,
                "location": {}
            },
            "currency_code": "USD",
            "metadata": {},
            "create_date": "2019-10-30T09:27:49.000+0000",
            "update_date": "2019-10-30T09:32:56.000+0000",
            "is_excluded_analysis": false
        }
    ],
    "aggregation_account_holdings": [
        {
            "aggregation_account_holding_id": "b90a63a0-be6c-4721-9d76-4fe47a181360",
            "ticker": "DDDD",
            "ticker_name": "Dunder Mifflin Company",
            "shares": 10.0,
            "currency_code": "USD",
            "amount": 440.45,
            "holding_type": "Equity",
            "asset_class": "US Equity",
            "price": 88.09,
            "cost_basis": 382.7,
            "exchange": "NASDAQ",
            "cusip": "172062101",
            "holding_date": "1971-01-01T00:00:03.000+0000",
            "metadata": {},
            "create_date": "2019-10-30T07:28:31.000+0000",
            "update_date": "2019-10-30T07:33:39.000+0000"
        }
    ]
}

Allocation

Allocation Management

Allocations are a collection of models to which accounts can subscribe. An account may be subscribed to one or more allocations. An allocation may have one or more accounts subscribing to it. For goals based investing/savings, an allocation may map to one goal. Allocations can also map to the nodes of a decision tree to determine which allocation(s) is/are most appropriate for an account.

Field Type Description
id UUID The id of the allocation
name string Name of the allocation
category string Category of the allocation used to group similar allocations
description string Description of the allocation
client_id UUID If the allocation is to be used by a specific client such as an advisor, the id of the client
benchmark_id UUID The id for the benchmark that the allocation should be compared to
inception_date date Date that the allocation first was managed
node_map array List of nodes in a decision tree that map to the allocation
      node_id UUID The id of the last node in the branch of a decision tree that maps to the allocation
metadata map Custom information associated with the allocation in the format key:value. See Metadata
is_active boolean Indicates if this allocation is active. Defaults to true which indicates it is active.
secondary_id string Alternate id that can be used to identify the object such as an internal id
create_date timestamp Timestamp for the date and time that the record was created
update_date timestamp Timestamp for the date and time that the record was last updated

PROTON API

The following fields may optionally be used in conjunction with the Proton API. These are usually calculated via an overnight process.

Field Type Description
performance double Historical performance for the allocation, used as an input for simulations.
volatility double Historical volatility for the allocation, used as an input for simulations.

List all allocations

Example Request

curl -X GET -H "Authorization: Bearer <access_token>" \
  "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/allocation"
api_instance = nucleus_api.AllocationApi(nucleus_api.ApiClient(configuration))
# List all Allocation
try:
    api_response = api_instance.get_allocation_all_using_get()
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_allocation_all_using_get: %s\n" % e)
AllocationApi apiInstance = new AllocationApi();
try {
            PageAllocation List = apiInstance.getAllocationAllUsingGet(true, null, null, 1, 10);
            System.out.println(List);
        } catch (ApiException e) {
            System.err.println("Exception when calling getAllocationAllUsingGet");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\AllocationApi(
    new GuzzleHttp\Client(),
    $config);
$ascending = false; // bool | ascending
$filter = null; // string | filter
$order_by = null; // string | order_by
$page = 0; // int | page
$size = 10; // int | size

try {
    $allocationlist = $apiInstance->getAllocationAllUsingGet($ascending, $filter, $order_by, $page, $size);
    print_r($allocationlist);
} catch (Exception $e) {
    echo 'Exception when calling AllocationApi->getAllocationAllUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::AllocationApi.new
opts = {
    ascending: false, # BOOLEAN | ascending
    filter: null, # String | filter
    order_by: null, # String | order_by
    page: 0, # Integer | page
    size: 25 # Integer | size
}

begin
  allocationlist = api_instance.get_allocation_all_using_get(opts)
  p allocationlist
rescue NucleusApi::ApiError => e
  puts "Exception when calling AllocationApi->get_allocation_all_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.AllocationApi();
var opts = {
    'ascending': false, // Boolean | ascending
    // 'filter': "", // String | filter
    'orderBy': "update_date", // String | order_by
    'page': 0, // Number | page
    'size': 25 // Number | size
};

var allocationlist = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.getAllocationAllUsingGet(opts, allocationlist)

Example Response

{
"content": [
    {
        "id": "04907eaa-3f33-49be-a35b-378cdf639fba",
        "category": "Alternative",
        "description": "Venture Fund I, L.P. gives accredited clients the ability to invest in the stock of private companies in the consumer, enterprise, retail, restaurant, and other high growth fields. There is no minimum investment and no management fee or carry charged.",
        "is_active": true,
        "name": "Venture Fund I, L.P.",
        "volatility": 0.054,
        "performance": 0.083,
        "node_map": [],
        "metadata": {}
    },
    {
        "id": "073def0e-6fa0-4e52-badb-6ff2aecbc2b2",
        "category": "Asset Allocation",
        "description": "",
        "is_active": true,
        "name": "Retirement Core 5",
        "volatility": 0.045,
        "performance": 0.078,
        "node_map": [],
        "metadata": {}
    },
    {
        "id": "013380bf-7f17-44c1-93c5-892a7ed3498c",
        "create_date": "2017-02-14T00:00:00.000+0000",
        "update_date": "2017-02-15T09:00:00.000+0000",
        "category": "Social",
        "description": "Dynamically managed diversified socially responsible ETF strategy allocated to U.S. Equities and tax-exempt Fixed Income. The strategy is tailored to investors with a very low risk tolerance, and aims to preserve capital with low turnover.",
        "is_active": true,
        "name": "Tax-Efficient SRI Core 2",
        "volatility": 0.0859,
        "performance": 0.0572,
        "node_map": [
            {
                "node_id": "5aafb611-bae9-481c-9da0-03044af09a7a"
            },
            {
                "node_id": "360baaa9-be8b-4463-bdae-974775cd894f"
            },
            {
                "node_id": "b530b536-4f99-45d3-bdbc-4729992868dc"
            }
        ],
        "metadata": {}
    }
  ],
  "last": true,
  "total_pages": 1,
  "total_elements": 2,
  "first": true,
  "sort": [
    {
        "direction": "DESC",
        "property": "id",
        "ignore_case": false,
        "null_handling": "NATIVE",
        "ascending": false,
        "descending": true
    }
  ],
  "number_of_elements": 2,
  "size": 2,
  "number": 0
}

Get details for all allocations defined for your tenant. Note that the decision tree nodes and metadata information are stored as nested objects within the allocation object.

HTTP REQUEST

GET /allocation

Create an allocation

Example Request

curl -X POST -H "Authorization: Bearer <access_token>" \
    -d '{
            "category": "Social",
            "description": "Dynamically managed diversified socially responsible ETF strategy allocated to U.S. Equities and tax-exempt Fixed Income. The strategy is tailored to investors with a very low risk tolerance, and aims to preserve capital with low turnover.",
            "is_active": true,
            "name": "Tax-Efficient SRI Core 2",
            "volatility": 0.0859,
            "performance": 0.0572,
            "node_map": [
                {
                    "node_id": "5aafb611-bae9-481c-9da0-03044af09a7a"
                },
                {
                    "node_id": "360baaa9-be8b-4463-bdae-974775cd894f"
                },
                {
                    "node_id": "b530b536-4f99-45d3-bdbc-4729992868dc"
                }
            ],
            "metadata": {}
        }' "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/allocation"
api_instance = nucleus_api.AllocationApi(nucleus_api.ApiClient(configuration))
# # # Create a Allocation
allocation = nucleus_api.Allocation(client_id="7507b143-11f3-4861-a353-c0b788cd0f2f", category="AB", name="New One")
try:
    api_response = api_instance.create_allocation_using_post(allocation);
    pprint(api_response)
except ApiException as e:
    print("create_allocation_using_post: %s\n" % e)
AllocationApi apiInstance = new AllocationApi();
        //Create an Allocation

         Allocation allocationCreate = new Allocation();
         allocationCreate.clientId(UUID.fromString("7507b143-11f3-4861-a353-c0b788cd0f2f"));
         allocationCreate.category("ABc");
         allocationCreate.name("One");

        try {
            Allocation result = apiInstance.createAllocationUsingPost(allocationCreate);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling createAllocationUsingPost");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\AllocationApi(
    new GuzzleHttp\Client(),
    $config);
//Create Alloocation
$allocation = new \com\hydrogen\nucleus\Model\Allocation();

try {
    $allocation->setClientId("7507b143-11f3-4861-a353-c0b788cd0f2f");
    $allocation->setCategory("ABC");
    $allocation->setName("New");
    $result = $apiInstance->createAllocationUsingPost($allocation);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->createAllocationUsingPost: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::AllocationApi.new

#Create Allocation
allocation = NucleusApi::Allocation.new

begin
  allocation.client_id = "7507b143-11f3-4861-a353-c0b788cd0f2f"
  allocation.category = "GBP"
  allocation.name = "New"
  result = api_instance.create_allocation_using_post(allocation)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->create_allocation_using_post: #{e}"
end
var apiInstance = new HydrogenNucleusApi.AllocationApi();
//Create Allocation
var allocationnew = new HydrogenNucleusApi.Allocation();
allocationnew.client_id = '7507b143-11f3-4861-a353-c0b788cd0f2f';
allocationnew.category = "New";
allocationnew.name = "ANC";



var newaallocation = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.createAllocationUsingPost(allocationnew, newaallocation)

Example Response

{
    "id": "013380bf-7f17-44c1-93c5-892a7ed3498c",
    "create_date": "2017-02-14T00:00:00.000+0000",
    "category": "Social",
    "description": "Dynamically managed diversified socially responsible ETF strategy allocated to U.S. Equities and tax-exempt Fixed Income. The strategy is tailored to investors with a very low risk tolerance, and aims to preserve capital with low turnover.",
    "is_active": true,
    "name": "Tax-Efficient SRI Core 2",
    "volatility": 0.0859,
    "performance": 0.0572,
    "node_map": [
        {
            "node_id": "5aafb611-bae9-481c-9da0-03044af09a7a"
        },
        {
            "node_id": "360baaa9-be8b-4463-bdae-974775cd894f"
        },
        {
            "node_id": "b530b536-4f99-45d3-bdbc-4729992868dc"
        }
    ],
    "metadata": {}
}

Create a new allocation for your tenant. The endpoint returns the allocation_id used to manage the allocation and to map an account to the allocation.

HTTP REQUEST

POST /allocation

ARGUMENTS

Parameter Type Required Description
name string required Name of the allocation
category string optional Category for the allocation used to group similar allocations
description string optional Description of the allocation
client_id UUID optional If the allocation is to be used by a specific client such as an advisor, the id of the client
benchmark_id UUID optional The id for the benchmark that the allocation should be compared to
inception_date date optional Date that the allocation first was managed
node_map array optional List of nodes in a decision tree that map to the allocation
      node_id UUID required The id of the last node in the branch of a decision tree that maps to the allocation
metadata map optional Custom information associated with the allocation in the format key:value. See Metadata
is_active boolean optional Indicator if this allocation is active. Default is true which indicates it is active
secondary_id string optional Alternate id that can be used to identify the object such as an internal id

PROTON API ARGUMENTS

The following fields may be optionally used in conjunction with the Proton API.

Field Type Required Description
performance double optional Historical performance for the allocation, used as an input for simulations.
volatility double optional Historical volatility for the allocation, used as an input for simulations.

Retrieve an allocation

Example Request

curl -X GET -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/allocation/013380bf-7f17-44c1-93c5-892a7ed3498c"
}
api_instance = nucleus_api.AllocationApi(nucleus_api.ApiClient(configuration))
try:
    api_response = api_instance.get_allocation_using_get("602ff601-cf70-4a57-8ffb-5a7044a301c5")
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_allocation_using_get: %s\n" % e)
AllocationApi apiInstance = new AllocationApi();
        try {
            Allocation responseAllocation = apiInstance.getAllocationUsingGet(UUID.fromString("e759ad98-a1b3-409b-9b48-e267b1f40759"));
            System.out.println(responseAllocation);
        } catch (ApiException e) {
            System.err.println("Exception when calling getAllocationUsingGet");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\AllocationApi(
    new GuzzleHttp\Client(),
    $config);
$allocation_id = "e759ad98-a1b3-409b-9b48-e267b1f40759";

try {
    $allocation = $apiInstance->getAllocationUsingGet($allocation_id);
    print_r($allocation);
} catch (Exception $e) {
    echo 'Exception when calling AllocationApi->getAllocationUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::AllocationApi.new
allocation_id = 'e759ad98-a1b3-409b-9b48-e267b1f40759' # String | UUID allocation_id

begin
  allocation = api_instance.get_allocation_using_get(allocation_id)
  p allocation
rescue NucleusApi::ApiError => e
  puts "Exception when calling AllocationApi->get_allocation_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.AllocationApi();
var allocationId = "2f11c049-0a17-4f75-abe5-681adba12218";
var allocation = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.getAllocationUsingGet("2f11c049-0a17-4f75-abe5-681adba12218", allocation)

Example Response

{
    "id": "013380bf-7f17-44c1-93c5-892a7ed3498c",
    "create_date": "2017-02-14T00:00:00.000+0000",
    "update_date": "2017-02-15T09:00:00.000+0000",
    "category": "Social",
    "description": "Dynamically managed diversified socially responsible ETF strategy allocated to U.S. Equities and tax-exempt Fixed Income. The strategy is tailored to investors with a very low risk tolerance, and aims to preserve capital with low turnover.",
    "is_active": true,
    "name": "Tax-Efficient SRI Core 2",
    "volatility": 0.0859,
    "performance": 0.0572,
    "node_map": [
        {
            "node_id": "5aafb611-bae9-481c-9da0-03044af09a7a"
        },
        {
            "node_id": "360baaa9-be8b-4463-bdae-974775cd894f"
        },
        {
            "node_id": "b530b536-4f99-45d3-bdbc-4729992868dc"
        }
    ],
    "metadata": {}
}

Retrieve the information for an allocation defined by your firm. The allocation_id must be provided. The endpoint returns the allocation_id and the details for the allocation specified.

HTTP REQUEST

GET /allocation/{allocation_id}

Update an allocation

HTTP REQUEST

Example Request

curl -X PUT -H "Authorization: Bearer <access_token>" \
    -d '{
            "category": "Social",
            "description": "Dynamically managed diversified socially responsible ETF strategy allocated to U.S. Equities and tax-exempt Fixed Income. The strategy is tailored to investors with a very low risk tolerance, and aims to preserve capital with low turnover.",
            "is_active": true,
            "name": "Tax-Efficient SRI Core 2",
            "volatility": 0.0859,
            "performance": 0.0572,
            "node_map": [
                {
                    "node_id": "5aafb611-bae9-481c-9da0-03044af09a7a"
                },
                {
                    "node_id": "360baaa9-be8b-4463-bdae-974775cd894f"
                },
                {
                    "node_id": "b530b536-4f99-45d3-bdbc-4729992868dc"
                }
            ],
            "metadata": {}
        }' "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/allocation/013380bf-7f17-44c1-93c5-892a7ed3498c"
}
api_instance = nucleus_api.AllocationApi(nucleus_api.ApiClient(configuration))
# # Update Allocation
allocation_update = {'name': 'New Account'}
allocation_id = 'e1c76a8a-f597-4367-bf7e-e463946a43eb'

try:
    api_response = api_instance.update_allocation_using_put(allocation_update, allocation_id)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling update_allocation_using_put: %s\n" % e)
AllocationApi apiInstance = new AllocationApi();
        // Update Allocation

        Map map = new HashMap();
        map.put("category", "ABD");

        try {
            Allocation response = apiInstance.updateAllocationUsingPut(map, UUID.fromString("9ed9a177-9f90-493b-8042-30da29009037"));
            System.out.println(response);
        } catch (ApiException e) {
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\AllocationApi(
    new GuzzleHttp\Client(),
    $config);
//Update Allocation
$allocation_update = new stdClass();
$allocation_id = "6af6bfea-f33f-400c-a468-d164d91492d0";

try {
    $allocation_update->name = "ANS";
    $result = $apiInstance->updateAllocationUsingPut($allocation_update, $allocation_id);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->updateAllocationUsingPut: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::AllocationApi.new

#Update Allocation
allocation_update = {"category" => 'ABC'};
allocation_id = '6af6bfea-f33f-400c-a468-d164d91492d0'
begin
  result = api_instance.update_allocation_using_put(allocation_update, allocation_id)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->update_allocation_using_put: #{e}"
end
var apiInstance = new HydrogenNucleusApi.AllocationApi();
//Update Allocation
var apiInstance = new HydrogenNucleusApi.AllocationApi();
var callback = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
var allocationupdate = new HydrogenNucleusApi.Allocation();
var allocationid = "c2812587-3211-4115-ba27-32e8f9c483b6";

allocationupdate.category = "NEW";
apiInstance.updateAllocationUsingPut(allocationupdate, allocationid, callback)

Example Response

{
    "id": "013380bf-7f17-44c1-93c5-892a7ed3498c",
    "create_date": "2017-02-14T00:00:00.000+0000",
    "update_date": "2017-02-15T09:00:00.000+0000",
    "category": "Social",
    "description": "Dynamically managed diversified socially responsible ETF strategy allocated to U.S. Equities and tax-exempt Fixed Income. The strategy is tailored to investors with a very low risk tolerance, and aims to preserve capital with low turnover.",
    "is_active": true,
    "name": "Tax-Efficient SRI Core 2",
    "volatility": 0.0859,
    "performance": 0.0572,
    "node_map": [
        {
            "node_id": "5aafb611-bae9-481c-9da0-03044af09a7a"
        },
        {
            "node_id": "360baaa9-be8b-4463-bdae-974775cd894f"
        },
        {
            "node_id": "b530b536-4f99-45d3-bdbc-4729992868dc"
        }
    ],
    "metadata": {}
}

Update an allocation defined by your firm. The allocation_id must be provided. To obtain the appropriate allocation_id, use the GET /allocation endpoint to view all of the allocations defined by your firm and their current information. The details to be updated must also be provided. The endpoint returns the allocation_id and the details for the allocation. If you wish to have an allocation no longer be available without permanently deleting it, use this endpoint to mark the is_active field as false.

PUT /allocation/{allocation_id}

Delete an allocation

Example Request

curl -X DELETE -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/allocation/013380bf-7f17-44c1-93c5-892a7ed3498c"
}
api_instance = nucleus_api.AllocationApi(nucleus_api.ApiClient(configuration))
# Delete a Allocation
allocation_id = '79f1b6e0-fd35-41c5-bff4-f981c3714d48'
try:
    api_instance.delete_allocation_using_delete(allocation_id)
except ApiException as e:
    print("Exception when delete_allocation_using_delete: %s\n" % e)
AllocationApi apiInstance = new AllocationApi();
        // Delete Allocation
        try {
            Allocation deleteresponse = apiInstance.deleteAllocationUsingDelete(UUID.fromString("79f1b6e0-fd35-41c5-bff4-f981c3714d48"));
            System.out.println(deleteresponse);
        } catch (ApiException e) {
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\AllocationApi(
    new GuzzleHttp\Client(),
    $config);
//Delete Allocation
$allocation_did = "e68cbe12-1058-4566-86dd-cb14bec023de"; // string | UUID account_id

try {
    $apiInstance->deleteAllocationUsingDelete($allocation_did);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->deleteAllocationUsingDelete: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::AllocationApi.new
#Delete Allocation
allocation1_id = 'bdb7ba59-e46f-41ec-9ac0-f47aebbaa7a9'
begin
  result = api_instance.delete_allocation_using_delete(allocation1_id)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->delete_allocation_using_delete: #{e}"
end
var apiInstance = new HydrogenNucleusApi.AllocationApi();
// // // //Delete a Allocation
var allocationd = "1170dc88-d507-41d7-8791-67ebe76708fa";


var deleteallocation = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully.');
    }
};
apiInstance.deleteAllocationUsingDelete(allocationd, deleteallocation)

Response (204 No Content)

Permanently delete an allocation defined by your firm. The allocation_id must be provided. To obtain the appropriate allocation_id, use the GET /allocation endpoint to view all of the allocations defined by your firm. This deletes the allocation_id and the allocation record. If you wish to have an allocation no longer be available without permanently deleting it, use the PUT /allocation/{allocation_id} endpoint to mark the is_active field as false.

HTTP REQUEST

DELETE /allocation/{allocation_id}

Allocation Composition

Allocation Composition is used to assign models to an allocation with specific weights and track the composition over time.

Field Type Description
id UUID The id of the allocation composition record
allocation_id UUID The id of the allocation for which you are adding a composition record
model_id UUID The id of the model that is assigned to the allocation
current_weight double The current weight of the model as a percentage of the allocation’s total value; ex. 20 representing 20%. The current weights of all the models must add up to 100. If the model is the only one, enter 100
strategic_weight double The strategic weight of the model as a percentage of the allocation’s total value; ex. 20 representing 20%. The strategic weights of all the models must add up to 100. If the model is the only one, enter 100
date date The date for this allocation composition record
metadata map Custom information associated with the entity in the format key:value
See Metadata

PROTON API

The following fields may be optionally used in conjunction with the Proton API.

Field Type Description
core boolean Indicator if the model_id is a core model for core-satellite investing. Defaults to false which means it is not a core model

List all allocation compositions

Example Request

curl -X GET -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/allocation_composition"
}
api_instance = nucleus_api.AllocationApi(nucleus_api.ApiClient(configuration))
try:
    api_response = api_instance.get_allocation_composition_all_using_get()
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_allocation_composition_all_using_get: %s\n" % e)
AllocationApi apiInstance = new AllocationApi();
        try {
            PageAllocationComposition List = apiInstance.getAllocationCompositionAllUsingGet(true, null, null, 1, 10);
            System.out.println(List);
        } catch (ApiException e) {
            System.err.println("Exception when calling getAllocationCompositionAllUsingGet");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\AllocationApi(
    new GuzzleHttp\Client(),
    $config);
$ascending = false; // bool | ascending
$filter = null; // string | filter
$order_by = null; // string | order_by
$page = 0; // int | page
$size = 10; // int | size

try {
    $allocationcompositionlist = $apiInstance->getAllocationCompositionAllUsingGet($ascending, $filter, $order_by, $page, $size);
    print_r($allocationcompositionlist);
} catch (Exception $e) {
    echo 'Exception when calling AllocationApi->getAllocationCompositionAllUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::AllocationApi.new
opts = {
    ascending: false, # BOOLEAN | ascending
    filter: null, # String | filter
    order_by: null, # String | order_by
    page: 0, # Integer | page
    size: 25 # Integer | size
}

begin
  compositionlist = api_instance.get_allocation_composition_all_using_get(opts)
  p compositionlist
rescue NucleusApi::ApiError => e
  puts "Exception when calling AllocationApi->get_allocation_composition_all_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.AllocationApi();
var opts = {
    'ascending': false, // Boolean | ascending
    // 'filter': "", // String | filter
    'orderBy': "update_date", // String | order_by
    'page': 0, // Number | page
    'size': 25 // Number | size
};

var allocationcompositionlist = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.getAllocationCompositionAllUsingGet(opts, allocationcompositionlist)

Example Response

{
    "content": [
        {
            "id": "2b74355b-00eb-460b-a504-822248e50621",
            "create_date": "2018-04-10T20:43:25.000+0000",
            "update_date": "2018-04-10T20:43:25.000+0000",
            "core": false,
            "current_weight": 100,
            "date": "2018-04-10",
            "strategic_weight": 100,
            "model_id": "dbebf51f-d325-4cdd-b043-78958e29bdce",
            "allocation_id": "9d076a5b-c9eb-4637-ab56-296165be3edc",
            "metadata": {}
        },
        {
            "id": "d05b26cc-367d-4c90-9365-cd89af237bbf",
            "create_date": "2018-04-05T20:42:19.000+0000",
            "update_date": "2018-04-05T20:42:19.000+0000",
            "core": false,
            "current_weight": 100,
            "date": "2018-04-05",
            "strategic_weight": 100,
            "model_id": "dbebf51f-d325-4cdd-b043-78958e29bdce",
            "allocation_id": "30708526-cf56-4560-8bd9-19e00417ec4b",
            "metadata": {}
        },
        {
            "id": "48745b11-ae08-4f96-8889-0be02a96bb5e",
            "create_date": "2018-04-05T20:32:25.000+0000",
            "update_date": "2018-04-05T20:32:25.000+0000",
            "core": false,
            "current_weight": 100,
            "date": "2018-04-05",
            "strategic_weight": 100,
            "model_id": "39c40045-df4b-4ebb-8df8-257dfe48c254",
            "allocation_id": "a31fc863-2a9a-48de-86f2-eb376370a64e",
            "metadata": {}
        }
    ],
    "last": false,
    "total_pages": 1,
    "total_elements": 3,
    "sort": [
        {
            "direction": "DESC",
            "property": "updateDate",
            "ignore_case": false,
            "null_handling": "NATIVE",
            "descending": true,
            "ascending": false
        }
    ],
    "first": true,
    "number_of_elements": 3,
    "size": 25,
    "number": 0
}

Get the allocation composition for all allocations. To view the composition of a specific allocation only, you may filter by the allocation_id.

HTTP REQUEST

GET /allocation_composition

Create an allocation composition

Example Request

curl -X POST -H "Authorization: Bearer <access_token>" \
    -d '{
            "core": false,
            "current_weight": 100,
            "date": "2018-04-10",
            "strategic_weight": 100,
            "model_id": "dbebf51f-d325-4cdd-b043-78958e29bdce",
            "allocation_id": "9d076a5b-c9eb-4637-ab56-296165be3edc"
        }' "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/allocation_composition"
api_instance = nucleus_api.AllocationApi(nucleus_api.ApiClient(configuration))
# Create a AllocationComposition
allocation_Composition = nucleus_api.AllocationComposition(current_weight="20.0", _date="2020-10-10", strategic_weight="10.0", model_id="758cb536-86f5-4f15-8a76-793fdda39984", allocation_id="d5529e8d-03d6-452e-9372-f3af8275dab5")
try:
    api_response = api_instance.create_allocation_composition_using_post(allocation_Composition)
    pprint(api_response)
except ApiException as e:
    print("create_allocation_composition_using_post: %s\n" % e)
AllocationApi apiInstance = new AllocationApi();
        //Create Allocation Composition
        AllocationComposition allocComposition = new AllocationComposition();
        allocComposition.setCurrentWeight(20.00);
        allocComposition.setDate(date2);
        allocComposition.setStrategicWeight(10.00);
        allocComposition.setModelId(UUID.fromString("758cb536-86f5-4f15-8a76-793fdda39984"));
        allocComposition.setAllocationId(UUID.fromString("d5529e8d-03d6-452e-9372-f3af8275dab5"));

        try {
            AllocationComposition response = apiInstance.createAllocationCompositionUsingPost(allocComposition);
            System.out.println(response);
        } catch (ApiException e) {
            System.err.println("Exception when calling createAllocationCompositionUsingPost");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\AllocationApi(
    new GuzzleHttp\Client(),
    $config);
//Create Allocation Composition
$allocation_composition = new \com\hydrogen\nucleus\Model\AllocationComposition();

try {
    $allocation_composition->setModelId("758cb536-86f5-4f15-8a76-793fdda39984");
    $allocation_composition->setAllocationId("d5529e8d-03d6-452e-9372-f3af8275dab5");
    $allocation_composition->setCurrentWeight("20");
    $allocation_composition->setDate("2020-10-10");
    $allocation_composition->setStrategicWeight("30");
    $result = $apiInstance->createAllocationCompositionUsingPost($allocation_composition);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->createAllocationCompositionUsingPost: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::AllocationApi.new
#Create Allocation Composition
allocation_composition = NucleusApi::AllocationComposition.new

begin
  allocation_composition.model_id = "758cb536-86f5-4f15-8a76-793fdda39984"
  allocation_composition.allocation_id = "d5529e8d-03d6-452e-9372-f3af8275dab5"
  allocation_composition.current_weight = "65"
  allocation_composition.strategic_weight = "76"
  allocation_composition.date = "2020-10-10"
  result = api_instance.create_allocation_composition_using_pos(allocation_composition)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->create_allocation_composition_using_pos: #{e}"
end
var apiInstance = new HydrogenNucleusApi.AllocationApi();
//Create Allocation Composition
var allocationcompositionnew = new HydrogenNucleusApi.AllocationComposition();
allocationcompositionnew.allocation_id = 'd5529e8d-03d6-452e-9372-f3af8275dab5';
allocationcompositionnew.model_id = '758cb536-86f5-4f15-8a76-793fdda39984';
allocationcompositionnew.current_weight = "30";
allocationcompositionnew.strategic_weight = "60";
allocationcompositionnew.date = "2020-11-10";


var newaallocationcomposition = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.createAllocationCompositionUsingPost(allocationcompositionnew, newaallocationcomposition)

Example Response

{
    "id": "2b74355b-00eb-460b-a504-822248e50621",
    "create_date": "2018-04-10T20:43:25.000+0000",
    "core": false,
    "current_weight": 100,
    "date": "2018-04-10",
    "strategic_weight": 100,
    "model_id": "dbebf51f-d325-4cdd-b043-78958e29bdce",
    "allocation_id": "9d076a5b-c9eb-4637-ab56-296165be3edc",
    "metadata": {}
}

Create a new allocation composition record for an allocation. An allocation will be composed of models and weights which you can store over time. The endpoint returns the allocation_composition_id used to manage the allocation composition record.

HTTP REQUEST

POST /allocation_composition

ARGUMENTS

Parameter Type Required Description
allocation_id UUID required The id of the allocation for which you are adding a composition record
model_id UUID required The id of the model that is assigned to the allocation
current_weight double required The current weight of the model as a percentage of the allocation’s total value; ex. 20 representing 20%. The current weights of all the models must add up to 100. If the model is the only one, enter 100
strategic_weight double required The strategic weight of the model as a percentage of the allocation’s total value; ex. 20 representing 20%. The strategic weights of all the models must add up to 100. If the model is the only one, enter 100
date date required The date for this allocation composition record
metadata map optional Custom information associated with the entity in the format key:value
See Metadata

PROTON API ARGUMENTS

The following fields may be optionally used in conjunction with the Proton API.

Parameter Type Required Description
core boolean optional Indicator if the model_id is a core model for core-satellite investing. Defaults to false which means it is not a core model

Retrieve an allocation composition

Example Request

curl -X GET -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/allocation_composition/2b74355b-00eb-460b-a504-822248e50621"
}
api_instance = nucleus_api.AllocationApi(nucleus_api.ApiClient(configuration))
try:
    api_response = api_instance.get_allocation_composition_using_get("3ddc7246-8d97-4e2b-ab9e-850fcce3a548")
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_allocation_composition_using_get: %s\n" % e)
AllocationApi apiInstance = new AllocationApi();
        try {
            AllocationComposition responseComposition = apiInstance.getAllocationCompositionUsingGet(UUID.fromString("73536bbc-9a32-48ff-8a01-163e85a270ad"));
            System.out.println(responseComposition);
        } catch (ApiException e) {
            System.err.println("Exception when calling getAllocationCompositionUsingGet");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\AllocationApi(
    new GuzzleHttp\Client(),
    $config);
$allocation_composition_id = "73536bbc-9a32-48ff-8a01-163e85a270ad"; // string | UUID allocation_composition_id

try {
    $allocationcomposition = $apiInstance->getAllocationCompositionUsingGet($allocation_composition_id);
    print_r($allocationcomposition);
} catch (Exception $e) {
    echo 'Exception when calling AllocationApi->getAllocationCompositionUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::AllocationApi.new
allocation_composition_id = '73536bbc-9a32-48ff-8a01-163e85a270ad' # String | UUID allocation_composition_id


begin
  composition = api_instance.get_allocation_composition_using_get(allocation_composition_id)
  p composition
rescue NucleusApi::ApiError => e
  puts "Exception when calling AllocationApi->get_allocation_composition_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.AllocationApi();
var allocationcompId = "3ddc7246-8d97-4e2b-ab9e-850fcce3a548";


var allocationcomp = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.getAllocationCompositionUsingGet("3ddc7246-8d97-4e2b-ab9e-850fcce3a548", allocationcomp)

Example Response

{
    "id": "2b74355b-00eb-460b-a504-822248e50621",
    "create_date": "2018-04-10T20:43:25.000+0000",
    "update_date": "2018-04-10T20:43:25.000+0000",
    "core": false,
    "current_weight": 100,
    "date": "2018-04-10",
    "strategic_weight": 100,
    "model_id": "dbebf51f-d325-4cdd-b043-78958e29bdce",
    "allocation_id": "9d076a5b-c9eb-4637-ab56-296165be3edc",
    "metadata": {}
}

Retrieve the information of an allocation composition record for an allocation. The allocation_composition_id must be provided. To obtain the appropriate allocation_composition_id for an allocation, use the GET /allocation_composition endpoint and filter by the allocation_id.

HTTP REQUEST

GET /allocation_composition/{allocation_composition_id}

Update an allocation composition

Example Request

curl -X PUT -H "Authorization: Bearer <access_token>" \
    -d '{
            "core": false,
            "current_weight": 100,
            "date": "2018-04-10",
            "strategic_weight": 100,
            "model_id": "dbebf51f-d325-4cdd-b043-78958e29bdce",
            "allocation_id": "9d076a5b-c9eb-4637-ab56-296165be3edc"
        }' "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/allocation_composition/2b74355b-00eb-460b-a504-822248e50621"
api_instance = nucleus_api.AllocationApi(nucleus_api.ApiClient(configuration))
#Update AllocationComposition
allocationComposition_update = {'current_weight': '30.0'}
allocationComposition_id = '29fbce13-fb3e-41ec-819a-b85fd4269ef2'

try:
    api_response = api_instance.update_allocation_composition_using_put(allocationComposition_update, allocationComposition_id)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling update_allocation_composition_using_put: %s\n" % e)
AllocationApi apiInstance = new AllocationApi();
        // Update Allocation Composition

        Map map2 = new HashMap();
        map.put("current_weight", 0.056);

        try {
            AllocationComposition response = apiInstance.updateAllocationCompositionUsingPut(map2, UUID.fromString("25147e82-26a6-4948-a88d-23ac33a7ff77"));
            System.out.println(response);
        } catch (ApiException e) {
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\AllocationApi(
    new GuzzleHttp\Client(),
    $config);
//Update Allocation Composition
$allocation_composition_update = new stdClass();
$allocation_composition_id = "5fbfcc3a-2820-4a7e-b7d6-a21c15365ce3";

try {
    $allocation_composition_update->current_weight = "20";
    $result = $apiInstance->updateAllocationCompositionUsingPut($allocation_composition_update, $allocation_composition_id);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->updateAllocationCompositionUsingPut: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::AllocationApi.new
#Update Allocation Composition
allocation_composition_update = {"date" => '2020-10-10'}
allocation_composition_id = '5fbfcc3a-2820-4a7e-b7d6-a21c15365ce3'
begin
  result = api_instance.update_allocation_composition_using_put(allocation_composition_update, allocation_composition_id)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->update_allocation_composition_using_put: #{e}"
end
var apiInstance = new HydrogenNucleusApi.AllocationApi();
//Update Allocation Composition
var apiInstance = new HydrogenNucleusApi.AllocationApi();
var callback = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
var allocationcompositionupdate = new HydrogenNucleusApi.AllocationComposition();
var allocationcompositionid = "c2812587-3211-4115-ba27-32e8f9c483b6";

allocationcompositionupdate.core = "NEW";
apiInstance.updateAllocationCompositionUsingPut(allocationcompositionupdate, allocationcompositionid, callback)

Example Response

{
    "id": "2b74355b-00eb-460b-a504-822248e50621",
    "create_date": "2018-04-10T20:43:25.000+0000",
    "update_date": "2018-04-10T20:43:25.000+0000",
    "core": false,
    "current_weight": 100,
    "date": "2018-04-10",
    "strategic_weight": 100,
    "model_id": "dbebf51f-d325-4cdd-b043-78958e29bdce",
    "allocation_id": "9d076a5b-c9eb-4637-ab56-296165be3edc",
    "metadata": {}
}

Update the information of an allocation composition record for an allocation. The allocation_composition_id must be provided. To obtain the appropriate allocation_composition_id for an allocation, use the GET /allocation_composition endpoint and filter by the allocation_id. The details to be updated must also be provided. The endpoint returns the allocation_composition_id and the details for the updated allocation composition record.

HTTP REQUEST

PUT /allocation_composition/{allocation_composition_id}

Delete an allocation composition

Example Request

curl -X DELETE -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/allocation_composition/2b74355b-00eb-460b-a504-822248e50621"
}
api_instance = nucleus_api.AllocationApi(nucleus_api.ApiClient(configuration))
# #  # Delete a AllocationComposition
allocationcomposition_id = '849a0c22-e35b-4524-b10f-dc78a1691ab1'
try:
    api_instance.delete_allocation_composition_using_delete(allocationcomposition_id)
except ApiException as e:
    print("Exception when delete_allocation_composition_using_delete: %s\n" % e)
AllocationApi apiInstance = new AllocationApi();
        // Delete Allocation Composition
        try {
            Allocation deleteresponse = apiInstance.deleteAllocationCompositionUsingDelete(UUID.fromString("ff657ed1-d447-4ed2-9ecc-be7915d9a969"));
            System.out.println(deleteresponse);
        } catch (ApiException e) {
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\AllocationApi(
    new GuzzleHttp\Client(),
    $config);
//Delete Allocation Composition
$allocation_composition_did = "849a0c22-e35b-4524-b10f-dc78a1691ab1"; // string | UUID account_id

try {
    $apiInstance->deleteAllocationCompositionUsingDelete($allocation_composition_did);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->deleteAllocationCompositionUsingDelete: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::AllocationApi.new
#Delete Allocation composition
allocation_composition1_id = '849a0c22-e35b-4524-b10f-dc78a1691ab1'
begin
  result = api_instance.delete_allocation_composition_using_delete(allocation_composition1_id)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->delete_allocation_composition_using_delete: #{e}"
end
var apiInstance = new HydrogenNucleusApi.AllocationApi();
// //Delete a AllocationComposition
var allocationcompd = "25147e82-26a6-4948-a88d-23ac33a7ff77";


var deleteallocationcomp = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully.');
    }
};
apiInstance.deleteAllocationCompositionUsingDelete(allocationcompd, deleteallocationcomp)

Response (204 No Content)

Permanently delete an allocation composition record for an allocation. The allocation_composition_id must be provided. To obtain the appropriate allocation_composition_id, use the GET /allocation_composition endpoint to view all of the allocation composition records for all allocations. This deletes the allocation_composition_id and the allocation composition record from the allocation.

HTTP REQUEST

DELETE /allocation/{allocation_composition_id}

Allocation Activity

List all allocation asset sizes

Example Request

curl -X GET -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/allocation/8d97c85c-8cbf-4ac1-a5df-f9d2bb6a77e0/asset_size"
}
api_instance = nucleus_api.AllocationApi(nucleus_api.ApiClient(configuration))
try:
    api_response = api_instance.get_allocation_all_asset_size_all_using_get("3ddc7246-8d97-4e2b-ab9e-850fcce3a548")
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_assetsize_using_get: %s\n" % e)
AllocationApi apiInstance = new AllocationApi();
        try {
            Object allocatioassetsize = apiInstance.getAllocationAllAssetSizeAllUsingGet(UUID.fromString("e759ad98-a1b3-409b-9b48-e267b1f40759"), date2, true, true, null, date1 );
            System.out.println(allocatioassetsize);
        } catch (ApiException e) {
            System.err.println("Exception when calling getAllocationAllAssetSizeAllUsingGet");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\AllocationApi(
    new GuzzleHttp\Client(),
    $config);
$allocation_id = "e759ad98-a1b3-409b-9b48-e267b1f40759";
$end_date = new \DateTime("2020-09-10"); // \DateTime | end date
$get_latest = true; // bool | get_latest
$is_current_weight = true; // bool | is_current_weight
$sort_type = null; // string | D (Daily), Q (quarterly), M (Monthly), Y (Annually)
$start_date = new \DateTime("2018-07-25"); // \DateTime | start date

try {
    $allocationassetsize = $apiInstance->getAllocationAllAssetSizeAllUsingGet($allocation_id, $end_date, $get_latest, $is_current_weight, $sort_type, $start_date);
    print_r($allocationassetsize);
} catch (Exception $e) {
    echo 'Exception when calling AllocationApi->getAllocationAllAssetSizeAllUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::AllocationApi.new
allocation_id = 'e759ad98-a1b3-409b-9b48-e267b1f40759' # String | UUID allocation_id

opts = {
    end_date: Date.parse('2013-10-20'), # Date | end date
    get_latest: true, # BOOLEAN | get_latest
    is_current_weight: true, # BOOLEAN | is_current_weight
    sort_type: null, # String | D (Daily), Q (quarterly), M (Monthly), Y (Annually)
    start_date: Date.parse('2013-10-20') # Date | start date
}

begin
  allocationasset = api_instance.get_allocation_all_asset_size_all_using_get(allocation_id, opts)
  p allocationasset
rescue NucleusApi::ApiError => e
  puts "Exception when calling AllocationApi->get_allocation_all_asset_size_all_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.AllocationApi();
var opts = {
    'endDate': new Date("2013-10-20"), // Date | end date
    'getLatest': true, // Boolean | get_latest
    'isCurrentWeight': true, // Boolean | is_current_weight
    'sortType': null, // String | D (Daily), Q (quarterly), M (Monthly), Y (Annually)
    'startDate': new Date("2013-10-20") // Date | start date
};

var allocationassetsize = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.getAllocationAllAssetSizeAllUsingGet(allocationId, opts, allocationassetsize)

Example Response

[
    {
        "date": "2016-01-04",
        "value": 1
    },
    {
        "date": "2016-01-05",
        "value": 1.1
    }
]

Get a list of asset sizes by date for a specific allocation. Asset size records are created at a model level, and aggregated to yield the allocation asset size(s). Allocation asset size represents the “growth of a dollar” rather than a monetary amount. The unique allocation_id must be provided. To obtain the appropriate allocation_id, use the GET /allocation endpoint to view all allocations defined for your tenant. The endpoint returns a date, an amount value, and the value added since the last asset size date, usually via deposit. Additional parameters available to narrow down what is returned include date range, only obtaining the latest record, and sorting by different units of time (eg. annually, quarterly, monthly, daily).

HTTP REQUEST

GET /allocation/{allocation_id}/asset_size

ARGUMENTS

Parameter Type Required Description
get_latest boolean optional Retrieve only the latest asset size. Defaults to false if not set
sort_type string optional Sort the asset sizes by D Daily, M Monthly, Q Quarterly, Y Yearly. Defaults to D Daily if not set. Must be capital letters
start_date date optional Start date for the data. Defaults to the first date if not set
end_date date optional End date for the data. Defaults to the last date if not set
is_current_weight boolean optional Retrieve allocation asset sizes using the current weight for aggregation. Defaults to true if not set

RESPONSE

Field Type Description
date date Date for this asset size record
value double “Growth of a dollar” within the allocation on the particular date

List all allocation holdings

Example Request

curl -X GET -H "Authorization: Bearer <access_token>" \
     "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/allocation/8d97c85c-8cbf-4ac1-a5df-f9d2bb6a77e0/holding"
}
api_instance = nucleus_api.AllocationApi(nucleus_api.ApiClient(configuration))
try:
    api_response = api_instance.get_allocation_all_holding_all_using_get("d5529e8d-03d6-452e-9372-f3af8275dab5")
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_all_holdings_using_get: %s\n" % e)
AllocationApi apiInstance = new AllocationApi();
        try {
            Object allocationHolding = apiInstance.getAllocationAllHoldingAllUsingGet(UUID.fromString("e759ad98-a1b3-409b-9b48-e267b1f40759"), date2, date1);
            System.out.println(allocationHolding);
        } catch (ApiException e) {
            System.err.println("Exception when calling getAllocationAllHoldingAllUsingGet");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\AllocationApi(
    new GuzzleHttp\Client(),
    $config);
$allocation_id = "e759ad98-a1b3-409b-9b48-e267b1f40759"; // string | UUID allocation_id
$end_date = new \DateTime("2020-09-10"); // \DateTime | end date
$start_date = new \DateTime("2018-07-25"); // \DateTime | start date

try {
    $allocationholding = $apiInstance->getAllocationAllHoldingAllUsingGet($allocation_id, $end_date, $start_date);
    print_r($allocationholding);
} catch (Exception $e) {
    echo 'Exception when calling AllocationApi->getAllocationAllHoldingAllUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::AllocationApi.new
allocation_id = 'e759ad98-a1b3-409b-9b48-e267b1f40759' # String | UUID allocation_id

opts = {
    end_date: Date.parse('2013-10-20'), # Date | end date
    start_date: Date.parse('2013-10-20') # Date | start date
}

begin
  holding = api_instance.get_allocation_all_holding_all_using_get(allocation_id, opts)
  p holding
rescue NucleusApi::ApiError => e
  puts "Exception when calling AllocationApi->get_allocation_all_holding_all_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.AllocationApi();
var opts = {
    'endDate': "2018-07-25",
    'startDate': "2020-09-10",
};

var allocationholding = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.getAllocationAllHoldingAllUsingGet(allocationId, opts, allocationholding)

Example Response

[
    {
        "current_weight": 15,
        "date": "2018-02-02",
        "strategic_weight": 15,
        "security_id": "b28ca897-6c2a-4e8f-b33f-d143a5e9a988"
    },
    {
        "current_weight": 35,
        "date": "2018-02-02",
        "strategic_weight": 35,
        "security_id": "a3098d24-33bb-4eb9-95dc-f7d091371d00"
    },
    {
        "current_weight": 2,
        "date": "2018-02-02",
        "strategic_weight": 2,
        "security_id": "dd561cf3-540a-4506-bdf9-52b7c86661f6"
    },
    {
        "current_weight": 6,
        "date": "2018-02-02",
        "strategic_weight": 6,
        "security_id": "f617534c-a2bb-49f6-a5c5-6ebcbaa3b274"
    },
    {
        "current_weight": 15,
        "date": "2018-02-02",
        "strategic_weight": 15,
        "security_id": "df82bd37-d390-41b9-9bef-6e599c58a316"
    },
    {
        "current_weight": 27,
        "date": "2018-02-02",
        "strategic_weight": 27,
        "security_id": "46521baf-6037-4595-bf20-66ae9f2703e7"
    }
]

Get the information for all securities assigned to a specific allocation. This represents the securities an allocation should hold, according to the models associated with said allocation. Respective security weights are listed as a percentage of each model’s total holdings. Holding records are created at a model level and aggregated to show the holdings of the allocation. The unique allocation_id must be provided. To obtain the appropriate allocation_id, use the GET /allocation endpoint to view all allocations defined for your tenant. The endpoint returns a list of security_ids and the details for all holding records. Additional parameters available to narrow down what is returned include a date range.

HTTP REQUEST

GET /allocation/{allocation_id}/holding

ARGUMENTS

Parameter Type Required Description
start_date date optional Start date for the data. Defaults to the first date if not set
end_date date optional End date for the data. Defaults to the last date if not set

RESPONSE

Field Type Description
security_id UUID The id for the security included in the holding record
current_weight double Current weight of the security as a percentage of the model’s total monetary value; ex. 20 representing 20%
strategic_weight double Strategic weight of the security as a percentage of the model’s total monetary value; ex. 20 representing 20%
date date Date of the holding record

List all allocation transactions

Example Request

curl -X GET -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/allocation/8d97c85c-8cbf-4ac1-a5df-f9d2bb6a77e0/transaction"
}
api_instance = nucleus_api.AllocationApi(nucleus_api.ApiClient(configuration))
try:
    api_response = api_instance.get_allocation_all_transaction_all_using_get("d5529e8d-03d6-452e-9372-f3af8275dab5")
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_all_transactions_using_get: %s\n" % e)
AllocationApi apiInstance = new AllocationApi();
        try {
            Object allocationtransaction = apiInstance.getAllocationAllTransactionAllUsingGet(UUID.fromString("e759ad98-a1b3-409b-9b48-e267b1f40759"), true, date2, null, 0, 10, date1);
            System.out.println(allocationtransaction);
        } catch (ApiException e) {
            System.err.println("Exception when calling getAllocationAllTransactionAllUsingGet");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\AllocationApi(
    new GuzzleHttp\Client(),
    $config);
$allocation_id = "e759ad98-a1b3-409b-9b48-e267b1f40759"; // string | UUID allocation_id
$ascending = false; // bool | ascending
$end_date = new \DateTime("2020-09-10"); // \DateTime | end date
$order_by = null; // string | order_by
$page = 0; // int | page
$size = 10; // int | size
$start_date = new \DateTime("2018-07-25"); // \DateTime | start date

try {
    $allocationtransaction = $apiInstance->getAllocationAllTransactionAllUsingGet($allocation_id, $ascending, $end_date, $order_by, $page, $size, $start_date);
    print_r($allocationtransaction);
} catch (Exception $e) {
    echo 'Exception when calling AllocationApi->getAllocationAllTransactionAllUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::AllocationApi.new
opts = {
    ascending: false, # BOOLEAN | ascending
    end_date: Date.parse('2013-10-20'), # Date | end date
    order_by: null, # String | order_by
    page: 0, # Integer | page
    size: 25, # Integer | size
    start_date: Date.parse('2013-10-20') # Date | start date
}

begin
  transaction = api_instance.get_allocation_all_transaction_all_using_get(allocation_id, opts)
  p transaction
rescue NucleusApi::ApiError => e
  puts "Exception when calling AllocationApi->get_allocation_all_transaction_all_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.AllocationApi();
var opts = {
    'endDate': "2018-07-25",
    'startDate': "2020-09-10",
    'ascending': false, // Boolean | ascending
    // 'filter': "", // String | filter
    'orderBy': "update_date", // String | order_by
    'page': 0, // Number | page
    'size': 25 // Number | size

};

var allocationtransaction = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.getAllocationAllTransactionAllUsingGet(allocationId, opts, allocationtransaction)

Example Response

{
    "content": [
        {
            "id": "8d97c85c-8cbf-4ac1-a5df-f9d2bb6a77e0",
            "create_date": "2018-01-25T04:30:25",
            "update_date": "2018-01-26T09:00:00",
            "shares": 150,
            "price": 23.45,
            "date": "2018-01-25",
            "model_id": "b663c459-4bda-4c57-82ea-09d41817fa",
            "security_id": "9c75e982-5554-4725-b23e-43ff53876df6",
            "transaction_code_id": "f5397b-7d22-433f-b01e-8202184a6386",
        }
    ],
    "total_pages": 1,
    "total_elements": 1,
    "last": true,
    "sort": [
      {
        "direction": "DESC",
        "property": "id",
        "ignore_case": false,
        "null_handling": "NATIVE",
        "descending": true,
        "ascending": false
      }
    ],
    "first": true,
    "number_of_elements": 1,
    "size": 25,
    "number": 0
  }

Get the information for all transactions made under an allocation to achieve the composition of the allocation. Transactions represent buy or sell orders for securities. Transaction records are created at a model level and all transactions for each model below the allocation are returned to show the allocation’s transaction activity. Must provide the unique allocation_id. To obtain the appropriate allocation_id, use the GET /allocation endpoint to view all allocations defined for your tenant. The endpoint returns a list of transaction_ids and details for each transaction. See the Order section for more information. Additional parameters available to narrow down what is returned include a date range or using the current weight for aggregation.

HTTP REQUEST

GET /allocation/{allocation_id}/transaction

ARGUMENTS

Parameter Type Required Description
start_date date optional Start date for the data. Defaults to the first date if not set
end_date date optional End date for the data. Defaults to the last date if not set

RESPONSE

Field Type Description
id UUID The id of the allocation transaction record
shares double Number of shares of the security purchased as part of the transaction
price double Security price at which the shares were purchased as part of the transaction
date date Date of the allocation transaction
model_id UUID The id of the model that the allocation transaction record falls under
security_id UUID The id of the security included in the allocation transaction
transaction_code_id integer The id referring to the transaction codes defined by your firm
secondary_id string Alternate id that can be used to identify the object such as an internal id
create_date timestamp Timestamp for the date and time that the record was created
update_date timestamp Timestamp for the date and time that the record was last updated

Get aggregate allocation data

Displays a breakdown of an allocation such as allocation composition, model holding, and security details. This view is useful when constructing drilldowns of allocations/models for clients.

Field Type Description
allocation_id UUID The id of the allocation
allocation_name string Name of the allocation
allocation_category string Category of the allocation
allocation_description string Description of the allocation
allocation_secondary_id UUID The secondary_id of the allocation
allocation_compositions array Array of allocation compositions
      allocation_composition_id UUID The id of the allocation composition
      allocation_composition_date date The date for this allocation composition record
      model_id UUID The id of the model that is assigned to the allocation
      model_name string Name of the model
      model_category string Category of the model such as “Equities”
      model_description string Description of the model
      model_strategic_weight double Strategic weight of the model as a percentage of the allocation’s total value; ex. 20 representing 20%
      model_current_weight double Current weight of the model as a percentage of the allocation’s total value; ex. 20 representing 20%
      model_currency_code string(3) Currency code for the base currency of the model
      model_secondary_id string Alternate id that can be used to identify the model such as an internal id
      allocation_composition_create_date array Timestamp for the date and time when the composition was created
      allocation_composition_update_date UUID Timestamp for the date and time when the composition was last updated
      model_holdings array Array of model holdings based on model_ids in the allocation_composition. Returns model_holdings that have the latest date.
          model_holding_id UUID The id of the model holding record
          model_holding_date date Date of the model holding
          security_id UUID The ID of the security
          security_name string The name of the security
          security_ticker string Security’s symbol on the exchange where it is traded
          security_asset_class string The asset class of the security such as “Equities” or “Fixed Income”
          security_sector string The sector of the security such as “Technology” or “Pharmaceuticals”
          security_industry string The industry of the security such as “Consumer Tech” or “Enterprise System”
          security_security_class string The security class of the security such as “Stock”, “Mutual Fund”, “ETF”, etc
          security_exchange string The exchange on which the security is traded such as “NYSE”
          security_secondary_id string Alternate ID of the security that can be used to identify the security such as an internal ID
          security_create_date timestamp Timestamp for the date and time when the security was created
          security_update_date timestamp Timestamp for the date and time when the security was last updated
          security_countries array Array of country and weights for the security
              country string Country where the company is located. See country codes
              weight double The weight of the country as a percentage of the security; ex. 20 representing 20%
          security_compositions array In the case that we have a security_id that consists of other securities, we use this array to return that security list. Return records where end_date = NULL.
              security_id UUID The ID of the security
              security_name string The name for the security
              security_ticker string Security’s symbol on the exchange where it is traded
              security_weight double The weight of the country as a percentage of the broader security; ex. 20 representing 20%. The weights of all the components must add up to 100.
              start_date date Date for when the underlying security started being a part of the broader security
              end_date date Date for when the underlying security no longer was a part of the broader security
              security_asset_class string The asset class of the security such as “Equities” or “Fixed Income”
              security_sector string The sector of the security such as “Technology” or “Pharmaceuticals”
              security_industry string The industry of the security such as “Consumer Tech” or “Enterprise System”
              security_security_class string The security class of the security such as “Stock”, “Mutual Fund”, “ETF”, etc
              security_secondary_id string Alternate id of the security that can be used to identify the security such as an internal id
              security_create_date timestamp Timestamp for the date and time when the security was created
              security_update_date timestamp Timestamp for the date and time when the security was last updated
              security_country array Array of originating country and weights for the security included in the composition
                  country string Country where the company is located. See country codes
                  weight double The weight of the country as a percentage of the security; ex. 20 representing 20%

HTTP REQUEST

GET /allocation/{allocation_id}/aggregate_data

Example Request

curl -X GET -H "Authorization: Bearer <access_token>" \
  "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/allocation/0797efda-cf8b-4661-9cb4-d1e8966a3dcd/aggregate_data"
api_instance = nucleus_api.AllocationApi(nucleus_api.ApiClient(configuration))
try:
    api_response = api_instance.get_allocation_all_aggregate_data_using_get("d5529e8d-03d6-452e-9372-f3af8275dab5")
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_allocation_aggregated_data_using_get: %s\n" % e)
AllocationApi apiInstance = new AllocationApi();
        try {
            Object allocationaggregatedata = apiInstance.getAllocationAllAggregateDataUsingGet(UUID.fromString("e759ad98-a1b3-409b-9b48-e267b1f40759"));
            System.out.println(allocationaggregatedata);
        } catch (ApiException e) {
            System.err.println("Exception when calling getAllocationAllAggregateDataUsingGet");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\AllocationApi(
    new GuzzleHttp\Client(),
    $config);
$allocation_id = "e759ad98-a1b3-409b-9b48-e267b1f40759"; // string | Allocation Id

try {
    $allocationaggregatedata = $apiInstance->getAllocationAllAggregateDataUsingGet($allocation_id);
    print_r($allocationaggregatedata);
} catch (Exception $e) {
    echo 'Exception when calling AllocationApi->getAllocationAllAggregateDataUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::AllocationApi.new
allocation_id = 'e759ad98-a1b3-409b-9b48-e267b1f40759' # String | Allocation Id

begin
  aggregate = api_instance.get_allocation_all_aggregate_data_using_get(allocation_id)
  p aggregate
rescue NucleusApi::ApiError => e
  puts "Exception when calling AllocationApi->get_allocation_all_aggregate_data_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.AllocationApi();
var opts = {
    'endDate': "2018-07-25",
    'startDate': "2020-09-10",
    'ascending': false, // Boolean | ascending
    // 'filter': "", // String | filter
    'orderBy': "update_date", // String | order_by
    'page': 0, // Number | page
    'size': 25 // Number | size

};

var allocationaggregatedata = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.getAllocationAllAggregateDataUsingGet(allocationId, allocationaggregatedata)

Example Response

{
  "allocation_id": "088be9e2-ae2e-4d56-83a2-2b67634fa56f",
  "allocation_name": "Medium Risk Global Asset Allocation",
  "allocation_category": "Medium Risk",
  "allocation_description": "Diversified asset allocation giving clients with a medium risk appetite exposure to global assets.",
  "allocation_secondary_id": null,
  "allocation_compositions": [
    {
      "allocation_composition_id": "34932d83-de4a-4a55-9ba3-154e256e9dab",
      "allocation_composition_date": "2026-10-14",
      "model_id": "86bcab43-2e7a-43ec-9ee8-4eb8321a7d34",
      "model_name": "Build Wealth 10 Taxable",
      "model_category": "Aggressive Long-Term Portfolio (Taxable)",
      "model_description": "A long-term portfolio for aggressive investors seeking compelling risk-adjusted returns in a taxable account.",
      "model_strategic_weight": 100.0,
      "model_current_weight": 100.0,
      "model_secondary_id": null,
      "allocation_composition_create_date": "2019-01-04T14:56:07.000+0000",
      "allocation_composition_update_date": "2019-01-04T14:56:07.000+0000",
      "model_holdings": [
        {
          "model_holding_id": "9721d7f2-5d33-41cd-96f6-5cf2464aaa9a",
          "model_holding_date": "2026-10-14",
          "security_id": "f241e336-3958-4d1f-bbd7-faf39772c3a4",
          "security_name": "Tesla, Inc.",
          "security_ticker": "1546613776467",
          "security_asset_class": "US Equity",
          "security_sector": "Consumer Cyclical",
          "security_industry": "Auto Manufacturers",
          "security_security_class": "stock",
          "security_exchange": "1546613776467",
          "security_secondary_id": null,
          "security_create_date": "2019-01-04T14:56:17.000+0000",
          "security_update_date": "2019-01-04T14:56:17.000+0000",
          "security_countries": [
            {
                "country": "US",
                "weight": 1.0
            }
          ],
          "security_compositions": [
            {
              "security_id": "000dkk9s-a9d0-sd8f-asd0fg9f",
              "security_name": "Apple",
              "security_ticker": "AAPL",
              "security_weight": 50,
              "start_date": "2018-02-02",
              "end_date": null,
              "security_asset_class": "TECH",
              "security_sector": "Technology",
              "security_industry": "Technology Services",
              "security_security_class": "Stocks",
              "security_secondary_id": "SYSGEN_APPLESTOCK_TIMESTAMP",
              "security_create_date": "2018-02-02T9:00:03.000+0000",
              "security_update_date": "2018-02-02T9:00:03.000+0000",
              "security_country": [
                {
                  "country" : "USA",
                  "weight" : 100
                }
              ]
            },
            {
              "security_id": "0099s9s8d-a9d0-sd8f-asd0fg9f",
              "security_name": "Salesforce",
              "security_ticker": "CRM",
              "security_weight": 50,
              "start_date": "2018-02-02",
              "end_date": null,
              "security_asset_class": "TECH",
              "security_sector": "Technology",
              "security_industry": "Technology Services",
              "security_security_class": "Stocks",
              "security_secondary_id": "SYSGEN_SALESFORCESTOCK_TIMESTAMP",
              "security_create_date": "2018-02-02T9:00:04.000+0000",
              "security_update_date": "2018-02-02T9:00:04.000+0000",
              "security_country": [
                {
                  "country" : "USA",
                  "weight" : 100
                }
              ]
            }
          ]
        }
      ]
    }
  ]
}

Budget

This entity allows the user to add budget details for various categories so that they can track their spending against their budget over time.

Field Type Description
id UUID The id of the budget
name string Name of the budget
client_id UUID The ID of the client the budget belongs to
account_id UUID The ID of the account the budget belongs to
card_id UUID The ID of the card the budget belongs to
goal_id UUID The ID of a goal mapped to the budget
aggregation_accounts array(map) List of aggregation accounts associated with the budget
      aggregation_account_id UUID The id of the aggregation account mapped to the budget
frequency_unit string Frequency of the budget. Value may be daily, weekly, bi-weekly, monthly, semi-monthly, quarterly, or annually
frequency integer Number of frequency_unit between each budget. For example, if the frequency_unit is weekly and the frequency is 2, this means the budget occurs every two weeks. Default is 1
currency_code string Alphabetic currency code for the base currency of the budget, limited to 3 characters. See currency codes
total_value double Total budget value if you do not wish to track by category
budget array(map) List of budget items and their descriptions if you wish to track by category
      category string Category of the budget
      subcategory string Subcategory of the budget
      value double Amount of the budget
start_date date The start date for the budget
end_date date The end date for the budget
is_active boolean Indicates if the budget is active. Defaults to true which indicates that it is currently active
metadata map Custom information associated with the budget in the format key:value
See Metadata
secondary_id string Alternate id that can be used to identify the budget such as an internal id
create_date timestamp Timestamp for the date and time that the budget was created
update_date timestamp Timestamp for the date and time that the budget was last updated

List all budgets

Example Request

curl -X GET -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/budget"
api_instance = nucleus_api.BudgetApi(nucleus_api.ApiClient(configuration))
try:
    api_response = api_instance.get_budget_all_using_get()
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_budget_all_using_get: %s\n" % e)
BudgetApi apiInstance = new BudgetApi();
        try {
            PageBudget List = apiInstance.getBudgetAllUsingGet(true, null, null, null, 0, 10 );
            System.out.println(List);
        } catch (ApiException e) {
            System.err.println("Exception when calling getBudgetAllUsingGet");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\BudgetApi(
    new GuzzleHttp\Client(),
    $config);
$ascending = false; // bool | ascending
$currency_conversion = null; // string | currency_conversion
$filter = null; // string | filter
$order_by = null; // string | order_by
$page = 0; // int | page
$size = 10; // int | size

try {
    $budgetlist = $apiInstance->getBudgetAllUsingGet($ascending, $currency_conversion, $filter, $order_by, $page, $size);
    print_r($budgetlist);
} catch (Exception $e) {
    echo 'Exception when calling BudgetApi->getBudgetAllUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::BudgetApi.new
opts = {
    ascending: false, # BOOLEAN | ascending
    currency_conversion: null, # String | currency_conversion
    filter: null, # String | filter
    order_by: null, # String | order_by
    page: 0, # Integer | page
    size: 25 # Integer | size
}

begin
  budgetlist = api_instance.get_budget_all_using_get(opts)
  p budgetlist
rescue NucleusApi::ApiError => e
  puts "Exception when calling BudgetApi->get_budget_all_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.BudgetApi();
var opts = {
    'ascending': false, // Boolean | ascending
    // 'filter': "", // String | filter
    'orderBy': "update_date", // String | order_by
    'page': 0, // Number | page
    'size': 25 // Number | size
};

var budgetlist = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.getBudgetAllUsingGet(opts, budgetlist)

Example Response

{
    "content": [
        {
            "id": "ce77358c-1e00-4e75-8deb-bd35c4ad8e65",
            "name": "Budget - Jun 2015",
            "account_id": null,
            "goal_id": null,
            "card_id": null,
            "client_id": "1c92f054-e4a6-4e45-b29b-567587f34c27",
            "aggregation_accounts": [],
            "frequency_unit": "monthly",
            "frequency": 1,
            "currency_code": "USD",
            "total_value": null,
            "budget": [
                {
                    "category": "Food & Dining",
                    "subcategory": "Alcohol & Bars",
                    "value": 50.0
                },
                {
                    "category": "Health & Fitness",
                    "subcategory": "Sports",
                    "value": 50.0
                }
            ],
            "start_date": "2015-01-01",
            "end_date": "2016-12-31",
            "is_active": true,
            "metadata": {},
            "create_date": "2019-07-16T20:06:03.000+0000",
            "update_date": "2019-08-09T21:09:38.000+0000"
        },
        {
            "id": "2529eeef-583a-4f71-a511-9754e630f541",
            "name": "Fashion Budget",
            "account_id": null,
            "goal_id": null,
            "card_id": null,
            "client_id": "10e6db9e-d2b2-4806-9a19-2203f877ece1",
            "aggregation_accounts": [],
            "frequency_unit": "monthly",
            "frequency": 1,
            "currency_code": "USD",
            "total_value": null,
            "budget": [
                {
                    "category": "Fashion",
                    "subcategory": "Other Fashion",
                    "value": 50.0
                },
                {
                    "category": "Fashion",
                    "subcategory": "Clothing",
                    "value": 150.0
                },
                {
                    "category": "Fashion",
                    "subcategory": "Shoes",
                    "value": 150.0
                }
            ],
            "start_date": "2019-08-01",
            "end_date": "2020-08-01",
            "is_active": true,
            "metadata": {},
            "create_date": "2019-08-06T14:49:57.000+0000",
            "update_date": "2019-08-06T14:49:57.000+0000"
        }
    ],
  "total_pages": 1,
  "total_elements": 2,
  "last": false,
  "number_of_elements": 25,
  "first": true,
  "sort": [
      {
          "direction": "DESC",
          "property": "updateDate",
          "ignore_case": false,
          "null_handling": "NATIVE",
          "descending": true,
          "ascending": false
      }
  ],
  "size": 25,
  "number": 0
}

Get details for all budgets created within your firm. Note that the budget information and the metadata information are nested objects within the budget object.

HTTP REQUEST

GET /budget

Create a budget

Example Request

curl -X POST -H "Authorization: Bearer <access_token>" \
    -H "Content-Type: application/json" \
    -d '{
          "client_id": "318d4823-f8ae-4324-98e4-b87f551e2a7e",
          "name": "Budget - Nov 2015",
          "frequency_unit": "monthly",
          "frequency": 1,
          "currency_code": "USD",
          "budget": [
            {
              "category": "Healthcare",
              "subcategory": "Vitamins",
              "value": 20.0
            },
            {
              "category": "Healthcare",
              "value": 70.0
            },
            {
              "category": "Gifts",
              "subcategory": "Wedding",
              "value": 90.0
            },
            {
              "category": "Leisure",
              "value": 100.0
            },
            {
              "category": "Loans",
              "subcategory": "Finance charge",
              "value": 30.0
            }
          ],
          "start_date": "2015-11-01",
          "end_date": "2015-11-30"
    }' "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/budget"
api_instance = nucleus_api.BudgetApi(nucleus_api.ApiClient(configuration))
# # Create a Budget
budget = nucleus_api.Budget(name="New", client_id="120c7d8f-2c0c-4501-b393-1b7856028010", frequency="2", frequency_unit="monthly", currency_code="GBP", total_value="100.0")
try:
    api_response = api_instance.create_budget_using_post(budget)
    pprint(api_response)
except ApiException as e:
    print("create_budget_using_post: %s\n" % e)
BudgetApi apiInstance = new BudgetApi();
        //Create Budget

        Budget createBudget = new Budget();
        createBudget.setName("Abc");
        createBudget.setClientId(UUID.fromString("120c7d8f-2c0c-4501-b393-1b7856028010"));
        createBudget.setFrequency(2);
        createBudget.setFrequencyUnit("monthly");
        createBudget.currencyCode("USD");
        createBudget.setTotalValue(100.00);

                try {
            Budget result = apiInstance.createBudgetUsingPost(createBudget);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling createBudgetUsingPost");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\BudgetApi(
    new GuzzleHttp\Client(),
    $config);
//Create Budget
$budget = new \com\hydrogen\nucleus\Model\Budget();

try {
    $budget->setClientId("120c7d8f-2c0c-4501-b393-1b7856028010");
    $budget->setName("ANC");
    $budget->setFrequency("2");
    $budget->setFrequencyUnit("monthly");
    $budget->setCurrencyCode("GBP");
    $budget->setTotalValue("100");
    $result = $apiInstance->createBudgetUsingPost($budget);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->createBudgetUsingPost: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::BudgetApi.new
#Create Budget
budget = NucleusApi::Budget.new

begin
  budget.client_id = "120c7d8f-2c0c-4501-b393-1b7856028010"
  budget.name = "New"
  budget.frequency = "2"
  budget.frequency_unit = "monthly"
  budget.currency_code = "USD"
  budget.total_value = "200"
  result = api_instance.create_budget_using_post(budget)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->create_budget_using_post: #{e}"
end
var apiInstance = new HydrogenNucleusApi.BudgetApi();
//Create Budget
var budget = new HydrogenNucleusApi.Budget();
budget.name = "New";
budget.client_id = '120c7d8f-2c0c-4501-b393-1b7856028010';
budget.frequency = "2";
budget.frequency_unit = "monthly";
budget.currency_code = "USD";
budget.total_value = "100";


var newbudget = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.createBudgetUsingPost(budget, newbudget)

Example Response

{
    "id": "c31322b7-f363-478f-93da-56994d08996e",
    "name": "Budget - Nov 2015",
    "account_id": null,
    "goal_id": null,
    "card_id": null,
    "client_id": "318d4823-f8ae-4324-98e4-b87f551e2a7e",
    "aggregation_accounts": [],
    "frequency_unit": "monthly",
    "frequency": 1,
    "currency_code": "USD",
    "total_value": null,
    "budget": [
        {
            "category": "Healthcare",
            "value": 70.0
        },
        {
            "category": "Healthcare",
            "subcategory": "Vitamins",
            "value": 20.0
        },
        {
            "category": "Leisure",
            "value": 100.0
        },
        {
            "category": "Loans",
            "subcategory": "Finance charge",
            "value": 30.0
        },
        {
            "category": "Gifts",
            "subcategory": "Wedding",
            "value": 90.0
        }
    ],
    "start_date": "2015-11-01",
    "end_date": "2015-11-30",
    "is_active": true,
    "metadata": {},
    "create_date": "2019-08-21T20:00:50.478+0000",
    "update_date": "2019-08-21T20:00:50.478+0000"
}

Create a new budget for a client. The create_date will default to the current date. The endpoint returns a unique budget_id that is used to manage the specific budget and referenced in other endpoints.

HTTP REQUEST

POST /budget

ARGUMENTS

Parameter Type Required Description
name string required Name of the budget
client_id UUID required The ID of the client the budget belongs to
account_id UUID optional The ID of the account the budget belongs to
card_id UUID optional The ID of the card the budget belongs to
goal_id UUID optional The ID of a goal mapped to the budget
aggregation_accounts array(map) optional List of aggregation accounts associated with the budget
      aggregation_account_id UUID required The id of the aggregation account mapped to the budget
currency_code string required Alphabetic currency code for the base currency of the budget, limited to 3 characters. See currency codes
total_value double required, conditional Total budget value if you do not wish to track by category. Either the total_value or values within the budget array must be set (not both at the same time).
budget array(map) required, conditional List of budget items and their descriptions if you wish to track by category. Either the total_value or values within the budget array must be set (not both at the same time).
      category string required Category of the budget
      subcategory string optional Subcategory of the budget
      value double required Value amount of the budget
frequency_unit string required Frequency of the budget. Value may be daily, weekly, bi-weekly, monthly, semi-monthly, quarterly, or annually
frequency integer optional Number of frequency_unit between each budget. For example, if the frequency_unit is weekly and the frequency is 2, this means the budget occurs every two weeks. Default is 1
start_date date optional The start date for the budget
end_date date optional The end date for the budget
is_active boolean optional Indicates if the budget is active. Defaults to true which indicates that it is currently active
metadata map optional Custom information associated with the budget in the format key:value
See Metadata
secondary_id string optional Alternate id that can be used to identify the budget such as an internal id

Retrieve a budget

Retrieve the information for a budget. The unique budget_id must be provided. The endpoint returns the budget_id and the details for the budget. Note that the budget information and the metadata information are nested objects within the budget object.

Example Request

curl -X GET -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/budget/c31322b7-f363-478f-93da-56994d08996e"
api_instance = nucleus_api.BudgetApi(nucleus_api.ApiClient(configuration))
try:
    api_response = api_instance.get_budget_using_get("d70b7b4c-5dff-4ba1-88a1-c99cd1bc0ae4")
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_budget_using_get: %s\n" % e)
BudgetApi apiInstance = new BudgetApi();
        try {
            Budget responseBudget = apiInstance.getBudgetUsingGet(UUID.fromString("d36b1d2c-1adb-4597-8682-22de246c25cb"), null);
            System.out.println(responseBudget);
        } catch (ApiException e) {
            System.err.println("Exception when calling getBudgetUsingGet");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\BudgetApi(
    new GuzzleHttp\Client(),
    $config);
$budget_id = "d36b1d2c-1adb-4597-8682-22de246c25cb"; // string | UUID budget_id
$currency_conversion = null; // string | USD

try {
    $budget = $apiInstance->getBudgetUsingGet($budget_id, $currency_conversion);
    print_r($budget);
} catch (Exception $e) {
    echo 'Exception when calling BudgetApi->getBudgetUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::BudgetApi.new
budget_id = 'd36b1d2c-1adb-4597-8682-22de246c25cb' # String | UUID budget_id

opts = {
    currency_conversion: null, # String | USD
}

begin
  budget = api_instance.get_budget_using_get(budget_id, opts)
  p budget
rescue NucleusApi::ApiError => e
  puts "Exception when calling BudgetApi->get_budget_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.BudgetApi();
var budgetId = "d70b7b4c-5dff-4ba1-88a1-c99cd1bc0ae4";


var budget = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.getBudgetUsingGet(budgetId, budget)

Example Response

{
    "id": "c31322b7-f363-478f-93da-56994d08996e",
    "name": "Budget - Nov 2015",
    "account_id": null,
    "goal_id": null,
    "card_id": null,
    "client_id": "318d4823-f8ae-4324-98e4-b87f551e2a7e",
    "aggregation_accounts": [],
    "frequency_unit": "monthly",
    "frequency": 1,
    "currency_code": "USD",
    "total_value": null,
    "budget": [
        {
            "category": "Healthcare",
            "value": 70.0
        },
        {
            "category": "Healthcare",
            "subcategory": "Vitamins",
            "value": 20.0
        },
        {
            "category": "Leisure",
            "value": 100.0
        },
        {
            "category": "Loans",
            "subcategory": "Finance charge",
            "value": 30.0
        },
        {
            "category": "Gifts",
            "subcategory": "Wedding",
            "value": 90.0
        }
    ],
    "start_date": "2015-11-01",
    "end_date": "2015-11-30",
    "is_active": true,
    "metadata": {},
    "create_date": "2019-08-21T20:00:50.000+0000",
    "update_date": "2019-08-21T20:00:50.000+0000"
}

HTTP REQUEST

GET /budget/{budget_id}

Update a budget

Example Request

curl -X PUT -H "Authorization: Bearer <access_token>" \
    -H "Content-Type: application/json" \
    -d '{
            "budget": [
                {
                    "category": "Healthcare",
                    "subcategory": "Vitamins",
                    "value": 100.0
                },
                {
                    "category": "Gifts",
                    "subcategory": "Wedding / Wedding shower",
                    "value": 90.0
                },
                {
                    "category": "Leisure (daily / non-vacation)",
                    "value": 100.0
                },
                {
                    "category": "Loans",
                    "subcategory": "Finance charge / Interest",
                    "value": 30.0
                }
            ]
    }' "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/budget/c31322b7-f363-478f-93da-56994d08996e"
api_instance = nucleus_api.BudgetApi(nucleus_api.ApiClient(configuration))
# #Update Budget
budget_Update = {'currency_code': 'USD'}
budget_id = '3eb62b3e-2771-4976-a99f-8831cfb7b968'
try:
    api_response = api_instance.update_budget_using_put(budget_Update, budget_id)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling update_budget_using_put: %s\n" % e)
BudgetApi apiInstance = new BudgetApi();
                //Update an Budget

        Map map = new HashMap();
        map.put("currency_code", "GBP");

        try {
            Budget response = apiInstance.updateBudgetUsingPut(map, UUID.fromString("b1bf95ce-c944-421a-834b-d5375d76ce78"));
            System.out.println(response);
        } catch (ApiException e) {
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\BudgetApi(
    new GuzzleHttp\Client(),
    $config);
//Update Budget
$budget_update = new stdClass();
$budget_id = "45ddcc95-40c4-4cee-b4b8-f721697a51a4";

try {
    $budget_update->currency_code = "GBP";
    $result = $apiInstance->updateBudgetUsingPut($budget_update, $budget_id);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->updateBudgetUsingPut: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::BudgetApi.new
#Update Budget
budget_update = {"currency_code" => 'CAD'}
budget_id = 'b9d61151-4491-4575-bc11-15bc0ce54304'
begin
  result = api_instance.update_budget_using_put(budget_update, budget_id)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->update_budget_using_put: #{e}"
end
var apiInstance = new HydrogenNucleusApi.BudgetApi();
//Update Budget
var apiInstance = new HydrogenNucleusApi.BudgetApi();
var callback = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
var budgetupdate = new HydrogenNucleusApi.Budget();
var budgetid = "2732ae83-7d8f-4403-95c8-8bff56f73dc3";

budgetupdate.currency_code = "GBP";
apiInstance.updateBudgetUsingPut(budgetupdate, budgetid, callback)

Example Response

{
    "id": "c31322b7-f363-478f-93da-56994d08996e",
    "name": "Budget - Nov 2015",
    "account_id": null,
    "goal_id": null,
    "card_id": null,
    "client_id": "318d4823-f8ae-4324-98e4-b87f551e2a7e",
    "aggregation_accounts": [],
    "frequency_unit": "monthly",
    "frequency": 1,
    "currency_code": "USD",
    "total_value": null,
    "budget": [
        {
            "category": "Healthcare",
            "subcategory": "Vitamins",
            "value": 100.0
        },
        {
            "category": "Leisure (daily / non-vacation)",
            "value": 100.0
        },
        {
            "category": "Loans",
            "subcategory": "Finance charge / Interest",
            "value": 30.0
        },
        {
            "category": "Gifts",
            "subcategory": "Wedding / Wedding shower",
            "value": 90.0
        }
    ],
    "start_date": "2015-11-01",
    "end_date": "2015-11-30",
    "is_active": true,
    "metadata": {},
    "create_date": "2019-08-21T20:00:50.000+0000",
    "update_date": "2019-08-21T20:00:50.000+0000"
}

Update the information for a budget. The unique budget_id must be provided. To obtain the appropriate budget_id, use the GET /budget endpoint to view all available budget_ids and their current information. The details to be updated must also be provided. The endpoint returns the budget_id and the details for the budget.

HTTP REQUEST

PUT /budget/{budget_id}

Delete a budget

Example Request

curl -X DELETE -H "Authorization: Bearer ce77358c-1e00-4e75-8deb-bd35c4ad8e65" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/budget/c31322b7-f363-478f-93da-56994d08996e"
api_instance = nucleus_api.BudgetApi(nucleus_api.ApiClient(configuration))
# # #  # Delete a Budget
# budget_id = 'c05e219c-c197-4303-abb2-e0ce0dc43b5f'
try:
    api_instance.delete_budget_using_delete(budget_id)
except ApiException as e:
    print("Exception when delete_budget_using_delete: %s\n" % e)
BudgetApi apiInstance = new BudgetApi();
        ////   Delete Budget
        try {
            Budget deleteresponse = apiInstance.deleteBudgetUsingDelete(UUID.fromString("c0692f22-29f2-43b4-9782-bf629b3f5226"));
            System.out.println(deleteresponse);
        } catch (ApiException e) {
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\BudgetApi(
    new GuzzleHttp\Client(),
    $config);
//Delete Budget
$budget_did = "3eb62b3e-2771-4976-a99f-8831cfb7b968"; // string | UUID account_id

try {
    $apiInstance->deleteBudgetUsingDelete($budget_did);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->deleteBudgetUsingDelete: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::BudgetApi.new
#Delete Budget
budget1_id = '95c2cb30-760a-47d4-9260-2f3f4958b801'
begin
  result = api_instance.delete_budget_using_delete(budget1_id)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->delete_budget_using_delete: #{e}"
end
var apiInstance = new HydrogenNucleusApi.BudgetApi();
// //Delete a Budget
var budgetdid = "b9d61151-4491-4575-bc11-15bc0ce54304";


var deletebudget = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully.');
    }
};
apiInstance.deleteBudgetUsingDelete(budgetdid, deletebudget)

Response (204 No Content)

Permanently delete a budget. The unique budget_id must be provided. To obtain the appropriate budget_id, use the GET /budget endpoint to view all available budget_ids. This deletes the budget_id and all the budget information associated with it.

HTTP REQUEST

DELETE /budget/{budget_id}

Benchmark

Benchmark Management

A benchmark is assigned a group of securities to act as an index for the performance of some aspect of the market, whether that be the market as a whole or a specific segment of the market. The benchmark essentially acts as a proxy for a client, account, allocation, model, or portfolio that would also hold a group of securities to approximate or measure their performance. A benchmark can also hold just one security to be used as a benchmark security and track its price growth. Benchmarks are required to us the Performance endpoints.

Field Type Description
id UUID The id of the benchmark
name string Name of the benchmark
composition array List of securities and their respective weights as a percentage of the benchmark’s total value
      weight double The weight of the security as a percentage of the benchmark’s total value; ex. 20 representing 20%. The weights of all the securities must add up to 100
      security_id string The id of the security in the benchmark
description string Description of the benchmark such as the market segment that it represents
client_id string The id of the client to which the benchmark belongs, if any
is_active boolean Indicates if the benchmark is active. Defaults to true which means it is active
metadata map Custom information associated with the entity in the format key:value
See Metadata
secondary_id string Alternate id that can be used to identify the object such as an internal id
create_date timestamp Timestamp for the date and time that the record was created
update_date timestamp Timestamp for the date and time that the record was last updated

List all benchmarks

Example Request

curl -X GET -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/benchmark"
api_instance = nucleus_api.BenchmarkApi(nucleus_api.ApiClient(configuration))
try:
    api_response = api_instance.get_benchmark_all_using_get()
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_benchmark_all_using_get: %s\n" % e)
BenchmarkApi apiInstance = new BenchmarkApi();
        try {
            PageBenchmark List = apiInstance.getBenchmarkAllUsingGet(true, null, null, 0,10);
            System.out.println(List);
        } catch (ApiException e) {
            System.err.println("Exception when calling getBenchmarkAllUsingGet");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\BenchmarkApi(
    new GuzzleHttp\Client(),
    $config);
$ascending = false; // bool | ascending
$filter = null; // string | filter
$order_by = null; // string | order_by
$page = 0; // int | page
$size = 10; // int | size

try {
    $benchmarklist = $apiInstance->getBenchmarkAllUsingGet($ascending, $filter, $order_by, $page, $size);
    print_r($benchmarklist);
} catch (Exception $e) {
    echo 'Exception when calling BenchmarkApi->getBenchmarkAllUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::BenchmarkApi.new
opts = {
    ascending: false, # BOOLEAN | ascending
    filter: null, # String | filter
    order_by: null, # String | order_by
    page: 0, # Integer | page
    size: 25 # Integer | size
}

begin
  benchmarklist = api_instance.get_benchmark_all_using_get(opts)
  p benchmarklist
rescue NucleusApi::ApiError => e
  puts "Exception when calling BenchmarkApi->get_benchmark_all_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.BenchmarkApi();
var opts = {
    'ascending': false, // Boolean | ascending
    // 'filter': "", // String | filter
    'orderBy': "update_date", // String | order_by
    'page': 0, // Number | page
    'size': 25 // Number | size
};

var benchmarklist = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.getBenchmarkAllUsingGet(opts, benchmarklist)

Example Response

{
    "content": [
        {
            "id": "d79bb3a3-f259-430c-8fa8-a93f87cc3bdf",
            "create_date": "2018-03-27T11:45:08.000+0000",
            "update_date": "2018-03-27T11:45:08.000+0000",
            "description": "80% US Small Cap, 20% US Municipal bonds",
            "is_active": true,
            "name": "80/20 US Benchmark",
            "composition": [
                {
                    "weight": 80,
                    "security_id": "00178f8e-2c0b-4e15-b725-74d53b9533ef"
                },
                {
                    "weight": 20,
                    "security_id": "001067fd-a504-43b0-858c-2a43a26e91e9"
                }
            ],
            "metadata": {}
        },
        {
            "id": "d2e19c41-9c57-4508-a5e8-6dff7f0ffe7d",
            "create_date": "2018-03-27T11:44:22.000+0000",
            "update_date": "2018-03-27T11:44:22.000+0000",
            "description": "60% US Small Cap, 40% US Municipal bonds",
            "is_active": true,
            "name": "60/40 US Benchmark",
            "composition": [
                {
                    "weight": 60,
                    "security_id": "00178f8e-2c0b-4e15-b725-74d53b9533ef"
                },
                {
                    "weight": 40,
                    "security_id": "001067fd-a504-43b0-858c-2a43a26e91e9"
                }
            ],
            "metadata": {}
        }
    ],
    "total_pages": 1,
    "total_elements": 2,
    "last": true,
    "number_of_elements": 2,
    "first": true,
    "sort": [
        {
            "direction": "DESC",
            "property": "updateDate",
            "ignore_case": false,
            "null_handling": "NATIVE",
            "descending": true,
            "ascending": false
        }
    ],
    "size": 25,
    "number": 0
}

Get details for all benchmarks defined for your tenant. Note that the composition information is stored as a nested object within the benchmark object.

HTTP REQUEST

GET /benchmark

Create a benchmark

Example Request

curl -X POST -H "Authorization: Bearer <access_token>" \
     -H "Content-Type: application/json" -H \
     -d '{
        "description": "80% US Small Cap, 20% US Municipal bonds",
        "name": "80/20 US Benchmark",
        "composition": [
            {
                "weight": 80,
                "security_id": "00178f8e-2c0b-4e15-b725-74d53b9533ef"
            },
            {
                "weight": 20,
                "security_id": "001067fd-a504-43b0-858c-2a43a26e91e9"
            }
        ]
     }' "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/benchmark"
api_instance = nucleus_api.BenchmarkApi(nucleus_api.ApiClient(configuration))
# # Create a Benchmark
benchmark = nucleus_api.Benchmark(name="New Mark")
try:
    api_response = api_instance.create_benchmark_using_post(benchmark)
    pprint(api_response)
except ApiException as e:
    print("create_benchmark_using_post: %s\n" % e)
BenchmarkApi apiInstance = new BenchmarkApi();
        //Create a Benchmark
Benchmark benchmark = new Benchmark();
        benchmark.setName("OneStar78");

                try {
            Benchmark result = apiInstance.createBenchmarkUsingPost(benchmark);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling createBenchmarkUsingPost");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\BenchmarkApi(
    new GuzzleHttp\Client(),
    $config);
//Create Benchmark
$benchmark = new \com\hydrogen\nucleus\Model\Benchmark();

try {
    $benchmark->setName("ABC CORP");
    $result = $apiInstance->createBenchmarkUsingPost($benchmark);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->createBenchmarkUsingPost: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::BenchmarkApi.new
#Create Benchmark
benchmark = NucleusApi::Benchmark.new

begin
  benchmark.name = "BNEW"
  result = api_instance.create_benchmark_using_post(benchmark)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->create_benchmark_using_post: #{e}"
end
var apiInstance = new HydrogenNucleusApi.BenchmarkApi();
//Create Benchmark
var benchmark = new HydrogenNucleusApi.Benchmark();
benchmark.name = "New";

var newbenchmark = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.createBenchmarkUsingPost(benchmark, newbenchmark)

Example Response

{
    "id": "d79bb3a3-f259-430c-8fa8-a93f87cc3bdf",
    "create_date": "2018-03-27T11:45:08.000+0000",
    "description": "80% US Small Cap, 20% US Municipal bonds",
    "is_active": true,
    "name": "80/20 US Benchmark",
    "composition": [
        {
            "weight": 80,
            "security_id": "00178f8e-2c0b-4e15-b725-74d53b9533ef"
        },
        {
            "weight": 20,
            "security_id": "001067fd-a504-43b0-858c-2a43a26e91e9"
        }
    ],
    "metadata": {}
}

Create a new benchmark for your tenant. The name for the benchmark must be provided. The composition of securities and their weights should also be provided as a nested object for the benchmark to be usable. The create_date will default to the current date. The endpoint returns a benchmark_id used to manage the benchmark and assign it to allocations.

HTTP REQUEST

POST /benchmark

ARGUMENTS

Parameter Type Required Description
name string required Name of the benchmark
composition array optional List of securities and their respective weights as a percentage of the benchmark’s total value. It is recommended to provide at least one security_id
      weight double required The weight of the security as a percentage of the benchmark’s total value; ex. 20 representing 20%. The weights of all the securities must add up to 100
      security_id string required The id of the security in the benchmark
description string optional Description of the benchmark such as the market segment that it represents
client_id string optional The id of the client to which the benchmark belongs, if any
is_active boolean optional Indicates if the benchmark is active. Defaults to true which means it is active
metadata map optional Custom information associated with the funding request in the format key:value. See Metadata
secondary_id string optional Alternate id that can be used to identify the object such as an internal id

Retrieve a benchmark

Example Request

curl -X GET -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/benchmark/d79bb3a3-f259-430c-8fa8-a93f87cc3bdf"
api_instance = nucleus_api.BenchmarkApi(nucleus_api.ApiClient(configuration))
try:
    api_response = api_instance.get_benchmark_using_get("fceee415-73bb-4efd-af23-42f47009ae24")
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_benchmark_using_get: %s\n" % e)
BenchmarkApi apiInstance = new BenchmarkApi();
        try {
            Benchmark responseBenchmark = apiInstance.getBenchmarkUsingGet(UUID.fromString("fcd65db8-2e9e-4be4-94b4-85f32fe4b6ac"));
            System.out.println(responseBenchmark);
        } catch (ApiException e) {
            System.err.println("Exception when calling getBenchmarkUsingGet");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\BenchmarkApi(
    new GuzzleHttp\Client(),
    $config);
$benchmark_id = "fcd65db8-2e9e-4be4-94b4-85f32fe4b6ac"; // string | UUID benchmark_id

try {
    $benchmark = $apiInstance->getBenchmarkUsingGet($benchmark_id);
    print_r($benchmark);
} catch (Exception $e) {
    echo 'Exception when calling BenchmarkApi->getBenchmarkUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::BenchmarkApi.new
benchmark_id = 'benchmark_id_example' # String | UUID benchmark_id

begin
  benchmark = api_instance.get_benchmark_using_get(benchmark_id)
  p benchmark
rescue NucleusApi::ApiError => e
  puts "Exception when calling BenchmarkApi->get_benchmark_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.BenchmarkApi();
var benchmarkId = "d919084a-92d0-4ed5-bcce-16d7cf3153fc";

var benchmark = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.getBenchmarkUsingGet("d919084a-92d0-4ed5-bcce-16d7cf3153fc", benchmark)

Example Response

{
    "id": "d79bb3a3-f259-430c-8fa8-a93f87cc3bdf",
    "create_date": "2018-03-27T11:45:08.000+0000",
    "update_date": "2018-03-27T11:45:08.000+0000",
    "description": "80% US Small Cap, 20% US Municipal bonds",
    "is_active": true,
    "name": "80/20 US Benchmark",
    "composition": [
        {
            "weight": 80,
            "security_id": "00178f8e-2c0b-4e15-b725-74d53b9533ef"
        },
        {
            "weight": 20,
            "security_id": "001067fd-a504-43b0-858c-2a43a26e91e9"
        }
    ],
    "metadata": {}
}

Retrieve the information for a benchmark. The benchmark_id must be provided. The endpoint returns the benchmark_id and the details for the benchmark specified.

HTTP REQUEST

GET /benchmark/{benchmark_id}

Update a benchmark

Example Request

curl -X PUT -H "Authorization: Bearer <access_token>" \
     -H "Content-Type: application/json" -H \
     -d '{
            "description": "80% US Small Cap, 20% US Municipal bonds",
             "name": "80/20 US Benchmark",
             "composition": [
                 {
                         "weight": 80,
                         "security_id": "00178f8e-2c0b-4e15-b725-74d53b9533ef"
                 },
                 {
                         "weight": 20,
                         "security_id": "001067fd-a504-43b0-858c-2a43a26e91e9"
                 }
             ]
        }' "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/benchmark/d79bb3a3-f259-430c-8fa8-a93f87cc3bdf"
api_instance = nucleus_api.BenchmarkApi(nucleus_api.ApiClient(configuration))
# #Update Benchmark
benchmark_update = {'name': 'New One'}
benchmark_id = '90352e3b-fdfb-4a0f-a3ea-9d09b911fe89'

try:
    api_response = api_instance.update_benchmark_using_put(benchmark_update, benchmark_id)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling update_benchmark_using_put: %s\n" % e)
BenchmarkApi apiInstance = new BenchmarkApi();
       // UpdateBenchmark

        Map map1 = new HashMap();
        map1.put("name", "new");

        try {
            Benchmark response = apiInstance.updateBenchmarkUsingPut(map1, UUID.fromString("90352e3b-fdfb-4a0f-a3ea-9d09b911fe89"));
            System.out.println(response);
        } catch (ApiException e) {
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\BenchmarkApi(
    new GuzzleHttp\Client(),
    $config);
//Update Benchmark
$benchmark_update = new stdClass();
$benchmark_id = "8ca1ef65-62a9-4ce2-9893-e693137a1c4b";

try {
    $benchmark->name = "abs";
    $result = $apiInstance->updateBenchmarkUsingPut($benchmark_update, $benchmark_id);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->updateBenchmarkUsingPut: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::BenchmarkApi.new
#Update Benchmark
benchmark_update = {"name" => 'CAD'}
benchmark_id = '099d4a29-9214-46ee-80cb-8a09923dfd6d'
begin
  result = api_instance.update_benchmark_using_put(benchmark_update, benchmark_id)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->update_benchmark_using_put: #{e}"
end
var apiInstance = new HydrogenNucleusApi.BenchmarkApi();
//Update Benchmark
var apiInstance = new HydrogenNucleusApi.BenchmarkApi();
var callback = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
var benchmarkupdate = new HydrogenNucleusApi.Benchmark();
var benchmarkid = "919c98e8-b22e-4174-976a-a96423b33c6e";

benchmarkupdate.name = "NEW";
apiInstance.updateBenchmarkUsingPut(benchmarkupdate, benchmarkid, callback)

Example Response

{
    "id": "d79bb3a3-f259-430c-8fa8-a93f87cc3bdf",
    "create_date": "2018-03-27T11:45:08.000+0000",
    "update_date": "2018-03-27T11:45:08.000+0000",
    "description": "80% US Small Cap, 20% US Municipal bonds",
    "is_active": true,
    "name": "80/20 US Benchmark",
    "composition": [
        {
            "weight": 80,
            "security_id": "00178f8e-2c0b-4e15-b725-74d53b9533ef"
        },
        {
            "weight": 20,
            "security_id": "001067fd-a504-43b0-858c-2a43a26e91e9"
        }
    ],
    "metadata": {}
}

Updated the information for a benchmark. The benchmark_id must be provided. To obtain the appropriate benchmark_id, use the GET /benchmark endpoint to view all of the benchmarks defined firm-wide and their current information. The details to be updated and the details to be maintained must also be provided. The endpoint returns the benchmark_id and the details for the benchmark. To mark the benchmark as inactive so that it is no longer used without deleting it, you can use this endpoint to change the is_active field to false.

HTTP REQUEST

PUT /benchmark/{benchmark_id}

Delete a benchmark

Example Request

curl -X DELETE -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/benchmark/d79bb3a3-f259-430c-8fa8-a93f87cc3bdf"
api_instance = nucleus_api.BenchmarkApi(nucleus_api.ApiClient(configuration))
# # Delete a Benchmark
benchmark_id = 'a3aa0330-0391-4847-9f41-3a2e7e509f4a'
try:
    api_instance.delete_benchmark_using_delete(benchmark_id)
except ApiException as e:
    print("Exception when delete_benchmark_using_delete: %s\n" % e)
BenchmarkApi apiInstance = new BenchmarkApi();
// Delete Benchmark
        try {
            Benchmark deleteresponse = apiInstance.deleteBenchmarkUsingDelete(UUID.fromString("fcb66c57-19e3-4d2c-8edc-5f1de4724111"));
            System.out.println(deleteresponse);
        } catch (ApiException e) {
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\BenchmarkApi(
    new GuzzleHttp\Client(),
    $config);
//Delete Benchmark
$benchmark_did = "099d4a29-9214-46ee-80cb-8a09923dfd6d"; // string | UUID account_id

try {
    $apiInstance->deleteBenchmarkUsingDelete($benchmark_did);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->deleteBenchmarkUsingDelete: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::BenchmarkApi.new

#Delete Benchmark
benchmark1_id = 'a3aa0330-0391-4847-9f41-3a2e7e509f4a'
begin
  result = api_instance.delete_benchmark_using_delete(benchmark1_id)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->delete_benchmark_using_delete: #{e}"
end
var apiInstance = new HydrogenNucleusApi.BenchmarkApi();
// //Delete a Benchmark
var benchid = "099d4a29-9214-46ee-80cb-8a09923dfd6d";


var deletebenchmark = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully.');
    }
};
apiInstance.deleteBenchmarkUsingDelete(benchid, deletebenchmark)

Response (204 No Content)

Permanently delete a benchmark. The benchmark_id must be provided. To obtain the appropriate benchmark_id, use the GET /benchmark endpoint to view all of the benchmarks defined firm-wide. This deletes the benchmark_id and the benchmark record. To mark the benchmark as inactive so that it is no longer used without deleting it, you can use the PUT /benchmark endpoint to change the is_active field to false.

HTTP REQUEST

DELETE /benchmark/{benchmark_id}

Benchmark Activity

List all benchmark asset sizes

Example Request

curl -X GET -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/benchmark/d79bb3a3-f259-430c-8fa8-a93f87cc3bdf/asset_size"
api_instance = nucleus_api.BenchmarkApi(nucleus_api.ApiClient(configuration))
try:
    api_response = api_instance.get_benchmark_asset_size_all_using_get("fceee415-73bb-4efd-af23-42f47009ae24")
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_benchmark_asset_size_all_using_get: %s\n" % e)
BenchmarkApi apiInstance = new BenchmarkApi();
        try {
            Object benchmark = apiInstance.getBenchmarkAssetSizeAllUsingGet(UUID.fromString("fcd65db8-2e9e-4be4-94b4-85f32fe4b6ac"), date2, null, date1);
            System.out.println(benchmark);
        } catch (ApiException e) {
            System.err.println("Exception when calling getBenchmarkAssetSizeAllUsingGet");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\BenchmarkApi(
    new GuzzleHttp\Client(),
    $config
);
$benchmark_id = "fcd65db8-2e9e-4be4-94b4-85f32fe4b6ac"; // string | UUID benchmark_id
$end_date = new \DateTime("2018-04-06"); // \DateTime | end date
$sort_type = "sort_type_example"; // string | sort_type
$start_date = new \DateTime("2018-04-06"); // \DateTime | start date

try {
    $benchmarkasset = $apiInstance->getBenchmarkAssetSizeAllUsingGet($benchmark_id, $end_date, $sort_type, $start_date);
    print_r($benchmarkasset);
} catch (Exception $e) {
    echo 'Exception when calling BenchmarkApi->getBenchmarkAssetSizeAllUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::BenchmarkApi.new
benchmark_id = 'fcd65db8-2e9e-4be4-94b4-85f32fe4b6ac' # String | UUID benchmark_id

opts = {
    end_date: Date.parse('2013-10-20'), # Date | end date
    sort_type: null, # String | sort_type
    start_date: Date.parse('2013-10-20') # Date | start date
}

begin
  asset = api_instance.get_benchmark_asset_size_all_using_get(benchmark_id, opts)
  p asset
rescue NucleusApi::ApiError => e
  puts "Exception when calling BenchmarkApi->get_benchmark_asset_size_all_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.BenchmarkApi();
var opts = {
    'endDate': "2018-07-25",
    'startDate': "2020-09-10",
    'ascending': false, // Boolean | ascending
    // 'filter': "", // String | filter
    'orderBy': "update_date", // String | order_by
    'page': 0, // Number | page
    'size': 25 // Number | size

};
var benchmarkasset = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.getBenchmarkAssetSizeAllUsingGet("d919084a-92d0-4ed5-bcce-16d7cf3153fc", opts)

Example Response

[
    {
        "date": "2018-02-03",
        "value": 100.1,
    },
        {
        "date": "2018-02-04",
        "value": 100.2,
    },
        {
        "date": "2018-02-05",
        "value": 100.3,
    }
]

Get a list of asset sizes by date for a benchmark. Asset size records are calculated using the securities and their weights in the composition of the particular benchmark_id and the security prices. Benchmark asset size represents the “growth of a dollar” rather than a monetary amount. The unique benchmark_id must be provided. To obtain the appropriate benchmark_id, use the GET /benchmark endpoint to view the benchmarks defined for your tenant. The endpoint returns a list of asset sizes by date for the benchmark. Additional parameters available to narrow down what is returned include date range, only obtaining the latest record, and sorting by different units of time (eg. annually, quarterly, monthly, daily).

HTTP REQUEST

GET /benchmark/{benchmark_id}/asset_size

ARGUMENTS

Parameter Type Required Description
get_latest boolean optional Retrieve only the latest asset size. Defaults to false if not set
sort_type string optional Sort the asset sizes by D Daily, M Monthly, Q Quarterly, Y Yearly. Defaults to D Daily if not set. Must be capital letters
start_date date optional Start date for the data. Defaults to the first date if not set
end_date date optional End date for the data. Defaults to the last date if not set

RESPONSE

Field Type Description
date date Date for this asset size record
value double “Growth of a dollar” within the benchmark on the particular date

Decision Tree

Decision trees are designed to guide your users in determining the best course of action for them based on their objectives. For example, a decision tree can be used to determine the most suitable allocation for a client’s investment portfolio according to a goal, time horizon, risk profile etc. Decision trees can also be used to guide the order of questionnaire questions; specifically, if the question order is meant to be dynamic and may change based on a client’s responses, then a decision tree needs to be used. Decision trees consist of a series of nodes, which generally represent questionnaire question and answer combinations. These nodes are linked together via node relationships. Each decision tree has an initial node. This node is mapped to a child node via a node relationship. The child node is then mapped to a subsequent child node via another node relationship, and so on. Certain nodes will be end nodes, or “leaves”, and those can be mapped to allocation(s) or models if applicable. These final node relationship in a branch of a decision tree is identified with an is_leaf flag, where true indicates that the child_node in the node relationship is the end node.

Tree Management

Field Type Description
id UUID The id of the decision tree
name string Name of the decision tree
category string A category for the decision tree such as “Onboarding” or “Risk Profile”
subcategory string A subcategory for the decision tree such as “Income-related”
description string Description for the decision tree such as “Tree to allocate clients to taxable portfolios”
is_active boolean Indicates if the tree is active. Defaults to true which indicates that it is currently active
metadata map Custom information associated with the entity in the format key:value
See Metadata
secondary_id string Alternate id that can be used to identify the object such as an internal id
create_date timestamp Timestamp for the date and time that the record was created
update_date timestamp Timestamp for the date and time that the record was last updated

List all decision trees

Example Request

curl -X GET -H "Authorization: Bearer 921c2e12-c3c3-4fe5-b8cc-2035d39ad44e" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/decision_tree"
DecisionTreeApi apiInstance = new DecisionTreeApi();
        try {
            PageDecisionTree List = apiInstance.getDecisionTreeAllUsingGet(true, null, null, 0, 10);
            System.out.println(List);
        } catch (ApiException e) {
            System.err.println("Exception when calling getDecisionTreeAllUsingGet");
            e.printStackTrace();
        }
api_instance = nucleus_api.DecisionTreeApi(nucleus_api.ApiClient(configuration))
try:
    api_response = api_instance.get_decision_tree_all_using_get()
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_decision_tree_all_using_get: %s\n" % e)
$apiInstance = new com\hydrogen\nucleus\Api\DecisionTreeApi(
    new GuzzleHttp\Client(),
    $config);
$ascending = false; // bool | ascending
$filter = null; // string | filter
$order_by = null; // string | order_by
$page = 0; // int | page
$size = 10; // int | size

try {
    $decisiontreelist = $apiInstance->getDecisionTreeAllUsingGet($ascending, $filter, $order_by, $page, $size);
    print_r($decisiontreelist);
} catch (Exception $e) {
    echo 'Exception when calling DecisionTreeApi->getDecisionTreeAllUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::DecisionTreeApi.new
opts = {
    ascending: false, # BOOLEAN | ascending
    filter: null, # String | filter
    order_by: null, # String | order_by
    page: 0, # Integer | page
    size: 25 # Integer | size
}

begin
  result = api_instance.get_decision_tree_all_using_get(opts)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling DecisionTreeApi->get_decision_tree_all_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.DecisionTreeApi();
var opts = {
    'ascending': false, // Boolean | ascending
    'filter': null, // String | filter
    'orderBy': null, // String | order_by
    'page': 0, // Number | page
    'size': 25 // Number | size
};

var decisiontreelist = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.getDecisionTreeAllUsingGet(opts, decisiontreelist)

Example Response

{
    "content": [
        {
            "id": "28021071-bece-400b-a0f6-23fb13adfcd3",
            "create_date": "2018-03-26T19:49:47.000+0000",
            "update_date": "2018-03-26T19:49:47.000+0000",
            "name": "Retirement Account Tree",
            "category": "Retirement Profile",
            "subcategory": "Income-related",
            "description": "Decision tree which allocates people looking to open a retirement account",
            "is_active": true,
            "metadata": {}
        },
        {
            "id": "0a5b1bf9-1e22-4eb2-b366-abacefc7a23b",
            "create_date": "2018-03-23T16:31:24.000+0000",
            "update_date": "2018-03-23T16:31:24.000+0000",
            "name": "Retirement Account Tree",
            "category": "Retirement Profile",
            "subcategory": "Income-related",
            "description": "Decision tree which allocates people looking to open a retirement account",
            "is_active": true,
            "metadata": {}
        },
        {
            "id": "0e62f776-b9e9-43cb-8e37-00d8b5133eee",
            "create_date": "2018-03-23T16:24:07.000+0000",
            "update_date": "2018-03-23T16:24:07.000+0000",
            "name": "Retirement Account Tree",
            "category": "Retirement Profile",
            "subcategory": "Income-related",
            "description": "Decision tree which allocates people looking to open a retirement account",
            "is_active": true,
            "metadata": {}
        }
    ],
    "total_pages": 1,
    "total_elements": 3,
    "last": true,
    "first": true,
    "sort": [
        {
          "direction": "DESC",
          "property": "id",
          "ignore_case": false,
          "null_handling": "NATIVE",
          "ascending": false,
          "descending": true
        }
    ],
    "number_of_elements": 1,
    "size": 25,
    "number": 0
}

Get the information for all decision trees defined for your tenant. The endpoint returns the id and the description details for each decision tree.

HTTP REQUEST

GET /decision_tree

Create a decision tree

Example Request

curl -X POST -H "Authorization: Bearer 921c2e12-c3c3-4fe5-b8cc-2035d39ad44e" \
      -H "Content-Type: application/json" \
      -d '{
              "name": "Retirement Account Tree",
              "category": "Retirement Profile",
              "subcategory": "Income-related",
              "description": "Decision tree which allocates people looking to open a retirement account"
          }' "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/decision_tree"
api_instance = nucleus_api.DecisionTreeApi(nucleus_api.ApiClient(configuration))
# # Create a DecisionTree
dtree = nucleus_api.DecisionTree(name="New Tree", description="Tree")
try:
    api_response = api_instance.create_decision_tree_using_post(dtree)
    pprint(api_response)
except ApiException as e:
    print("create_decision_tree_using_post: %s\n" % e)
DecisionTreeApi apiInstance = new DecisionTreeApi();
        //Create a Decision Tree
        DecisionTree dtree = new DecisionTree();
        dtree.setName("Abc");
        dtree.setDescription("One A");


        try {
            DecisionTree result = apiInstance.createDecisionTreeUsingPost(dtree);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling createDecisionTreeUsingPost");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\DecisionTreeApi(
    new GuzzleHttp\Client(),
    $config);
//Create Decision Tree
$dtree = new \com\hydrogen\nucleus\Model\DecisionTree();

try {
    $dtree->setName("ABC");
    $dtree->setDescription("New");
    $result = $apiInstance->createDecisionTreeResultUsingPost($dtree);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->createDecisionTreeResultUsingPost: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::DecisionTreeApi.new
#Create Dtree
dtree = NucleusApi::DecisionTree.new

begin
  dtree.name = "New"
  dtree.description = "ABC"
  result = api_instance.create_decision_tree_using_post(dtree)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->create_decision_tree_using_post: #{e}"
end
var apiInstance = new HydrogenNucleusApi.DecisionTreeApi();
//Create a DecisionTree
var dtree = new HydrogenNucleusApi.DecisionTree();
dtree.name = "New";
dtree.description = "Dtree";


var newdtree = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.createDecisionTreeUsingPost(dtree, newdtree)

Example Response

{
    "id": "28021071-bece-400b-a0f6-23fb13adfcd3",
    "create_date": "2018-03-26T19:49:47.000+0000",
    "name": "Retirement Account Tree",
    "category": "Retirement Profile",
    "subcategory": "Income-related",
    "description": "Decision tree which allocates people looking to open a retirement account",
    "is_active": true,
    "metadata": {}
}

Create a new decision tree for your tenant. The create_date will default to the current date. The endpoint returns a decision_tree_id used to manage the decision tree and assign it to other entities.

HTTP REQUEST

POST /decision_tree

ARGUMENTS

Parameter Type Required Description
name string required Name of the decision tree
category string optional A category for the decision tree such as “Onboarding” or “Risk Profile”
subcategory string optional A subcategory for the decision tree such as “Income-related”
description string optional Description for the decision tree such as “Tree to allocate clients to taxable portfolios”
is_active boolean optional Indicates if the tree is active. Defaults to true which indicates that it is currently active
metadata map optional Custom information associated with the entity in the format key:value
See Metadata
secondary_id string optional Alternate id that can be used to identify the object such as an internal id

Retrieve a decision tree

Example Request

curl -X GET -H "Authorization: Bearer 921c2e12-c3c3-4fe5-b8cc-2035d39ad44e" \
      "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/decision_tree/28021071-bece-400b-a0f6-23fb13adfcd3"
DecisionTreeApi apiInstance = new DecisionTreeApi();
        try {
            DecisionTree responseTree = apiInstance.getDecisionTreeUsingGet(UUID.fromString("930c6ae6-0ca2-49c7-9d20-963d3a92895e"));
            System.out.println(responseTree);
        } catch (ApiException e) {
            System.err.println("Exception when calling getDecisionTreeUsingGet");
            e.printStackTrace();
        }
api_instance = nucleus_api.DecisionTreeApi(nucleus_api.ApiClient(configuration))
try:
    api_response = api_instance.get_decision_tree_using_get("f1c46c6e-7270-4b7b-b49d-0dca01731014")
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_decision_tree_using_get: %s\n" % e)
$apiInstance = new com\hydrogen\nucleus\Api\DecisionTreeApi(
    new GuzzleHttp\Client(),
    $config);
$decision_tree_id = "930c6ae6-0ca2-49c7-9d20-963d3a92895e"; // string | UUID decision_tree_id

try {
    $decisiontree = $apiInstance->getDecisionTreeUsingGet($decision_tree_id);
    print_r($decisiontree);
} catch (Exception $e) {
    echo 'Exception when calling DecisionTreeApi->getDecisionTreeUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::DecisionTreeApi.new
decision_tree_id = '930c6ae6-0ca2-49c7-9d20-963d3a92895e' # String | UUID decision_tree_id
begin
  decisiontree = api_instance.get_decision_tree_using_get(decision_tree_id)
  p decisiontree
rescue NucleusApi::ApiError => e
  puts "Exception when calling DecisionTreeApi->get_decision_tree_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.DecisionTreeApi();
var decisiontreeid = "930c6ae6-0ca2-49c7-9d20-963d3a92895e";


var decisiontree = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.getDecisionTreeUsingGet(decisiontreeid, decisiontree)

Example Response

{
    "id": "28021071-bece-400b-a0f6-23fb13adfcd3",
    "create_date": "2018-03-26T19:49:47.000+0000",
    "update_date": "2018-03-26T19:49:47.000+0000",
    "name": "Retirement Account Tree",
    "category": "Retirement Profile",
    "subcategory": "Income-related",
    "description": "Decision tree which allocates people looking to open a retirement account",
    "is_active": true,
    "metadata": {}
}

Retrieve the information for a decision tree. The decision_tree_id must be provided. This endpoint returns the decision_tree_id and the details for the decision tree specified.

HTTP REQUEST

GET /decision_tree/{decision_tree_id}

Update a decision tree

Example Request

curl -X PUT -H "Authorization: Bearer 921c2e12-c3c3-4fe5-b8cc-2035d39ad44e" \
      -H "Content-Type: application/json" \
      -d '{
              "name": "Retirement Account Tree",
              "category": "Retirement Profile",
              "subcategory": "Income-related",
              "description": "Decision tree which allocates people looking to open a retirement account"
          }' "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/decision_tree/28021071-bece-400b-a0f6-23fb13adfcd3"
api_instance = nucleus_api.DecisionTreeApi(nucleus_api.ApiClient(configuration))
# #Update DecisionTree
dtree_update = {'name': 'Tree One'}
dtree_id = 'b170b979-eaa3-4651-8532-951d13021dda'
try:
    api_response = api_instance.update_decision_tree_using_put(dtree_update, dtree_id)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling update_decision_tree_using_put: %s\n" % e)
DecisionTreeApi apiInstance = new DecisionTreeApi();
        //Update a DecisionTree
        Map map = new HashMap();
        map.put("name", "abc");

        try {
            DecisionTree response = apiInstance.updateDecisionTreeUsingPut(map, UUID.fromString("a05b8b81-06e6-42a5-ae15-ec1bccc6195a"));
            System.out.println(response);
        } catch (ApiException e) {
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\DecisionTreeApi(
    new GuzzleHttp\Client(),
    $config);
//Update DTree
$dtree_update = new stdClass();
$dtree_id = "d24b1c01-c210-4792-89a5-d36673ace959";

try {
    $dtree_update->description = "ABC";
    $result = $apiInstance->updateDecisionTreeUsingPut($dtree_update, $dtree_id);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->updateDecisionTreeUsingPut: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::DecisionTreeApi.new
#Update DTree
dtree_update = {"name" => 'GBP'}
dtree_id = '6b9e9d7e-d6ef-41d7-8cba-2b6588951a05'
begin
  result = api_instance.update_decision_tree_using_put(dtree_update, dtree_id)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->update_decision_tree_using_put: #{e}"
end
var apiInstance = new HydrogenNucleusApi.DecisionTreeApi();
//Update Dtree
var apiInstance = new HydrogenNucleusApi.DecisionTreeApi();
var callback = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
var dtreeupdate = new HydrogenNucleusApi.DecisionTree();
var dtreeid = 'a05b8b81-06e6-42a5-ae15-ec1bccc6195a';

dtreeupdate.category = "New";
apiInstance.updateDecisionTreeUsingPut(dtreeupdate, dtreeid, callback)

Example Response

{
    "id": "28021071-bece-400b-a0f6-23fb13adfcd3",
    "create_date": "2018-03-26T19:49:47.000+0000",
    "update_date": "2018-03-26T19:49:47.000+0000",
    "name": "Retirement Account Tree",
    "category": "Retirement Profile",
    "subcategory": "Income-related",
    "description": "Decision tree which allocates people looking to open a retirement account",
    "is_active": true,
    "metadata": {}
}

Updated the information for a decision tree. The decision_tree_id must be provided. To obtain the appropriate decision_tree_id, use the GET /decision_tree endpoint to view all decision trees defined for your tenant and their current information. The details to be updated must also be provided. This endpoint returns the decision_tree_id and the details for the decision tree.

HTTP REQUEST

PUT /decision_tree/{decision_tree_id}

Delete a decision tree

Example Request

curl -X DELETE -H "Authorization: Bearer 921c2e12-c3c3-4fe5-b8cc-2035d39ad44e" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/decision_tree/28021071-bece-400b-a0f6-23fb13adfcd3"
api_instance = nucleus_api.DecisionTreeApi(nucleus_api.ApiClient(configuration))
# # Delete a DecisionTree
dtreen_id = '402c714c-93d8-4b6e-ae6e-2c2a44e0dc60'
try:
    api_instance.delete_decision_tree_using_delete(dtreen_id)
except ApiException as e:
    print("Exception when delete_decision_tree_using_delete: %s\n" % e)
DecisionTreeApi apiInstance = new DecisionTreeApi();
        //Delete a DecisionTree
        try {
            DecisionTree responseDelete = apiInstance.deleteDecisionTreeUsingDelete(UUID.fromString(""));
            System.out.println(responseDelete);
        } catch (ApiException e) {
            System.err.println("Exception when calling deleteDecisionTreeUsingDelete");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\DecisionTreeApi(
    new GuzzleHttp\Client(),
    $config);

//Delete Dtree
$dtree_did = "592aeae8-1501-4bd0-a69c-b847932296db"; // string | UUID account_id

try {
    $apiInstance->deleteDecisionTreeUsingDelete($dtree_did);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->deleteDecisionTreeUsingDelete: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::DecisionTreeApi.new
#Delete Dtree
dtree1_id = '06a96780-10b1-4d3c-9a37-1cce1ad5a7a3'
begin
  result = api_instance.delete_decision_tree_using_delete(dtree1_id)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->delete_decision_tree_using_delete: #{e}"
end
var apiInstance = new HydrogenNucleusApi.DecisionTreeApi();
// //Delete a Dtree
var dtreed = "06a96780-10b1-4d3c-9a37-1cce1ad5a7a3";


var deletedtree = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully.');
    }
};
apiInstance.deleteDecisionTreeUsingDelete(dtreed, deletedtree)

Response (204 No Content)

Permanently delete a decision tree. The decision_tree_id must be provided. To obtain the appropriate decision_tree_id, use the GET /decision_tree endpoint to view all decision trees defined for your tenant. This deletes the decision_tree_id and the details for the decision tree.

HTTP REQUEST

DELETE /decision_tree/{decision_tree_id}

Nodes

Nodes correspond to question and answer combinations along a decision tree that a client must answer, usually as part of a questionnaire. Nodes are linked together in parent-child relationships to create a branch of a decision tree. The first node of a branch is used to map to the first question of a questionnaire. When creating a decision tree, you should create a node corresponding to each question in the questionnaire and the possible answer combinations for the questions before the current question. The last node along the branch is the end node and maps to one or more allocations or models.

Field Type Description
id UUID The id of the node
name string Name of the node
is_first boolean Indicates if this is the first node of the decision tree. Defaults to false meaning it is not the first node
question_id UUID The id of the question that corresponds to this node
metadata map Custom information associated with the entity in the format key:value
See Metadata
secondary_id string Alternate id that can be used to identify the object such as an internal id
create_date timestamp Timestamp for the date and time that the record was created
update_date timestamp Timestamp for the date and time that the record was last updated

List all nodes

Example Request

curl -X GET -H "Authorization: Bearer 921c2e12-c3c3-4fe5-b8cc-2035d39ad44e" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/node"
DecisionTreeApi apiInstance = new DecisionTreeApi();
        try {
            PageNode List = apiInstance.getNodeAllUsingGet(true, null, null, 0, 10);
            System.out.println(List);
        } catch (ApiException e) {
            System.err.println("Exception when calling getNodeAllUsingGet");
            e.printStackTrace();
        }
api_instance = nucleus_api.DecisionTreeApi(nucleus_api.ApiClient(configuration))
try:
    api_response = api_instance.get_node_all_using_get()
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_node_all_using_get: %s\n" % e)
$apiInstance = new com\hydrogen\nucleus\Api\DecisionTreeApi(
    new GuzzleHttp\Client(),
    $config);
$ascending = false; // bool | ascending
$filter = null; // string | filter
$order_by = null; // string | order_by
$page = 0; // int | page
$size = 10; // int | size

try {
    $nodeslist = $apiInstance->getNodeAllUsingGet($ascending, $filter, $order_by, $page, $size);
    print_r($nodeslist);
} catch (Exception $e) {
    echo 'Exception when calling DecisionTreeApi->getNodeAllUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::DecisionTreeApi.new
opts = {
    ascending: false, # BOOLEAN | ascending
    filter: null, # String | filter
    order_by: null, # String | order_by
    page: 0, # Integer | page
    size: 25 # Integer | size
}

begin
  nodelist = api_instance.get_node_all_using_get(opts)
  p nodelist
rescue NucleusApi::ApiError => e
  puts "Exception when calling DecisionTreeApi->get_node_all_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.DecisionTreeApi();
var opts = {
    'ascending': false, // Boolean | ascending
    'filter': null, // String | filter
    'orderBy': null, // String | order_by
    'page': 0, // Number | page
    'size': 25 // Number | size
};

var nodelist = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.getNodeAllUsingGet(opts, nodelist)

Example Response

{
    "content": [
        {
            "id": "05b9f2e6-aabc-44b5-8e02-f1ab216ebd62",
            "create_date": "2018-03-26T19:50:51.000+0000",
            "update_date": "2018-03-26T19:50:51.000+0000",
            "name": "What is your age?",
            "question_id": "286ddd93-4fed-4e01-b26b-838813212c34",
            "is_first": false,
            "metadata": {}
        },
        {
            "id": "0faa837e-370d-4721-8cbc-e2e167d973d9",
            "create_date": "2018-03-26T19:50:51.000+0000",
            "update_date": "2018-03-26T19:50:51.000+0000",
            "name": "What is your annual income in dollars?",
            "question_id": "286ddd93-4fed-4e01-b26b-838813212c34",
            "is_first": false,
            "metadata": {}
        },
        {
            "id": "1154c13c-0f5b-4c39-80ac-196633169a2e",
            "create_date": "2018-03-26T19:50:51.000+0000",
            "update_date": "2018-03-26T19:50:51.000+0000",
            "name": "What is your risk tolerance?",
            "question_id": "286ddd93-4fed-4e01-b26b-838813212c34",
            "is_first": false,
            "metadata": {}
        }
    ],
    "total_pages": 1,
    "total_elements": 3,
    "last": false,
    "number_of_elements": 25,
    "first": true,
    "sort": [
        {
            "direction": "DESC",
            "property": "updateDate",
            "ignore_case": false,
            "null_handling": "NATIVE",
            "descending": true,
            "ascending": false
        }
    ],
    "size": 25,
    "number": 0
}

List all nodes that are defined for your tenant. The endpoint returns the node_id and the details for the node.

HTTP REQUEST

GET /node

Create a node

Example Request

curl -X POST -H "Authorization: Bearer 921c2e12-c3c3-4fe5-b8cc-2035d39ad44e" \
      -H "Content-Type: application/json" \
      -d '{
              "name": "What is your annual income in dollars?",
              "question_id": "286ddd93-4fed-4e01-b26b-838813212c34",
              "is_first": false
          }' "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/node"
api_instance = nucleus_api.DecisionTreeApi(nucleus_api.ApiClient(configuration))
# # # Create a Node
node = nucleus_api.Node(name="New One", question_id="2eef250b-f772-4259-91ef-18886a68b050", is_first="true")
try:
    api_response = api_instance.create_node_using_post(node)
    pprint(api_response)
except ApiException as e:
    print("create_node_using_post: %s\n" % e)
DecisionTreeApi apiInstance = new DecisionTreeApi();
        //Create a Node
        Node node = new Node();
        node.setName("NEw");
        node.setQuestionId(UUID.fromString("3287f986-3649-422a-8af1-c320e995bc74"));

        try {
            Node result = apiInstance.createNodeUsingPost(node);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling createNodeUsingPost");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\DecisionTreeApi(
    new GuzzleHttp\Client(),
    $config);

//Create Node
$node = new \com\hydrogen\nucleus\Model\Node();

try {
    $node->setQuestionId("3287f986-3649-422a-8af1-c320e995bc74");
    $node->setName("New");
    $result = $apiInstance->createNodeUsingPost($node);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->createNodeUsingPost: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::DecisionTreeApi.new
#Create Node
node = NucleusApi::Node.new

begin
  node.question_id = "3287f986-3649-422a-8af1-c320e995bc74"
  node.name = "New"
  result = api_instance.create_node_using_post(node)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->create_node_using_post: #{e}"
end
var apiInstance = new HydrogenNucleusApi.DecisionTreeApi();
//Create a Node
var node = new HydrogenNucleusApi.Node();
node.name ="New A";
node.question_id = '93d24939-a6a2-4d1c-b4a0-7a4ea13742de';


var newnode = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.createNodeUsingPost(node, newnode)

Example Response

{
    "id": "05b9f2e6-aabc-44b5-8e02-f1ab216ebd62",
    "create_date": "2018-03-26T19:50:51.000+0000",
    "name": "What is your annual income in dollars?",
    "question_id": "286ddd93-4fed-4e01-b26b-838813212c34",
    "is_first": false,
    "metadata": {}
}

Create a new node for your tenant that can be used in a decision tree and mapped to other nodes. The question_id in the node must be provided. To obtain the appropriate question_id, use the GET /questionnaire/{questionnaire_id} endpoint to view all the question_ids for a questionnaire. The create_date will default to the current date. The endpoint returns a node_id used to map the node to a decision tree and to other nodes.

HTTP REQUEST

POST /node

ARGUMENTS

Parameter Type Required Description
name string required Name of the node
question_id UUID required The id of the question that corresponds to this node
is_first boolean optional Indicates if this is the first node of the decision tree. Defaults to false meaning it is not the first node
metadata map optional Custom information associated with the entity in the format key:value
See Metadata
secondary_id string optional Alternate id that can be used to identify the object such as an internal id

Retrieve a node

Example Request

curl -X GET -H "Authorization: Bearer 921c2e12-c3c3-4fe5-b8cc-2035d39ad44e" \
      "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/node/05b9f2e6-aabc-44b5-8e02-f1ab216ebd62"
DecisionTreeApi apiInstance = new DecisionTreeApi();
        try {
            Node responseNode = apiInstance.getNodeUsingGet(UUID.fromString("7631565f-cca2-4607-bb9e-49d15abd21f4"));
            System.out.println(responseNode);
        } catch (ApiException e) {
            System.err.println("Exception when calling getNodeUsingGet");
            e.printStackTrace();
        }
api_instance = nucleus_api.DecisionTreeApi(nucleus_api.ApiClient(configuration))
try:
    api_response = api_instance.get_node_using_get("c811e37f-a91c-4794-8273-7e29f1fe3e69")
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_node_using_get: %s\n" % e)
$apiInstance = new com\hydrogen\nucleus\Api\DecisionTreeApi(
    new GuzzleHttp\Client(),
    $config);
$node_id = "7631565f-cca2-4607-bb9e-49d15abd21f4"; // string | UUID node_id

try {
    $node = $apiInstance->getNodeUsingGet($node_id);
    print_r($node);
} catch (Exception $e) {
    echo 'Exception when calling DecisionTreeApi->getNodeUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::DecisionTreeApi.new
node_id = '7631565f-cca2-4607-bb9e-49d15abd21f4' # String | UUID node_id


begin
  node = api_instance.get_node_using_get(node_id)
  p node
rescue NucleusApi::ApiError => e
  puts "Exception when calling DecisionTreeApi->get_node_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.DecisionTreeApi();
var nodeid = "7631565f-cca2-4607-bb9e-49d15abd21f4";


var node = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.getNodeUsingGet(nodeid, node)

Example Response

{
    "id": "05b9f2e6-aabc-44b5-8e02-f1ab216ebd62",
    "create_date": "2018-03-26T19:50:51.000+0000",
    "update_date": "2018-03-26T19:50:51.000+0000",
    "name": "What is your annual income in dollars?",
    "question_id": "286ddd93-4fed-4e01-b26b-838813212c34",
    "is_first": false,
    "metadata": {}
}

Retrieve the information for a node. The node_id must be provided. The endpoint returns the node_id and the details for the node specified.

HTTP REQUEST

GET /node/{node_id}

Update a node

Example Request

curl -X PUT -H "Authorization: Bearer 921c2e12-c3c3-4fe5-b8cc-2035d39ad44e" \
      -H "Content-Type: application/json" \
      -d '{
              "name": "What is your annual income in dollars?",
              "question_id": "286ddd93-4fed-4e01-b26b-838813212c34",
              "is_first": false
          }' "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/node/05b9f2e6-aabc-44b5-8e02-f1ab216ebd62"
api_instance = nucleus_api.DecisionTreeApi(nucleus_api.ApiClient(configuration))
# # Update Node
node_update = {'name': 'Major'}
noderelation_id = '4f7395ef-efd5-4bb5-b64f-edfeeae9a387'
try:
    api_response = api_instance.update_node_using_put(node_update, noderelation_id)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling update_node_using_put: %s\n" % e)
DecisionTreeApi apiInstance = new DecisionTreeApi();
        //Update a Node
        Map map1 = new HashMap();
        map.put("name", "abc");

        try {
            Node response = apiInstance.updateNodeUsingPut(map1, UUID.fromString("19789287-fd7e-464b-b0ef-d70a9bde9c8c"));
            System.out.println(response);
        } catch (ApiException e) {
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\DecisionTreeApi(
    new GuzzleHttp\Client(),
    $config);

//Update Node
$node_update = new stdClass();
$node_id = "509caa64-5395-4065-b6e3-f0297dcac442";

try {
    $node_update->name = "ABC";
    $result = $apiInstance->updateNodeUsingPut($node_update, $node_id);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->updateNodeUsingPut: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::DecisionTreeApi.new
#Update Node
node_update = {"name" => 'New'}
node_id = 'fa05540f-1215-48d3-98ad-22e867dd6cc3'
begin
  result = api_instance.update_node_using_put(node_update, node_id)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->update_node_using_put: #{e}"
end
var apiInstance = new HydrogenNucleusApi.DecisionTreeApi();
 //Update Node
 var apiInstance = new HydrogenNucleusApi.DecisionTreeApi();
 var callback = function(error, data, response) {
     if (error) {
         console.error(error);
     } else {
         console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
     }
 };
 var nodeupdate = new HydrogenNucleusApi.Node();
 var nodeid = '5c284f9f-beac-4f84-97df-14682530782c';

 nodeupdate.name = "New A";
 apiInstance.updateNodeUsingPut(nodeupdate, nodeid, callback)

Example Response

{
    "id": "05b9f2e6-aabc-44b5-8e02-f1ab216ebd62",
    "create_date": "2018-03-26T19:50:51.000+0000",
    "update_date": "2018-03-26T19:50:51.000+0000",
    "name": "What is your annual income in dollars?",
    "question_id": "286ddd93-4fed-4e01-b26b-838813212c34",
    "is_first": false,
    "metadata": {}
}

Updated the information for a node. The node_id must be provided. To obtain the appropriate node_id, use the GET /node endpoint to view all the nodes defined for your tenant and their current information. The details to be updated must also be provided. The endpoint returns the node_id and the details for the node.

HTTP REQUEST

PUT /node/{node_id}

Delete a node

Example Request

curl -X DELETE -H "Authorization: Bearer 921c2e12-c3c3-4fe5-b8cc-2035d39ad44e" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/node/05b9f2e6-aabc-44b5-8e02-f1ab216ebd62"
api_instance = nucleus_api.DecisionTreeApi(nucleus_api.ApiClient(configuration))
# # Delete a Node
noded_id = 'f0a00c53-0f32-4401-a1f7-bac1e63a5b26'
try:
    api_instance.delete_node_using_delete(noded_id)
except ApiException as e:
    print("Exception when delete_node_using_delete: %s\n" % e)
DecisionTreeApi apiInstance = new DecisionTreeApi();
        //Delete a Node
        try {
            DecisionTree responseDelete = apiInstance.deleteNodeUsingDelete(UUID.fromString(""));
            System.out.println(responseDelete);
        } catch (ApiException e) {
            System.err.println("Exception when calling deleteNodeUsingDelete");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\DecisionTreeApi(
    new GuzzleHttp\Client(),
    $config);
//Delete Node
$node_did = "2401e944-7a34-4d92-9372-79b928aaaa1e"; // string | UUID account_id

try {
    $apiInstance->deleteNodeUsingDelete($node_did);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->deleteNodeUsingDelete: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::DecisionTreeApi.new
#Delete Node
node1_id = '509caa64-5395-4065-b6e3-f0297dcac442'
begin
  result = api_instance.delete_node_using_delete(node1_id)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->delete_node_using_delete: #{e}"
end
var apiInstance = new HydrogenNucleusApi.DecisionTreeApi();
//Delete a Node
var noded = "412215fc-518f-41e0-af74-4a270f572007";


var deletenode = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully.');
    }
};
apiInstance.deleteNodeUsingDelete(noded, deletenode)

Response (204 No Content)

Permanently delete a node. The node_id must be provided. To obtain the appropriate node_id, use the GET /node endpoint to view all the nodes defined for your tenant. This deletes the node_id and the details for the node.

HTTP REQUEST

DELETE /node/{node_id}

Node Relationships

Node relationships indicate the order in which nodes should follow each other along a decision tree branch. Each node relationship corresponds to the possible path that can be taken after a question based on the response provided by a client. The answer_id in the node relationship is used to identify the client response provided for that answer_id. You must create a node relationship for every required node-to-node flow, eventually leading to the last node of the decision tree, which maps to the corresponding allocation or model.

Field Type Description
id UUID The id of the node relationship
answer_id UUID The id of the answer to a question_id that corresponds to the node relationship
value string Value of the answer
decision_tree_id UUID The id of the decision tree to which the node relationship belongs
node_parent_id UUID The id for the parent node
node_child_id UUID The id for the child node
is_leaf boolean Indicates if the node relationship represents the last point in the decision tree branch. true indicates that the next node is the last node, and that it maps to an allocation or model
metadata map Custom information associated with the entity in the format key:value
See Metadata
secondary_id string Alternate id that can be used to identify the object such as an internal id
create_date timestamp Timestamp for the date and time that the record was created
update_date timestamp Timestamp for the date and time that the record was last updated

List all node relationships

Example Request

curl -X GET -H "Authorization: Bearer 921c2e12-c3c3-4fe5-b8cc-2035d39ad44e" \
      "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/node_relationship"
DecisionTreeApi apiInstance = new DecisionTreeApi();
        try {
            PageNodeRelationship List = apiInstance.getNodeRelationshipAllUsingGet(true, null, null, 0, 10);
            System.out.println(List);
        } catch (ApiException e) {
            System.err.println("Exception when calling getNodeRelationshipAllUsingGet");
            e.printStackTrace();
        }
api_instance = nucleus_api.DecisionTreeApi(nucleus_api.ApiClient(configuration))
try:
    api_response = api_instance.get_node_relationship_all_using_get()
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_node_relationship_all_using_get: %s\n" % e)
$apiInstance = new com\hydrogen\nucleus\Api\DecisionTreeApi(
    new GuzzleHttp\Client(),
    $config);
$ascending = false; // bool | ascending
$filter = null; // string | filter
$order_by = null; // string | order_by
$page = 0; // int | page
$size = 10; // int | size

try {
    $noderelationshiplist = $apiInstance->getNodeRelationshipAllUsingGet($ascending, $filter, $order_by, $page, $size);
    print_r($noderelationshiplist);
} catch (Exception $e) {
    echo 'Exception when calling DecisionTreeApi->getNodeRelationshipAllUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::DecisionTreeApi.new
opts = {
    ascending: false, # BOOLEAN | ascending
    filter: null, # String | filter
    order_by: null, # String | order_by
    page: 0, # Integer | page
    size: 25 # Integer | size
}

begin
  relationshiplist = api_instance.get_node_relationship_all_using_get(opts)
  p relationshiplist
rescue NucleusApi::ApiError => e
  puts "Exception when calling DecisionTreeApi->get_node_relationship_all_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.DecisionTreeApi();
var opts = {
    'ascending': false, // Boolean | ascending
    'filter': null, // String | filter
    'orderBy': null, // String | order_by
    'page': 0, // Number | page
    'size': 25 // Number | size
};

var noderelationlist = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.getNodeRelationshipAllUsingGet(opts, noderelationlist)

Example Response

{
  "content": [
      {
          "id": "8397d8fd-e80d-48ea-bf79-81f32b12606e",
          "create_date": "2018-03-26T19:54:31.000+0000",
          "update_date": "2018-03-26T19:54:31.000+0000",
          "node_parent_id": "05b9f2e6-aabc-44b5-8e02-f1ab216ebd62",
          "node_child_id": "d5011ba6-50c6-427b-a29c-b7802a2c8660",
          "answer_id": "556cedaa-37ba-4dc7-ad03-0990b9252e1d",
          "value": "high",
          "is_leaf": false,
          "decision_tree_id": "28021071-bece-400b-a0f6-23fb13adfcd3",
          "metadata": {}
      },
      {
          "id": "c7114848-d17f-420e-b73b-53a5b8fca9d9",
          "create_date": "2018-03-26T19:54:31.000+0000",
          "update_date": "2018-03-26T19:54:31.000+0000",
          "node_parent_id": "05b9f2e6-aabc-44b5-8e02-f1ab216ebd62",
          "node_child_id": "df9b27e4-f619-4deb-b207-5635dbb15bb4",
          "answer_id": "0217b35e-36fe-4796-8e7f-61e93e9e6ef5",
          "value": "medium",
          "is_leaf": false,
          "decision_tree_id": "28021071-bece-400b-a0f6-23fb13adfcd3",
          "metadata": {}
      },
      {
          "id": "84f29454-498b-4785-91ac-1f9af0c686c6",
          "create_date": "2018-03-26T19:54:28.000+0000",
          "update_date": "2018-03-26T19:54:28.000+0000",
          "node_parent_id": "05b9f2e6-aabc-44b5-8e02-f1ab216ebd62",
          "node_child_id": "a787a485-555b-4463-af83-d3643a767d96",
          "answer_id": "0217b35e-36fe-4796-8e7f-61e93e9e6ef5",
          "value": "low",
          "is_leaf": true,
          "decision_tree_id": "28021071-bece-400b-a0f6-23fb13adfcd3",
          "metadata": {}
      }
  ],
  "total_pages": 1,
  "last": true,
  "total_elements": 3,
  "first": true,
  "sort": [
    {
      "direction": "DESC",
      "property": "id",
      "ignore_case": false,
      "null_handling": "NATIVE",
      "ascending": false,
      "descending": true
    }
  ],
  "number_of_elements": 1,
  "size": 25,
  "number": 0
}

Get the information for all the node relationships defined for your tenant. The endpoint returns a list of UUIDs and the details for all node relationships.

HTTP REQUEST

GET /node_relationship

Create a node relationship

Example Request

curl -X POST -H "Authorization: Bearer 921c2e12-c3c3-4fe5-b8cc-2035d39ad44e" \
      -H "Content-Type: application/json" \
      -d '{
              "node_parent_id": "05b9f2e6-aabc-44b5-8e02-f1ab216ebd62",
              "node_child_id": "d5011ba6-50c6-427b-a29c-b7802a2c8660",
              "answer_id": "556cedaa-37ba-4dc7-ad03-0990b9252e1d",
              "value": "high",
              "is_leaf": false,
              "decision_tree_id": "28021071-bece-400b-a0f6-23fb13adfcd3"
          }' "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/node_relationship"
api_instance = nucleus_api.DecisionTreeApi(nucleus_api.ApiClient(configuration))
# # Create a NodeRelationShip
node_relationship = nucleus_api.NodeRelationship(answer_id="fac351fa-6173-47b7-8611-1fc2dad4fdca", value="One", decision_tree_id="b170b979-eaa3-4651-8532-951d13021dda", node_parent_id="fa05540f-1215-48d3-98ad-22e867dd6cc3")
try:
    api_response = api_instance.create_node_relationship_using_post(node_relationship)
    pprint(api_response)
except ApiException as e:
    print("create_node_relationship_using_post: %s\n" % e)
DecisionTreeApi apiInstance = new DecisionTreeApi();
        //Create a Node RelationShip
        NodeRelationship noderelation = new NodeRelationship();
        noderelation.setAnswerId(UUID.fromString("f4a11447-784f-4e19-94ba-228ecaf7c4c0"));
        noderelation.setValue("New");
        noderelation.setDecisionTreeId(UUID.fromString("6b9e9d7e-d6ef-41d7-8cba-2b6588951a05"));
        noderelation.setNodeParentId(UUID.fromString("f0a00c53-0f32-4401-a1f7-bac1e63a5b26"));

        try {
            NodeRelationship result = apiInstance.createNodeRelationshipUsingPost(noderelation);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling createNodeRelationshipUsingPost");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\DecisionTreeApi(
    new GuzzleHttp\Client(),
    $config);

//Create NodeRelationship
$node_relation = new \com\hydrogen\nucleus\Model\NodeRelationship();

try {
    $node_relation->setAnswerId("f4a11447-784f-4e19-94ba-228ecaf7c4c0");
    $node_relation->setDecisionTreeId("6b9e9d7e-d6ef-41d7-8cba-2b6588951a05");
    $node_relation->setNodeParentId("f0a00c53-0f32-4401-a1f7-bac1e63a5b26");
    $node_relation->setValue("ABc");
    $result = $apiInstance->createNodeRelationshipUsingPost($node_relation);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->createNodeRelationshipUsingPost: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::DecisionTreeApi.new
#Create Node Relationship
node_relation = NucleusApi::NodeRelationship.new

begin
  node_relation.node_parent_id = "f0a00c53-0f32-4401-a1f7-bac1e63a5b26"
  node_relation.decision_tree_id = "6b9e9d7e-d6ef-41d7-8cba-2b6588951a05"
  node_relation.answer_id = "f4a11447-784f-4e19-94ba-228ecaf7c4c0"
  node_relation.value = "One"
  result = api_instance.create_node_relationship_using_post(node_relation)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->create_node_relationship_using_post: #{e}"
end
var apiInstance = new HydrogenNucleusApi.DecisionTreeApi();
//Create a Node Relationship
var noderelation = new HydrogenNucleusApi.NodeRelationship();
noderelation.answer_id = 'a5eec1b0-0df0-455b-b94b-a7a23f991139';
noderelation.decision_tree_id = 'a05b8b81-06e6-42a5-ae15-ec1bccc6195a';
noderelation.node_parent_id = '0a33bced-465c-431e-b201-fe7b42a14b48';
noderelation.value = "abc";



var newnoderelation = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.createNodeRelationshipUsingPost(noderelation, newnoderelation)

Example Response

{
    "id": "8397d8fd-e80d-48ea-bf79-81f32b12606e",
    "create_date": "2018-03-26T19:54:31.000+0000",
    "node_parent_id": "05b9f2e6-aabc-44b5-8e02-f1ab216ebd62",
    "node_child_id": "d5011ba6-50c6-427b-a29c-b7802a2c8660",
    "answer_id": "556cedaa-37ba-4dc7-ad03-0990b9252e1d",
    "value": "high",
    "is_leaf": false,
    "decision_tree_id": "28021071-bece-400b-a0f6-23fb13adfcd3",
    "metadata": {}
}

Create a new node relationship for your tenant. The answer_id, the node_id of the parent node, the node_id of the child node and the decision_tree_id must be provided. To obtain the appropriate answer_id, use the GET /questionnaire/{questionnaire_id} endpoint to view all the answer_ids for a questionnaire. To obtain the appropriate node_ids, use the GET /node endpoint to view all the nodes defined for your tenant. To obtain the appropriate decision_tree_id, use the GET /decision_tree endpoint to view all the decision trees defined for your tenant. The endpoint returns a node_relationship_id used to store the mapping between two nodes, as well as the last node to an allocation or model (if applicable).

HTTP REQUEST

POST /node_relationship

ARGUMENTS

Parameter Type Required Description
answer_id UUID required The id of the answer to a question_id that corresponds to the node relationship
value string required Value of the answer
decision_tree_id UUID required The id of the decision tree to which the node relationship belongs
node_parent_id UUID required The id for the parent node.
node_child_id UUID optional The id for the child node.
is_leaf boolean optional Indicator if the node relationship represents the last point in the decision tree branch. true indicates it is the last point and that is maps to an allocation or model
metadata map optional Custom information associated with the entity in the format key:value
See Metadata
secondary_id string optional Alternate id that can be used to identify the object such as an internal id

Retrieve a node relationship

Example Request

curl -X GET -H "Authorization: Bearer 921c2e12-c3c3-4fe5-b8cc-2035d39ad44e" \
      "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/node_relationship/8397d8fd-e80d-48ea-bf79-81f32b12606e"
DecisionTreeApi apiInstance = new DecisionTreeApi();
        try {
            NodeRelationship responseRelationship = apiInstance.getNodeRelationshipUsingGet(UUID.fromString("1452b959-2fba-4645-9d4d-bbaac5b91d5b"));
            System.out.println(responseRelationship);
        } catch (ApiException e) {
            System.err.println("Exception when calling getNodeRelationshipUsingGet");
            e.printStackTrace();
        }
api_instance = nucleus_api.DecisionTreeApi(nucleus_api.ApiClient(configuration))
try:
    api_response = api_instance.get_node_relationship_using_get("ea239ece-568c-4373-9908-5b945d23ccf1")
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_node_relationship_using_get: %s\n" % e)
$apiInstance = new com\hydrogen\nucleus\Api\DecisionTreeApi(
    new GuzzleHttp\Client(),
    $config);
$node_relationship_id = "1452b959-2fba-4645-9d4d-bbaac5b91d5b"; // string | UUID node_relationship_id

try {
    $noderelationship = $apiInstance->getNodeRelationshipUsingGet($node_relationship_id);
    print_r($noderelationship);
} catch (Exception $e) {
    echo 'Exception when calling DecisionTreeApi->getNodeRelationshipUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::DecisionTreeApi.new
node_relationship_id = '1452b959-2fba-4645-9d4d-bbaac5b91d5b' # String | UUID node_relationship_id


begin
  relationship = api_instance.get_node_relationship_using_get(node_relationship_id)
  p relationship
rescue NucleusApi::ApiError => e
  puts "Exception when calling DecisionTreeApi->get_node_relationship_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.DecisionTreeApi();
var noderelationid = "1452b959-2fba-4645-9d4d-bbaac5b91d5b";


var noderelation = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.getNodeRelationshipUsingGet(noderelationid, noderelation)

Example Response

{
    "id": "8397d8fd-e80d-48ea-bf79-81f32b12606e",
    "create_date": "2018-03-26T19:54:31.000+0000",
    "update_date": "2018-03-26T19:54:31.000+0000",
    "node_parent_id": "05b9f2e6-aabc-44b5-8e02-f1ab216ebd62",
    "node_child_id": "d5011ba6-50c6-427b-a29c-b7802a2c8660",
    "answer_id": "556cedaa-37ba-4dc7-ad03-0990b9252e1d",
    "value": "high",
    "is_leaf": false,
    "decision_tree_id": "28021071-bece-400b-a0f6-23fb13adfcd3",
    "metadata": {}
}

Retrieve the information for a node relationship. The node_relationship_id must be provided. The endpoint returns the node_relationship_id and the details for the node relationship specified.

HTTP REQUEST

GET /node_relationship/{node_relationship_id}

Update a node relationship

Example Request

curl -X PUT -H "Authorization: Bearer 921c2e12-c3c3-4fe5-b8cc-2035d39ad44e" \
      -H "Content-Type: application/json" \
      -d '{
              "node_parent_id": "05b9f2e6-aabc-44b5-8e02-f1ab216ebd62",
              "node_child_id": "d5011ba6-50c6-427b-a29c-b7802a2c8660",
              "answer_id": "556cedaa-37ba-4dc7-ad03-0990b9252e1d",
              "value": "high",
              "is_leaf": true,
              "decision_tree_id": "28021071-bece-400b-a0f6-23fb13adfcd3"
        }' "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/node_relationship/8397d8fd-e80d-48ea-bf79-81f32b12606e"
api_instance = nucleus_api.DecisionTreeApi(nucleus_api.ApiClient(configuration))
# # Update NodeRelationShip
noderelation_update = {'is_leaf': 'None'}
noderelation_id = 'eb00b207-efd0-41c1-9789-389d348bcb80'
try:
    api_response = api_instance.update_node_relationship_using_put(noderelation_update, noderelation_id)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling update_node_relationship_using_put: %s\n" % e)
DecisionTreeApi apiInstance = new DecisionTreeApi();
        //Update a Noderelationship
        Map map2 = new HashMap();
        map.put("value", "abc");

        try {
            NodeRelationship response = apiInstance.updateNodeRelationshipUsingPut(map2, UUID.fromString("0395e7ee-8024-45a9-9df1-dad638ab541d"));
            System.out.println(response);
        } catch (ApiException e) {
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\DecisionTreeApi(
    new GuzzleHttp\Client(),
    $config);

//Update NodeRelationship
$node_relation_update = new stdClass();
$node_relation_id = "75d191e0-4b75-4b26-bc26-0dc80aa3a3d3";

try {
    $node_relation_update->value = "high";
    $result = $apiInstance->updateNodeRelationshipUsingPut($node_relation_update, $node_relation_id);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->updateNodeRelationshipUsingPut: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::DecisionTreeApi.new
#Update Node relation
node_relation_update = {"value" => 'New'}
node_relation_id = '75d191e0-4b75-4b26-bc26-0dc80aa3a3d3'
begin
  result = api_instance.update_node_relationship_using_put(node_relation_update, node_relation_id)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->update_node_relationship_using_put: #{e}"
end
var apiInstance = new HydrogenNucleusApi.DecisionTreeApi();
// //Update NodeRelation
var apiInstance = new HydrogenNucleusApi.DecisionTreeApi();
var callback = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
var noderelationupdate = new HydrogenNucleusApi.NodeRelationship();
var noderelationid = 'c2d24207-41c8-48eb-a9cf-0666d51d032c';

noderelationupdate.value = "New A";
apiInstance.updateNodeRelationshipUsingPut(noderelationupdate, noderelationid, callback)

Example Response

{
    "id": "8397d8fd-e80d-48ea-bf79-81f32b12606e",
    "create_date": "2018-03-26T19:54:31.000+0000",
    "update_date": "2018-03-26T19:54:31.000+0000",
    "node_parent_id": "05b9f2e6-aabc-44b5-8e02-f1ab216ebd62",
    "node_child_id": "d5011ba6-50c6-427b-a29c-b7802a2c8660",
    "answer_id": "556cedaa-37ba-4dc7-ad03-0990b9252e1d",
    "value": "high",
    "is_leaf": true,
    "decision_tree_id": "28021071-bece-400b-a0f6-23fb13adfcd3",
    "metadata": {}
}

Update the information for a node relationship. The node_relationship_id must be provided. To obtain the appropriate node_relationship_id, use the GET /node_relationship endpoint to view all the node relationships defined for your tenant and their current information. The details to be updated must also be provided. The endpoint returns the node_relationship_id and the details for the node relationship.

HTTP REQUEST

PUT /node_relationship/{node_relationship_id}

Delete a node relationship

Example Request

curl -X DELETE -H "Authorization: Bearer 921c2e12-c3c3-4fe5-b8cc-2035d39ad44e" \
      "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/node_relationship/8397d8fd-e80d-48ea-bf79-81f32b12606e"
api_instance = nucleus_api.DecisionTreeApi(nucleus_api.ApiClient(configuration))
# # Delete a NodeRelationship
noderelationd_id = '02cc4773-87b5-4f3f-9a2d-d8ff5dd5bb05'
try:
    api_instance.delete_node_relationship_using_delete(noderelationd_id)
except ApiException as e:
    print("Exception when delete_node_relationship_using_delete: %s\n" % e)
DecisionTreeApi apiInstance = new DecisionTreeApi();
        //Delete a NodeRelationship
        try {
            NodeRelationship responseDelete = apiInstance.deleteNodeRelationshipUsingDelete(UUID.fromString(""));
            System.out.println(responseDelete);
        } catch (ApiException e) {
            System.err.println("Exception when calling deleteNodeRelationshipUsingDelete");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\DecisionTreeApi(
    new GuzzleHttp\Client(),
    $config);
//Delete NodeRelationship
$node_relation_did = "a9defe0e-0f61-40ef-a916-2f48e4d60d0e"; // string | UUID account_id

try {
    $apiInstance->deleteNodeRelationshipUsingDelete($node_relation_did);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->deleteNodeRelationshipUsingDelete: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::DecisionTreeApi.new
#Delete Node Relation
noderelation1_id = '0395e7ee-8024-45a9-9df1-dad638ab541d'
begin
  result = api_instance.delete_node_relationship_using_delete(noderelation1_id)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->delete_node_relationship_using_delete: #{e}"
end
var apiInstance = new HydrogenNucleusApi.DecisionTreeApi();
var noderelationd = "a9defe0e-0f61-40ef-a916-2f48e4d60d0e";
var deletenoderelation = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully.');
    }
};
apiInstance.deleteNodeRelationshipUsingDelete(noderelationd, deletenoderelation)

Response (204 No Content)

Permanently delete a node relationship. The node_relationship_id must be provided. To obtain the appropriate node_relationship_id, use the GET /node_relationship endpoint to view all the node relationships defined for your tenant. This deletes the node_relationship_id and the details for the node relationship.

HTTP REQUEST

DELETE /node_relationship/{node_relationship_id}

Model

Model Management

Models correspond to portfolios and determine their composition. Models generally consist of one or more securities and are usually assigned to one or more allocations, though that is not required. An account may have one or more models based on the allocation for the account.

Field Type Description
id UUID The id of the model
name string Name of the model usually used to indicate what is included in the model
category string Category that the model falls under such as “Equities”
description string Description of what types of investments are represented in the model
client_id UUID If the model is to be used by a specific client such as an advisor, the id of the client
benchmark_id UUID The id of the benchmark to compare this model against
node_map list List of the node_ids for the nodes of a decision tree that map to this model
      node_id UUID The id of the last node in the branch of a decision tree that maps to the model
currency_code string Alphabetic currency code for the base currency of the model, limited to 3 characters. See currency codes
is_active boolean Indicates if the model is active. Defaults to true which indicates that it is currently active
metadata map Custom information associated with the model in the format key:value. See Metadata
secondary_id string Alternate id that can be used to identify the object such as an internal id
create_date timestamp Timestamp for the date and time the record was created
update_date timestamp Timestamp for the date and time the record was last updated

PROTON API

The following fields may optionally be used in conjunction with the Proton API.

Field Type Description
downside boolean Indicator if rebalancing type for the model set to Downside Protection. true indicates that it is set for Downside Protection
tax_efficiency_id integer If downside is true, this represents level of restriction on the frequency of trading. Value may be 0 no restriction, 1 low, 2 moderate, 3 high, or 4 very high
period_rebal boolean Indicates if rebalancing type for the model is set to Period Based. true indicates that there is period-based rebalancing
rebalance_period integer If period_rebal is true, frequency of rebalancing period. Value may be 0 never, 1 annually, 2 semi-annually, 3 quarterly, or 4 monthly
drift_rebal boolean Indicates if rebalancing type for the model is set to Drift Based. true indicates that there is drift-base rebalancing
default_drift_factor float If drift_rebal is true, default drift threshold for the model as a decimal percentage. For example, 0.10 would set the model to rebalance when the weights drift 10% from the target weight. This is used if no drift_factor is set at the /model_holding level

List all models

Example Request

curl -X GET -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/model"
api_instance = nucleus_api.ModelApi(nucleus_api.ApiClient(configuration))
try:
    api_response = api_instance.get_model_all_using_get()
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_model_all_using_get: %s\n" % e)
ModelApi apiInstance = new ModelApi();
        try {
            PageModel List = apiInstance.getModelAllUsingGet(true,null, null, 1,10);
            System.out.println(List);
        } catch (ApiException e) {
            System.err.println("Exception when calling getModelAllUsingGet");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\ModelApi(
    new GuzzleHttp\Client(),
    $config);
$ascending = false; // bool | ascending
$filter = null; // string | filter
$order_by = null; // string | order_by
$page = 0; // int | page
$size = 10; // int | size

try {
    $modellist = $apiInstance->getModelAllUsingGet($ascending, $filter, $order_by, $page, $size);
    print_r($modellist);
} catch (Exception $e) {
    echo 'Exception when calling ModelApi->getModelAllUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::ModelApi.new
opts = {
    ascending: false, # BOOLEAN | ascending
    filter: null, # String | filter
    order_by: null, # String | order_by
    page: 0, # Integer | page
    size: 25 # Integer | size
}

begin
  modellist = api_instance.get_model_all_using_get(opts)
  p modellist
rescue NucleusApi::ApiError => e
  puts "Exception when calling ModelApi->get_model_all_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.ModelApi();
var opts = {
    'ascending': false, // Boolean | ascending
    // 'filter': "", // String | filter
    'orderBy': "update_date", // String | order_by
    'page': 0, // Number | page
    'size': 25 // Number | size
};

var modellist = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.getModelAllUsingGet(opts, modellist)

Example Response

{
    "content": [
        {
            "id": "013380bf-7f17-44c1-93c5-892a7ed3498c",
            "create_date": "2018-02-02T9:00:03.000+0000",
            "update_date": "2018-02-02T21:56:03.000+0000",
            "secondary_id": "3546728",
            "currency_code": "USD",
            "category": "Alpha Generating",
            "description": "Tactical Industrial Stock",
            "is_active": true,
            "name": "Industrial Stocks",
            "downside": true,
            "tax_efficiency_id": 2,
            "period_rebal": true,
            "rebalance_period": 3,
            "drift_rebal": true,
            "default_drift_factor": 0.10,
            "benchmark_id": null,
            "node_map": [],
            "metadata": {}
        },
        {
            "id": "04907eaa-3f33-49be-a35b-378cdf639fba",
            "create_date": "2018-02-02T9:00:03.000+0000",
            "update_date": "2018-02-02T21:56:03.000+0000",
            "secondary_id": "3546729",
            "category": "Risk Managed",
            "description": "Dynamic ESG Nasdaq Stock",
            "is_active": true,
            "name": "Concentrated Aggressive SRI Core",
            "downside": false,
            "period_rebal": true,
            "rebalance_period": 3,
            "drift_rebal": true,
            "default_drift_factor": 0.10,
            "benchmark_id": null,
            "node_map": [],
            "metadata": {}
        },
        {
            "id": "073def0e-6fa0-4e52-badb-6ff2aecbc2b2",
            "create_date": "2018-02-02T9:00:03.000+0000",
            "update_date": "2018-02-02T21:56:03.000+0000",
            "currency_code": "USD",
            "secondary_id": "3546730",
            "category": "Risk Managed",
            "description": "Dynamic Nasdaq Stock (Tax-Efficient)",
            "is_active": true,
            "name": "Concentrated Aggressive Core [Tax-Efficient]",
            "node_map": [],
            "benchmark_id": null,
            "metadata": {}
        }
  ],
  "total_pages": 1,
  "total_elements": 3,
  "last": true,
  "sort": [
      {
        "direction": "DESC",
        "property": "id",
        "ignore_case": false,
        "null_handling": "NATIVE",
        "descending": true,
        "ascending": false
      }
  ],
  "first": true,
  "number_of_elements": 3,
  "size": 25,
  "number": 1
}

Get details for all models defined for your tenant to which portfolios can subscribe. Note that the metadata and node map information are stored as nested objects within the model object.

HTTP REQUEST

GET /model

Create a model

Example Request

curl -X POST -H "Authorization: Bearer <access_token>" \
   -H "Content-Type: application/json" \
   -d '{
          "category": "Alpha Generating",
          "description": "Tactical Industrial Stock",
          "name": "Industrial Stocks",
          "secondary_id": "3546728"
      }' "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/model"
api_instance = nucleus_api.ModelApi(nucleus_api.ApiClient(configuration))
# # Create a Model
model = nucleus_api.Model(name="New Model")
try:
    api_response = api_instance.create_model_using_post(model)
    pprint(api_response)
except ApiException as e:
    print("create_model_using_post: %s\n" % e)
ModelApi apiInstance = new ModelApi();
        //Create a Model
        Model modelNew = new Model();
        modelNew.setName("New Model");

        try {
            Model result = apiInstance.createModelUsingPost(modelNew);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling createModelUsingPost");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\ModelApi(
    new GuzzleHttp\Client(),
    $config);
//Create Model
$model = new \com\hydrogen\nucleus\Model\Model();

try {
    $model->setName("New model");
    $result = $apiInstance->createModelUsingPost($model);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->createModelUsingPost: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::ModelApi.new
#Create Model
model = NucleusApi::Model.new

begin
  model.name = "New Model"
  result = api_instance.create_model_using_post(model)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->create_model_using_post: #{e}"
end
var apiInstance = new HydrogenNucleusApi.ModelApi();
//Create a Model
var model = new HydrogenNucleusApi.Model();
model.name = "New Model";

var newmodel = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.createModelUsingPost(model, newmodel)

Example Response

{
    "id": "013380bf-7f17-44c1-93c5-892a7ed3498c",
    "create_date": "2018-02-02T9:00:03.000+0000",
    "currency_code": "USD",
    "category": "Alpha Generating",
    "description": "Tactical Industrial Stock",
    "is_active": true,
    "name": "Industrial Stocks",
    "secondary_id": "3546728",
    "node_map": [],
    "benchmark_id": null,
    "metadata": {}
}

Create a new model for your tenant to which a portfolios can later subscribe. The name of the model must be provided. The endpoint returns a model_id used to manage the model. Once the model is created, the model_id can be assigned to an allocation, and portfolios can subscribe to the model. Note that the metadata and node map information are stored as nested objects within the model object.

HTTP REQUEST

POST /model

ARGUMENTS

Parameter Type Required Description
name string required Name of the model usually used to indicate what is included in the model
category string optional Category that the model falls under such as “Tech”
description string optional Description of what types of investments are represented in the model
client_id UUID optional If the model is to be used by a specific client such as an advisor, the id of the client
benchmark_id UUID optional The id of the benchmark to compare this model against
node_map list optional List of the node_ids for the nodes of a decision tree that map to this model
      node_id UUID required The id of the last node in the branch of a decision tree that maps to the model
currency_code string optional Alphabetic currency code for the base currency of the model, limited to 3 characters. See currency codes
is_active boolean optional Indicates for whether or not the model is active. Defaults to true which indicates that it is currently active
metadata map optional Custom information associated with the model in the format key:value. See Metadata
secondary_id string optional Alternate id that can be used to identify the object such as an internal id

PROTON API

The following arguments may be used in conjunction with the Proton API.

Field Type Required Description
downside boolean optional Indicator if rebalancing type for the model set to Downside Protection. true indicates that it is set for Downside Protection
tax_efficiency_id integer optional If downside is true, this represents level of restriction on the frequency of trading. Value may be 0 no restriction, 1 low, 2 moderate, 3 high, or 4 very high
period_rebal boolean optional Indicates if rebalancing type for the model is set to Period Based. true indicates that there is period-based rebalancing
rebalance_period integer optional If period_rebal is true, frequency of rebalancing period. Value may be 0 never, 1 annually, 2 semi-annually, 3 quarterly, or 4 monthly
drift_rebal boolean optional Indicates if rebalancing type for the model is set to Drift Based. true indicates that there is drift-base rebalancing
default_drift_factor float optional If drift_rebal is true, default drift threshold for the model as a decimal percentage. For example, 0.10 would set the model to rebalance when the weights drift 10% from the target weight. This is used if no drift_factor is set at the /model_holding level

Retrieve a model

Example Request

curl -X GET -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/model/013380bf-7f17-44c1-93c5-892a7ed3498c"
api_instance = nucleus_api.ModelApi(nucleus_api.ApiClient(configuration))
try:
    api_response = api_instance.get_model_using_get("c7ef5002-b236-4f4c-8a3d-1620e3803236")
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_model_using_get: %s\n" % e)
ModelApi apiInstance = new ModelApi();
        try {
            Model responseModel = apiInstance.getModelUsingGet(UUID.fromString("a9e3b1a2-e8f3-4bb6-88ef-0d629a4ffaa9"));
            System.out.println(responseModel);
        } catch (ApiException e) {
            System.err.println("Exception when calling getModelAllUsingGet");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\ModelApi(
    new GuzzleHttp\Client(),
    $config);
$model_id = "a9e3b1a2-e8f3-4bb6-88ef-0d629a4ffaa9"; // string | UUID model_id

try {
    $model = $apiInstance->getModelUsingGet($model_id);
    print_r($model);
} catch (Exception $e) {
    echo 'Exception when calling ModelApi->getModelUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::ModelApi.new
model_id = 'a9e3b1a2-e8f3-4bb6-88ef-0d629a4ffaa9' # String | UUID model_id


begin
  model = api_instance.get_model_using_get(model_id)
  p model
rescue NucleusApi::ApiError => e
  puts "Exception when calling ModelApi->get_model_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.ModelApi();
var modelID = "a9e3b1a2-e8f3-4bb6-88ef-0d629a4ffaa9";

var opts = {
    'currencyConversion': null, // String | USD
};

var model = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.getModelUsingGet(modelID, model)

Example Response

{
    "id": "013380bf-7f17-44c1-93c5-892a7ed3498c",
    "create_date": "2018-02-02T9:00:03.000+0000",
    "update_date": "2018-02-02T21:56:03.000+0000",
    "category": "Alpha Generating",
    "description": "Tactical Industrial Stock",
    "is_active": true,
    "currency_code": "USD",
    "secondary_id": "3546728",
    "node_map": [],
    "benchmark_id": null,
    "metadata": {}
}

Get the information for a model for your tenant. The model_id must be provided. The endpoint returns a model_id and the details for the model specified.

HTTP REQUEST

GET /model/{model_id}

Update a model

Example Request

curl -X PUT -H "Authorization: Bearer <access_token>" \
   -H "Content-Type: application/json" \
   -d '{
          "category": "Alpha Generating",
          "description": "Tactical Industrial Stock",
          "name": "Industrial Stocks",
          "currency_code": "USD",
          "secondary_id": "3546728"
      }' "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/model/013380bf-7f17-44c1-93c5-892a7ed3498c"
api_instance = nucleus_api.ModelApi(nucleus_api.ApiClient(configuration))
# # Update a Model
model_update = {'currency_code': 'GBP'}
model_id = 'dbff09fa-f349-42eb-b840-97a3093bfdb0'
try:
    api_response = api_instance.update_model_using_put(model_update, model_id)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling update_model_using_put: %s\n" % e)
ModelApi apiInstance = new ModelApi();
        //Update a Model
        Map map = new HashMap();
        map.put("currency_code", "GBP");

        try {
            Model response = apiInstance.updateModelUsingPut(map, UUID.fromString("b35b9f77-88cb-48ba-aff8-362b469fb474"));
            System.out.println(response);
        } catch (ApiException e) {
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\ModelApi(
    new GuzzleHttp\Client(),
    $config);
//Update Model
$model_update = new stdClass();
$model_id = "4dae3778-ccd7-41ec-a561-6183364c8c37";

try {
    $model_update->name = "ABC";
    $result = $apiInstance->updateModelUsingPut($model_update, $model_id);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->updateModelUsingPut: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::ModelApi.new
#Update Model
model_update = {"currency_code" => 'GBP'}
model_id = '4dae3778-ccd7-41ec-a561-6183364c8c37'
begin
  result = api_instance.update_model_using_put(model_update, model_id)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->update_model_using_put: #{e}"
end
var apiInstance = new HydrogenNucleusApi.ModelApi();
//Update Model
var apiInstance = new HydrogenNucleusApi.ModelApi();
var callback = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
var modelupdate = new HydrogenNucleusApi.Model();
var modelid = '9320d9c2-e09c-46e0-a35c-0ff730f72b07';

modelupdate.name = "MNX";
apiInstance.updateModelUsingPut(modelupdate, modelid, callback)

Example Response

{
    "id": "013380bf-7f17-44c1-93c5-892a7ed3498c",
    "create_date": "2018-02-02T9:00:03.000+0000",
    "update_date": "2018-02-02T21:56:03.000+0000",
    "category": "Alpha Generating",
    "description": "Tactical Industrial Stock",
    "is_active": true,
    "name": "Industrial Stocks",
    "currency_code": "USD",
    "secondary_id": "3546728",
    "node_map": [],
    "benchmark_id": null,
    "metadata": {}
}

Update a model for your tenant. The model_id must be provided. To obtain the appropriate model_id, use the GET /model endpoint to view all models defined for your tenant and their current information. The details to be updated must also be provided. The endpoint returns the model_id and the details for the model. If you wish the model to no longer be used without permanently deleting it, you can use this endpoint to update the is_active field to false.

HTTP REQUEST

PUT /model/{model_id}

Change a model composition

Example Request

curl -X POST -H "Authorization: Bearer <access_token>" \
    -H "Content-Type: application/json" \
    -d '{
          "model_id": "a0d59204-82b7-430b-ab32-e94dee48e7ae",
          "holdings": [
              {
               "current_weight": 90,
               "strategic_weight": 90,
               "date": "2018-09-05",
               "is_safe_security": true,
               "is_initial_holding": true,
               "security_id": "f8265114-06e8-48c9-82d8-e0962c7b5a47"
              },
              {
               "current_weight": 10,
               "strategic_weight": 10,
               "date": "2018-09-05",
               "is_safe_security": true,
               "is_initial_holding": true,
               "security_id": "51e57240-a213-435e-aff6-652daf37f6f0"
              }
            ],
          "sell_transaction_code_id": "81745d99-6a23-4faa-9072-3e5d529af61f",
          "buy_transaction_code_id": "2e0a00db-035b-43fc-b30a-3ef8eeaac78f"
      }' "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/model/a0d59204-82b7-430b-ab32-e94dee48e7ae/model_change"

Example Response

[
    {
        "id": "befd2c52-307e-4e54-904d-a9fff0115f89",
        "create_date": "2018-09-05T18:54:11.473+0000",
        "update_date": "2018-09-05T18:54:11.473+0000",
        "shares": 0.9,
        "price": 10,
        "date": "2018-09-05",
        "model_id": "a0d59204-82b7-430b-ab32-e94dee48e7ae",
        "security_id": "f8265114-06e8-48c9-82d8-e0962c7b5a47",
        "transaction_code_id": "2e0a00db-035b-43fc-b30a-3ef8eeaac78f"
    },
    {
        "id": "befd2c52-307e-4e54-904d-a9fff0115f89",
        "create_date": "2018-09-05T18:54:11.473+0000",
        "update_date": "2018-09-05T18:54:11.473+0000",
        "shares": 10,
        "price": 1,
        "date": "2018-09-05",
        "model_id": "a0d59204-82b7-430b-ab32-e94dee48e7ae",
        "security_id": "51e57240-a213-435e-aff6-652daf37f6f0",
        "transaction_code_id": "2e0a00db-035b-43fc-b30a-3ef8eeaac78f"
    }
]

Model composition changes represent a change in a model’s holdings. When the model holdings are changed, model transactions are created that may be used to calculate the model holdings. This endpoint creates both the necessary model holdings and model transaction records to reflect the changes to the model composition. This endpoint combines the following three actions into one workflow:

1) Create new model holdings
2) Calculate each model transaction
3) Create each model transaction to track the changes in the model’s composition

The endpoint takes in the details for the new model holding records, including the model_id and a list of all the model’s securities and their corresponding weights. Information should be provided for the new securities to be added to the model, the securities whose weights within the model change, and security weights that remain consistent. The endpoint then creates the new model holding records and returns the ids for all of the model transactions created.

HTTP REQUEST

POST /model/{model_id}/model_change

DATA DEPENDENCIES

  1. Model - POST /model
  2. Model Holdings - POST /model_holding
  3. Model Asset Size - POST /model_asset_size
  4. Security - POST /security
  5. Security Price - POST /security_price
  6. Buy and Sell Transaction Codes - POST /transaction_code

ARGUMENTS

Parameter Type Required Description
model_id UUID required The id of the model whose holdings are to be updated
holdings array required The information for the new holding records to be created
      security_id UUID required The id of the security included in this holding record
      current_weight double required Current weight of the security as a percentage of the model’s total value; ex. 20 representing 20%. If the security is the only one, enter 100
      strategic_weight double required Strategic weight of the security as a percentage of the model’s total value; ex. 20 representing 20%. If the security is the only one, enter 100
      date date required Date of the security weight
sell_transaction_code_id UUID required The transaction_code_id to be populated in any model transaction to sell securities
buy_transaction_code_id UUID required The transaction_code_id to be populated in any model transaction to buy securities

PROTON API

The following fields may optionally be used in conjunction with the Proton API.

Field Type Required Description
drift_factor float optional Drift factor for the security as a decimal percentage. For example, 0.10 would set the security to rebalance when the weights drift 10% from the target weight in the model.
is_cash boolean optional Indicates if the security is cash. Used for Downside Protection rebalancing. Default is false meaning it is not a cash security
is_safe_security boolean optional Indicates if the security is “safe” such as fixed income or cash. Used for Downside Protection rebalancing. Default is false meaning it is not a safe security

RESPONSE

Field Type Description
id UUID The id of the model transaction record created
shares double Number of shares of the security purchased as part of the transaction
price double Security price at which the shares were purchased as part of the transaction
date date Date of the transaction
model_id UUID The id of the model that the transaction record falls under
security_id UUID The id of the security included in the transaction
transaction_code_id integer The id referring to the transaction codes defined by your firm
create_date timestamp Timestamp for the date and time that the record was created
update_date timestamp Timestamp for the date and time that the record was last updated

Delete a model

Example Request

curl -X DELETE -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/model/013380bf-7f17-44c1-93c5-892a7ed3498c"
api_instance = nucleus_api.ModelApi(nucleus_api.ApiClient(configuration))
# # # Delete a Model
model1_id = '9320d9c2-e09c-46e0-a35c-0ff730f72b07'
try:
    api_instance.delete_model_using_delete(model1_id)
except ApiException as e:
    print("Exception when delete_model_using_delete: %s\n" % e)
ModelApi apiInstance = new ModelApi();
        //Delete a Model
        try {
            Model deleteresponse = apiInstance.deleteModelUsingDelete(UUID.fromString("021e37e8-7ef1-43e6-b412-45f75cc22140"));
            System.out.println(deleteresponse);
        } catch (ApiException e) {
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\ModelApi(
    new GuzzleHttp\Client(),
    $config);
//Delete Model
$model_did = "dbff09fa-f349-42eb-b840-97a3093bfdb0"; // string | UUID account_id

try {
    $apiInstance->deleteModelUsingDelete($model_did);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->deleteModelUsingDelete: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::ModelApi.new

#Delete Model
model1_id = 'dbff09fa-f349-42eb-b840-97a3093bfdb0'
begin
  result = api_instance.delete_model_using_delete(model1_id)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->delete_model_using_delete: #{e}"
end
var apiInstance = new HydrogenNucleusApi.ModelApi();
// // // //Delete a Model
var invoicepaymentidd = "22d77ddc-9d57-4a3b-bacd-6ef97e956bba";


var deleteinvoicepayment = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully.');
    }
};
apiInstance.deleteInvoicePaymentUsingDelete(invoicepaymentidd, deleteinvoicepayment)

Response (204 No Content)

Permanently delete a model for your tenant. The model_id must be provided. To obtain the appropriate model_id, use the GET /model endpoint to view all models defined for your tenant. This deletes the model_id and all the model information so that the model is no longer available. If you wish the model to no longer be used without permanently deleting it, you can use the PUT /model/{model_id} endpoint to update the is_active field to false.

HTTP REQUEST

DELETE /model/{model_id}

Model Asset Sizes

Asset sizes are used to track the progression of the model. Asset size records are created at a model level and aggregated at an allocation level. Model asset sizes represent the growth of the theoretical model assets rather than a monetary amount. For example, you may store model asset sizes as the growth of $1 or $10,000.

Field Type Description
id UUID The id of the model asset size record
date date Date for this asset size record
asset_size double “Growth of a dollar” within the model on the particular date
is_reconciled boolean Indicates the asset size record is reconciled. true means it is reconciled
model_id UUID The id of the model that the asset size record falls under
currency_code string Alphabetic currency code for the base currency of the model, limited to 3 characters. See currency codes
secondary_id string Alternate id that can be used to identify the object such as an internal id
create_date timestamp Timestamp for the date and time that the record was created
update_date timestamp Timestamp for the date and time that the record was last updated

List all model asset sizes

Example Request

curl -X GET -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/model_asset_size"
api_instance = nucleus_api.ModelApi(nucleus_api.ApiClient(configuration))
try:
    api_response = api_instance.get_model_asset_size_all_using_get()
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_model_asset_size_all_using_get: %s\n" % e)
ModelApi apiInstance = new ModelApi();
        try {
            PageModelAssetSize List = apiInstance.getModelAssetSizeAllUsingGet(true, null, null, null, 0, 10);
            System.out.println(List);
        } catch (ApiException e) {
            System.err.println("Exception when calling getModelAssetSizeAllUsingGet");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\ModelApi(
    new GuzzleHttp\Client(),
    $config);
$ascending = false; // bool | ascending
$currency_conversion = null; // string | currency_conversion
$filter = null; // string | filter
$order_by = null; // string | order_by
$page = 0; // int | page
$size = 10; // int | size

try {
    $modelassetslist = $apiInstance->getModelAssetSizeAllUsingGet($ascending, $currency_conversion, $filter, $order_by, $page, $size);
    print_r($modelassetslist);
} catch (Exception $e) {
    echo 'Exception when calling ModelApi->getModelAssetSizeAllUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::ModelApi.new
opts = {
    ascending: false, # BOOLEAN | ascending
    currency_conversion: null, # String | currency_conversion
    filter: null, # String | filter
    order_by: null, # String | order_by
    page: 0, # Integer | page
    size: 25 # Integer | size
}

begin
  modelassetsizelist = api_instance.get_model_asset_size_all_using_get(opts)
  p modelassetsizelist
rescue NucleusApi::ApiError => e
  puts "Exception when calling ModelApi->get_model_asset_size_all_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.ModelApi();
var opts = {
    'ascending': false, // Boolean | ascending
    'currencyConversion': null, // String | currency_conversion
    'filter': null, // String | filter
    'orderBy': null, // String | order_by
    'page': 0, // Number | page
    'size': 25 // Number | size
};

var modelassetlist = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.getModelAssetSizeAllUsingGet(opts, modelassetlist)

Example Response

{
  "content": [
    {
      "id": "b4c033db-9d05-4a33-8e28-40650d454487",
      "create_date": "2018-02-02T9:00:03.000+0000",
      "update_date": "2018-02-02T21:56:03.000+0000",
      "asset_size": 1.1,
      "date": "2016-01-04",
      "is_reconciled": true,
      "model_id": "5736e6f7-5e12-448e-830c-c1f2b9317d48",
      "currency_code": "USD"
    },
    {
      "id": "b4c033db-9d05-4a33-8e28-40650d454488",
      "create_date": "2018-02-02T9:00:03.000+0000",
      "update_date": "2018-02-02T21:56:03.000+0000",
      "asset_size": 1.1,
      "date": "2016-01-04",
      "is_reconciled": true,
      "model_id": "4b61f78e-d80e-452d-8201-b1adb87f5bb4",
      "currency_code": "USD"
    }
  ],
  "last": false,
  "total_pages": 1,
  "total_elements": 2,
  "first": true,
  "sort": [
    {
      "direction": "DESC",
      "property": "id",
      "ignore_case": false,
      "null_handling": "NATIVE",
      "ascending": false,
      "descending": true
    }
  ],
  "number_of_elements": 2,
  "size": 25,
  "number": 0
}

Get a list of asset sizes per date for all models defined for your tenant. Additional parameters available to narrow down what is returned include a date range, only obtaining the latest record, and sorting by different units of time (eg. annually, quarterly, monthly, daily), etc. The endpoint returns a date, amount, and the amount added to the asset size since the previous asset size for each date within the date range.

HTTP REQUEST

GET /model_asset_size

Create a model asset size

Example Request

curl -X POST -H "Authorization: Bearer <access_token>" \
    -H "Content-Type: application/json" \
    -d '{
            "asset_size" : 1.1,
            "date" : "2017-01-02",
            "is_reconciled" : true,
            "model_id" : "5736e6f7-5e12-448e-830c-c1f2b9317d48",
            "currency_code": "USD"
        }' "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/model_asset_size"
api_instance = nucleus_api.ModelApi(nucleus_api.ApiClient(configuration))
# # Create a ModelAssetSize
model_asset = nucleus_api.ModelAssetSize(_date="2020-10-10", asset_size="0.88", is_reconciled="false", model_id="005976f5-b5b5-43f9-8ad0-a0a6d9fdb22a")
try:
    api_response = api_instance.create_model_asset_size_using_post(model_asset)
    pprint(api_response)
except ApiException as e:
    print("create_model_asset_size_using_post: %s\n" % e)
ModelApi apiInstance = new ModelApi();
        //Create a Model Asset Size
        ModelAssetSize assetSize = new ModelAssetSize();
        assetSize.setDate(enddate);
        assetSize.setAssetSize(0.888);
        assetSize.setIsReconciled(false);
        assetSize.setModelId(UUID.fromString("005976f5-b5b5-43f9-8ad0-a0a6d9fdb22a"));

                try {
            ModelAssetSize result = apiInstance.createModelAssetSizeUsingPost(assetSize);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling createModelAssetSizeUsingPost");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\ModelApi(
    new GuzzleHttp\Client(),
    $config);
//Create Model Asset Size
$modelasset = new \com\hydrogen\nucleus\Model\ModelAssetSize();

try {
    $modelasset->setModelId('005976f5-b5b5-43f9-8ad0-a0a6d9fdb22a');
    $modelasset->setDate("2020-10-10");
    $modelasset->setAssetSize("200");
    $modelasset->setIsReconciled("false");
    $result = $apiInstance->createModelAssetSizeUsingPost($modelasset);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->createModelAssetSizeUsingPost: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::ModelApi.new
#Create Model
model_asset = NucleusApi::ModelAssetSize.new

begin
  model_asset.model_id = "005976f5-b5b5-43f9-8ad0-a0a6d9fdb22a"
  model_asset.asset_size = "500"
  model_asset.is_reconciled = "true"
  model_asset.date = "2020-10-10"
  result = api_instance.create_model_asset_size_using_post(model_asset)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->create_model_asset_size_using_post: #{e}"
end
var apiInstance = new HydrogenNucleusApi.ModelApi();
//Create a ModelAsset
var modelasset = new HydrogenNucleusApi.ModelAssetSize();
modelasset.model_id = "005976f5-b5b5-43f9-8ad0-a0a6d9fdb22a";
modelasset.date = "2020-10-10";
modelasset.asset_size = "30";
modelasset.is_reconciled = "false";


var newmodelasset = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.createModelAssetSizeUsingPost(modelasset, newmodelasset)

Example Response

{
  "id": "4b61f78e-d80e-452d-8201-b1adb87f5bb4",
  "create_date": "2018-02-02T9:00:03.000+0000",
  "update_date": "2018-02-02T21:56:03.000+0000",
  "asset_size": 1.1,
  "date": "2017-01-02",
  "is_reconciled": true,
  "model_id": "5736e6f7-5e12-448e-830c-c1f2b9317d48",
  "currency_code": "USD"
}

Create a new asset size record for a model. Asset sizes are used to track the progression of the model. The unique model_id must be provided. To obtain the appropriate model_id, use the GET /model endpoint to view all the models defined for your tenant. The value of the asset size and date for the asset size record must also be provided. The endpoint returns a model_asset_size_id used to manage the asset size record.

HTTP REQUEST

POST /model_asset_size

ARGUMENTS

Parameter Type Required Description
date date required Date for this asset size record
asset_size double required “Growth of a dollar” within the model on the particular date
is_reconciled boolean required Indicates the asset size record is reconciled. true means it is reconciled
model_id UUID required The id of the model for the asset size record
currency_code string optional Alphabetic currency code for the base currency of the model, limited to 3 characters. See currency codes
secondary_id string optional Alternate id that can be used to identify the object such as an internal id

Retrieve a model asset size

Example Request

curl -X GET -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/model_asset_size/4b61f78e-d80e-452d-8201-b1adb87f5bb4"
api_instance = nucleus_api.ModelApi(nucleus_api.ApiClient(configuration))
try:
    api_response = api_instance.get_model_asset_size_using_get("68e6d452-d008-434f-a3d4-cd95c92003ef")
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_model_asset_size_using_get: %s\n" % e)
ModelApi apiInstance = new ModelApi();
        ModelAssetSize responseModelAsset = null;
        try {
            responseModelAsset = apiInstance.getModelAssetSizeUsingGet(UUID.fromString("ac778ed1-e69d-43a2-8ac4-e036d9709359"), null);
            System.out.println(responseModelAsset);
        } catch (ApiException e) {
            System.err.println("Exception when calling getModelAssetSizeUsingGet");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\ModelApi(
    new GuzzleHttp\Client(),
    $config);
$model_asset_size_id = "ac778ed1-e69d-43a2-8ac4-e036d9709359"; // string | UUID model_asset_size_id
$currency_conversion = null; // string | USD

try {
    $modelassetsize = $apiInstance->getModelAssetSizeUsingGet($model_asset_size_id, $currency_conversion);
    print_r($modelassetsize);
} catch (Exception $e) {
    echo 'Exception when calling ModelApi->getModelAssetSizeUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::ModelApi.new
model_asset_size_id = 'ac778ed1-e69d-43a2-8ac4-e036d9709359' # String | UUID model_asset_size_id

opts = {
    currency_conversion: null, # String | USD
}

begin
  modelassetsize = api_instance.get_model_asset_size_using_get(model_asset_size_id, opts)
  p modelassetsize
rescue NucleusApi::ApiError => e
  puts "Exception when calling ModelApi->get_model_asset_size_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.ModelApi();
var modelassetID = "ac778ed1-e69d-43a2-8ac4-e036d9709359";

var opts = {
    'currencyConversion': null, // String | USD
};

var modelasset = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.getModelAssetSizeUsingGet(modelassetID, opts, modelasset)

Example Response

{
  "id": "4b61f78e-d80e-452d-8201-b1adb87f5bb4",
  "create_date": "2018-02-02T9:00:03.000+0000",
  "update_date": "2018-02-02T21:56:03.000+0000",
  "asset_size": 1.1,
  "date": "2016-01-02",
  "is_reconciled": true,
  "model_id": "5736e6f7-5e12-448e-830c-c1f2b9317d48",
  "currency_code": "USD"
}

Retrieve the information for a model asset size record for a model. The model_asset_size_id must be provided. The endpoint returns the model_asset_size_id and details for the model asset size record specified.

HTTP REQUEST

GET /model_asset_size/{model_asset_size_id}

Update a model asset size

Example Request

curl -X PUT -H "Authorization: Bearer <access_token>" \
    -H "Content-Type: application/json" \
    -d '{
            "asset_size" : 1.1,
            "date" : "2017-01-04",
            "is_reconciled" : true,
            "model_id" : "5736e6f7-5e12-448e-830c-c1f2b9317d48",
            "currency_code": "USD"
        }' "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/model_asset_size/4b61f78e-d80e-452d-8201-b1adb87f5bb4"
api_instance = nucleus_api.ModelApi(nucleus_api.ApiClient(configuration))
# # Update a ModelAssetSize
model_asset_update = {'currency_code': 'GBP'}
model_asset_id = 'dc0579a2-52f6-4194-80dd-086a6ba79f79'
try:
    api_response = api_instance.update_model_asset_size_using_put(model_asset_update, model_asset_id)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling update_model_asset_size_using_put: %s\n" % e)
ModelApi apiInstance = new ModelApi();
//        //Update a ModelAssetSize
//        Map map = new HashMap();
//        map.put("asset_size", "10.00");
//
//        try {
//            ModelAssetSize response = apiInstance.updateModelAssetSizeUsingPut(map, UUID.fromString("14a03975-24a4-4953-9489-fef644df905c"));
//            System.out.println(response);
//        } catch (ApiException e) {
//            e.printStackTrace();
//        }
$apiInstance = new com\hydrogen\nucleus\Api\ModelApi(
    new GuzzleHttp\Client(),
    $config);

//Update Model Asset Size
$modelasset_update = new stdClass();
$modelasset_id = "fa60afa2-9e42-4c2f-a001-2a7a9674d407";

try {
    $modelasset_update->asset_size = "300";
    $result = $apiInstance->updateModelAssetSizeUsingPut($modelasset_update, $modelasset_id);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->updateModelAssetSizeUsingPut: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::ModelApi.new
#Update Model Asset SIze
model_asset_update = {"date" => '2020-10-10'}
model_asset_id = '14a03975-24a4-4953-9489-fef644df905c'
begin
  result = api_instance.update_model_asset_size_using_put(model_asset_update, model_asset_id)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->update_model_asset_size_using_put: #{e}"
end
var apiInstance = new HydrogenNucleusApi.ModelApi();
//Update ModelAsset
var apiInstance = new HydrogenNucleusApi.ModelApi();
var callback = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
var modelassetupdate = new HydrogenNucleusApi.ModelAssetSize();
var modelassetid = 'dc0579a2-52f6-4194-80dd-086a6ba79f79';

modelassetupdate.date = "2020-10-10";
apiInstance.updateModelAssetSizeUsingPut(modelassetupdate, modelassetid, callback)

Example Response

{
  "id": "4b61f78e-d80e-452d-8201-b1adb87f5bb4",
  "create_date": "2018-02-02T9:00:03.000+0000",
  "update_date": "2018-02-02T21:56:03.000+0000",
  "asset_size": 1.1,
  "date": "2016-01-04",
  "is_reconciled": true,
  "model_id": "5736e6f7-5e12-448e-830c-c1f2b9317d48",
  "currency_code": "USD"
}

Update a model asset size record for a model. The model_asset_size_id must be provided. To obtain the appropriate model_asset_size_id, use the GET /model_asset_size endpoint to view all model asset size records and their current information. The details to be updated must also be provided. The endpoint returns the model_asset_size_id and details for the model asset size record specified.

HTTP REQUEST

PUT /model_asset_size/{model_asset_size_id}

Delete a model asset size

Example Request

curl -X DELETE -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/model_asset_size/4b61f78e-d80e-452d-8201-b1adb87f5bb4"
api_instance = nucleus_api.ModelApi(nucleus_api.ApiClient(configuration))
# # Delete a ModelAssetSize
model1_asset1_id = 'fa60afa2-9e42-4c2f-a001-2a7a9674d407'
try:
    api_instance.delete_model_asset_size_using_delete(model1_asset1_id)
except ApiException as e:
    print("Exception when delete_model_asset_size_using_delete: %s\n" % e)
ModelApi apiInstance = new ModelApi();
        //Delete a ModelAssetSize
        try {
            ModelAssetSize deleteresponse = apiInstance.deleteModelAssetSizeUsingDelete(UUID.fromString("9d03ab6d-7e7a-4ddf-8ddb-8116ee48851c"));
            System.out.println(deleteresponse);
        } catch (ApiException e) {
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\ModelApi(
    new GuzzleHttp\Client(),
    $config);

//Delete Model Asset Size
$modelasset_did = "79706dee-ee08-4ab7-b0c3-a6e465435fe6"; // string | UUID account_id

try {
    $apiInstance->deleteModelAssetSizeUsingDelete($modelasset_did);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->deleteModelAssetSizeUsingDelete: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::ModelApi.new
#Delete Model Asset
model_asset1_id = 'fa60afa2-9e42-4c2f-a001-2a7a9674d407'
begin
  result = api_instance.delete_model_asset_size_using_delete(model_asset1_id)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->delete_model_asset_size_using_delete: #{e}"
end
var apiInstance = new HydrogenNucleusApi.ModelApi();
// // // //Delete a ModelAsset
var modelassetid1 = "14a03975-24a4-4953-9489-fef644df905c";


var modelassetdelete = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully.');
    }
};
apiInstance.deleteModelAssetSizeUsingDelete(modelassetid1, modelassetdelete)

Response (204 No Content)

Permanently delete a model asset size record for a model. The model_asset_size_id must be provided.

HTTP REQUEST

DELETE /model_asset_size/{model_asset_size_id}

Model Holdings

Holding records represent the securities that are held under a model for a particular date. Holding records are created at the model level and aggregated at an allocation level.

Field Type Description
id UUID The id of the security holding record
model_id UUID The id of the model that the security holding record falls under
security_id UUID The id of the security included in this holding record
current_weight double Current weight of the security as a percentage of the model’s total value; ex. 20 representing 20%. If the security is the only one, enter 100
strategic_weight double Strategic weight of the security as a percentage of the model’s total value; ex. 20 representing 20%. If the security is the only one, enter 100
date date Date of the security weight
metadata map Custom information associated with the model holding in the format key:value. See Metadata
secondary_id string Alternate id that can be used to identify the object such as an internal id
create_date timestamp Timestamp for the date and time that the record was created
update_date timestamp Timestamp for the date and time that the record was last updated

PROTON API

The following fields may optionally be used in conjunction with the Proton API.

Field Type Description
drift_factor float Drift factor for the security as a decimal percentage. For example, 0.10 would set the security to rebalance when the weights drift 10% from the target weight in the model.
is_cash boolean Indicates if the security is cash. Used for Downside Protection rebalancing. Default is false meaning it is not a cash security
is_safe_security boolean Indicates if the security is “safe” such as fixed income or cash. Used for Downside Protection rebalancing. Default is false meaning it is not a safe security

List all model holdings

Example Request

curl -X GET -H "Authorization: Bearer <access_token>" \
      "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/model_holding"
api_instance = nucleus_api.ModelApi(nucleus_api.ApiClient(configuration))
try:
    api_response = api_instance.get_model_holding_all_using_get()
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_model_holding_all_using_get: %s\n" % e)
ModelApi apiInstance = new ModelApi();
        try {
            PageModelHolding List = apiInstance.getModelHoldingAllUsingGet(true, null, null, 1, 10);
            System.out.println(List);
        } catch (ApiException e) {
            System.err.println("Exception when calling getModelHoldingAllUsingGet");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\ModelApi(
    new GuzzleHttp\Client(),
    $config);
$ascending = false; // bool | ascending
$filter = null; // string | filter
$order_by = null; // string | order_by
$page = 0; // int | page
$size = 10; // int | size

try {
    $modelholdinglist = $apiInstance->getModelHoldingAllUsingGet($ascending, $filter, $order_by, $page, $size);
    print_r($modelholdinglist);
} catch (Exception $e) {
    echo 'Exception when calling ModelApi->getModelHoldingAllUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::ModelApi.new
opts = {
    ascending: false, # BOOLEAN | ascending
    filter: null, # String | filter
    order_by: null, # String | order_by
    page: 0, # Integer | page
    size: 25 # Integer | size
}

begin
  modelholdinglist = api_instance.get_model_holding_all_using_get(opts)
  p modelholdinglist
rescue NucleusApi::ApiError => e
  puts "Exception when calling ModelApi->get_model_holding_all_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.ModelApi();
var opts = {
    'ascending': false, // Boolean | ascending
    'currencyConversion': null, // String | currency_conversion
    'filter': null, // String | filter
    'orderBy': null, // String | order_by
    'page': 0, // Number | page
    'size': 25 // Number | size
};

var modelholdinglist = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.getModelHoldingAllUsingGet(opts, modelholdinglist)

Example Response

{
  "content": [
    {
      "id": "b4c033db-9d05-4a33-8e28-40650d454487",
      "create_date": "2018-02-02T19:29:37.000+0000",
      "update_date": "2018-02-02T09:00:00.000+0000",
      "current_weight": 20,
      "strategic_weight": 20,
      "date": "2018-02-02",
      "model_id": "efa289b2-3565-42e6-850b-8dad25727e99",
      "security_id": "cf9de92f-1c59-4188-93af-d7d5cefd0644",
      "metadata": {}
    },
    {
      "id": "7960419c-c098-4450-8cc5-866b7385230b",
      "create_date": "2018-02-02T19:29:37.000+0000",
      "update_date": "2018-02-02T09:00:00.000+0000",
      "current_weight": 20,
      "strategic_weight": 20,
      "date": "2018-02-02",
      "model_id": "cf9de92f-1c59-4188-93af-d7d5cefd0644",
      "security_id": "4b61f78e-d80e-452d-8201-b1adb87f5bb4",
      "metadata": {}
    }
  ],
  "last": true,
  "total_pages": 1,
  "total_elements": 2,
  "first": true,
  "sort": [
    {
      "direction": "ASC",
      "property": "id",
      "ignore_case": false,
      "null_handling": "NATIVE",
      "ascending": true,
      "descending": false
    }
  ],
  "number_of_elements": 2,
  "size": 25,
  "number": 0
}

Get all model holding records for all models defined for your tenant. You can provide the model_id to filter results for a model. To obtain the appropriate model_id, us the GET /model endpoint to view all the model defined by your firm. You can provide a security_id to filter results for a security. To obtain the appropriate security_id use the GET /security endpoint to view all securities defined for your tenant. You can also provide a specific date range to view the model holdings on the dates within that range. Note that the metadata and node_map information are stored as a nested object within the model holding object.

HTTP REQUEST

GET /model_holding

ARGUMENTS

Parameter Type Required Description
use_strategic boolean optional Return holdings based on the strategic weight. Defaults to false meaning the holdings are returned based on the current weight

Create a model holding

Example Request

curl -X POST -H "Authorization: Bearer <access_token>" \
    -H "Content-Type: application/json" \
    -d '{
            "current_weight": 20,
            "strategic_weight": 20,
            "date": "2018-02-02",
            "model_id": "cf9de92f-1c59-4188-93af-d7d5cefd0644",
            "security_id": "4b61f78e-d80e-452d-8201-b1adb87f5bb4"
      }' "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/model_holding"
api_instance = nucleus_api.ModelApi(nucleus_api.ApiClient(configuration))
# # Create a ModelHolding
model_holding = nucleus_api.ModelHolding(model_id="5e4c6c7a-d584-4c69-b5ce-bf48e624f6f5", security_id="5ec1d9d8-79a9-433c-a80e-1f4905cb0f4a", current_weight="20", strategic_weight="10", _date="2020-10-10")
try:
    api_response = api_instance.create_model_holding_using_post(model_holding)
    pprint(api_response)
except ApiException as e:
    print("create_model_holding_using_post: %s\n" % e)
ModelApi apiInstance = new ModelApi();
        //Create a Model Holding
        ModelHolding holding = new ModelHolding();
        holding.setModelId(UUID.fromString("5e4c6c7a-d584-4c69-b5ce-bf48e624f6f5"));
        holding.setSecurityId(UUID.fromString("5ec1d9d8-79a9-433c-a80e-1f4905cb0f4a"));
        holding.setCurrentWeight(20.00);
        holding.setStrategicWeight(10.00);
        holding.setDate(startdate);

                                try {
            ModelHolding response = apiInstance.createModelHoldingUsingPost(holding);
            System.out.println(response);
        } catch (ApiException e) {
            System.err.println("Exception when calling createModelHoldingUsingPost");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\ModelApi(
    new GuzzleHttp\Client(),
    $config);

//Create Model Holding
$modelholding = new \com\hydrogen\nucleus\Model\ModelHolding();

try {
    $modelholding->setModelId("5e4c6c7a-d584-4c69-b5ce-bf48e624f6f5");
    $modelholding->setSecondaryId("5ec1d9d8-79a9-433c-a80e-1f4905cb0f4a");
    $modelholding->setCurrentWeight("30");
    $modelholding->setStrategicWeight("40");
    $modelholding->setDate("2020-10-10");
    $result = $apiInstance->createModelHoldingUsingPost($modelholding);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->createModelHoldingUsingPost: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::ModelApi.new
#Create Model Holding
model_holding = NucleusApi::ModelHolding.new

begin
  model_holding.model_id = "5e4c6c7a-d584-4c69-b5ce-bf48e624f6f5"
  model_holding.security_id = "5ec1d9d8-79a9-433c-a80e-1f4905cb0f4a"
  model_holding.current_weight = "40"
  model_holding.strategic_weight = "50"
  model_holding.date = "2020-10-10"
  result = api_instance.create_model_holding_using_post(model_holding)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->create_model_holding_using_post: #{e}"
end
var apiInstance = new HydrogenNucleusApi.ModelApi();
//Create a ModelHolding
var modelholding = new HydrogenNucleusApi.ModelHolding();
modelholding.model_id = "005976f5-b5b5-43f9-8ad0-a0a6d9fdb22a";
modelholding.security_id = "5ec1d9d8-79a9-433c-a80e-1f4905cb0f4a";
modelholding.current_weight = "40";
modelholding.strategic_weight = "30";
modelholding.date = "2020-10-10";

var newmodelholding = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.createModelHoldingUsingPost(modelholding, newmodelholding)

Example Response

{
  "id": "7960419c-c098-4450-8cc5-866b7385230b",
  "create_date": "2018-02-02T19:29:37.000+0000",
  "current_weight": 20,
  "strategic_weight": 20,
  "date": "2018-02-02",
  "model_id": "cf9de92f-1c59-4188-93af-d7d5cefd0644",
  "security_id": "4b61f78e-d80e-452d-8201-b1adb87f5bb4",
  "metadata": {}
}

Create a new model holding record for a specific model and date. The unique model_id must be provided. To obtain the appropriate model_id, us the GET /model endpoint to view all the model defined by your firm. The security_id for the specific security must be provided. To obtain the appropriate security_id use the GET /security endpoint to view all securities defined for your tenant. The endpoint returns a model_holding_id used to manage this model holding record.

HTTP REQUEST

POST /model_holding

ARGUMENTS

Parameter Type Required Description
model_id UUID required The id of the model that the security holding record falls under
security_id UUID required The id of the security included in this holding record
current_weight double required Current weight of the security as a percentage of the model’s total value; ex. 20 representing 20%. If the security is the only one, enter 100
strategic_weight double required Strategic weight of the security as a percentage of the model’s total value; ex. 20 representing 20%. If the security is the only one, enter 100
date date required Date of the security weight
metadata map optional Custom information associated with the model holding in the format key:value. See Metadata
secondary_id string optional Alternate id that can be used to identify the object such as an internal id

PROTON API

The following fields may optionally be used in conjunction with the Proton API.

Field Type Required Description
drift_factor float optional Drift factor for the security as a decimal percentage. For example, 0.10 would set the security to rebalance when the weights drift 10% from the target weight in the model.
is_cash boolean optional Indicates if the security is cash. Used for Downside Protection rebalancing. Default is false meaning it is not a cash security
is_safe_security boolean optional Indicates if the security is “safe” such as fixed income or cash. Used for Downside Protection rebalancing. Default is false meaning it is not a safe security

Retrieve a model holding

Example Request

curl -X GET -H "Authorization: Bearer <access_token>" \
      "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/model_holding/7960419c-c098-4450-8cc5-866b7385230b"
api_instance = nucleus_api.ModelApi(nucleus_api.ApiClient(configuration))
try:
    api_response = api_instance.get_model_holding_using_get("2cade28b-9687-4056-a679-a297c4434d05")
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_model_holding_using_get: %s\n" % e)
ModelApi apiInstance = new ModelApi();
        try {
            ModelHolding responseModelHolding = apiInstance.getModelHoldingUsingGet(UUID.fromString("4099fdaf-6fc6-406e-8f20-1df523266819"));
            System.out.println(responseModelHolding);
        } catch (ApiException e) {
            System.err.println("Exception when calling getModelHoldingAllUsingGet");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\ModelApi(
    new GuzzleHttp\Client(),
    $config);
$model_holding_id = "4099fdaf-6fc6-406e-8f20-1df523266819"; // string | UUID model_holding_id

try {
    $modelholding = $apiInstance->getModelHoldingUsingGet($model_holding_id);
    print_r($modelholding);
} catch (Exception $e) {
    echo 'Exception when calling ModelApi->getModelHoldingUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::ModelApi.new
model_holding_id = '4099fdaf-6fc6-406e-8f20-1df523266819' # String | UUID model_holding_id


begin
  modelholding = api_instance.get_model_holding_using_get(model_holding_id)
  p modelholding
rescue NucleusApi::ApiError => e
  puts "Exception when calling ModelApi->get_model_holding_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.ModelApi();
var modelholdingID = "4099fdaf-6fc6-406e-8f20-1df523266819";

var opts = {
    'currencyConversion': null, // String | USD
};

var modelholding = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.getModelHoldingUsingGet(modelholdingID, modelholding)

Example Response

{
  "id": "7960419c-c098-4450-8cc5-866b7385230b",
  "create_date": "2018-02-02T19:29:37.000+0000",
  "update_date": "2018-02-02T09:00:00.000+0000",
  "current_weight": 20,
  "strategic_weight": 20,
  "date": "2018-02-02",
  "model_id": "cf9de92f-1c59-4188-93af-d7d5cefd0644",
  "security_id": "4b61f78e-d80e-452d-8201-b1adb87f5bb4",
  "metadata": {}
}

Retrieve the information for a model holding record for a model. The model_holding_id must be provided. The endpoint returns the model_holding_id and details for the model holding record specified.

HTTP REQUEST

GET /model_holding/{model_holding_id}

Update a model holding

Example Request

curl -X PUT -H "Authorization: Bearer <access_token>" \
    -H "Content-Type: application/json" \
    -d '{
            "current_weight": 20,
            "strategic_weight": 20,
            "date": "2018-02-02",
            "model_id": "cf9de92f-1c59-4188-93af-d7d5cefd0644",
            "security_id": "4b61f78e-d80e-452d-8201-b1adb87f5bb4"
      }' "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/model_holding/7960419c-c098-4450-8cc5-866b7385230b"
api_instance = nucleus_api.ModelApi(nucleus_api.ApiClient(configuration))
# # Update a ModelHolding
model_holding_update = {'model_weight': '30'}
model_holding_id = '91dff387-1cdb-4d9a-a70f-3b50a6fc1962'
try:
    api_response = api_instance.update_model_holding_using_put(model_holding_update, model_holding_id)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling update_model_holding_using_put: %s\n" % e)
ModelApi apiInstance = new ModelApi();
        //Update a ModelHolding
        Map map = new HashMap();
        map.put("current_weight", "30.0");

        try {
            ModelHolding response = apiInstance.updateModelHoldingUsingPut(map, UUID.fromString("4551d711-87bc-4f40-b8f5-db9b731dd891"));
            System.out.println(response);
        } catch (ApiException e) {
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\ModelApi(
    new GuzzleHttp\Client(),
    $config);

//Update Model Holding
$modelholding_update = new stdClass();
$modelholding_id = "0cd4fa59-d908-44d4-8da5-8ccfe8253948";

try {
    $modelholding_update->current_weight = "60";
    $result = $apiInstance->updateModelHoldingUsingPut($modelholding_update, $modelholding_id);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->updateModelHoldingUsingPut: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::ModelApi.new
#Update Model Holding
model_holding_update = {"current_weight" => '200'}
model_holding_id = '4551d711-87bc-4f40-b8f5-db9b731dd891'
begin
  result = api_instance.update_model_holding_using_put(model_holding_update, model_holding_id)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->update_model_holding_using_put: #{e}"
end
var apiInstance = new HydrogenNucleusApi.ModelApi();
//Update ModelHolding
var apiInstance = new HydrogenNucleusApi.ModelApi();
var callback = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
var modelholdingupdate = new HydrogenNucleusApi.ModelHolding();
var modelholdingid = '4551d711-87bc-4f40-b8f5-db9b731dd891';

modelholdingupdate.date = "2020-10-10";
apiInstance.updateModelHoldingUsingPut(modelholdingid, modelholdingupdate, callback)

Example Response

{
  "id": "7960419c-c098-4450-8cc5-866b7385230b",
  "create_date": "2018-02-02T19:29:37.000+0000",
  "update_date": "2018-02-02T09:00:00.000+0000",
  "current_weight": 20,
  "strategic_weight": 20,
  "date": "2018-02-02",
  "model_id": "cf9de92f-1c59-4188-93af-d7d5cefd0644",
  "security_id": "4b61f78e-d80e-452d-8201-b1adb87f5bb4",
  "metadata": {}
}

Update a model holding record for a model. The model_holding_id must be provided. To obtain the appropriate model_holding_id, use the GET /model_holding endpoint to view all model holdings and their current information. The details to be update and the details to be maintained must also be provided. The endpoint returns the model_holding_id and details for the model holding record.

HTTP REQUEST

PUT /model_holding/{model_holding_id}

Delete a model holding

Example Request

curl -X DELETE -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/model_holding/7960419c-c098-4450-8cc5-866b7385230b"
api_instance = nucleus_api.ModelApi(nucleus_api.ApiClient(configuration))
# # Delete a ModelHolding
model1_holding_id = '0cd4fa59-d908-44d4-8da5-8ccfe8253948'
try:
    api_instance.delete_model_holding_using_delete(model1_holding_id)
except ApiException as e:
    print("Exception when delete_model_holding_using_delete: %s\n" % e)
ModelApi apiInstance = new ModelApi();
        //Delete a ModelHolding
        try {
            ModelHolding deleteresponse = apiInstance.deleteModelHoldingUsingDelete(UUID.fromString("714ef741-7780-46cb-b241-4d05b0181422"));
            System.out.println(deleteresponse);
        } catch (ApiException e) {
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\ModelApi(
    new GuzzleHttp\Client(),
    $config);

//Delete Model Holding
$modelholding_did = "058fdcd7-a567-450e-8e4f-6a893a8fac5e"; // string | UUID account_id

try {
    $apiInstance->deleteModelHoldingUsingDelete($modelholding_did);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->deleteModelHoldingUsingDelete: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::ModelApi.new

#Delete Model Holding
model_holding1_id = '0cd4fa59-d908-44d4-8da5-8ccfe8253948'
begin
  result = api_instance.delete_model_holding_using_delete(model_holding1_id)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->delete_model_holding_using_delete: #{e}"
end
var apiInstance = new HydrogenNucleusApi.ModelApi();
// // // //Delete a ModelHolding
var modelholding1 = "0cd4fa59-d908-44d4-8da5-8ccfe8253948";


var modelholdingdelete = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully.');
    }
};
apiInstance.deleteModelHoldingUsingDelete(modelholding1, modelholdingdelete)

Response (204 No Content)

Permanently delete a model holding record for a model. The model_holding_id must be provided. To obtain the appropriate model_holding_id, use the GET /model_holding endpoint to view all model holdings. This deletes the model_holding_id and model holding record information from the model.

HTTP REQUEST

DELETE /model_holding/{model_holding_id}

Model Transactions

Transactions represent buy or sell orders for securities. Transactions are created at a model or portfolio level and aggregated at a goal, account, allocation, or client level.

Field Type Description
id UUID The id of the model transaction record
shares double Number of shares of the security purchased as part of the transaction
price double Security price at which the shares were purchased as part of the transaction
date date Date of the transaction
model_id UUID The id of the model that the transaction record falls under
security_id UUID The id of the security included in the transaction
transaction_code_id integer The id referring to the transaction codes defined by your firm
secondary_id string Alternate id that can be used to identify the object such as an internal id
create_date timestamp Timestamp for the date and time that the record was created
update_date timestamp Timestamp for the date and time that the record was last updated

List all model transactions

Example Request

curl -X GET -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/model_transaction"
api_instance = nucleus_api.ModelApi(nucleus_api.ApiClient(configuration))
try:
    api_response = api_instance.get_model_transaction_all_using_get()
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_model_transaction_all_using_get: %s\n" % e)
ModelApi apiInstance = new ModelApi();
        try {
            PageModelTransaction List = apiInstance.getModelTransactionAllUsingGet(true, null, null, 1, 5);
            System.out.println(List);
        } catch (ApiException e) {
            System.err.println("Exception when calling getModelTransactionAllUsingGet");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\ModelApi(
    new GuzzleHttp\Client(),
    $config);
$ascending = false; // bool | ascending
$filter = null; // string | filter
$order_by = null; // string | order_by
$page = 0; // int | page
$size = 10; // int | size

try {
    $modeltransactionlist = $apiInstance->getModelTransactionAllUsingGet($ascending, $filter, $order_by, $page, $size);
    print_r($modeltransactionlist);
} catch (Exception $e) {
    echo 'Exception when calling ModelApi->getModelTransactionAllUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::ModelApi.new
opts = {
    ascending: false, # BOOLEAN | ascending
    filter: null, # String | filter
    order_by: null, # String | order_by
    page: 0, # Integer | page
    size: 25 # Integer | size
}

begin
  modeltransactionlist = api_instance.get_model_transaction_all_using_get(opts)
  p modeltransactionlist
rescue NucleusApi::ApiError => e
  puts "Exception when calling ModelApi->get_model_transaction_all_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.ModelApi();
var opts = {
    'ascending': false, // Boolean | ascending
    'currencyConversion': null, // String | currency_conversion
    'filter': null, // String | filter
    'orderBy': null, // String | order_by
    'page': 0, // Number | page
    'size': 25 // Number | size
};

var modeltransactionlist = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.getModelTransactionAllUsingGet(opts, modeltransactionlist)

Example Response

{
  "content": [
    {
      "id": "e7cf805b-4307-41e9-8b58-90b6359fa900",
      "create_date": "2018-02-07T19:29:37.000+0000",
      "update_date": "2018-02-12T09:00:00.000+0000",
      "shares": 20,
      "price": 101.10,
      "date": "2018-02-07",
      "model_id": "5736e6f7-5e12-448e-830c-c1f2b9317d48",
      "security_id": "fad85772-ded2-4f12-90f7-28e68afcac6f",
      "transaction_code_id": "099961da-7f41-4309-950f-2b51689a0033"
    }
  ],
  "total_pages": 1,
  "total_elements": 1,
  "last": true,
  "sort": [
      {
        "direction": "DESC",
        "property": "id",
        "ignore_case": false,
        "null_handling": "NATIVE",
        "descending": true,
        "ascending": false
      }
  ],
  "first": true,
  "number_of_elements": 1,
  "size": 25,
  "number": 1
}

Get details for all transaction records for all models defined by your firm. Additional parameters available to limit what is returned include a date range.

HTTP REQUEST

GET /model_transaction

Create a model transaction

Example Request

curl -X POST -H "Authorization: Bearer <access_token>" \
    -H "Content-Type: application/json" \
    -d '{
            "shares" : 200,
            "price": 1.42,
            "date" : "2018-02-07",
            "model_id" : "5736e6f7-5e12-448e-830c-c1f2b9317d48",
            "security_id" : "fad85772-ded2-4f12-90f7-28e68afcac6f",
            "transaction_code_id" : "f5af397b-7d22-433f-b01e-8202184a6386"
        }' "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/model_transaction"
api_instance = nucleus_api.ModelApi(nucleus_api.ApiClient(configuration))
# # Create a ModelTransaction
model_transaction = nucleus_api.ModelTransaction(price="100", shares="50", _date="2020-10-10", model_id="5e4c6c7a-d584-4c69-b5ce-bf48e624f6f5", transaction_code_id="a9d47d25-f2cf-4c63-8d09-db1a3bfdb906", security_id="5ec1d9d8-79a9-433c-a80e-1f4905cb0f4a")
try:
    api_response = api_instance.create_model_transaction_using_post(model_transaction)
    pprint(api_response)
except ApiException as e:
    print("create_model_transaction_using_post: %s\n" % e)
ModelApi apiInstance = new ModelApi();
        //Create a Model Transaction
        ModelTransaction transaction = new ModelTransaction();
        transaction.setShares(100.00);
        transaction.setPrice(20000.0);
        transaction.setDate(startdate);
        transaction.setModelId(UUID.fromString("5e4c6c7a-d584-4c69-b5ce-bf48e624f6f5"));
        transaction.setTransactionCodeId(UUID.fromString("a9d47d25-f2cf-4c63-8d09-db1a3bfdb906"));
        transaction.setSecurityId(UUID.fromString("5ec1d9d8-79a9-433c-a80e-1f4905cb0f4a"));

        try {
            ModelTransaction response = apiInstance.createModelTransactionUsingPost(transaction);
            System.out.println(response);
        } catch (ApiException e) {
            System.err.println("Exception when calling createModelTransactionUsingPost");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\ModelApi(
    new GuzzleHttp\Client(),
    $config);

//Create Model transaction
$modeltransaction = new \com\hydrogen\nucleus\Model\ModelTransaction();

try {
    $modeltransaction->setModelId("5e4c6c7a-d584-4c69-b5ce-bf48e624f6f5");
    $modeltransaction->setTransactionCodeId("a9d47d25-f2cf-4c63-8d09-db1a3bfdb906");
    $modeltransaction->setSecurityId("5ec1d9d8-79a9-433c-a80e-1f4905cb0f4a");
    $modeltransaction->setShares("200");
    $modeltransaction->setPrice("300");
    $modeltransaction->setDate("2020-10-10");
    $result = $apiInstance->createModelTransactionUsingPost($modeltransaction);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->createModelTransactionUsingPost: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::ModelApi.new

#Create Model Transaction
model_transaction = NucleusApi::ModelTransaction.new

begin
  model_transaction.model_id = "5e4c6c7a-d584-4c69-b5ce-bf48e624f6f5"
  model_transaction.transaction_code_id = "a9d47d25-f2cf-4c63-8d09-db1a3bfdb906"
  model_transaction.security_id = "5ec1d9d8-79a9-433c-a80e-1f4905cb0f4a"
  model_transaction.shares = "300"
  model_transaction.price = "40"
  model_transaction.date = "2020-10-10"
  result = api_instance.create_model_transaction_using_post(model_transaction)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->create_model_transaction_using_post: #{e}"
end
var apiInstance = new HydrogenNucleusApi.ModelApi();
//Create a ModelTransaction
var modeltrans = new HydrogenNucleusApi.ModelTransaction();
modeltrans.model_id = "005976f5-b5b5-43f9-8ad0-a0a6d9fdb22a";
modeltrans.security_id = "a5ec1d9d8-79a9-433c-a80e-1f4905cb0f4a";
modeltrans.transaction_code_id = "a9d47d25-f2cf-4c63-8d09-db1a3bfdb906";
modeltrans.shares = "300";
modeltrans.price = "400";
modeltrans.date = "2020-10-10";

var newmodeltrans = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.createModelTransactionUsingPost(modeltrans, newmodeltrans)

Example Response

{
  "id": "e7cf805b-4307-41e9-8b58-90b6359fa900",
  "create_date": "2018-02-07T19:29:37.000+0000",
  "shares": 200,
  "price": 1.42,
  "date": "2018-02-07",
  "model_id" : "5736e6f7-5e12-448e-830c-c1f2b9317d48",
  "security_id" : "fad85772-ded2-4f12-90f7-28e68afcac6f",
  "transaction_code_id" : "f5af397b-7d22-433f-b01e-8202184a6386"
}

Create a new transaction record for a security under a model for a specific date. Transactions represent buy or sell orders for securities. The unique model_id and the unique security_id must be provided. To obtain the appropriate model_id use the GET /model endpoint to view all available models defined for your tenant. To obtain the appropriate security_id use the GET /security endpoint to view all securities defined for your tenant. A transaction_code_id must also be provided. To obtain the appropriate transaction_code_id use the GET /transaction_code endpoint to view all available transaction codes for your tenant. The create_date will default to the current date. The endpoint returns a transaction_id used to manage the transaction record.

HTTP REQUEST

POST /model_transaction

ARGUMENTS

Parameter Type Required Description
shares double required Number of shares of the security purchased as part of the transaction
price double required Security price at which the shares were purchased as part of the transaction
date date required Date of the transaction
model_id UUID required The id of the model that the transaction record falls under
security_id UUID required The id of the security included in the transaction
transaction_code_id integer required The id referring to the transaction codes defined by your firm
secondary_id string optional Alternate id that can be used to identify the object such as an internal id

Retrieve a model transaction

Example Request

curl -X GET -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/model_transaction/e7cf805b-4307-41e9-8b58-90b6359fa900"
api_instance = nucleus_api.ModelApi(nucleus_api.ApiClient(configuration))
try:
    api_response = api_instance.get_model_transaction_using_get("0a1cebca-ad19-4872-95e7-635c716cf595")
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_model_transaction_using_get: %s\n" % e)
ModelApi apiInstance = new ModelApi();
        try {
            ModelTransaction responseModelTransaction = apiInstance.getModelTransactionUsingGet(UUID.fromString("83f3b081-9b11-4158-a526-5f7f3896b508"));
            System.out.println(responseModelTransaction);
        } catch (ApiException e) {
            System.err.println("Exception when calling getModelTransactionUsingGet");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\ModelApi(
    new GuzzleHttp\Client(),
    $config);
$model_transaction_id = "83f3b081-9b11-4158-a526-5f7f3896b508"; // string | UUID model_transaction_id

try {
    $modeltransaction = $apiInstance->getModelTransactionUsingGet($model_transaction_id);
    print_r($modeltransaction);
} catch (Exception $e) {
    echo 'Exception when calling ModelApi->getModelTransactionUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::ModelApi.new
model_transaction_id = '83f3b081-9b11-4158-a526-5f7f3896b508' # String | UUID model_transaction_id


begin
  modeltransaction = api_instance.get_model_transaction_using_get(model_transaction_id)
  p modeltransaction
rescue NucleusApi::ApiError => e
  puts "Exception when calling ModelApi->get_model_transaction_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.ModelApi();
var modeltransactionID = "83f3b081-9b11-4158-a526-5f7f3896b508";

var opts = {
    'currencyConversion': null, // String | USD
};

var modeltransaction = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.getModelTransactionUsingGet(modeltransactionID, modeltransaction)

Example Response

{
  "id": "e7cf805b-4307-41e9-8b58-90b6359fa900",
  "create_date": "2018-02-07T19:29:37.000+0000",
  "update_date": "2018-02-12T09:00:00.000+0000",
  "shares": 200,
  "price": 1.42,
  "date": "2018-02-07",
  "model_id" : "5736e6f7-5e12-448e-830c-c1f2b9317d48",
  "security_id" : "fad85772-ded2-4f12-90f7-28e68afcac6f",
  "transaction_code_id" : "72ebcdfa-70c7-427b-aebb-0df000b3a0a0"
}

Retrieve the information for a model transaction for a model. The model_transaction_id must be provided. The endpoint returns the model_transaction_id and details for the model transaction record specified.

HTTP REQUEST

GET /model_transaction/{model_transaction_id}

Update a model transaction

Example Request

curl -X PUT -H "Authorization: Bearer <access_token>" \
    -H "Content-Type: application/json" \
    -d '{
            "shares": 200,
            "price" : 1.42,
            "date" : "2018-02-07",
            "model_id" : "5736e6f7-5e12-448e-830c-c1f2b9317d48",
            "security_id" : "fad85772-ded2-4f12-90f7-28e68afcac6f",
            "transaction_code_id" : "f5af397b-7d22-433f-b01e-8202184a6386"
        }' "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/model_transaction/e7cf805b-4307-41e9-8b58-90b6359fa900"
api_instance = nucleus_api.ModelApi(nucleus_api.ApiClient(configuration))
# # Update a ModelTransaction
model_transaction_update = {'shares': '30'}
model_transaction_id = '5bba832a-5889-4c7e-b2b4-64e5f610e75b'
try:
    api_response = api_instance.update_model_transaction_using_put(model_transaction_update, model_transaction_id)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling update_model_transaction_using_put: %s\n" % e)
ModelApi apiInstance = new ModelApi();
        //Update a ModelTransaction
        Map map = new HashMap();
        map.put("shares", "200");
        map.put("price", "2000");

        try {
            ModelTransaction response = apiInstance.updateModelTransactionUsingPut(map, UUID.fromString("1edb07e4-c433-4519-8ceb-baf388832b62"));
            System.out.println(response);
        } catch (ApiException e) {
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\ModelApi(
    new GuzzleHttp\Client(),
    $config);
//Update Model transaction
$modeltransaction_update = new stdClass();
$modeltransaction_id = "c87cd45c-4268-4f58-b65b-6ffd505ec2cd";

try {
    $modeltransaction_update->shares = "66";
    $result = $apiInstance->updateModelTransactionUsingPut($modeltransaction_update, $modeltransaction_id);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->updateModelTransactionUsingPut: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::ModelApi.new

#Update Model Transaction
model_transaction_update = {"shares" => '200'}
model_transaction_id = '1edb07e4-c433-4519-8ceb-baf388832b62'
begin
  result = api_instance.update_model_transaction_using_put(model_transaction_update, model_transaction)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->update_model_transaction_using_put: #{e}"
end
var apiInstance = new HydrogenNucleusApi.ModelApi();
//Update Modeltrans
var apiInstance = new HydrogenNucleusApi.ModelApi();
var callback = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
var modeltransupdate = new HydrogenNucleusApi.ModelTransaction();
var modeltransid = '1edb07e4-c433-4519-8ceb-baf388832b62';

modeltransupdate.date = "2020-10-10";
apiInstance.updateModelTransactionUsingPut(modeltransid, modeltransupdate, callback)

Example Response

{
  "id": "e7cf805b-4307-41e9-8b58-90b6359fa900",
  "create_date": "2018-02-07T19:29:37.000+0000",
  "update_date": "2018-02-12T09:00:00.000+0000",
  "shares": 200,
  "price": 1.42,
  "date": "2018-02-07",
  "model_id": "5736e6f7-5e12-448e-830c-c1f2b9317d48",
  "security_id": "fad85772-ded2-4f12-90f7-28e68afcac6f",
  "transaction_code_id": "f5af397b-7d22-433f-b01e-8202184a6386"
}

Update a model transaction for a model. The model_transaction_id must be provided. To obtain the appropriate model_transaction_id, use the GET /model_transaction endpoint to view all model transactions and their current information. The details to be updated must also be provided. The endpoint returns the model_transaction_id and details for the model transaction record.

HTTP REQUEST

PUT /model_transaction/{model_transaction_id}

Delete a model transaction

Example Request

curl -X DELETE -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/model_transaction/e7cf805b-4307-41e9-8b58-90b6359fa90"
api_instance = nucleus_api.ModelApi(nucleus_api.ApiClient(configuration))
# # # Delete a ModelTransaction
model1_transaction_id = '2b7c55f1-2280-4058-b924-de0abb54ddd6'
try:
    api_instance.delete_model_transaction_using_delete(model1_transaction_id)
except ApiException as e:
    print("Exception when delete_model_transaction_using_delete: %s\n" % e)
ModelApi apiInstance = new ModelApi();

        //Delete a ModelTransaction
        try {
            ModelTransaction deleteresponse = apiInstance.deleteModelTransactionUsingDelete(UUID.fromString("c2aef246-6c8c-46ff-bd81-07f2e5b0766e"));
            System.out.println(deleteresponse);
        } catch (ApiException e) {
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\ModelApi(
    new GuzzleHttp\Client(),
    $config);



//Delete Model Transactions
$modeltransaction_did = "2c2173f5-259e-4089-b76a-29f3f1d867ae"; // string | UUID account_id

try {
    $apiInstance->deleteModelTransactionUsingDelete($modeltransaction_did);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->deleteModelTransactionUsingDelete: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::ModelApi.new

#Delete Model Transaction
model_transaction1_id = '98feeeae-7fad-4fa7-86e1-34907941651f'
begin
  result = api_instance.delete_model_transaction_using_delete(model_transaction1_id)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->delete_model_transaction_using_delete: #{e}"
end
var apiInstance = new HydrogenNucleusApi.ModelApi();
// // // //Delete a Modeltrans
var modeltrans1 = "98feeeae-7fad-4fa7-86e1-34907941651f";


var modeltransdelete = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully.');
    }
};
apiInstance.deleteModelTransactionUsingDelete(modeltrans1, modeltransdelete)

Response (204 No Content)

Permanently delete a model transaction for a model. The model_transaction_id must be provided. To obtain the appropriate model_transaction_id, use the GET /model_transaction endpoint to view all model transactions. This deletes the model_transaction_id and the model transaction record.

HTTP REQUEST

DELETE /model_transaction/{model_transaction_id}

Model Commentary

Model commentary is used to understand the logic behind each model. Commentary may consist of rationale behind various trades conducted by your investment team such as rebalancing or strategic asset allocation changes.

Field Type Description
id UUID The id of the model comment
model_id UUID The id of the model that the comment falls under
comment string Body of the comment
date date Date for when the comment applies
metadata map Custom information associated with the entity in the format key:value
See Metadata
secondary_id string Alternate id that can be used to identify the object such as an internal id
create_date timestamp Timestamp for the date and time that the record was created
update_date timestamp Timestamp for the date and time that the record was last updated

List all model commentary

Example Request

curl -X GET -H "Authorization: Bearer 7f137375-c63b-49fb-84eb-5abbd3b780a3" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/model_comment"
api_instance = nucleus_api.ModelApi(nucleus_api.ApiClient(configuration))
try:
    api_response = api_instance.get_model_comment_all_using_get()
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_model_comment_all_using_get: %s\n" % e)
ModelApi apiInstance = new ModelApi();
        try {
            PageModelComment List = apiInstance.getModelCommentAllUsingGet(true, null, null, 0, 8);
            System.out.println(List);
        } catch (ApiException e) {
            System.err.println("Exception when calling getModelCommentAllUsingGet");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\ModelApi(
    new GuzzleHttp\Client(),
    $config);
$ascending = false; // bool | ascending
$filter = null; // string | filter
$order_by = null; // string | order_by
$page = 0; // int | page
$size = 10; // int | size

try {
    $modelcommentlist = $apiInstance->getModelCommentAllUsingGet($ascending, $filter, $order_by, $page, $size);
    print_r($modelcommentlist);
} catch (Exception $e) {
    echo 'Exception when calling ModelApi->getModelCommentAllUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::ModelApi.new
opts = {
    ascending: false, # BOOLEAN | ascending
    filter: null, # String | filter
    order_by: null, # String | order_by
    page: 0, # Integer | page
    size: 25 # Integer | size
}

begin
  commentlist = api_instance.get_model_comment_all_using_get(opts)
  p commentlist
rescue NucleusApi::ApiError => e
  puts "Exception when calling ModelApi->get_model_comment_all_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.ModelApi();
var opts = {
    'ascending': false, // Boolean | ascending
    'currencyConversion': null, // String | currency_conversion
    'filter': null, // String | filter
    'orderBy': null, // String | order_by
    'page': 0, // Number | page
    'size': 25 // Number | size
};

var modelcommentlist = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.getModelCommentAllUsingGet(opts, modelcommentlist)

Example Response

{
  "content": [
    {
      "id": "8d97c85c-8cbf-4ac1-a5df-f9d2bb6a77e0",
      "create_date": "2018-02-07T19:29:37.000+0000",
      "update_date": "2018-02-12T09:00:00.000+0000",
      "comment": "We reduced your holdings to risky assets due to heightened geo-political risks.",
      "date": "2018-02-07",
      "model_id": "fad85772-ded2-4f12-90f7-28e68afcac6f",
      "metadata": {}
    }
  ],
  "total_pages": 1,
  "last": true,
  "total_elements": 1,
  "first": true,
  "sort": [
    {
      "direction": "ASC",
      "property": "id",
      "ignore_case": false,
      "null_handling": "NATIVE",
      "ascending": true,
      "descending": false
    }
  ],
  "number_of_elements": 1,
  "size": 25,
  "number": 0
}

List all comments for all models defined by your firm. You can filter to view only the comments for a specific model by providing a model_id. To obtain the appropriate model_id, use the GET /model endpoint to view all models defined for your tenant.

HTTP REQUEST

GET /model_comment

Create a model commentary

Example Request

curl -X POST -H "Authorization: Bearer 7f137375-c63b-49fb-84eb-5abbd3b780a3" \
    -H "Content-Type: application/json" \
    -d '{
            "comment" : "We reduced your holdings to risky assets due to heightened geo-political risks.",
            "date" : "2018-01-31",
            "model_id" : "fad85772-ded2-4f12-90f7-28e68afcac6f"
        }' "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/model_comment"
api_instance = nucleus_api.ModelApi(nucleus_api.ApiClient(configuration))

# # Create a ModelComment
model_comment = nucleus_api.ModelComment(model_id="296ec0fd-838e-47f1-9314-d8f01c505803", _date="2020-10-10", comment="New Model")
try:
    api_response = api_instance.create_model_comment_using_post(model_comment)
    pprint(api_response)
except ApiException as e:
    print("create_model_comment_using_post: %s\n" % e)
ModelApi apiInstance = new ModelApi();

        //Create Model Comment
        ModelComment comment = new ModelComment();
        comment.setModelId(UUID.fromString("296ec0fd-838e-47f1-9314-d8f01c505803"));
        comment.setComment("First Model");
        comment.setDate(startdate);

                        try {
            ModelComment response = apiInstance.createModelCommentUsingPost(comment);
            System.out.println(response);
        } catch (ApiException e) {
            System.err.println("Exception when calling createModelCommentUsingPost");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\ModelApi(
    new GuzzleHttp\Client(),
    $config);

//Create Model Comment
$modelcomment = new \com\hydrogen\nucleus\Model\ModelComment();

try {
    $modelcomment->setModelId("296ec0fd-838e-47f1-9314-d8f01c505803");
    $modelcomment->setComment("new");
    $modelcomment->setDate("2020-10-10");
    $result = $apiInstance->createModelCommentUsingPost($modelcomment);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->createModelCommentUsingPost: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::ModelApi.new

#Create Model Comment
model_comment = NucleusApi::ModelComment.new

begin
  model_comment.model_id = "296ec0fd-838e-47f1-9314-d8f01c505803"
  model_comment.comment = "New"
  model_comment.date = "2020-10-10"
  result = api_instance.create_model_comment_using_post(model_comment)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->create_model_comment_using_post: #{e}"
end
var apiInstance = new HydrogenNucleusApi.ModelApi();
//Create a ModelComment
var modelcomment = new HydrogenNucleusApi.ModelComment();
modelcomment.model_id = "005976f5-b5b5-43f9-8ad0-a0a6d9fdb22a";
modelcomment.comment = "new";
modelcomment.date = "2020-10-10";


var newmodelcommment = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.createModelCommentUsingPost(modelcomment, newmodelcommment)

Example Response

{
  "id": "e7cf805b-4307-41e9-8b58-90b6359fa900",
  "create_date": "2018-02-07T19:29:37.000+0000",
  "update_date": "2018-02-12T09:00:00.000+0000",
  "comment": "We reduced your holdings to risky assets due to heightened geo-political risks.",
  "date": "2018-02-07",
  "model_id": "fad85772-ded2-4f12-90f7-28e68afcac6f",
  "metadata": {}
}

Create a new comment for a model available for your tenant. The unique model_id must be provided. To obtain the appropriate model_id, use the GET /model endpoint to view all models defined for your tenant. The create_date will default to the current date. The endpoint returns a unique model_comment_id used to manage the model comment.

HTTP REQUEST

POST /model_comment

ARGUMENTS

Parameter Type Required Description
model_id UUID required The id of the model that the comment falls under
comment string required Body of the comment
date date required Date for when the comment applies
metadata map optional Custom information associated with the entity in the format key:value
See Metadata
secondary_id string optional Alternate id that can be used to identify the object such as an internal id

Retrieve a model commentary

Example Request

curl -X GET -H "Authorization: Bearer 7f137375-c63b-49fb-84eb-5abbd3b780a3" \
      "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/model_comment/e7cf805b-4307-41e9-8b58-90b6359fa900"
api_instance = nucleus_api.ModelApi(nucleus_api.ApiClient(configuration))
try:
    api_response = api_instance.get_model_comment_using_get("")
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_model_comment_using_get: %s\n" % e)
ModelApi apiInstance = new ModelApi();
        try {
            ModelComment responseModelComment = apiInstance.getModelCommentUsingGet(UUID.fromString("9a8a2a79-28d4-4d68-989a-475d5fd3858b"));
            System.out.println(responseModelComment);
        } catch (ApiException e) {
            System.err.println("Exception when calling getModelCommentUsingGet");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\ModelApi(
    new GuzzleHttp\Client(),
    $config);
$model_comment_id = "9a8a2a79-28d4-4d68-989a-475d5fd3858b"; // string | UUID model_comment_id

try {
    $modelcomment = $apiInstance->getModelCommentUsingGet($model_comment_id);
    print_r($modelcomment);
} catch (Exception $e) {
    echo 'Exception when calling ModelApi->getModelCommentUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::ModelApi.new
model_comment_id = '9a8a2a79-28d4-4d68-989a-475d5fd3858b' # String | UUID model_comment_id

begin
  comment = api_instance.get_model_comment_using_get(model_comment_id)
  p comment
rescue NucleusApi::ApiError => e
  puts "Exception when calling ModelApi->get_model_comment_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.ModelApi();
var modelcommentID = "9a8a2a79-28d4-4d68-989a-475d5fd3858b";

var opts = {
    'currencyConversion': null, // String | USD
};

var modelcomment = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.getModelCommentUsingGet(modelcommentID, modelcomment)

Example Response

{
  "id": "e7cf805b-4307-41e9-8b58-90b6359fa900",
  "create_date": "2018-02-07T19:29:37.000+0000",
  "update_date": "2018-02-12T09:00:00.000+0000",
  "comment": "We reduced your holdings to risky assets due to heightened geo-political risks.",
  "date": "2018-02-07",
  "model_id": "fad85772-ded2-4f12-90f7-28e68afcac6f",
  "metadata": {}
}

Retrieve the information for a model comment for a model. The model_comment_id must be provided. The endpoint returns the model_comment_id and details for the model comment specified.

HTTP REQUEST

GET /model_comment/{model_comment_id}

Update a model commentary

Example Request

curl -X PUT -H "Authorization: Bearer 7f137375-c63b-49fb-84eb-5abbd3b780a3" \
    -H "Content-Type: application/json" \
    -d '{
            "comment" : "We reduced your holdings to risky assets due to heightened geo-political risks.",
            "date" : "2018-01-31",
            "model_id" : "fad85772-ded2-4f12-90f7-28e68afcac6f2"
        }' "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/model_comment/e7cf805b-4307-41e9-8b58-90b6359fa900"
api_instance = nucleus_api.ModelApi(nucleus_api.ApiClient(configuration))

# # Update a ModelComment
model_comment_update = {'comment': 'New Comment'}
model_comment_id = '030b17f7-71b2-4b15-92b3-0440a8bf967a'
try:
    api_response = api_instance.update_model_comment_using_put(model_comment_update, model_comment_id)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling update_model_comment_using_put: %s\n" % e)
ModelApi apiInstance = new ModelApi();
        //Update a ModelComment
        Map map = new HashMap();
        map.put("comment", "Model Comment");

        try {
            ModelComment response = apiInstance.updateModelCommentUsingPut(map, UUID.fromString("eb517d7b-e7d5-4041-a167-df45b0d39eac"));
            System.out.println(response);
        } catch (ApiException e) {
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\ModelApi(
    new GuzzleHttp\Client(),
    $config);

//Update Model Comment
$modelcomment_update = new stdClass();
$modelcomment_id = "d8fd81fa-aa77-4cdd-9f6a-9f6e4e39b28d";

try {
    $modelcomment_update->comment = "ty";
    $result = $apiInstance->updateModelCommentUsingPut($modelcomment_update, $modelcomment_id);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->updateModelCommentUsingPut: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::ModelApi.new

#Update Model Comment
model_comment_update = {"date" => '2020-10-10'}
model_comment_id = 'f98ea3c5-3908-457d-8304-dd8a901b5c30'
begin
  result = api_instance.update_model_comment_using_put(model_comment_update, model_comment_id)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->update_model_comment_using_put: #{e}"
end
var apiInstance = new HydrogenNucleusApi.ModelApi();
//Update Modelcomment
var apiInstance = new HydrogenNucleusApi.ModelApi();
var callback = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
var modelcommentupdate = new HydrogenNucleusApi.ModelComment();
var modelcommmentid = '3f91c483-ee96-464b-989b-999e35132266';

modelcommentupdate.date = "2020-10-10";
apiInstance.updateModelCommentUsingPut(modelcommmentid, modelcommentupdate, callback)

Example Response

{
  "id": "e7cf805b-4307-41e9-8b58-90b6359fa900",
  "create_date": "2018-02-07T19:29:37.000+0000",
  "update_date": "2018-02-12T09:00:00.000+0000",
  "comment": "We reduced your holdings to risky assets due to heightened geo-political risks.",
  "date": "2018-02-07",
  "model_id": "fad85772-ded2-4f12-90f7-28e68afcac6f",
  "metadata": {}
}

Update a model comment for a model. The model_comment_id must be provided. To obtain the appropriate model_comment_id, use the GET /model_comment endpoint to view all model comments and their current information. The details to be updated must also be provided. The endpoint returns the model_comment_id and details for the model comment.

HTTP REQUEST

PUT /model_comment/{model_comment_id}

Delete a model commentary

Example Request

curl -X DELETE -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/model_comment/e7cf805b-4307-41e9-8b58-90b6359fa900"
api_instance = nucleus_api.ModelApi(nucleus_api.ApiClient(configuration))
# # Delete a ModelComment
model1_comment_id = 'fa60afa2-9e42-4c2f-a001-2a7a9674d407'
try:
    api_instance.delete_model_comment_using_delete(model1_comment_id)
except ApiException as e:
    print("Exception when delete_model_comment_using_delete: %s\n" % e)
ModelApi apiInstance = new ModelApi();
        //Delete a ModelComment
        try {
            ModelComment deleteresponse = apiInstance.deleteModelCommentUsingDelete(UUID.fromString("7db511dd-24fb-4fd6-8a61-cb2b1602303c"));
            System.out.println(deleteresponse);
        } catch (ApiException e) {
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\ModelApi(
    new GuzzleHttp\Client(),
    $config);

//Delete Model Comment
$modelcomment_did = "e57e005f-7365-4190-8720-e051c433112b"; // string | UUID account_id

try {
    $apiInstance->deleteModelCommentUsingDelete($modelcomment_did);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->deleteModelCommentUsingDelete: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::ModelApi.new
#Delete Model Comment
model_comment1_id = 'd8fd81fa-aa77-4cdd-9f6a-9f6e4e39b28d'
begin
  result = api_instance.delete_model_comment_using_delete(model_comment1_id)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->delete_model_comment_using_delete: #{e}"
end
var apiInstance = new HydrogenNucleusApi.ModelApi();
// // // //Delete a ModelComment
var modelcomment1 = "f98ea3c5-3908-457d-8304-dd8a901b5c30";


var modelcommentdelete = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully.');
    }
};
apiInstance.deleteModelCommentUsingDelete(modelcomment1, modelcommentdelete)

Response (204 No Content)

Permanently delete a model comment for a model. The model_comment_id must be provided. To obtain the appropriate model_comment_id, use the GET /model_comment endpoint to view all model comments. This deletes the model_comment_id and the model comment record from the model.

HTTP REQUEST

DELETE /model_comment/{model_comment_id}

Order

Order Management

Order records represent order tickets for securities that would be passed on to an agent or Securities Trading Organization (STO) for execution. Orders are usually generated as part of rebalancing of accounts or portfolios, but they can also be created one-off.

Field Type Description
id UUID The id of the order record
transaction_code_id UUID The id referring to the transaction codes defined by your firm
quantity double The number of shares of security being bought or sold
security_id UUID The id of the security being bought or sold
date date Date for when the order was generated
price double Price of the security at the time the order is created. Should be provided to use the rebalancing functionality
amount double Dollar value of the order (price * quantity)
commission double Dollar amount paid by customer to execute the order at the broker
order_bulk_id UUID In the case that the order is part of a bulk order, the id of the bulk order
is_read boolean Indicates if the order record has been read. Defaults to false which indicates that it has not been read
order_type string Type of the order transaction
order_ticket_id UUID The id that reflects all orders generated during a rebalance
portfolio_id UUID The id of the portfolio that the order falls under
account_id UUID The id of the account that the order falls under
model_id UUID The id of the model with which the order is associated
metadata map Custom information associated with the order record in the format key:value.
See Metadata
create_date timestamp Timestamp for the date and time that the record was created
update_date timestamp Timestamp for the date and time that the record was last updated

List all order records

Example Request

curl -X GET -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/order"
api_instance = nucleus_api.OrderApi(nucleus_api.ApiClient(configuration))
try:
    api_response = api_instance.get_order_all_using_get()
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_order_all_using_get: %s\n" % e)
OrderApi apiInstance = new OrderApi();
        try {
            PageOrder List = apiInstance.getOrderAllUsingGet(true, null, null, 0, 10);
            System.out.println(List);
        } catch (ApiException e) {
            System.err.println("Exception when calling getOrderAllUsingGet1");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\OrderApi(
    new GuzzleHttp\Client(),
    $config);
$ascending = false; // bool | ascending
$filter = null; // string | filter
$order_by = null; // string | order_by
$page = 0; // int | page
$size = 10; // int | size

try {
    $orderlist = $apiInstance->getOrderAllUsingGet($ascending, $filter, $order_by, $page, $size);
    print_r($orderlist);
} catch (Exception $e) {
    echo 'Exception when calling OrderApi->getOrderAllUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::OrderApi.new
opts = {
    ascending: false, # BOOLEAN | ascending
    filter: null, # String | filter
    order_by: null, # String | order_by
    page: 0, # Integer | page
    size: 25 # Integer | size
}

begin
  orderlist = api_instance.get_order_all_using_get(opts)
  p orderlist
rescue NucleusApi::ApiError => e
  puts "Exception when calling OrderApi->get_order_all_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.OrderApi();
var opts = {
    'ascending': false, // Boolean | ascending
    // 'filter': "", // String | filter
    'orderBy': "update_date", // String | order_by
    'page': 0, // Number | page
    'size': 25 // Number | size
};

var orderlist = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.getOrderAllUsingGet(opts, orderlist)

Example Response

{
  "content": [
    {
      "id": "67190064-0731-4b29-b2a7-4a35eb8e7afe",
      "create_date": "2018-02-07T19:29:37.000+0000",
      "update_date": "2018-02-12T09:00:00.000+0000",
      "transaction_code_id": "f5af397b-7d22-433f-b01e-8202184a6386",
      "order_bulk_id": "114556fe-ee78-431d-be5e-60ae08ddf9a7",
      "date": "2018-02-12",
      "price": 51.25,
            "amount": null,
            "commission": null,
      "is_read": false,
      "order_ticket_id": "5da53a30-49e6-4162-8728-58d6348bfb24",
      "quantity": 4,
      "security_id": "65363b6d-fcca-41ea-bc88-419e927fff0d",
      "account_id": "c80c9729-3fd5-4a2f-be8e-915cdf21b49d",
      "model_id": "f43a535b-477d-447c-99ca-b47cb2037849",
      "metadata": {}
    },
    {
      "id": "fab27a8b-3d6d-4c74-a9a9-443feebe04e7",
      "create_date": "2018-02-07T19:29:37.000+0000",
      "update_date": "2018-02-12T09:00:00.000+0000",
      "transaction_code_id": "f5af397b-7d22-433f-b01e-8202184a6386",
      "order_bulk_id": "114556fe-ee78-431d-be5e-60ae08ddf9a7",
      "date": "2018-02-11",
      "price": 45,
            "amount": null,
            "commission": null,
      "is_read": true,
      "order_type": "bulk order",
      "order_ticket_id": "0de415ac-0265-43d7-add4-553232c5032b",
      "portfolio_id": "c34794e9-f927-468b-b47e-ea17c3d533c5",
      "quantity": 2,
      "security_id": "a7376937-da3e-423c-9764-767c22bf89e8",
      "account_id": "c80c9729-3fd5-4a2f-be8e-915cdf21b49d",
      "model_id": "f43a535b-477d-447c-99ca-b47cb2037849",
      "metadata": {
        "order_purpose": "tax loss harvested"
      }
    }
  ],
  "last": true,
  "total_elements": 2,
  "total_pages": 1,
  "sort": [
    {
      "direction": "DESC",
      "property": "id",
      "ignore_case": false,
      "null_handling": "NATIVE",
      "ascending": false,
      "descending": true
    }
  ],
  "first": true,
  "number_of_elements": 2,
  "size": 25,
  "number": 0
}

Get the information for all order records defined for your tenant. You can provide an account_id, portfolio_id, or model_id to view the order records for a specific account, portfolio or model respectively. Note that the metadata information is stored as a nested object within the order record object.

HTTP REQUEST

GET /order

Create an order record

Example Request

curl -X POST -H "Authorization: Bearer <access_token>" \
     -H "Content-Type: application/json" \
     -d '{
          "transaction_code_id": "f5af397b-7d22-433f-b01e-8202184a6386",
          "date": "2018-02-11",
          "price": 51.25,
          "order_type": "initial order",
          "order_ticket_id": "5da53a30-49e6-4162-8728-58d6348bfb24",
          "portfolio_id": "c34794e9-f927-468b-b47e-ea17c3d533c5",
          "quantity": 2,
          "security_id": "65363b6d-fcca-41ea-bc88-419e927fff0d",
          "account_id": "c80c9729-3fd5-4a2f-be8e-915cdf21b49d",
          "model_id": "f43a535b-477d-447c-99ca-b47cb2037849",
          "metadata": {
            "order_purpose": "tax loss harvested"
          }
      }' "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/order"
api_instance = nucleus_api.OrderApi(nucleus_api.ApiClient(configuration))

# # Create a Order
order = nucleus_api.Order(transaction_code_id="3e78b32b-0cb9-42e3-9a74-acdc7ff179db", quantity="10", security_id="16fd2d66-db89-44fd-ac8e-a12ceebb38e3", _date="2020-10-10", price="100", order_ticket_id="9d0cc6f3-e7af-474e-aa41-ce084ad535f0")
try:
    api_response = api_instance.create_order_using_post(order)
    pprint(api_response)
except ApiException as e:
    print("create_order_using_post: %s\n" % e)
OrderApi apiInstance = new OrderApi();
        //Create an Order
        Order order = new Order();
        order.setTransactionCodeId(UUID.fromString("3e78b32b-0cb9-42e3-9a74-acdc7ff179db"));
        order.setQuantity(100.00);
        order.setSecurityId(UUID.fromString("16fd2d66-db89-44fd-ac8e-a12ceebb38e3"));
        order.setDate(startdate);
        order.setPrice(50.00);

                try {
            Order result = apiInstance.createOrderUsingPost(order);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling createOrderUsingPost");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\OrderApi(
    new GuzzleHttp\Client(),
    $config);
//Create Order
$order = new \com\hydrogen\nucleus\Model\Order();

try {
    $order->setTransactionCodeId("3e78b32b-0cb9-42e3-9a74-acdc7ff179db");
    $order->setSecurityId("16fd2d66-db89-44fd-ac8e-a12ceebb38e3");
    $order->setQuantity("100");
    $order->setDate("2020-10-10");
    $order->setPrice("200");
    $result = $apiInstance->createOrderUsingPost($order);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->createOrderUsingPost: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::OrderApi.new
#Create Order
order = NucleusApi::Order.new

begin
  order.transaction_code_id = "3e78b32b-0cb9-42e3-9a74-acdc7ff179db"
  order.security_id = "16fd2d66-db89-44fd-ac8e-a12ceebb38e3"
  order.quantity = "50"
  order.date = "2020-10-10"
  order.price = "500"
  result = api_instance.create_order_using_post(order)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->create_order_using_post: #{e}"
end
var apiInstance = new HydrogenNucleusApi.OrderApi();
//Create a Order
var order = new HydrogenNucleusApi.Order();
order.transaction_code_id = '3e78b32b-0cb9-42e3-9a74-acdc7ff179db';
order.security_id = '16fd2d66-db89-44fd-ac8e-a12ceebb38e3';
order.quantity = "20";
order.date = "2020-10-10";
order.price = "200";

var neworder = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.createOrderUsingPost(order, neworder)

Example Response

{
    "id": "67190064-0731-4b29-b2a7-4a35eb8e7afe",
    "create_date": "2018-02-07T19:29:37.000+0000",
    "update_date": "2018-02-07T19:29:37.000+0000",
    "transaction_code_id": "f5af397b-7d22-433f-b01e-8202184a6386",
    "date": "2018-02-11",
    "price": 51.25,
        "amount": null,
        "commission": null,
    "order_type": "initial order",
    "order_ticket_id": "5da53a30-49e6-4162-8728-58d6348bfb24",
    "portfolio_id": "c34794e9-f927-468b-b47e-ea17c3d533c5",
    "quantity": 2,
    "security_id": "65363b6d-fcca-41ea-bc88-419e927fff0d",
    "account_id": "c80c9729-3fd5-4a2f-be8e-915cdf21b49d",
    "model_id": "f43a535b-477d-447c-99ca-b47cb2037849",
    "metadata": {
        "order_purpose": "tax loss harvested"
    }
}

Create an order record for your tenant. The details for the order including the security_id for the securities being ordered and the transaction_code_id to indicate if the securities are being bought or sold must be provided. To obtain the appropriate security_id and transaction_code_id, use the GET /security and GET /transaction_code endpoints to view all securities and transaction codes defined by your firm. The create_date will default to the current date. the endpoint returns an order_id used to manage the order record.

HTTP REQUEST

POST /order

ARGUMENTS

Parameter Type Required Description
transaction_code_id UUID required The id referring to the transaction codes defined by your firm
quantity double required The number of shares of security being bought or sold
security_id UUID required The id of the security being bought or sold
date date required Date for when the order was generated
price double required, conditional Price of the security at the time the order is created. Should be provided to use the rebalancing functionality. Either the amount or quantity must be supplied.
amount double required, conditional Dollar value of the order (price * quantity). Either the amount or quantity must be supplied.
commission double optional Dollar amount paid by customer to execute the order at the broker
order_bulk_id UUID optional In the case that the order is part of a bulk order, the id of the bulk order
is_read boolean optional Indicator for whether or not the order record has been read. Defaults to false which indicates that it has not been read
order_type string optional Type of the order transaction
order_ticket_id UUID optional The id that reflects all orders generated during a rebalance
portfolio_id UUID optional The id of the portfolio that the order falls under. Used when aggregating order records into Bulk Order
account_id UUID optional The id of the account that the order falls under. Used when aggregating order records into Bulk Order
model_id UUID optional The id of the model with which the order is associated. Used when aggregating order records into Bulk Order
metadata map optional Custom information associated with the order record in the format key:value.
See Metadata

Retrieve an order record

Example Request

curl -X GET -H "Authorization: Bearer <access_token>" \
     "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/order/67190064-0731-4b29-b2a7-4a35eb8e7afe"
api_instance = nucleus_api.OrderApi(nucleus_api.ApiClient(configuration))
try:
    api_response = api_instance.get_order_using_get("3918da58-0951-4225-b1d7-ecb306369471")
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_order_all_using_get1: %s\n" % e)
OrderApi apiInstance = new OrderApi();
        try {
            Order responseOrder = apiInstance.getOrderUsingGet(UUID.fromString("4eaf6824-d078-4daa-806d-cbab10ffccc5"));
            System.out.println(responseOrder);
        } catch (ApiException e) {
            System.err.println("Exception when calling getOrderUsingGet");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\OrderApi(
    new GuzzleHttp\Client(),
    $config);
$order_id = "4eaf6824-d078-4daa-806d-cbab10ffccc5"; // string | UUID order_id

try {
    $order = $apiInstance->getOrderUsingGet($order_id);
    print_r($order);
} catch (Exception $e) {
    echo 'Exception when calling OrderApi->getOrderUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::OrderApi.new
order_id = '4eaf6824-d078-4daa-806d-cbab10ffccc5' # String | UUID order_id


begin
  order = api_instance.get_order_using_get(order_id)
  p order
rescue NucleusApi::ApiError => e
  puts "Exception when calling OrderApi->get_order_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.OrderApi();
var orderID = "4eaf6824-d078-4daa-806d-cbab10ffccc5";

var opts = {
    'currencyConversion': null, // String | USD
};

var order = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.getOrderUsingGet(orderID, order)

Example Response

{
    "id": "67190064-0731-4b29-b2a7-4a35eb8e7afe",
    "create_date": "2018-02-07T19:29:37.000+0000",
    "update_date": "2018-02-12T09:00:00.000+0000",
    "transaction_code_id": "f5af397b-7d22-433f-b01e-8202184a6386",
    "date": "2018-02-11",
    "price": 51.25,
        "amount": null,
        "commission": null,
    "order_bulk_id": "114556fe-ee78-431d-be5e-60ae08ddf9a7",
    "order_type": "bulk order",
    "order_ticket_id": "5da53a30-49e6-4162-8728-58d6348bfb24",
    "portfolio_id": "c34794e9-f927-468b-b47e-ea17c3d533c5",
    "quantity": 2,
    "security_id": "65363b6d-fcca-41ea-bc88-419e927fff0d",
    "account_id": "c80c9729-3fd5-4a2f-be8e-915cdf21b49d",
    "model_id": "f43a535b-477d-447c-99ca-b47cb2037849",
    "metadata": {
      "order_purpose": "tax loss harvested"
    }
}

Retrieve the information for an order record. The unique order_id must be provided. The endpoint returns the order_id and the details for the order record specified.

HTTP REQUEST

GET /order/{order_id}

Update an order record

Example Request

curl -X PUT -H "Authorization: Bearer <access_token>" \
     -H "Content-Type: application/json" \
     -d '{
            "transaction_code_id": "f5af397b-7d22-433f-b01e-8202184a6386",
            "order_bulk_id": "8df5a4ff-4ca3-4f6f-a0f7-89bc3d4dabc9",
            "date": "2018-02-11",
            "price": 51.25,
            "is_read": true,
            "order_type": "bulk order",
            "order_ticket_id": "5da53a30-49e6-4162-8728-58d6348bfb24",
            "portfolio_id": "066304b6-017d-4c2c-8b76-92d772f1f3d5",
            "quantity": 2,
            "security_id": "066304b6-017d-4c2c-8b76-92d772f1f3d56",
            "account_id": "066304b6-017d-4c2c-8b76-92d772f1f3d7",
            "model_id": "066304b6-017d-4c2c-8b76-92d772f1f3d8",
            "metadata": {
              "order_purpose": "tax loss harvested"
            }
       }' "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/order/cd10b1f0-a158-499c-b3d6-ce3277b779fe"
api_instance = nucleus_api.OrderApi(nucleus_api.ApiClient(configuration))
    # # Update a OrderTrack
order_update = {'quantity': '300'}
order_id = '816e33fd-983f-4bfb-875d-89fd23846269'
try:
    api_response = api_instance.update_order_using_put(order_update, order_id)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling update_order_using_put: %s\n" % e)
OrderApi apiInstance = new OrderApi();
        //        //Update a Order
        Map map = new HashMap();
        map.put("quantity", "200");


        try {
            Order response = apiInstance.updateOrderUsingPut(map, UUID.fromString("f4d17c11-fb71-4f6c-bfed-fa4fcacdcff0"));
            System.out.println(response);
        } catch (ApiException e) {
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\OrderApi(
    new GuzzleHttp\Client(),
    $config);
//Update Order
$order_update = new stdClass();
$order_id = "3c7a983b-53ff-495d-a170-d0e6346e3b38";

try {
    $order_update->price = "300";
    $result = $apiInstance->updateOrderUsingPut($order_update, $order_id);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->updateOrderUsingPut: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::OrderApi.new
#Update Order
order_update = {"date" => '2020-10-10'}
order_id = '4c0a65f1-ed3b-4e99-9a6f-9c404bd1854c'
begin
  result = api_instance.update_order_using_put(order_update, order_id)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->update_order_using_put: #{e}"
end
var apiInstance = new HydrogenNucleusApi.OrderApi();
//Update Order
var apiInstance = new HydrogenNucleusApi.OrderApi();
var callback = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
var orderupdate = new HydrogenNucleusApi.Order();
var orderid = '9320d9c2-e09c-46e0-a35c-0ff730f72b07';

orderupdate.amount = "400";
apiInstance.updateOrderUsingPut(orderupdate, orderid, callback)

Example Response

{
    "id": "cd10b1f0-a158-499c-b3d6-ce3277b779fe",
    "create_date": "2018-02-07T19:29:37.000+0000",
    "update_date": "2018-02-12T09:00:00.000+0000",
    "transaction_code_id": "f5af397b-7d22-433f-b01e-8202184a6386",
    "order_bulk_id": "8df5a4ff-4ca3-4f6f-a0f7-89bc3d4dabc9",
    "date": "2018-02-11",
    "price": 51.25,
        "amount": null,
        "commission": null,
    "is_read": true,
    "order_type": "bulk order",
    "order_ticket_id": "5da53a30-49e6-4162-8728-58d6348bfb24",
    "portfolio_id": "066304b6-017d-4c2c-8b76-92d772f1f3d5",
    "quantity": 2,
    "security_id": "066304b6-017d-4c2c-8b76-92d772f1f3d56",
    "account_id": "066304b6-017d-4c2c-8b76-92d772f1f3d7",
    "model_id": "066304b6-017d-4c2c-8b76-92d772f1f3d8",
    "metadata": {
      "order_purpose": "tax loss harvested"
    }
}

Update the information for an order record. The unique order_id must be provided. To obtain the appropriate order_id, use the GET /order endpoint to view all order records defined for your tenant and their current information. The details to be updated must also be provided. The endpoint returns the order_id and all of the details for the order record.

HTTP REQUEST

PUT /order/{order_id}

Delete an order record

Example Request

curl -X DELETE -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/order/cd10b1f0-a158-499c-b3d6-ce3277b779fe"
api_instance = nucleus_api.OrderApi(nucleus_api.ApiClient(configuration))
# # # # Delete a Order
order1_id = '4187bda1-6d2c-40f8-80cb-d048484bbeb6'
try:
    api_instance.delete_order_using_delete(order1_id)
except ApiException as e:
    print("Exception when delete_order_using_delete: %s\n" % e)
OrderApi apiInstance = new OrderApi();
//        //Delete a Order
        try {
            Order deleteresponse = apiInstance.deleteOrderUsingDelete(UUID.fromString("4c0a65f1-ed3b-4e99-9a6f-9c404bd1854c"));
            System.out.println(deleteresponse);
        } catch (ApiException e) {
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\OrderApi(
    new GuzzleHttp\Client(),
    $config);
//Delete Order
$order_did = "4c0a65f1-ed3b-4e99-9a6f-9c404bd1854c"; // string | UUID account_id

try {
    $apiInstance->deleteOrderUsingDelete($order_did);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->deleteOrderUsingDelete: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::OrderApi.new
#Delete Order
order1_id = 'cb3da452-ee4a-4fc1-9ff1-f0ab164e6a61'
begin
  result = api_instance.delete_order_using_delete(order1_id)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->delete_order_using_delete: #{e}"
end
var apiInstance = new HydrogenNucleusApi.OrderApi();
//Delete a Order
var orderidd = "e3e00162-d38b-404a-b1d2-9779f02b5dbd";


var deleteorder = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully.');
    }
};
apiInstance.deleteOrderUsingDelete(orderidd, deleteorder)

Response (204 No Content)

Permanently delete an order record. The unique order_id must be provided. To obtain the appropriate order_id, use the GET /order endpoint to view all order records defined for your tenant and their current information. This deletes the order_id and the order record information.

HTTP REQUEST

DELETE /order/{order_id}

Bulk Orders

Order records for each security can be aggregated into bulk orders by date at a firm, client, account, or portfolio level in order to optimize the number of transactions needed.

Field Type Description
order_bulk_id UUID The id of the bulk order
order_id UUID The id of the order record that is part of the bulk order
account_id UUID The id of the account that the order falls under
model_id UUID The id of the model associated with the order
portfolio_id UUID The id of the portfolio that the order falls under
date date Date for when the order was generated
metadata map Custom information associated with the entity in the format key:value
See Metadata
create_date timestamp Timestamp for the date and time that the record was created
update_date timestamp Timestamp for the date and time that the record was last updated

List all bulk orders

Example Request

curl -X GET -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/order_bulk"
api_instance = nucleus_api.OrderApi(nucleus_api.ApiClient(configuration))
try:
    api_response = api_instance.get_order_bulk_all_using_get()
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_order_bulk_all_using_get: %s\n" % e)
OrderApi apiInstance = new OrderApi();
        try {
            Object bulkOrder = apiInstance.getOrderBulkAllUsingGet(true, null, null, 0, 10);
            System.out.println(bulkOrder);
        } catch (ApiException e) {
            System.err.println("Exception when calling getOrderBulkAllUsingGet");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\OrderApi(
    new GuzzleHttp\Client(),
    $config);
$ascending = true; // bool | ascending
$filter = null; // string | filter
$order_by = null; // string | order_by
$page = 0; // int | page
$size = 10; // int | size

try {
    $bulkorders = $apiInstance->getOrderBulkAllUsingGet($ascending, $filter, $order_by, $page, $size);
    print_r($bulkorders);
} catch (Exception $e) {
    echo 'Exception when calling OrderApi->getOrderBulkAllUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::OrderApi.new
opts = {
    ascending: true, # BOOLEAN | ascending
    filter: null, # String | filter
    order_by: null, # String | order_by
    page: 0, # Integer | page
    size: 25 # Integer | size
}

begin
  bulkorder = api_instance.get_order_bulk_all_using_get(opts)
  p bulkorder
rescue NucleusApi::ApiError => e
  puts "Exception when calling OrderApi->get_order_bulk_all_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.OrderApi();
var opts = {
    'ascending': false, // Boolean | ascending
    // 'filter': "", // String | filter
    'orderBy': "update_date", // String | order_by
    'page': 0, // Number | page
    'size': 25 // Number | size
};

var bulkorder = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.getOrderBulkAllUsingGet(opts, bulkorder)

Example Response

{
  "content": [
    {
      "id": "67190064-0731-4b29-b2a7-4a35eb8e7afe",
      "create_date": "2018-02-07T19:29:37.000+0000",
      "update_date": "2018-02-12T09:00:00.000+0000",
      "order_id": "72c0c834-03e1-49c3-bf13-eb5adcba6e9e",
      "portfolio_id": "066304b6-017d-4c2c-8b76-92d772f1f3d5",
      "account_id": "066304b6-017d-4c2c-8b76-92d772f1f3d7",
      "model_id": "066304b6-017d-4c2c-8b76-92d772f1f3d8",
      "date": "2018-02-11",
      "metadata": {}
    },
    {
      "id": "f43a535b-477d-447c-99ca-b47cb2037849",
      "create_date": "2018-02-07T19:29:37.000+0000",
      "update_date": "2018-02-12T09:00:00.000+0000",
      "order_id": "a7376937-da3e-423c-9764-767c22bf89e8",
      "portfolio_id": "066304b6-017d-4c2c-8b76-92d772f1f3d5",
      "account_id": "066304b6-017d-4c2c-8b76-92d772f1f3d7",
      "model_id": "066304b6-017d-4c2c-8b76-92d772f1f3d8",
      "date": "2018-02-11",
      "metadata": {}
    }
  ],
  "last": true,
  "total_elements": 2,
  "total_pages": 1,
  "sort": [
    {
      "direction": "ASC",
      "property": "id",
      "ignore_case": false,
      "null_handling": "NATIVE",
      "ascending": true,
      "descending": false
    }
  ],
  "first": true,
  "number_of_elements": 2,
  "size": 25,
  "number": 0
}

Get the information for all bulk order records. The endpoint returns the list of ids for the bulk order, the ids for the order records that are part of each bulk order, the date for each order record, and the ids for the account, portfolios, and models that each order record falls under.

HTTP REQUEST

GET /order_bulk

Bulk orders for your tenant

Example Request

curl -X POST -H "Authorization: Bearer <access_token>" \
    -H "Content-Type: application/json" \
    -d '{
        "date":"2017-03-06",
        "buy_transaction_code_id": "f5af397b-7d22-433f-b01e-8202184a6386",
        "sell_transaction_code_id": "7d8d41d0-ed4b-4ae2-acb3-e0baed2ff1cc"
      }' "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/order_bulk"
api_instance = nucleus_api.OrderApi(nucleus_api.ApiClient(configuration))
# # Create a OrderBulk

order_bulk = nucleus_api.TokenDateRequest(account_id="ed58b488-b214-43d4-923f-5a7cc69f5407", sell_transaction_code_id="e658a046-8a66-4bfa-b990-b225fa1652c0", buy_transaction_code_id="5218388a-67e2-450e-9489-01c1b75b76e4")
try:
    api_response = api_instance.create_order_bulk_using_post(order_bulk)
    pprint(api_response)
except ApiException as e:
    print("create_order_bulk_using_post: %s\n" % e)
OrderApi apiInstance = new OrderApi();
//       //Create an Order Bulk
       OrderBulk bulkOrder = new OrderBulk();
       TokenDateRequest accountOrderbulk = new TokenDateRequest();
        accountOrderbulk.setDate(odt);
        accountOrderbulk.setBuyTransactionCodeId(UUID.fromString("6216575c-c171-4982-bb81-d496573776a9"));
        accountOrderbulk.setSellTransactionCodeId(UUID.fromString("2d1daf54-d434-4867-bb7f-89992b00b084"));

                try {
            List<Order> result = apiInstance.createOrderBulkUsingPost(accountOrderbulk);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling createOrderTrackUsingPost");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\OrderApi(
    new GuzzleHttp\Client(),
    $config);
//Create Order Bulk
$order_bulk = new \com\hydrogen\nucleus\Model\TokenDateRequest();

try {
    $order_bulk->setBuyTransactionCodeId("6216575c-c171-4982-bb81-d496573776a9");
    $order_bulk->setSellTransactionCodeId("2d1daf54-d434-4867-bb7f-89992b00b084");
    $order_bulk->setDate("2020-10-10");
    $result = $apiInstance->createOrderBulkUsingPost($order_bulk);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->createOrderBulkUsingPost: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::OrderApi.new

#Create Order Bulk
order_bulk = NucleusApi::TokenDateRequest.new

begin
  order_bulk.buy_transaction_code_id = "6216575c-c171-4982-bb81-d496573776a9"
  order_bulk.sell_transaction_code_id = "2d1daf54-d434-4867-bb7f-89992b00b084"
  order_bulk.date = "2020-10-10"
  result = api_instance.create_order_bulk_using_post(order_bulk)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->create_order_bulk_using_post: #{e}"
end
//Create a OrderBulk
var orderbulk = new HydrogenNucleusApi.TokenDateRequest();
orderbulk.buy_transaction_code_id = '6216575c-c171-4982-bb81-d496573776a9';
orderbulk.sell_transaction_code_id = '2d1daf54-d434-4867-bb7f-89992b00b084';
orderbulk.date = "2020-10-10";



var neworderbulk = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
 apiInstance.createOrderBulkUsingPost(orderbulk, neworderbulk)

Example Response

[
    {
        "id": "0bc55529-b998-42bc-9637-6a19b317760e",
        "create_date": "2017-03-06T18:09:27.031+0000",
        "update_date": "2017-03-06T18:09:27.031+0000",
        "transaction_code_id": "9e0b8266-5fe2-422a-bb2a-e0910225c39e",
        "order_bulk_id": "bc565812-d50e-49c5-9e4e-6bb6524dceb7",
        "date": "2017-03-06",
        "is_read": false,
        "order_ticket_id": "53eaa9da-9a5d-4e20-8e76-24aa8b1dd4d1",
        "quantity": 1,
        "security_id": "615e3777-98d6-48d6-a05b-9c000af5d4b6",
        "metadata": {},
        "price": 100
    },
    {
        "id": "8e658fe0-5309-42f2-805d-5cc76db1b3ca",
        "create_date": "2017-03-06T18:09:27.031+0000",
        "update_date": "2017-03-06T18:09:27.031+0000",
        "transaction_code_id": "9e0b8266-5fe2-422a-bb2a-e0910225c39e",
        "order_bulk_id": "bc565812-d50e-49c5-9e4e-6bb6524dceb7",
        "date": "2017-03-06",
        "is_read": false,
        "order_ticket_id": "f891c472-f534-40bb-b8bb-48fb6e62b1d2",
        "quantity": 4,
        "security_id": "a678d82d-2101-4966-89f3-cf57dcbed1c4",
        "metadata": {},
        "price": 65.44
    }
]

Aggregates all orders on a given date for your tenant. The specific date must be provided. This endpoint will net all the orders for that date to reduce the number of required transactions. The endpoint returns a list of all orders included in the bulk order, including a bulk_order_id which can be used to manage the bulk order record for all of the orders.

HTTP REQUEST

POST /order_bulk

ARGUMENTS

Parameter Type Required Description
date date required Date for all the orders that should be aggregated together in the bulk order record
buy_transaction_code_id string required The id of the transaction code that will ultimately be used to denote the buy transactions
sell_transaction_code_id string required The id of the transaction code that will ultimately be used to denote the sell transactions
metadata map optional Custom information associated with the entity in the format key:value
See Metadata

Bulk orders for a client

Example Request

curl -X POST -H "Authorization: Bearer <access_token>" \
    -H "Content-Type: application/json" \
    -d '{
        "date":"2017-03-06",
        "buy_transaction_code_id": "f5af397b-7d22-433f-b01e-8202184a6386",
        "sell_transaction_code_id": "7d8d41d0-ed4b-4ae2-acb3-e0baed2ff1cc"
      }' "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/client/c34794e9-f927-468b-b47e-ea17c3d533c5/order_bulk"
api_instance = nucleus_api.OrderApi(nucleus_api.ApiClient(configuration))
# # Create a OrderBulk

order_bulk = nucleus_api.TokenDateRequest(account_id="ed58b488-b214-43d4-923f-5a7cc69f5407", sell_transaction_code_id="e658a046-8a66-4bfa-b990-b225fa1652c0", buy_transaction_code_id="5218388a-67e2-450e-9489-01c1b75b76e4")
try:
    api_response = api_instance.create_order_bulk_using_post(order_bulk)
    pprint(api_response)
except ApiException as e:
    print("create_order_bulk_using_post: %s\n" % e)
OrderApi apiInstance = new OrderApi();
//       //Create an Order Bulk
       OrderBulk bulkOrder = new OrderBulk();
       TokenDateRequest accountOrderbulk = new TokenDateRequest();
        accountOrderbulk.setDate(odt);
        accountOrderbulk.setBuyTransactionCodeId(UUID.fromString("6216575c-c171-4982-bb81-d496573776a9"));
        accountOrderbulk.setSellTransactionCodeId(UUID.fromString("2d1daf54-d434-4867-bb7f-89992b00b084"));

                try {
            List<Order> result = apiInstance.createOrderBulkUsingPost(accountOrderbulk);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling createOrderTrackUsingPost");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\OrderApi(
    new GuzzleHttp\Client(),
    $config);
//Create Order Bulk
$order_bulk = new \com\hydrogen\nucleus\Model\TokenDateRequest();

try {
    $order_bulk->setBuyTransactionCodeId("6216575c-c171-4982-bb81-d496573776a9");
    $order_bulk->setSellTransactionCodeId("2d1daf54-d434-4867-bb7f-89992b00b084");
    $order_bulk->setDate("2020-10-10");
    $result = $apiInstance->createOrderBulkUsingPost($order_bulk);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->createOrderBulkUsingPost: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::OrderApi.new

#Create Order Bulk
order_bulk = NucleusApi::TokenDateRequest.new

begin
  order_bulk.buy_transaction_code_id = "6216575c-c171-4982-bb81-d496573776a9"
  order_bulk.sell_transaction_code_id = "2d1daf54-d434-4867-bb7f-89992b00b084"
  order_bulk.date = "2020-10-10"
  result = api_instance.create_order_bulk_using_post(order_bulk)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->create_order_bulk_using_post: #{e}"
end
//Create a OrderBulk
var orderbulk = new HydrogenNucleusApi.TokenDateRequest();
orderbulk.buy_transaction_code_id = '6216575c-c171-4982-bb81-d496573776a9';
orderbulk.sell_transaction_code_id = '2d1daf54-d434-4867-bb7f-89992b00b084';
orderbulk.date = "2020-10-10";

var neworderbulk = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
 apiInstance.createOrderBulkUsingPost(orderbulk, neworderbulk)

Example Response

[
    {
        "id": "0bc55529-b998-42bc-9637-6a19b317760e",
        "create_date": "2017-03-06T18:09:27.031+0000",
        "update_date": "2017-03-06T18:09:27.031+0000",
        "transaction_code_id": "9e0b8266-5fe2-422a-bb2a-e0910225c39e",
        "order_bulk_id": "bc565812-d50e-49c5-9e4e-6bb6524dceb7",
        "date": "2017-03-06",
        "is_read": false,
        "order_ticket_id": "53eaa9da-9a5d-4e20-8e76-24aa8b1dd4d1",
        "quantity": 1,
        "security_id": "615e3777-98d6-48d6-a05b-9c000af5d4b6",
        "metadata": {},
        "price": 100
    },
    {
        "id": "8e658fe0-5309-42f2-805d-5cc76db1b3ca",
        "create_date": "2017-03-06T18:09:27.031+0000",
        "update_date": "2017-03-06T18:09:27.031+0000",
        "transaction_code_id": "9e0b8266-5fe2-422a-bb2a-e0910225c39e",
        "order_bulk_id": "bc565812-d50e-49c5-9e4e-6bb6524dceb7",
        "date": "2017-03-06",
        "is_read": false,
        "order_ticket_id": "f891c472-f534-40bb-b8bb-48fb6e62b1d2",
        "quantity": 4,
        "security_id": "a678d82d-2101-4966-89f3-cf57dcbed1c4",
        "metadata": {},
        "price": 65.44
    }
]

Aggregates all orders on a given date for a client. The unique client_id and the specific date must be provided. To obtain the appropriate client_id, use the GET /client endpoint to view all clients registered with your tenant. This endpoint will net all the client’s orders for that date to reduce the number of required transactions. The endpoint returns a list of all orders included in the bulk order, including a bulk_order_id which can be used to manage the bulk order record for all of the orders.

HTTP REQUEST

POST /client/{client_id}/order_bulk

ARGUMENTS

Parameter Type Required Description
date date required Date for all the orders that should be aggregated together in the bulk order record
buy_transaction_code_id string required The id of the transaction code that will ultimately be used to denote the buy transactions
sell_transaction_code_id string required The id of the transaction code that will ultimately be used to denote the sell transactions

Bulk orders for an account

Example Request

curl -X POST -H "Authorization: Bearer <access_token>" \
    -H "Content-Type: application/json" \
    -d '{
        "date":"2017-03-06",
        "buy_transaction_code_id": "f5af397b-7d22-433f-b01e-8202184a6386",
        "sell_transaction_code_id": "7d8d41d0-ed4b-4ae2-acb3-e0baed2ff1cc"
      }' "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/account/066304b6-017d-4c2c-8b76-92d772f1f3d7/order_bulk"

Example Response

[
    {
        "id": "0bc55529-b998-42bc-9637-6a19b317760e",
        "create_date": "2017-03-06T18:09:27.031+0000",
        "update_date": "2017-03-06T18:09:27.031+0000",
        "transaction_code_id": "9e0b8266-5fe2-422a-bb2a-e0910225c39e",
        "order_bulk_id": "bc565812-d50e-49c5-9e4e-6bb6524dceb7",
        "date": "2017-03-06",
        "price": 100,
        "is_read": false,
        "order_ticket_id": "53eaa9da-9a5d-4e20-8e76-24aa8b1dd4d1",
        "quantity": 1,
        "security_id": "615e3777-98d6-48d6-a05b-9c000af5d4b6",
        "metadata": {}
    },
    {
        "id": "8e658fe0-5309-42f2-805d-5cc76db1b3ca",
        "create_date": "2017-03-06T18:09:27.031+0000",
        "update_date": "2017-03-06T18:09:27.031+0000",
        "transaction_code_id": "9e0b8266-5fe2-422a-bb2a-e0910225c39e",
        "order_bulk_id": "bc565812-d50e-49c5-9e4e-6bb6524dceb7",
        "date": "2017-03-06",
        "price": 65.44,
        "is_read": false,
        "order_ticket_id": "f891c472-f534-40bb-b8bb-48fb6e62b1d2",
        "quantity": 4,
        "security_id": "a678d82d-2101-4966-89f3-cf57dcbed1c4",
        "metadata": {}
    }
]

Aggregates all orders on a given date for an account . The unique account_id and the specific date must be provided. To obtain the appropriate account_id, use the GET /account endpoint to view all accounts defined for your tenant. This endpoint will net all the orders on that date for the account to reduce the number of required transactions. The endpoint returns a list of all orders included in the bulk order, including a bulk_order_id which can be used to manage the bulk order record for all of the orders.

HTTP REQUEST

POST /account/{account_id}/order_bulk

ARGUMENTS

Parameter Type Required Description
date date required Date for all the orders that should be aggregated together in the bulk order record
buy_transaction_code_id string required The id of the transaction code that will ultimately be used to denote the buy transactions
sell_transaction_code_id string required The id of the transaction code that will ultimately be used to denote the sell transactions

Sell all account order

Example Request

curl -X POST -H "Authorization: Bearer <access_token>" \
    -H "Content-Type: application/json" \
    -d '{
            "sell_transaction_code_id": "7d8d41d0-ed4b-4ae2-acb3-e0baed2ff1cc"
      }' "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/account/52654829-e80b-4f16-9f8b-c9fde8a1aa63/order_sell_all"

Example Response

[
    {
        "id": "67190064-0731-4b29-b2a7-4a35eb8e7afe",
        "create_date": "2018-02-07T19:29:37.000+0000",
        "update_date": "2018-02-12T09:00:00.000+0000",
        "transaction_code_id": "f5af397b-7d22-433f-b01e-8202184a6386",
        "order_bulk_id": "114556fe-ee78-431d-be5e-60ae08ddf9a7",
        "date": "2017-03-06",
        "price": 51.25,
        "is_read": false,
        "order_ticket_id": "5da53a30-49e6-4162-8728-58d6348bfb24",
        "quantity": 4,
        "security_id": "000cb131-0b59-4b14-a0ef-e7832d5ecf51",
        "account_id": "c80c9729-3fd5-4a2f-be8e-915cdf21b49d",
        "portfolio_id": "665969c4-7b2d-44f8-91de-4607416c75cf",
        "model_id": "f43a535b-477d-447c-99ca-b47cb2037849",
        "metadata": {}
    },
    {
        "id": "35895811-9b52-4497-ac47-7ceba25dc4e5",
        "create_date": "2018-02-07T19:29:37.000+0000",
        "update_date": "2018-02-12T09:00:00.000+0000",
        "transaction_code_id": "f5af397b-7d22-433f-b01e-8202184a6386",
        "order_bulk_id": "114556fe-ee78-431d-be5e-60ae08ddf9a7",
        "date": "2017-03-06",
        "price": 40.5,
        "is_read": false,
        "order_ticket_id": "5da53a30-49e6-4162-8728-58d6348bfb24",
        "quantity": 4,
        "security_id": "351c6084-1ed2-4b48-ba8e-fa8fe9709756",
        "account_id": "c80c9729-3fd5-4a2f-be8e-915cdf21b49d",
        "portfolio_id": "665969c4-7b2d-44f8-91de-4607416c75cf",
        "model_id": "8ac591a5-fa28-4880-b066-3db3d61c6bf9",
        "metadata": {}
    },
  ]

Create order records necessary to entirely sell all the holdings within an account. Securities will only be sold; no securities will be bought. The unique account_id must be provided. To obtain the appropriate account_id, use the GET /account endpoint to view all of the accounts defined for your tenant. The endpoint returns a series of order records with order_ids and their underlying information, similar to the GET /order endpoint.

HTTP REQUEST

POST /account/{account_id}/order_sell_all

ARGUMENTS

Parameter Type Required Description
sell_transaction_code_id UUID required The id of the transaction code to denote a buy transaction
buy_transaction_code_id UUID optional The id of the transaction code to denote a buy transaction
buy_threshold double optional Buying threshold for the account as a monetary amount. Defaults to 0
cash_portfolio_id UUID optional The id of the cash portfolio for the account
commit_orders boolean optional Indicates if the orders should be committed for execution. Defaults to true which indicates they should be committed
non_fractional boolean optional Indicates if purchasing/selling fractional shares of securities is allowed. Defaults to false which indicates it is allowed
port_threshold double optional Threshold for the portfolio as a monetary amount. Defaults to 0
restrictions_on boolean optional Indicates if there are restrictions on the account that should be followed. Defaults to false which indicates there are not
sell_threshold double optional Selling threshold for the account as a monetary amount. Defaults to 0

Sell all portfolio order

curl -X POST -H "Authorization: Bearer <access_token>" \
    -H "Content-Type: application/json" \
    -d '{
            "sell_transaction_code_id": "7d8d41d0-ed4b-4ae2-acb3-e0baed2ff1cc"
      }' "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/portfolio/ef93ce1c-b50e-4856-803a-db5332be93b0/order_sell_all"

Example Response

[
    {
        "id": "67190064-0731-4b29-b2a7-4a35eb8e7afe",
        "create_date": "2018-02-07T19:29:37.000+0000",
        "update_date": "2018-02-12T09:00:00.000+0000",
        "transaction_code_id": "f5af397b-7d22-433f-b01e-8202184a6386",
        "order_bulk_id": "114556fe-ee78-431d-be5e-60ae08ddf9a7",
        "date": "2017-03-06",
        "price": 51.25,
        "is_read": false,
        "order_ticket_id": "5da53a30-49e6-4162-8728-58d6348bfb24",
        "quantity": 4,
        "portfolio_id": "8bf331f7-c7c6-46b5-b57b-36fcffdd5cbb",
        "security_id": "000cb131-0b59-4b14-a0ef-e7832d5ecf51",
        "account_id": "c80c9729-3fd5-4a2f-be8e-915cdf21b49d",
        "model_id": "f43a535b-477d-447c-99ca-b47cb2037849",
        "metadata": {}
    },
    {
        "id": "35895811-9b52-4497-ac47-7ceba25dc4e5",
        "create_date": "2018-02-07T19:29:37.000+0000",
        "update_date": "2018-02-12T09:00:00.000+0000",
        "transaction_code_id": "f5af397b-7d22-433f-b01e-8202184a6386",
        "order_bulk_id": "114556fe-ee78-431d-be5e-60ae08ddf9a7",
        "date": "2017-03-062",
        "price": 40.5,
        "is_read": false,
        "order_ticket_id": "5da53a30-49e6-4162-8728-58d6348bfb24",
        "quantity": 4,
        "portfolio_id": "8bf331f7-c7c6-46b5-b57b-36fcffdd5cbb",
        "security_id": "351c6084-1ed2-4b48-ba8e-fa8fe9709756",
        "account_id": "c80c9729-3fd5-4a2f-be8e-915cdf21b49d",
        "model_id": "f43a535b-477d-447c-99ca-b47cb2037849",
        "metadata": {}
    }
]

Create order records necessary to entirely sell all the holdings within a portfolio. Securities will only be sold; no securities will be bought. The unique portfolio_id must be provided. To obtain the appropriate portfolio_id, use the GET /portfolio endpoint to view all of the portfolios defined for your tenant. The endpoint returns a series of order records with order_ids and their underlying information, similar to the GET /order endpoint.

HTTP REQUEST

POST /portfolio/{portfolio_id}/order_sell_all

ARGUMENTS

Parameter Type Required Description
sell_transaction_code_id UUID required The id of the transaction code to denote a buy transaction
buy_transaction_code_id UUID optional The id of the transaction code to denote a buy transaction
buy_threshold double optional Buying threshold for the account as a monetary amount. Defaults to 0
cash_sec_id UUID optional The id of the cash security for the portfolio
commit_orders boolean optional Indicates if the orders should be committed for execution. Defaults to true which indicates they should be committed
non_fractional boolean optional Indicates if purchasing/selling fractional shares of securities is allowed. Defaults to false which indicates it is allowed
port_threshold double optional Threshold for the portfolio as a monetary amount. Defaults to 0
restrictions_on boolean optional Indicates if there are restrictions on the account that should be followed. Defaults to false which indicates there are not
sell_threshold double optional Selling threshold for the account as a monetary amount. Defaults to 0

Order Status

Order statuses are assigned to order track records to track the progress of the order record. For example, an order status can be used to track that an order ticket was passed to an agent for execution, or that an order is pending settlement.

Field Type Description
id UUID The id of the order status
status string Value of the order status such as “Passed to Agent”
description string Additional description of the order status
metadata map Custom information associated with the entity in the format key:value. See Metadata
create_date timestamp Timestamp for the date and time that the record was created
update_date timestamp Timestamp for the date and time that the record was last updated

List all order statuses

Example Request

curl -X GET -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/order_status"
api_instance = nucleus_api.OrderApi(nucleus_api.ApiClient(configuration))
try:
    api_response = api_instance.get_order_status_all_using_get()
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_order_status_all_using_get: %s\n" % e)
OrderApi apiInstance = new OrderApi();
        try {
            PageOrderStatus List = apiInstance.getOrderStatusAllUsingGet(true, null, null, 0, 10);
            System.out.println(List);
        } catch (ApiException e) {
            System.err.println("Exception when calling getOrderStatusAllUsingGet");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\OrderApi(
    new GuzzleHttp\Client(),
    $config);
$ascending = false; // bool | ascending
$filter = null; // string | filter
$order_by = null; // string | order_by
$page = 0; // int | page
$size =10; // int | size

try {
    $orderstatuslist = $apiInstance->getOrderStatusAllUsingGet($ascending, $filter, $order_by, $page, $size);
    print_r($orderstatuslist);
} catch (Exception $e) {
    echo 'Exception when calling OrderApi->getOrderStatusAllUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::OrderApi.new
opts = {
    ascending: false, # BOOLEAN | ascending
    filter: null, # String | filter
    order_by: null, # String | order_by
    page: 0, # Integer | page
    size: 25 # Integer | size
}

begin
  orderstatuslist = api_instance.get_order_status_all_using_get(opts)
  p orderstatuslist
rescue NucleusApi::ApiError => e
  puts "Exception when calling OrderApi->get_order_status_all_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.OrderApi();
var opts = {
    'ascending': false, // Boolean | ascending
    // 'filter': "", // String | filter
    'orderBy': "update_date", // String | order_by
    'page': 0, // Number | page
    'size': 25 // Number | size
};

var orderstatuslist = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.getOrderStatusAllUsingGet(opts, orderstatuslist)

Example Response

{
  "content": [
    {
      "id": "9b515c67-3791-400f-9da4-9dc69eb992ac",
      "create_date": "2018-02-07T19:29:37.000+0000",
      "update_date": "2018-02-12T09:00:00.000+0000",
      "description": "orders have been executed",
      "status": "complete",
      "metadata": {}
    }
  ],
  "last": true,
  "total_elements": 1,
  "total_pages": 1,
  "sort": [
    {
      "direction": "DESC",
      "property": "id",
      "ignore_case": false,
      "null_handling": "NATIVE",
      "ascending": false,
      "descending": true
    }
  ],
  "first": true,
  "number_of_elements": 1,
  "size": 25,
  "number": 0
}

Get the information for all order statuses defined for your tenant. The endpoint returns a list of ids with details for each order status.

HTTP REQUEST

GET /order_status

Create an order status

Example Request

curl -X POST -H "Authorization: Bearer <access_token>" \
    -H "Content-Type: application/json" \
    -d '{
          "description": "orders have been executed",
          "status": "complete"
      }' "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/order_status"
api_instance = nucleus_api.OrderApi(nucleus_api.ApiClient(configuration))

# Create a OrderStatus
order_status = nucleus_api.OrderStatus(status="created", description="New")
try:
    api_response = api_instance.create_order_status_using_post(order_status)
    pprint(api_response)
except ApiException as e:
    print("create_order_status_using_post: %s\n" % e)
OrderApi apiInstance = new OrderApi();
        //Create a Order Status
        OrderStatus statusOrder = new OrderStatus();
        statusOrder.setStatus("new");
        statusOrder.setDescription("new Status");

        try {
            OrderStatus result = apiInstance.createOrderStatusUsingPost(statusOrder);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling createOrderStatusUsingPost");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\OrderApi(
    new GuzzleHttp\Client(),
    $config);
//Create Order Status
$order_status = new \com\hydrogen\nucleus\Model\OrderStatus();

try {
    $order_status->setStatus("New");
    $order_status->setDescription("ABC");
    $result = $apiInstance->createOrderStatusUsingPost($order_status);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->createOrderStatusUsingPost: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::OrderApi.new
#Create Order Status
order_status = NucleusApi::OrderStatus.new

begin
  order_status.status = "New"
  order_status.description = "New Id"
  result = api_instance.create_order_status_using_post(order_status)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->create_order_status_using_post: #{e}"
end
var apiInstance = new HydrogenNucleusApi.OrderApi();
//Create a OrderStatus
var orderstatus = new HydrogenNucleusApi.OrderStatus();
orderstatus.status = "New";
orderstatus.description = "abc";


var neworderstatus = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.createOrderStatusUsingPost(orderstatus, neworderstatus)

Example Response

{
  "id": "9b515c67-3791-400f-9da4-9dc69eb992ac",
  "create_date": "2018-02-07T19:29:37.000+0000",
  "description": "orders have been executed",
  "status": "complete",
  "metadata": {}
}

Create an order status for your tenant. An order status represents a step in the order track process and the it can later be assigned to order records. Must provide the status value (ex. “Passed to Agent”) and the status description. The create_date will default to the current date. The endpoint returns a order_status_id used to manage the order status and to assign it to order records later on.

HTTP REQUEST

POST /order_status

ARGUMENTS

Parameter Type Required Description
status string required Value of the order status such as “Passed to Agent”
description string required Additional description of the order status
metadata map optional Custom information associated with the entity in the format key:value. See Metadata

Retrieve an order status

Example Request

curl -X GET -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/order_status/9b515c67-3791-400f-9da4-9dc69eb992ac"
api_instance = nucleus_api.OrderApi(nucleus_api.ApiClient(configuration))
try:
    api_response = api_instance.get_order_status_using_get("d399b488-dfdb-41ad-b782-b1d892fcc25d")
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_order_status_using_get: %s\n" % e)
OrderApi apiInstance = new OrderApi();
        try {
            OrderStatus responseStatus = apiInstance.getOrderStatusUsingGet(UUID.fromString("515280c6-90f4-43dd-8643-3ef2c7cbe3dc"));
            System.out.println(responseStatus);
        } catch (ApiException e) {
            System.err.println("Exception when calling getOrderStatusUsingGet");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\OrderApi(
    new GuzzleHttp\Client(),
    $config);
$order_status_id = "515280c6-90f4-43dd-8643-3ef2c7cbe3dc"; // string | UUID order_status_id

try {
    $orderstatus = $apiInstance->getOrderStatusUsingGet($order_status_id);
    print_r($orderstatus);
} catch (Exception $e) {
    echo 'Exception when calling OrderApi->getOrderStatusUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::OrderApi.new
order_status_id = '515280c6-90f4-43dd-8643-3ef2c7cbe3dc' # String | UUID order_status_id


begin
  orderstatus = api_instance.get_order_status_using_get(order_status_id)
  p orderstatus
rescue NucleusApi::ApiError => e
  puts "Exception when calling OrderApi->get_order_status_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.OrderApi();
var orderstatusID = "515280c6-90f4-43dd-8643-3ef2c7cbe3dc";

var opts = {
    'currencyConversion': null, // String | USD
};

var orderstatus = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.getOrderStatusUsingGet(orderstatusID, orderstatus)

Example Response

{
  "id": "9b515c67-3791-400f-9da4-9dc69eb992ac",
  "create_date": "2018-02-07T19:29:37.000+0000",
  "update_date": "2018-02-12T09:00:00.000+0000",
  "description": "orders have been executed",
  "status": "complete",
  "metadata": {}
}

Retrieve the information for an order status defined for your tenant. The unique order_status_id must be provided. The endpoint returns the details for the order status specified.

HTTP REQUEST

GET /order_status/{order_status_id}

Update an order status

Example Request

curl -X PUT -H "Authorization: Bearer <access_token>" \
    -H "Content-Type: application/json" \
    -d '{
        "description": "orders have not been executed",
        "status": "not complete"
    }' "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/order_status/9b515c67-3791-400f-9da4-9dc69eb992ac"
api_instance = nucleus_api.OrderApi(nucleus_api.ApiClient(configuration))
# # Update a OrderStatus
order_status_update = {'status': 'Updated'}
order_status_id = 'd97c53b6-bc44-4616-9f83-54dc42b3d24f'
try:
    api_response = api_instance.update_order_status_using_put(order_status_update, order_status_id)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling update_order_status_using_put: %s\n" % e)
OrderApi apiInstance = new OrderApi();
        //        //Update a OrdeStatus
        Map map2 = new HashMap();
        map.put("status", "created");


        try {
            OrderStatus response = apiInstance.updateOrderStatusUsingPut(map2, UUID.fromString("d97c53b6-bc44-4616-9f83-54dc42b3d24f"));
            System.out.println(response);
        } catch (ApiException e) {
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\OrderApi(
    new GuzzleHttp\Client(),
    $config);

//Update Order Status
$orderstatus_update = new stdClass();
$orderstatus_id = "0bff9523-8975-4dfd-a9b8-44a02800140f";

try {
    $orderstatus_update->status = "neew";
    $result = $apiInstance->updateOrderStatusUsingPut($orderstatus_update, $orderstatus_id);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->updateOrderStatusUsingPut: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::OrderApi.new
#Update Order Status
order_status_update = {"status" => 'new'}
order_status_id = '2a70e5e7-9cfe-4873-8041-c966b4aff772'
begin
  result = api_instance.update_order_status_using_put(order_status_update, order_status_id)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->update_order_status_using_put: #{e}"
end
var apiInstance = new HydrogenNucleusApi.OrderApi();
//Update OrderStatus
var apiInstance = new HydrogenNucleusApi.OrderApi();
var callback = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
var orderstatusupdate = new HydrogenNucleusApi.OrderStatus();
var orderstatusid = 'efe676b9-0a55-4469-ae90-b9efda4c7571';

orderstatusupdate.status = "New";
apiInstance.updateOrderStatusUsingPut(orderstatusid, orderstatusupdate, callback)

Example Response

{
    "id": "9b515c67-3791-400f-9da4-9dc69eb992ac",
    "create_date": "2018-02-07T19:29:37.000+0000",
    "update_date": "2018-02-12T09:00:00.000+0000",
    "description": "orders have not been executed",
    "status": "not complete",
    "metadata": {}
}

Update the information for an order status defined for your tenant. The unique order_status_id must be provided. To obtain the appropriate order_status_id, use the GET /order_status endpoint to view all order statuses defined for your tenant and their current information. The details to be updated must also be provided. The endpoint returns the order_status_id and all of the details for the order status.

HTTP REQUEST

PUT /order_status/{order_status_id}

Delete an order status

Example Request

curl -X DELETE -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/order_status/9b515c67-3791-400f-9da4-9dc69eb992ac"
api_instance = nucleus_api.OrderApi(nucleus_api.ApiClient(configuration))
# # # # Delete a OrderStatus
order1_status_id = '2e25591d-2dfc-4a41-8387-6b01506dc703'
try:
    api_instance.delete_order_status_using_delete(order1_status_id)
except ApiException as e:
    print("Exception when delete_order_status_using_delete: %s\n" % e)
OrderApi apiInstance = new OrderApi();

        //        //Delete a OrderStatus
        try {
            OrderStatus deleteresponse = apiInstance.deleteOrderStatusUsingDelete(UUID.fromString("0bff9523-8975-4dfd-a9b8-44a02800140f"));
            System.out.println(deleteresponse);
        } catch (ApiException e) {
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\OrderApi(
    new GuzzleHttp\Client(),
    $config);
//Delete Order Status
$orderstatus_did = "2a70e5e7-9cfe-4873-8041-c966b4aff772"; // string | UUID account_id

try {
    $apiInstance->deleteOrderStatusUsingDelete($orderstatus_did);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->deleteOrderStatusUsingDelete: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::OrderApi.new

#Delete Order Status
order_status1_id = 'efe676b9-0a55-4469-ae90-b9efda4c7571'
begin
  result = api_instance.delete_order_status_using_delete(order_status1_id)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->delete_order_status_using_delete: #{e}"
end
var apiInstance = new HydrogenNucleusApi.OrderApi();
//Delete a Order
var orderstatusidd = "b59c8fee-f2a2-4420-bf33-c4d1231ab6d7";


var deleteorderstatus = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully.');
    }
};
apiInstance.deleteOrderStatusUsingDelete(orderstatusidd, deleteorderstatus)

Response (204 No Content)

Permanently delete an order status defined for your tenant. The unique order_status_id must be provided. To obtain the appropriate order_status_id, use the GET /order_status endpoint to view all order statuses defined for your tenant. Deletes the order_status_id and the order status so that it can no longer be assigned to order track records.

HTTP REQUEST

DELETE /order_status/{order_status_id}

Order Tracking

Order tracking records are created to store the order status history of an order record and information on the order ticket that was carried out by the agent (ex. commission or fees).

Field Type Description
id UUID The id of the order track record
order_id UUID The id of the order to which the order track record belongs
order_status_id UUID The id of the order status currently assigned to the order track record
date date Date of the order track record
commission double Commission earned by the agent on the order
external_track_id UUID The external id used by the agent or other party executing the order to track the order ticket (if provided)
fee double Total fees associated with the order
price double Execution price at which the securities in the order were bought or sold
quantity double Quantity of securities that were bought or sold
metadata map Custom information associated with the order tracking record in the format key:value. See Metadata
create_date timestamp Timestamp for the date and time that the record was created
update_date timestamp Timestamp for the date and time that the record was last updated

List all order tracking records

Example Request

curl -X GET -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/order_track"
api_instance = nucleus_api.OrderApi(nucleus_api.ApiClient(configuration))
try:
    api_response = api_instance.get_order_track_all_using_get()
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_order_track_all_using_get: %s\n" % e)
OrderApi apiInstance = new OrderApi();
        try {
            PageOrderTrack List = apiInstance.getOrderTrackAllUsingGet(true, null, null, 0, 10);
            System.out.println(List);
        } catch (ApiException e) {
            System.err.println("Exception when calling getOrderTrackAllUsingGet");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\OrderApi(
    new GuzzleHttp\Client(),
    $config);
$ascending = false; // bool | ascending
$filter = null; // string | filter
$order_by = null; // string | order_by
$page = 0; // int | page
$size = 10; // int | size

try {
    $ordertrackinglist = $apiInstance->getOrderTrackAllUsingGet($ascending, $filter, $order_by, $page, $size);
    print_r($ordertrackinglist);
} catch (Exception $e) {
    echo 'Exception when calling OrderApi->getOrderTrackAllUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::OrderApi.new
opts = {
    ascending: false, # BOOLEAN | ascending
    filter: null, # String | filter
    order_by: null, # String | order_by
    page: 0, # Integer | page
    size: 25 # Integer | size
}

begin
  trackinglist = api_instance.get_order_track_all_using_get(opts)
  p trackinglist
rescue NucleusApi::ApiError => e
  puts "Exception when calling OrderApi->get_order_track_all_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.OrderApi();
var opts = {
    'ascending': false, // Boolean | ascending
    // 'filter': "", // String | filter
    'orderBy': "update_date", // String | order_by
    'page': 0, // Number | page
    'size': 25 // Number | size
};

var ordertracklist = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.getOrderTrackAllUsingGet(opts, ordertracklist)

Example Response

{
  "content": [
    {
      "id": "ef93ce1c-b50e-4856-803a-db5332be93b0",
      "create_date": "2018-02-07T19:29:37.000+0000",
      "update_date": "2018-02-12T09:00:00.000+0000",
      "commission": 10,
      "date": "2018-02-11",
      "fee": 5,
      "price": 55,
      "quantity": 5,
      "order_id": "a20c0b29-836f-419d-9000-b47e4392d5f1",
      "order_status_id": "9b515c67-3791-400f-9da4-9dc69eb992ac",
      "metadata": {
        "order_management_system": "IBM",
        "order_settlement": "T+3"
      }
    }
  ],
  "last": true,
  "total_elements": 1,
  "total_pages": 1,
  "sort": [
    {
      "direction": "DESC",
      "property": "id",
      "ignore_case": false,
      "null_handling": "NATIVE",
      "ascending": false,
      "descending": true
    }
  ],
  "first": true,
  "number_of_elements": 1,
  "size": 25,
  "number": 0
}

Get the information for all order tracking record for all order records. You can filter using order_id to view all order tracking records for a specific order. Note that the metadata is stored as a nested object within the order tracking object.

HTTP REQUEST

GET /order_track

Create an order tracking record

Example Request

curl -X POST -H "Authorization: Bearer <access_token>" \
    -H "Content-Type: application/json" \
    -d '{
          "commission": 10,
          "date": "2018-02-11",
          "fee": 5,
          "price": 55,
          "quantity": 5,
          "order_id": "a20c0b29-836f-419d-9000-b47e4392d5f1",
          "order_status_id": "9b515c67-3791-400f-9da4-9dc69eb992ac"
      }' "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/order_track"
api_instance = nucleus_api.OrderApi(nucleus_api.ApiClient(configuration))

# # Create a OrderTrack
order_track = nucleus_api.OrderTrack(order_id="4b08bc2e-e98b-4273-88e7-fb07280eb18e", order_status_id="3cb05271-8fe2-49d9-8aea-190cf5885596", _date="2020-10-10")
try:
    api_response = api_instance.create_order_track_using_post(order_track)
    pprint(api_response)
except ApiException as e:
    print("create_order_track_using_post: %s\n" % e)
OrderApi apiInstance = new OrderApi();
       //Create an Order Track
        OrderTrack trackOrder = new OrderTrack();
        trackOrder.setOrderId(UUID.fromString("4b08bc2e-e98b-4273-88e7-fb07280eb18e"));
        trackOrder.setOrderStatusId(UUID.fromString("3cb05271-8fe2-49d9-8aea-190cf5885596"));
        trackOrder.setDate(startdate);

        try {
            OrderTrack result = apiInstance.createOrderTrackUsingPost(trackOrder);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling createOrderTrackUsingPost");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\OrderApi(
    new GuzzleHttp\Client(),
    $config);
//Create Order Track
$order_track = new \com\hydrogen\nucleus\Model\OrderTrack();

try {
    $order_track->setOrderId("4b08bc2e-e98b-4273-88e7-fb07280eb18e");
    $order_track->setOrderStatusId("3cb05271-8fe2-49d9-8aea-190cf5885596");
    $order_track->setDate("2020-10-10");

    $result = $apiInstance->createOrderTrackUsingPost($order_track);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->createOrderTrackUsingPost: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::OrderApi.new

#Create Order Track
order_track = NucleusApi::OrderTrack.new

begin
  order_track.order_id = "4b08bc2e-e98b-4273-88e7-fb07280eb18e"
  order_track.order_status_id = "3cb05271-8fe2-49d9-8aea-190cf5885596"
  order_track.date = "2020-10-10"
  result = api_instance.create_order_track_using_post(order_track)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->create_order_track_using_post: #{e}"
end
var apiInstance = new HydrogenNucleusApi.OrderApi();
//Create a OrderTrack
var ordertrack = new HydrogenNucleusApi.OrderTrack();
ordertrack.order_id = '4b08bc2e-e98b-4273-88e7-fb07280eb18e';
ordertrack.order_status_id = '3cb05271-8fe2-49d9-8aea-190cf5885596';
ordertrack.date = "2020-10-01";



var newordertrack = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.createOrderTrackUsingPost(ordertrack, newordertrack)

Example Response

{
    "id": "ef93ce1c-b50e-4856-803a-db5332be93b0",
    "create_date": "2018-02-07T19:29:37.000+0000",
    "commission": 10,
    "date": "2018-02-11",
    "fee": 5,
    "price": 55,
    "quantity": 5,
    "order_id": "a20c0b29-836f-419d-9000-b47e4392d5f1",
    "order_status_id": "9b515c67-3791-400f-9da4-9dc69eb992ac",
    "metadata": {}
}

Create a new order tracking record for an order. The unique order_id and the unique order_status_id and the date for the tracking record must be provided. To obtain the appropriate order_id, use the GET /order endpoint to view all order records defined for your tenant. To obtain the appropriate order_status_id, use the GET /order_status endpoint to view all order statuses defined for your tenant. The create_date will default to the current date. The endpoint returns an order_tracking_id used to manage the order tracking record.

HTTP REQUEST

POST /order_track

ARGUMENTS

Parameter Type Required Description
order_id UUID required The id of the order that the to which order track record belongs
order_status_id UUID required The id of the order status currently assigned to the order track record
date date required Date of the order track record
commission double optional Commission earned by the agent on the order
external_track_id UUID optional The external id used by the agent or other party executing the order to track the order ticket (if provided)
fee double optional Total fees associated with the order
price double optional Execution price at which the securities in the order were bought or sold
quantity double optional Quantity of securities that were bought or sold
metadata map optional Custom information associated with the order tracking record in the format key:value. See Metadata

Retrieve an order tracking record

Example Request

curl -X GET -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/order_track/ef93ce1c-b50e-4856-803a-db5332be93b0"
api_instance = nucleus_api.OrderApi(nucleus_api.ApiClient(configuration))
try:
    api_response = api_instance.get_order_track_using_get("90abf348-ffcb-406e-9854-8e73ce8b1cd3")
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_order_track_using_get: %s\n" % e)
OrderApi apiInstance = new OrderApi();
        try {
            OrderTrack responseTrack = apiInstance.getOrderTrackUsingGet(UUID.fromString("fc5fc37f-8414-4005-9619-b6a2bd8acd90"));
            System.out.println(responseTrack);
        } catch (ApiException e) {
            System.err.println("Exception when calling getOrderTrackUsingGet");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\OrderApi(
    new GuzzleHttp\Client(),
    $config);
$order_track_id = "fc5fc37f-8414-4005-9619-b6a2bd8acd90"; // string | UUID order_track_id

try {
    $ordertracking = $apiInstance->getOrderTrackUsingGet($order_track_id);
    print_r($ordertracking);
} catch (Exception $e) {
    echo 'Exception when calling OrderApi->getOrderTrackUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::OrderApi.new
order_track_id = 'fc5fc37f-8414-4005-9619-b6a2bd8acd90' # String | UUID order_track_id


begin
  ordertrack = api_instance.get_order_track_using_get(order_track_id)
  p ordertrack
rescue NucleusApi::ApiError => e
  puts "Exception when calling OrderApi->get_order_track_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.OrderApi();
var ordertrackID = "fc5fc37f-8414-4005-9619-b6a2bd8acd90";

var opts = {
    'currencyConversion': null, // String | USD
};

var ordertrack = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.getOrderTrackUsingGet(ordertrackID, ordertrack)

Example Response

{
    "id": "ef93ce1c-b50e-4856-803a-db5332be93b0",
    "create_date": "2018-02-07T19:29:37.000+0000",
    "update_date": "2018-02-12T09:00:00.000+0000",
    "commission": 10,
    "date": "2018-02-11",
    "fee": 5,
    "price": 55,
    "quantity": 5,
    "order_id": "a20c0b29-836f-419d-9000-b47e4392d5f1",
    "order_status_id": "9b515c67-3791-400f-9da4-9dc69eb992ac",
    "metadata": {}
}

Retrieve the information for an order tracking record for an order. The unique order_track_id must be provided. The endpoint returns the details for the order tracking record specified.

HTTP REQUEST

GET /order_track/{order_track_id}

Update an order tracking record

Example Request

curl -X PUT -H "Authorization: Bearer <access_token>" \
    -H "Content-Type: application/json" \
    -d '{
        "id": "ef93ce1c-b50e-4856-803a-db5332be93b0",
        "commission": 10,
        "date": "2018-02-11",
        "fee": 5,
        "price": 50,
        "quantity": 5,
        "order_id": "a20c0b29-836f-419d-9000-b47e4392d5f1",
        "order_status_id": "9b515c67-3791-400f-9da4-9dc69eb992ac"
      }' "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/order_track/ef93ce1c-b50e-4856-803a-db5332be93b0"
api_instance = nucleus_api.OrderApi(nucleus_api.ApiClient(configuration))

# # Update a OrderTrack
order_track_update = {'price': '300'}
order_track_id = '222ecb9d-728c-4349-ba13-8d9aed2d8700'
try:
    api_response = api_instance.update_order_track_using_put(order_track_update, order_track_id)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling update_order_track_using_put: %s\n" % e)
OrderApi apiInstance = new OrderApi();
        //        //Update a OrderTrack
        Map map1 = new HashMap();
        map.put("fee", "200");


        try {
            OrderTrack response = apiInstance.updateOrderTrackUsingPut(map1, UUID.fromString("dc8c2e80-8b0f-4881-bd35-9c8d9edde25a"));
            System.out.println(response);
        } catch (ApiException e) {
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\OrderApi(
    new GuzzleHttp\Client(),
    $config);
//Update Order Track
$ordertrack_update = new stdClass();
$ordertrack_id = "dc8c2e80-8b0f-4881-bd35-9c8d9edde25a";

try {
    $ordertrack_update->date = "2020-10-10";
    $result = $apiInstance->updateOrderTrackUsingPut($ordertrack_update, $ordertrack_id);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->updateOrderTrackUsingPut: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::OrderApi.new

#Update Order Track
order_track_update = {"date" => '2020-10-10'}
order_track_id = 'c178d680-cc57-449c-87cb-8f83033e2262'
begin
  result = api_instance.update_order_track_using_put(order_track_update, order_track_id)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->update_order_track_using_put: #{e}"
end
var apiInstance = new HydrogenNucleusApi.OrderApi();
//Update OrderTrack
var apiInstance = new HydrogenNucleusApi.OrderApi();
var callback = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
var ordertarckupdate = new HydrogenNucleusApi.OrderTrack();
var ordertrackid = '1cd826da-a299-4a04-a644-ee9b1a9adf75';

ordertarckupdate.fee = "400";
apiInstance.updateOrderTrackUsingPut(ordertarckupdate, ordertrackid, callback)

Example Response

{
    "id": "ef93ce1c-b50e-4856-803a-db5332be93b0",
    "create_date": "2018-02-07T19:29:37.000+0000",
    "update_date": "2018-02-13T09:00:00.000+0000",
    "commission": 10,
    "date": "2018-02-11",
    "fee": 5,
    "price": 50,
    "quantity": 5,
    "order_id": "a20c0b29-836f-419d-9000-b47e4392d5f1",
    "order_status_id": "9b515c67-3791-400f-9da4-9dc69eb992ac",
    "metadata": {}
}

Update the information for an order tracking record for an order. The unique order_track_id must be provided. To obtain the appropriate order_track_id, use the GET /order_track endpoint to view all order tracking records for your tenant and their current information. The details to be updated must also be provided. The endpoint returns the order_track_id and all of the details for the order tracking record.

HTTP REQUEST

PUT /order_track/{order_track_id}

Delete an order tracking record

Example Request

curl -X DELETE -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/order_track/ef93ce1c-b50e-4856-803a-db5332be93b0"
api_instance = nucleus_api.OrderApi(nucleus_api.ApiClient(configuration))

# # # # Delete a OrderTrack
order1_track_id = '3fe570fd-b087-47a9-bda8-7d41a9f19c01'
try:
    api_instance.delete_order_track_using_delete(order1_track_id)
except ApiException as e:
    print("Exception when delete_order_track_using_delete: %s\n" % e)
OrderApi apiInstance = new OrderApi();
        //        //Delete a OrderTrack
        try {
            OrderTrack deleteresponse = apiInstance.deleteOrderTrackUsingDelete(UUID.fromString("3fe570fd-b087-47a9-bda8-7d41a9f19c01"));
            System.out.println(deleteresponse);
        } catch (ApiException e) {
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\OrderApi(
    new GuzzleHttp\Client(),
    $config);
//Delete Order Track
$ordertrack_did = "222ecb9d-728c-4349-ba13-8d9aed2d8700"; // string | UUID account_id

try {
    $apiInstance->deleteOrderTrackUsingDelete($ordertrack_did);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->deleteOrderTrackUsingDelete: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::OrderApi.new

#Delete Order Track
order_track1_id = 'b3fd27da-c9c7-4b60-aa0c-d2e90fc7ef7a'
begin
  result = api_instance.delete_order_track_using_delete(order_track1_id)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->delete_order_track_using_delete: #{e}"
end
var apiInstance = new HydrogenNucleusApi.OrderApi();
//Delete a Order
var ordertrackidd = "3fe570fd-b087-47a9-bda8-7d41a9f19c01";


var deleteordertrack = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully.');
    }
};
apiInstance.deleteOrderTrackUsingDelete(ordertrackidd, deleteordertrack)

Response (204 No Content)

Permanently delete an order tracking record for an order. The unique order_track_id must be provided. To obtain the appropriate order_track_id, use the GET /order_track endpoint to view all order tracking records for your tenant. Deletes the order_track and the order tracking record.

HTTP REQUEST

DELETE /order_track/{order_track_id}

Questionnaire

Questionnaires represent a series of questions that a user can answer to help in the selection or customization of a product. For example, it can be an investment risk profile questionnaire that helps determine a client’s risk profile and the appropriate allocations or models for him/her. Questionnaires can also be assigned to goals and represent the questions a client must answer to customize their goal. The answer values provided to questions from a client are stored as client responses. Questions can be answered so that they only apply to a specific account, or they can be answered to apply to a client as a whole so that the client does not have to answer the same question multiple times.

Questionnaire Management

Field Type Description
id UUID The id of the questionnaire
name string Name for the questionnaire
description string Descriptions for additional information on the questionnaire
decision_tree_id UUID The id of the decision tree that corresponds to the questionnaire
type string Type of questionnaire such as “retirement plan”
is_active boolean Indicates if the questionnaire is currently active. Defaults to true which indicates it is active.
questions array List of questions to be answered as well as their respective answers and weights within the questionnaire
      id string The id of the question
      category string A category for the question such as “Onboarding” or “Risk Profile”
      subcategory string A subcategory for the question such as “Income-related”
      title string Title for the question such as the body of the question or a header. Pairs with the description field
      description string Description for the question such as additional question content. Pairs with the title field
      question_type string The type of question structure such as “multiple_choice” or “free_form”
      order_index string The order of the question within the questionnaire or category such as “1”, “2”, “3”
      document string A reference link to a document related to the question
      image string A reference link to an image associated with the question
      weight float The weight of the question as a percentage of the total questionnaire if each question does not contribute equally when calculating the final “score”; ex. 20 representing 20%.
      tooltip string A tooltip to display on the UI explaining the question
      is_account boolean Indicates if the question is answered at an account-level
      metadata map Custom information associated with the question in the format key:value. See Metadata
      answers array Possible answers to the question such as multiple choice options
            id string The id of the answer option
            value string Value for the answer option
            order_index string The order of the answer option within the question or category such as “1”, “2”, “3”
            label string A label to be assigned to the answer option for data labeling purposes
            image string A reference link to an image associated with the answer option
            weight float The weight of the answer option as a percentage or value of the total questionnaire score if each answer does not contribute equally when calculating the final “score”; ex. 20 representing 20% or 20 points
            tooltip string A tooltip to display on the UI explaining the answer
            is_default boolean Indicates the default answer to a question in a questionnaire when the UI is displayed to a user. Defaults to false
            metadata map Custom information associated with the answer options in the format key:value. See Metadata
secondary_id string Alternate id that can be used to identify the object such as an internal id
create_date timestamp Timestamp for the date and time that the record was created
update_date timestamp Timestamp for the date and time that the record was last updated

List all questionnaires

Example Request

curl -X GET -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/questionnaire"
api_instance = nucleus_api.QuestionnaireApi(nucleus_api.ApiClient(configuration))
try:
    api_response = api_instance.get_questionnaire_all_using_get()
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_questionnaire_all_using_get: %s\n" % e)
QuestionnaireApi apiInstance = new QuestionnaireApi();
        try {
            PageQuestionnaire List = apiInstance.getQuestionnaireAllUsingGet(true, null, null, 0, 10);
            System.out.println(List);
        } catch (ApiException e) {
            System.err.println("Exception when calling getQuestionnaireAllUsingGet");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\QuestionnaireApi(
    new GuzzleHttp\Client(),
    $config);
$ascending = false; // bool | ascending
$filter = null; // string | filter
$order_by = null; // string | order_by
$page = 0; // int | page
$size = 10; // int | size

try {
    $questionnairelist = $apiInstance->getQuestionnaireAllUsingGet($ascending, $filter, $order_by, $page, $size);
    print_r($questionnairelist);
} catch (Exception $e) {
    echo 'Exception when calling QuestionnaireApi->getQuestionnaireAllUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::QuestionnaireApi.new
opts = {
    ascending: false, # BOOLEAN | ascending
    filter: null, # String | filter
    order_by: null, # String | order_by
    page: 0, # Integer | page
    size: 25 # Integer | size
}

begin
  questionnairelist = api_instance.get_questionnaire_all_using_get(opts)
  p questionnairelist
rescue NucleusApi::ApiError => e
  puts "Exception when calling QuestionnaireApi->get_questionnaire_all_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.QuestionnaireApi();
var opts = {
    'ascending': false, // Boolean | ascending
    // 'filter': "", // String | filter
    'orderBy': "update_date", // String | order_by
    'page': 0, // Number | page
    'size': 25 // Number | size
};

var questionnairelist = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.getQuestionnaireAllUsingGet(opts, questionnairelist)

Example Response

{
    "content": [
        {
          "id": "29fa5156-cd89-4056-9125-ce2428b05f11",
          "create_date": "2018-01-01T21:56:03.000+0000",
          "update_date": "2018-01-15T21:56:03.000+0000",
          "name": "Onboarding Questionnaire",
          "description": "Basic goals onboarding for accounts",
          "type": "Goals",
          "is_active": true,
          "secondary_id": null,
          "questions": [
              {
                  "id": "df392582-514f-486b-b15b-fecba66a104f",
                  "category": "Onboarding",
                  "subcategory": "Basic",
                  "title": "What is your age?",
                  "question_type": "free_form",
                  "order_index": "1",
                  "document": "http://domain.com/legal_agreement.pdf",
                  "image": "http://domain.com/age_graphic.pdf",
                  "tooltip": null,
                  "weight": 0,
                  "is_account": false,
                  "answers": [
                    {
                        "id": "d31c694f-bcb5-427f-b081-91e64e90229a",
                        "value": ">40",
                        "order_index": 2,
                        "image": "http://domain.com/age_graphic1.pdf",
                        "label": null,
                        "weight": 0,
                        "tooltip": null,
                        "is_default": false,
                        "metadata": {}
                    },
                    {
                        "id": "1e52401f-bfec-410b-bca1-afa5f0be37b5",
                        "value": "0-40",
                        "order_index": 1,
                        "image": "http://domain.com/age_graphic2.pdf",
                        "label": null,
                        "weight": 0,
                        "tooltip": null,
                        "is_default": false,
                        "metadata": {}
                    }
                  ],
                  "metadata": {}
              },
              {
                  "id": "65fabce6-c7a3-464c-99a2-717008f4acfe",
                  "category": "Onboarding",
                  "subcategory": "Basic",
                  "title": "What is your annual income in dollars?",
                  "question_type": "monetary_input",
                  "order_index": "2",
                  "weight": 0,
                  "tooltip": null,
                  "is_account": false,
                  "answers": [
                      {
                          "id": "7d8de5fa-6174-4a30-9e70-8e638a3d5304",
                          "value": ">100,000",
                          "order_index": 2,
                          "image": "http://domain.com/income_graphic1.pdf",
                          "label": "Mass Affluent",
                          "weight": 0,
                          "tooltip": null,
                          "is_default": false,
                          "metadata": {}
                      },
                      {
                          "id": "0ffe04ba-5db0-4a72-9fd1-2ba9479e685a",
                          "value": "0-100,000",
                          "order_index": 1,
                          "image": "http://domain.com/income_graphic2.pdf",
                          "label": "Retail",
                          "weight": 0,
                          "tooltip": null,
                          "is_default": false,
                          "metadata": {}
                      }
                  ],
                  "metadata": {}
              }
            ]
          }
        ],
    "last": true,
    "total_pages": 1,
    "total_elements": 2,
    "number_of_elements": 2,
    "first": true,
    "sort": [
        {
            "direction": "DESC",
            "property": "updateDate",
            "ignore_case": false,
            "null_handling": "NATIVE",
            "ascending": false,
            "descending": true
        }
    ],
    "size": 25,
    "number": 0
}

Get the information for all questionnaires defined for your tenant. You can filter using a decision_tree_id to view the questionnaire associated with a specific decision tree. To obtain the appropriate decision_tree_id, use the GET /decision_tree endpoint to view all decision trees defined for your tenant. Note that the questions are stored as nested objects within the questionnaire object if they have been submitted. The answers are nested within the question object if they have been submitted too. You may update questions and answers within the questionnaire, or individually in their entities below.

HTTP REQUEST

GET /questionnaire

Create a questionnaire

Example Request

curl -X POST -H "Authorization: Bearer <access_token>"
     -H "Content-Type: application/json"
     -d '{
            "name": "Onboarding Questionnaire",
            "description": "Basic goals onboarding for accounts",
            "type": "Goals",
            "is_active": true
       }' "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/questionnaire"
api_instance = nucleus_api.QuestionnaireApi(nucleus_api.ApiClient(configuration))
# # Create a Questionnaire
questionnaire = nucleus_api.Questionnaire(name="New One")
try:
    api_response = api_instance.create_questionnaire_using_post(questionnaire)
    pprint(api_response)
except ApiException as e:
    print("create_questionnaire_using_post: %s\n" % e)
QuestionnaireApi apiInstance = new QuestionnaireApi();
        //Create a Questionnaire
        Questionnaire questionnaire = new Questionnaire();
        questionnaire.setName("Abc");

        try {
            Questionnaire result = apiInstance.createQuestionnaireUsingPost(questionnaire);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling createQuestionnaireUsingPost");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\QuestionnaireApi(
    new GuzzleHttp\Client(),
    $config);
//Create Questionnaire
$questionnaire = new \com\hydrogen\nucleus\Model\Questionnaire();

try {
    $questionnaire->setName("ABC");
    $result = $apiInstance->createQuestionnaireUsingPost($questionnaire);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->createQuestionnaireUsingPost: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::QuestionnaireApi.new
#Create Questionnaire
questionnaire = NucleusApi::Questionnaire.new

begin
  questionnaire.name = "New"
  result = api_instance.create_questionnaire_using_post(questionnaire)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->create_questionnaire_using_post: #{e}"
end
var apiInstance = new HydrogenNucleusApi.QuestionnaireApi();
//Create a Questionnaire
var questionnaire = new HydrogenNucleusApi.Questionnaire();
questionnaire.name = "New";


var newquestionnaire = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.createQuestionnaireUsingPost(questionnaire, newquestionnaire)

Example Response

{
    "id": "29fa5156-cd89-4056-9125-ce2428b05f11",
    "create_date": "2018-01-01T21:56:03.000+0000",
    "update_date": "2018-01-01T21:56:03.000+0000",
    "name": "Onboarding Questionnaire",
    "description": "Basic goals onboarding for accounts",
    "type": "Goals",
    "is_active": true,
    "questions": []
}

Create a new questionnaire for your tenant. A name for the questionnaire and the embedded questions and answers must be provided. The endpoint returns a questionnaire_id to manage the questionnaire and assign it to goals.

HTTP REQUEST

POST /questionnaire

ARGUMENTS

Parameter Type Required Description
name string required Name for the questionnaire
description string optional Descriptions for additional information on the questionnaire
decision_tree_id UUID optional The id of the decision tree that corresponds to the questionnaire
type string optional Type of questionnaire such as “retirement plan”
is_active boolean optional Indicates if the questionnaire is currently active. Defaults to true which indicates it is active.
secondary_id string optional Alternate id that can be used to identify the object such as an internal id

Retrieve a questionnaire

Example Request

curl -X GET -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/questionnaire/29fa5156-cd89-4056-9125-ce2428b05f11"
api_instance = nucleus_api.QuestionnaireApi(nucleus_api.ApiClient(configuration))
try:
    api_response = api_instance.get_questionnaire_using_get("c424ae1e-6a24-4763-bacb-1427de175b95")
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_questionnaire_using_get: %s\n" % e)
QuestionnaireApi apiInstance = new QuestionnaireApi();
        try {
            Questionnaire responseq = apiInstance.getQuestionnaireUsingGet(UUID.fromString("c424ae1e-6a24-4763-bacb-1427de175b95"));
            System.out.println(responseq);
        } catch (ApiException e) {
            System.err.println("Exception when calling getQuestionnaireUsingGet");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\QuestionnaireApi(
    new GuzzleHttp\Client(),
    $config);
$questionnaire_id = "c424ae1e-6a24-4763-bacb-1427de175b95"; // string | UUID questionnaire_id

try {
    $questionnaire = $apiInstance->getQuestionnaireUsingGet($questionnaire_id);
    print_r($questionnaire);
} catch (Exception $e) {
    echo 'Exception when calling QuestionnaireApi->getQuestionnaireUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::QuestionnaireApi.new
questionnaire_id = 'c424ae1e-6a24-4763-bacb-1427de175b95' # String | UUID questionnaire_id


begin
  questionnaire = api_instance.get_questionnaire_using_get(questionnaire_id)
  p questionnaire
rescue NucleusApi::ApiError => e
  puts "Exception when calling QuestionnaireApi->get_questionnaire_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.QuestionnaireApi();
var questionnaireID = "c424ae1e-6a24-4763-bacb-1427de175b95";


var questionnaire = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.getQuestionnaireUsingGet(questionnaireID, questionnaire)

Example Response

{
    "id": "29fa5156-cd89-4056-9125-ce2428b05f11",
    "create_date": "2018-01-01T21:56:03.000+0000",
    "update_date": "2018-01-15T21:56:03.000+0000",
    "name": "Onboarding Questionnaire",
    "description": "Basic goals onboarding for accounts",
    "type": "Goals",
    "is_active": true,
    "questions": [
        {
            "id": "df392582-514f-486b-b15b-fecba66a104f",
            "category": "Onboarding",
            "subcategory": "Basic",
            "title": "What is your age?",
            "question_type": "free_form",
            "order_index": "1",
            "document": null,
            "image": "http://domain.com/age_graphic.pdf",
            "weight": 0,
            "tooltip": null,
            "is_account": false,
            "answers": [
                {
                  "id": "d31c694f-bcb5-427f-b081-91e64e90229a",
                  "value": ">40",
                  "order_index": 1,
                  "image": "http://domain.com/age_graphic1.pdf",
                  "label": null,
                  "weight": 0,
                  "tooltip": null,
                  "is_default": false,
                  "metadata": {}
                },
                {
                  "id": "1e52401f-bfec-410b-bca1-afa5f0be37b5",
                  "value": "0-40",
                  "order_index": 1,
                  "image": "http://domain.com/age_graphic2.pdf",
                  "label": null,
                  "weight": 0,
                  "tooltip": null,
                  "is_default": false,
                  "metadata": {}
                }
            ],
            "metadata": {}
        },
        {
            "id": "65fabce6-c7a3-464c-99a2-717008f4acfe",
            "category": "Onboarding",
            "subcategory": "Basic",
            "title": "What is your annual income in dollars?",
            "question_type": "monetary_input",
            "order_index": "2",
            "weight": 0,
            "tooltip": null,
            "is_account": false,
            "answers": [
                {
                  "id": "7d8de5fa-6174-4a30-9e70-8e638a3d5304",
                  "value": ">100,000",
                  "order_index": 2,
                  "image": "http://domain.com/income_graphic1.pdf",
                  "label": "Mass Affluent",
                  "weight": null,
                  "tooltip": null,
                  "is_default": false,
                  "metadata": {}
                },
                {
                  "id": "0ffe04ba-5db0-4a72-9fd1-2ba9479e685a",
                  "value": "0-100,000",
                  "order_index": 1,
                  "image": "http://domain.com/income_graphic2.pdf",
                  "weight": 0,
                  "tooltip": null,
                  "is_default": false,
                  "metadata": {}
                }
            ],
            "metadata": {}
        }
    ]
}

Retrieve the information for a questionnaire for your tenant. The questionnaire_id must be provided. The endpoint returns the questionnaire_id and the details for the questionnaire specified.

HTTP REQUEST

GET /questionnaire/{questionnaire_id}

Update a questionnaire

Example Request

curl -X PUT -H "Authorization: Bearer <access_token>"
    -H "Content-Type: application/json"
    -d '{
          "type": "Non Goals"
      }' "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/questionnaire/29fa5156-cd89-4056-9125-ce2428b05f11"
api_instance = nucleus_api.QuestionnaireApi(nucleus_api.ApiClient(configuration))
# # # Update a Questionnaire
questionnaire_update = {'name': 'Updated Name'}
questionnaire_id = '0e96f588-51d4-49c7-993a-1ad6ff266516'
try:
    api_response = api_instance.update_questionnaire_using_put(questionnaire_update, questionnaire_id)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling update_questionnaire_using_put: %s\n" % e)
QuestionnaireApi apiInstance = new QuestionnaireApi();
        //        //Update a Questionnaire
        Map map = new HashMap();
        map.put("name", "New");

        try {
            Questionnaire response = apiInstance.updateQuestionnaireUsingPut(map, UUID.fromString("455af4a1-3629-4bc5-9ec7-0974c0ae3665"));
            System.out.println(response);
        } catch (ApiException e) {
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\QuestionnaireApi(
    new GuzzleHttp\Client(),
    $config);

//Update Questionnaire
$questionnaire_update = new stdClass();
$questionnaire_id = "455af4a1-3629-4bc5-9ec7-0974c0ae3665";

try {
    $questionnaire_update->name = "ABC";
    $result = $apiInstance->updateQuestionnaireUsingPut($questionnaire_update, $questionnaire_id);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->updateQuestionnaireUsingPut: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::QuestionnaireApi.new
#Update Questionnaire
questionnnaire_update = {"price" => '50'}
questionnaire_id = '0ccaef12-9ddf-4dad-a1b0-65719b0caa3e'
begin
  result = api_instance.update_questionnaire_using_put(questionnnaire_update, questionnaire_id)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->update_questionnaire_using_put: #{e}"
end
var apiInstance = new HydrogenNucleusApi.QuestionnaireApi();
//Update Questionnaire
var apiInstance = new HydrogenNucleusApi.QuestionnaireApi();
var callback = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
var questionnaireupdate = new HydrogenNucleusApi.Questionnaire();
var questionnaireid = '8f5ec5c9-306c-476d-825c-4d0474b106a7';

questionnaireupdate.name = "New";
apiInstance.updateQuestionnaireUsingPut(questionnaireupdate, questionnaireid, callback)

Example Response

{
    "id": "29fa5156-cd89-4056-9125-ce2428b05f11",
    "create_date": "2018-01-01T21:56:03.000+0000",
    "update_date": "2018-01-15T21:56:03.000+0000",
    "name": "Onboarding Questionnaire",
    "description": "Basic goals onboarding for accounts",
    "type": "Non Goals",
    "is_active": true,
    "questions": []
}

Update a questionnaire for your tenant. The questionnaire_id must be provided in the URL. To obtain the appropriate questionnaire_id, use the GET /questionnaire endpoint to view all questionnaires for your tenant and their current information. The endpoint returns the questionnaire_id and the details for the questionnaire.

HTTP REQUEST

PUT /questionnaire/{questionnaire_id}

Delete a questionnaire

Example Request

curl -X DELETE -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/questionnaire/429fa5156-cd89-4056-9125-ce2428b05f11"
api_instance = nucleus_api.QuestionnaireApi(nucleus_api.ApiClient(configuration))
# # # # Delete a Questionnaire
questionnaire1_id = '0ccaef12-9ddf-4dad-a1b0-65719b0caa3e'
try:
    api_instance.delete_questionnaire_using_delete(questionnaire1_id)
except ApiException as e:
    print("Exception when delete_questionnaire_using_delete: %s\n" % e)
QuestionnaireApi apiInstance = new QuestionnaireApi();
        //Delete a Questionnaire
        try {
            Questionnaire responseDelete = apiInstance.deleteQuestionnaireUsingDelete(UUID.fromString("fef9f0f4-8e49-4855-b581-5360133d610f"));
            System.out.println(responseDelete);
        } catch (ApiException e) {
            System.err.println("Exception when calling deleteBusinessUsingDelete");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\QuestionnaireApi(
    new GuzzleHttp\Client(),
    $config);

//Delete Questionnaire
$questionnaire_did = "8588e525-3a16-457d-97b2-a3b3a1d27e42"; // string | UUID account_id

try {
    $apiInstance->deleteQuestionnaireUsingDelete($questionnaire_did);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->deleteQuestionnaireUsingDelete: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::QuestionnaireApi.new
#Delete Questionnaire
questionnaire1_id = 'a8b6f6a1-b592-4887-8563-84868736c502'
begin
  result = api_instance.delete_questionnaire_using_delete(questionnaire1_id)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->delete_questionnaire_using_delete: #{e}"
end
var apiInstance = new HydrogenNucleusApi.QuestionnaireApi();
//Delete a Questionnaire
var questionnairedid = "fef9f0f4-8e49-4855-b581-5360133d610f";


var deletequestionnaire = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully.');
    }
};
apiInstance.deleteQuestionnaireUsingDelete(questionnairedid, deletequestionnaire)

Response (204 No Content)

Permanently delete a questionnaire for your tenant. The questionnaire_id must be provided. To obtain the appropriate questionnaire_id, use the GET /questionnaire endpoint to view all questionnaires for your tenant. This deletes the questionnaire_id and the details for the questionnaire.

HTTP REQUEST

DELETE /questionnaire/{questionnaire_id}

Question

Questions can be created and attached to a questionnaire_id using the service below.

Field Type Description
id UUID The id of the question
questionnaire_id UUID The id of the questionnaire this question belongs to. All questions can only be attached to one questionnaire at a time.
title string Title for the question such as the body of the question or a header. Pairs with the description field
description string Description for the question such as additional question content. Pairs with the title field
category string A category for the question such as “Onboarding” or “Risk Profile”
subcategory string A subcategory for the question such as “Income-related”
question_type string The type of question structure such as “multiple_choice” or “free_form”
order_index string The order of the question within the questionnaire or category such as “1”, “2”, “3”
document string A reference link to a document related to the question
image string A reference link to an image associated with the question
weight float The weight of the question as a percentage of the total questionnaire if each question does not contribute equally when calculating the final “score”; ex. 20 representing 20%.
tooltip string A tooltip to display on the UI explaining the question
is_account boolean Indicates if the question is answered at an account-level
      answers array Possible answers to the question such as multiple choice options
            id string The id of the answer option
            value string Value for the answer option
            order_index string The order of the answer option within the question or category such as “1”, “2”, “3”
            label string A label to be assigned to the answer option for data labeling purposes
            image string A reference link to an image associated with the answer option
            weight float The weight of the answer option as a percentage or value of the total questionnaire score if each answer does not contribute equally when calculating the final “score”; ex. 20 representing 20% or 20 points
            tooltip string A tooltip to display on the UI explaining the answer
            is_default boolean Indicates the default answer to a question in a questionnaire when the UI is displayed to a user. Defaults to false
            metadata map Custom information associated with the answer option in the format key:value. See Metadata
metadata map Custom information associated with the question in the format key:value. See Metadata
secondary_id string Alternate id that can be used to identify the object such as an internal id
create_date timestamp Timestamp for the date and time that the record was created
update_date timestamp Timestamp for the date and time that the record was last updated

List all questions

Example Request

curl -X GET -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/question"
api_instance = nucleus_api.QuestionnaireApi(nucleus_api.ApiClient(configuration))
try:
    api_response = api_instance.get_questionnaire_using_get("c424ae1e-6a24-4763-bacb-1427de175b95")
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_questionnaire_using_get: %s\n" % e)
QuestionnaireApi apiInstance = new QuestionnaireApi();
        try {
            PageQuestionnaire List = apiInstance.getQuestionnaireAllUsingGet(true, null, null, 0, 10);
            System.out.println(List);
        } catch (ApiException e) {
            System.err.println("Exception when calling getQuestionnaireAllUsingGet");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\QuestionnaireApi(
    new GuzzleHttp\Client(),
    $config);
$ascending = false; // bool | ascending
$filter = null; // string | filter
$order_by = null; // string | order_by
$page = 0; // int | page
$size = 10; // int | size

try {
    $questionlist = $apiInstance->getQuestionAllUsingGet($ascending, $filter, $order_by, $page, $size);
    print_r($questionlist);
} catch (Exception $e) {
    echo 'Exception when calling QuestionnaireApi->getQuestionAllUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::QuestionnaireApi.new
opts = {
    ascending: false, # BOOLEAN | ascending
    filter: null, # String | filter
    order_by: null, # String | order_by
    page: 0, # Integer | page
    size: 25 # Integer | size
}

begin
  questionlist = api_instance.get_question_all_using_get(opts)
  p questionlist
rescue NucleusApi::ApiError => e
  puts "Exception when calling QuestionnaireApi->get_question_all_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.QuestionnaireApi();
var opts = {
    'ascending': false, // Boolean | ascending
    // 'filter': "", // String | filter
    'orderBy': "update_date", // String | order_by
    'page': 0, // Number | page
    'size': 25 // Number | size
};

var questionslist = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.getQuestionAllUsingGet(opts, questionslist)

Example Response

{
    "content": [
        {
          "id": "df392582-514f-486b-b15b-fecba66a104f",
          "create_date": "2018-01-02T21:56:03.000+0000",
          "update_date": "2018-01-02T21:56:03.000+0000",
          "title": "What is your age?",
          "description": null,
          "category": "Onboarding",
          "subcategory": "Basic",
          "question_type": "free_form",
          "order_index": "1",
          "document": null,
          "image": "http://domain.com/age_graphic.pdf",
          "tooltip": null,
          "weight": null,
          "is_account": false,
          "answers": [
            {
              "id": "d31c694f-bcb5-427f-b081-91e64e90229a",
              "value": ">40",
              "order_index": 2,
              "image": "http://domain.com/age_graphic1.pdf",
              "label": null,
              "weight": null,
              "tooltip": null,
              "is_default": false,
              "metadata": {}
            },
            {
              "id": "1e52401f-bfec-410b-bca1-afa5f0be37b5",
              "value": "0-40",
              "order_index": 1,
              "image": "http://domain.com/age_graphic2.pdf",
              "label": null,
              "weight": null,
              "tooltip": null,
              "is_default": false,
              "metadata": {}
            }
          ],
          "metadata": {},
          "secondary_id": null
        },
        {
          "id": "65fabce6-c7a3-464c-99a2-717008f4acfe",
          "create_date": "2018-01-01T21:56:03.000+0000",
          "update_date": "2018-01-15T21:56:03.000+0000",
          "title": "What is your annual income in dollars?",
          "description": null,
          "category": "Onboarding",
          "subcategory": "Basic",
          "question_type": "monetary_input",
          "order_index": "2",
          "weight": null,
          "tooltip": null,
          "is_account": false,
          "answers": [
            {
              "id": "7d8de5fa-6174-4a30-9e70-8e638a3d5304",
              "value": ">100,000",
              "order_index": 2,
              "image": "http://domain.com/income_graphic1.pdf",
              "label": "Mass Affluent",
              "weight": null,
              "tooltip": null,
              "is_default": false,
              "metadata": {}
            },
            {
              "id": "0ffe04ba-5db0-4a72-9fd1-2ba9479e685a",
              "value": "0-100,000",
              "order_index": 1,
              "image": "http://domain.com/income_graphic2.pdf",
              "label": "Retail",
              "weight": null,
              "tooltip": null,
              "is_default": false,
              "metadata": {}
            }
            ],
          "metadata": {},
          "secondary_id": null
        }
      ],
        "last": true,
        "total_pages": 1,
        "total_elements": 2,
        "number_of_elements": 2,
        "first": true,
        "sort": [
            {
                "direction": "DESC",
                "property": "updateDate",
                "ignore_case": false,
                "null_handling": "NATIVE",
                "ascending": false,
                "descending": true
            }
        ],
        "size": 25,
        "number": 0
}

Get the information for all questions defined for your tenant. You can filter using a questionnaire_id to view the questions associated with a specific questionnaire. To obtain the appropriate questionnaire_id, use the GET /questionnaire endpoint to view all questionnaire defined for your tenant.

HTTP REQUEST

GET /question

Create a question

Example Request

curl -X POST -H "Authorization: Bearer <access_token>"
     -H "Content-Type: application/json"
     -d '{
            "title": "What is your age?",
            "category": "Onboarding",
            "subcategory": "Basic",
            "question_type": "free_form",
            "order_index": "1",
            "image": "http://domain.com/age_graphic.pdf"
      }' "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/question"
api_instance = nucleus_api.QuestionnaireApi(nucleus_api.ApiClient(configuration))
# # Create a Question
question = nucleus_api.Question(questionnaire_id="0e96f588-51d4-49c7-993a-1ad6ff266516", title="New Question")
try:
    api_response = api_instance.create_question_using_post(question)
    pprint(api_response)
except ApiException as e:
    print("create_questionnaire_using_post: %s\n" % e)
QuestionnaireApi apiInstance = new QuestionnaireApi();


        //Create a Question
        Question newQuestion = new Question();
        newQuestion.setQuestionnaireId(UUID.fromString("a250ef54-675a-4bae-8b7b-a6d94de50f79"));
        newQuestion.setTitle("New One");


                try {
            Question result = apiInstance.createQuestionUsingPost(newQuestion);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling createQuestionUsingPost");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\QuestionnaireApi(
    new GuzzleHttp\Client(),
    $config);
//Create Question
$question = new \com\hydrogen\nucleus\Model\Question();

try {
    $question->setQuestionnaireId("a250ef54-675a-4bae-8b7b-a6d94de50f79");
    $question->setTitle("New");
    $result = $apiInstance->createQuestionUsingPost($question);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->createQuestionUsingPost: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::QuestionnaireApi.new
#Create Question
question = NucleusApi::Question.new

begin
  question.questionnaire_id = "a250ef54-675a-4bae-8b7b-a6d94de50f79"
  question.title = "New"
  result = api_instance.create_question_using_post(question)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->create_question_using_post: #{e}"
end
var apiInstance = new HydrogenNucleusApi.QuestionnaireApi();
//Create a Question
var question = new HydrogenNucleusApi.Question();
question.questionnaire_id = 'a250ef54-675a-4bae-8b7b-a6d94de50f79';
question.title = "New";


var newquestion = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.createQuestionUsingPost(question, newquestion)

Example Response

{
    "id": "29fa5156-cd89-4056-9125-ce2428b05f11",
    "create_date": "2018-01-01T21:56:03.000+0000",
    "update_date": "2018-01-15T21:56:03.000+0000",
    "title": "What is your age?",
    "description": null,
    "category": "Onboarding",
    "subcategory": "Basic",
    "question_type": "free_form",
    "order_index": "1",
    "document": null,
    "image": "http://domain.com/age_graphic.pdf",
    "weight": null,
    "tooltip": null,
    "is_account": false,
    "answers": [],
    "metadata": {},
    "secondary_id": null
}

Create a new question for your tenant. A questionnaire_id must be provided. The endpoint returns a question_id to manage the question.

HTTP REQUEST

POST /question

ARGUMENTS

Parameter Type Required Description
questionnaire_id UUID required The id of the questionnaire this question belongs to. All questions can only be attached to one questionnaire at a time.
title string required Title for the question such as the body of the question or a header. Pairs with the description field
description string optional Description for the question such as additional question content. Pairs with the title field
category string optional A category for the question such as “Onboarding” or “Risk Profile”
subcategory string optional A subcategory for the question such as “Income-related”
question_type string optional The type of question structure such as “multiple_choice” or “free_form”
order_index string optional The order of the question within the questionnaire or category such as “1”, “2”, “3”
document string optional A reference link to a document related to the question
image string optional A reference link to an image associated with the question
weight float optional The weight of the question as a percentage of the total questionnaire if each question does not contribute equally when calculating the final “score”; ex. 20 representing 20%.
tooltip string optional A tooltip to display on the UI explaining the question
is_account boolean optional Indicates if the question is answered at an account-level
metadata map optional Custom information associated with the question in the format key:value. See Metadata
secondary_id string optional Alternate id that can be used to identify the object such as an internal id

Retrieve a question

Example Request

curl -X GET -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/question/29fa5156-cd89-4056-9125-ce2428b05f11"
api_instance = nucleus_api.QuestionnaireApi(nucleus_api.ApiClient(configuration))
try:
    api_response = api_instance.get_question_using_get("b0674d0d-3e61-4177-94b7-93681b1b0cdd")
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_question_using_get: %s\n" % e)
QuestionnaireApi apiInstance = new QuestionnaireApi();
        try {
            Question responsequestion = apiInstance.getQuestionUsingGet(UUID.fromString("567c29d7-0a86-4f8e-a0b0-c20457fcc99e"));
            System.out.println(responsequestion);
        } catch (ApiException e) {
            System.err.println("Exception when calling getQuestionUsingGet");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\QuestionnaireApi(
    new GuzzleHttp\Client(),
    $config);
$question_id = "567c29d7-0a86-4f8e-a0b0-c20457fcc99e"; // string | UUID question_id

try {
    $question = $apiInstance->getQuestionUsingGet($question_id);
    print_r($question);
} catch (Exception $e) {
    echo 'Exception when calling QuestionnaireApi->getQuestionUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::QuestionnaireApi.new
question_id = '567c29d7-0a86-4f8e-a0b0-c20457fcc99e' # String | UUID question_id

begin
  question = api_instance.get_question_using_get(question_id)
  p question
rescue NucleusApi::ApiError => e
  puts "Exception when calling QuestionnaireApi->get_question_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.QuestionnaireApi();
var questionID = "567c29d7-0a86-4f8e-a0b0-c20457fcc99e";


var question = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.getQuestionUsingGet(questionID, question)

Example Response

{
    "id": "df392582-514f-486b-b15b-fecba66a104f",
    "create_date": "2018-01-01T21:56:03.000+0000",
    "update_date": "2018-01-15T21:56:03.000+0000",
    "title": "What is your age?",
    "description": null,
    "category": "Onboarding",
    "subcategory": "Basic",
    "question_type": "free_form",
    "order_index": "1",
    "document": null,
    "image": "http://domain.com/age_graphic.pdf",
    "weight": null,
    "tooltip": null,
    "is_account": false,
    "answers": [
      {
        "id": "d31c694f-bcb5-427f-b081-91e64e90229a",
        "value": ">40",
        "order_index": 2,
        "image": "http://domain.com/age_graphic1.pdf",
        "label": null,
        "weight": null,
        "tooltip": null,
        "is_default": false,
        "metadata": {}
      },
      {
        "id": "1e52401f-bfec-410b-bca1-afa5f0be37b5",
        "value": "0-40",
        "order_index": 1,
        "image": "http://domain.com/age_graphic2.pdf",
        "label": null,
        "weight": null,
        "tooltip": null,
        "is_default": false,
        "metadata": {}
      }
    ],
    "metadata": {},
    "secondary_id": null
}

Retrieve the information for a question for your tenant. The question_id must be provided. The endpoint returns the question_id and the details for the question specified, along with any answers that have been assigned to the question.

HTTP REQUEST

GET /question/{question_id}

Update a question

Example Request

curl -X PUT -H "Authorization: Bearer <access_token>"
    -H "Content-Type: application/json"
    -d '{
          "title": "How old are you?"
      }' "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/question/29fa5156-cd89-4056-9125-ce2428b05f11"
api_instance = nucleus_api.QuestionnaireApi(nucleus_api.ApiClient(configuration))
# # # Update a Question
question_update = {'description': 'Updated Name'}
question_id = '9033cfb7-30a8-4966-a2b6-7b26f8317b08'
try:
    api_response = api_instance.update_question_using_put(question_update, question_id)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling update_question_using_put: %s\n" % e)
QuestionnaireApi apiInstance = new QuestionnaireApi();
        //        //Update a Question
        Map map1 = new HashMap();
        map.put("name", "New");

        try {
            Question response = apiInstance.updateQuestionUsingPut(map1, UUID.fromString("345cf821-2fe7-4518-894f-aeeeef7cd26d"));
            System.out.println(response);
        } catch (ApiException e) {
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\QuestionnaireApi(
    new GuzzleHttp\Client(),
    $config);
//Update Question
$question_update = new stdClass();
$question_id = "345cf821-2fe7-4518-894f-aeeeef7cd26d";

try {
    $question_update->title  = "ABC";
    $result = $apiInstance->updateQuestionUsingPut($question_update, $question_id);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->updateQuestionUsingPut: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::QuestionnaireApi.new
#Update Question
question_update = {"weight" => '50'}
question_id = '47b548bb-ba99-49a2-9ae1-c72f23b3f4a4'
begin
  result = api_instance.update_question_using_put(question_update, question_id)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->update_question_using_put: #{e}"
end
var apiInstance = new HydrogenNucleusApi.QuestionnaireApi();
//Update Question
var apiInstance = new HydrogenNucleusApi.QuestionnaireApi();
var callback = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
var questionupdate = new HydrogenNucleusApi.Question();
var questionid = '1b9e315a-8d7e-4e48-8ff1-cbe508dbcc30';

questionupdate.description = "New";
apiInstance.updateQuestionUsingPut(questionupdate, questionid, callback)

Example Response

{
    "id": "df392582-514f-486b-b15b-fecba66a104f",
    "create_date": "2018-01-01T21:56:03.000+0000",
    "update_date": "2018-01-15T21:56:03.000+0000",
    "title": "How old are you?",
    "description": null,
    "category": "Onboarding",
    "subcategory": "Basic",
    "question_type": "free_form",
    "order_index": "1",
    "document": null,
    "image": "http://domain.com/age_graphic.pdf",
    "weight": null,
    "tooltip": null,
    "is_account": false,
    "answers": [
      {
        "id": "d31c694f-bcb5-427f-b081-91e64e90229a",
        "value": ">40",
        "order_index": 2,
        "image": "http://domain.com/age_graphic1.pdf",
        "label": null,
        "weight": null,
        "tooltip": null,
        "is_default": false,
        "metadata": {}
      },
      {
        "id": "1e52401f-bfec-410b-bca1-afa5f0be37b5",
        "value": "0-40",
        "order_index": 1,
        "image": "http://domain.com/age_graphic2.pdf",
        "label": null,
        "weight": null,
        "tooltip": null,
        "is_default": false,
        "metadata": {}
      }
    ],
    "metadata": {},
    "secondary_id": null
}

Update a question for your tenant. The question_id must be provided in the URL. To obtain the appropriate question_id, use the GET /question endpoint to view all questions for your tenant and their current information. The endpoint returns the question_id and the details for the question.

HTTP REQUEST

PUT /question/{question_id}

Delete a question

Example Request

curl -X DELETE -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/question/429fa5156-cd89-4056-9125-ce2428b05f11"
api_instance = nucleus_api.QuestionnaireApi(nucleus_api.ApiClient(configuration))
# # Delete a Question
question1_id = '47b548bb-ba99-49a2-9ae1-c72f23b3f4a4'
try:
    api_instance.delete_question_using_delete(question1_id)
except ApiException as e:
    print("Exception when delete_question_using_delete: %s\n" % e)
QuestionnaireApi apiInstance = new QuestionnaireApi();

        //Delete a Question
        try {
            Question responseDelete = apiInstance.deleteQuestionUsingDelete(UUID.fromString("345cf821-2fe7-4518-894f-aeeeef7cd26d"));
            System.out.println(responseDelete);
        } catch (ApiException e) {
            System.err.println("Exception when calling deleteQuestionUsingDelete");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\QuestionnaireApi(
    new GuzzleHttp\Client(),
    $config);
//Delete Question
$question_did = "47b548bb-ba99-49a2-9ae1-c72f23b3f4a4"; // string | UUID account_id

try {
    $apiInstance->deleteQuestionUsingDelete($question_did);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->deleteQuestionUsingDelete: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::QuestionnaireApi.new
#Delete Question
question1_id = 'a84fe18-858c-4f3c-bba8-602ce40b2173'
begin
  result = api_instance.delete_question_using_delete(question1_id)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->delete_question_using_delete: #{e}"
end
var apiInstance = new HydrogenNucleusApi.QuestionnaireApi();
// //Delete a Question
var questiondid = "345cf821-2fe7-4518-894f-aeeeef7cd26d";


var deletequestion = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully.');
    }
};
apiInstance.deleteQuestionUsingDelete(questiondid, deletequestion)

Response (204 No Content)

Permanently delete a question for your tenant. The question_id must be provided. To obtain the appropriate question_id, use the GET /question endpoint to view all questions for your tenant. This deletes the question_id and the details for the question.

HTTP REQUEST

DELETE /question/{question_id}

Answer

Answers can be created and attached to a question_id using the service below.

Field Type Description
id UUID The id of the answer
question_id UUID The id of the question this answer belongs to. All answers can only be attached to one question at a time.
value string Value for the answer option
order_index string The order of the answer option within the question or category such as “1”, “2”, “3”
label string A label to be assigned to the answer option for data labeling purposes
image string A reference link to an image associated with the answer option
weight float The weight of the answer option as a percentage or value of the total questionnaire score if each answer does not contribute equally when calculating the final “score”; ex. 20 representing 20% or 20 points
tooltip string A tooltip to display on the UI explaining the answer
is_default boolean Indicates the default answer to a question in a questionnaire when the UI is displayed to a user. Defaults to false
metadata map Custom information associated with the question in the format key:value. See Metadata
secondary_id string Alternate id that can be used to identify the object such as an internal id
create_date timestamp Timestamp for the date and time that the record was created
update_date timestamp Timestamp for the date and time that the record was last updated

List all answers

Example Request

curl -X GET -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/answer"
api_instance = nucleus_api.QuestionnaireApi(nucleus_api.ApiClient(configuration))
try:
    api_response = api_instance.get_answer_all_using_get()
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_answer_all_using_get: %s\n" % e)
QuestionnaireApi apiInstance = new QuestionnaireApi();
        try {
            PageAnswer List = apiInstance.getAnswerAllUsingGet(true, null, null, 0, 10);
            System.out.println(List);
        } catch (ApiException e) {
            System.err.println("Exception when calling getAnswerAllUsingGet");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\QuestionnaireApi(
    new GuzzleHttp\Client(),
    $config);
$ascending = false; // bool | ascending
$filter = null; // string | filter
$order_by = null; // string | order_by
$page = 0; // int | page
$size = 10; // int | size

try {
    $answerlist = $apiInstance->getAnswerAllUsingGet($ascending, $filter, $order_by, $page, $size);
    print_r($answerlist);
} catch (Exception $e) {
    echo 'Exception when calling QuestionnaireApi->getAnswerAllUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::QuestionnaireApi.new
opts = {
    ascending: false, # BOOLEAN | ascending
    filter: null, # String | filter
    order_by: null, # String | order_by
    page: 0, # Integer | page
    size: 25 # Integer | size
}

begin
  answerlist = api_instance.get_answer_all_using_get(opts)
  p answerlist
rescue NucleusApi::ApiError => e
  puts "Exception when calling QuestionnaireApi->get_answer_all_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.QuestionnaireApi();
var opts = {
    'ascending': false, // Boolean | ascending
    // 'filter': "", // String | filter
    'orderBy': "update_date", // String | order_by
    'page': 0, // Number | page
    'size': 25 // Number | size
};

var answerlist = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.getAnswerAllUsingGet(opts, answerlist)

Example Response

{
    "content": [
      {
          "id": "d31c694f-bcb5-427f-b081-91e64e90229a",
          "value": ">40",
          "image": "http://domain.com/age_graphic1.pdf",
          "label": null,
          "weight": null,
          "tooltip": null,
          "is_default": false,
          "metadata": {}
      },
      {
          "id": "1e52401f-bfec-410b-bca1-afa5f0be37b5",
          "value": "0-40",
          "image": "http://domain.com/age_graphic2.pdf",
          "label": null,
          "weight": null,
          "tooltip": null,
          "is_default": false,
          "metadata": {}
      }
    ],
    "last": true,
    "total_pages": 1,
    "total_elements": 2,
    "number_of_elements": 2,
    "first": true,
    "sort": [
        {
            "direction": "DESC",
            "property": "updateDate",
            "ignore_case": false,
            "null_handling": "NATIVE",
            "ascending": false,
            "descending": true
        }
    ],
    "size": 25,
    "number": 0
}

Get the information for all answers defined for your tenant. You can filter using a question_id to view the answers associated with a specific question. To obtain the appropriate question_id, use the GET /question endpoint to view all questions defined for your tenant.

HTTP REQUEST

GET /answer

Create an answer

Example Request

curl -X POST -H "Authorization: Bearer <access_token>"
     -H "Content-Type: application/json"
     -d '{
            "title": "What is your age?",
            "category": "Onboarding",
            "subcategory": "Basic",
            "question_type": "free_form",
            "order_index": "1",
            "image": "http://domain.com/age_graphic.pdf"
      }' "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/question"
api_instance = nucleus_api.QuestionnaireApi(nucleus_api.ApiClient(configuration))
# Create a Answer
answer = nucleus_api.Answer(question_id="9033cfb7-30a8-4966-a2b6-7b26f8317b08", value="New")
try:
    api_response = api_instance.create_answer_using_post(answer)
    pprint(api_response)
except ApiException as e:
    print("create_answer_using_post: %s\n" % e)
QuestionnaireApi apiInstance = new QuestionnaireApi();
        //Create a Answer
        Answer newanswer = new Answer();
        newanswer.setQuestionId(UUID.fromString("345cf821-2fe7-4518-894f-aeeeef7cd26d"));
        newanswer.setValue("ABc");


        try {
            Answer result = apiInstance.createAnswerUsingPost(newanswer);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling createAnswerUsingPost");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\QuestionnaireApi(
    new GuzzleHttp\Client(),
    $config);
//Create Answer
$answer = new \com\hydrogen\nucleus\Model\Answer();

try {
    $answer->setQuestionId('345cf821-2fe7-4518-894f-aeeeef7cd26d');
    $answer->setValue("New");
    $result = $apiInstance->createAnswerUsingPost($answer);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->createAnswerUsingPost: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::QuestionnaireApi.new
#Create Answer
answer = NucleusApi::Answer.new

begin
  answer.question_id = "345cf821-2fe7-4518-894f-aeeeef7cd26d"
  answer.value = "ABC"
  result = api_instance.create_answer_using_post(answer)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->create_answer_using_post: #{e}"
end
var apiInstance = new HydrogenNucleusApi.QuestionnaireApi();
//Create a Answer
var answer = new HydrogenNucleusApi.Answer();
answer.question_id = '47b548bb-ba99-49a2-9ae1-c72f23b3f4a4';
answer.value = "ABC";


var newanswer = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.createAnswerUsingPost(answer, newanswer)

Example Response

{
    "id": "29fa5156-cd89-4056-9125-ce2428b05f11",
    "create_date": "2018-01-01T21:56:03.000+0000",
    "update_date": "2018-01-15T21:56:03.000+0000",
    "title": "What is your age?",
    "description": null,
    "category": "Onboarding",
    "subcategory": "Basic",
    "question_type": "free_form",
    "order_index": "1",
    "document": null,
    "image": "http://domain.com/age_graphic.pdf",
    "weight": null,
    "tooltip": null,
    "is_account": false,
    "metadata": {},
    "secondary_id": null,
    "answers": []
}

Create a new answer for your tenant. A question_id must be provided. The endpoint returns a answer_id to manage the question.

HTTP REQUEST

POST /answer

ARGUMENTS

Parameter Type Required Description
question_id UUID required The id of the question this answer belongs to. All answers can only be attached to one question at a time.
value string required Value for the answer option
order_index string optional The order of the answer option within the question or category such as “1”, “2”, “3”
label string optional A label to be assigned to the answer option for data labeling purposes
image string optional A reference link to an image associated with the answer option
weight float optional The weight of the answer option as a percentage or value of the total questionnaire score if each answer does not contribute equally when calculating the final “score”; ex. 20 representing 20% or 20 points
tooltip string optional A tooltip to display on the UI explaining the answer
is_default boolean optional Indicates the default answer to a question in a questionnaire when the UI is displayed to a user. Defaults to false
metadata map optional Custom information associated with the question in the format key:value. See Metadata
secondary_id string optional Alternate id that can be used to identify the object such as an internal id

Retrieve an answer

Example Request

curl -X GET -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/answer/29fa5156-cd89-4056-9125-ce2428b05f11"
api_instance = nucleus_api.QuestionnaireApi(nucleus_api.ApiClient(configuration))
try:
    api_response = api_instance.get_answer_using_get("a876cb1c-eba0-4828-b693-fc028b5c08c3")
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_answer_using_get: %s\n" % e)
QuestionnaireApi apiInstance = new QuestionnaireApi();
        try {
            Answer responseAnswer = apiInstance.getAnswerUsingGet(UUID.fromString("019afaa5-88ec-4283-a2f2-05cda47dd019"));
            System.out.println(responseAnswer);
        } catch (ApiException e) {
            System.err.println("Exception when calling getAnswerUsingGet");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\QuestionnaireApi(
    new GuzzleHttp\Client(),
    $config);
$answer_id = "019afaa5-88ec-4283-a2f2-05cda47dd019"; // string | UUID answer_id

try {
    $answer = $apiInstance->getAnswerUsingGet($answer_id);
    print_r($answer);
} catch (Exception $e) {
    echo 'Exception when calling QuestionnaireApi->getAnswerUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::QuestionnaireApi.new
answer_id = '019afaa5-88ec-4283-a2f2-05cda47dd019' # String | UUID answer_id

begin
  answer = api_instance.get_answer_using_get(answer_id)
  p answer
rescue NucleusApi::ApiError => e
  puts "Exception when calling QuestionnaireApi->get_answer_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.QuestionnaireApi();
var answerID = "019afaa5-88ec-4283-a2f2-05cda47dd019";


var answer = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.getAnswerUsingGet(answerID, answer)

Example Response

{
    "id": "d31c694f-bcb5-427f-b081-91e64e90229a",
    "value": ">40",
    "image": "http://domain.com/age_graphic1.pdf",
    "label": null,
    "weight": null,
    "tooltip": null,
    "is_default": false,
    "metadata": {}
}

Retrieve the information for an answer for your tenant. The answer_id must be provided. The endpoint returns the answer_id and the details for the answer specified.

HTTP REQUEST

GET /answer/{answer_id}

Update an answer

Example Request

curl -X PUT -H "Authorization: Bearer <access_token>"
    -H "Content-Type: application/json"
    -d '{
          "title": "How old are you?"
      }' "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/answer/29fa5156-cd89-4056-9125-ce2428b05f11"
api_instance = nucleus_api.QuestionnaireApi(nucleus_api.ApiClient(configuration))
# # Update a Answer
answer_update = {'value': 'One'}
answer_id = 'f1b4380e-f1c8-45a7-9d74-2acb3d6853b9'
try:
    api_response = api_instance.update_answer_using_put(answer_update, answer_id)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling update_answer_using_put: %s\n" % e)
QuestionnaireApi apiInstance = new QuestionnaireApi();
        //        //Update a Answer
        Map map2 = new HashMap();
        map.put("name", "New");

        try {
            Answer response = apiInstance.updateAnswerUsingPut(map2, UUID.fromString("f4a11447-784f-4e19-94ba-228ecaf7c4c0"));
            System.out.println(response);
        } catch (ApiException e) {
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\QuestionnaireApi(
    new GuzzleHttp\Client(),
    $config);

//Update Answer
$answer_update = new stdClass();
$answer_id = "3ba82bfd-28b0-4667-b396-760680619fbe";

try {
    $answer_update->value = "new";
    $result = $apiInstance->updateAnswerUsingPut($answer_update, $answer_id);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->updateAnswerUsingPut: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::QuestionnaireApi.new
#Update Answer
answer_update = {"value" => 'USD'}
answer_id = 'fac351fa-6173-47b7-8611-1fc2dad4fdca'
begin
  result = api_instance.update_answer_using_put(answer_update, answer_id)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->update_answer_using_put: #{e}"
end
var apiInstance = new HydrogenNucleusApi.QuestionnaireApi();
//Update Answer
var apiInstance = new HydrogenNucleusApi.QuestionnaireApi();
var callback = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
var answerupdate = new HydrogenNucleusApi.Answer();
var answerid = 'a83ec444-e345-4ab1-a5e5-33c3cd60dcbe';

answerupdate.value = "New";
apiInstance.updateAnswerUsingPut(answerupdate, answerid, callback)

Example Response

{
    "id": "d31c694f-bcb5-427f-b081-91e64e90229a",
    "value": ">40",
    "image": "http://domain.com/age_graphic1.pdf",
    "label": null,
    "weight": null,
    "tooltip": null,
    "is_default": false,
    "metadata": {}
}

Update an answer for your tenant. The answer_id must be provided in the URL. To obtain the appropriate answer_id, use the GET /answer endpoint to view all answers for your tenant and their current information. The endpoint returns the answer_id and the details for the answer.

HTTP REQUEST

PUT /answer/{answer_id}

Delete an answer

Example Request

curl -X DELETE -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/answer/429fa5156-cd89-4056-9125-ce2428b05f11"
api_instance = nucleus_api.QuestionnaireApi(nucleus_api.ApiClient(configuration))
# # # Delete a Answer
answer1_id = '3ba82bfd-28b0-4667-b396-760680619fbe'
try:
    api_instance.delete_answer_using_delete(answer1_id)
except ApiException as e:
    print("Exception when delete_answer_using_delete: %s\n" % e)
QuestionnaireApi apiInstance = new QuestionnaireApi();
        //Delete a Answer
        try {
            Answer responseDelete = apiInstance.deleteAnswerUsingDelete(UUID.fromString("fac351fa-6173-47b7-8611-1fc2dad4fdca"));
            System.out.println(responseDelete);
        } catch (ApiException e) {
            System.err.println("Exception when calling deleteAnswerUsingDelete");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\QuestionnaireApi(
    new GuzzleHttp\Client(),
    $config);
//Delete Answer
$answer_did = "a015e92c-0134-41a6-9606-594937a44940"; // string | UUID account_id

try {
    $apiInstance->deleteAnswerUsingDelete($answer_did);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->deleteAnswerUsingDelete: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::QuestionnaireApi.new
#Delete Answer
answer1_id = '3ba82bfd-28b0-4667-b396-760680619fbe'
begin
  result = api_instance.delete_answer_using_delete(answer1_id)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->delete_answer_using_delete: #{e}"
end
var apiInstance = new HydrogenNucleusApi.QuestionnaireApi();
// //Delete a Answer
var answerdid = "208200cc-cc64-42e5-b87b-e54b48860489";


var deleteanswer = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully.');
    }
};
apiInstance.deleteAnswerUsingDelete(answerdid, deleteanswer)

Response (204 No Content)

Permanently delete an answer for your tenant. The answer_id must be provided. To obtain the appropriate answer_id, use the GET /answer endpoint to view all answers for your tenant. This deletes the answer_id and the details for the answer.

HTTP REQUEST

DELETE /answer/{answer_id}

Risk Profile

This entity allows the user to store risk profile entities such as “Conservative”, “Moderate”, “Aggressive” and attached each profile to a min and max risk score.

Field Type Description
id UUID The id of the risk profile
name string The name of the risk profile
client_id UUID The ID of the client the risk profile belongs to, used for custom risk profiles of advisors at your firm
category string The category of the risk profile to group common profiles
description string The description of the risk profile
risk_score_min double The minimum risk score this profile is assigned to
risk_score_max double The maximum risk score this profile is assigned to
metadata map Custom information associated with the risk profile in the format key:value
See Metadata
secondary_id string Alternate id that can be used to identify the risk profile such as an internal id
create_date timestamp Timestamp for the date and time that the risk profile was created
update_date timestamp Timestamp for the date and time that the risk profile was last updated

List all risk profiles

Example Request

curl -X GET -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/risk_profile"
api_instance = nucleus_api.RiskProfileApi(nucleus_api.ApiClient(configuration))
try:
    api_response = api_instance.get_risk_profile_all_using_get()
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_risk_profile_all_using_get: %s\n" % e)
RiskProfileApi apiInstance = new RiskProfileApi();
        try {
            PageRiskProfile List = apiInstance.getRiskProfileAllUsingGet(true, null, null, 0, 10);
            System.out.println(List);
        } catch (ApiException e) {
            System.err.println("Exception when calling getRiskProfileAllUsingGet");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\RiskProfileApi(
    new GuzzleHttp\Client(),
    $config);
$ascending = false; // bool | ascending
$filter = null; // string | filter
$order_by = null; // string | order_by
$page = 0; // int | page
$size = 10; // int | size

try {
    $riskprofilelist = $apiInstance->getRiskProfileAllUsingGet($ascending, $filter, $order_by, $page, $size);
    print_r($riskprofilelist);
} catch (Exception $e) {
    echo 'Exception when calling RiskProfileApi->getRiskProfileAllUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::RiskProfileApi.new
opts = {
    ascending: false, # BOOLEAN | ascending
    filter: null, # String | filter
    order_by: null, # String | order_by
    page: 0, # Integer | page
    size: 25 # Integer | size
}

begin
  riskprofilelist = api_instance.get_risk_profile_all_using_get(opts)
  p riskprofilelist
rescue NucleusApi::ApiError => e
  puts "Exception when calling RiskProfileApi->get_risk_profile_all_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.RiskProfileApi();
var opts = {
    'ascending': false, // Boolean | ascending
    // 'filter': "", // String | filter
    'orderBy': "update_date", // String | order_by
    'page': 0, // Number | page
    'size': 25 // Number | size
};
var riskprofilelist = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.getRiskProfileAllUsingGet(opts, riskprofilelist)

Example Response

{
    "content": [
        {
            "id": "ce77358c-1e00-4e75-8deb-bd35c4ad8e65",
            "name": "Conservative",
            "client_id": null,
            "category": null,
            "description": null,
            "risk_score_min": 20,
            "risk_score_max": 40,
            "metadata": {},
            "create_date": "2019-07-16T20:06:03.000+0000",
            "update_date": "2019-08-09T21:09:38.000+0000"
        },
        {
            "id": "c31322b7-f363-478f-93da-56994d08996e",
            "name": "Aggressive",
            "client_id": null,
            "category": null,
            "description": null,
            "risk_score_min": 80,
            "risk_score_max": 100,
            "metadata": {},
            "create_date": "2019-07-16T20:06:03.000+0000",
            "update_date": "2019-08-09T21:09:38.000+0000"
        }
    ],
    "total_pages": 1,
    "total_elements": 2,
    "last": false,
    "number_of_elements": 25,
    "first": true,
    "sort": [
        {
            "direction": "DESC",
            "property": "updateDate",
            "ignore_case": false,
            "null_handling": "NATIVE",
            "descending": true,
            "ascending": false
        }
    ],
    "size": 25,
    "number": 0
}

Get details for all risk profiles created within your firm or filter for a specific client_id.

HTTP REQUEST

GET /risk_profile

Create a risk profile

Example Request

curl -X POST -H "Authorization: Bearer <access_token>" \
    -H "Content-Type: application/json" \
    -d '{
            "name": "Conservative",
            "risk_score_min": 20,
            "risk_score_max": 40
        }' "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/risk_profile"

Example Response

{
    "id": "ce77358c-1e00-4e75-8deb-bd35c4ad8e65",
    "name": "Conservative",
    "client_id": null,
    "category": "",
    "description": null,
    "risk_score_min": 20,
    "risk_score_max": 40,
    "metadata": {},
    "create_date": "2019-07-16T20:06:03.000+0000",
    "update_date": "2019-08-09T21:09:38.000+0000"
}
api_instance = nucleus_api.RiskProfileApi(nucleus_api.ApiClient(configuration))
# # Create a RiskProfile
risk = nucleus_api.RiskProfile(name="New One")
try:
    api_response = api_instance.create_risk_profile_using_post(risk)
    pprint(api_response)
except ApiException as e:
    print("create_risk_profile_using_post: %s\n" % e)
RiskProfileApi apiInstance = new RiskProfileApi();
        //Create a RiskProfile
        RiskProfile profileRisk = new RiskProfile();
        profileRisk.setName("New Profile");

        try {
            RiskProfile result = apiInstance.createRiskProfileUsingPost(profileRisk);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling createRiskProfileUsingPost");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\RiskProfileApi(
    new GuzzleHttp\Client(),
    $config);
//Create RiskProfile
$riskprofile = new \com\hydrogen\nucleus\Model\RiskProfile();

try {
    $riskprofile->setName("New Nmame");
    $result = $apiInstance->createRiskProfileUsingPost($riskprofile);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->createRiskProfileUsingPost: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::RiskProfileApi.new
#Create RiskProfile
riskprofile = NucleusApi::RiskProfile.new

begin
  riskprofile.name = "New Name"
  result = api_instance.create_risk_profile_using_post(riskprofile)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->create_risk_profile_using_post: #{e}"
end
var apiInstance = new HydrogenNucleusApi.RiskProfileApi();
//Create a RiskProfile
var riskprofile = new HydrogenNucleusApi.RiskProfile();
riskprofile.name = "New Name";


var newriskprofile = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.createRiskProfileUsingPost(riskprofile, newriskprofile)

Create a new risk profile for your tenant. For custom risk profiles used by advisors in your firm, add a client_id to the profile. To assign a risk profile to a Client or Account and track over time, use the Score service. The create_date will default to the current date. The endpoint returns a unique risk_profile_id that is used to manage the specific risk profile and referenced in other endpoints.

HTTP REQUEST

POST /risk_profile

ARGUMENTS

Parameter Type Required Description
name string required The name of the risk profile
client_id UUID optional The ID of the client the risk profile belongs to, used for custom risk profiles of advisors at your firm
category string optional The category of the risk profile to group common profiles
description string optional The description of the risk profile
risk_score_min double optional The minimum risk score this profile is assigned to
risk_score_max double optional The maximum risk score this profile is assigned to
metadata map optional Custom information associated with the risk profile in the format key:value
See Metadata
secondary_id string optional Alternate id that can be used to identify the risk profile such as an internal id

Retrieve a risk profile

Retrieve the information for a risk profile. The unique risk_profile_id must be provided. The endpoint returns the risk_profile_id and the details for the risk profile.

Example Request

curl -X GET -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/risk_profile/ce77358c-1e00-4e75-8deb-bd35c4ad8e65"
api_instance = nucleus_api.RiskProfileApi(nucleus_api.ApiClient(configuration))
try:
    api_response = api_instance.get_risk_profile_using_get("7a450481-bf5a-48be-afb5-0476a0ade132")
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_risk_profile_using_get: %s\n" % e)
RiskProfileApi apiInstance = new RiskProfileApi();
        try {
            RiskProfile responseRisk = apiInstance.getRiskProfileUsingGet(UUID.fromString("b35078bc-6755-4e30-a846-91ee99201230"));
            System.out.println(responseRisk);
        } catch (ApiException e) {
            System.err.println("Exception when calling getRiskProfileUsingGet");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\RiskProfileApi(
    new GuzzleHttp\Client(),
    $config);
$risk_profile_id = "b35078bc-6755-4e30-a846-91ee99201230"; // string | UUID risk_profile_id

try {
    $riskprofile = $apiInstance->getRiskProfileUsingGet($risk_profile_id);
    print_r($riskprofile);
} catch (Exception $e) {
    echo 'Exception when calling RiskProfileApi->getRiskProfileUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::RiskProfileApi.new
risk_profile_id = 'b35078bc-6755-4e30-a846-91ee99201230' # String | UUID risk_profile_id


begin
  riskprofile = api_instance.get_risk_profile_using_get(risk_profile_id)
  p riskprofile
rescue NucleusApi::ApiError => e
  puts "Exception when calling RiskProfileApi->get_risk_profile_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.RiskProfileApi();
var riskprofileID = "b35078bc-6755-4e30-a846-91ee99201230";


var riskprofile = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.getRiskProfileUsingGet(riskprofileID, riskprofile)

Example Response

{
    "id": "ce77358c-1e00-4e75-8deb-bd35c4ad8e65",
    "name": "Conservative",
    "client_id": null,
    "category": "",
    "description": null,
    "risk_score_min": 20,
    "risk_score_max": 40,
    "metadata": {},
    "create_date": "2019-07-16T20:06:03.000+0000",
    "update_date": "2019-08-09T21:09:38.000+0000"
}

HTTP REQUEST

GET /risk_profile/{risk_profile_id}

Update a risk profile

Example Request

curl -X PUT -H "Authorization: Bearer <access_token>" \
    -H "Content-Type: application/json" \
    -d '{
            "risk_score_min": 25
        }' "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/risk_profile/ce77358c-1e00-4e75-8deb-bd35c4ad8e65"
api_instance = nucleus_api.RiskProfileApi(nucleus_api.ApiClient(configuration))
# # # Update RiskProfile
risk_update = {'name': 'PNC'}
risk_id = 'a023a220-a4df-4608-bd38-5a1d5861b65d'
try:
    api_response = api_instance.update_risk_profile_using_put(risk_update, risk_id)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling update_risk_profile_using_put: %s\n" % e)
RiskProfileApi apiInstance = new RiskProfileApi();
        //Update a RiskProfile
        Map map = new HashMap();
        map.put("category", "New");

        try {
            RiskProfile response = apiInstance.updateRiskProfileUsingPut(map, UUID.fromString("32c28cb9-bca8-477f-9fe8-950bb2ee36a4"));
            System.out.println(response);
        } catch (ApiException e) {
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\RiskProfileApi(
    new GuzzleHttp\Client(),
    $config);

//Update RiskProfile
$riskprofile_update = new stdClass();
$rprofile_id = "c744e036-3611-4bb9-ab34-7297d1513115";

try {
    $riskprofile_update->name = "ABC";
    $result = $apiInstance->updateRiskProfileUsingPut($riskprofile_update, $rprofile_id);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->updateRiskProfileUsingPut: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::RiskProfileApi.new
#Update RiskProfile
riskprofile_update = {"category" => 'new'}
riskprofile_id = '32c28cb9-bca8-477f-9fe8-950bb2ee36a4'
begin
  result = api_instance.update_risk_profile_using_put(riskprofile_update, riskprofile_id)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->update_risk_profile_using_put: #{e}"
end
var apiInstance = new HydrogenNucleusApi.RiskProfileApi();
//Update RiskProfile
var apiInstance = new HydrogenNucleusApi.RiskProfileApi();
var callback = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
var riskprofileupdate = new HydrogenNucleusApi.RiskProfile();
var riskprofileid = 'e33c1872-df91-4396-8374-4dac1fe2e8a3';

riskprofileupdate.name = "New Name";
apiInstance.updateRiskProfileUsingPut(riskprofileupdate, riskprofileid, callback)

Example Response

{
    "id": "ce77358c-1e00-4e75-8deb-bd35c4ad8e65",
    "name": "Conservative",
    "client_id": null,
    "category": "",
    "description": null,
    "risk_score_min": 25,
    "risk_score_max": 40,
    "metadata": {},
    "create_date": "2019-07-16T20:06:03.000+0000",
    "update_date": "2019-08-09T21:09:38.000+0000"
}

Update the information for a risk profile. The unique risk_profile_id must be provided. To obtain the appropriate risk_profile_id, use the GET /risk_profile endpoint to view all available risk_profile_ids and their current information. The details to be updated must also be provided. The endpoint returns the risk_profile_id and the details for the risk profile.

HTTP REQUEST

PUT /risk_profile/{risk_profile_id}

Delete a risk profile

Example Request

curl -X DELETE -H "Authorization: Bearer ce77358c-1e00-4e75-8deb-bd35c4ad8e65" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/risk_profile/c31322b7-f363-478f-93da-56994d08996e"
api_instance = nucleus_api.RiskProfileApi(nucleus_api.ApiClient(configuration))
# # # Delete a RiskProfile
answer1_id = '5ca56b01-a36e-4b35-b381-9d7688ff0e7a'
try:
    api_instance.delete_risk_profile_using_delete(answer1_id)
except ApiException as e:
    print("Exception when delete_risk_profile_using_delete: %s\n" % e)
RiskProfileApi apiInstance = new RiskProfileApi();
        //Delete a RiskProfile
        try {
            RiskProfile deleteresponse = apiInstance.deleteRiskProfileUsingDelete(UUID.fromString("9e9abb92-2f96-42e6-b83f-98f65077f9e9"));
            System.out.println(deleteresponse);
        } catch (ApiException e) {
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\RiskProfileApi(
    new GuzzleHttp\Client(),
    $config);

//Delete Riskprofile
$rprofile_did = "b35078bc-6755-4e30-a846-91ee99201230"; // string | UUID account_id

try {
    $apiInstance->deleteRiskProfileUsingDelete($rprofile_did);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->deleteRiskProfileUsingDelete: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::RiskProfileApi.new

#Delete RiskProfile
riskprofile1_id = 'c744e036-3611-4bb9-ab34-7297d1513115'
begin
  result = api_instance.delete_risk_profile_using_delete(riskprofile1_id)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->delete_risk_profile_using_delete: #{e}"
end
var apiInstance = new HydrogenNucleusApi.RiskProfileApi();
var riskprofiledid = "c744e036-3611-4bb9-ab34-7297d1513115";


var deleteriskprofile = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully.');
    }
};
apiInstance.deleteRiskProfileUsingDelete(riskprofiledid, deleteriskprofile)

Response (204 No Content)

Permanently delete a risk profile. The unique risk_profile_id must be provided. To obtain the appropriate risk_profile_id, use the GET /risk_profile endpoint to view all available risk_profile_ids. This deletes the risk_profile_id and all the profile information associated with it.

HTTP REQUEST

DELETE /risk_profile/{risk_profile_id}

Securities

Security Management

Securities represent financial assets that correspond to a client’s holdings. Orders represent transactions to buy or sell securities. Securities belong to portfolios and are aggregated at a client or account level. A client, account, and portfolio will usually hold more than one security. Securities may also belong to one or more models.

Field Type Description
id UUID The id of the security
name string Name for the security
ticker string Security’s ticker or the symbol on the exchange where it is traded
description longtext Description of the security or company
cusip string Security’s CUSIP, a nine-character numeric or alphanumeric code that identifies a North American financial security for clearing and trade settlement
isin string International Securities Identification Number (ISIN) for the security, a twelve-character alphanumeric code that identifies a financial security for clearing and trade settlement
asset_class string The asset class for the security such as “Equities”, “Fixed Income”, “Commodities”, etc.
category string Category for the security such as “Large Blend” or “Growth”
sector string Sector for the security such as “Technology” or “Pharmaceuticals”
industry string The industry of the security such as “Consumer Tech” or “Enterprise Systems”
exchange string The exchange on which the security is traded
security_class string The security class of the security such as “stock”, “mutual fund”, “exchange-traded fund (ETF)”, etc.
total_expense_ratio double The total expense ratio for the fund represented in percentage terms such as “1.50”
proxy_id UUID ID of a security that will serve as a proxy in financial analytics
currency_code string Alphabetic currency code for the base currency of the security, limited to 3 characters. See currency codes
image string URL of the logo for the security or company
security_composition array Details on the components of a security, their relative weight within the security, and their start and end dates
      component_id UUID The id of the underlying security that is part of the broader security
      start_date date Date for when the underlying security started being a part of the broader security
      end_date date Date for when the underlying security no longer was a part of the broader security
      weight double The weight of the country as a percentage of the broader security; ex. 20 representing 20%. The weights of all the components must add up to 100
security_country array Each country where the security is traded and its relative weight within the security
      country string Country where the security is traded represented using their ISO ALPHA-2 Code. See Country Code reference table
      weight double The weight of the country as a percentage of the security; ex. 20 representing 20%. The weights of all the countries must add up to 100
brokers map List of brokers that the security is traded at
      broker_name string Name of the broker that trades the security
      status string Status of the security at the broker
is_active boolean Indicates if the security is active. Defaults to true which indicates that it is active
metadata map Custom information associated with the security in the format key:value. See Metadata
secondary_id string Alternate id that can be used to identify the object such as an internal id
create_date timestamp Timestamp for the date and time that the record was created
update_date timestamp Timestamp for the date and time that the record was last updated

List all securities

Example Request

curl -X GET -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/security"
api_instance = nucleus_api.SecuritiesApi(nucleus_api.ApiClient(configuration))
try:
    api_response = api_instance.get_security_all_using_get()
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_security_all_using_get: %s\n" % e)
SecuritiesApi apiInstance = new SecuritiesApi();
     try {
            PageSecurity List = apiInstance.getSecurityAllUsingGet(true, null, null, 0, 10);
            System.out.println(List);
        } catch (ApiException e) {
            System.err.println("Exception when calling getSecurityAllUsingGet");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\SecuritiesApi(
    new GuzzleHttp\Client(),
    $config);
$ascending = false; // bool | ascending
$filter = null; // string | filter
$order_by = null; // string | order_by
$page = 0; // int | page
$size = 10; // int | size

try {
    $securitylist = $apiInstance->getSecurityAllUsingGet($ascending, $filter, $order_by, $page, $size);
    print_r($securitylist);
} catch (Exception $e) {
    echo 'Exception when calling SecuritiesApi->getSecurityAllUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::SecuritiesApi.new
opts = {
    ascending: false, # BOOLEAN | ascending
    filter: null, # String | filter
    order_by: null, # String | order_by
    page: 0, # Integer | page
    size: 25, # Integer | size
}

begin
  securitylist = api_instance.get_security_all_using_get(opts)
  p securitylist
rescue NucleusApi::ApiError => e
  puts "Exception when calling SecuritiesApi->get_security_all_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.SecuritiesApi();
var opts = {
    'ascending': false, // Boolean | ascending
    // 'filter': "", // String | filter
    'orderBy': "update_date", // String | order_by
    'page': 0, // Number | page
    'size': 25 // Number | size
};

var securitylist = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.getSecurityAllUsingGet(opts, securitylist)

Example Response

{
    "content": [
        {
            "id": "000094b3-aedb-4626-9bce-7d00140a614c",
            "create_date": "2018-01-01T21:56:03.000+0000",
            "update_date": "2018-01-15T21:56:03.000+0000",
            "industry": "Heavy Construction",
            "is_active": true,
            "name": "Wowjoint Holdings Limited - Common Shares",
            "sector": "Industrial Goods",
            "total_expense_ratio": null,
            "currency_code": "USD",
            "image": null,
            "ticker": "BWOW",
            "description": null,
            "cusip": null,
            "isin": null,
            "proxy_id": "ad761e8d-8c82-4ee7-a1d3-c3669078b432",
            "security_country": [
              {
                "weight": 100,
                "country": "CN"
              }
            ],
            "security_composition": [],
            "asset_class": "EM Equities",
            "brokers": {},
            "metadata": {}
        },
        {
            "id": "0000c009-e76f-40cd-a0ad-d4f73bbc700f",
            "create_date": "2018-01-01T21:56:03.000+0000",
            "update_date": "2018-01-15T21:56:03.000+0000",
            "category": "World Stock",
            "is_active": true,
            "name": "JPMorgan Global Research Enh Idx Select",
            "total_expense_ratio": 2.15,
            "currency_code": "USD",
            "image": null,
            "security_class": "Mutual Fund",
            "ticker": "JEITX",
            "description": null,
            "cusip": null,
            "isin": null,
            "proxy_id": "ad761e8d-8c82-4ee7-a1d3-c3669078b432",
            "security_country": [],
            "security_composition": [],
            "asset_class": "Intl Equities",
            "brokers": {},
            "metadata": {}
        },
        {
            "id": "000183ac-2288-4564-a76b-119f4694be98",
            "create_date": "2018-01-01T21:56:03.000+0000",
            "update_date": "2018-01-15T21:56:03.000+0000",
            "category": "Large Blend",
            "is_active": true,
            "name": "Pioneer Research Y",
            "total_expense_ratio": 3.20,
            "currency_code": "USD",
            "image": null,
            "security_class": "Mutual Fund",
            "ticker": "PRFYX",
            "description": null,
            "cusip": null,
            "isin": null,
            "proxy_id": "ad761e8d-8c82-4ee7-a1d3-c3669078b432",
            "security_country": [],
            "security_composition": [],
            "asset_class": "US Equities",
            "brokers": {},
            "metadata": {}
        },
        {
            "id": "000228d4-6089-4b9f-8849-d0a5503411b1",
            "create_date": "2018-01-01T21:56:03.000+0000",
            "update_date": "2018-01-15T21:56:03.000+0000",
            "category": "Target Date 2051+",
            "is_active": true,
            "name": "BlackRock LifePath Active 2055 R",
            "total_expense_ratio": 2.75,
            "currency_code": "USD",
            "image": null,
            "security_class": "Mutual Fund",
            "ticker": "BRPLX",
            "description": null,
            "cusip": null,
            "isin": null,
            "proxy_id": "ad761e8d-8c82-4ee7-a1d3-c3669078b432",
            "security_country": [],
            "security_composition": [],
            "asset_class": "Diversified Allocation",
            "brokers": {},
            "metadata": {}
        },
        {
            "id": "00036fb7-c47e-44a2-9b55-0fd40e779887",
            "create_date": "2018-01-01T21:56:03.000+0000",
            "update_date": "2018-01-15T21:56:03.000+0000",
            "industry": "Semiconductor Equipment &amp; Materials",
            "is_active": true,
            "name": "Cymer, Inc.",
            "total_expense_ratio": null,
            "currency_code": "USD",
            "image": null,
            "sector": "Technology",
            "ticker": "CYMI",
            "description": null,
            "cusip": null,
            "isin": null,
            "proxy_id": "ad761e8d-8c82-4ee7-a1d3-c3669078b432",
            "security_country": [
              {
                "weight": 100,
                "country": "US"
              }
            ],
            "security_composition": [],
            "asset_class": "US Equities",
            "brokers": {},
            "metadata": {}
        },
    ],
    "total_pages": 1,
    "total_elements": 5,
    "last": false,
    "number_of_elements": 5,
    "first": true,
    "sort": [
        {
            "direction": "DESC",
            "property": "updateDate",
            "ignore_case": false,
            "null_handling": "NATIVE",
            "descending": true,
            "ascending": false
        }
    ],
    "size": 25,
    "number": 0
}

Get details for all securities defined for your tenant. Note that the metadata information, the country information, and the security composition information are stored as nested objects within the security object.

HTTP REQUEST

GET /security

Create a security

Example Request

curl -X POST -H "Authorization: Bearer <access_token>" \
    -H "Content-Type: application/json" \
    -d '{
            "name": "Vanguard FTSE All-World ex-US ETF",
            "ticker": "VEU",
            "asset_class": "Intl Equities",
            "security_class": "ETF",
            "is_active": true,
            "metadata": {},
            "proxy_id": "ad761e8d-8c82-4ee7-a1d3-c3669078b432",
            "security_country": [
              {
                "weight": 50,
                "country": "DE"
              },
              {
                "weight": 15,
                "country": "JP"
              },
              {
                "weight": 21,
                "country": "AX"
              },
              {
                "weight": 5,
                "country": "CN"
              },
              {
                "weight": 5,
                "country": "TU"
              },
              {
                "weight": 4,
                "country": "EU"
              }
          ],
          "security_composition": [
            {
              "component_id": "ac2ead7b-d3c2-401c-9c7e-5b769de9262e",
              "start_date": "2015-01-01",
              "end_date": "2020-01-01",
              "weight": 50
            },
            {
              "component_id": "bfa4621e-233f-4075-b7cc-d7946f38e484",
              "start_date": "2015-01-01",
              "end_date": "2020-01-01",
              "weight": 50
            }
          ]
      }' "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/security"
api_instance = nucleus_api.SecuritiesApi(nucleus_api.ApiClient(configuration))
# Create a Security
security = nucleus_api.Security(name="New", ticker="kgjhh")
try:
    api_response = api_instance.create_security_using_post(security)
    pprint(api_response)
except ApiException as e:
    print("create_security_using_post: %s\n" % e)
SecuritiesApi apiInstance = new SecuritiesApi();
        //Create a Security
        Security security = new Security();
        security.setName("One A");
        security.setTicker("A");

        try {
            Security result = apiInstance.createSecurityUsingPost(security);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling createSecurityUsingPost");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\SecuritiesApi(
    new GuzzleHttp\Client(),
    $config);
#Create Security
security = NucleusApi::Security.new


begin
  security.name = "One"
  security.ticker = "BBB"
  result = api_instance.create_security_using_post(security)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->create_security_using_post: #{e}"
end
api_instance = NucleusApi::SecuritiesApi.new
#Create Security
security = NucleusApi::Security.new


begin
  security.name = "One"
  security.ticker = "BBB"
  result = api_instance.create_security_using_post(security)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->create_security_using_post: #{e}"
end
var apiInstance = new HydrogenNucleusApi.SecuritiesApi();
//Create a Security
var security = new HydrogenNucleusApi.Security();
security.name = "ABC";
security.ticker = "AB";



var newsecurity = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.createSecurityUsingPost(security, newsecurity)

Example Response

{
    "id": "b690fc43-9cdd-4547-b8cd-afadf6b58b2a",
    "create_date": "2018-01-01T21:56:03.000+0000",
    "is_active": true,
    "name": "Vanguard FTSE All-World ex-US ETF",
    "security_class": "ETF",
    "total_expense_ratio": null,
    "currency_code": "USD",
    "image": null,
    "ticker": "VEU",
    "description": null,
    "cusip": null,
    "isin": null,
    "proxy_id": "ad761e8d-8c82-4ee7-a1d3-c3669078b432",
    "security_country": [
      {
        "weight": 50,
        "country": "DE"
      },
      {
        "weight": 15,
        "country": "JP"
      },
      {
        "weight": 21,
        "country": "AX"
      },
      {
        "weight": 5,
        "country": "CN"
      },
      {
        "weight": 5,
        "country": "TU"
      },
      {
        "weight": 4,
        "country": "EU"
      }
    ],
    "security_composition": [
      {
        "component_id": "ac2ead7b-d3c2-401c-9c7e-5b769de9262e",
        "start_date": "2015-01-01",
        "end_date": "2020-01-01",
        "weight": 50
      },
      {
        "component_id": "bfa4621e-233f-4075-b7cc-d7946f38e484",
        "start_date": "2015-01-01",
        "end_date": "2020-01-01",
        "weight": 50
      }
    ],
    "asset_class": "Intl Equities",
    "brokers": {},
    "metadata": {}
}

Create a new security for your tenant. The create_date will default to the current date. The endpoint returns the security_id used to manage the security and referenced in orders, portfolios, transactions etc. Note that the metadata information, the country information, and the security composition information are stored as nested objects within the security object.

HTTP REQUEST

POST /security

ARGUMENTS

Parameter Type Required Description
name string required Name for the security
ticker string required Security’s ticker or the symbol on the exchange where it is traded
description longtext optional Description of the security or company
cusip string optional Security’s CUSIP, a nine-character numeric or alphanumeric code that identifies a North American financial security for clearing and trade settlement
isin string optional International Securities Identification Number (ISIN) for the security, a twelve-character alphanumeric code that identifies a financial security for clearing and trade settlement
asset_class string optional The asset class for the security such as “Equities”, “Fixed Income”, “Commodities”, etc.
category string optional Category for the security such as “Large Blend” or “Growth”
sector string optional Sector for the security such as “Technology” or “Pharmaceuticals”
industry string optional The industry of the security such as “Consumer Tech” or “Enterprise Systems”
security_class string optional The security class of the security such as “stock”, “mutual fund”, “ETF” (exchange-traded fund), etc.
exchange string optional The exchange on which the security is traded
total_expense_ratio double optional The total expense ratio for the fund represented in percentage terms such as “1.50”
proxy_id UUID optional ID of a security that will serve as a proxy in financial analytics
currency_code string optional Alphabetic currency code for the base currency of the security, limited to 3 characters. See currency codes
image string optional URL of the logo for the security or company
security_composition array optional Details on the components of a security, their relative weight within the security, and their start and end dates
      component_id UUID required The id of the underlying security that is part of the broader security
      start_date date required Date for when the underlying security started being a part of the broader security
      end_date date required Date for when the underlying security no longer was a part of the broader security
      weight double required The weight of the country as a percentage of the broader security; ex. 20 representing 20%. The weights of all the components must add up to 100
security_country array optional Each country where the security is traded and its relative weight within the security
      country string required Country where the security is traded represented using their ISO ALPHA-2 Code. See Country Code reference table
      weight double required The weight of the country as a percentage of the security; ex. 20 representing 20%. The weights of all the countries must add up to 100
brokers map optional List of brokers that the security is traded at
      broker_name string required Name of the broker that trades the security
      status string required Status of the security at the broker
is_active boolean optional Indicates if the security is active. Defaults to true which indicates that it is active
metadata map optional Custom information associated with the security in the format key:value. See Metadata
secondary_id string optional Alternate id that can be used to identify the object such as an internal id

Retrieve a security

Example Request

curl -X GET -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/security/b690fc43-9cdd-4547-b8cd-afadf6b58b2a"
api_instance = nucleus_api.SecuritiesApi(nucleus_api.ApiClient(configuration))
try:
    api_response = api_instance.get_security_using_get("01e51cc4-7d33-4a29-a8a2-bb392c4c3c6e")
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_security_using_get: %s\n" % e)
SecuritiesApi apiInstance = new SecuritiesApi();
        try {
            Security responseSecurity = apiInstance.getSecurityUsingGet(UUID.fromString("17d4b0b6-0878-426a-9dd6-5e205caa2bb2"));
            System.out.println(responseSecurity);
        } catch (ApiException e) {
            System.err.println("Exception when calling getSecurityUsingGet");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\SecuritiesApi(
    new GuzzleHttp\Client(),
    $config);
$security_id = "17d4b0b6-0878-426a-9dd6-5e205caa2bb2"; // string | UUID security_id

try {
    $security = $apiInstance->getSecurityUsingGet($security_id);
    print_r($security);
} catch (Exception $e) {
    echo 'Exception when calling SecuritiesApi->getSecurityUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::SecuritiesApi.new
security_id = '17d4b0b6-0878-426a-9dd6-5e205caa2bb2' # String | UUID security_id


begin
  security = api_instance.get_security_using_get(security_id)
  p security
rescue NucleusApi::ApiError => e
  puts "Exception when calling SecuritiesApi->get_security_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.SecuritiesApi();
var securityID = "17d4b0b6-0878-426a-9dd6-5e205caa2bb2";

var opts = {
    'currencyConversion': null, // String | USD
};

var security = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.getSecurityUsingGet(securityID, security)

Example Response

{
    "id": "b690fc43-9cdd-4547-b8cd-afadf6b58b2a",
    "create_date": "2018-01-01T21:56:03.000+0000",
    "update_date": "2018-01-15T21:56:03.000+0000",
    "is_active": true,
    "name": "Vanguard FTSE All-World ex-US ETF",
    "security_class": "ETF",
    "total_expense_ratio": null,
    "currency_code": "USD",
    "image": null,
    "ticker": "VEU",
    "description": null,
    "cusip": null,
    "isin": null,
    "proxy_id": "ad761e8d-8c82-4ee7-a1d3-c3669078b432",
    "security_country": [
      {
        "weight": 50,
        "country": "DE"
      },
      {
        "weight": 15,
        "country": "JP"
      },
      {
        "weight": 21,
        "country": "AX"
      },
      {
        "weight": 5,
        "country": "CN"
      },
      {
        "weight": 5,
        "country": "TU"
      },
      {
        "weight": 4,
        "country": "EU"
      }
    ],
    "security_composition": [
      {
        "component_id": "ac2ead7b-d3c2-401c-9c7e-5b769de9262e",
        "start_date": "2015-01-01",
        "end_date": "2020-01-01",
        "weight": 50
      },
      {
        "component_id": "bfa4621e-233f-4075-b7cc-d7946f38e484",
        "start_date": "2015-01-01",
        "end_date": "2020-01-01",
        "weight": 50
      }
    ],
    "asset_class": "Intl Equities",
    "brokers": {},
    "metadata": {}
}

Retrieve the information for a security defined for your tenant. The security_id must be provided. The endpoint returns the security_id and the details for the security specified.

HTTP REQUEST

GET /security/{security_id}

Update a security

Example Request

curl -X PUT -H "Authorization: Bearer <access_token>" \
    -H "Content-Type: application/json" \
    -d '{
            "is_active": true,
            "name": "Vanguard FTSE All-World ex-US ETF",
            "security_class": "ETF",
            "ticker": "VEU",
            "proxy_id": "ad761e8d-8c82-4ee7-a1d3-c3669078b432",
            "security_country": [
              {
                "weight": 50,
                "country": "DE"
              },
              {
                "weight": 15,
                "country": "JP"
              },
              {
                "weight": 21,
                "country": "AX"
              },
              {
                "weight": 5,
                "country": "CN"
              },
              {
                "weight": 5,
                "country": "TU"
              },
              {
                "weight": 4,
                "country": "EU"
              }
            ],
            "security_composition": [
              {
                "component_id": "ac2ead7b-d3c2-401c-9c7e-5b769de9262e",
                "start_date": "2015-01-01",
                "end_date": "2020-01-01",
                "weight": 50
              },
              {
                "component_id": "bfa4621e-233f-4075-b7cc-d7946f38e484",
                "start_date": "2015-01-01",
                "end_date": "2020-01-01",
                "weight": 50
              }
            ],
            "asset_class": "Intl Equities"
          }' "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/security/b690fc43-9cdd-4547-b8cd-afadf6b58b2a"
api_instance = nucleus_api.SecuritiesApi(nucleus_api.ApiClient(configuration))
# # # Update Security
security_update = {'currency_code': 'GBP'}
security_id = '27fb1c2f-61c2-4e06-92ff-e0e6eefed2cd'
try:
    api_response = api_instance.update_security_using_put(security_update, security_id)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling update_security_using_put: %s\n" % e)
SecuritiesApi apiInstance = new SecuritiesApi();
        //Update a Security
        Map map = new HashMap();
        map.put("category", "New One");

        try {
            Security response = apiInstance.updateSecurityUsingPut(map, UUID.fromString("9d07cfa7-382f-4233-a375-688d4795b93b"));
            System.out.println(response);
        } catch (ApiException e) {
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\SecuritiesApi(
    new GuzzleHttp\Client(),
    $config);
//Update Security
$security_update = new stdClass();
$security_id = "27fb1c2f-61c2-4e06-92ff-e0e6eefed2cd";

try {
    $security_update->name = "anc";
    $result = $apiInstance->updateSecurityUsingPut($security_update, $security_id);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->updateSecurityUsingPut: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::SecuritiesApi.new
#Update Security
security_update = {"ticker" => 'BB'}
security_id = '27fb1c2f-61c2-4e06-92ff-e0e6eefed2cd'
begin
  result = api_instance.update_security_using_put(security_update, security_id)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->update_security_using_put: #{e}"
end
var apiInstance = new HydrogenNucleusApi.SecuritiesApi();
//Update Security
var apiInstance = new HydrogenNucleusApi.SecuritiesApi();
var callback = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
var securityupdate = new HydrogenNucleusApi.Security();
var securityid = '36590fea-91a7-4494-b7e0-1bc12a5c05b8';

securityupdate.currency_code = "GBP";
apiInstance.updateSecurityUsingPut(securityupdate, securityid, callback)

Example Response

{
    "id": "b690fc43-9cdd-4547-b8cd-afadf6b58b2a",
    "create_date": "2018-01-01T21:56:03.000+0000",
    "update_date": "2018-01-15T21:56:03.000+0000",
    "is_active": true,
    "name": "Vanguard FTSE All-World ex-US ETF",
    "security_class": "ETF",
    "total_expense_ratio": null,
    "currency_code": "USD",
    "image": null,
    "ticker": "VEU",
    "description": null,
    "cusip": null,
    "isin": null,
    "proxy_id": "ad761e8d-8c82-4ee7-a1d3-c3669078b432",
    "security_country": [
      {
        "weight": 50,
        "country": "DE"
      },
      {
        "weight": 15,
        "country": "JP"
      },
      {
        "weight": 21,
        "country": "AX"
      },
      {
        "weight": 5,
        "country": "CN"
      },
      {
        "weight": 5,
        "country": "TU"
      },
      {
        "weight": 4,
        "country": "EU"
      }
    ],
    "security_composition": [
      {
        "component_id": "ac2ead7b-d3c2-401c-9c7e-5b769de9262e",
        "start_date": "2015-01-01",
        "end_date": "2020-01-01",
        "weight": 50
      },
      {
        "component_id": "bfa4621e-233f-4075-b7cc-d7946f38e484",
        "start_date": "2015-01-01",
        "end_date": "2020-01-01",
        "weight": 50
      }
    ],
    "asset_class": "Intl Equities",
    "brokers": {},
    "metadata": {}
}

Update a security for your tenant. The security_id must be provided. To obtain the appropriate security_id, use the GET /security endpoint to view all securities defined for your tenant and their current information. The details to be updated must also be provided. The endpoint returns the security_id and all the details for the security. If you wish to have the security no longer be available without permanently deleting it entirely, then use this endpoint to update the is_active field to false.

HTTP REQUEST

PUT /security/{security_id}

Delete a security

Example Request

curl -X DELETE -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/security/b690fc43-9cdd-4547-b8cd-afadf6b58b2a"
api_instance = nucleus_api.SecuritiesApi(nucleus_api.ApiClient(configuration))
# # # # # # Delete a Security
security1_id = '34c33c6f-e82b-4f88-aabf-3cc43afdce4e'
try:
    api_instance.delete_security_using_delete(security1_id)
except ApiException as e:
    print("Exception when delete_security_using_delete: %s\n" % e)
SecuritiesApi apiInstance = new SecuritiesApi();
        //Delete a Security
        try {
            Security deleteresponse = apiInstance.deleteSecurityUsingDelete(UUID.fromString("ca8e7c46-76c9-4850-8fbf-44b2392c4e7a"));
            System.out.println(deleteresponse);
        } catch (ApiException e) {
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\SecuritiesApi(
    new GuzzleHttp\Client(),
    $config);
//Delete Security
$security_did = "9d07cfa7-382f-4233-a375-688d4795b93b"; // string | UUID account_id

try {
    $apiInstance->deleteSecurityUsingDelete($security_did);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->deleteSecurityUsingDelete: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::SecuritiesApi.new
#Delete Security
security1_id = '9d07cfa7-382f-4233-a375-688d4795b93b'
begin
  result = api_instance.delete_security_using_delete(security1_id)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->delete_security_using_delete: #{e}"
end
var apiInstance = new HydrogenNucleusApi.SecuritiesApi();
// // // //Delete a Security
var securityidd = "ca8e7c46-76c9-4850-8fbf-44b2392c4e7a";


var deletesecurity = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully.');
    }
};
apiInstance.deleteSecurityUsingDelete(securityidd, deletesecurity)

Response (204 No Content)

Permanently delete a security for your tenant. The security_id must be provided. To obtain the appropriate security_id, use the GET /security endpoint to view all securities defined for your tenant. Deletes the security_id and the details for the security record. If you wish to have the security no longer be available without permanently deleting it entirely, then use the PUT /security endpoint to update the is_active field to false.

HTTP REQUEST

DELETE /security/{security_id}

Security Prices

Security prices represent stored market prices for specific securities. These can be used to provide a historical view of a security’s pricing and understand its performance. Security prices are required to use the Performance endpoints.

Parameter Type Description
id UUID The id of the security price
security_id UUID The id of the security
price double Value for the close price of the security
adjusted_price double Value for the adjusted close price of the security
open double Value for the open price of the security on the date specified
high double Value for the high price of the security on the date specified
low double Value for the low price of the security on the date specified
volume double Value for the volume of the security on the date specified
date timestamp Date when the particular price was applicable for this security
currency_code string Alphabetic currency code for the base currency of the security, limited to 3 characters. See currency codes
secondary_id string Alternate id that can be used to identify the object such as an internal id
create_date timestamp Timestamp for the date and time that the record was created
update_date timestamp Timestamp for the date and time that the record was last updated

List all security prices

Example Request

curl -X GET -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/security_price"
api_instance = nucleus_api.SecuritiesApi(nucleus_api.ApiClient(configuration))
try:
    api_response = api_instance.get_security_price_all_using_get()
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_security_price_all_using_get: %s\n" % e)
SecuritiesApi apiInstance = new SecuritiesApi();
        try {
            PageSecurityPrice List = apiInstance.getSecurityPriceAllUsingGet(true, null, null, null, 0, 10);
            System.out.println(List);
        } catch (ApiException e) {
            System.err.println("Exception when calling getSecurityPriceAllUsingGet");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\SecuritiesApi(
    new GuzzleHttp\Client(),
    $config);
$ascending = false; // bool | ascending
$currency_conversion = null; // string | currency_conversion
$filter = null; // string | filter
$order_by = null; // string | order_by
$page = 0; // int | page
$size = 10; // int | size

try {
    $securitypricelist = $apiInstance->getSecurityPriceAllUsingGet($ascending, $currency_conversion, $filter, $order_by, $page, $size);
    print_r($securitypricelist);
} catch (Exception $e) {
    echo 'Exception when calling SecuritiesApi->getSecurityPriceAllUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::SecuritiesApi.new
opts = {
    ascending: false, # BOOLEAN | ascending
    currency_conversion: null, # String | currency_conversion
    filter: null, # String | filter
    order_by: null, # String | order_by
    page: 0, # Integer | page
    size: 25 # Integer | size
}

begin
  pricelist = api_instance.get_security_price_all_using_get(opts)
  p pricelist
rescue NucleusApi::ApiError => e
  puts "Exception when calling SecuritiesApi->get_security_price_all_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.SecuritiesApi();
var opts = {
    'ascending': false, // Boolean | ascending
    // 'filter': "", // String | filter
    'orderBy': "update_date", // String | order_by
    'page': 0, // Number | page
    'size': 25 // Number | size
};

var securitypricelist = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.getSecurityPriceAllUsingGet(opts, securitypricelist)

Example Response

{
    "content": [
        {
            "id": "00036fb7-c47e-44a2-9b55-0fd40e779887",
            "create_date": "2018-01-01T21:56:03.000+0000",
            "update_date": "2018-01-15T21:56:03.000+0000",
            "price": 60.55,
            "adjusted_price": 0,
            "open": null,
            "high": null,
            "low": null,
            "volume": null,
            "date": "2017-10-26T00:00:00.000+0000",
            "currency_code": "USD",
            "security_id": "7da36f64-928a-40c7-b663-7fcee7738979"
        },
        {
            "id": "0004b2c6-6909-4630-80fa-df45ccb2d3a1",
            "create_date": "2018-01-01T21:56:03.000+0000",
            "update_date": "2018-01-15T21:56:03.000+0000",
            "price": 77.55,
            "adjusted_price": 0,
            "open": null,
            "high": null,
            "low": null,
            "volume": null,
            "date": "2017-10-09T00:00:00.000+0000",
            "security_id": "c925fdff-aafe-4e14-809f-c03a7717f265"
        },
        {
            "id": "000bca42-8461-4248-a5ff-a5d1f5716e27",
            "create_date": "2018-01-01T21:56:03.000+0000",
            "update_date": "2018-01-15T21:56:03.000+0000",
            "price": 48.54,
            "adjusted_price": 0,
            "open": null,
            "high": null,
            "low": null,
            "volume": null,
            "date": "2017-10-04T00:00:00.000+0000",
            "security_id": "1f87f39b-e6c0-473f-ade0-dc6ba659920a"
        }
    ],
    "last": false,
    "total_pages": 1,
    "total_elements": 3,
    "sort": [
        {
            "direction": "ASC",
            "property": "updateDate",
            "ignore_case": false,
            "null_handling": "NATIVE",
            "descending": false,
            "ascending": true
        }
    ],
    "first": true,
    "number_of_elements": 3,
    "size": 25,
    "number": 0
}

Get prices for all securities defined for your tenant. You can filter using a security_id to obtain the prices for a specific security. You can also choose to get the latest prices for a security or each security.

HTTP REQUEST

GET /security_price

Create a security price

Example Request

curl -X POST -H "Authorization: Bearer <access_token>" \
    -H "Content-Type: application/json" \
    -d '{
            "adjusted_price": 0,
            "date": "2017-10-26T00:00:00.000+0000",
            "price": 60.55,
            "currency_code": "USD",
            "security_id": "7da36f64-928a-40c7-b663-7fcee7738979"
        }' "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/security_price"
api_instance = nucleus_api.SecuritiesApi(nucleus_api.ApiClient(configuration))
# # Create a SecurityPrice
security_price = nucleus_api.SecurityPrice(security_id="1ef0132e-1492-4684-a3e5-f7dbac580d26", price="100", _date="2020-10-10")
try:
    api_response = api_instance.create_security_price_using_post(security_price)
    pprint(api_response)
except ApiException as e:
    print("create_security_price_using_post: %s\n" % e)
SecuritiesApi apiInstance = new SecuritiesApi();
        //Create a Security Price
        SecurityPrice price = new SecurityPrice();
        price.setSecurityId(UUID.fromString("1ef0132e-1492-4684-a3e5-f7dbac580d26"));
        price.setPrice(100.00);
        price.setDate(odt);

        try {
            SecurityPrice result = apiInstance.createSecurityPriceUsingPost(price);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling createSecurityPriceUsingPost");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\SecuritiesApi(
    new GuzzleHttp\Client(),
    $config);
//Create SecurityPrice
$security_price = new \com\hydrogen\nucleus\Model\SecurityPrice();


try {
    $security_price->setSecurityId('1ef0132e-1492-4684-a3e5-f7dbac580d26');
    $security_price->setPrice("200");
    $security_price->setDate("2020-10-10");
    $result = $apiInstance->createSecurityPriceUsingPost($security_price);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->createSecurityPriceUsingPost: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::SecuritiesApi.new
#Create Security Price
security_price = NucleusApi::SecurityPrice.new

begin
  security_price.security_id = '1ef0132e-1492-4684-a3e5-f7dbac580d26'
  security_price.price = "200"
  security_price.date = "2020-10-10"
  result = api_instance.create_security_price_using_post(security_price)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->create_security_price_using_post: #{e}"
end
var apiInstance = new HydrogenNucleusApi.SecuritiesApi();
//Create a SecurityPrice
var securityprice = new HydrogenNucleusApi.SecurityPrice();
securityprice.security_id = '1ef0132e-1492-4684-a3e5-f7dbac580d26';
securityprice.price = "200";
securityprice.date = "2020-10-13";



var newsecurityprice = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.createSecurityPriceUsingPost(securityprice, newsecurityprice)

Example Response

{
  "id": "00036fb7-c47e-44a2-9b55-0fd40e779887",
  "create_date": "2018-01-01T21:56:03.000+0000",
  "price": 60.55,
  "adjusted_price": 0,
  "open": null,
  "high": null,
  "low": null,
  "volume": null,
  "date": "2017-10-26T00:00:00.000+0000",
  "currency_code": "USD",
  "security_id": "7da36f64-928a-40c7-b663-7fcee7738979"
}

Create a new price for a security defined for your tenant. The unique security_id must be provided. To obtain the appropriate security_id, use the GET /security endpoint to view all securities defined for your tenant. The create_date will default to the current date. The endpoint returns the security_price_id used to manage the security price and to map the price to the unique security_id provided.

HTTP REQUEST

POST /security_price

ARGUMENTS

Parameter Type Required Description
security_id UUID required The id of the security
price double required Value for the close price of the security
date timestamp required Date when the particular price was applicable for this security
adjusted_price double optional Value for the adjusted close price of the security
open double optional Value for the open price of the security on the date specified
high double optional Value for the high price of the security on the date specified
low double optional Value for the low price of the security on the date specified
volume double optional Value for the volume of the security on the date specified
currency_code string optional Alphabetic currency code for the base currency of the security, limited to 3 characters. See currency codes
secondary_id string optional Alternate id that can be used to identify the object such as an internal id

Retrieve a security price

Example Request

curl -X GET -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/security_price/00036fb7-c47e-44a2-9b55-0fd40e779887"
api_instance = nucleus_api.SecuritiesApi(nucleus_api.ApiClient(configuration))
try:
    api_response = api_instance.get_security_price_using_get("1f416cd9-12ab-4e42-afba-b4f8aa16b953")
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_security_price_using_get: %s\n" % e)
SecuritiesApi apiInstance = new SecuritiesApi();
        try {
            SecurityPrice responsePrice = apiInstance.getSecurityPriceUsingGet(UUID.fromString("72904022-456e-4090-9751-5bf36d206808"), null);
            System.out.println(responsePrice);
        } catch (ApiException e) {
            System.err.println("Exception when calling getSecurityPriceUsingGet");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\SecuritiesApi(
    new GuzzleHttp\Client(),
    $config);
$security_price_id = "72904022-456e-4090-9751-5bf36d206808"; // string | UUID security_price_id
$currency_conversion = null; // string | USD

try {
    $securityprice = $apiInstance->getSecurityPriceUsingGet($security_price_id, $currency_conversion);
    print_r($securityprice);
} catch (Exception $e) {
    echo 'Exception when calling SecuritiesApi->getSecurityPriceUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::SecuritiesApi.new
security_price_id = '72904022-456e-4090-9751-5bf36d206808' # String | UUID security_price_id

opts = {
    currency_conversion: null, # String | USD
}

begin
  price = api_instance.get_security_price_using_get(security_price_id, opts)
  p price
rescue NucleusApi::ApiError => e
  puts "Exception when calling SecuritiesApi->get_security_price_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.SecuritiesApi();
var securitypriceID = "72904022-456e-4090-9751-5bf36d206808";

var opts = {
    'currencyConversion': null, // String | USD
};

var securityprice = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.getSecurityPriceUsingGet(securitypriceID, opts, securityprice)

Example Response

{
  "id": "00036fb7-c47e-44a2-9b55-0fd40e779887",
  "create_date": "2018-01-01T21:56:03.000+0000",
  "update_date": "2018-01-15T21:56:03.000+0000",
  "price": 60.55,
  "adjusted_price": 0,
  "open": null,
  "high": null,
  "low": null,
  "volume": null,
  "date": "2017-10-26T00:00:00.000+0000",
  "currency_code": "USD",
  "security_id": "7da36f64-928a-40c7-b663-7fcee7738979"
}

Retrieve the information for a security price for a security. The security_price_id must be provided. To obtain the appropriate security_price_id, use the GET /security_price to view all security prices defined for your tenant. The endpoint returns the security_price_id and the details for the security price specified.

HTTP REQUEST

GET /security_price/{security_price_id}

Update a security price

Example Request

curl -X PUT -H "Authorization: Bearer <access_token>" \
    -H "Content-Type: application/json" \
    -d '{
            "adjusted_price": 0,
            "date": "2017-10-26T00:00:00.000+0000",
            "price": 60.55,
            "currency_code": "USD",
            "security_id": "7da36f64-928a-40c7-b663-7fcee7738979"
        }' "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/security_price/00036fb7-c47e-44a2-9b55-0fd40e779887"
api_instance = nucleus_api.SecuritiesApi(nucleus_api.ApiClient(configuration))
# # # # Update SecurityPrice
security_price_update = {'currency_code': 'GBP'}
security_price_id = 'dda8014a-e795-4d53-91e8-49038f3dfc42'
try:
    api_response = api_instance.update_security_price_using_put(security_price_update, security_price_id)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling update_security_price_using_put: %s\n" % e)
SecuritiesApi apiInstance = new SecuritiesApi();
        //Update a SecurityPrice
        Map map = new HashMap();
        map.put("adjusted_price", "200");

        try {
            SecurityPrice response = apiInstance.updateSecurityPriceUsingPut(map, UUID.fromString("be63a881-f64a-4a42-8500-31d56d38c854"));
            System.out.println(response);
        } catch (ApiException e) {
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\SecuritiesApi(
    new GuzzleHttp\Client(),
    $config);
//Update SecurityPrice
$security_price_update = new stdClass();
$security_price_id = "dda8014a-e795-4d53-91e8-49038f3dfc42";

try {
    $security_price_update->price = "300";
    $result = $apiInstance->updateSecurityPriceUsingPut($security_price_update, $security_price_id);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->updateSecurityPriceUsingPut: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::SecuritiesApi.new
#Update Security Price
security_price_update = {"price" => '200'}
security_price_id = 'cf1a42a1-08d0-40f5-9367-25064a285911'
begin
  result = api_instance.update_security_price_using_put(security_price_update, security_price_id)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->update_security_price_using_put: #{e}"
end
var apiInstance = new HydrogenNucleusApi.SecuritiesApi();
//Update Security
var apiInstance = new HydrogenNucleusApi.SecuritiesApi();
var callback = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
var securitypriceupdate = new HydrogenNucleusApi.SecurityPrice();
var securitypriceid = 'b9114707-cec3-4df2-a0e2-1f5f1ba88f9d';

securitypriceupdate.currency_code = "GBP";
apiInstance.updateSecurityPriceUsingPut(securitypriceupdate, securitypriceid, callback)

Example Response

{
    "id": "00036fb7-c47e-44a2-9b55-0fd40e779887",
    "create_date": "2018-01-01T21:56:03.000+0000",
    "update_date": "2018-01-15T21:56:03.000+0000",
    "price": 60.55,
    "adjusted_price": 0,
    "open": null,
    "high": null,
    "low": null,
    "volume": null,
    "date": "2017-10-26T00:00:00.000+0000",
    "currency_code": "USD",
    "security_id": "7da36f64-928a-40c7-b663-7fcee7738979"
}

Update a security price for a security. The security_price_id must be provided. To obtain the appropriate security_price_id, use the GET /security_price to view all security prices defined for your tenant and their current information. The details to be updated must also be provided. The endpoint returns the security_price_id and all the details for the security price.

HTTP REQUEST

PUT /security_price/{security_price_id}

Delete a security price

Example Request

curl -X DELETE -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/security_price/00036fb7-c47e-44a2-9b55-0fd40e779887"
api_instance = nucleus_api.SecuritiesApi(nucleus_api.ApiClient(configuration))
# # # # Delete a SecurityPrice
security_price1_id = '3cf173c8-8a4e-4750-a2ce-56ed7e771b20'
try:
    api_instance.delete_security_price_using_delete(security_price1_id)
except ApiException as e:
    print("Exception when delete_security_price_using_delete: %s\n" % e)
SecuritiesApi apiInstance = new SecuritiesApi();
        //Delete a SecurityPrice
        try {
            SecurityPrice deleteresponse = apiInstance.deleteSecurityPriceUsingDelete(UUID.fromString("a1915de5-c77f-46bd-97d0-aa56c10e7f23"));
            System.out.println(deleteresponse);
        } catch (ApiException e) {
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\SecuritiesApi(
    new GuzzleHttp\Client(),
    $config);
//Delete Security Price
$security_price_did = "be63a881-f64a-4a42-8500-31d56d38c854"; // string | UUID account_id

try {
    $apiInstance->deleteSecurityPriceUsingDelete($security_price_did);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->deleteSecurityPriceUsingDelete: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::SecuritiesApi.new
#Delete Security Price
security_price1_id = '440ebc12-8b0b-4637-89df-492328ba8c19'
begin
  result = api_instance.delete_security_price_using_delete(security_price1_id)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->delete_security_price_using_delete: #{e}"
end
var apiInstance = new HydrogenNucleusApi.SecuritiesApi();
// // // //Delete a Security
var securitypriceidd = "3cedf768-31fc-459a-a8e6-669bb72cdd1c";


var deletesecurityprice = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully.');
    }
};
apiInstance.deleteSecurityPriceUsingDelete(securitypriceidd, deletesecurityprice)

Response (204 No Content)

Permanently delete a security price from a security. The security_price_id must be provided. To obtain the appropriate security_price_id, use the GET /security_price to view all security prices defined for your tenant. Permanently deletes the security_price_id and the price information from the security.

HTTP REQUEST

DELETE /security_price/{security_price_id}

Security Exclusions

Security exclusions represent account or portfolio level preferences to not trade a certain security. For example, when rebalancing an account or portfolio, the security orders generated are checked against the security exclusions before the new order record is created to ensure the order does not include any security exclusions. If it does, then the order record is not generated.

Field Type Description
id UUID The id of the security exclusion
client_id UUID The id of the client to which the security exclusion applies
security_id UUID The id of the security that is subject to the exclusion
is_restrict_buy boolean Indicates if the exclusion applies to buy transactions
is_restrict_sell boolean Indicates if the exclusion applies to sell transactions
account_id UUID The id of the account to which the security exclusion applies (if account-specific)
portfolio_id UUID The id of the portfolio to which the security exclusion applies (if portfolio-specific)
secondary_id string Alternate id that can be used to identify the object such as an internal id
metadata map Custom information associated with the entity in the format key:value
See Metadata
create_date timestamp Timestamp for the date and time the record was created
update_date timestamp Timestamp for the date and time the record was last updated

List all security exclusions

Example Request

curl -X GET -H "Authorization: Bearer <access_token>" \
      "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/security_exclusion"
api_instance = nucleus_api.SecuritiesApi(nucleus_api.ApiClient(configuration))
try:
    api_response = api_instance.get_security_exclusion_all_using_get()
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_security_price_all_using_get: %s\n" % e)
SecuritiesApi apiInstance = new SecuritiesApi();
        try {
            Object securityexclusion = apiInstance.getSecurityExclusionAllUsingGet(true, null, null, 0, 10);
            System.out.println(securityexclusion);
        } catch (ApiException e) {
            System.err.println("Exception when calling getSecurityExclusionAllUsingGet");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\SecuritiesApi(
    new GuzzleHttp\Client(),
    $config);
$ascending = false; // bool | ascending
$filter = null; // string | filter
$order_by = null; // string | order_by
$page = 0; // int | page
$size = 10; // int | size

try {
    $securityexclusionlist = $apiInstance->getSecurityExclusionAllUsingGet($ascending, $filter, $order_by, $page, $size);
    print_r($securityexclusionlist);
} catch (Exception $e) {
    echo 'Exception when calling SecuritiesApi->getSecurityExclusionAllUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::SecuritiesApi.new
opts = {
    ascending: false, # BOOLEAN | ascending
    filter: null, # String | filter
    order_by: null, # String | order_by
    page: 0, # Integer | page
    size: 25 # Integer | size
}

begin
  exclusionlist = api_instance.get_security_exclusion_all_using_get(opts)
  p exclusionlist
rescue NucleusApi::ApiError => e
  puts "Exception when calling SecuritiesApi->get_security_exclusion_all_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.SecuritiesApi();
var opts = {
    'ascending': false, // Boolean | ascending
    // 'filter': "", // String | filter
    'orderBy': "update_date", // String | order_by
    'page': 0, // Number | page
    'size': 25 // Number | size
};

var securityexclusionlist = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.getSecurityExclusionAllUsingGet(opts, securityexclusionlist)

Example Response

{
    "content": [
        {
            "id": "9f8d05ec-e42c-4112-be35-af6dc5054bd4",
            "create_date": "2018-01-01T21:56:03.000+0000",
            "update_date": "2018-01-15T21:56:03.000+0000",
            "client_id": "199a8c08-cdd5-4c8c-8abf-535447cea11b",
            "security_id": "00036fb7-c47e-44a2-9b55-0fd40e779887",
            "account_id": "199a8c08-cdd5-4c8c-8abf-535447cea11b",
            "is_restrict_buy": true,
            "is_restrict_sell": false,
            "metadata": {}
        },
        {
            "id": "03722da4-9d79-4cd5-8411-6a15ced457c2",
            "create_date": "2018-01-01T21:56:03.000+0000",
            "update_date": "2018-01-15T21:56:03.000+0000",
            "is_restrict_buy": true,
            "is_restrict_sell": false,
            "client_id": "199a8c08-cdd5-4c8c-8abf-535447cea11b",
            "security_id": "00036fb7-c47e-44a2-9b55-0fd40e779887",
            "metadata": {}
        }
    ],
    "total_elements": 2,
    "last": true,
    "number_of_elements": 2,
    "first": true,
    "sort": [
        {
            "direction": "DESC",
            "property": "updateDate",
            "ignore_case": false,
            "null_handling": "NATIVE",
            "descending": true,
            "ascending": false
        }
    ],
    "size": 25,
    "number": 0
}

Get details for all security exclusions defined for your tenant. There’s the option to filter using a security_id to view the exclusions on a specific security. There’s also the option to filter using a client_id, account_id, or portfolio_id to view the exclusions for a specific account or portfolio.

HTTP REQUEST

GET /security_exclusion

Create a security exclusion

Example Request

curl -X POST -H "Authorization: Bearer <access_token>" \
    -H "Content-Type: application/json" \
    -d '{
            "client_id": "199a8c08-cdd5-4c8c-8abf-535447cea11b",
            "security_id": "00036fb7-c47e-44a2-9b55-0fd40e779887",
            "account_id": "199a8c08-cdd5-4c8c-8abf-535447cea11b",
            "is_restrict_buy": true,
            "is_restrict_sell": false
        }' "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/security_exclusion"
api_instance = nucleus_api.SecuritiesApi(nucleus_api.ApiClient(configuration))
# # Create a SecurityExclusion
security_exclusion = nucleus_api.SecurityExclusion(security_id="1ef0132e-1492-4684-a3e5-f7dbac580d26", client_id="173d4b11-2d88-4e23-aefe-a10e1c0fdaad", is_restrict_buy="false", is_restrict_sell="false")
try:
    api_response = api_instance.create_security_exclusion_using_post(security_exclusion)
    pprint(api_response)
except ApiException as e:
    print("create_security_exclusion_using_post: %s\n" % e)
SecuritiesApi apiInstance = new SecuritiesApi();
        //Create a Security Exclusion
        SecurityExclusion exclusion = new SecurityExclusion();
        exclusion.setSecurityId(UUID.fromString("1ef0132e-1492-4684-a3e5-f7dbac580d26"));
        exclusion.setClientId(UUID.fromString("173d4b11-2d88-4e23-aefe-a10e1c0fdaad"));
        exclusion.setIsRestrictBuy(false);
        exclusion.setIsRestrictSell(false);

        try {
            SecurityExclusion result = apiInstance.createSecurityExclusionUsingPost(exclusion);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling createSecurityExclusionUsingPost");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\SecuritiesApi(
    new GuzzleHttp\Client(),
    $config);
//Create SecurityExclusion
$security_exclusion = new \com\hydrogen\nucleus\Model\SecurityExclusion();


try {
    $security_exclusion->setSecurityId('1ef0132e-1492-4684-a3e5-f7dbac580d26');
    $security_exclusion->setClientId('173d4b11-2d88-4e23-aefe-a10e1c0fdaad');
    $security_exclusion->setIsRestrictBuy("false");
    $security_exclusion->setIsRestrictSell("false");
    $result = $apiInstance->createSecurityExclusionUsingPost($security_exclusion);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->createSecurityExclusionUsingPost: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::SecuritiesApi.new
#Create Security Exclusion
security_exclusion = NucleusApi::SecurityExclusion.new

begin
  security_exclusion.security_id = 'security_exclusion'
  security_exclusion.account_id = "173d4b11-2d88-4e23-aefe-a10e1c0fdaad"
  security_exclusion.is_restrict_buy = "false"
  security_exclusion.is_restrict_sell = "false"
  result = api_instance.create_security_exclusion_using_post(security_exclusion)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->create_security_exclusion_using_post: #{e}"
end
var apiInstance = new HydrogenNucleusApi.SecuritiesApi();
//Create a SecurityExclusion
var securityexclusion = new HydrogenNucleusApi.SecurityExclusion();
securityexclusion.security_id = '1ef0132e-1492-4684-a3e5-f7dbac580d26';
securityexclusion.client_id = '173d4b11-2d88-4e23-aefe-a10e1c0fdaad';
securityexclusion.is_restrict_buy = "false";
securityexclusion.is_restrict_sell = "false";



var newsecurityexclusion = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.createSecurityExclusionUsingPost(securityexclusion, newsecurityexclusion)

Example Response

{
    "id": "9f8d05ec-e42c-4112-be35-af6dc5054bd4",
    "create_date": "2018-01-01T21:56:03.000+0000",
    "client_id": "199a8c08-cdd5-4c8c-8abf-535447cea11b",
    "security_id": "00036fb7-c47e-44a2-9b55-0fd40e779887",
    "account_id": "199a8c08-cdd5-4c8c-8abf-535447cea11b",
    "is_restrict_buy": true,
    "is_restrict_sell": false,
    "metadata": {}
}

Create a new security exclusion for a specific account or portfolio. The security_id of the security to be excluded and a client_id and account_id to which the security exclusion applies must be provided. To obtain the appropriate security_id use the GET /security endpoint to view all securities defined for your tenant. To obtain the appropriate client_id use the GET /client endpoint to view all clients defined for your tenant. To obtain the appropriate account_id, use the GET /account endpoint to view all the accounts defined for your tenant. If the exclusion applies to a specific portfolio, then provide a unique portfolio_id for the client portfolio in question. To obtain the appropriate portfolio_id use the GET /portfolio endpoint to view all the portfolios defined for your tenant. The create_date will default to the current date. The endpoint returns a security_exclusion_id that can be used to manage the security exclusion.

HTTP REQUEST

POST /security_exclusion

ARGUMENTS

Parameter Type Required Description
client_id UUID required The id of the client to which the security exclusion applies
security_id UUID required The id of the security that is subject to the exclusion
is_restrict_buy boolean required Indicates if the exclusion applies to buy transactions
is_restrict_sell boolean required Indicates if the exclusion applies to sell transactions
account_id UUID optional The id of the account to which the security exclusion applies (if account-specific)
portfolio_id UUID optional The id of the portfolio to which the security exclusion applies (if portfolio-specific)
metadata map optional Custom information associated with the entity in the format key:value
See Metadata
secondary_id string optional Alternate id that can be used to identify the object such as an internal id

Retrieve a security exclusion

Example Request

curl -X GET -H "Authorization: Bearer <access_token>" \
      "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/security_exclusion/9f8d05ec-e42c-4112-be35-af6dc5054bd4"
try:
    api_response = api_instance.get_security_exclusion_using_get("29006aa4-2a2b-4c56-91fe-cd587e063a8d")
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_security_exclusion_using_get: %s\n" % e)
SecuritiesApi apiInstance = new SecuritiesApi();
        try {
            SecurityExclusion responseExclusion = apiInstance.getSecurityExclusionUsingGet(UUID.fromString("7a592038-d985-4957-8546-1f6bf7722370"));
            System.out.println(responseExclusion);
        } catch (ApiException e) {
            System.err.println("Exception when calling getSecurityExclusionUsingGet");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\SecuritiesApi(
    new GuzzleHttp\Client(),
    $config);
$security_exclusion_id = "7a592038-d985-4957-8546-1f6bf7722370"; // string | UUID security_exclusion_id

try {
    $securityexclusion = $apiInstance->getSecurityExclusionUsingGet($security_exclusion_id);
    print_r($securityexclusion);
} catch (Exception $e) {
    echo 'Exception when calling SecuritiesApi->getSecurityExclusionUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::SecuritiesApi.new
security_exclusion_id = '7a592038-d985-4957-8546-1f6bf7722370' # String | UUID security_exclusion_id


begin
  exclusion = api_instance.get_security_exclusion_using_get(security_exclusion_id)
  p exclusion
rescue NucleusApi::ApiError => e
  puts "Exception when calling SecuritiesApi->get_security_exclusion_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.SecuritiesApi();
var securityexclusionID = "7a592038-d985-4957-8546-1f6bf7722370";

var opts = {
    'currencyConversion': null, // String | USD
};

var securityexclusion = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.getSecurityExclusionUsingGet(securityexclusionID, securityexclusion)

Example Response

{
    "id": "9f8d05ec-e42c-4112-be35-af6dc5054bd4",
    "create_date": "2018-01-01T21:56:03.000+0000",
    "update_date": "2018-01-15T21:56:03.000+0000",
    "client_id": "199a8c08-cdd5-4c8c-8abf-535447cea11b",
    "security_id": "00036fb7-c47e-44a2-9b55-0fd40e779887",
    "account_id": "199a8c08-cdd5-4c8c-8abf-535447cea11b",
    "is_restrict_buy": true,
    "is_restrict_sell": false,
    "metadata": {}
}

Retrieve the information for a security exclusion. The security_exclusion_id must be provided. The endpoint returns the details for the security exclusion specified.

HTTP REQUEST

GET /security_exclusion/{security_exclusion_id}

Update a security exclusion

Example Request

curl -X PUT -H "Authorization: Bearer <access_token>" \
    -H "Content-Type: application/json" \
    -d '{
            "client_id": "199a8c08-cdd5-4c8c-8abf-535447cea11b",
            "security_id": "00036fb7-c47e-44a2-9b55-0fd40e779887",
            "account_id": "199a8c08-cdd5-4c8c-8abf-535447cea11b",
            "is_restrict_buy": true,
            "is_restrict_sell": false
        }' "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/security_exclusion/9f8d05ec-e42c-4112-be35-af6dc5054bd4"
api_instance = nucleus_api.SecuritiesApi(nucleus_api.ApiClient(configuration))
# # # # Update SecurityExclusion
security_exclusion_update = {'is_restrict_buy': 'true'}
security_exclusion_id = 'b77fbfe6-7be4-4595-837b-c380102e75da'
try:
    api_response = api_instance.update_security_exclusion_using_put(security_exclusion_update, security_exclusion_id)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling update_security_exclusion_using_put: %s\n" % e)
SecuritiesApi apiInstance = new SecuritiesApi();

        //Update a SecurityExclusion
        Map map = new HashMap();
        map.put("is_restrict_buy", "true");

        try {
            SecurityExclusion response = apiInstance.updateSecurityExclusionUsingPut(map, UUID.fromString("453a370c-b66d-4f3b-b3ac-47557c6f1b8f"));
            System.out.println(response);
        } catch (ApiException e) {
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\SecuritiesApi(
    new GuzzleHttp\Client(),
    $config);
//Update SecurityExclusion
$security_exclusion_update = new stdClass();
$security_exclusion_id = "453a370c-b66d-4f3b-b3ac-47557c6f1b8f";

try {
    $security_exclusion_update->is_restrict_buy = "false";
    $result = $apiInstance->updateSecurityExclusionUsingPut($security_exclusion_update, $security_exclusion_id);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->updateSecurityExclusionUsingPut: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::SecuritiesApi.new
#Update Security Exclusion
security_exclusion_update = {"is_restrict_sell" => 'false'}
security_exclusion_id = '453a370c-b66d-4f3b-b3ac-47557c6f1b8f'
begin
  result = api_instance.update_security_exclusion_using_put(security_exclusion_update, security_exclusion_id)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->update_security_exclusion_using_put: #{e}"
end
var apiInstance = new HydrogenNucleusApi.SecuritiesApi();
// //Update SecurityExclusion
var apiInstance = new HydrogenNucleusApi.SecuritiesApi();
var callback = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
var securityexclusionupdate = new HydrogenNucleusApi.SecurityExclusion();
var securityexclusionid = 'e1f69766-6666-414d-b193-b9283438d8a4';

securityexclusionupdate.is_restrict_buy = "false";
apiInstance.updateSecurityExclusionUsingPut(securityexclusionupdate, securityexclusionid, callback)

Example Response

{
    "id": "9f8d05ec-e42c-4112-be35-af6dc5054bd4",
    "create_date": "2018-01-01T21:56:03.000+0000",
    "update_date": "2018-01-15T21:56:03.000+0000",
    "client_id": "199a8c08-cdd5-4c8c-8abf-535447cea11b",
    "security_id": "00036fb7-c47e-44a2-9b55-0fd40e779887",
    "account_id": "199a8c08-cdd5-4c8c-8abf-535447cea11b",
    "is_restrict_buy": true,
    "is_restrict_sell": false,
    "metadata": {}
}

Update the information for a security exclusion. The security_exclusion_id must be provided. To obtain the appropriate security_exclusion_id, use the GET /security_exclusion endpoint to view all security exclusions defined firm-wide and their current information. The details to be updated must also be provided. The endpoint returns the security_exclusion_id and all of the details for the security exclusion.

HTTP REQUEST

PUT /security_exclusion/{security_exclusion_id}

Delete a security exclusion

Example Request

curl -X DELETE -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/security_exclusion/9f8d05ec-e42c-4112-be35-af6dc5054bd4"
api_instance = nucleus_api.SecuritiesApi(nucleus_api.ApiClient(configuration))
# # # Delete a SecurityExclusion
security_exclusion1_id = 'cf1a42a1-08d0-40f5-9367-25064a285911'
try:
    api_instance.delete_security_exclusion_using_delete(security_exclusion1_id)
except ApiException as e:
    print("Exception when delete_security_exclusion_using_delete: %s\n" % e)
SecuritiesApi apiInstance = new SecuritiesApi();

        //Delete a SecurityExclusion
        try {
            SecurityExclusion deleteresponse = apiInstance.deleteSecurityExclusionUsingDelete(UUID.fromString("4544fd24-2f36-44d7-8a87-8c589f6f64c6"));
            System.out.println(deleteresponse);
        } catch (ApiException e) {
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\SecuritiesApi(
    new GuzzleHttp\Client(),
    $config);
//Delete Security Exclusion
$security_exclusion_did = "aef121a7-617d-4c85-ac5c-6d4734edbc30"; // string | UUID account_id

try {
    $apiInstance->deleteSecurityExclusionUsingDelete($security_exclusion_did);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->deleteSecurityExclusionUsingDelete: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::SecuritiesApi.new
#Delete Security Exclusion
security_exclusion1_id = 'aef121a7-617d-4c85-ac5c-6d4734edbc30'
begin
  result = api_instance.delete_security_exclusion_using_delete(security_exclusion1_id)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->delete_security_exclusion_using_delete: #{e}"
end
var apiInstance = new HydrogenNucleusApi.SecuritiesApi();
// // // // //Delete a SecurityExclusion
var securityexclusionidd = "f3069aa7-f3c5-48db-b66c-30c3b129b757";


var deletesecurityexclusion = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully.');
    }
};
apiInstance.deleteSecurityExclusionUsingDelete(securityexclusionidd, deletesecurityexclusion)

Response (204 No Content)

Permanently delete a security exclusion. The security_exclusion_id must be provided. To obtain the appropriate security_exclusion_id, use the GET /security_exclusion endpoint to view all security exclusions defined firm-wide. The endpoint deletes the security_exclusion_id and the security exclusion record.

HTTP REQUEST

DELETE /security_exclusion/{security_exclusion_id}

Score

Score is used to store scores referenced within the application. Scores may be either calculated using the Proton API or obtained from an alternate source. Scores can be stored for key entities including clients, accounts, goals, portfolios, allocations, models, benchmarks and securities. Score types that can be stored include:

1) Risk Score
2) Dimensional Risk Score
3) Diversification Score
4) Portfolio Optimization Score
5) Goal Achievement Score
6) Credit Score
7) Risk Profile

Field Type Description
id UUID The id for the score
score_type string The type of score. Values may be risk_score, dimensional_risk_score, diversification_score, portfolio_optimization_score, goal_achievement_score, credit_score, or risk_profile
score_value string The value of the score, which may be a number, a label, etc.
client_id UUID The id of a client to which the score applies (if client-specific)
account_id UUID The id of an account to which the score applies (if account-specific)
portfolio_id UUID The id of a portfolio to which the score applies (if portfolio-specific)
goal_id UUID The id of a goal to which the score applies (if goal-specific)
allocation_id UUID The id of an allocation to which the score applies (if allocation-specific)
model_id UUID The id of a model to which the score applies (if model-specific)
benchmark_id UUID The id of a benchmark to which the score applies (if benchmark-specific)
security_id UUID The id of a security to which the score applies (if security-specific)
score_time_stamp datetime Date and time for the score
metadata map Custom information associated with the score in the format key:value
See Metadata
secondary_id string Alternate id that can be used to identify the object such as an internal id
create_date timestamp Timestamp for the date and time that the record was created
update_date timestamp Timestamp for the date and time that the record was last updated

List all scores

Example Request

curl -X GET -H "Authorization: Bearer <access_token>" \
  "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/score"
api_instance = nucleus_api.ScoreApi(nucleus_api.ApiClient(configuration))
try:
    api_response = api_instance.get_score_all_using_get()
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_score_all_using_get: %s\n" % e)
ScoreApi apiInstance = new ScoreApi();
        try {
            PageScore List = apiInstance.getScoreAllUsingGet(true, null, null, 0, 10);
            System.out.println(List);
        } catch (ApiException e) {
            System.err.println("Exception when calling getScoreAllUsingGet");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\ScoreApi(
    new GuzzleHttp\Client(),
    $config);
$ascending = false; // bool | ascending
$filter = null; // string | filter
$order_by = null; // string | order_by
$page = 0; // int | page
$size = 10; // int | size

try {
    $scorelist = $apiInstance->getScoreAllUsingGet($ascending, $filter, $order_by, $page, $size);
    print_r($scorelist);
} catch (Exception $e) {
    echo 'Exception when calling ScoreApi->getScoreAllUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::ScoreApi.new
opts = {
    ascending: false, # BOOLEAN | ascending
    filter: null, # String | filter
    order_by: null, # String | order_by
    page: 0, # Integer | page
    size: 25 # Integer | size
}

begin
  scorelist = api_instance.get_score_all_using_get(opts)
  p scorelist
rescue NucleusApi::ApiError => e
  puts "Exception when calling ScoreApi->get_score_all_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.ScoreApi();
var opts = {
    'ascending': false, // Boolean | ascending
    // 'filter': "", // String | filter
    'orderBy': "update_date", // String | order_by
    'page': 0, // Number | page
    'size': 25 // Number | size
};

var scorelist = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.getScoreAllUsingGet(opts, scorelist)

Example Response

{
    "content": [
        {
            "id": "739ecd39-e1ae-4a0b-b266-dd3ddc616163",
            "create_date": "2018-11-01T00:00:00.000+0000",
            "score_type": "risk_score",
            "score_value": "76",
            "client_id": "58f90162-1bd7-4441-a1f2-cbaa4b2e3595",
            "score_time_stamp": "2018-11-01T00:00:00.000+0000",
            "metadata": {
                "questionnaire": "Risk Profile Questionnaire"
            }
        },
        {
            "id": "4675770f-e52b-46e2-ac4b-683adbeb034c",
            "create_date": "2017-01-01T00:00:00.000+0000",
            "score_type": "risk_score",
            "score_value": "85",
            "model_id": "89a510ad-e817-49a3-9af2-0fb59487d9ad",
            "score_time_stamp": "2017-01-01T00:00:00.000+0000",
            "metadata": {}
        }
        {
            "id": "c0b33394-998c-4095-ad98-22551f7dbb1f",
            "create_date": "2018-11-01T00:00:00.000+0000",
            "score_type": "risk_profile",
            "score_value": "Conservative",
            "client_id": "c17cd2e1-5ecc-48e0-8f7c-5cecd9055429",
            "score_time_stamp": "2018-11-01T00:00:00.000+0000",
            "metadata": {
                "questionnaire": "Risk Profile Questionnaire"
            }
        }
    ],
    "last": false,
    "total_pages": 1,
    "total_elements": 3,
    "sort": [
        {
            "direction": "DESC",
            "property": "updateDate",
            "ignore_case": false,
            "null_handling": "NATIVE",
            "descending": true,
            "ascending": false
        }
    ],
    "first": true,
    "number_of_elements": 3,
    "size": 25,
    "number": 0
}

Get information for all scores stored for your tenant. You can filter using one of the unique ids such as the client_id to view the scores for a client or for another particular entity. You can also filter by the value provided for score_time_stamp to find the scores for a specific date or date range. Note that the metadata information for the score is stored as a nested object within the score object.

HTTP REQUEST

GET /score

Create a score

Example Request

curl -X POST -H "Authorization: Bearer <access_token>" \
-H "Content-Type: application/json" \
-d '{
          "score_type": "risk_score",
          "score_value": "76",
          "client_id": "58f90162-1bd7-4441-a1f2-cbaa4b2e3595",
          "score_time_stamp": "2018-11-01T00:00:00.000+0000",
          "metadata": {
              "questionnaire": "Risk Profile Questionnaire"
          }
    }' "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/score"
api_instance = nucleus_api.ScoreApi(nucleus_api.ApiClient(configuration))

# # Create a Score
score = nucleus_api.Score(score_type="risk_score", score_value="one")
try:
    api_response = api_instance.create_score_using_post(score)
    pprint(api_response)
except ApiException as e:
    print("create_score_using_post: %s\n" % e)
ScoreApi apiInstance = new ScoreApi();
        //Create a Score
            Score score = new Score();
        score.setScoreType(Score.ScoreTypeEnum.fromValue("risk_score"));
        score.setScoreValue("one");

        try {
            Score result = apiInstance.createScoreUsingPost(score);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling createScoreUsingPost");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\ScoreApi(
    new GuzzleHttp\Client(),
    $config);
//Create Score
$score = new \com\hydrogen\nucleus\Model\Score();


try {
    $score->setScoreType("risk_score");
    $score->setScoreValue("New");
    $result = $apiInstance->createScoreUsingPost($score);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->createScoreUsingPost: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::ScoreApi.new
#Create Score
score = NucleusApi::Score.new


begin
  score.score_type = "Final"
  score.score_value = "One"
  result = api_instance.create_score_using_post(score)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->create_score_using_post: #{e}"
end
var apiInstance = new HydrogenNucleusApi.ScoreApi();
//Create a Score
var score = new HydrogenNucleusApi.Score();
score.score_type = "risk_score";
score.score_value = "one"

var newscore = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.createScoreUsingPost(score, newscore)

Example Response

{
    "id": "739ecd39-e1ae-4a0b-b266-dd3ddc616163",
    "create_date": "2018-11-01T00:00:00.000+0000",
    "score_type": "risk_score",
    "score_value": "76",
    "client_id": "58f90162-1bd7-4441-a1f2-cbaa4b2e3595",
    "score_time_stamp": "2018-11-01T00:00:00.000+0000",
    "metadata": {
        "questionnaire": "Risk Profile Questionnaire"
    }
}

Create a score for a client, account, goal, portfolio, allocation, model, benchmark or security. The endpoint returns a score_id that can then be used to manage the score.

HTTP REQUEST

POST /score

ARGUMENTS

Parameter Type Required Description
score_type string required The type of score. Values may be risk_score, dimensional_risk_score, diversification_score, portfolio_optimization_score, goal_achievement_score, credit_score, or risk_profile
score_value string required The value of the score, which may be a number, a label, etc.
client_id UUID optional The id of a client to which the score applies (if client-specific)
account_id UUID optional The id of an account to which the score applies (if account-specific)
portfolio_id UUID optional The id of a portfolio to which the score applies (if portfolio-specific)
goal_id UUID optional The id of a goal to which the score applies (if goal-specific)
allocation_id UUID optional The id of an allocation to which the score applies (if allocation-specific)
model_id UUID optional The id of a model to which the score applies (if model-specific)
benchmark_id UUID optional The id of a benchmark to which the score applies (if benchmark-specific)
security_id UUID optional The id of a security to which the score applies (if security-specific)
score_time_stamp datetime optional Date and time for the score
metadata map optional Custom information associated with the score in the format key:value
See Metadata
secondary_id string optional Alternate id that can be used to identify the object such as an internal id

Retrieve a score

Example Request

curl -X GET -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/score/739ecd39-e1ae-4a0b-b266-dd3ddc616163"
api_instance = nucleus_api.ScoreApi(nucleus_api.ApiClient(configuration))
try:
    api_response = api_instance.get_score_using_get("eb3a4ec0-18b3-4e6d-bc78-9b688e553031")
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_score_using_get: %s\n" % e)
ScoreApi apiInstance = new ScoreApi();
        try {
            Score responseScore = apiInstance.getScoreUsingGet(UUID.fromString("eb3a4ec0-18b3-4e6d-bc78-9b688e553031"));
            System.out.println(responseScore);
        } catch (ApiException e) {
            System.err.println("Exception when calling getScoreAllUsingGet");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\ScoreApi(
    new GuzzleHttp\Client(),
    $config);
$score_id = "eb3a4ec0-18b3-4e6d-bc78-9b688e553031"; // string | UUID score_id

try {
    $score = $apiInstance->getScoreUsingGet($score_id);
    print_r($score);
} catch (Exception $e) {
    echo 'Exception when calling ScoreApi->getScoreUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::ScoreApi.new
score_id = 'eb3a4ec0-18b3-4e6d-bc78-9b688e553031' # String | UUID score_id


begin
  score = api_instance.get_score_using_get(score_id)
  p score
rescue NucleusApi::ApiError => e
  puts "Exception when calling ScoreApi->get_score_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.ScoreApi();
var scoreID = "eb3a4ec0-18b3-4e6d-bc78-9b688e553031";

var opts = {
    'currencyConversion': null, // String | USD
};

var score = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.getScoreUsingGet(scoreID, score)

Example Response

{
    "id": "739ecd39-e1ae-4a0b-b266-dd3ddc616163",
    "create_date": "2018-11-01T00:00:00.000+0000",
    "score_type": "risk_score",
    "score_value": "76",
    "client_id": "58f90162-1bd7-4441-a1f2-cbaa4b2e3595",
    "score_time_stamp": "2018-11-01T00:00:00.000+0000",
    "metadata": {
        "questionnaire": "Risk Profile Questionnaire"
    }
}

Retrieve the information for a specific score associated with a client, account, goal, portfolio, allocation, model, benchmark or security. The unique score_id must be provided. The endpoint returns the score_id and details for the score specified. Note that the metadata information for the score is stored as a nested object within the score object.

HTTP REQUEST

GET /score/{score_id}

Update a score

Example Request

curl -X PUT -H "Authorization: Bearer <access_token>" \
-H "Content-Type: application/json" \
-d '{
          "score_type": "risk_score",
          "score_value": "80",
          "client_id": "58f90162-1bd7-4441-a1f2-cbaa4b2e3595",
          "score_time_stamp": "2018-11-01T00:00:00.000+0000",
          "metadata": {
              "questionnaire": "Risk Profile Questionnaire"
          }
    }' "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/score/739ecd39-e1ae-4a0b-b266-dd3ddc616163"
api_instance = nucleus_api.ScoreApi(nucleus_api.ApiClient(configuration))
# # # Update Score
score_update = {'score_value': 'Two'}
score_id = '2bb2249f-95bc-43e9-b60d-7599a3684a82'
try:
    api_response = api_instance.update_score_using_put(score_update, score_id)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling update_score_using_put: %s\n" % e)
ScoreApi apiInstance = new ScoreApi();
         //Update a Score
         Map map = new HashMap();
         map.put("score_value", "one");

         try {
             Score response = apiInstance.updateScoreUsingPut(map, UUID.fromString("c6d9c639-6979-4412-a445-513dc804d131"));
             System.out.println(response);
         } catch (ApiException e) {
             e.printStackTrace();
         }
$apiInstance = new com\hydrogen\nucleus\Api\ScoreApi(
    new GuzzleHttp\Client(),
    $config);
//Update Score
$score_update = new stdClass();
$score_id = "c7f100ea-3e16-4646-9c7b-2cc24ca1d6c5";

try {
    $score_update->score_value = "56";
    $result = $apiInstance->updateScoreUsingPut($score_update, $score_id);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->updateScoreUsingPut: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::ScoreApi.new
#Update Score
score_update = {"score_type" => 'ABc'}
score_id = 'b8b0c9e4-6526-4ce8-9a7f-477ea548d80a'
begin
  result = api_instance.update_score_using_put(score_update, score_id)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->update_score_using_put: #{e}"
end
var apiInstance = new HydrogenNucleusApi.ScoreApi();
// //Update Score
var apiInstance = new HydrogenNucleusApi.ScoreApi();
var callback = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
var scoreupdate = new HydrogenNucleusApi.Score();
var scoreid = '01dfbcaf-27a5-4232-87ac-8ba3b280d73d';

scoreupdate.score_value = "one";
apiInstance.updateScoreUsingPut(scoreupdate, scoreid, callback)

Example Response

{
    "id": "739ecd39-e1ae-4a0b-b266-dd3ddc616163",
    "create_date": "2018-11-01T00:00:00.000+0000",
    "update_date": "2019-11-01T00:00:00.000+0000",
    "score_type": "risk_score",
    "score_value": "80",
    "client_id": "58f90162-1bd7-4441-a1f2-cbaa4b2e3595",
    "score_time_stamp": "2018-11-01T00:00:00.000+0000",
    "metadata": {
        "questionnaire": "Risk Profile Questionnaire"
    }
}

Update the information for a score. The unique score_id must be provided. To obtain the appropriate score_id, use the GET /score endpoint to view all scores stored for your tenant and their current information. The details to be updated must also be provided. The endpoint returns the score_id and the details for the score.

HTTP REQUEST

PUT /score/{score_id}

Delete a score

Example Request

curl -X DELETE -H "Authorization: Bearer <access_token>" \
    "https://[sandbox][api].hydrogenplatform.com/nucleus/v1/score/739ecd39-e1ae-4a0b-b266-dd3ddc616163"
api_instance = nucleus_api.ScoreApi(nucleus_api.ApiClient(configuration))
# # # # # Delete a Score
score1_id = '90791aa4-0aac-440b-9dd4-9be1a7c40f30'
try:
    api_instance.delete_score_using_delete(score1_id)
except ApiException as e:
    print("Exception when delete_score_using_delete: %s\n" % e)
ScoreApi apiInstance = new ScoreApi();
        //Delete a Score
        try {
            Score deleteresponse = apiInstance.deleteScoreUsingDelete(UUID.fromString("3db4a110-c836-4008-8ce2-bc444f978a61"));
            System.out.println(deleteresponse);
        } catch (ApiException e) {
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\ScoreApi(
    new GuzzleHttp\Client(),
    $config);

//Delete Score
$score_did = "39387086-283f-4c95-949a-fc5968a49c4d"; // string | UUID account_id

try {
    $apiInstance->deleteScoreUsingDelete($score_did);
} catch (Exception $e) {
    echo 'Exception when calling AccountApi->deleteScoreUsingDelete: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::ScoreApi.new
#Delete Score
score1_id = 'c7f100ea-3e16-4646-9c7b-2cc24ca1d6c5'
begin
  result = api_instance.delete_score_using_delete(score1_id)
  p result
rescue NucleusApi::ApiError => e
  puts "Exception when calling ->delete_score_using_delete: #{e}"
end
var apiInstance = new HydrogenNucleusApi.ScoreApi();

// // // //Delete a Score
var scoreidd = "c4b3f7b3-574a-48eb-a4e4-714c4c72edf6";


var deletescore = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully.');
    }
};
apiInstance.deleteScoreUsingDelete(scoreid, deletescore)

Response (204 No Content)

Permanently delete a score. The unique score_id must be provided. To obtain the appropriate score_id, use the GET /score endpoint to view all scores stored for your tenant. This deletes the score_id and all score record information.

HTTP REQUEST

DELETE /score/{score_id}

Resources

Authorities

Authorities are assigned to users when the user is created in the application. These determine which endpoints the user can access application-wide and the data they will be able to view. There are nine Authorities available:

  1. Super Admin: ROLE_SUPER_ADMIN
  2. Admin: ROLE_ADMIN
  3. Portfolio Manager: ROLE_PORTFOLIO_MANAGER
  4. Marketing Manager: ROLE_MARKETING_MANAGER
  5. Operations Agent: ROLE_OPERATIONS
  6. Support Agent: ROLE_SUPPORT
  7. Business Owner: ROLE_BUSINESS_OWNER
  8. Advisor: ROLE_ADVISOR
  9. Client: ROLE_CLIENT

Super Admin

The Super Admin authority represents master control abilities that should be given to only a few individuals or in the case that you do not want to restrict a user’s access to any endpoint. Any users that have the authority of Super Admin will be able to access all endpoints and all data records.

Admin

The Admin authority represents users with an internal control function such as Tech Managers handling maintenance on the platform. These users will have access to all endpoints except for a handful of DELETE endpoints that pertain to sensitive customer information. In particular, only these users, along with Super Admins, will have the ability to create and edit entities relating to the application’s set-up such as transaction codes or account types. They will also be able to view all data records across the platform.

Portfolio Manager

The Portfolio Manager authority represents users managing the firm-wide company investing strategy. They will have access to information around the investments that users have made and how they have been performing. Portfolio Managers will also have the ability to create firm-wide entities such as models and allocations relating to investment strategies. There are no record-level restrictions for Portfolio Managers, so they will be able to view all data records returned from the endpoints to which the Portfolio Manager user has access.

Marketing Manager

The Marketing Manager authority represents users working on communications, marketing, and other related operations. Broadly, they will have the ability to retrieve most data in order to be able to perform demographics analysis and other analyses to help support marketing and communication efforts. They will also have full control of any entities related to marketing and communication functions. There are no record-level restrictions for Marketing Managers, so they will be able to view all data records returned from the endpoints to which the Marketing Manager user has access.

Operations Agent

The Operations Agent authority represents users managing internal operational processes such as trades/order management. Overall, Operations Agents will have access to most endpoints except for DELETE endpoints or endpoints relating to sensitive customer information. There are no record-level restrictions for Operations Agents, so they will be able to view all data records returned from the endpoints to which the Operations Agent user has access.

Support Agent

The Support Agent authority represents users providing customer service. Broadly Support Agents generally do not have the ability to DELETE entities or create and edit firm-wide entities, but they will have access to the majority of other endpoints to address any customer service requests. There are no record-level restrictions for Support Agents, so they will be able to view all data records returned from the endpoints to which the Support Agent user has access.

Business Owner

The Business Owner authority represents users that own a Business entity and have the legal authority to act on behalf of that business. Business Owners will have the same permissions as a ROLE_ADMIN user, but ONLY for users that are associated with their business_id in the Client entity.

Advisor

The Advisor authority represents users that act on behalf of clients and/or help customers manage their account. Overall, Advisors will not have the ability to delete most entities or create certain firm-wide entities, but they will have access to most other endpoints to be able to fully manage clients. Advisors will only have access to data records that are either 1) not client-specific or account-specific or 2) client-specific/account-specific for the clients and accounts to whom they are linked.

Client

The Client authority represents users that are customers with accounts in the application. Overall, Clients will not have the ability to delete most entities or create firm-wide entities, but they will have access to most other endpoints to be able to fully manage their accounts. They are able to delete data records specific to them. Clients will only have access to data records that are either 1) not client-specific or account-specific or 2) client-specific/account-specific for themselves and the accounts to whom they are linked.

Permission Types

Permission Types apply specifically to the ROLE_CLIENT and ROLE_ADVISOR users. Permission Types are assigned to a client-account relationship. A client’s Permission Type for a specific account will control the actions the user can take on the account and the data specific to the account that the user can view. There are four Permission Types available.

  1. Inquiry Access: INQUIRY_ACCESS
  2. Limited Authority: LIMITED_AUTHORITY
  3. Full Authority: FULL_AUTHORITY
  4. Power of Attorney: POWER_OF_ATTORNEY

Please see the Account section for more details on how to manage the Permission Types of clients mapped to an account.

Inquiry Access

Inquiry Access grants access to make inquiries on an account like obtaining balances for individuals performing support functions on the account. Client and/or Advisor users that are mapped to an account with the permission_type of INQUIRY_ACCESS will only be able to use the GET method with endpoints for entities that represent actions at an account-level or below. These users will not have access to the POST, PUT, or DELETE methods for endpoints relating to accounts. In addition, they will only be able to retrieve data for accounts to which they are mapped.

Limited Authority

Limited Authority provides the same access as Inquiry Access with the ability to also make deposits and orders on an account. Client and/or Advisor users that are mapped to an account with the permission_type of LIMITED_AUTHORITY will be able to retrieve data below accounts to which they are mapped as well as create new entities below the accounts, but they will not have the ability to edit or delete account information. In addition, they will not be able to access information for accounts to which they are not mapped.

Full Authority

Full Authority provides the same access as Limited Authority with the ability to make withdrawals/transfer, set restrictions, and make changes to an account. Client and/or Advisor users that are mapped to an account with the permission_type of FULL_AUTHORITY will be able to retrieve data below accounts to which they are mapped as well as create and edit account information and entities below the accounts. They also have the ability to delete some entities or information but not all. In addition, they will not be able to access information for accounts to which they are not mapped.

Power of Attorney

Power of Attorney provides the same access as Full Authority but for individuals that are not the original account owners but have been granted legal control of an account. Client and/or Advisor users that are mapped to an account with the permission_type of POWER_OF_ATTORNEY will be able to retrieve data below accounts to which they are mapped as well as create and edit account information and entities below the accounts. They also have the ability to delete some entities or information but not all. In addition, they will not be able to access information for accounts to which they are not mapped.

Countries

GET /resource/country

api_instance = nucleus_api.ResourceApi(nucleus_api.ApiClient(configuration))
try:
    api_response = api_instance.get_all_country_using_get()
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_all_country_using_get: %s\n" % e)
ResourceApi apiInstance = new ResourceApi();
        try {
            Object country = apiInstance.getAllCountryUsingGet();
            System.out.println(country);
        } catch (ApiException e) {
            System.err.println("Exception when calling getAllCountryUsingGet");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\ResourceApi(
    new GuzzleHttp\Client(),
    $config);
try {
    $countries = $apiInstance->getAllCountryUsingGet();
    print_r($countries);
} catch (Exception $e) {
    echo 'Exception when calling ResourceApi->getAllCountryUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::ResourceApi.new
begin
  country = api_instance.get_all_country_using_get
  p country
rescue NucleusApi::ApiError => e
  puts "Exception when calling ResourceApi->get_all_country_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.ResourceApi();
var country = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};
apiInstance.getAllCountryUsingGet(country)

The following table includes the ISO Alpha-2 country codes that can be passed into endpoints that require a country

Alpha-2 Code Country Latitude Longitude
AD Andorra 42.546245 1.601554
AE United Arab Emirates 23.424076 53.847818
AF Afghanistan 33.93911 67.709953
AG Antigua and Barbuda 17.060816 -61.796428
AI Anguilla 18.220554 -63.068615
AL Albania 41.153332 20.168331
AM Armenia 40.069099 45.038189
AN Netherlands Antilles 12.226079 -69.060087
AO Angola -11.202692 17.873887
AQ Antarctica -75.250973 -0.071389
AR Argentina -38.416097 -63.616672
AS American Samoa -14.270972 -170.132217
AT Austria 47.516231 14.550072
AU Australia -25.274398 133.775136
AW Aruba 12.52111 -69.968338
AZ Azerbaijan 40.143105 47.576927
BA Bosnia and Herzegovina 43.915886 17.679076
BB Barbados 13.193887 -59.543198
BD Bangladesh 23.684994 90.356331
BE Belgium 50.503887 4.469936
BF Burkina Faso 12.238333 -1.561593
BG Bulgaria 42.733883 25.48583
BH Bahrain 25.930414 50.637772
BI Burundi -3.373056 29.918886
BJ Benin 9.30769 2.315834
BM Bermuda 32.321384 -64.75737
BN Brunei 4.535277 114.727669
BO Bolivia -16.290154 -63.588653
BR Brazil -14.235004 -51.92528
BS Bahamas 25.03428 -77.39628
BT Bhutan 27.514162 90.433601
BV Bouvet Island -54.423199 3.413194
BW Botswana -22.328474 24.684866
BY Belarus 53.709807 27.953389
BZ Belize 17.189877 -88.49765
CA Canada 56.130366 -106.346771
CC Cocos Islands -12.164165 96.870956
CD Democratic Republic of the Congo -4.038333 21.758664
CF Central African Republic 6.611111 20.939444
CG The Republic of the Congo -0.228021 15.827659
CH Switzerland 46.818188 8.227512
CI Ivory Coast 7.539989 -5.54708
CK Cook Islands -21.236736 -159.777671
CL Chile -35.675147 -71.542969
CM Cameroon 7.369722 12.354722
CN China 35.86166 104.195397
CO Colombia 4.570868 -74.297333
CR Costa Rica 9.748917 -83.753428
CU Cuba 21.521757 -77.781167
CV Cape Verde 16.002082 -24.013197
CX Christmas Island -10.447525 105.690449
CY Cyprus 35.126413 33.429859
CZ Czech Republic 49.817492 15.472962
DE Germany 51.165691 10.451526
DJ Djibouti 11.825138 42.590275
DK Denmark 56.26392 9.501785
DM Dominica 15.414999 -61.370976
DO Dominican Republic 18.735693 -70.162651
DZ Algeria 28.033886 1.659626
EC Ecuador -1.831239 -78.183406
EE Estonia 58.595272 25.013607
EG Egypt 26.820553 30.802498
EH Western Sahara 24.215527 -12.885834
ER Eritrea 15.179384 39.782334
ES Spain 40.463667 -3.74922
ET Ethiopia 9.145 40.489673
FI Finland 61.92411 25.748151
FJ Fiji -16.578193 179.414413
FK Falkland Islands -51.796253 -59.523613
FM Micronesia 7.425554 150.550812
FO Faroe Islands 61.892635 -6.911806
FR France 46.227638 2.213749
GA Gabon -0.803689 11.609444
GB United Kingdom 55.378051 -3.435973
GD Grenada 12.262776 -61.604171
GE Georgia 42.315407 43.356892
GF French Guiana 3.933889 -53.125782
GG Guernsey 49.465691 -2.585278
GH Ghana 7.946527 -1.023194
GI Gibraltar 36.137741 -5.345374
GL Greenland 71.706936 -42.604303
GM Gambia 13.443182 -15.310139
GN Guinea 9.945587 -9.696645
GP Guadeloupe 16.995971 -62.067641
GQ Equatorial Guinea 1.650801 10.267895
GR Greece 39.074208 21.824312
GS South Georgia and the South Sandwich Islands -54.429579 -36.587909
GT Guatemala 15.783471 -90.230759
GU Guam 13.444304 144.793731
GW Guinea-Bissau 11.803749 -15.180413
GY Guyana 4.860416 -58.93018
HK Hong Kong 22.396428 114.109497
HM Heard Island and McDonald Islands -53.08181 73.504158
HN Honduras 15.199999 -86.241905
HR Croatia 45.1 15.2
HT Haiti 18.971187 -72.285215
HU Hungary 47.162494 19.503304
ID Indonesia -0.789275 113.921327
IE Ireland 53.41291 -8.24389
IL Israel 31.046051 34.851612
IM Isle of Man 54.236107 -4.548056
IN India 20.593684 78.96288
IO British Indian Ocean Territory -6.343194 71.876519
IQ Iraq 33.223191 43.679291
IR Iran 32.427908 53.688046
IS Iceland 64.963051 -19.020835
IT Italy 41.87194 12.56738
JE Jersey 49.214439 -2.13125
JM Jamaica 18.109581 -77.297508
JO Jordan 30.585164 36.238414
JP Japan 36.204824 138.252924
KE Kenya -0.023559 37.906193
KG Kyrgyzstan 41.20438 74.766098
KH Cambodia 12.565679 104.990963
KI Kiribati -3.370417 -168.734039
KM Comoros -11.875001 43.872219
KN Saint Kitts and Nevis 17.357822 -62.782998
KP North Korea 40.339852 127.510093
KR South Korea 35.907757 127.766922
KW Kuwait 29.31166 47.481766
KY Cayman Islands 19.513469 -80.566956
KZ Kazakhstan 48.019573 66.923684
LA Laos 19.85627 102.495496
LB Lebanon 33.854721 35.862285
LC Saint Lucia 13.909444 -60.978893
LI Liechtenstein 47.166 9.555373
LK Sri Lanka 7.873054 80.771797
LR Liberia 6.428055 -9.429499
LS Lesotho -29.609988 28.233608
LT Lithuania 55.169438 23.881275
LU Luxembourg 49.815273 6.129583
LV Latvia 56.879635 24.603189
LY Libya 26.3351 17.228331
MA Morocco 31.791702 -7.09262
MC Monaco 43.750298 7.412841
MD Moldova 47.411631 28.369885
ME Montenegro 42.708678 19.37439
MG Madagascar -18.766947 46.869107
MH Marshall Islands 7.131474 171.184478
MK Macedonia 41.608635 21.745275
ML Mali 17.570692 -3.996166
MM Myanmar 21.913965 95.956223
MN Mongolia 46.862496 103.846656
MO Macau 22.198745 113.543873
MP Northern Mariana Islands 17.33083 145.38469
MQ Martinique 14.641528 -61.024174
MR Mauritania 21.00789 -10.940835
MS Montserrat 16.742498 -62.187366
MT Malta 35.937496 14.375416
MU Mauritius -20.348404 57.552152
MV Maldives 3.202778 73.22068
MW Malawi -13.254308 34.301525
MX Mexico 23.634501 -102.552784
MY Malaysia 4.210484 101.975766
MZ Mozambique -18.665695 35.529562
NA Namibia -22.95764 18.49041
NC New Caledonia -20.904305 165.618042
NE Niger 17.607789 8.081666
NF Norfolk Island -29.040835 167.954712
NG Nigeria 9.081999 8.675277
NI Nicaragua 12.865416 -85.207229
NL Netherlands 52.132633 5.291266
NO Norway 60.472024 8.468946
NP Nepal 28.394857 84.124008
NR Nauru -0.522778 166.931503
NU Niue -19.054445 -169.867233
NZ New Zealand -40.900557 174.885971
OM Oman 21.512583 55.923255
PA Panama 8.537981 -80.782127
PE Peru -9.189967 -75.015152
PF French Polynesia -17.679742 -149.406843
PG Papua New Guinea -6.314993 143.95555
PH Philippines 12.879721 121.774017
PK Pakistan 30.375321 69.345116
PL Poland 51.919438 19.145136
PM Saint Pierre and Miquelon 46.941936 -56.27111
PN Pitcairn Islands -24.703615 -127.439308
PR Puerto Rico 18.220833 -66.590149
PS Palestinian Territories 31.952162 35.233154
PT Portugal 39.399872 -8.224454
PW Palau 7.51498 134.58252
PY Paraguay -23.442503 -58.443832
QA Qatar 25.354826 51.183884
RE Réunion -21.115141 55.536384
RO Romania 45.943161 24.96676
RS Serbia 44.016521 21.005859
RU Russia 61.52401 105.318756
RW Rwanda -1.940278 29.873888
SA Saudi Arabia 23.885942 45.079162
SB Solomon Islands -9.64571 160.156194
SC Seychelles -4.679574 55.491977
SD Sudan 12.862807 30.217636
SE Sweden 60.128161 18.643501
SG Singapore 1.352083 103.819836
SH Saint Helena -24.143474 -10.030696
SI Slovenia 46.151241 14.995463
SJ Svalbard and Jan Mayen 77.553604 23.670272
SK Slovakia 48.669026 19.699024
SL Sierra Leone 8.460555 -11.779889
SM San Marino 43.94236 12.457777
SN Senegal 14.497401 -14.452362
SO Somalia 5.152149 46.199616
SR Suriname 3.919305 -56.027783
ST São Tomé and Príncipe 0.18636 6.613081
SV El Salvador 13.794185 -88.89653
SY Syria 34.802075 38.996815
SZ Swaziland -26.522503 31.465866
TC Turks and Caicos Islands 21.694025 -71.797928
TD Chad 15.454166 18.732207
TF French Southern Territories -49.280366 69.348557
TG Togo 8.619543 0.824782
TH Thailand 15.870032 100.992541
TJ Tajikistan 38.861034 71.276093
TK Tokelau -8.967363 -171.855881
TL Timor-Leste -8.874217 125.727539
TM Turkmenistan 38.969719 59.556278
TN Tunisia 33.886917 9.537499
TO Tonga -21.178986 -175.198242
TR Turkey 38.963745 35.243322
TT Trinidad and Tobago 10.691803 -61.222503
TV Tuvalu -7.109535 177.64933
TW Taiwan 23.69781 120.960515
TZ Tanzania -6.369028 34.888822
UA Ukraine 48.379433 31.16558
UG Uganda 1.373333 32.290275
UM U.S. Minor Outlying Islands 19.2823181 166.647049
US United States 37.09024 -95.712891
UY Uruguay -32.522779 -55.765835
UZ Uzbekistan 41.377491 64.585262
VA Vatican City 41.902916 12.453389
VC Saint Vincent and the Grenadines 12.984305 -61.287228
VE Venezuela 6.42375 -66.58973
VG British Virgin Islands 18.420695 -64.639968
VI U.S. Virgin Islands 18.335765 -64.896335
VN Vietnam 14.058324 108.277199
VU Vanuatu -15.376706 166.959158
WF Wallis and Futuna -13.768752 -177.156097
WS Samoa -13.759029 -172.104629
XK Kosovo 42.602636 20.902977
YE Yemen 15.552727 48.516388
YT Mayotte -12.8275 45.166244
ZA South Africa -30.559482 22.937506
ZM Zambia -13.133897 27.849332
ZW Zimbabwe -19.015438 29.154857

States

GET /resource/state

api_instance = nucleus_api.ResourceApi(nucleus_api.ApiClient(configuration))
try:
    api_response = api_instance.get_all_states_using_get()
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_all_states_using_get: %s\n" % e)
ResourceApi apiInstance = new ResourceApi();
        try {
            Object states = apiInstance.getAllStatesUsingGet(null);
            System.out.println(states);
        } catch (ApiException e) {
            System.err.println("Exception when calling getAllStatesUsingGet");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\ResourceApi(
    new GuzzleHttp\Client(),
    $config);
$country_code = "US"; // string | country_code

try {
    $states = $apiInstance->getAllStatesUsingGet($country_code);
    print_r($states);
} catch (Exception $e) {
    echo 'Exception when calling ResourceApi->getAllStatesUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::ResourceApi.new
opts = {
    country_code: 'US' # String | country_code
}

begin
  states = api_instance.get_all_states_using_get(opts)
  p states
rescue NucleusApi::ApiError => e
  puts "Exception when calling ResourceApi->get_all_states_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.ResourceApi();
var opts = {
    'countryCode': "US" // String | country_code
};

var states = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};

apiInstance.getAllStatesUsingGet(opts, states)

ARGUMENTS

Parameter Type Required Description
country_code string optional Alpha-2 country code where state is located

The following table includes states that can be pulled in to populate a dropdown on a frontend application

Country Code Abbreviation State
US AK Alaska
US AL Alabama
US AR Arkansas
US AZ Arizona
US CA California
US CO Colorado
US CT Connecticut
US DC District of Columbia
US DE Delaware
US FL Florida
US GA Georgia
US HI Hawaii
US IA Iowa
US ID Idaho
US IL Illinois
US IN Indiana
US KS Kansas
US KY Kentucky
US LA Louisiana
US MA Massachusetts
US MD Maryland
US ME Maine
US MI Michigan
US MN Minnesota
US MO Missouri
US MS Mississippi
US MT Montana
US NC North Carolina
US ND North Dakota
US NE Nebraska
US NH New Hampshire
US NJ New Jersey
US NM New Mexico
US NV Nevada
US NY New York
US OH Ohio
US OK Oklahoma
US OR Oregon
US PA Pennsylvania
US RI Rhode Island
US SC South Carolina
US TN Tennessee
US TX Texas
US UT Utah
US VA Virginia
US VT Vermont
US WA Washington
US WI Wisconsin
US WV West Virginia
US WY Wyoming

Currencies

GET /resource/currency

api_instance = nucleus_api.ResourceApi(nucleus_api.ApiClient(configuration))
try:
    api_response = api_instance.get_all_currency_using_get()
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_all_country_using_get: %s\n" % e)
ResourceApi apiInstance = new ResourceApi();
        try {
            Object currency = apiInstance.getAllCurrencyUsingGet();
            System.out.println(currency);
        } catch (ApiException e) {
            System.err.println("Exception when calling getAllCurrencyUsingGet");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\ResourceApi(
    new GuzzleHttp\Client(),
    $config);
try {
    $currencies = $apiInstance->getAllCurrencyUsingGet();
    print_r($currencies);
} catch (Exception $e) {
    echo 'Exception when calling ResourceApi->getAllCurrencyUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::ResourceApi.new
begin
  currency = api_instance.get_all_currency_using_get
  p currency
rescue NucleusApi::ApiError => e
  puts "Exception when calling ResourceApi->get_all_currency_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.ResourceApi();
var currency = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};

apiInstance.getAllCurrencyUsingGet(currency)

The following table includes the ISO 4217 currency codes that can be passed into endpoints that require a currency_code

Alphabetic Code Currency Numeric Code
AED UAE Dirham 784
AFN Afghan Afghani 971
ALL Albanian Lek 008
AMD Armenian Dram 051
ANG Netherlands Antillean Guilder 532
AOA Angolan Kwanza 973
ARS Argentine Peso 032
AUD Australian Dollar 036
AWG Aruban Florin 533
AZN Azerbaijan Manat 944
BAM Convertible Mark 977
BBD Barbados Dollar 052
BDT Bangladeshi Taka 050
BGN Bulgarian Lev 975
BHD Bahraini Dinar 048
BIF Burundi Franc 108
BMD Bermudian Dollar 060
BND Brunei Dollar 096
BOB Bolivian Boliviano 068
BOV Bolivian Mvdol 984
BRL Brazilian Real 986
BSD Bahamian Dollar 044
BTN Bhutanese Ngultrum 064
BWP Botswanan Pula 072
BYN Belarusian Ruble 933
BZD Belize Dollar 084
CAD Canadian Dollar 124
CDF Congolese Franc 976
CHE WIR Eur 947
CHF Swiss Franc 756
CHW WIR Franc 948
CLF Chilean Unidad de Fomento 990
CLP Chilean Peso 152
CNY Yuan Renminbi 156
COP Colombian Peso 170
COU Colombian Unidad de Valor Real 970
CRC Costa Rican Colon 188
CUC Cuban Peso Convertible 931
CUP Cuban Peso 192
CVE Cabo Verde Escudo 132
CZK Czech Koruna 203
DJF Djibouti Franc 262
DKK Danish Krone 208
DOP Dominican Peso 214
DZD Algerian Dinar 012
EGP Egyptian Pound 818
ERN Eritrean Nakfa 232
ETB Ethiopian Birr 230
EUR Euro 978
FJD Fiji Dollar 242
FKP Falkland Islands Pound 238
GBP Pound Sterling 826
GEL Georgian Lari 981
GHS Ghana Cedi 936
GIP Gibraltar Pound 292
GMD Gambian Dalasi 270
GNF Guinean Franc 324
GTQ Guatemalan Quetzal 320
GYD Guyana Dollar 328
HKD Hong Kong Dollar 344
HNL Honduran Lempir 340
HRK Croatian Kuna 191
HTG Haitian Gourde 332
HUF Hungarian Forint 348
IDR Indonesian Rupiah 360
ILS New Israeli Sheqel 376
INR Indian Rupee 356
IQD Iraqi Dinar 368
IRR Iranian Rial 364
ISK Iceland Krona 352
JMD Jamaican Dollar 388
JOD Jordanian Dinar 400
JPY Japanese Yen 392
KES Kenyan Shilling 404
KGS Kyrgyzstani Som 417
KHR Cambodian Riel 116
KMF Comorian Franc 174
KPW North Korean Won 408
KRW Korean Won 410
KWD Kuwaiti Dinar 414
KYD Cayman Islands Dollar 136
KZT Kazakhstani Tenge 398
LAK Lao Kip 418
LBP Lebanese Pound 422
LKR Sri Lanka Rupee 144
LRD Liberian Dollar 430
LSL Lesotho Loti 426
LYD Libyan Dinar 434
MAD Moroccan Dirham 504
MDL Moldovan Leu 498
MGA Malagasy Ariary 969
MKD Macedonian Denar 807
MMK Myanmar Kyat 104
MNT Mongolian Tugrik 496
MOP Macanese Pataca 446
MRU Mauritanian Ouguiya 929
MUR Mauritius Rupee 480
MVR Maldivian Rufiyaa 462
MWK Malawi Kwacha 454
MXN Mexican Peso 484
MXV Mexican Unidad de Inversion (UDI) 979
MYR Malaysian Ringgit 458
MZN Mozambique Metical 943
NAD Namibia Dollar 516
NGN Nigerian Naira 566
NIO Nicaraguan Cordoba Oro 558
NOK Norwegian Krone 578
NPR Nepalese Rupee 524
NZD New Zealand Dollar 554
OMR Omani Rial 512
PAB Panamanian Balboa 590
PEN Peruvian Sol 604
PGK Papua New Guinean Kina 598
PHP Philippine Peso 608
PKR Pakistan Rupee 586
PLN Polish Zloty 985
PYG Paraguayan Guarani 600
QAR Qatari Rial 634
RON Romanian Leu 946
RSD Serbian Dinar 941
RUB Russian Ruble 643
RWF Rwanda Franc 646
SAR Saudi Riyal 682
SBD Solomon Islands Dollar 090
SCR Seychelles Rupee 690
SDG Sudanese Pound 938
SEK Swedish Krona 752
SGD Singapore Dollar 702
SHP Saint Helena Pound 654
SLL Sierra Leonean Leone 694
SOS Somali Shilling 706
SRD Surinam Dollar 968
SSP South Sudanese Pound 728
STN Sao Tomean Dobra 930
SVC El Salvador Colon 222
SYP Syrian Pound 760
SZL Lilangeni 748
THB Thai Baht 764
TJS Tajikistani Somoni 972
TMT Turkmenistan New Manat 934
TND Tunisian Dinar 788
TOP Tongan Pa’anga 776
TRY Turkish Lira 949
TTD Trinidad and Tobago Dollar 780
TWD New Taiwan Dollar 901
TZS Tanzanian Shilling 834
UAH Ukrainian Hryvnia 980
UGX Uganda Shilling 800
USD US Dollar 840
UYI Uruguay Peso en Unidades Indexadas (UI) 940
UYU Uruguay Peso Uruguayo 858
UYW Uruguay Unidad Previsional 927
UZS Uzbekistan Sum 860
VES Venezuelan Bolívar Soberano 928
VND Vietnamese Dong 704
VUV Vanuatu Vatu 548
WST Samoan Tala 882
XAF CFA Franc BEAC 950
XAG Silver 961
XAU Gold 959
XCD East Caribbean Dollar 951
XOF CFA Franc BCEAO 952
XPD Palladium 964
XPF CFP Franc 953
XPT Platinum 962
XSU Sucre 994
XUA ADB Unit of Account 965
YER Yemeni Rial 886
ZAR South African Rand 710
ZMW Zambian Kwacha 967
ZWL Zimbabwe Dollar 932

FX Rates

GET /resource/fx_rate

api_instance = nucleus_api.ResourceApi(nucleus_api.ApiClient(configuration))
try:
    api_response = api_instance.get_currency_exchange_rate_all_using_get()
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_currency_exchange_rate_all_using_get: %s\n" % e)
ResourceApi apiInstance = new ResourceApi();
        try {
            Object fxrate = apiInstance.getCurrencyExchangeRateAllUsingGet(null);
            System.out.println(fxrate);
        } catch (ApiException e) {
            System.err.println("Exception when calling getCurrencyExchangeRateAllUsingGet");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\ResourceApi(
    new GuzzleHttp\Client(),
    $config);
$filter = null; // string | filter

try {
    $Fxrate = $apiInstance->getCurrencyExchangeRateAllUsingGet($filter);
    print_r($Fxrate);
} catch (Exception $e) {
    echo 'Exception when calling ResourceApi->getCurrencyExchangeRateAllUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::ResourceApi.new
fx_rate_list = [NucleusApi::FxRate.new] # Array<FxRate> | fxRateList


begin
  fxrate = api_instance.create_fx_rate_bulk_using_post(fx_rate_list)
  p fxrate
rescue NucleusApi::ApiError => e
  puts "Exception when calling ResourceApi->create_fx_rate_bulk_using_post: #{e}"
end
var apiInstance = new HydrogenNucleusApi.ResourceApi();
var opts = {
    'filter': null, // String | filter
};

var fxrate = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};

apiInstance.getCurrencyExchangeRateAllUsingGet(opts, fxrate)

Retrieve FX rates for currency pairs supported by Hydrogen. An automatic conversion will take place when the currency_conversion parameter is passed to applicable GET services. This service is for reference only.

ARGUMENTS

Parameter Type Required Description
currency_code_from string optional ISO 4217 currency code for the currency you wish to convert from. Value may be one of: AED, ARS, AUD, BRL, CAD, CHF, CLP, CNY, COP, CZK, DKK, EUR, GBP, HKD, HRK, HUF, IDR, ILS, INR, ISK, JPY, KRW, KWD, MAD, MXN, MYR, NOK, NZD, PEN, PHP, PLN, RON, RUB, SEK, SGD, THB, TRY, TWD, USD, ZAR
currency_code_to string optional ISO 4217 currency code for the currency you wish to convert to. Value may be one of: USD, CAD, EUR, GBP, AUD, CHF
exchange_rate double optional Rate that you may exchange the currency_code_from into the currency_code_to. For instance, an exchange rate of 1.2 from EURO to USD, means you will receive 1.2 Dollars for every Euro you exchange.
date date optional Date that you wish to retrieve the rate for. If no date is entered, then all dates will be returned for the pair. Rates are updated every 6 hours.

*Please note, we do not currently support the following currency pairs: CZKUSD, CZKAUD, DKKCAD, DKKGBP, DKKAUD

Account Categories

GET /resource/account_category

api_instance = nucleus_api.ResourceApi(nucleus_api.ApiClient(configuration))
# List all AccountCategory
try:
    api_response = api_instance.get_account_result_for_mapping()
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_account_result_for_mapping: %s\n" % e)
ResourceApi apiInstance = new ResourceApi();
        //List all Account Category
        try {
            Object accountcategory = apiInstance.getAccountResultForMapping(null, null, null);
            System.out.println(accountcategory);
        } catch (ApiException e) {
            System.err.println("Exception when calling getAccountResultForMapping");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\ResourceApi(
    new GuzzleHttp\Client(),
    $config);
//List all Account Category
try {
    $account_category = $apiInstance->getAccountResultForMapping();
    print_r($account_category);
} catch (Exception $e) {
    echo 'Exception when calling ResourceApi->getAllCountryUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::ResourceApi.new
#List all AccountCategory
begin
  accountcategory = api_instance.get_account_result_for_mapping
  p accountcategory
rescue NucleusApi::ApiError => e
  puts "Exception when calling ResourceApi->get_account_result_for_mapping: #{e}"
end
var apiInstance = new HydrogenNucleusApi.ResourceApi();
// //List all Account Category
var opts = {
    'ascending': false, // Boolean | ascending
    // 'filter': "", // String | filter
    'orderBy': "update_date", // String | order_by
    'page': 0, // Number | page
    'size': 25 // Number | size
};
var accountcategory = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};

apiInstance.getAccountResultForMapping(opts, accountcategory)

Retrieve a list of account categories, which are used in aggregation account records.

RESPONSE

Field Type Description
id UUID The ID of the account category record
category string The name of the category for this account category record
subcategory string The name of the subcategory for this account category record
is_asset boolean Indicates if the account category represents an asset. A value of true indicates that it represents an asset
is_liability boolean Indicates if the account category represents a liability. A value of true indicates that it represents a liability
is_short_term boolean Indicates if the account category represents a short term liability. A value of true indicates that it represents a short term liability
is_long_term boolean Indicates if the account category represents a long term liablity. A value of true indicates that it represents a long term liability
is_cash boolean Indicates if the account category represents cash. A value of true indicates that it represents cash
is_investment boolean Indicates if the account category represents an investment. A value of true indicates that it represents an investment
is_business boolean Indicates if the account category represents a business account. A value of true indicates that it represents a business account
is_investable_cash boolean Indicates if the account category represents investable cash. A value of true indicates that it represents investable cash
is_mortgage boolean Indicates if the account category represents a mortgage. A value of true indicates that it represents a mortgage
is_retirement boolean Indicates if the account category represents a retirement account. A value of true indicates that it represents a retirement account
is_liquid boolean Indicates if the account category represents a liquid asset. A value of true indicates that it represents a liquid asset

Transaction Categories

GET /resource/transaction_category

api_instance = nucleus_api.ResourceApi(nucleus_api.ApiClient(configuration))
# List all Transaction Category
try:
    api_response = api_instance.get_transaction_result_for_mapping()
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_transaction_result_for_mapping: %s\n" % e)
ResourceApi apiInstance = new ResourceApi();
         //List all Transaction Category
         try {
             Object trasactioncategory = apiInstance.getTransactionResultForMapping(null, null, null);
             System.out.println(trasactioncategory);
         } catch (ApiException e) {
             System.err.println("Exception when calling getTransactionResultForMapping");
             e.printStackTrace();
         }
$apiInstance = new com\hydrogen\nucleus\Api\ResourceApi(
    new GuzzleHttp\Client(),
    $config);
//List all TransactionCategory
try {
    $transaction_category = $apiInstance->getTransactionResultForMapping();
    print_r($transaction_category);
} catch (Exception $e) {
    echo 'Exception when calling ResourceApi->getInstitutionUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::ResourceApi.new

#List all TransactionCategory
begin
  tcategory = api_instance.get_transaction_result_for_mapping
  p tcategory
rescue NucleusApi::ApiError => e
  puts "Exception when calling ResourceApi->get_transaction_result_for_mapping: #{e}"
end
var apiInstance = new HydrogenNucleusApi.ResourceApi();
// //List all Transaction Category
var opts = {
    'ascending': false, // Boolean | ascending
    //'filter': "null", // String | filter
    'orderBy': "update_date", // String | order_by
    'page': 0, // Number | page
    'size': 25 // Number | size
};
var transactioncategory = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};

apiInstance.getTransactionCodeAllUsingGet(opts, transactioncategory)

Retrieve a list of transaction categories, which are used in all cards, banking, and aggregation transaction records.

RESPONSE

Field Type Description
id UUID The ID of the transaction category record
category string The name of the category for this transaction category record
subcategory string The name of the subcategory for this transaction category record. A value of null indicates that this record is a primary transaction category record, representing all records that have the same category value but different subcategory values
is_fee boolean Indicates if the transaction category represents a fee. A value of true indicates that it represents a fee
is_transfer boolean Indicates if the transaction category represents a transfer. A value of true indicates that it represents a transfer
is_subscription boolean Indicates if the transaction category represents a subscription. A value of true indicates that it represents a subscription
is_housing_cost boolean Indicates if the transaction category represents a housing cost. A value of true indicates that it represents a housing cost
is_utility_payment boolean Indicates if the transaction category represents a utility payment. A value of true indicates that it represents a utility payment
is_telecom_payment boolean Indicates if the transaction category represents a telecom payment. A value of true indicates that it represents a telecom payment
is_insurance_payment boolean Indicates if the transaction category represents an insurance payment. A value of true indicates that it represents an insurance payment
is_debt_payment boolean Indicates if the transaction category represents a debt payment. A value of true indicates that it represents a debt payment
is_transportation_cost boolean Indicates if the transaction category represents a transportation cost. A value of true indicates that it represents a transportation cost
is_food_cost boolean Indicates if the transaction category represents a food cost. A value of true indicates that it represents a food cost
is_living_expense boolean Indicates if the transaction category represents a living expense. A value of true indicates that it represents a living expense
hydrogen_transaction_category_id UUID For tenants using custom labels, indicates the ID of the default Hydrogen transaction category record that was duplicated and then edited to have the custom category and/or subcategory shown in this record. Will be the same as the id for all records if custom labels are not being utilized by the tenant, indicating that the records are default Hydrogen transaction categories

Institutions

GET /resource/institution

api_instance = nucleus_api.ResourceApi(nucleus_api.ApiClient(configuration))
# List all Institution
try:
    api_response = api_instance.get_institution_all_using_get()
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_institution_all_using_get: %s\n" % e)
ResourceApi apiInstance = new ResourceApi();
//        //List all Institution
//        try {
//            Object institution = apiInstance.getInstitutionAllUsingGet(true, null, null, 0, 10);
//            System.out.println(institution);
//        } catch (ApiException e) {
//            System.err.println("Exception when calling getInstitutionAllUsingGet");
//            e.printStackTrace();
//        }
$apiInstance = new com\hydrogen\nucleus\Api\ResourceApi(
    new GuzzleHttp\Client(),
    $config);
//List all Institution
try {
    $institution = $apiInstance->getInstitutionAllUsingGet();
    print_r($institution);
} catch (Exception $e) {
    echo 'Exception when calling ResourceApi->getInstitutionAllUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::ResourceApi.new

#List all Institution
begin
  institution = api_instance.get_institution_all_using_get
  p institution
rescue NucleusApi::ApiError => e
  puts "Exception when calling ResourceApi->get_institution_all_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.ResourceApi();
//List all Institution
var opts = {
    'ascending': false, // Boolean | ascending
    // 'filter': "", // String | filter
    'orderBy': "update_date", // String | order_by
    'page': 0, // Number | page
    'size': 25 // Number | size
};
var institution = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};

apiInstance.getInstitutionAllUsingGet(opts, institution)

Example Response

{
    "content": [
        {
            "id": "9d8da50c-9700-459f-926d-0d1cf1304935",
            "code": "td_bank",
            "name": "TD Bank USA",
            "logo_url_small": "https://content.moneydesktop.com/storage/MD_Assets/Ipad%20Logos/50x50/default_50x50.png",
            "logo_url_medium": "https://content.moneydesktop.com/storage/MD_Assets/Ipad%20Logos/100x100/default_100x100.png",
            "website_url": "http://www.tdbank.com/",
            "create_date": "2018-09-17T19:13:53.000+0000",
            "update_date": "2019-10-28T21:05:54.000+0000"
        }
    ],
    "first": true,
    "last": true,
    "totalPages": 1,
    "totalElements": 1,
    "sort": [
        {
            "property": "id",
            "direction": "DESC",
            "ignoreCase": false,
            "nullHandling": "NATIVE"
        }
    ],
    "numberOfElements": 1,
    "size": 25,
    "number": 0
  }

Retrieve a cleansed institution list and their metadata. These institutions are used in all bank links, cards, and aggregation accounts, and are cleansed to common values, to provide an enhanced user experience.

RESPONSE

Field Type Description
id string Unique id that identifies the institution
code string Unique code that identifies the institution
name string Name of the institution such as “Chase”
logo_url_small string URL path for the small logo of the institution such as https://domain.com/logo.png
logo_url_medium string URL path for the medium logo of the institution such as https://domain.com/logo.png
website_url string URL path for the website of the institution such as https://domain.com
create_date timestamp Timestamp for the date and time that the record was created
update_date timestamp Timestamp for the date and time that the record was last updated

Merchants

GET /resource/merchant

api_instance = nucleus_api.ResourceApi(nucleus_api.ApiClient(configuration))
# List all Merchnats
try:
    api_response = api_instance.get_merchants_all_using_get()
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_merchants_all_using_get: %s\n" % e)
ResourceApi apiInstance = new ResourceApi();
        //List all Merchant
        try {
            Object merchant = apiInstance.getMerchantsAllUsingGet(true, null, null, 0, 10);
            System.out.println(merchant);
        } catch (ApiException e) {
            System.err.println("Exception when calling getMerchantsAllUsingGet");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\ResourceApi(
    new GuzzleHttp\Client(),
    $config);
//List all Merchant
try {
    $merchant = $apiInstance->getMerchantsAllUsingGet();
    print_r($merchant);
} catch (Exception $e) {
    echo 'Exception when calling ResourceApi->getInstitutionUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::ResourceApi.new


#List all Merchant
begin
  merchant = api_instance.get_merchants_all_using_get
  p merchant
rescue NucleusApi::ApiError => e
  puts "Exception when calling ResourceApi->get_merchants_all_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.ResourceApi();
// //List all Merchant
var opts = {
    'ascending': false, // Boolean | ascending
    //'filter': "null", // String | filter
    'orderBy': "update_date", // String | order_by
    'page': 0, // Number | page
    'size': 25 // Number | size
};
var merchant = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};

apiInstance.getMerchantsAllUsingGet(opts, merchant)

Example Response

{
    "content": [
        {
            "id": "9d8da50c-9700-459f-926d-0d1cf1304935",
            "logo_url": "https://content.mx.com/logos/merchants/MCH-ad6d3405-ec03-721d-b0ca-eeceeebcb8b5.png",
            "name": "1-800 Contacts",
            "website_url": "https://www.1800contacts.com",
            "create_date": "2018-09-17T19:13:53.000+0000",
            "update_date": "2019-10-28T21:05:54.000+0000"
        }
    ],
    "first": true,
    "last": true,
    "totalPages": 1,
    "totalElements": 1,
    "sort": [
        {
            "property": "id",
            "direction": "DESC",
            "ignoreCase": false,
            "nullHandling": "NATIVE"
        }
    ],
    "numberOfElements": 1,
    "size": 25,
    "number": 0
  }

Retrieve a cleansed merchant list and their metadata. These merchants are used in all cards, banking, and aggregation transactions, and are cleansed to common values so they can be utilized in spending controls and budgets.

RESPONSE

Field Type Description
id UUID The unique id of the merchant within Hydrogen
name string Name of the merchant such as “Starbucks”
logo_url string URL path for the logo of the merchant such as https://domain.com/logo.png
website_url string URL path for the website of the merchant such as https://domain.com
create_date timestamp Timestamp for the date and time that the record was created
update_date timestamp Timestamp for the date and time that the record was last updated

Merchant Category Codes

GET /resource/merchant_category_code

api_instance = nucleus_api.ResourceApi(nucleus_api.ApiClient(configuration))
try:
    api_response = api_instance.get_all_merchant_category_code_using_get()
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_all_merchant_category_code_using_get: %s\n" % e)
ResourceApi apiInstance = new ResourceApi();
        try {
            Object merchantCode = apiInstance.getAllMerchantCategoryCodeUsingGet();
            System.out.println(merchantCode);
        } catch (ApiException e) {
            System.err.println("Exception when calling getAllMerchantCategoryCodeUsingGet");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\ResourceApi(
    new GuzzleHttp\Client(),
    $config);
try {
    $merchantcode = $apiInstance->getAllMerchantCategoryCodeUsingGet();
    print_r($merchantcode);
} catch (Exception $e) {
    echo 'Exception when calling ResourceApi->getAllMerchantCategoryCodeUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::ResourceApi.new
begin
  merchantcode = api_instance.get_all_merchant_category_code_using_get
  p merchantcode
rescue NucleusApi::ApiError => e
  puts "Exception when calling ResourceApi->get_all_merchant_category_code_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.ResourceApi();
var merchantcode = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};

apiInstance.getAllMerchantCategoryCodeUsingGet(merchantcode)

Retrieve integer Merchant Category Codes (MCC) and their descriptions. These codes are used to identify merchant types by the card networks.

ARGUMENTS

Parameter Type Required Description
mcc integer optional Identifier of the Merchant Category Code (MCC)
category string optional Merchant category assigned to the MCC, used to organize large groups of MCCs such as airlines and hotels
subcategory string optional Merchant subcategory assigned under the category to the MCC

RESPONSE

Field Type Description
mcc integer Identifier of the Merchant Category Code (MCC)
description string Description of the MCC such as the industry of the merchant
category string Merchant category assigned to the MCC, used to organize large groups of MCCs such as airlines and hotels
subcategory string Merchant subcategory assigned under the category to the MCC

Statistics

The following tables include all of the parameters that can be passed into the performance endpoints as a stat

GET /resource/statistic

api_instance = nucleus_api.ResourceApi(nucleus_api.ApiClient(configuration))
try:
    api_response = api_instance.get_all_statistics_using_get()
    pprint(api_response)
except ApiException as e:
    print("Exception when calling get_all_statistics_using_get: %s\n" % e)
ResourceApi apiInstance = new ResourceApi();
        try {
            Object statistics = apiInstance.getAllStatisticsUsingGet();
            System.out.println(statistics);
        } catch (ApiException e) {
            System.err.println("Exception when calling getAllStatisticsUsingGet");
            e.printStackTrace();
        }
$apiInstance = new com\hydrogen\nucleus\Api\ResourceApi(
    new GuzzleHttp\Client(),
    $config);
try {
    $statistics = $apiInstance->getAllStatisticsUsingGet();
    print_r($statistics);
} catch (Exception $e) {
    echo 'Exception when calling ResourceApi->getAllStatisticsUsingGet: ', $e->getMessage(), PHP_EOL;
}
api_instance = NucleusApi::ResourceApi.new
begin
  statistics = api_instance.get_all_statistics_using_get
  p statistics
rescue NucleusApi::ApiError => e
  puts "Exception when calling ResourceApi->get_all_statistics_using_get: #{e}"
end
var apiInstance = new HydrogenNucleusApi.ResourceApi();
var statistics = function(error, data, response) {
    if (error) {
        console.error(error);
    } else {
        console.log('API called successfully. Returned data: ' +JSON.stringify(data, null, '\t') + '\n');
    }
};

apiInstance.getAllStatisticsUsingGet(statistics)

PERFORMANCE

Parameter Stat Name Type Description
cum_return Cumulative Return point-in-time Total percentage growth since inception
ann_return Annualized Return point-in-time Compounded percentage growth over a 1-year period
daily_return Daily Return time-series Price at time ‘t’ compared with the price at EOD ‘t-1’
mtd_return Month-to-Date Return time-series Price at time ‘t’ compared with the price at EOD on the last day of the previous month
ytd_return Year-to-Date Return time-series Price at time ‘t’ compared with the price at EOD on the last day of the previous year
rolling_n_day_return Rolling n-Day Return time-series Price at time ‘t’ compared with the price at EOD ‘t-n’
calendar_monthly_return Calendar Monthly Return time-series Price at EOD on the last day of the month compared against the price at end-of-day EOD on the last day of the previous month
calendar_quarterly_return Calendar Quarterly Return time-series Price at EOD on the last day of the quarter compared against the price at EOD on the last day of the previous quarter
calendar_yearly_return Calendar Yearly Return time-series Price at EOD December 31 of this year compared against the price at EOD December 31 the previous year
one_yr_return One Year Return time-series Price at time ‘t’ compared with the price at EOD same day, 1 year ago
three_yr_return Three Year Return time-series Price at time ‘t’ compared with the price at EOD same day, 3 years ago
five_yr_return Five Year Return time-series Price at time ‘t’ compared with the price at EOD same day, 5 years ago
seven_yr_return Seven Year Return time-series Price at time ‘t’ compared with the price at EOD same day, 7 years ago
ten_yr_return Ten Year Return time-series Price at time ‘t’ compared with the price at EOD same day, 10 years ago
best_month Best Month Return point-in-time Highest 1-month return
worst_month Worst Month Return point-in-time Lowest 1-month return
best_yr Best Year Return point-in-time Highest 1-year return
worst_yr Worst year Return point-in-time Lowest 1-year return
best_qtr Best Quarter Return point-in-time Highest 3-month return
worst_qtr Worst Quarter Return point-in-time Lowest 3-month return
avg_return Average Return point-in-time Average performance during a specified time period
avg_gain Average Gain point-in-time Average positive return during a specified time period
avg_loss Average Loss point-in-time Average negative return during a specified time period
alpha Alpha point-in-time Excess return relative to benchmark
active_premium Active Premium point-in-time Annualized return excess of benchmark annualized return
tracking_error Tracking Error point-in-time Difference between the price of a position and the price of the benchmark it was meant to track
moving_avg_n_day Moving Average n-Day time-series Average price over n-days
dollar_growth Growth of $1 time-series Growth in value of $1 invested in security or portfolio
total_earnings Total Earnings point-in-time Total dollar amount earned during time period

RISK

Parameter Stat Name Type Description
ann_vol Annualized Volatility/Standard Deviation point-in-time Variance of returns from the mean for a year
daily_vol Daily Volatility/Standard Deviation point-in-time Variance of the daily returns from the mean for the time period
rolling_n_day_vol Rolling n-Day Volatility/Standard Deviation time-series Variance of returns from the mean for n-days
downside_deviation Downside Deviation point-in-time Downside risk exceeding a minimum threshold
semi_deviation Semi Deviation point-in-time Standard deviation of returns lower than mean return
beta Beta point-in-time Volatility of returns relative to market as a whole
correlation Correlation point-in-time Strength of relationship between two securities
covariance Covariance point-in-time Direction of relationship between two securities
r_squared R-squared point-in-time Percentage of returns attributable to a benchmark
drawdown Drawdown time-series Percentage peak-to-trough decline during specified time period
max_drawdown Maximum Drawdown point-in-time Maximum percentage peak-to-trough decline during specified time period
rolling_n_day_max_drawdown Rolling n-Day Maximum Drawdown time-series Percentage peak-to-trough decline for n-days during specified time period
upside_risk Upside Risk point-in-time Volatility of returns during winning periods
downside_risk Downside Risk point-in-time Volatility of returns during losing periods
current_drawdown Current Drawdown point-in-time Current peak-to-trough decline since inception
var VAR (Value at Risk) point-in-time Maximum possible loss during a specific time frame based on a confidence interval

RATIOS

Parameter Stat Name Type Description
sharpe_ratio Sharpe Ratio point-in-time Risk-adjusted return (using standard deviation)
treynor_ratio Treynor Ratio point-in-time Risk-adjusted return (using beta)
sortino_ratio Sortino Ratio point-in-time Downside risk-adjusted return
up_capture Up Capture point-in-time Percentage of positive market returns captured
down_capture Down Capture point-in-time Percentage of negative market returns captured
information_ratio Information Ratio point-in-time Risk-adjusted return (using tracking error)
calmar_ratio Calmar Ratio point-in-time Risk-adjusted return for the previous 3 years (using drawdowns)
pct_gain_ratio Percentage Gain Ratio point-in-time Periods in which security return exceeded positive benchmark returns
pct_loss_ratio Percentage Loss Ratio point-in-time Periods in which security return exceeded negative benchmark returns
gain_loss_ratio Gain Loss Ratio point-in-time Number of instances positive returns exceeded negative returns
profit_loss_ratio Profit Loss Ratio point-in-time Average gains compared to average losses
up_pct_ratio Up Percentage Ratio point-in-time Ratio of periods return exceeded positive benchmark returns to periods of positive benchmark return
down_pct_ratio Down Percentage Ratio point-in-time Ratio of periods return exceeded negative benchmark returns to periods of negative benchmark return
sterling_ratio Sterling Ratio point-in-time Risk-adjusted return for the previous 3 years (assuming max drawdowns will be exceeded)

DISTRIBUTIONS

Parameter Stat Name Type Description
skewness Skewness time-series Asymmetry of return distribution
kurtosis Kurtosis time-series Distribution of returns around the mean
monte_carlo Monte Carlo time-series Probability of a portfolio achieving a certain outcome
histogram Histogram time-series Distribution of data over a continuous interval or certain time period
tstat T-Statistic time-series Departure of estimated value from its hypothesized value