Maintenance: Added general VCR cassette BasicAuth mask handling for Freshdesk.

This commit is contained in:
Dominik Klein 2021-07-14 16:19:46 +00:00 committed by Thorsten Eckel
parent 7dda3cdaf9
commit ee62e47a87
9 changed files with 71 additions and 156 deletions

View file

@ -10,24 +10,11 @@ require 'rails_helper'
RSpec.describe 'Freshdesk import', type: :integration, use_vcr: true, db_strategy: :reset, required_envs: %w[IMPORT_FRESHDESK_ENDPOINT IMPORT_FRESHDESK_ENDPOINT_KEY IMPORT_FRESHDESK_ENDPOINT_SUBDOMAIN] do # rubocop:disable RSpec/DescribeClass RSpec.describe 'Freshdesk import', type: :integration, use_vcr: true, db_strategy: :reset, required_envs: %w[IMPORT_FRESHDESK_ENDPOINT IMPORT_FRESHDESK_ENDPOINT_KEY IMPORT_FRESHDESK_ENDPOINT_SUBDOMAIN] do # rubocop:disable RSpec/DescribeClass
before do before do
if !ENV['IMPORT_FRESHDESK_ENDPOINT']
raise "ERROR: Need IMPORT_FRESHDESK_ENDPOINT - hint IMPORT_FRESHDESK_ENDPOINT='https://example.freshdesk.com/api/v2'"
end
if !ENV['IMPORT_FRESHDESK_ENDPOINT_KEY']
raise "ERROR: Need IMPORT_FRESHDESK_ENDPOINT_KEY - hint IMPORT_FRESHDESK_ENDPOINT_KEY='01234567899876543210'"
end
Setting.set('import_freshdesk_endpoint', ENV['IMPORT_FRESHDESK_ENDPOINT']) Setting.set('import_freshdesk_endpoint', ENV['IMPORT_FRESHDESK_ENDPOINT'])
Setting.set('import_freshdesk_endpoint_key', ENV['IMPORT_FRESHDESK_ENDPOINT_KEY']) Setting.set('import_freshdesk_endpoint_key', ENV['IMPORT_FRESHDESK_ENDPOINT_KEY'])
Setting.set('import_mode', true) Setting.set('import_mode', true)
Setting.set('system_init_done', false) Setting.set('system_init_done', false)
VCR.configure do |c|
# The API key is used only inside the base64 encoded Basic Auth string, so mask that as well.
c.filter_sensitive_data('<IMPORT_FRESHDESK_ENDPOINT_BASIC_AUTH>') { Base64.encode64( "#{ENV['IMPORT_FRESHDESK_ENDPOINT_KEY']}:X" ).chomp }
end
VCR.use_cassette 'freshdesk_import' do VCR.use_cassette 'freshdesk_import' do
ImportJob.create(name: 'Import::Freshdesk').start ImportJob.create(name: 'Import::Freshdesk').start
end end

View file

@ -0,0 +1,6 @@
# Copyright (C) 2012-2021 Zammad Foundation, http://zammad-foundation.org/
# The API key is used only inside the base64 encoded Basic Auth string, so mask that as well.
VCR.configure do |c|
c.filter_sensitive_data('<IMPORT_FRESHDESK_ENDPOINT_BASIC_AUTH>') { Base64.encode64( "#{ENV['IMPORT_FRESHDESK_ENDPOINT_KEY']}:X" ).chomp }
end

View file

