Rest API - URL and Resource DesignWhich of the following is the best noun-based REST API endpoint to represent a collection of user profiles?A/userProfilesListB/getUsersC/usersD/fetchUsersCheck Answer
Step-by-Step SolutionSolution:Step 1: Identify noun-based resource namingREST API endpoints should use plural nouns to represent collections.Step 2: Evaluate options/users uses the plural noun 'users' without verbs or actions, which is correct. Options B, C, and D include verbs or unnecessary words.Final Answer:/users -> Option CQuick Check:Plural noun without verbs [OK]Quick Trick: Use plural nouns without verbs for collections [OK]Common Mistakes:Including verbs in resource namesUsing singular nouns for collectionsAdding action words like 'get' or 'fetch'
Master "URL and Resource Design" in Rest API9 interactive learning modes - each teaches the same concept differentlyLearnWhyDeepVisualTryChallengeProjectRecallTime
More Rest API Quizzes HTTP Methods - Idempotency of methods - Quiz 2easy HTTP Status Codes - Why status codes communicate outcomes - Quiz 9hard HTTP Status Codes - 422 Unprocessable Entity - Quiz 10hard Query Parameters and Filtering - Pagination with limit and offset - Quiz 6medium Query Parameters and Filtering - Search parameter - Quiz 6medium REST API Fundamentals - REST constraints and principles - Quiz 15hard REST API Fundamentals - REST vs SOAP vs GraphQL comparison - Quiz 9hard REST API Fundamentals - Why REST APIs exist - Quiz 2easy REST API Fundamentals - First API request and response - Quiz 12easy Request and Response Format - Response envelope patterns - Quiz 10hard