Rest Api

What type of relationship is defined as one resource existing only if another parent resource exist-for example, pages in a book?

1.

`Partial`

2.

`dependent`

3.

`associative`

4.

`linked`

Q 1 / 61

Rest Api

Which URL pattern is recommended when working with one resource and a collection of resources?

1.

`/companies/{id} and/company`

2.

`/company/{id} and/companies`

3.

`/companies/{id} and/companies`

4.

`/company/{id} and/company`

Q 2 / 61

Rest Api

When dealing with JSON web Tokens (JWTs), what is a claim?

1.

`data in the token`

2.

`Ownership`

3.

`a permission`

4.

`and integer`

Q 3 / 61

Rest Api

Which REST constraint specifies that knowledge and understanding obtained from one component of the API should be generally applicable elsewhere in the API?

1.

`Uniform Interface`

2.

`Client-Server`

3.

`Stateless`

4.

`Chacheable`

Q 4 / 61

Rest Api

What would you enable to allow a browser on another site to make an AJAX request to your API?

1.

`HTTP`

2.

`REST`

3.

`OPTIONS`

4.

`CORS`

Q 5 / 61

Rest Api

APIs commonly use webhooks to **_**.

1.

`notify other systems of an event`

2.

`catch error faster`

3.

`improve error logging`

4.

`log additional data`

Q 6 / 61

Rest Api

What is the underlying goal of all APIs?

1.

`to add new technologies to an organization's infrastructure.`

2.

`to share features and functionality with other system.`

3.

`to move infrastructure to the cloud.`

4.

`to appease the latest digital transformation effort.`

Q 7 / 61

Rest Api

Which is a common command-line tool for using or exploring an API?

1.

`bash`

2.

`curl`

3.

`ssh`

4.

`powerShell`

Q 8 / 61

Rest Api

What is the modern specification for describing an API?

1.

`OpenAPI (Swagger)`

2.

`WADL`

3.

`WSDL`

4.

`OAuth`

Q 9 / 61

Rest Api

Which HTTP verb is normally used to update or create a resource in an API?

1.

`SUBMIT`

2.

`WRITE`

3.

`POST`

4.

`CREATE`

Q 10 / 61

Rest Api

What is one benefit of server-side caching in APIs?

1.

`Mobile app work better.`

2.

`It improves uptime.`

3.

`It offers better security.`

4.

`It reduce load on servers.`

Q 11 / 61

Rest Api

Your API resource does no allow deletion, and a client application attempted to delete the resource. What HTTP response code should you return?

1.

`409 Conflict`

2.

`400 Bad Request`

3.

`406 Not Acceptable`

4.

`405 Method Not Allowed`

Q 12 / 61

Rest Api

What is OpenID Connect?

1.

`an identify layer on top of OAuth 2.0`

2.

`the new name for SAML 3.0`

3.

`a modern replacement for API keys`

4.

`an SSO competitor for OAuth 2.0`

Q 13 / 61

Rest Api

What is one benefit of GraphQl over REST approaches?

1.

`flexible querying/responses`

2.

`more stable APIs`

3.

`compatible with more gateways`

4.

`more secure by default`

Q 14 / 61

Rest Api

Which REST constraint specifies that there should be no shared context?

1.

`Stateless`

2.

`Client-Server`

3.

`Uniform Interface`

4.

`Cacheable`

Q 15 / 61

Rest Api

What purpose does a User-Agent serve?

1.

`It identifies the user ID.`

2.

`It identifies the client application or SDK.`

3.

`It identifies if the API should expect a user authentication.`

4.

`It identifies if the API should accept microservice traffic.`

Q 16 / 61

Rest Api

If you were to add versioning by using the Accept and Content-Type header, what would be the correct format of the header value?

1.

`application/json`

2.

`application/json_version2`

3.

`text/html`

4.

`application/vnd.myapp.v2+json`

Q 17 / 61

Rest Api

What is one benefit that OAuth provides over an API key approach?

1.

`A token is encrypted.`

2.

`A token is encoded.`

3.

`A token is scoped to the use case.`

4.

`A token can be shared between systems.`

Q 18 / 61

Rest Api

The ability to execute the same API request over and over again without changing the resource's state is an example of _.

1.

`stateless architecture`

2.

`idempotency`

3.

`a uniform interface`