@ -21,7 +21,7 @@ http_interactions:
message: Unauthorized message: Unauthorized
headers: headers:
Date: Date:
- Fri, 02 Jul 2021 17:06:20 GMT - Thu, 08 Jul 2021 14:44:52 GMT
Content-Type: Content-Type:
- application/json; charset=utf-8 - application/json; charset=utf-8
Transfer-Encoding: Transfer-Encoding:
@ -31,7 +31,7 @@ http_interactions:
Status: Status:
- 401 Unauthorized - 401 Unauthorized
X-Request-Id: X-Request-Id:
- 2e63f677-9401-4c0f-be3b-09452148e5aa - 0ce1a277-88bd-4d52-9202-e7c40b92cb38
X-Freshdesk-Api-Version: X-Freshdesk-Api-Version:
- latest=v2; requested=v2 - latest=v2; requested=v2
X-Rack-Cache: X-Rack-Cache:
@ -55,16 +55,16 @@ http_interactions:
X-Ratelimit-Used-Currentrequest: X-Ratelimit-Used-Currentrequest:
- '1' - '1'
X-Envoy-Upstream-Service-Time: X-Envoy-Upstream-Service-Time:
- '33' - '31'
X-Trace-Id: X-Trace-Id:
- 00-145e8f2b02698d2ce2900f4f616e4988-3dedbca8f1ce26b7-00 - 00-51ed9c1c0a83b39abc54bc0c33cc642b-dc8bddd14d14bc03-00
Server: Server:
- fwe - fwe
body: body:
encoding: UTF-8 encoding: UTF-8
string: '{"code":"invalid_credentials","message":"You have to be logged in to string: '{"code":"invalid_credentials","message":"You have to be logged in to
perform this action."}' perform this action."}'
recorded_at: Fri, 02 Jul 2021 17:06:20 GMT recorded_at: Thu, 08 Jul 2021 14:44:52 GMT
- request: - request:
method: get method: get
uri: https://<IMPORT_FRESHDESK_ENDPOINT_SUBDOMAIN>.freshdesk.com/api/v2/agents/me uri: https://<IMPORT_FRESHDESK_ENDPOINT_SUBDOMAIN>.freshdesk.com/api/v2/agents/me
@ -90,7 +90,7 @@ http_interactions:
message: Unauthorized message: Unauthorized
headers: headers:
Date: Date:
- Fri, 02 Jul 2021 17:06:22 GMT - Thu, 08 Jul 2021 14:44:53 GMT
Content-Type: Content-Type:
- application/json; charset=utf-8 - application/json; charset=utf-8
Transfer-Encoding: Transfer-Encoding:
@ -100,7 +100,7 @@ http_interactions:
Status: Status:
- 401 Unauthorized - 401 Unauthorized
X-Request-Id: X-Request-Id:
- d42c365d-e4f9-4630-a854-fd9df3ccd492 - 5719108c-486f-40f0-9fdf-7caba98042f7
X-Freshdesk-Api-Version: X-Freshdesk-Api-Version:
- latest=v2; requested=v2 - latest=v2; requested=v2
X-Rack-Cache: X-Rack-Cache:
@ -124,16 +124,16 @@ http_interactions:
X-Ratelimit-Used-Currentrequest: X-Ratelimit-Used-Currentrequest:
- '1' - '1'
X-Envoy-Upstream-Service-Time: X-Envoy-Upstream-Service-Time:
- '30' - '39'
X-Trace-Id: X-Trace-Id:
- 00-23eaa754c0267bfd394c79555a57ab33-9419b7e2834dca13-00 - 00-5c35e85dfee04cac7f75d7ab33d64969-f8f94253325a913e-00
Server: Server:
- fwe - fwe
body: body:
encoding: UTF-8 encoding: UTF-8
string: '{"code":"invalid_credentials","message":"You have to be logged in to string: '{"code":"invalid_credentials","message":"You have to be logged in to
perform this action."}' perform this action."}'
recorded_at: Fri, 02 Jul 2021 17:06:22 GMT recorded_at: Thu, 08 Jul 2021 14:44:53 GMT
- request: - request:
method: get method: get
uri: https://<IMPORT_FRESHDESK_ENDPOINT_SUBDOMAIN>.freshdesk.com/api/v2/agents/me uri: https://<IMPORT_FRESHDESK_ENDPOINT_SUBDOMAIN>.freshdesk.com/api/v2/agents/me
@ -159,7 +159,7 @@ http_interactions:
message: Unauthorized message: Unauthorized
headers: headers:
Date: Date:
- Fri, 02 Jul 2021 17:06:22 GMT - Thu, 08 Jul 2021 14:44:53 GMT
Content-Type: Content-Type:
- application/json; charset=utf-8 - application/json; charset=utf-8
Transfer-Encoding: Transfer-Encoding:
@ -169,7 +169,7 @@ http_interactions:
Status: Status:
- 401 Unauthorized - 401 Unauthorized
X-Request-Id: X-Request-Id:
- c1a30c87-f725-40bf-b5af-1f35408ab1b7 - ca94e08c-04a5-44ad-837e-7dd0cb693fd9
X-Freshdesk-Api-Version: X-Freshdesk-Api-Version:
- latest=v2; requested=v2 - latest=v2; requested=v2
X-Rack-Cache: X-Rack-Cache:
@ -193,14 +193,14 @@ http_interactions:
X-Ratelimit-Used-Currentrequest: X-Ratelimit-Used-Currentrequest:
- '1' - '1'
X-Envoy-Upstream-Service-Time: X-Envoy-Upstream-Service-Time:
- '38' - '75'
X-Trace-Id: X-Trace-Id:
- 00-6fb57292c47b89dcf35159f5bf216f66-43bb559927582d60-00 - 00-3ed5efb5331d9b0e6cfd35a96da0e7ca-7a1106d2c14516ba-00
Server: Server:
- fwe - fwe
body: body:
encoding: UTF-8 encoding: UTF-8
string: '{"code":"invalid_credentials","message":"You have to be logged in to string: '{"code":"invalid_credentials","message":"You have to be logged in to
perform this action."}' perform this action."}'
recorded_at: Fri, 02 Jul 2021 17:06:22 GMT recorded_at: Thu, 08 Jul 2021 14:44:53 GMT
recorded_with: VCR 6.0.0 recorded_with: VCR 6.0.0

