Skip to main content

Heron Data API (2021-07-19)

Download OpenAPI specification:Download

EnrichmentFeedback

Bulk create category feedback

Provide bulk feedback on Transaction Categories

Authorizations:
BasicAuth
Request Body schema: application/json

A list of objects containing a Transaction's heron id and the suggested Category. If you provide a heron_id for Category, you don't need to provide other fields. If heron_id is provided, we disregard label.

Array
object (CategoryFeedback)
source
string or null <= 120 characters
Default: null

your identifier for where the feedback comes from e.g. bob_the_underwriter

transaction_heron_id
required
string

heron id of transaction

Responses

Request samples

Content type
application/json
[
  • {
    }
]

Response samples

Content type
application/json
{
  • "num_annotations": 1
}

Create category, merchant feedback

Provide feedback on a Transaction's Categories and Merchants

Authorizations:
BasicAuth
path Parameters
heron_id
required
string

Transaction heron_id

Request Body schema: application/json

A partial Transaction object with the suggested Category and/or Merchant. If you provide a heron_id for Category or Merchant, you don't need to provide other fields. If you don't know the Merchant heron_id nor name, you can just send the is_correct boolean. If heron_id is provided, we disregard name and label. If is_correct is set to true, we disregard all other Merchant fields.

object (TransactionFeedbackSchema)
object
Default: {}
object
Default: {}
source
string or null <= 120 characters
Default: null

your identifier for where the feedback comes from e.g. bob_the_underwriter

Responses

Request samples

Content type
application/json
{
  • "transaction": {
    }
}

Categories

Get categories

Get available categories

Authorizations:
BasicAuth

Responses

Response samples

Content type
application/json
{
  • "categories": [
    ]
}

CrmIntegrations

List CRM Integrations

Get a list of CRM Integrations

Authorizations:
BasicAuth

Responses

Response samples

Content type
application/json
{
  • "crm_integrations": [
    ]
}

Create a CRM integration

Create a CRM integration, e.g., with Salesforce

Authorizations:
BasicAuth
Request Body schema: application/json
auth
required
object

Authentication details for the CRM integration

required
object

The configuration for the CRM integration

instance_url
required
string <url>

Base URL of the CRM integration

is_enabled
boolean
Default: true

Whether the integration is enabled

is_live
boolean
Default: true

Whether the integration is live

provider
required
string
Enum: "salesforce" "lendsmart" "orgmeter" "centrex" "lendsaas"

The CRM provider

secret
required
string

A secret key for the CRM integration

property name*
additional property
any

Responses

Request samples

Content type
application/json
{
  • "auth": { },
  • "config": {
    },
  • "is_enabled": true,
  • "is_live": true,
  • "provider": "salesforce",
  • "secret": "string"
}

Response samples

Content type
application/json
{
  • "crm_integration": {
    }
}

Patch a CRM integration

patch a CRM integration

Authorizations:
BasicAuth
path Parameters
heron_id
required
string
Request Body schema: application/json
auth
object

Authentication details for the CRM integration

object

The configuration for the CRM integration

instance_url
string <url>

Base URL of the CRM integration

is_enabled
boolean
Default: true

Whether the integration is enabled

is_live
boolean
Default: true

Whether the integration is live

provider
string
Enum: "salesforce" "lendsmart" "orgmeter" "centrex" "lendsaas"

The CRM provider

secret
string

A secret key for the CRM integration

property name*
additional property
any

Responses

Request samples

Content type
application/json
{
  • "auth": { },
  • "config": {
    },
  • "is_enabled": true,
  • "is_live": true,
  • "provider": "salesforce",
  • "secret": "string"
}

Response samples

Content type
application/json
{
  • "config": {
    },
  • "heron_id": "string",
  • "is_enabled": true,
  • "is_live": true,
  • "provider": "salesforce"
}

EndUserDataSourceAccounts

Update a data source account

Update a data source account

Authorizations:
BasicAuth
path Parameters
heron_id
required
string
Request Body schema: application/json
is_enabled
boolean

Whether or not the account is enabled. If disabled, hides related transactions from analytics

Responses

Request samples

Content type
application/json
{
  • "is_enabled": true
}

Response samples

Content type
application/json
{
  • "account_id": "202348",
  • "anomaly_score": 200,
  • "balances": [
    ],
  • "currency": "USD",
  • "end_date": "2022-01-31",
  • "heron_id": "dso_VeP5gv7NCbyhzvTJwyKhJ7",
  • "institution_name": "Chase",
  • "is_enabled": true,
  • "max_date": "2022-01-31",
  • "min_date": "2022-01-01",
  • "name": "Checking Account",
  • "num_transactions": 120,
  • "number": "123456789",
  • "owner_name": "John Doe",
  • "reference_id": "account-202348",
  • "start_date": "2022-01-01",
  • "transactions_match_balances": true,
  • "type": "Checking"
}

EndUserDataSources

Update a data source

Update a data source

Authorizations:
BasicAuth
path Parameters
heron_id
required
string
Request Body schema: application/json
is_enabled
boolean
Default: true

Whether or not the data source is enabled. If disabled, hides related transactions from analytics

Responses

Request samples

Content type
application/json
{
  • "is_enabled": true
}

Response samples

Content type
application/json
{
  • "created": "2024-03-27T05:02:45.455455",
  • "data_source_accounts": [
    ],
  • "heron_id": "dso_fW8tWjKmTgCujq3vbJWJKj",
  • "is_enabled": true,
  • "last_updated": "2024-05-08T05:02:45.455483",
  • "metadata": {
    },
  • "reference_id": "pdf_5kxpBU6LLApNmLGDDSfU7z",
  • "status": "new",
  • "type": "pdf"
}

