Skip to main content

Standards

Requests​

The below information is required on all requests.

Headers​

Headers required on all requests to Hammer API.

ParameterRequiredDescription
AuthorizationTrueBearer token generated for the Identity endpoint
Ocp-Apim-Subscription-KeyTrueAPI Subscription key provided by StoneX

Responses​

This API suite will return a standardized response for all Endpoints containing the below information.

Success Response​

Data returned to a successful API call.

NameData TypeDefinition
StatusCodeIntegerHTTP status code
MessageStringBrief message about the status of the request
DataObjectThe data returned from the API
ErrorsArray of ErrorsError Object
TraceIdStringId for each API transaction that can be used for tracking & debugging
HasErrorsBooleanIndicates if there are errors related to the request

Error Response​

Data returned to a unsuccessful API call.

NameData TypeDefinition
StatusCodeIntegerHTTP status code
MessageStringBrief message about the status of the request
TraceIdStringId for each API transaction that can be used for tracking & debugging
ErrorsArray of ErrorsError Object
HasErrorsBooleanIndicates if there are errors related to the request

Error Object​

NameData TypeDefinition
CodeStringStoneX Error code
FieldStringField name from the request that caused the error
ReasonStringDescription of the issue

Standard Errors​

CodeReason
ERR.1000Field Can Not Be Empty
ERR.4000Backend error

Standard Data Format​

Date Format​

AttributesData TypeLengthDescription
birthDateString10yyyy-MM-dd

Update Requests​

Clients can make updates or changes in following ways:

Updates in Single Attributes​

Value in a single attribute can be updated and can be deleted using the* sign.

Updating an attribute
{
"accountNumber": "87654321",
"subNumber": "252",
"main": {
"repCode": "JC01"
},
"PrimaryOwner": {
"name1": "John",
"name2": "David",
"name3": "Doe",
"name4": "JR"
}
}
Deleting an attribute value
{
"accountNumber": "87654321",
"subNumber":"252",
"main": {
"repCode": "JC01"
},
"PrimaryOwner": {
"name4": "*"
}
}

Updates in Arrays​

1. Array with Identifiers​

The specific values sent will be updated within the object containing the identifier.

{
"associatedParties": [
{
"customerId": "321658432136584634",
"role": "secondary",
"name1": "John"
},

{
"customerId": "465846984321635413",
"role": "secondary",
"name1": "Kelly"
}
]
}

Updates the specific one value in the array

{
"associatedParties": [
{
"customerId": "465846984321635413",
"role": "secondary",
"name1": "Kelly"
}
]
}
delete

An identifier must be used to remove an entire data block of a "key-value" pair from the object, and also, the"delete" = "True" needs to be used to complete the deleting process.

2. Array without Identifiers​

Array value will be replaced with the new array provided in the request.

Array Object
{
"caisCustomerType": ["ACC", "ONB"]
}