### Install Mono Connect.js SDK version 2.0.2 Source: https://docs.mono.co/docs/changelog Use this npm command to install SDK version 2.0.2, which permanently loads the v2 widget. ```bash npm install @mono.co/connect.js@2.0.2 ``` -------------------------------- ### Install Mono Connect.js SDK version 0.2.5 Source: https://docs.mono.co/docs/changelog Use this npm command to install SDK version 0.2.5, which maintains compatibility with both v1 and v2 widgets. ```bash npm install @mono.co/connect.js@0.2.5 ``` -------------------------------- ### Install @mono.co/connect.js with NPM or Yarn Source: https://docs.mono.co/docs/financial-data/sdk Install the Mono Connect widget package using either NPM or Yarn. Choose one command based on your package manager. ```bash npm install @mono.co/connect.js ``` ```bash yarn add @mono.co/connect.js ``` -------------------------------- ### Start Watchlist Monitoring (POST /v3/lookup/watchlist/monitor) Source: https://docs.mono.co/docs/lookup/watchlist-screening/integration-guide Start ongoing monitoring for a previously screened subject by POSTing to /v3/lookup/watchlist/monitor. The response returns a monitoring ID with status "successful". To stop monitoring, send a DELETE request to https://api.withmono.com/v3/lookup/watchlist/monitor/{id}. ```bash curl --request POST \ --url https://api.withmono.com/v3/lookup/watchlist/monitor \ --header 'accept: application/json' \ --header 'content-type: application/json' \ --header 'mono-sec-key: YOUR_MONO_SECRET_KEY' \ --data '{ "type": "individual", "name": "Tariq Bassey", "date_of_birth": "1941-08-17", "gender": "male", "country": "ng" }' ``` ```json { "status": "successful", "message": "Request completed successfully", "timestamp": "2026-03-24T10:45:02.273Z", "data": { "id": "aml_scr_c957dbe8cc42a663abfadc085d2a8f08", "status": "successful" } } ``` -------------------------------- ### Import Mono Connect widget Source: https://docs.mono.co/docs/financial-data/sdk Import the Mono Connect widget into your project after installation. ```javascript import Connect from '@mono.co/connect.js' ``` -------------------------------- ### Mono Income endpoint GET request Source: https://docs.mono.co/docs/quickstart Sample curl command to initiate the Mono Income endpoint. Sends a GET request to retrieve a user's income pattern. Requires a valid account ID and mono-sec-key. ```bash curl --request GET \ --url https://api.withmono.com/v2/accounts/id/income \ --header 'Content-Type: application/json' \ --header 'accept: application/json' \ --header 'mono-sec-key: string' ``` -------------------------------- ### cURL Sample Response Source: https://docs.mono.co/docs/financial-data/reauth-link Example JSON response from the initiate reauth request, containing mono_url, customer, account, and other details. ```json { "status": "successful", "message": "Request was successfully completed", "timestamp": "2024-05-01T09:16:35.817Z", "data": { "mono_url": "https://link.mono.co/ALTAYGCOV", "customer": "66312718b0f47", "account": "663127dedfbd0", "meta": { "ref": "099777" }, "scope": "reauth", "institution": "5f5b530a67ffc15e5911e0d2", "auth_method": "internet_banking", "redirect_url": "https://mono.co", "created_at": "2024-05-01T09:16:35.809Z" } } ``` -------------------------------- ### Initiate Statement Insights - GET Request Source: https://docs.mono.co/docs/financial-data/enrichment/statement-insights Send a GET request to the endpoint to start analyzing transactions for a connected bank account. The account ID is required as a path parameter. ```http GET https://api.withmono.com/v2/accounts/{id}/statement/insights ``` -------------------------------- ### Initiate account linking with curl POST to /v2/accounts/initiate Source: https://docs.mono.co/docs/quickstart Use this curl command to create a customer and initiate account linking. Requires a mono-sec-key header and a JSON body with customer details, meta ref, scope, and redirect_url. The response includes a mono_url to redirect the user to the Mono widget. ```bash curl --request POST \ --url https://api.withmono.com/v2/accounts/initiate \ --header 'accept: application/json' \ --header 'content-type: application/json' \ --header 'mono-sec-key: string' \ --data '{ "customer": { "name": "Samuel Olamide", "email": "samuel@neem.com" }, "meta": { "ref": "99008877TEST"}, "scope": "auth", "redirect_url": "https://mono.co" } ' ``` -------------------------------- ### Initiate Prove Session with curl and Example Response Source: https://docs.mono.co/docs/lookup/prove/integration-guide Initiate a Prove session by POSTing to https://api.withmono.com/v1/prove/initiate with your secret key. The response contains either a mono_url for browser-based flows or a request id for SDK integration. The kyc_level can be tier_1, tier_2, tier_3, or custom; identities is required only when kyc_level is custom and must include at least one of bvn or nin. ```bash curl --request POST \ --url https://api.withmono.com/v1/prove/initiate \ --header 'accept: application/json' \ --header 'content-type: application/json' \ --header 'mono-sec-key: ' \ --data '{ "reference": "testreference123", "redirect_url": "https://mono.co", "kyc_level": "custom", // or tier_1, tier_2, tier_3 "identities": ["bvn", "address"], // required only when kyc_level is custom "bank_accounts": true, "customer": { "name": "Adebayo Adeyemi", "phone": "08012345678", "email": "test@example.com", "address": "20, Angel's Place, Eke street off NTA road, Ikeja Lagos", "identity": { "type": "BVN", // can either be BVN or NIN "number": "12345678900" } } }' ``` ```json { "status": "successful", "message": "Request completed successfully", "timestamp": "2025-01-10T21:47:35.919Z", "data": { "id": "reRVZW59A3Q123", "customer": "67d18b0770caaed57fe3tb2bw", "mono_url": "https://prove.mono.co/reRVZW59A3Q123", "reference": "testreference123", "redirect_url": "https://mono.co", "bank_accounts": true, "kyc_level": "custom", "identities": ["bvn", "address"], "is_blacklisted": false, "live_mode": true } } ``` -------------------------------- ### Get Institutions - JSON Response Source: https://docs.mono.co/docs/financial-data/partners-api-guide/sandbox-guide Example response from the institutions endpoint, showing a successful request with a list of institutions. Includes fields like _id, name, type, icon, primary_color, and auth_methods with expected login form fields. ```json { "status": "successful", "message": "Request completed successfully", "timestamp": "2025-05-13T09:38:07.908Z", "data": [ { "_id": "5f2d08bf60b92e2888287703", "name": "Bank", "type": "PERSONAL_BANKING", "icon": "https://connect.withmono.com/build/img/access-bank.png", "identifier": "mono.connections.identifier", "nip_code": "000000", "country": "ng", "primary_color": "#004085", "scope": [ { "name": "Financial Data", "type": "financial_data" } ], "auth_methods": [ { "type": "internet_banking", "ui": { "title": "Log in to bank", "form": [ { "type": "elements.input", "name": "username", "hint": "Username", "contentType": "string" }, { "type": "elements.input", "name": "password", "hint": "Password", "contentType": "password" } ] } } ] } ] } ``` -------------------------------- ### Example Webhook Payload Source: https://docs.mono.co/docs/disburse/integration-guide Example payload for the event.disbursement.completed webhook. Shows the event type and data including status, amounts, and counts. ```json { "event": "event.disbursement.completed", "data": { "message": "Disbursement has been successfully completed", "reference": "disburse7345923", "total_amount": 2000000, "total_fee": 3500, "status": "failed", "transactions_count": 1, "processing": { "count": 0, "amount": 0 }, "successful": { "count": 0, "amount": 0 }, "failed": { "count": 1, "amount": 2000000 }, "app": "69989083f7682ba3968b0125", "business": "67adaad3d23314578c205d10" } } ``` -------------------------------- ### Instantiate Directpay widget with Connect Source: https://docs.mono.co/docs/payments/sdk-guide Creates a new Connect instance with the live public key, scope 'payments', and the payment ID from the Initiate Payments API. Calls setup() and open() to launch the widget. ```javascript const monoWidget = new Connect({ key: "live_pk_from_your_dashboard", scope: "payments", data: { payment_id: "txreq_HeqMWnpWVvzdpMXiB4I123456" } }); monoWidget.setup(); monoWidget.open() ``` -------------------------------- ### Mono Connect Widget Setup with Customer Object Source: https://docs.mono.co/docs/financial-data/integration-guide Sets up the Mono Connect widget with a customer object. The `key` must be your Mono application public key. The `data` callback is required and should contain the customer object. When an `id` is provided, the name, email, and identity fields are not required. ```javascript ``` -------------------------------- ### GET /v2/accounts/{id}/balance Source: https://docs.mono.co/docs/financial-data/manual-data-sync Retrieves the real-time balance of a specific account. Use this endpoint after receiving a successful sync webhook to get updated data. ```APIDOC ## GET /v2/accounts/{id}/balance ### Description Retrieves the real-time balance of a specific account. Use this endpoint after receiving a successful sync webhook to get updated data. ### Method GET ### Endpoint https://api.withmono.com/v2/accounts/{id}/balance ### Parameters #### Path Parameters - **id** (string) - Required - The unique identifier of the account. ### Response #### Success Response (200) - **status** (string) - Status of the request. - **message** (string) - Response message. - **timestamp** (string) - Timestamp of the response. - **data** (object) - Contains account details. - **id** (string) - Account ID. - **name** (string) - Account holder's name. - **account_number** (string) - Account number. - **balance** (number) - Current account balance. - **currency** (string) - Currency code. #### Response Example { "status": "successful", "message": "Request was successfully completed", "timestamp": "2024-07-05T12:20:59.336Z", "data": { "id": "666b166ce06be73", "name": "Samuel Olamide", "account_number": "0200000043", "balance": 53769, "currency": "NGN" } } ``` -------------------------------- ### Initiate account linking with account match verification (curl) Source: https://docs.mono.co/docs/financial-data/connect-link Use this curl command to initiate account linking with account match verification. The request includes the customer, institution, and check_account_match fields. The institution.id, auth_method, and account_number are required. Set check_account_match to true to enable verification. ```bash curl --request POST \ --url https://api.withmono.com/v2/accounts/initiate \ --header 'accept: application/json' \ --header 'content-type: application/json' \ --header 'mono-sec-key: string' \ --data '{ "customer": { "name": "Samuel Olamide", "email": "samuel@neem.com" }, "meta": { "ref": "99008877TEST" }, "institution": { "id": "5f2d08bf60b92e2888287704", "auth_method": "internet_banking", "account_number": "02605538421" }, "check_account_match": true, "scope": "auth", "redirect_url": "https://mono.co" } ' ``` -------------------------------- ### Statements API Response Example Source: https://docs.mono.co/docs/financial-data/statements Example JSON response from the Statements API, showing a successful retrieval of transaction data with fields like id, type, amount, narration, balance, and date. ```json { "status": "successful", "message": "Transactions retrieved successfully", "timestamp": "2024-05-07T13:23:27.123Z", "data": [ { "id": "66321893cd7b216069425e55", "type": "debit", "amount": 14, "narration": "0235416643:WTax.Pd:01-04-2024to 30-04-2024", "balance": null, "date": "2024-04-30T00:00:00.000Z" }, { "id": "66321893cd7b216069425e72", "type": "credit", "amount": 500000, "narration": "NIP:SAMUEL OLAMIDE-Subscription", "balance": null, "date": "2024-01-07T00:00:00.000Z" } ], "meta": { "count": 31 } } ``` -------------------------------- ### cURL Sample Request for Initiate Income Source: https://docs.mono.co/docs/financial-data/income cURL sample request for the Initiate Income endpoint. Requires the `mono-sec-key` header for authentication. Note the URL in the source contains a typo ('htthttps') and should be corrected to 'https' before use. ```bash curl --request GET \ --url htthttps://api.withmono.com/v2/accounts/:id/income \ --header 'mono-sec-key: string' \ --header 'accept: application/json' ``` -------------------------------- ### GET Request for CAC Directors Lookup Source: https://docs.mono.co/docs/lookup/cac-lookup Sends a GET request to the CAC directors lookup endpoint. The {id} path parameter is required and must be the ID returned from the business lookup response. ```http GET https://api.withmono.com/v3/lookup/cac/company/{id}/directors ``` -------------------------------- ### Prove SDK widget instantiation with requestId Source: https://docs.mono.co/docs/lookup/prove/integration-guide HTML page that loads the Prove SDK and instantiates the widget with a requestId from Step 1. The button triggers window.prove.open() to start verification. Includes onLoad, onEvent, and onSuccess callbacks. ```html Document
``` -------------------------------- ### Settlement Webhook Example Source: https://docs.mono.co/docs/payments/split-payments Example of the settlement webhook payload for the direct_debit.split_settlement_successful event. It includes fields such as reference, business, app, status, message, date, currency, split_fee, amount_settled, fee_bearer, and account details. ```json { event: "direct_debit.split_settlement_successful", data: { reference: "po_tr65CqSSomGEv785xQYvJ3P5", business: "60cc8f95ba1772018c5c6b1d", app: "61e270e2bbe2010771c0dec7", status: "settled", message: "Successfully settled", date: "2024-12-08T23:00:00.000Z", currency: "NGN", split_fee: 10 amount_settled: 200, fee_bearer: "sub_accounts", account: { account_name: "Samuel Olamide", account_number: "0123456789", account_type: "sub_account", institution: { name: "Access bank", code: "044", nibss_code: "000014" } }, } } ``` -------------------------------- ### cURL Request to Initiate Reauth Source: https://docs.mono.co/docs/financial-data/reauth-link Sample cURL command to initiate reauth. Uses mono-sec-key header and includes account, scope, meta.ref, and redirect_url. ```bash curl --request POST \ --url https://api.withmono.com/v2/accounts/initiate \ --header 'Content-Type: application/json' \ --header 'accept: application/json' \ --data '{ "meta": { "ref": "099777"}, "scope": "reauth", "account": "65c4c03aa66a95b572cb5a86", "redirect_url": "https://mono.co" }' ``` -------------------------------- ### GET /v3/lookup/cac/company/{id}/directors Source: https://docs.mono.co/docs/lookup/cac-lookup This endpoint allows you to retrieve the list of directors for a business or company using the ID obtained from a business lookup. It requires a GET request with the company ID in the path and a secret key for authentication. ```APIDOC ## GET /v3/lookup/cac/company/{id}/directors ### Description Lookup the directors of a business or company using the ID returned from the business lookup response. ### Method GET ### Endpoint https://api.withmono.com/v3/lookup/cac/company/{id}/directors ### Parameters #### Path Parameters - **id** (string) - Required - The ID returned from the business lookup response. ### Request Example ``` curl -X GET \ -H "mono-sec-key: YOUR_MONO_SECRET_KEY" \ "https://api.withmono.com/v3/lookup/cac/company/{id}/directors" ``` ### Response #### Success Response (200) - **status** (string) - Status of the request. - **message** (string) - Message describing the result. - **timestamp** (string) - Timestamp of the response. - **data** (array) - Array of director objects. #### Response Example ``` { "status": "successful", "message": "CAC lookup successful", "timestamp": "2024-02-14T13:42:07.629Z", "data": [ { "id": 6706910, "surname": "SAMUEL", "firstname": "OLAMIDE", "other_name": "NOMO", "email": "", "business_email": "samuel@neem.com", "phone_number": "01234567890", "gender": "MALE", "former_nationality": "", "age": 56, "city": "", "occupation": "", "former_name": "", "corporation_name": "", "rc_number": "", "corporation_company": null, "state": "LAGOS", "pobox": null, "accreditationnumber": "", "is_lawyer": null, "last_visit": 0, "form_type": "International Passport", "is_presenter": null, "is_chairman": null, "num_shares_alloted": 1, "type_of_shares": "ORDINARY", "date_of_birth": "1995-05-05T23:00:00.000+00:00", "status": "ACTIVE", "date_of_termination": null, "date_of_appointment": null, "date_of_change_of_address": null, "former_address": null, "former_postal": null, "former_surname": "", "former_first_name": "", "former_other_name": "", "date_of_status_change": null, "identity_number": "A0345456618", "identity_issue_state": null, "other_directorship_details": "", "portal_user_fk": null, "affiliates_fk": null, "process_type_fk": { "id": 6564, "name": "COMPANY_REGISTRATION", "description": "Company Registration", "amount": 1, "type": null, "product_id": "511111119", "bank_code": "25670" }, "company": null, "same_person_as_fk": null, "nature_of_app_or_discharge": null, "is_designated": null, "end_of_appointment": null, "appointed_by": null, "date_of_deed_of_discharge": null, "date_of_resolution": null, "country_fk": { "id": 1, "name": "NIGERIA", "code": "NIGERIA" }, "country_of_residence": null, "is_carried_over_from_name_avai": null, "lga": null, "corporation_registration_date": null, "is_company_deleted": null, "government_organisation_name": null, "foreign_organisation_name": null, "company_street_address": null, "company_state": null, "company_city": null, "is_corporate": null, "county_of_incorporation_fk": null, "nationality": null, "address": "40, BUHARI CRESCENT GRA", "business_address": "25, ADEMOLA BUHARI CRESCENT, WUSE 2, ABUJA, FCT, NIGERIA", "postcode": "", "street_number": "", "affiliates_residential_address": null, "affiliates_psc_information": 67364910, "legal_owners_of_interests": [], "legal_owners_of_voting_rights": [], "stock_exchange_soes": [], "approved_for_notice_of_psc": null, "company_address2": "", "full_address2": "39, KOLA AMODU CRESCENT MAGODA GRA, LAGOS", "affiliate_type_fk": { "id": 7516, "name": "SHAREHOLDER", "description": "SHAREHOLDER" } } ] } ``` ``` -------------------------------- ### cURL request to initiate account linking Source: https://docs.mono.co/docs/financial-data/connect-link Sample cURL command to send a POST request to the initiate endpoint. Includes the required headers and JSON body with customer, meta, scope, and redirect_url. ```bash curl --request POST \ --url https://api.withmono.com/v2/accounts/initiate \ --header 'accept: application/json' \ --header 'content-type: application/json' \ --header 'mono-sec-key: string' \ --data '{ "customer": { "name": "Samuel Olamide", "email": "samuel@neem.com" }, "meta": { "ref": "99008877TEST"}, "scope": "auth", "redirect_url": "https://mono.co" } ' ``` -------------------------------- ### Response object from initiate endpoint Source: https://docs.mono.co/docs/quickstart Example JSON response from the initiate endpoint. Contains mono_url for redirecting to the Mono widget, customer ID, meta ref, scope, redirect_url, and created_at timestamp. ```json { "status": "successful", "message": "Request was successfully completed", "timestamp": "2024-03-18T11:51:41.624Z", "data": { "mono_url": "https://link.mono.co/ALGSTO222222WE", "customer": "65f82acd00000003aa9028d", "meta": { "ref": "99008877TEST" }, "scope": "auth", "redirect_url": "https://mono.co", "created_at": "2024-03-18T11:51:41.605Z" } } ``` -------------------------------- ### POST /v2/accounts/initiate Source: https://docs.mono.co/docs/financial-data/connect-link Initiates account linking by generating a URL to send to users. Requires customer information, scope, and redirect URL, authenticated with the mono-sec-key header. ```APIDOC ## POST /v2/accounts/initiate ### Description Initiates account linking by generating a URL to send to users. Requires customer information, scope, and redirect URL, authenticated with the mono-sec-key header. ### Method POST ### Endpoint https://api.withmono.com/v2/accounts/initiate ### Parameters #### Request Body - **customer** (object) - Required - User's customer information (name and email) - **customer.name** (string) - Required - User's name - **customer.email** (string) - Required - User's email - **scope** (string) - Required - Specify the scope as "auth" - **meta** (object) - Optional - Meta object expecting a "ref" key - **meta.ref** (string) - Optional - Unique reference to tie the account linked via generated URL - **redirect_url** (string) - Required - Valid URL for successful account linking redirection #### Request Headers - **mono-sec-key** (string) - Required - Your Mono secret key ### Request Example ```json { "customer": { "name": "Samuel Olamide", "email": "samuel@neem.com" }, "meta": { "ref": "99008877TEST"}, "scope": "auth", "redirect_url": "https://mono.co" } ``` ### Response #### Success Response (200) - **status** (string) - Status of the request (e.g., "successful") - **message** (string) - Response message - **timestamp** (string) - Timestamp of the response - **data** (object) - Response data - **data.mono_url** (string) - URL for account linking - **data.customer** (string) - Customer ID - **data.meta** (object) - Meta object with ref - **data.scope** (string) - Scope of the request - **data.redirect_url** (string) - Redirect URL - **data.created_at** (string) - Creation timestamp #### Response Example ```json { "status": "successful", "message": "Request was successfully completed", "timestamp": "2024-03-18T11:51:41.624Z", "data": { "mono_url": "https://link.mono.co/ALGSTO222222WE", "customer": "65f82acd00000003aa9028d", "meta": { "ref": "99008877TEST" }, "scope": "auth", "redirect_url": "https://mono.co", "created_at": "2024-03-18T11:51:41.605Z" } } ``` ``` -------------------------------- ### GET /owo/v1/users/status Source: https://docs.mono.co/docs/whatsapp-payment/integration-guide Check if a user has an Owo account and its status. ```APIDOC ## GET /owo/v1/users/status ### Description Check if a user has an Owo account and its status. ### Method GET ### Endpoint https://api.withmono.com/owo/v1/users/status ### Parameters #### Query Parameters - **phone** (string) - Required - The user's phone number in E.164 format, without the leading + (e.g. 23480...). #### Request Headers - **mono-sec-key** (string) - Required - Your Owo secret API key. ### Request Example ``` curl --request GET \ --url https://api.withmono.com/owo/v1/users/status?phone=2348012345678 \ --header 'accept: application/json' \ --header 'mono-sec-key: your_secret_key' ``` ### Response #### Success Response (200) - **status** (string) - The status of the request. - **message** (string) - A message describing the result. - **timestamp** (string) - The timestamp of the response. - **data.exists** (boolean) - Whether the user exists. - **data.status** (string) - The user's status: `active`, `pending_activation`, or `not_found`. #### Response Example ``` { "status": "successful", "message": "User is active and ready to perform transactions.", "timestamp": "2025-08-15T14:10:00.465Z", "data": { "exists": true, "status": "active" } } ``` ``` -------------------------------- ### GET /v3/institutions Source: https://docs.mono.co/docs/financial-data/partners-api-guide/integration-guide Retrieves the list of institutions that can be connected to, with optional filters. ```APIDOC ## GET /v3/institutions ### Description Returns a list of financial institutions that you can connect to. You can filter by scope (e.g., `financial_data`), bank code, or authentication method. The response includes institution details such as ID, icon, primary color, and expected credentials for each auth method. ### Method GET ### Endpoint `/v3/institutions` ### Parameters #### Query Parameters - **scope** (string) - Required - The scope of institutions to retrieve. For this guide, use `financial_data`. - **bank_code** (string) - Optional - Filter institutions by bank code. - **auth_method** (string) - Optional - Filter institutions by authentication method. ### Request Example ``` curl -X GET "https://api.withmono.com/v3/institutions?scope=financial_data" \ -H "mono-sec-key: " ``` ### Response #### Success Response (200) - **status** (string) - Status of the request, e.g., "successful". - **message** (string) - Message describing the result. - **timestamp** (string) - Timestamp of the response. - **data** (array of objects) - List of institutions. Each object contains: - `_id` (string) - Institution ID. - `name` (string) - Institution name. - `type` (string) - Type of institution (e.g., "PERSONAL_BANKING"). - `icon` (string) - URL to the institution's icon. - `identifier` (string) - Identifier for the institution. - `nip_code` (string) - NIP code. - `country` (string) - Country code (e.g., "ng"). - `primary_color` (string) - Primary color in hex format. - `scope` (array of objects) - Scopes available for the institution. Each object contains `name` and `type`. - `auth_methods` (array of objects) - Supported authentication methods. Each object contains `type` and `ui` details, including form fields. #### Response Example ``` { "status": "successful", "message": "Request completed successfully", "timestamp": "2025-05-13T09:38:07.908Z", "data": [ { "_id": "5f2d08bf60b92e2888287703", "name": "Bank", "type": "PERSONAL_BANKING", "icon": "https://connect.withmono.com/build/img/access-bank.png", "identifier": "mono.connections.identifier", "nip_code": "000000", "country": "ng", "primary_color": "#004085", "scope": [ { "name": "Financial Data", "type": "financial_data" } ], "auth_methods": [ { "type": "internet_banking", "ui": { "title": "Log in to bank", "form": [ { "type": "elements.input", "name": "username", "hint": "Username", "contentType": "string" }, { "type": "elements.input", "name": "password", "hint": "Password", "contentType": "password" } ] } } ] } ] } ``` ```