From 8310489cc4f8fb6db7dee3606c09d5d7c2b52df5 Mon Sep 17 00:00:00 2001 From: Britta Stallknecht Date: Mon, 25 Aug 2025 13:01:53 +0000 Subject: [PATCH 1/5] feat: valid placeholders for API keys to increase convenience --- _docs_integrate/examples/example.config.json | 2 +- _docs_integrate/migration-from-v6-to-v7.md | 2 +- _docs_operate/configuration.md | 8 ++++---- _docs_operate/setup-with-docker-compose.md | 2 +- 4 files changed, 7 insertions(+), 7 deletions(-) diff --git a/_docs_integrate/examples/example.config.json b/_docs_integrate/examples/example.config.json index ad0a30b2a..5912859b9 100644 --- a/_docs_integrate/examples/example.config.json +++ b/_docs_integrate/examples/example.config.json @@ -14,7 +14,7 @@ "apiKey": { "keys": { "": { - "key": " https://enmeshed.eu/operate/configuration#httpserver>" + "key": " https://enmeshed.eu/operate/configuration#apikey>" } } } diff --git a/_docs_integrate/migration-from-v6-to-v7.md b/_docs_integrate/migration-from-v6-to-v7.md index ccf62e9d3..4b4b547b4 100644 --- a/_docs_integrate/migration-from-v6-to-v7.md +++ b/_docs_integrate/migration-from-v6-to-v7.md @@ -85,7 +85,7 @@ import { ApiKeyAuthenticator, ConnectorClient } from "@nmshd/connector-sdk"; const connectorClient = ConnectorClient.create({ baseUrl: "https://", - authenticator: new ApiKeyAuthenticator("") + authenticator: new ApiKeyAuthenticator("") }); ``` diff --git a/_docs_operate/configuration.md b/_docs_operate/configuration.md index 1ff7407ed..4457061e5 100644 --- a/_docs_operate/configuration.md +++ b/_docs_operate/configuration.md @@ -74,7 +74,7 @@ You want to configure the following values: "apiKey": { "keys": { "default": { - "key": "an-api-key" + "key": "a-valid-API-key-with-at-least-30-chars" } } } @@ -86,7 +86,7 @@ You want to configure the following values: - The first value can be configured using the variable `infrastructure:httpServer:enabled="true"`. Note that the value is represented as a string in the environment variable and the Connector will rewrite it to its boolean representation. - The second value can be configured using the variable `infrastructure:httpServer:port="8080"`. Note that the value is represented as a string in the environment variable and the Connector will rewrite it to its number representation. -- The third value can be configured using the variable `infrastructure:httpServer:authentication:apiKey:keys:default:key="an-api-key"`. +- The third value can be configured using the variable `infrastructure:httpServer:authentication:apiKey:keys:default:key="a-valid-API-key-with-at-least-30-chars"`. ## Configuration options @@ -235,7 +235,7 @@ The HTTP server is the base for the `coreHttpApi` Module. It opens an express HT "apiKey": { "keys": { "default": { - "key": "an-api-key" + "key": "a-valid-API-key-with-at-least-30-chars" } } } @@ -312,7 +312,7 @@ If multiple authentication methods are configured, the authentication methods wi "apiKey": { "keys": { "default": { - "key": "an-api-key" + "key": "a-valid-API-key-with-at-least-30-chars" } } } diff --git a/_docs_operate/setup-with-docker-compose.md b/_docs_operate/setup-with-docker-compose.md index 423331aa6..a8c811df3 100644 --- a/_docs_operate/setup-with-docker-compose.md +++ b/_docs_operate/setup-with-docker-compose.md @@ -141,7 +141,7 @@ To use the api platform hosted on the Connector you need to make the following c "apiKey": { "keys": { "": { - "key": "" + "key": "" } } } From 1d1d7cf8c5375bd7bf3bd00db40618e6966a0f30 Mon Sep 17 00:00:00 2001 From: Britta Stallknecht Date: Mon, 25 Aug 2025 13:15:38 +0000 Subject: [PATCH 2/5] feat: specify requirements for valid API keys --- _docs_operate/configuration.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/_docs_operate/configuration.md b/_docs_operate/configuration.md index 4457061e5..37865e18f 100644 --- a/_docs_operate/configuration.md +++ b/_docs_operate/configuration.md @@ -338,7 +338,7 @@ The `apiKey` authentication method is used to authenticate requests using an API - **key** `required` - The actual API key that is used to authenticate the request. This key must be kept secret and should not be shared with anyone. + The actual API key that is used to authenticate the request. This key must be kept secret and should not be shared with anyone. A valid API key must be at least 30 characters long and contain at least 2 digits, 2 uppercase letters, 2 lowercase letters and 1 special character out of ``!"#$%&'()*+,-./:;<=>?@[\]^_`{|}~``. - **description** `optional` From 3e8d7d63e344ddcfbd52ab9448287de9f18ebe71 Mon Sep 17 00:00:00 2001 From: Britta Stallknecht Date: Mon, 25 Aug 2025 13:27:19 +0000 Subject: [PATCH 3/5] refactor: shouting placeholders --- _docs_integrate/migration-from-v6-to-v7.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/_docs_integrate/migration-from-v6-to-v7.md b/_docs_integrate/migration-from-v6-to-v7.md index 4b4b547b4..3bdec6bbc 100644 --- a/_docs_integrate/migration-from-v6-to-v7.md +++ b/_docs_integrate/migration-from-v6-to-v7.md @@ -84,8 +84,8 @@ With every version of the Connector, we ship a matching [TypeScript SDK]({% link import { ApiKeyAuthenticator, ConnectorClient } from "@nmshd/connector-sdk"; const connectorClient = ConnectorClient.create({ - baseUrl: "https://", - authenticator: new ApiKeyAuthenticator("") + baseUrl: "https://", + authenticator: new ApiKeyAuthenticator("") }); ``` From c23dd7ed7475213ab52bc5b5a82f031a5ee3ef8c Mon Sep 17 00:00:00 2001 From: Britta Stallknecht Date: Mon, 25 Aug 2025 13:43:16 +0000 Subject: [PATCH 4/5] refactor: increase maintainability of documentation --- _docs_integrate/examples/example.config.json | 2 +- _docs_operate/configuration.md | 8 ++++---- _docs_operate/setup-with-docker-compose.md | 2 +- 3 files changed, 6 insertions(+), 6 deletions(-) diff --git a/_docs_integrate/examples/example.config.json b/_docs_integrate/examples/example.config.json index 5912859b9..bc97b625e 100644 --- a/_docs_integrate/examples/example.config.json +++ b/_docs_integrate/examples/example.config.json @@ -14,7 +14,7 @@ "apiKey": { "keys": { "": { - "key": " https://enmeshed.eu/operate/configuration#apikey>" + "key": " https://enmeshed.eu/operate/configuration#apikey>" } } } diff --git a/_docs_operate/configuration.md b/_docs_operate/configuration.md index 37865e18f..c61c11918 100644 --- a/_docs_operate/configuration.md +++ b/_docs_operate/configuration.md @@ -74,7 +74,7 @@ You want to configure the following values: "apiKey": { "keys": { "default": { - "key": "a-valid-API-key-with-at-least-30-chars" + "key": "a-valid-API-key" } } } @@ -86,7 +86,7 @@ You want to configure the following values: - The first value can be configured using the variable `infrastructure:httpServer:enabled="true"`. Note that the value is represented as a string in the environment variable and the Connector will rewrite it to its boolean representation. - The second value can be configured using the variable `infrastructure:httpServer:port="8080"`. Note that the value is represented as a string in the environment variable and the Connector will rewrite it to its number representation. -- The third value can be configured using the variable `infrastructure:httpServer:authentication:apiKey:keys:default:key="a-valid-API-key-with-at-least-30-chars"`. +- The third value can be configured using the variable `infrastructure:httpServer:authentication:apiKey:keys:default:key="a-valid-API-key"`. ## Configuration options @@ -235,7 +235,7 @@ The HTTP server is the base for the `coreHttpApi` Module. It opens an express HT "apiKey": { "keys": { "default": { - "key": "a-valid-API-key-with-at-least-30-chars" + "key": "a-valid-API-key" } } } @@ -312,7 +312,7 @@ If multiple authentication methods are configured, the authentication methods wi "apiKey": { "keys": { "default": { - "key": "a-valid-API-key-with-at-least-30-chars" + "key": "a-valid-API-key" } } } diff --git a/_docs_operate/setup-with-docker-compose.md b/_docs_operate/setup-with-docker-compose.md index a8c811df3..3d3f59854 100644 --- a/_docs_operate/setup-with-docker-compose.md +++ b/_docs_operate/setup-with-docker-compose.md @@ -141,7 +141,7 @@ To use the api platform hosted on the Connector you need to make the following c "apiKey": { "keys": { "": { - "key": "" + "key": "" } } } From 01da7b59cbeb31ae27ea5403889672b5636b7ba1 Mon Sep 17 00:00:00 2001 From: Britta Stallknecht Date: Mon, 25 Aug 2025 13:47:06 +0000 Subject: [PATCH 5/5] fix: restrictive placeholder --- _docs_integrate/migration-from-v6-to-v7.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/_docs_integrate/migration-from-v6-to-v7.md b/_docs_integrate/migration-from-v6-to-v7.md index 3bdec6bbc..44422fe2f 100644 --- a/_docs_integrate/migration-from-v6-to-v7.md +++ b/_docs_integrate/migration-from-v6-to-v7.md @@ -84,8 +84,8 @@ With every version of the Connector, we ship a matching [TypeScript SDK]({% link import { ApiKeyAuthenticator, ConnectorClient } from "@nmshd/connector-sdk"; const connectorClient = ConnectorClient.create({ - baseUrl: "https://", - authenticator: new ApiKeyAuthenticator("") + baseUrl: "", + authenticator: new ApiKeyAuthenticator("") }); ```