Get data source account summary

Get a list of data sources accounts & their summarised information for a company

Authorizations:
BasicAuth
path Parameters
end_user_id_or_heron_id
required
string

Responses

Response samples

Content type
application/json
[
  • {
    }
]

Get data sources

Get a list of data sources for a company

Authorizations:
BasicAuth
path Parameters
end_user_id_or_heron_id
required
string

Responses

Response samples

Content type
application/json
[
  • {
    }
]

EmailTemplates

Get email templates

Read all available templates

Authorizations:
BasicAuth

Responses

Response samples

Content type
application/json
{
  • "rules": [
    ]
}

Create an email template

Create an email template used to send emails conditional on events like policy evaluation

Authorizations:
BasicAuth
Request Body schema: application/json
html_body
required
string

The body of the email to send.

name
required
string [ 3 .. 50 ] characters ^[a-zA-Z0-9_-]+$

Unique name of the email template. Used to match which email template to send. Only alphanumeric characters, underscores, and dashes are allowed.

to_address
string or null <email>
Default: null

The email address to send the email to

property name*
additional property
any

Responses

Request samples

Content type
application/json
{
  • "html_body": "string",
  • "name": "string",
  • "to_address": null
}

Response samples

Content type
application/json
{
  • "email_template": {
    }
}

Patch an email template

Update an email template

Authorizations:
BasicAuth
path Parameters
heron_id
required
string
Request Body schema: application/json
html_body
string

The body of the email to send.

name
string [ 3 .. 50 ] characters ^[a-zA-Z0-9_-]+$

Unique name of the email template. Used to match which email template to send. Only alphanumeric characters, underscores, and dashes are allowed.

to_address
string or null <email>
Default: null

The email address to send the email to

property name*
additional property
any

Responses

Request samples

Content type
application/json
{
  • "html_body": "string",
  • "name": "string",
  • "to_address": null
}

Response samples

Content type
application/json
{
  • "email_template": {
    }
}

EndUserEmails

Export an end user email as an EML file

Export an end user email as an EML file. Attachments are not included.

Authorizations:
BasicAuth
path Parameters
heron_id
required
string

The heron_id of the email to export

Responses

EndUserFiles

Update the end user file's class

Use this endpoint to change the end user file's class. The file will be reprocessed as the new type.

Authorizations:
BasicAuth
path Parameters
heron_id
required
string
Request Body schema: application/json
file_class
string
Enum: "other" "iso_application_form" "bank_statement" "debt_summary" "email"
reference_id
string

Responses

Request samples

Content type
application/json
{
  • "file_class": "other",
  • "reference_id": "string"
}

Response samples

Content type
application/json
{
  • "bank_statement": null,
  • "created": "2019-08-24T14:15:22Z",
  • "file_class": "other",
  • "filename": "string",
  • "heron_id": "string",
  • "iso_application": {
    },
  • "reference_id": "string"
}

Get EndUserFile as a base64 string

Get the base64 string representation of an end user file

Authorizations:
BasicAuth
path Parameters
heron_id
required
string

The heron_id of the end user file

Responses

Response samples

Content type
application/json
{
  • "file_b64": "string"
}

Get EndUserFiles

Get all files for an end user

Authorizations:
BasicAuth
path Parameters
end_user_id_or_heron_id
required
string

Responses

Response samples

Content type
application/json
[
  • {
    }
]

Post EndUserFile

Upload file to an end user & asynchronously classify its type

Authorizations:
BasicAuth
path Parameters
end_user_id_or_heron_id
required
string
Request Body schema: application/json
file_base64
required
string
filename
required
string
reference_id
string or null

Responses

Request samples

Content type
application/json
{
  • "file_base64": "string",
  • "filename": "string",
  • "reference_id": "string"
}

Download EndUserFiles

Download all files for an end user as a zip

Authorizations:
BasicAuth
path Parameters
end_user_id_or_heron_id
required
string

Responses

EndUsers

List EndUsers

Get a list of EndUsers

Authorizations:
BasicAuth
query Parameters
name
string or null
Default: null
Example: name=your_end_user_name

Filter by name associated with end user

page
integer >= 1
Default: 1

Pagination page number

include_data_sources
boolean
Default: false
Example: include_data_sources=true

Whether the to include data sources for each end user

heron_id
string or null
Default: null
Example: heron_id=eus_hNMsr2itu9gigQKcWzFUjQ

Unique ID generated by Heron

limit
integer [ 1 .. 10000 ]
Default: 1000

Pagination limit per page

order_by
string
Default: "last_updated_desc"
Enum: "last_updated_desc" "last_updated_asc" "created_desc" "created_asc"

Order to return end users by

is_portfolio
boolean or null
Default: null
Example: is_portfolio=true

Whether the end user is part of a lending portfolio

include_scorecard_metrics
boolean
Default: false
Example: include_scorecard_metrics=true

Whether to include scorecard metrics for each end user (under field criteria)

status
string or null
Default: null
Enum: "new" "ready" "processed" "reviewed" "review_requested" "failed"
Example: status=reviewed

Filter by status of end user

end_user_id
string or null
Default: null
Example: end_user_id=your_end_user_id

Filter by ID associated with end_user_id field in transactions

Responses

Response samples

Content type
application/json
{
  • "_meta": {
    },
  • "end_users": [
    ]
}

Create EndUser

Create a new end user. If transactions have previously been sent for this end_user_id, use PUT end_users to update instead.

