Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Adding a listener #166

Open
emielhagen opened this issue Nov 1, 2023 · 0 comments
Open

Adding a listener #166

emielhagen opened this issue Nov 1, 2023 · 0 comments
Assignees

Comments

@emielhagen
Copy link

Hi,

Would you consider adding the possibility to configure the Mollie client with a listener, which can be used for e.g. logging? For me it would be useful to be able to log URI, request and response with our own logger.

For example something like

Mollie::Client.configure do |config|
  config.listener = ->(uri, request, response) do
    OurLogger.log(
      'MollieApiRequest',
      hash: {
        uri:,
        request:,
        response:,
      },
    )
  end
@justincase justincase self-assigned this Nov 11, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants