Bird
0
0

What will be the value of servers[0].url in this OpenAPI snippet? servers: - url: https://api.example.com/v1 - url: https://api.example.com/v2

medium📝 Predict Output Q5 of 15
Rest API - API Documentation
What will be the value of servers[0].url in this OpenAPI snippet? servers: - url: https://api.example.com/v1 - url: https://api.example.com/v2
Ahttps://api.example.com/v1
Bhttps://api.example.com/v2
Chttps://api.example.com
Dhttps://api.example.com/v3
Step-by-Step Solution
Solution:
  1. Step 1: Understand the servers array

    The servers key holds a list of server objects, each with a url.
  2. Step 2: Identify the first server URL

    The first element (servers[0]) has the URL https://api.example.com/v1.
  3. Final Answer:

    https://api.example.com/v1 -> Option A
  4. Quick Check:

    First server URL = https://api.example.com/v1 [OK]
Quick Trick: First server URL is servers[0].url [OK]
Common Mistakes:
MISTAKES
  • Picking second or third URL
  • Ignoring array order
  • Assuming default URL

Want More Practice?

15+ quiz questions · All difficulty levels · Free

Free Signup - Practice All Questions
More Rest API Quizzes