View file

@ -21,7 +21,7 @@ http_interactions:
message: Not Found message: Not Found
headers: headers:
Date: Date:
- Fri, 02 Jul 2021 17:06:16 GMT - Thu, 08 Jul 2021 14:44:47 GMT
Content-Type: Content-Type:
- application/json; charset=utf-8 - application/json; charset=utf-8
Transfer-Encoding: Transfer-Encoding:
@ -31,7 +31,7 @@ http_interactions:
Status: Status:
- 404 Not Found - 404 Not Found
X-Request-Id: X-Request-Id:
- 200f4a46-412a-4e8a-b417-2639ef0c7dfe - edf9bb99-1c3c-48df-875e-455cbd963c52
X-Rack-Cache: X-Rack-Cache:
- miss - miss
Cache-Control: Cache-Control:
@ -45,13 +45,13 @@ http_interactions:
X-Fw-Ratelimiting-Managed: X-Fw-Ratelimiting-Managed:
- 'false' - 'false'
X-Envoy-Upstream-Service-Time: X-Envoy-Upstream-Service-Time:
- '902' - '29'
X-Trace-Id: X-Trace-Id:
- 00-616a357299270485862d4b040120e5ef-32eb6e8fbf69042e-00 - 00-e50f39ffa8d89a7ab2f260463b10436e-4d93e6d797831b87-00
Server: Server:
- fwe - fwe
body: body:
encoding: ASCII-8BIT encoding: ASCII-8BIT
string: " " string: " "
recorded_at: Fri, 02 Jul 2021 17:06:16 GMT recorded_at: Thu, 08 Jul 2021 14:44:47 GMT
recorded_with: VCR 6.0.0 recorded_with: VCR 6.0.0

View file

