Bird
0
0

Which configuration correctly sets this up?

hard📝 Application Q15 of 15
AWS - API Gateway
You want to create an API with a resource /orders that supports both GET and POST methods. The GET method returns a mock response, and the POST method triggers a Lambda function. Which configuration correctly sets this up?
ACreate /orders resource; add GET and POST methods both with MOCK integration
BCreate /orders resource; add GET method with MOCK integration; add POST method with Lambda integration
CCreate /orders resource; add GET method with Lambda integration; add POST method with MOCK integration
DCreate /orders resource; add GET and POST methods both with Lambda integration
Step-by-Step Solution
Solution:
  1. Step 1: Match method to integration type

    The GET method should use MOCK integration to return a static response without backend calls.
  2. Step 2: Configure POST method to trigger Lambda

    The POST method must be integrated with Lambda to process incoming data.
  3. Step 3: Verify the correct combination

    Create /orders resource; add GET method with MOCK integration; add POST method with Lambda integration correctly assigns MOCK to GET and Lambda to POST on the /orders resource.
  4. Final Answer:

    Create /orders resource; add GET method with MOCK integration; add POST method with Lambda integration -> Option B
  5. Quick Check:

    GET=MOCK, POST=Lambda [OK]
Quick Trick: GET with MOCK, POST with Lambda for mixed behavior [OK]
Common Mistakes:
MISTAKES
  • Swapping MOCK and Lambda integrations between methods
  • Using same integration for both methods incorrectly
  • Forgetting to create the resource before methods

Want More Practice?

15+ quiz questions · All difficulty levels · Free

Free Signup - Practice All Questions
More AWS Quizzes