LogoLogo
Connect
Connect
  • 🏡Welcome to LHV Connect API
  • 📺News and Updates
    • 📈Performance and Stats
    • 🔔Notice of Change
  • 🧭Quick Start Guide
  • 🎥Connect Fundamentals
    • Authentication and Certificates
    • Environments
    • Messaging Pattern
    • Service Provider model
    • Technical limitations
    • Encoding and Languages
    • Response Compression
    • Dates and Time Zones
    • Response Codes and Error handling
    • Onboarding
    • Live Proving
    • LHV UK and Estonia integrations
    • FAQ and Tips
  • 📖Service Catalogue
    • 💚Heartbeat
      • Heartbeat - GET
      • Heartbeat Advanced - GET
    • 📩Messages Services
      • Get next message
      • Get list of messages
      • Get list of messages V2
      • Get message by response ID
      • Get list of requests
      • Get request by request ID
      • Count number of messages
      • Mark message as processed
      • Mark batch of messages as processed
      • Mark batch of messages as processed V2
      • Messages Metadata
      • Get compressed message for testing
    • 💰Account Information Services
      • Account Balance
      • Account Statement
      • Transaction Notification
        • Incoming Bacs Credit Notification
    • 💸Payment Initiation Services
      • Pain.001.001.09
      • Pain.002.001.10
      • Samples
      • Authentication methods
      • Payment Scheme Selection
      • Payment Return Initiation
      • Payments Service Idempotency
      • Payments Originating Overseas
      • Legacy documents
        • pain.001.001.03 format
    • ✅Confirmation of Payee Services
      • Confirmation of Payee - Requester
      • Confirmation of Payee - Responder
    • 😶‍🌫️VIBAN Services
      • VIBAN Open
      • VIBAN Bulk Open
      • VIBAN Modify
      • VIBAN Info
      • VIBAN Close
      • VIBAN Notification
    • 🔗Indirect Scheme Access
      • Agency Account Synchronization
      • RTF - Routing Table Files message
      • 🧾Payment Collection Services
        • 💷Bacs Direct Debit
          • Bacs Direct Debit Mandate Initiation Request
          • Bacs Direct Debit Mandate Initiation Response
          • Bacs Direct Debit Mandate Initiation Response Confirmation
          • Bacs Direct Debit Mandate Cancellation Request
          • Bacs Direct Debit Mandate Cancellation Response
          • Direct Debit Incoming Collection Notification Request
          • Direct Debit Collection Notification Response
          • Direct Debit Collection Notification Response Confirmation
          • Direct Debit Reversal Notification Request
          • Examples
    • 📨Webhooks
      • Webhook Format and Processing
      • Managing Webhook Configurations
      • Webhook Security
      • Webhook Metadata
      • Full Bodied Webhooks
  • 🗓️Reference
    • Glossary
    • Code Reference Tables
      • Balance Type Codes
      • Credit and Debit Transaction Codes
      • Payment Scheme Codes
      • Direct Debit Scheme Codes
      • Payment Reject Codes
      • Payment Return Codes
      • Bacs Direct Debit Mandate Reject Codes
      • Bacs Direct Debit Reject Codes
      • Bacs Direct Debit Reversal Reason
      • Bank Transaction Codes
      • Transaction Purpose Codes
      • Category Purpose Codes
      • Private Person Identification Codes
      • Organisation Identification Type Codes
      • Payment Priority Codes
      • Charges Bearer Codes
  • ☎️Support
    • Contact
Powered by GitBook
On this page
  • Service description
  • Request
  • Response

Was this helpful?

  1. Service Catalogue
  2. Messages Services

Get list of messages V2

Service description

Version 2 of the Get list of messages service differs by supporting pagination.

V2 version supports only LHV UK messages where x-bank-code = LHVUK. It does not include the messages from LHV EE where x-bank-code = LHVEE.

With these limitations the service could be more suitable for specific use cases like integrations testing and problem solving.

Request

GET https://connect.lhv.com/v2/messages

Parameters

Name
Value
Description

pageSize

integer

Number of messages to return on one page. Max value is 1000!

pageNumber

integer

Page number

responseType

string

Optional. Filter specific service messages. The value can be any Message-Response-Type (e.g., ACCOUNT_STATEMENT, CREDIT_DEBIT_NOTIFICATION, PAYMENT). Similar to Filter-Response-Type header for V1 service.

messageRequestId

string

Optional. Filter by Request ID value from any previous service request like Payments, Account Statement etc.

includeProcessed

true/false

Optional. Also includes messages that are already processed by the Customer

includeMetadata

true/false

Optional. Includes Metadata block. Default is false.

serviceProvider

true/false