@ -21,7 +21,7 @@ http_interactions:
message: Unauthorized message: Unauthorized
headers: headers:
Date: Date:
- Fri, 02 Jul 2021 17:06:27 GMT - Thu, 08 Jul 2021 14:44:59 GMT
Content-Type: Content-Type:
- application/json; charset=utf-8 - application/json; charset=utf-8
Transfer-Encoding: Transfer-Encoding:
@ -31,7 +31,7 @@ http_interactions:
Status: Status:
- 401 Unauthorized - 401 Unauthorized
X-Request-Id: X-Request-Id:
- 88e25c54-4030-47ae-b722-18b422c28fc8 - 23514661-1b1e-4794-af85-4258cd13df06
X-Freshdesk-Api-Version: X-Freshdesk-Api-Version:
- latest=v2; requested=v2 - latest=v2; requested=v2
X-Rack-Cache: X-Rack-Cache:
@ -55,16 +55,16 @@ http_interactions:
X-Ratelimit-Used-Currentrequest: X-Ratelimit-Used-Currentrequest:
- '1' - '1'
X-Envoy-Upstream-Service-Time: X-Envoy-Upstream-Service-Time:
- '31' - '36'
X-Trace-Id: X-Trace-Id:
- 00-1c1f649281457de1806d4886dab13c2f-6b61ac894a9f055d-00 - 00-1369aa8348250d3161f7be598ec434f4-2966dbe53b8eae9f-00
Server: Server:
- fwe - fwe
body: body:
encoding: UTF-8 encoding: UTF-8
string: '{"code":"invalid_credentials","message":"You have to be logged in to string: '{"code":"invalid_credentials","message":"You have to be logged in to
perform this action."}' perform this action."}'
recorded_at: Fri, 02 Jul 2021 17:06:27 GMT recorded_at: Thu, 08 Jul 2021 14:44:59 GMT
- request: - request:
method: get method: get
uri: https://<IMPORT_FRESHDESK_ENDPOINT_SUBDOMAIN>.freshdesk.com/api/v2/agents/me uri: https://<IMPORT_FRESHDESK_ENDPOINT_SUBDOMAIN>.freshdesk.com/api/v2/agents/me
@ -83,14 +83,14 @@ http_interactions:
Host: Host:
- "<IMPORT_FRESHDESK_ENDPOINT_SUBDOMAIN>.freshdesk.com" - "<IMPORT_FRESHDESK_ENDPOINT_SUBDOMAIN>.freshdesk.com"
Authorization: Authorization:
- Basic MWlPRmFiVjFYc1kwZ3h0eU9ud1E6WA== - Basic <IMPORT_FRESHDESK_ENDPOINT_BASIC_AUTH>
response: response:
status: status:
code: 200 code: 200
message: OK message: OK
headers: headers:
Date: Date:
- Fri, 02 Jul 2021 17:06:28 GMT - Thu, 08 Jul 2021 14:45:01 GMT
Content-Type: Content-Type:
- application/json; charset=utf-8 - application/json; charset=utf-8
Transfer-Encoding: Transfer-Encoding:
@ -102,7 +102,7 @@ http_interactions:
Pragma: Pragma:
- no-cache - no-cache
X-Request-Id: X-Request-Id:
- 89c1b015-7196-4436-85c6-e0c69124366d - d5ab60cd-84d3-4816-8a52-01410cb3c82f
X-Freshdesk-Api-Version: X-Freshdesk-Api-Version:
- latest=v2; requested=v2 - latest=v2; requested=v2
X-Rack-Cache: X-Rack-Cache:
@ -118,7 +118,7 @@ http_interactions:
Expires: Expires:
- Wed, 13 Oct 2010 00:00:00 UTC - Wed, 13 Oct 2010 00:00:00 UTC
Set-Cookie: Set-Cookie:
- _helpkit_session=BAh7B0kiD3Nlc3Npb25faWQGOgZFVEkiJTAyYTU2MTY3NTIwMzNkZWI4YzRhNjc3NDVhNTIwODk1BjsAVEkiEF9jc3JmX3Rva2VuBjsARkkiMXZiMktSb2tVZUFiZFNMd01tdDh4QmZrYytrQyttbUZta2Q4MmRxUis5aWs9BjsARg%3D%3D--f0265d3ae3abd09d70b9a795e42cd4904caa4e47; - _helpkit_session=BAh7B0kiD3Nlc3Npb25faWQGOgZFVEkiJTQ0MjMyNGNkZWQ3YjhjZDE5ZTU2YWI5ZWFiZmYwYWRmBjsAVEkiEF9jc3JmX3Rva2VuBjsARkkiMVFnWXQveElsdWNnY2RaR3NiOXAwRWVjbU1EZk9ISWFPYlJpYXNCaEgyQUk9BjsARg%3D%3D--7c926b47ede8867f6c888c5df8a516fea8b1be9a;
path=/; HttpOnly; secure path=/; HttpOnly; secure
- _x_w=5_2; path=/; HttpOnly; secure - _x_w=5_2; path=/; HttpOnly; secure
X-Fw-Ratelimiting-Managed: X-Fw-Ratelimiting-Managed:
@ -130,14 +130,14 @@ http_interactions:
X-Ratelimit-Used-Currentrequest: X-Ratelimit-Used-Currentrequest:
- '1' - '1'
X-Envoy-Upstream-Service-Time: X-Envoy-Upstream-Service-Time:
- '63' - '51'
X-Trace-Id: X-Trace-Id:
- 00-d3cdc65ae441713e724c94001ed3bbe9-9e4b391525ebb2d3-00 - 00-1907904008abae8ffb674d4d6e17d131-f421d789c393542e-00
Server: Server:
- fwe - fwe
body: body:
encoding: ASCII-8BIT encoding: ASCII-8BIT
string: '{"available":false,"occasional":false,"id":80014400475,"ticket_scope":1,"signature":null,"group_ids":[],"role_ids":[80000198826],"skill_ids":[],"available_since":null,"contact":{"active":true,"email":"info@<IMPORT_FRESHDESK_ENDPOINT_SUBDOMAIN>.org","job_title":null,"language":"en","mobile":null,"name":"Thorsten string: '{"available":false,"occasional":false,"id":80014400475,"ticket_scope":1,"signature":null,"group_ids":[],"role_ids":[80000198826],"skill_ids":[],"available_since":null,"contact":{"active":true,"email":"info@<IMPORT_FRESHDESK_ENDPOINT_SUBDOMAIN>.org","job_title":null,"language":"en","mobile":null,"name":"Thorsten
Eckel","phone":null,"time_zone":"Eastern Time (US & Canada)","created_at":"2021-04-09T13:23:58Z","updated_at":"2021-04-09T13:31:00Z","last_login_at":"2021-06-04T06:55:46Z"},"created_at":"2021-04-09T13:23:58Z","updated_at":"2021-06-08T09:56:50Z","type":"support_agent"}' Eckel","phone":null,"time_zone":"Eastern Time (US & Canada)","created_at":"2021-04-09T13:23:58Z","updated_at":"2021-04-09T13:31:00Z","last_login_at":"2021-06-07T05:38:22Z"},"created_at":"2021-04-09T13:23:58Z","updated_at":"2021-07-08T07:08:47Z","type":"support_agent"}'
recorded_at: Fri, 02 Jul 2021 17:06:28 GMT recorded_at: Thu, 08 Jul 2021 14:45:01 GMT
recorded_with: VCR 6.0.0 recorded_with: VCR 6.0.0

View file