Authorizations:
BasicAuth
Request Body schema: application/json
object (EndUserPostParams)
end_user_id
required
string <= 140 characters

id defined by user; links to the end_user_id for transactions

is_portfolio
boolean

Whether the end user is part of a lending portfolio

name
string or null <= 128 characters

Name of end user; may help to improve categorisation accuracy

profit_and_loss_layout
any or null

Responses

Request samples

Content type
application/json
{
  • "end_user": {
    }
}

Response samples

Content type
application/json
{
  • "end_user": {
    }
}

Update EndUser

Confirm an end user is ready for async procesing by sending a status of "ready". The end_user_id must have previously been sent with at least one Transaction.

Authorizations:
BasicAuth
Request Body schema: application/json

Dictionary representing an EndUser

object (EndUser)
end_user_id
required
string <= 140 characters

id defined by user; links to the end_user_id for transactions

is_portfolio
boolean

Whether the end user is part of a lending portfolio

name
string or null <= 128 characters

Name of end user; may help to improve categorisation accuracy

profit_and_loss_layout
any or null
status
string
Enum: "new" "ready" "processed" "reviewed" "review_requested" "failed"

Status of end user; 'ready' triggers async processing, 'review_requested' triggers manual review request

Responses

Callbacks

Request samples

Content type
application/json
{
  • "end_user": {
    }
}

Response samples

Content type
application/json
{
  • "end_user": {
    }
}

Callback payload samples

Callback
POST: $yourWebhookUrl
Content type
application/json
{
  • "created": "2019-08-24T14:15:22Z",
  • "data": {
    },
  • "meta": { },
  • "topic": "string"
}

Delete EndUser by heron_id or end_user_id

Delete an end user. You must delete associated transactions before doing this.

Authorizations:
BasicAuth
path Parameters
end_user_id_or_heron_id
required
string

Responses

Get EndUser by heron_id or end_user_id

Get an end user using its end_user_id or heron_id

Authorizations:
BasicAuth
path Parameters
end_user_id_or_heron_id
required
string

Responses

Response samples

Content type
application/json
{
  • "end_user": {
    }
}

Get EndUser emails

Get the emails associated with an end user

Authorizations:
BasicAuth
path Parameters
end_user_id_or_heron_id
required
string

Responses

Response samples

Content type
application/json
[
  • {
    }
]

Get EndUser information

Get the company details of an end user including loan information

Authorizations:
BasicAuth
path Parameters
end_user_id_or_heron_id
required
string

Responses

Response samples

Content type
application/json
{
  • "amount_requested": 0,
  • "annual_revenue": 0,
  • "business_start_date": "2019-08-24",
  • "company_billing_address": {
    },
  • "company_email": "string",
  • "company_legal_business_name": "string",
  • "company_phone_number": "string",
  • "company_physical_address": {
    },
  • "company_website": "string",
  • "dba": "string",
  • "federal_tax_id": "string",
  • "industry_type": "string",
  • "loan_purpose": "string",
  • "monthly_revenue": 0,
  • "naics": "string",
  • "owner_1": {
    },
  • "owner_2": {
    },
  • "predicted_industry_probability": 0,
  • "source_type": "iso_application_form",
  • "state_of_incorporation": "string",
  • "type_of_business_entity": "string"
}

Patch EndUser information

Update the end user information

Authorizations:
BasicAuth
path Parameters
end_user_id_or_heron_id
required
string
Request Body schema: application/json
amount_requested
number
annual_revenue
number
business_start_date
string <date>
object (Address)
company_email
string
company_legal_business_name
string
company_phone_number
string
object (Address)
company_website
string
dba
string

Doing business as

federal_tax_id
string
industry_type
string
loan_purpose
string
monthly_revenue
number
naics
string
object (Owner)
object (Owner)
predicted_industry_probability
number
source_type
string
Enum: "api" "iso_application_form" "heron_industry_classifier" "rel6_industry_classifier"

Source of the end user information

state_of_incorporation
string
type_of_business_entity
string

Responses

Request samples

Content type
application/json
{
  • "amount_requested": 0,
  • "annual_revenue": 0,
  • "business_start_date": "2019-08-24",
  • "company_billing_address": {
    },
  • "company_email": "string",
  • "company_legal_business_name": "string",
  • "company_phone_number": "string",
  • "company_physical_address": {
    },
  • "company_website": "string",
  • "dba": "string",
  • "federal_tax_id": "string",
  • "industry_type": "string",
  • "loan_purpose": "string",
  • "monthly_revenue": 0,
  • "naics": "string",
  • "owner_1": {
    },
  • "owner_2": {
    },
  • "predicted_industry_probability": 0,
  • "source_type": "iso_application_form",
  • "state_of_incorporation": "string",
  • "type_of_business_entity": "string"
}

Response samples

Content type
application/json
{
  • "amount_requested": 0,
  • "annual_revenue": 0,
  • "business_start_date": "2019-08-24",
  • "company_billing_address": {
    },
  • "company_email": "string",
  • "company_legal_business_name": "string",
  • "company_phone_number": "string",
  • "company_physical_address": {
    },
  • "company_website": "string",
  • "dba": "string",
  • "federal_tax_id": "string",
  • "industry_type": "string",
  • "loan_purpose": "string",
  • "monthly_revenue": 0,
  • "naics": "string",
  • "owner_1": {
    },
  • "owner_2": {
    },
  • "predicted_industry_probability": 0,
  • "source_type": "iso_application_form",
  • "state_of_incorporation": "string",
  • "type_of_business_entity": "string"
}

Enrich transactions of EndUser

