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.
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:
- Client Credentials
- 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 theaccess_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 theaccess_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 theaccess_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:
- 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/
- Store the private key that is created in your application securely
- 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
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:
- Strings: PUT the field to
null
- Arrays: Put the array to
[]
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:
- Account: GET /account/{account_id}/asset_size, GET /account/{account_id}/holding, GET /account/{account_id}/transaction
- Client: GET /client/{client_id}/asset_size, GET /client/{client_id}/holding, GET /client/{client_id}/transaction
- Goal: GET /goal/{goal_id}/asset_size, GET /goal/{goal_id}/holding, GET /goal/{goal_id}/transaction
- Card: GET /card/{card_id}/asset_size, GET /card/{card_id}/transaction
- Household: GET /household/{household_id}/asset_size, GET /household/{household_id}/holding, GET /household/{household_id}/transaction
- Portfolio: GET /portfolio_asset_size, GET /portfolio_asset_size/{portfolio_asset_size_id}, GET /portfolio_transaction, GET /portfolio_transaction/{portfolio_transaction_id}, GET /portfolio_holding, GET /portfolio_holding/{portfolio_holding_id}
- Funding: GET /funding, GET /funding/{funding_id}, GET /bank_link, GET /bank_link/{bank_link_id}, GET /deposit, GET /deposit/{deposit_id}, GET /withdrawal, GET /withdrawal/{withdrawal_id}, GET /transfer, GET /transfer/{transfer_id}
- Model: GET /model_asset_size, GET /model_asset_size/{model_asset_size_id}
- Security: GET /security_price, GET /security_price/{security_price_id}
- Aggregation Account: GET /aggregation_account_balance, GET /aggregation_account_balance/{aggregation_account_balance_id}, GET /aggregation_account_transaction, GET /aggregation_account_transaction/{aggregation_account_transaction_id}, GET /aggregation_account_holding, GET /aggregation_account_holding/{aggregation_account_holding_id}, GET /client/{client_id}/aggregation_account_overview, GET /aggregation_account/{aggregation_account_id}/aggregate_data
- Budget: GET /budget, GET /budget/{budget_id}
- Customer: GET /customer_revenue, GET /customer_revenue/{customer_revenue_id}
- Invoice: GET /invoice, GET /invoice/{invoice_id}, GET /invoice_payment, GET /invoice_payment/{invoice_payment_id}
- Financial Statement: GET /financial_statement, GET /financial_statement/{financial_statement_id}
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:
- Adding new API resources.
- Adding new optional request parameters to existing API methods.
- Adding new fields to existing API responses.
- Changing the order of fields in existing API responses.
- Changing the length or format of objects
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:
- Client demographic data
- Data labels for frontend UI
- Internal IDs
- Associated images
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 thesignature
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_id
s 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_id
s 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_id
s 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_id
s 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_id
s registered with your tenant. The endpoint returns a list of security_id
s, 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_id
s registered with your tenant. The endpoint returns a list of transaction_id
s 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_id
s 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_id
s 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_id
s registered with your tenant. The endpoint returns a list of security_id
s, 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_id
s registered with your tenant. The endpoint returns a list of transaction_id
s 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 Link
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 |
List all bank links
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
Create a 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 |
Retrieve a bank link
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}
Update a bank link
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}
Delete a bank link
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) {