From 0290b9fbc9e5cf2b7ac212accc4f638397fa40ee Mon Sep 17 00:00:00 2001 From: Paul Abel Date: Fri, 17 Oct 2025 10:01:31 +0100 Subject: [PATCH] Use appropriate Content-Type header in examples --- .../app-protect-waf-v5/compile-waf-policies.md | 2 ++ .../manage-waf-security-policies.md | 12 +++++++++--- 2 files changed, 11 insertions(+), 3 deletions(-) diff --git a/content/nic/installation/integrations/app-protect-waf-v5/compile-waf-policies.md b/content/nic/installation/integrations/app-protect-waf-v5/compile-waf-policies.md index c7ba92fc3..b96530dac 100644 --- a/content/nic/installation/integrations/app-protect-waf-v5/compile-waf-policies.md +++ b/content/nic/installation/integrations/app-protect-waf-v5/compile-waf-policies.md @@ -56,6 +56,7 @@ In the same directory you created `simple-policy.json`, create a POST request fo ```shell curl -X POST https://{{NMS_FQDN}}/api/platform/v1/security/policies \ -H "Authorization: Bearer " \ + -H "Content-Type: application/json" \ -d @simple-policy.json ``` @@ -122,6 +123,7 @@ Send a POST request to create the bundle through the API: ```shell curl -X POST https://{{NMS_FQDN}}/api/platform/v1/security/policies/bundles \ -H "Authorization: Bearer " \ + -H "Content-Type: application/json" \ -d @security-policy-bundles.json ``` diff --git a/content/nim/nginx-app-protect/manage-waf-security-policies.md b/content/nim/nginx-app-protect/manage-waf-security-policies.md index 925543c31..284888ba4 100644 --- a/content/nim/nginx-app-protect/manage-waf-security-policies.md +++ b/content/nim/nginx-app-protect/manage-waf-security-policies.md @@ -95,6 +95,7 @@ For example: ```shell curl -X POST https://{{NIM_FQDN}}/api/platform/v1/security/policies \ -H "Authorization: Bearer " \ + -H "Content-Type: application/json" \ -d @ignore-xss-example.json ``` @@ -164,6 +165,7 @@ To use `POST`, include the policy metadata and content in your request: ```shell curl -X POST https://{{NIM_FQDN}}/api/platform/v1/security/policies?isNewRevision=true \ -H "Authorization: Bearer " \ + -H "Content-Type: application/json" \ -d @update-xss-policy.json ``` @@ -179,7 +181,7 @@ Then include the UID in your PUT request: ```shell curl -X PUT https://{{NIM_FQDN}}/api/platform/v1/security/policies/ \ -H "Authorization: Bearer " \ - --Content-Type application/json \ + -H "Content-Type application/json" \ -d @update-xss-policy.json ``` @@ -277,6 +279,7 @@ Example: ```shell curl -X POST https://{{NIM_FQDN}}/api/platform/v1/security/policies/bundles \ -H "Authorization: Bearer " \ + -H "Content-Type: application/json" \ -d @security-policy-bundles.json ``` @@ -540,6 +543,7 @@ Example: ```shell curl -X POST https://{{NIM_FQDN}}/api/platform/v1/security/logprofiles \ -H "Authorization: Bearer " \ + -H "Content-Type: application/json" \ -d @default-log-example.json ``` @@ -600,6 +604,7 @@ To create a new revision: ```shell curl -X POST https://{{NIM_FQDN}}/api/platform/v1/security/logprofiles?isNewRevision=true \ -H "Authorization: Bearer " \ + -H "Content-Type: application/json" \ -d @update-default-log.json ``` @@ -610,7 +615,7 @@ To overwrite an existing security log profile: ```shell curl -X PUT https://{{NIM_FQDN}}/api/platform/v1/security/logprofiles/ \ -H "Authorization: Bearer " \ - --Content-Type application/json \ + -H "Content-Type application/json" \ -d @update-log-profile.json ``` @@ -619,7 +624,7 @@ To overwrite an existing security log profile: ```shell curl -X PUT https://{{NIM_FQDN}}/api/platform/v1/security/logprofiles/ \ -H "Authorization: Bearer " \ - --Content-Type application/json \ + -H "Content-Type: application/json" \ -d @update-log-profile.json ``` @@ -686,6 +691,7 @@ Example: ```shell curl -X POST https://{{NIM_FQDN}}/api/platform/v1/security/publish \ -H "Authorization: Bearer " \ + -H "Content-Type: application/json" \ -d @publish-request.json ```