Optional. Filter only Service Provider messages. Similar to Filter-Service-Provider header for V1 service.

Headers

Name
Value
Description

Client-Code

customer value

For Service Providers only. Company registration code of the Service Provider or its customer. When using the Service Provider own value also related customers messages are returned by default - see also Filter-Service-Provider for more options.

Client-Country

customer value

For Service Providers only. Should match the value of Client-Code

Body

JSon with a list of messages metadata - type, timing, reference ID's.

Response

Headers

Name
Value
Description

Content-Type

application/json

Format of the message body

X-Bank-Code

LHVUK, LHVEE

LHV Bank entity

Client-Code

customer value

When using service provider model - customer entity related to the message

Client-Country

customer value

When using service provider model - customer entity related to the message

Body

OK

{
    "pageNumber": 1,
    "pageSize": 100,
    "totalPages": 2,
    "totalElements": 109,
    "messages": [
        {
            "messageResponseId": "RES27dc481c24af499d8cab27ec8099a4d2",
            "messageRequestId": "REQ06d2e575a6c94061b7235ca160350680",
            "messageResponseType": "ACCOUNT_STATEMENT",
            "clientCode": "123123123",
            "clientCountry": "GB",
            "messageCreatedTime": "2024-05-23T16:51:30.939+01:00",
            "bankCode": "LHVUK"
        },
        {
            "messageResponseId": "RESc8ea0a0a395c4f19b4eab32e8a8c0b04",
            "messageResponseType": "CREDIT_DEBIT_NOTIFICATION",
            "clientCode": "123123123",
            "clientCountry": "GB",
            "messageCreatedTime": "2024-05-23T16:54:13.477+01:00",
            "bankCode": "LHVUK"
        },
		....
        {
            "messageResponseId": "RESdf66d9bf1142439388f7ce47d3a02505",
            "messageRequestId": "REQb6057056347e47ef96729d76f265b292",
            "messageResponseType": "PAYMENT",
            "clientCode": "123123123",
            "clientCountry": "GB",
            "messageCreatedTime": "2024-05-24T07:42:07.538+01:00",
            "bankCode": "LHVUK"
        }
    ]
}

OK

Including Metadata info

{
    "pageNumber": 1,
    "pageSize": 100,
    "totalPages": 1,
    "totalElements": 2,
    "messages": [
        {
            "messageResponseId": "RESbca427c4ba9348558b3a3de5b57ab458",
            "messageRequestId": "REQ70cda19353504910812afe4fbf5c16f0",
            "messageResponseType": "HEARTBEAT",
            "messageCreatedTime": "2024-12-10T08:18:54.029+00:00",
            "bankCode": "LHVUK"
        },
        {
            "messageResponseId": "RESc7e74dba11624bad8918c27223bfdb41",
            "messageRequestId": "REQdbc9a823086c40f69d507f9fb875f851",
            "messageResponseType": "ACCOUNT_BALANCE",
            "messageCreatedTime": "2024-12-10T08:20:10.502+00:00",
            "bankCode": "LHVUK",
            "metadata": {
                "Reports": [
                    {
                        "Acct.Ccy": "GBP",
                        "Acct.IBAN": "GB98LHVB04031400001999"
                    }
                ]
            }
        }
    ]
}

OK

With includeProcessed=true parameter including also processed messages.

{
    "pageNumber": 1,
    "pageSize": 100,
    "totalPages": 6,
    "totalElements": 515,
    "messages": [
        {
            "messageResponseId": "RES39d1708ac07d4539ad4ba2da445dc5c7",
            "messageRequestId": "REQ9f4d04421b2c4aaf8d2cf05edd316b51",
            "messageResponseType": "ACCOUNT_BALANCE",
            "clientCode": "123123123",
            "clientCountry": "GB",
            "messageProcessed": true,
            "messageCreatedTime": "2024-06-24T12:04:02.791+01:00",
            "bankCode": "LHVUK"
        },
        {
            "messageResponseId": "RES73f3a32ac9614bef92bc10c528be014d",
            "messageRequestId": "REQb7de32f54fd44f188bf56b264e58a09e",
            "messageResponseType": "ACCOUNT_STATEMENT",
            "clientCode": "123123123",
            "clientCountry": "GB",
            "messageProcessed": true,
            "messageCreatedTime": "2024-06-24T12:04:04.591+01:00",
            "bankCode": "LHVUK"
        },
```

No content

Error code and description

<Errors>
    <Error>
        <ErrorCode>FORBIDDEN</ErrorCode>
        <Description>User doesn't exist</Description>
    </Error>
</Errors>

PreviousGet list of messagesNextGet message by response ID

Last updated 1 month ago

Was this helpful?

📖
📩