Enriches transactions of an end user identified by its end_user_id or heron_id. There is an optional priority parameter that can be set to high to prioritize the enrichment over normal (default) priority. High priority enrichment is only enabled for enterprise-level accounts. Please contact support@herondata.io to upgrade your account.

Authorizations:
BasicAuth
path Parameters
end_user_id_or_heron_id
required
string
query Parameters
priority
string
Default: "normal"
Enum: "normal" "high"

Priority for async enrichment

Responses

Response samples

Content type
application/json
{
  • "end_user": {
    }
}

EndUserCalculations

Get EndUser balance

Get balance for given EndUser on a daily and account granularity

Authorizations:
BasicAuth
query Parameters
date_max
string or null <date>
Default: null
Example: date_max=2024-05-07

Filter for transactions with date earlier than the input value (inclusive). It has precedence over timestamp_max

date_min
string or null <date>
Default: null
Example: date_min=2024-05-08

Filter for transactions with timestamp after the input value (inclusive). It has precedence over timestamp_min

to_currency
string or null
Enum: "GBP" "USD" "EUR"
Example: to_currency=USD

ISO 4217 currency code to convert to

timestamp_min
string or null <date-time>
Default: null
Example: timestamp_min=2024-05-08T05:02:44.525179

Deprecated (use date_min instead). Filter for transactions with timestamp after the input value

timestamp_max
string or null <date-time>
Default: null
Example: timestamp_max=2024-05-07T05:02:44.525229

Deprecated (use date_max instead). Filter for transactions with timestamp earlier than the input value

end_user_heron_id
string or null
Default: null
Example: end_user_heron_id=eus_QGRTsXcMjn7GuwtzSpkGPY

Heron-generated id for end user; either end_user_id or end_user_heron_id is required

end_user_id
string or null
Default: null
Example: end_user_id=your_end_user_id

end_user_id for statistics; either end_user_id or end_user_heron_id is required

include_forecast
boolean
Default: false

If true, forecasts the balances of each account

Responses

Response samples

Content type
application/json
{
  • "daily_balances": [
    ],
  • "forecasted": [
    ],
  • "summary": {
    }
}

Get EndUser forecasts

Get forecast amounts for a given EndUser and category

Authorizations:
BasicAuth
query Parameters
category_label
string
Example: category_label=Revenue

Label of category to be forecasted; either category_heron_id or category_label must be present

date_granularity
string
Default: "month"
Enum: "week" "month"
Example: date_granularity=month

Aggregate results over time, i.e., aggregate by week or by month

to_date
string or null <date>
Default: null
Example: to_date=2022-01-31

The latest transaction timestamp date to use in forecasting

category_heron_id
string
Example: category_heron_id=ctg_GQrwZPoufy6vdYYnzxZEDe

Heron ID of category to be forecasted; either category_heron_id or category_label must be present

from_date
string or null <date>
Default: null
Example: from_date=2022-01-01

The earliest transaction timestamp date to use in forecasting

to_currency
string or null
Enum: "GBP" "USD" "EUR"
Example: to_currency=USD

ISO 4217 currency code to convert to

end_user_heron_id
string or null
Default: null
Example: end_user_heron_id=eus_QGRTsXcMjn7GuwtzSpkGPY

Heron-generated id for end user; either end_user_id or end_user_heron_id is required

end_user_id
string or null
Default: null
Example: end_user_id=your_end_user_id

end_user_id for statistics; either end_user_id or end_user_heron_id is required

Responses

Response samples

Content type
application/json
[
  • {
    }
]

Get EndUser statistics

Get summarized statistics for a given EndUser

Authorizations:
BasicAuth
query Parameters
group_by
string
Default: "category"
Enum: "category" "merchant"
Example: group_by=category

Pivot results by merchant or by category

merchant_heron_ids
Array of strings
Default: []
Example: merchant_heron_ids=mrc_bH3x5cLvcH9JrPke8noKUC&merchant_heron_ids=mrc_huwS7A67YKJPZ6hSBYV9pv

Filter by specific merchants

date_granularity
string
Default: "month"
Enum: "day" "week" "month" "quarter" "year"
Example: date_granularity=month

Aggregate results over time, e.g., by week or by quarter

to_date
string or null <date>
Default: null
Example: to_date=2024-05-07

Filter for transactions with timestamp before the input value (as date)

from_date
string or null <date>
Default: null
Example: from_date=2024-05-08

Filter for transactions with timestamp after the input value (as date)

to_currency
string or null
Enum: "GBP" "USD" "EUR"
Example: to_currency=USD

ISO 4217 currency code to convert to

category_heron_ids
Array of strings
Default: []
Example: category_heron_ids=ctg_Eigb73yc2vh7eKfqV3YLTc&category_heron_ids=ctg_cjhJop5FPv78NS7m42nH8K

Filter by specific categories

end_user_heron_id
string or null
Default: null
Example: end_user_heron_id=eus_QGRTsXcMjn7GuwtzSpkGPY

Heron-generated id for end user; either end_user_id or end_user_heron_id is required

end_user_id
string or null
Default: null
Example: end_user_id=your_end_user_id

end_user_id for statistics; either end_user_id or end_user_heron_id is required

Responses

Response samples

Content type
application/json
{
  • "statistics": [
    ]
}

Get EndUser anomalies

Get anomalies for given EndUser given a category label or heron id

Authorizations:
BasicAuth
path Parameters
end_user_id_or_heron_id
required
string

The end_user_id or heron_id of EndUser to upload

query Parameters
category_label_or_heron_id
required
string
Example: category_label_or_heron_id=Revenue

Label or Heron ID of category to find anomalies for

