From 29d80936878347ff86d76b157088d4a80c6dbd17 Mon Sep 17 00:00:00 2001 From: moklokov Date: Wed, 19 Jun 2024 16:58:05 +0300 Subject: [PATCH] Add keap api key to call headers --- lib/infusionsoft/connection.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/infusionsoft/connection.rb b/lib/infusionsoft/connection.rb index a73552e..31d87d5 100755 --- a/lib/infusionsoft/connection.rb +++ b/lib/infusionsoft/connection.rb @@ -14,7 +14,7 @@ def connection(service_call, *args) 'port' => 443, 'use_ssl' => true }) - client.http_header_extra = {'User-Agent' => user_agent} + client.http_header_extra = {'User-Agent' => user_agent, 'X-Keap-API-Key' => api_key} begin api_logger.info "CALL: #{service_call} api_url: #{api_url} at:#{Time.now} args:#{args.inspect}" result = client.call("#{service_call}", api_key, *args)