@adobe/spacecat-shared-http-utils 1.6.4 → 1.6.5

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md CHANGED
@@ -1,3 +1,10 @@
1
+ # [@adobe/spacecat-shared-http-utils-v1.6.5](https://github.com/adobe/spacecat-shared/compare/@adobe/spacecat-shared-http-utils-v1.6.4...@adobe/spacecat-shared-http-utils-v1.6.5) (2024-08-16)
2
+
3
+
4
+ ### Bug Fixes
5
+
6
+ * add more debug logs ([#331](https://github.com/adobe/spacecat-shared/issues/331)) ([7268589](https://github.com/adobe/spacecat-shared/commit/726858966f6a74fad91a2eafa5fbf333b72d78cd))
7
+
1
8
  # [@adobe/spacecat-shared-http-utils-v1.6.4](https://github.com/adobe/spacecat-shared/compare/@adobe/spacecat-shared-http-utils-v1.6.3...@adobe/spacecat-shared-http-utils-v1.6.4) (2024-08-16)
2
9
 
3
10
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@adobe/spacecat-shared-http-utils",
3
- "version": "1.6.4",
3
+ "version": "1.6.5",
4
4
  "description": "Shared modules of the Spacecat Services - HTTP Utils",
5
5
  "type": "module",
6
6
  "main": "src/index.js",
@@ -29,12 +29,14 @@ export default class ScopedApiKeyHandler extends AbstractHandler {
29
29
  if (!dataAccess) {
30
30
  throw new Error('Data access is required');
31
31
  }
32
+ this.log('Checking for API key in the request headers', 'debug');
32
33
 
33
34
  const apiKeyFromHeader = headers['x-api-key'];
34
35
  if (!hasText(apiKeyFromHeader)) {
35
36
  return null;
36
37
  }
37
38
 
39
+ this.log(`Checking for API key: ${apiKeyFromHeader}`, 'debug');
38
40
  // Keys are stored by their hash, so we need to hash the key to look it up
39
41
  const hashedApiKey = hashWithSHA256(apiKeyFromHeader);
40
42
  this.log(`Checking for API key with hash: ${hashedApiKey}`, 'debug');