Responses

Response samples

Content type
application/json
[
  • {
    }
]

Get EndUser bank statement summary

Get the bank statement summary by month for an end user

Authorizations:
BasicAuth
path Parameters
end_user_id_or_heron_id
required
string
query Parameters
grouping
string
Default: "by_month"
Enum: "by_month" "by_data_source_account_heron_id" "rolling_30_days_from_last_txn" "rolling_30_days_from_today"

Determines how to group transactions. It supports calendar month (by_month) or rolling 30-day period (from last txns with rolling_30_days_from_last_txn or from today with rolling_30_days_from_today)

Responses

Response samples

Content type
application/json
{
  • "average": {
    },
  • "by_data_source_account_heron_id": {
    },
  • "by_month": {
    },
  • "grouping": "string",
  • "rolling_30_days_from_last_txn": {
    },
  • "rolling_30_days_from_today": {
    },
  • "total": {
    }
}

Get EndUser metric benchmarks

Get the benchmarks for each metric for an end user

Authorizations:
BasicAuth
path Parameters
end_user_id_or_heron_id
required
string

Responses

Response samples

Content type
application/json
{
  • "benchmarks": [
    ]
}

Export as a spreadsheet

Export a spreadsheet for an end user containing key metrics and reports

Authorizations:
BasicAuth
path Parameters
end_user_id_or_heron_id
required
string

Responses

Get EndUser Heron Score (beta)

Get Heron Score for end user with a breakdown of the feature group contributions which resulted in the score. The score is calculated for the day of last transaction. This is a beta feature and is subject to change.

Authorizations:
BasicAuth
path Parameters
end_user_id_or_heron_id
required
string
query Parameters
date
string or null <date>
Default: null
Example: date=2023-01-19

Cut-off date to consider transactions to for calculating heron score (inclusive)

min_category_confidence
number or null
Default: null
Example: min_category_confidence=0.8

Minimum company categorisation confidence to calculate Heron Score

Responses

Response samples

Content type
application/json
{
  • "data_quality_issues": [
    ],
  • "feature_groups_contributions": {
    },
  • "predicted_at": "2019-08-24T14:15:22Z",
  • "reference_timestamp": "2019-08-24T14:15:22Z",
  • "status": "not_available",
  • "value": 0
}

Get EndUser industry

Predict the industry of the end user based on its name

Authorizations:
BasicAuth
path Parameters
end_user_id_or_heron_id
required
string

The end_user_id or heron_id of EndUser

query Parameters
naics_code_min_digits
integer [ 2 .. 6 ]
Example: naics_code_min_digits=2

Minimum number of digits in NAICS code

naics_code_max_digits
integer [ 2 .. 6 ]
Example: naics_code_max_digits=6

Maximum number of digits in NAICS code

Responses

Response samples

Content type
application/json
{
  • "label": "Fruit and Vegetable Preserving and Specialty Food Manufacturing",
  • "probability": 0.42,
  • "taxonomy": "naics",
  • "taxonomy_value": "3114"
}

Get EndUser merchant summary

Get the summary of transactions by merchant for an end user for a given category

Authorizations:
BasicAuth
path Parameters
end_user_id_or_heron_id
required
string
query Parameters
category_label_or_heron_id
required
Array of strings non-empty

Responses

Response samples

Content type
application/json
{
  • "by_merchant_summary": [
    ]
}

Get EndUser named dates

Get the named dates associated with an end user, e.g., date of last transaction

Authorizations:
BasicAuth
path Parameters
end_user_id_or_heron_id
required
string

Responses

Response samples

Content type
application/json
{
  • "named_dates": [
    ]
}

Get EndUser P&L

Calculates the profit & loss table for an end user, based on the layout defined (if any)

Authorizations:
BasicAuth
path Parameters
end_user_id_or_heron_id
required
string
query Parameters
to_date
string or null <date>
Default: null
Example: to_date=2022-01-31

The latest transaction timestamp date to use

currency
string or null = 3 characters
Example: currency=USD

ISO 4217 currency code for balance

from_date
string or null <date>
Default: null
Example: from_date=2022-01-01

The earliest transaction timestamp date to use

dates_ascending
boolean
Default: false

If true, dates are sorted left to right by ascending order. False by default, i.e., by default sorted in descending date order so more recent dates are first

Responses

Response samples

Content type
application/json
{
  • "dates": [
    ],
  • "sections": [
    ]
}

Update EndUser P&L layout

Update the profit and loss layout for the end user, which determines how the profit and loss table is calculated

Authorizations:
BasicAuth
path Parameters
end_user_id_or_heron_id
required
string
Request Body schema: application/json
category_labels
required
Array of strings non-empty

List of category labels to assign to a different section

section_slug
required
string

Slug of section to assign labels to

Responses

Request samples

Content type
application/json
{
  • "category_labels": [
    ],
  • "section_slug": "operational_expenses"
}

Response samples

Content type
application/json
{
  • "sections": [
    ]
}

Get EndUser scorecard

Get scorecard metrics and rule violations for a user

Authorizations:
BasicAuth
path Parameters
end_user_id_or_heron_id
required
string
query Parameters
date
string or null <date>
Default: null
Example: date=2023-01-19

Cut-off date to consider transactions to for calculating scorecard (inclusive)

named_date
string or null
Default: null
Enum: "end_user_created" "end_user_last_updated" "last_transaction" "end_user_last_enriched" "last_data_source_end_date_or_transaction_timestamp"
Example: named_date=end_user_created

Qualitative description for date to calculate scorecard

Responses

Response samples

