Drupal is a registered trademark of Dries Buytaert
Protected Pages 3.0.0 Major update available for module protected_pages (3.0.0). Commerce Core 3.3.8 Minor update available for module commerce (3.3.8). Search API HTML Element Filter 1.0.7 Minor update available for module search_api_html_element_filter (1.0.7). Layout Builder Reorder 2.0.1 Minor update available for module layout_builder_reorder (2.0.1). Ban 1.1.0 Minor update available for module ban (1.1.0). Field Formatter Range 2.0.0 Major update available for module field_formatter_range (2.0.0). Field Formatter Range 8.x-1.8 Minor update available for module field_formatter_range (8.x-1.8). Varbase Media Header 9.2.1 Minor update available for module varbase_media_header (9.2.1). Search API Solr 4.3.11 Module search_api_solr updated after 14 months of inactivity (4.3.11). Provus Mega Menu Module provus_mega_menu crossed 1,000 active installs.

Http Client Logs

123 sites Security covered
View on drupal.org

This module logs all outgoing HTTP requests and responses made by Drupal's core HTTP client to the database. It provides a user interface for managing and viewing these logs, allowing for easy tracking of external communications.

Log all drupal core http_client request & response logs in database. So we can easily track the outgoing request made by \Drupal::httpClient().

Features:
1. This module logs all the request and response data made by drupal core \Drupal::httpClient();.
2. provide UI to manage the logs, for example: filter, view details etc.

How to use:
1. composer require drupal/http_client_log
2. drush en -y http_client_log
3. using below code to start request.

use Drupal\Component\Serialization\Json;
$base_url = "https://httpbin.org";
$client = \Drupal::httpClient();

$response = $client->get($base_url . '/get');
$data = Json::Decode($response->getBody());
dpm($data);

$response = $client->get($base_url . '/anything', [
  'headers' => [
    'accept' => 'application/json'
  ],
]);
$data = Json::decode($response->getBody());
dpm($data);

$response = $client->post($base_url . '/status/500', [
  'verify' => true,
  'headers' => [
    'accept' => 'text/plain'
  ],
]);
$data = $response->getBody()->getContents();
dpm($data);

4. visit "/admin/reports/http-client-log"

Activity

Total releases
3
First release
Dec 2024
Latest release
1 month ago
Releases (12 mo)
2 ▲ from 1
Maintenance
Active

Release Timeline

Releases

Version Type Release date
1.2.1 Stable May 21, 2026
1.2.x-dev Dev Sep 10, 2025
1.2.0 Stable Dec 9, 2024