@ -21,7 +21,7 @@ http_interactions:
message: Unauthorized message: Unauthorized
headers: headers:
Date: Date:
- Fri, 02 Jul 2021 17:06:23 GMT - Thu, 08 Jul 2021 14:44:55 GMT
Content-Type: Content-Type:
- application/json; charset=utf-8 - application/json; charset=utf-8
Transfer-Encoding: Transfer-Encoding:
@ -31,7 +31,7 @@ http_interactions:
Status: Status:
- 401 Unauthorized - 401 Unauthorized
X-Request-Id: X-Request-Id:
- 262fe662-8486-4316-b974-df293f704f50 - 7902d2cc-0bee-4f7c-9422-0a803602306b
X-Freshdesk-Api-Version: X-Freshdesk-Api-Version:
- latest=v2; requested=v2 - latest=v2; requested=v2
X-Rack-Cache: X-Rack-Cache:
@ -55,16 +55,16 @@ http_interactions:
X-Ratelimit-Used-Currentrequest: X-Ratelimit-Used-Currentrequest:
- '1' - '1'
X-Envoy-Upstream-Service-Time: X-Envoy-Upstream-Service-Time:
- '36' - '44'
X-Trace-Id: X-Trace-Id:
- 00-4f440d7bb5e7f826dfbd5dc01a8fa92d-f4b5245d48142109-00 - 00-bf646768b4fb3bbf4733ab1d89f9cc65-d5c0ee890610da12-00
Server: Server:
- fwe - fwe
body: body:
encoding: UTF-8 encoding: UTF-8
string: '{"code":"invalid_credentials","message":"You have to be logged in to string: '{"code":"invalid_credentials","message":"You have to be logged in to
perform this action."}' perform this action."}'
recorded_at: Fri, 02 Jul 2021 17:06:23 GMT recorded_at: Thu, 08 Jul 2021 14:44:55 GMT
- request: - request:
method: get method: get
uri: https://<IMPORT_FRESHDESK_ENDPOINT_SUBDOMAIN>.freshdesk.com/api/v2/agents/me uri: https://<IMPORT_FRESHDESK_ENDPOINT_SUBDOMAIN>.freshdesk.com/api/v2/agents/me
@ -90,7 +90,7 @@ http_interactions:
message: Unauthorized message: Unauthorized
headers: headers:
Date: Date:
- Fri, 02 Jul 2021 17:06:25 GMT - Thu, 08 Jul 2021 14:44:57 GMT
Content-Type: Content-Type:
- application/json; charset=utf-8 - application/json; charset=utf-8
Transfer-Encoding: Transfer-Encoding:
@ -100,7 +100,7 @@ http_interactions:
Status: Status:
- 401 Unauthorized - 401 Unauthorized
X-Request-Id: X-Request-Id:
- 7e415a16-de0a-4b75-a116-828e5bcaf9fc - 8007c6d5-96f0-9608-9571-59cad9b5d205
X-Freshdesk-Api-Version: X-Freshdesk-Api-Version:
- latest=v2; requested=v2 - latest=v2; requested=v2
X-Rack-Cache: X-Rack-Cache:
@ -124,16 +124,16 @@ http_interactions:
X-Ratelimit-Used-Currentrequest: X-Ratelimit-Used-Currentrequest:
- '1' - '1'
X-Envoy-Upstream-Service-Time: X-Envoy-Upstream-Service-Time:
- '39' - '36'
X-Trace-Id: X-Trace-Id:
- 00-ad29ebb187bd9fa578b0a5fce0d1e5f3-731e1b5906db477a-00 - 00-3740e89fc64ccd0a3b92ed13203aeaf7-e34c3c1b71452bba-01
Server: Server:
- fwe - fwe
body: body:
encoding: UTF-8 encoding: UTF-8
string: '{"code":"invalid_credentials","message":"You have to be logged in to string: '{"code":"invalid_credentials","message":"You have to be logged in to
perform this action."}' perform this action."}'
recorded_at: Fri, 02 Jul 2021 17:06:25 GMT recorded_at: Thu, 08 Jul 2021 14:44:57 GMT
- request: - request:
method: get method: get
uri: https://<IMPORT_FRESHDESK_ENDPOINT_SUBDOMAIN>.freshdesk.com/api/v2/agents/me uri: https://<IMPORT_FRESHDESK_ENDPOINT_SUBDOMAIN>.freshdesk.com/api/v2/agents/me
@ -159,7 +159,7 @@ http_interactions:
message: Unauthorized message: Unauthorized
headers: headers:
Date: Date:
- Fri, 02 Jul 2021 17:06:25 GMT - Thu, 08 Jul 2021 14:44:57 GMT
Content-Type: Content-Type:
- application/json; charset=utf-8 - application/json; charset=utf-8
Transfer-Encoding: Transfer-Encoding:
@ -169,7 +169,7 @@ http_interactions:
Status: Status:
- 401 Unauthorized - 401 Unauthorized
X-Request-Id: X-Request-Id:
- daa1345a-5ddb-4fc5-8d5c-9e0aca066592 - 0b8d8dee-e471-40db-ae98-962331e21405
X-Freshdesk-Api-Version: X-Freshdesk-Api-Version:
- latest=v2; requested=v2 - latest=v2; requested=v2
X-Rack-Cache: X-Rack-Cache:
@ -193,14 +193,14 @@ http_interactions:
X-Ratelimit-Used-Currentrequest: X-Ratelimit-Used-Currentrequest:
- '1' - '1'
X-Envoy-Upstream-Service-Time: X-Envoy-Upstream-Service-Time:
- '34' - '78'
X-Trace-Id: X-Trace-Id:
- 00-ccc686cbe819b7f7fa128656364bdcdb-9b4e5cab85db1987-00 - 00-02cfc4ead37ab53768d74f2055525b82-acaa880886cf4572-00
Server: Server:
- fwe - fwe
body: body:
encoding: UTF-8 encoding: UTF-8
string: '{"code":"invalid_credentials","message":"You have to be logged in to string: '{"code":"invalid_credentials","message":"You have to be logged in to
perform this action."}' perform this action."}'
recorded_at: Fri, 02 Jul 2021 17:06:25 GMT recorded_at: Thu, 08 Jul 2021 14:44:57 GMT
recorded_with: VCR 6.0.0 recorded_with: VCR 6.0.0