Content type
application/json
{
  • "metrics": [
    ],
  • "rule_violations": [
    ]
}

EndUserRules

Evaluate all rules for an end user

Authorizations:
BasicAuth
path Parameters
end_user_id_or_heron_id
required
string

Responses

Response samples

Content type
application/json
[
  • {
    }
]

EndUserIntegrations

Upload Inscribe

Upload Inscribe JSON for a specified end user to translate into Heron Data format and add transactions for the end user

Authorizations:
BasicAuth
path Parameters
end_user_id_or_heron_id
required
string

The end_user_id or heron_id of EndUser to upload

Request Body schema: application/json
customer_name
string or null
Default: null
object (InscribeParsedDetails)

Responses

Request samples

Content type
application/json
{
  • "customer_name": null,
  • "parsed_details": {
    }
}

Response samples

Content type
application/json
{
  • "_summary": {
    }
}

Get Integration Links

Get a list of integration links for a specified end user

Authorizations:
BasicAuth
path Parameters
end_user_id_or_heron_id
required
string

The end_user_id or heron_id of EndUser

Responses

Response samples

Content type
application/json
{
  • "links": [
    ]
}

Upload Ocrolus

Upload Ocrolus JSON for a specified end user to translate into Heron Data format and add transactions for the end user

Authorizations:
BasicAuth
path Parameters
end_user_id_or_heron_id
required
string

The end_user_id or heron_id of EndUser to upload

Request Body schema: application/json
required
object (OcrolusResponse)
required
Array of objects (OcrolusBankAccount)
name
required
string

Responses

Request samples

Content type
application/json
{
  • "response": {
    }
}

Response samples

Content type
application/json
{
  • "_summary": {
    }
}

Get PDFs

Get list of PDFs for a specified end user

Authorizations:
BasicAuth
path Parameters
end_user_id_or_heron_id
required
string

The end_user_id or heron_id of EndUser to upload

query Parameters
with_processed_results
boolean

Include processed results where applicable per pdf

Responses

Response samples

Content type
application/json
{
  • "pdfs": [
    ]
}

Parse all PDF

Starts parsing all PDFs for a specified end users. This will not restart any PDFs that are already being parsed

Authorizations:
BasicAuth
path Parameters
end_user_id_or_heron_id
required
string

The end_user_id or heron_id of EndUser to upload

Responses

Response samples

Content type
application/json
{
  • "pdf_heron_ids": [
    ],
  • "request_id": "string"
}

Upload PDF

Upload encoded PDF of transactions for a specified end user to translate into Heron Data format

Authorizations:
BasicAuth
path Parameters
end_user_id_or_heron_id
required
string

The end_user_id or heron_id of EndUser to upload

Request Body schema: application/json
account_id
string or null
Default: null

Unique ID for account associated with PDF

currency
string or null
Default: null
Enum: "USD" "GBP"

ISO 4217 currency code for transactions in account. We currently only support GBP and USD PDFs

filename
string or null
Default: null

The filename of the PDF

pdf_base64
required
string^data\:\w+\/\w+\;base64\,

The base64 encoded string of the PDF file. If using Javascript, this is directly the output of the FileReader.readAsDataURL() output. See https://developer.mozilla.org/en-US/docs/Web/API/FileReader/readAsDataURL for more info

read_us_dates
boolean or null
Default: null

True if date formats in the statement are US: month/date/year

reference_id
string or null <= 140 characters
Default: null

An optional field for your unique identifier for the PDF

with_fraud
boolean or null
Default: null

True if fraud detection should be enabled for this PDF

Responses

Request samples

Content type
application/json
{
  • "account_id": "checking_account_202348",
  • "currency": "USD",
  • "filename": "my-favourite.pdf",
  • "pdf_base64": "string",
  • "read_us_dates": null,
  • "reference_id": "my-favourite-pdf",
  • "with_fraud": null
}

Response samples

Content type
application/json
{
  • "pdf_heron_id": "string",
  • "request_id": "string"
}

Upload Plaid assets

Upload Plaid asset JSON for a specified end user to translate into Heron Data format and add transactions for the end user

Authorizations:
BasicAuth
path Parameters
end_user_id_or_heron_id
required
string

The end_user_id or heron_id of EndUser to upload

Request Body schema: application/json
required
object (PlaidAssetReport)
date_generated
required
string <date-time>
days_requested
required
integer
required
Array of objects (PlaidAssetReportItem)

Responses

Request samples

Content type
application/json
{
  • "report": {
    }
}

Response samples

Content type
application/json
{
  • "_summary": {
    }
}

Upload Plaid transactions

Upload Plaid transactions JSON for a specified end user to translate into Heron Data format and add transactions for the end user

Authorizations:
BasicAuth
path Parameters
end_user_id_or_heron_id
required
string

The end_user_id or heron_id of EndUser to upload

Request Body schema: application/json
Array of objects (PlaidAccountSnapshot)
required
Array of objects (PlaidTransaction)

Responses

Request samples

Content type
application/json
{
  • "accounts": [
    ],
  • "transactions": [
    ]
}

Response samples

Content type
application/json
{
  • "_summary": {
    }
}

Upload Yodlee

Upload Yodlee JSON files for a specified end user to translate into Heron Data format and add transactions for the end user

Authorizations:
BasicAuth
path Parameters
end_user_id_or_heron_id
required
string

The end_user_id or heron_id of EndUser to upload

Request Body schema: application/json
Array of objects (YodleeAccount)
Array of objects (YodleeTransaction)

Responses

Request samples

Content type
application/json
{
  • "accounts": [
    ],
  • "transactions": [
    ]
}

