0
0
Microservicessystem_design~10 mins

API versioning for services in Microservices - Interactive Code Practice

Choose your learning style9 modes available
Practice - 5 Tasks
Answer the questions below
1fill in blank
easy

Complete the code to specify the API version in the URL path.

Microservices
GET /api/[1]/users
Drag options to blanks, or click blank then click option'
Aversion1
Bapi1
Cv1
Dservice1
Attempts:
3 left
💡 Hint
Common Mistakes
Using long or unclear version names in the URL path.
Not including the version in the URL at all.
2fill in blank
medium

Complete the code to specify the API version using a custom HTTP header.

Microservices
X-API-Version: [1]
Drag options to blanks, or click blank then click option'
Aservice_v1
Bversion1
Capi_version_1
Dv1
Attempts:
3 left
💡 Hint
Common Mistakes
Using long descriptive strings in headers.
Confusing header names with version values.
3fill in blank
hard

Fix the error in the versioning strategy by choosing the correct versioning method.

Microservices
API versioning is done by [1] the API endpoint URL.
Drag options to blanks, or click blank then click option'
Aembedding
Bignoring
Chiding
Dremoving
Attempts:
3 left
💡 Hint
Common Mistakes
Not including version info in the API URL.
Removing version info from requests.
4fill in blank
hard

Fill both blanks to complete the API versioning strategy using query parameters.

Microservices
GET /users?[1]=[2]
Drag options to blanks, or click blank then click option'
Aversion
Bv
C1
Dapi
Attempts:
3 left
💡 Hint
Common Mistakes
Using unclear parameter names.
Using complex version values.
5fill in blank
hard

Fill all three blanks to complete the code for content negotiation versioning using the Accept header.

Microservices
Accept: application/[1].v[2]+[3]
Drag options to blanks, or click blank then click option'
Ajson
B2
Cxml
Djsonapi
Attempts:
3 left
💡 Hint
Common Mistakes
Mixing media types incorrectly.
Using invalid version formats.