AdobeDocs / adobe-dev-console

Apache License 2.0
21 stars 123 forks source link

Wrong curl syntax for delete in src/pages/guides/authentication/ServerToServerAuthentication/implementation.md #90

Closed venkatrbalaji closed 5 months ago

venkatrbalaji commented 1 year ago

Expected Behaviour

The given curl command should delete an existing client secret based on the UUID provided.

Actual Behaviour

Returns "403 Forbidden"

Reproduce Scenario (including but not limited to)

Deleting an old client secret while performing client secret rotation on a project.

Suggested Fix:

Update the curl method to DELETE on line 144 of src/pages/guides/authentication/ServerToServerAuthentication/implementation.md as below.

curl -X DELETE 'https://api.adobe.io/console/organizations/{orgId}/credentials/{credentialId}/secrets/{uuid from step 9}' \
     -H 'Authorization: Bearer {ACCESS TOKEN GENERATED IN STEP 5}'
     -H 'x-api-key: {CLIENT ID FROM STEP 6}'

Steps to Reproduce

  1. Follow the steps 1-9 in src/pages/guides/authentication/ServerToServerAuthentication/implementation.md to create a client secret
  2. On step 10, Run the below curl command provided in documentation to delete an existing client secret.
    curl -X POST 'https://api.adobe.io/console/organizations/{orgId}/credentials/{credentialId}/secrets/{uuid from step 9}' \
     -H 'Authorization: Bearer {ACCESS TOKEN GENERATED IN STEP 5}'
     -H 'x-api-key: {CLIENT ID FROM STEP 6}'

Platform and Version

Sample Code that illustrates the problem

Logs taken while reproducing problem

theManikJindal commented 5 months ago

This is fixed now.