Response samples

Content type
application/json
{
  • "_summary": {
    }
}

Update PDF attributes including status

Update PDF attributes including status

Authorizations:
BasicAuth
path Parameters
heron_id
required
string

heron_id of the pdf

Request Body schema: application/json
filename
string

The filename of the PDF

fraud_reason
string or null

If fraud reason

is_fraud
boolean

True if fraud was detected in the PDF

notes
string

Notes associated with PDF, e.g., rejected reason, failed reason

reference_id
string <= 140 characters

An optional field for your unique identifier for the PDF

status
string
Enum: "new" "parsing" "parsed" "processed" "approved" "rejected" "failed" "transactions_loaded"

Status of PDF

Responses

Request samples

Content type
application/json
{
  • "filename": "my-favourite.pdf",
  • "fraud_reason": "string",
  • "is_fraud": true,
  • "notes": "string",
  • "reference_id": "my-favourite-pdf",
  • "status": "processed"
}

Response samples

Content type
application/json
{
  • "pdf": {
    },
  • "request_id": "string"
}

Send patch transactions for a pdf statement

Send patch transactions processed pdf that will override the extracted transactions in the specified statement

Authorizations:
BasicAuth
path Parameters
heron_id
required
string

heron_id of the pdf

Request Body schema: application/json
exclude
boolean

True if the statement should be excluded from processing

index
required
integer

The index of the statement in the pdf to patch

object (PdfPatchStatementSummary)
required
Array of objects (PdfPatchTransaction)

The full list of transactions that will be used to override the extracted transactions for the specified statement

Responses

Request samples

Content type
application/json
{
  • "exclude": true,
  • "index": 0,
  • "summary": {
    },
  • "transactions": [
    ]
}

Response samples

Content type
application/json
{
  • "ok": true
}

ISOApplication

Upload an ISO application PDF for for an end user

Use this endpoint to upload an ISO application PDF. Once uploaded, the file will be automatically scrubbed asynchronously. You can use the returned iso_application heron_id (prefixed "iso_") to fetch the scrubbing results. Please contact support@herondata.io to enable this endpoint.

Authorizations:
BasicAuth
path Parameters
end_user_id_or_heron_id
required
string
Request Body schema: multipart/form-data
file
string <binary>

Responses

Response samples

Content type
application/json
{
  • "bank_statement": null,
  • "created": "2019-08-24T14:15:22Z",
  • "file_class": "other",
  • "filename": "string",
  • "heron_id": "string",
  • "iso_application": {
    },
  • "reference_id": "string"
}

Get EndUser ISO Applications

Get all ISO applications for an end user

Authorizations:
BasicAuth
path Parameters
end_user_id_or_heron_id
required
string

Responses

Response samples

Content type
application/json
[
  • {
    }
]

Upload an ISO application PDF for automated scrubbing in under 15 seconds

Use this endpoint to upload an ISO application PDF. Once uploaded, the file will be automatically scrubbed asynchronously. You can use the returned heron_id (prefixed "iso_") to fetch the scrubbing results from the GET endpoint below. Please contact support@herondata.io to enable this endpoint.

Authorizations:
BasicAuth
Request Body schema: multipart/form-data
file
string <binary>

Responses

Response samples

Content type
application/json
{
  • "heron_id": "string",
  • "status": "processing"
}

Upload an ISO application PDF for automated scrubbing in under 15 seconds (base64)

This endpoint is for uploading ISO application PDFs in base64 format.

Authorizations:
BasicAuth
Request Body schema: application/json
file_base64
required
string^data\:\w+\/\w+\;base64\,

The base64 encoded string of the file

filename
required
string

The original filename of the ISO application form

reference_id
string or null
Default: null

A reference id for the file

Responses

Request samples

Content type
application/json
{
  • "file_base64": "base64_encoded_string",
  • "filename": "iso_app.pdf",
  • "reference_id": "your-file-id"
}

Response samples

Content type
application/json
{
  • "heron_id": "string",
  • "status": "processing"
}

Get the scrubbed results and data validations of an uploaded ISO application by its heron_id (prefixed "iso_")

Use this endpoint to retrieve the scrubbed results and data validations of an uploaded ISO application PDF once it has finished processing. If processing is still underway, the processing_status field will be "processing".

Authorizations:
BasicAuth
path Parameters
heron_id
required
string

Responses

Response samples

Content type
application/json
{
  • "created": "2019-08-24T14:15:22Z",
  • "end_user_heron_id": "string",
  • "end_user_id": "string",
  • "field_validations": [
    ],
  • "filename": "iso_app.pdf",
  • "heron_id": "iso_6hBjQT9k6KP2rLCXwjUJff",
  • "processing_status": "processed",
  • "quality_status": "fully_matched",
  • "result": {
    },
  • "source_email": {
    }
}

EndUserAccounts

Get Missing Accounts (beta)

Get a list of possible missing accounts for a given End User. This endpoint is in beta and likely to change.

Authorizations:
BasicAuth
path Parameters
end_user_id_or_heron_id
required
string

The end_user_id or heron_id of EndUser

Responses

Response samples

Content type
application/json
{
  • "missing_accounts": [
    ]
}

EnrichedTransactions

Get end user transactions

Get all unique transactions for a single end user. Set end user status to "ready" to initiate transaction enrichment, otherwise may contain both enriched and unenriched transactions

Authorizations:
BasicAuth
path Parameters
end_user_id_or_heron_id
required
string
query Parameters
page
integer >= 1
Default: 1

Results page

last_updated_min
string or null <date-time>
Default: null
Example: last_updated_min=2024-05-08T05:02:45.648270