View file

@ -21,7 +21,7 @@ http_interactions:
message: Not Found message: Not Found
headers: headers:
Date: Date:
- Fri, 02 Jul 2021 17:06:18 GMT - Thu, 08 Jul 2021 14:44:49 GMT
Content-Type: Content-Type:
- application/json; charset=utf-8 - application/json; charset=utf-8
Transfer-Encoding: Transfer-Encoding:
@ -31,7 +31,7 @@ http_interactions:
Status: Status:
- 404 Not Found - 404 Not Found
X-Request-Id: X-Request-Id:
- ea835512-a5f9-4872-bcf0-102168c453a6 - 0331764a-f490-4d1c-a2ca-474b7c7d3b25
X-Rack-Cache: X-Rack-Cache:
- miss - miss
Cache-Control: Cache-Control:
@ -47,11 +47,11 @@ http_interactions:
X-Envoy-Upstream-Service-Time: X-Envoy-Upstream-Service-Time:
- '31' - '31'
X-Trace-Id: X-Trace-Id:
- 00-4aeca9c6614c654f313a692679670477-54a60f5fbd984c56-00 - 00-03bc675e6fd9c1676c45ca67aef06828-1fe725684acee4f8-00
Server: Server:
- fwe - fwe
body: body:
encoding: ASCII-8BIT encoding: ASCII-8BIT
string: " " string: " "
recorded_at: Fri, 02 Jul 2021 17:06:18 GMT recorded_at: Thu, 08 Jul 2021 14:44:50 GMT
recorded_with: VCR 6.0.0 recorded_with: VCR 6.0.0

View file

@ -1,78 +0,0 @@
---
http_interactions:
- request:
method: get
uri: https://<IMPORT_FRESHDESK_ENDPOINT_SUBDOMAIN>.freshdesk.com/api/v2/agents/me
body:
encoding: US-ASCII
string: ''
headers:
Content-Type:
- application/json
Accept-Encoding:
- gzip;q=1.0,deflate;q=0.6,identity;q=0.3
Accept:
- "*/*"
User-Agent:
- Ruby
Host:
- "<IMPORT_FRESHDESK_ENDPOINT_SUBDOMAIN>.freshdesk.com"
Authorization:
- Basic MWlPRmFiVjFYc1kwZ3h0eU9ud1E6WA==
response:
status:
code: 200
message: OK
headers:
Date:
- Sat, 03 Jul 2021 06:18:11 GMT
Content-Type:
- application/json; charset=utf-8
Transfer-Encoding:
- chunked
Connection:
- keep-alive
Status:
- 200 OK
Pragma:
- no-cache
X-Request-Id:
- 4e07257c-5b3a-4a2b-8c32-17f7088aa701
X-Freshdesk-Api-Version:
- latest=v2; requested=v2
X-Rack-Cache:
- miss
Cache-Control:
- must-revalidate, no-cache, no-store, private, max-age=0
X-Xss-Protection:
- 1; mode=block
X-Ua-Compatible:
- IE=Edge,chrome=1
X-Content-Type-Options:
- nosniff
Expires:
- Wed, 13 Oct 2010 00:00:00 UTC
Set-Cookie:
- _helpkit_session=BAh7B0kiD3Nlc3Npb25faWQGOgZFVEkiJWRiNWJjYjE2MjJhNjYzODY5NTZjMDY1OWEwOTI0ODZjBjsAVEkiEF9jc3JmX3Rva2VuBjsARkkiMUJ1clZXWU42c0pQb21BdytWQUFWczVwb2pHZXdvckNYQVZuTEVFaDE0U0E9BjsARg%3D%3D--98cd298564a0bfe7396d38be08f58ed98127adad;
path=/; HttpOnly; secure
- _x_w=5_2; path=/; HttpOnly; secure
X-Fw-Ratelimiting-Managed:
- 'true'
X-Ratelimit-Total:
- '100'
X-Ratelimit-Remaining:
- '99'
X-Ratelimit-Used-Currentrequest:
- '1'
X-Envoy-Upstream-Service-Time:
- '45'
X-Trace-Id:
- 00-f906ee496f5f50e1c8766cb5323ad55f-2a5d9f13ea92af0d-00
Server:
- fwe
body:
encoding: ASCII-8BIT
string: '{"available":false,"occasional":false,"id":80014400475,"ticket_scope":1,"signature":null,"group_ids":[],"role_ids":[80000198826],"skill_ids":[],"available_since":null,"contact":{"active":true,"email":"info@<IMPORT_FRESHDESK_ENDPOINT_SUBDOMAIN>.org","job_title":null,"language":"en","mobile":null,"name":"Thorsten
Eckel","phone":null,"time_zone":"Eastern Time (US & Canada)","created_at":"2021-04-09T13:23:58Z","updated_at":"2021-04-09T13:31:00Z","last_login_at":"2021-06-04T06:55:46Z"},"created_at":"2021-04-09T13:23:58Z","updated_at":"2021-06-08T09:56:50Z","type":"support_agent"}'
recorded_at: Sat, 03 Jul 2021 06:18:12 GMT
recorded_with: VCR 6.0.0

View file