4.

`cacheability`

Q 19 / 61

Rest Api

What component can you use to wrap legacy architectures or protocols into a REST interface for easier consumption and integration?

1.

`API proxy`

2.

`API gateway`

3.

`OpenAPI`

4.

`OAuth authorization server`

Q 20 / 61

Rest Api

What protection does a JSON Web Token (JWT) offer to mitigate tampering with its contents?

1.

`transport over SSL`

2.

`encrypted payload`

3.

`a signature`

4.

`encoded payload`

Q 21 / 61

Rest Api

What OAuth term is used to represent permissions?

1.

`token`

2.

`scope`

3.

`claim`

4.

`back channel`

Q 22 / 61

Rest Api

What additional type of token would you see when using OpenID Connect?

1.

`ID token`

2.

`refresh token`

3.

`access token`

4.

`auth code token`

Q 23 / 61

Rest Api

What should you add to a Cache-Control response header to specify that a response should not be stored in an intermediary cache?

1.

`no-proxy`

2.

`client-only`

3.

`restricted`

4.

`private`

Q 24 / 61

Rest Api

Which OAuth grant type can support a refresh token?

1.

`Authorization Code Grant`

2.

`Client Credentials Grant`

3.

`Implicit Grant`

4.

`Authentication Grant`

Q 25 / 61

Rest Api

Using OAuth, what scope would you request for write access to the API?

1.

`It varies from API to API.`

2.

`admin`

3.

`write`

4.

`read-write`

Q 26 / 61

Rest Api

Which property would you use to include subresources directly into a JSON document?

1.

`_embedded`

2.

`resources`

3.

`subresources`

4.

`_links`

Q 27 / 61

Rest Api

What is the best way to track SDK and version usage?

1.

`tracking downloads`

2.

`Accept headers`

3.

`user agents`

4.

`polling users`

Q 28 / 61

Rest Api

Which REST constraint allows for the presence of caching, routing, and other systems between the client and server?

1.

`Layered System`

2.

`Stateless`

3.

`Client-Server`

4.

`Cacheable`

Q 29 / 61

Rest Api

Which content is best to include in your documentation?

1.

`your tech stack`

2.

`reasoning for your naming schema`

3.

`your mission statement`

4.

`sample code`

Q 30 / 61

Rest Api

What metric tracks overall availability for your API?

1.

`Response Time`

2.

`Time to First Hello World`

3.

`TTL`

4.

`Uptime`

Q 31 / 61

Rest Api

What is the recommended method and URL pattern for retrieving a specific user?

1.

`GET /user/{id}`

2.

`GET /users/{id}`

3.

`GET /user?id={id}`

4.

`GET /users?id={id}`

Q 32 / 61

Rest Api

What is the purpose of a link relation?

1.

`to describe relationships between resources or actions`

2.

`to describe subresources related to the current one`

3.

`to link two resources together`

4.

`to describe a resource and its purpose`

Q 33 / 61

Rest Api

When building SDKs, which languages should you support?

1.

Java, Javascript, and .NET

2.

and you can support

3.

PHP, Python, and Go

4.

the languages that your target users use

Q 34 / 61

Rest Api

Which property would you use to include references to other resources in a JSON document?

1.

`resources`

2.

`_embedded`

3.

`subresources`

4.

`_links`

Q 35 / 61

Rest Api

What is OAuth?

1.

an authorization framework for granted delegated access

2.

an approach to single sign-on for APIs

3.

a method for API authentication

4.

HTTP Basic Authentication 2.0

Q 36 / 61

Rest Api

What should your API documentation describe?

1.

JSON

2.

HTTP

3.

common use cases

4.

your tech stack

Q 37 / 61

Rest Api

What is the purpose of an OAuth refresh token?

1.

to share user profile information

2.

to update an API configuration

3.

to keep a web session active

4.

to retrieve an access token

Q 38 / 61

Rest Api

What is Time to First Hello World?

1.

how long it takes for a developer to do something with your API

2.

how long it takes to start a new programming language

3.

how long it takes to install your SDK

4.

how long it takes to read your documentation

Q 39 / 61

Rest Api

Which response header tells the client and intermediaries that the response is not to be cached anywhere?

1.

Cache-State: none

2.

Expires:-1

3.

Cache-Control: no-cache

4.

Cache-Control: no-store

Q 40 / 61

Rest Api

What component hides the distinctions or boundaries between various microservices from end-client applications?

1.

`API gateway`

2.

`API logging `

3.

`a layered system `

4.

`API proxy`

Q 41 / 61

Rest Api

The textbook approach to api versioning is to use **_**.

1.

`common knowledge`

2.

`URLs`

3.

`no versioning`

4.

`the Accept header`

Q 42 / 61

Rest Api

Which is the most secure method to transmit an API key?

1.

`URL parameter`

2.

`Authorization header`

3.

`Base64 encoding`

4.

`Basic Auth`

Q 43 / 61

Rest Api

Within Oauth, what component validates the user's identity?

1.

`client`

2.

`not specified`

3.

`authorization server`

4.

`resource server`

Q 44 / 61

Rest Api

API traffic that is entirely internal to your organization is normally called _?

1.

`inbound traffic`

2.

`north-south traffic `

3.

`internal traffic `

4.

`east-west traffic`

Q 45 / 61

Rest Api

What is the best approach for requesting JSON instead of XML from an API?

1.

`Add .json to the URL.`

2.

`APIs do not use XML.`

3.

`Use the Content-Type header.`

4.

`Use the Accept header.`

Q 46 / 61

Rest Api

When a user attempts to access a record that is not their own, which HTTP response code is the most appropriate?

1.

`403`

2.

`404`

3.

`401`

4.

`405`

Q 47 / 61

Rest Api

Which is a benefit of using an API gateway?

1.

`HTTP verbs`

2.

`JSON payloads`

3.

`HTTP response codes`

4.

`rate limiting/throttling`

Q 48 / 61

Rest Api

API testing must be treated as **_**?

1.

`red team testing`

2.

`white box testing`

3.

`blue box testing`

4.

`black box testing`

Q 49 / 61

Rest Api

Which HTTP verb is used in a CORS preflight request?

1.

`PUT`

2.

`POST`

3.

`GET`

4.

`OPTIONS`

Q 50 / 61

Rest Api

Which response header will tell the client that the response is cached for 1 minute ?

1.

`Expires: 1 minute`

2.

`Cache-Control: max-age=60`

3.

`Expires: 1 January 2020`

4.

`Cache-Expires: max-age=60`

Q 51 / 61

Rest Api

What is the concept that allows an API client to explore an API via links embedded in payloads?

1.

`hypermedia`

2.

`link relations`

3.

`parsing`

4.

`browsing`

Q 52 / 61

Rest Api

Which HTTP response code describes a new resource as created successfully?

1.

`200`

2.

`201`

3.

`204`

4.

`202`

Q 53 / 61

Rest Api

Which is an example of Code on Demand?

1.

AWS Lambda

2.

downloading open-source software

3.

Serverless

4.

JavaScript on a webpage

Q 54 / 61

Rest Api

Which URL pattern should you follow for accessing a subresource attached to a specific resource?

1.

/companies/employees/{companyId}/{employeeId}

2.

/company/{companyId}/employees/{employeeId}

3.

/companies/{companyId}/employees/{employeeId}

4.

/companies/{companyId}/employee/{employeeId}

Q 55 / 61

Rest Api

Which REST constraint essentially prohibits the use of cookies?

1.

Stateless

2.

Cacheable

3.

Layered System

4.

Uniform Interface

Q 56 / 61

Rest Api

Which HTTP verb is used to delete a resource?

1.

FLUSH

2.

DELETE

3.

CLEAR

4.

DESTROY

Q 57 / 61

Rest Api

Which verb is _not_ considered idempotent?

1.

DELETE

2.

GET

3.

PUT

4.

POST

Q 58 / 61

Rest Api

Which REST constraint specifies that each request should stand on its own and not have a specific required order?

1.

Uniform Interface

2.

Cacheable

3.

Stateless

4.

Client-Server

Q 59 / 61

Rest Api

When you get a 429 code, what should you do next?

1.

Check you JSON structure.

2.

Check the API uptime status.

3.

Slow down your requests.

4.

Check you API key.

Q 60 / 61

Rest Api

When exploring record sets, what is the best approach for pagination?

1.

date-based filtering

2.

next/previous cursors

3.

page size and filters

4.

database IDs

Q 61 / 61