Filter for transactions whose values were last updated in Heron systems after the specified input value, isoformat

per_page
integer [ 1 .. 50000 ]
Default: 100

Desired results per page

Responses

Response samples

Content type
application/json
{
  • "_meta": {
    },
  • "transactions_enriched": [
    ]
}

Get enriched transaction

Get enriched transaction

Authorizations:
BasicAuth
path Parameters
reference_id_or_heron_id
required
string

Responses

Response samples

Content type
application/json
{
  • "transaction_enriched": {
    }
}

Transactions

Create end user transactions (async)

Upload transactions for a specific end user. Does not include enriching transactions -- set end user status = 'ready' to initiate processing. For synchronous enrichment, please instead use "Enrich transactions (sync). Either timestamp (preferred) or date must be present in the transaction payload."

Authorizations:
BasicAuth
path Parameters
end_user_id_or_heron_id
required
string
Request Body schema: application/json
Array of objects or null (AccountBalance1)

Bank account balance information for a particular account_id. The balance here must be the latest balance after all the transactions in this batch have been applied.

required
Array of objects (EndUserTransactionPostAsync) non-empty

Responses

Request samples

Content type
application/json
{
  • "balances": [
    ],
  • "transactions": [
    ]
}

Response samples

Content type
application/json
{
  • "request_id": "string",
  • "transactions_loaded": 0
}

Delete transactions

Delete transactions

Authorizations:
BasicAuth
query Parameters
heron_ids
Array of strings
Default: []

Heron IDs of transactions to be deleted

heron_id
string or null
Default: null
Example: heron_id=txn_NU73UQfYve5uxyRhosjE5s

(legacy) Heron ID of transaction to be deleted

account_id
string or null
Default: null

account_id of transactions to be deleted

request_id
string or null
Default: null

Request ID of transactions to be deleted

only_duplicates
boolean or null
Default: null

if true, deletes only transactions that are marked as duplicates

reference_ids
Array of strings
Default: []

Reference IDs of transactions to be deleted

end_user_id
string or null
Default: null

end_user_id of transactions to be deleted

Responses

Callbacks

Response samples

Content type
application/json
{
  • "message": "string"
}

Callback payload samples

Callback
POST: $yourWebhookUrl
Content type
application/json
{
  • "created": "2024-05-08T05:02:44.519223",
  • "data": {
    },
  • "meta": { },
  • "topic": "end_user.processed"
}

Get transactions

Get transactions

Authorizations:
BasicAuth
query Parameters
page
integer >= 1
Default: 1

Page of transaction to return

category_heron_id
Array of strings or null
Default: []
Example: category_heron_id=ctg_h2Xi4cEDGu8nePmNc6XQYL

Filter by the heron_id of the category that the transaction is annotated with

timestamp_date_min
string <date>
Example: timestamp_date_min=2020-04-27

Filter by earliest transaction timestamp

limit
integer [ 1 .. 10000 ]
Default: 1000

Number of transactions to return per page

confidence_min
number [ 0 .. 1 ]

Filter by minimum confidence of annotation associated with transaction

description_keyword
string

Filter by keyword match on transaction description; case insensitive

reference_id
string

Reference Id of transaction

created_date_min
string <date>
Example: created_date_min=2020-04-27

Filter by earliest transaction upload date - when Heron received the transaction

is_recurring
boolean

Filter by whether the transaction is recurring

min_amount
number

Filter by minimum amount of transaction

from_date
string <date>

Deprecated; see created_date_ or timestamp_date_

max_amount
number

Filter by maximum amount of transaction

has_merchant
boolean or null
Default: null

Filter by whether the transaction has a merchant entity associated with it

request_id
string

Request-Id header returned in the response of POST transactions. Sending this parameter will return all transactions sent in a particular POST request, including any duplicates.

end_user_id
string

End user id of transaction

confidence_max
number [ 0 .. 1 ]

Filter by maximum confidence of annotation associated with transaction

to_date
string <date>

Deprecated; see created_date_ or timestamp_date_

timestamp_date_max
string <date>
Example: timestamp_date_max=2020-04-27

Filter by latest transaction timestamp

description_regex
string

Filter by regex matching transaction description

heron_id
string
Example: heron_id=txn_CFVyGuetKqadG3QhsTXkAp

Heron generated Id of transaction

transaction_code
string

Filter by transaction code

merchant_group_id
string

Filter by merchant group id

order_by
string
Default: "id_asc"
Enum: "amount_asc" "amount_desc" "abs_amount_asc" "abs_amount_desc" "description_asc" "description_desc" "timestamp_asc" "timestamp_desc" "id_asc" "id_desc" "confidence_asc" "confidence_desc"

What to order transactions by

last_updated_max
string <date-time>
Example: last_updated_max=2024-05-08T05:02:44.514986

Filter for transactions whose values were last updated in Heron systems before the specified input value

last_updated_min
string <date-time>
Example: last_updated_min=2024-05-08T05:02:44.514972

Filter for transactions whose values were last updated in Heron systems after the specified input value

merchant_heron_id
string

Filter by merchant heron id

include_duplicates
boolean

Whether or not to include duplicate transactions in the response. Defaults to false unless request_id is provided, in which case it defaults to true.

created_date_max
string <date>
Example: created_date_max=2020-04-27

Filter by latest transaction upload date - when Heron received the transaction

has_matching_transaction
boolean

Filter by whether the transaction has a matching transaction

Responses

Response samples

Content type
application/json
{
  • "_meta": {
    },
  • "_summary": {
    },
  • "transactions": [