Skip to main content

Ongoing AML

The "Ongoing AML" feature offers continuous, real-time monitoring and analysis of your AML requests, ensuring your business remains vigilant against financial crimes at all times. By enabling real-time insights, this feature helps you detect and respond to suspicious activities as they happen, significantly reducing the risk of compliance breaches and financial losses.

With Ongoing AML, you can tailor the monitoring timeline to fit your business needs, whether it’s for a few days, weeks, or even months. The feature employs advanced algorithms and data analysis techniques, constantly evaluating transactions for signs of money laundering or other illicit activities. Additionally, Ongoing AML provides live notifications, webhooks, and emails to alert you immediately of any changes or suspicious activities.

Request​

"Requests" refer to the various HTTP methods used for interacting with the API, providing details on endpoint URLs, parameters, headers, request bodies, and examples.

Read Ongoing Requests​

Description:
The "Read Ongoing Requests" API allows you to retrieve detailed information about all active AML monitoring requests. With this endpoint, you can programmatically access a comprehensive list of all AML requests currently under monitoring, including the entity being monitored, the countries involved, and the status of the request. This API is essential for tracking ongoing AML efforts and ensuring that your business remains compliant with regulatory requirements.

Method Call:   GET

API:

https://api.thekyb.com/api/ongoingRequest/read?page=PAGE_NUMBER&limit=LIMIT&search=SEARCH_TERM&country_names[]=COUNTRY_NAME&match_status=MATCH_STATUS&ongoing_monitoring=ONGOING_MONITORING&start_date=START_DATE&end_date=END_DATE
ParameterDescription
searchType: String
Required: Optional
Description: The search term used to query specific AML requests. Users can perform searches based on entity names, such as "john doe", or use a service reference ID such as SERVICE_RANDOM_ID. This flexibility allows for precise filtering of ongoing AML requests based on specific criteria.
pageType: String
Required: Optional
Default: 1
Description: Page attribute tells the page number of the retrieved result.The page number can be specified using the "page" query parameter.
limitType: String
Required: Optional
Default: 25
Description: The "limit" key refers to a parameter that allows users to specify the maximum number of results or records they want to receive from a request. This parameter is particularly useful when dealing with large datasets or when users only need a specific number of items from the API response.
country_namesType: Array
Required: Optional
Description: An array of country names associated with the AML service. This parameter specifies the countries or regions to which the service is relevant or available. It assists in targeting and managing services based on geographical considerations.
match_statusType: String
Required: Optional
Description: The current status of the matching process.
"match_status": "potential match" indicates that the service request has identified a possible match, but further verification may be required.
"match_status": "no match" indicates that the service request has been completed, and no match was found.
ongoing_monitoringType: String
Required: Optional
Description: Filters by ongoing monitoring status. Send it as a query value, true or false. (In the response, ongoing_monitoring is returned as a Boolean.)
start_dateType: String
Required: Optional
Description: Specifies the beginning date for filtering results. The format should be "DD-MM-YYYY". Use this parameter to retrieve records starting from this date onward. If not provided, the API will include all records from the earliest date.
end_dateType: String
Required: Optional
Description: Specifies the ending date for filtering results. The format should be "DD-MM-YYYY". Use this parameter to retrieve records up to and including this date. If not provided, the API will include all records up to the present date.
GET /api/ongoingRequest/read HTTP/1.1
Host: api.thekyb.com
Content-Type: application/json
token: YOUR_SECRET_KEY

Update Ongoing AML​

Description:
The "Update Ongoing AML" API allows you to enable or disable ongoing monitoring for a specific AML request. This API provides a flexible way to manage your AML monitoring processes by giving you control over whether a particular request continues to be monitored in real-time.

Method Call:   POST

API:

https://api.thekyb.com/api/ongoingRequest/update
ParameterDescription
service_typeType: String
Required: Yes
Description: Specifies the type of ongoing monitoring request. The value is ongoing_aml to enable or disable monitoring for an AML company or person.
aml_request_idType: String
Required: Yes (when service_type is ongoing_aml)
Description: The unique identifier for the AML request you wish to enable or disable ongoing monitoring for. This ID links to a specific AML request that is being monitored or requires monitoring.
durationType: Integer
Required: When ongoing_enable is true. Not needed when disabling.
Description: Specifies the duration for which ongoing monitoring should be active. This value determines how long the AML request will be monitored. The range of allowed values depends on the duration_type parameter:
- If duration_type is "day", the duration value must be between 1 and 7.
- If duration_type is "week", the duration value must be between 1 and 4.
- If duration_type is "month", the duration value must be between 1 and 12.
duration_typeType: String
Required: When ongoing_enable is true. Not needed when disabling.
Description: Defines the unit of time for the duration: "day", "week" or "month". This parameter specifies how the duration should be interpreted (e.g., "1 day" or "1 month").
ongoing_enableType: Boolean
Required: Yes
Description: A boolean flag to enable or disable ongoing monitoring for the specified AML request. Set to true to enable monitoring or false to disable it. This parameter directly controls whether the request will be actively monitored in real-time.
POST /api/ongoingRequest/update HTTP/1.1
Host: api.thekyb.com
Content-Type: application/json
token: YOUR_SECRET_KEY

{
"service_type": "ongoing_aml",
"aml_request_id": "YOUR_AML_REQUEST_ID",
"duration": 1,
"duration_type": "day",
"ongoing_enable": true
}

Response​