@ -21,7 +21,7 @@ http_interactions:
message: Unauthorized message: Unauthorized
headers: headers:
Date: Date:
- Fri, 02 Jul 2021 17:06:30 GMT - Thu, 08 Jul 2021 14:45:03 GMT
Content-Type: Content-Type:
- application/json; charset=utf-8 - application/json; charset=utf-8
Transfer-Encoding: Transfer-Encoding:
@ -31,7 +31,7 @@ http_interactions:
Status: Status:
- 401 Unauthorized - 401 Unauthorized
X-Request-Id: X-Request-Id:
- 66aac436-9efb-4643-a8ca-e4250e5ba347 - 16535d28-0fa9-4bbd-81a5-7734a134dbe6
X-Freshdesk-Api-Version: X-Freshdesk-Api-Version:
- latest=v2; requested=v2 - latest=v2; requested=v2
X-Rack-Cache: X-Rack-Cache:
@ -55,16 +55,16 @@ http_interactions:
X-Ratelimit-Used-Currentrequest: X-Ratelimit-Used-Currentrequest:
- '1' - '1'
X-Envoy-Upstream-Service-Time: X-Envoy-Upstream-Service-Time:
- '30' - '226'
X-Trace-Id: X-Trace-Id:
- 00-88a9c09bf2c30bcef8eea4f252e63c6b-0b6c0658c2370f17-00 - 00-cfd704f35e647fd26907025f0d0227db-0078eeaf66759491-00
Server: Server:
- fwe - fwe
body: body:
encoding: UTF-8 encoding: UTF-8
string: '{"code":"invalid_credentials","message":"You have to be logged in to string: '{"code":"invalid_credentials","message":"You have to be logged in to
perform this action."}' perform this action."}'
recorded_at: Fri, 02 Jul 2021 17:06:30 GMT recorded_at: Thu, 08 Jul 2021 14:45:03 GMT
- request: - request:
method: get method: get
uri: https://<IMPORT_FRESHDESK_ENDPOINT_SUBDOMAIN>.freshdesk.com/api/v2/agents/me uri: https://<IMPORT_FRESHDESK_ENDPOINT_SUBDOMAIN>.freshdesk.com/api/v2/agents/me
@ -83,14 +83,14 @@ http_interactions:
Host: Host:
- "<IMPORT_FRESHDESK_ENDPOINT_SUBDOMAIN>.freshdesk.com" - "<IMPORT_FRESHDESK_ENDPOINT_SUBDOMAIN>.freshdesk.com"
Authorization: Authorization:
- Basic MWlPRmFiVjFYc1kwZ3h0eU9ud1E6WA== - Basic <IMPORT_FRESHDESK_ENDPOINT_BASIC_AUTH>
response: response:
status: status:
code: 200 code: 200
message: OK message: OK
headers: headers:
Date: Date:
- Fri, 02 Jul 2021 17:06:32 GMT - Thu, 08 Jul 2021 14:45:04 GMT
Content-Type: Content-Type:
- application/json; charset=utf-8 - application/json; charset=utf-8
Transfer-Encoding: Transfer-Encoding:
@ -102,7 +102,7 @@ http_interactions:
Pragma: Pragma:
- no-cache - no-cache
X-Request-Id: X-Request-Id:
- '096094d7-b196-941f-bbe3-22acc2b2bbe1' - 3613fc6e-8364-44f1-b5ae-e4b92c4f17b6
X-Freshdesk-Api-Version: X-Freshdesk-Api-Version:
- latest=v2; requested=v2 - latest=v2; requested=v2
X-Rack-Cache: X-Rack-Cache:
@ -118,7 +118,7 @@ http_interactions:
Expires: Expires:
- Wed, 13 Oct 2010 00:00:00 UTC - Wed, 13 Oct 2010 00:00:00 UTC
Set-Cookie: Set-Cookie:
- _helpkit_session=BAh7B0kiD3Nlc3Npb25faWQGOgZFVEkiJTdkNzE4MWMzYjQzMjMxNTYzZTFhN2Y5MTE3ZjM2MjQ5BjsAVEkiEF9jc3JmX3Rva2VuBjsARkkiMXorVFhHeEY1YU5VcW5xZjBaaE9BTllMZTM5azdHL3ZZTmphQkpXWVJhWEE9BjsARg%3D%3D--9f8399eb8b8434c862f21cfd38da18f3479ca5be; - _helpkit_session=BAh7B0kiD3Nlc3Npb25faWQGOgZFVEkiJTNmMDYxMzM4YmI1MGE3NjdhMWM5YjMxODJjMDJiYjQ1BjsAVEkiEF9jc3JmX3Rva2VuBjsARkkiMU9rVTAybEdLVmVCc2ZXaGpERThtNHYyeERURHVrRllZYnRJT3ZkQnN4MHc9BjsARg%3D%3D--362eaa4142cd23acdd978a5d43af16884701199e;
path=/; HttpOnly; secure path=/; HttpOnly; secure
- _x_w=5_2; path=/; HttpOnly; secure - _x_w=5_2; path=/; HttpOnly; secure
X-Fw-Ratelimiting-Managed: X-Fw-Ratelimiting-Managed:
@ -130,14 +130,14 @@ http_interactions:
X-Ratelimit-Used-Currentrequest: X-Ratelimit-Used-Currentrequest:
- '1' - '1'
X-Envoy-Upstream-Service-Time: X-Envoy-Upstream-Service-Time:
- '62' - '71'
X-Trace-Id: X-Trace-Id:
- 00-42555d29af204cf817095f7d2dce5178-00cb4ebcca7ebfe1-01 - 00-0b4df5d88358f783274f4e709f735c1b-f919d65b8eb09b19-00
Server: Server:
- fwe - fwe
body: body:
encoding: ASCII-8BIT encoding: ASCII-8BIT
string: '{"available":false,"occasional":false,"id":80014400475,"ticket_scope":1,"signature":null,"group_ids":[],"role_ids":[80000198826],"skill_ids":[],"available_since":null,"contact":{"active":true,"email":"info@<IMPORT_FRESHDESK_ENDPOINT_SUBDOMAIN>.org","job_title":null,"language":"en","mobile":null,"name":"Thorsten string: '{"available":false,"occasional":false,"id":80014400475,"ticket_scope":1,"signature":null,"group_ids":[],"role_ids":[80000198826],"skill_ids":[],"available_since":null,"contact":{"active":true,"email":"info@<IMPORT_FRESHDESK_ENDPOINT_SUBDOMAIN>.org","job_title":null,"language":"en","mobile":null,"name":"Thorsten
Eckel","phone":null,"time_zone":"Eastern Time (US & Canada)","created_at":"2021-04-09T13:23:58Z","updated_at":"2021-04-09T13:31:00Z","last_login_at":"2021-06-04T06:55:46Z"},"created_at":"2021-04-09T13:23:58Z","updated_at":"2021-06-08T09:56:50Z","type":"support_agent"}' Eckel","phone":null,"time_zone":"Eastern Time (US & Canada)","created_at":"2021-04-09T13:23:58Z","updated_at":"2021-04-09T13:31:00Z","last_login_at":"2021-06-07T05:38:22Z"},"created_at":"2021-04-09T13:23:58Z","updated_at":"2021-07-08T07:08:47Z","type":"support_agent"}'
recorded_at: Fri, 02 Jul 2021 17:06:32 GMT recorded_at: Thu, 08 Jul 2021 14:45:04 GMT
recorded_with: VCR 6.0.0 recorded_with: VCR 6.0.0