Bird
Raised Fist0

Why does this API key invalidation request fail?

medium📝 Debug Q7 of Q15
Elasticsearch - Security
Why does this API key invalidation request fail?
{
  "api_key": "12345"
}
AThe request body must be empty
BThe field should be "id", not "api_key"
CAPI key values must be numeric
DAPI keys cannot be invalidated via API
Step-by-Step Solution
Solution:
  1. Step 1: Check required field for invalidation

    The API expects "id" or "name" fields, not "api_key".
  2. Step 2: Validate other options

    API keys can be invalidated, values are strings, and request body is not empty.
  3. Final Answer:

    The field should be "id", not "api_key" -> Option B
  4. Quick Check:

    Use "id" field to invalidate API keys [OK]
Quick Trick: Use "id" or "name" to invalidate API keys [OK]
Common Mistakes:
MISTAKES
  • Using wrong field names in request
  • Assuming API keys cannot be invalidated
  • Sending empty request body

Want More Practice?

15+ quiz questions · All difficulty levels · Free

Free Signup - Practice All Questions
More Elasticsearch Quizzes