The Ongoing AML API provides two types of responses when an ongoing monitoring request is made: an HTTP response and a callback response. Both responses are delivered in JSON format with an application/json header. The response includes a Key Signature in the header, which is used to verify the authenticity of the response source.

Read Ongoing Requests​

Description:
The "Read Ongoing Requests" response serves as an essential tool for users to monitor and manage their ongoing AML activities. By delivering detailed information about each active monitoring request, including the entity being monitored, involved countries, and current status, users can effectively track their AML efforts. This comprehensive overview enables businesses to stay informed about potential risks, ensuring they remain compliant with regulatory requirements and can make timely decisions to mitigate financial crime.

Method Call:   GET

API:

https://api.thekyb.com/api/ongoingRequest/read?page=PAGE_NUMBER&limit=LIMIT&search=SEARCH_TERM&country_names[]=COUNTRY_NAME&match_status=MATCH_STATUS&ongoing_monitoring=ONGOING_MONITORING&start_date=START_DATE&end_date=END_DATE

Response:

{
"error": false,
"message": "Ongoing requests fetched successfully",
"data": {
"ongoing_requests": [
{
"_id": "ONGOING_REQUEST_ID",
"aml_request_id": "AML_REQUEST_ID",
"kyb_request_id": null,
"company_id": null,
"search": "SEARCH_TERM",
"country_names": [],
"duration": 30,
"duration_type": "day",
"service_type": [
"ongoing_aml"
],
"ongoing_monitoring": true,
"match_status": "potential match",
"total_ongoing_request": 0,
"last_updated_at": null,
"created_at": "2026-08-24T07:29:55.809000Z"
}
],
"pagination": {
"total": 205,
"per_page": 25,
"current_page": 1,
"last_page": 9,
"from": 1,
"to": 25
}
}
}

Response Parameters:

ParameterDescription
errorIndicates whether an error occurred during the API request. false indicates that the request was successful without errors.
messageA descriptive message indicating the status or outcome of the request. In this case, it confirms that ongoing requests were fetched successfully.
data.ongoing_requestsAn array containing ongoing request objects. Each object holds detailed information about a specific ongoing request.
data.ongoing_requests._idA unique identifier for the ongoing request.
data.ongoing_requests.aml_request_idA unique identifier for the AML request associated with this ongoing request.
data.ongoing_requests.kyb_request_idThe KYB request ID linked to this ongoing request, if any. Can be a string or null.
data.ongoing_requests.company_idThe company ID linked to this ongoing request, if any. Can be a string or null.
data.ongoing_requests.searchThe search term used for the ongoing request.
data.ongoing_requests.country_namesAn array of country names associated with the ongoing request.
data.ongoing_requests.durationType: Integer
The numeric duration for which ongoing monitoring is active.
data.ongoing_requests.duration_typeType: String
The unit for duration. Possible values include day, week, and month.
data.ongoing_requests.service_typeAn array listing the service_type associated with the ongoing request, such as "ongoing_aml".
data.ongoing_requests.ongoing_monitoringType: Boolean
Indicates whether ongoing monitoring is enabled for this request. true = enabled; false = disabled.
data.ongoing_requests.match_statusThe match status of the ongoing AML request. It can be either no match or potential match.
data.ongoing_requests.total_ongoing_requestThe total number of ongoing requests on an AML request.
data.ongoing_requests.last_updated_atThe timestamp of the last update made to this ongoing request. Can be a timestamp string or null.
data.ongoing_requests.created_atThe timestamp of when the ongoing request was created.
data.paginationObject used to navigate paginated ongoing request results.
data.pagination.totalTotal number of ongoing requests matching the query.
data.pagination.per_pageNumber of ongoing requests returned per page.
data.pagination.current_pageThe current page number in the paginated results.
data.pagination.last_pageThe last available page number in the paginated results.
data.pagination.fromPosition of the first item on the current page within the full result set.
data.pagination.toPosition of the last item on the current page within the full result set.

Update Ongoing AML​

Description:
The "Update Ongoing AML" response confirms the success or failure of your request to enable or disable ongoing monitoring for a specific AML request.

Method Call:   POST

API:

https://api.thekyb.com/api/ongoingRequest/update

Response:

{
"error": false,
"message": "Ongoing AML enabled successfully",
"data": {}
}

When ongoing monitoring is disabled ("ongoing_enable": false), the message is "Ongoing AML disabled successfully".

Response Parameters:

ParameterDescription
errorThe "error" parameter can have a value of either "true" or "false." In the current scenario, since there were no errors during the request processing, the value of "error" is "false." However, in situations where errors occur, such as missing required parameters or criteria not being met, the value of the "error" parameter will change to "true."
messageThe "message" field in API response formats provides a descriptive text or notification intended to convey additional information or instructions to the API consumer. It is commonly used to communicate relevant details about the response, such as success messages, error messages, or any other informative content that aids in understanding the outcome of the API request. The "message" field helps provide context and guidance to the API consumer regarding the status or result of the API operation.

Error Response:

When the request fails validation, the API returns HTTP status 400:

{
"error": true,
"message": "Ongoing AML already enabled on this request.",
"data": {}
}
MessageCause
Ongoing AML already enabled on this request.ongoing_enable is true, but ongoing monitoring is already turned on for this AML request.
Ongoing AML is already disabled on this request.ongoing_enable is false, but ongoing monitoring is already turned off for this AML request.
aml request id is not validThe aml_request_id does not exist, or does not belong to your account.
aml request id is required when service type is ongoing_aml.aml_request_id was not sent.