Complete Latest api Interview Questions and Answers for Freshers and Experienced


Note: Below Interview Questions and Answers can be used by Freshers and Experienced together.

Complete Latest API Question and Answers

API Question and AnswersPlay Quiz On API  |  More Q&A Click Here
# Question Options Answer
1 Which of the following is not a valid HTTP methods used in RESTful web services?
  • GET
  • PUT
  • TIME
  • POST
  • TIME
    2 Which of the following component of HTTP request contains message content or Resource representation?
  • Request Body
  • URI
  • HTTP Version
  • Request Header
  • Request Body
    3 What URI stands for?
  • Unit Resource Identifier
  • Uniform Representation Identifier
  • Uniform Resource Identifier
  • None of the above.
  • Uniform Resource Identifier
    4 Which of the following HTTP method should be used to create resource using RESTful web service?
  • GET
  • DELETE
  • PUT
  • OPTIONS
  • PUT
    5 Public directive of Cache Control Header of HTTP response indicates that resource is cachable by any component.
  • true
  • false
  • none
  • all
  • true
    6 Which of the following is a best practice for designing a secure RESTful web service?
  • Validate Malformed XML/JSON - Check for well formed input passed to a web service method.
  • Throw generic Error Messages - A web service method should use HTTP error messages like 403 to show access forbidden etc.
  • Both of the above.
  • None of the above.
  • Both of the above.
    7 What JAX-RS stands for?
  • Just API for RESTful Web Services.
  • Joint API for RESTful Web Services.
  • JAVA API for RESTful Web Services.
  • None of the above.None of the above.
  • JAVA API for RESTful Web Services.
    8 Which of the following annotation of JAX RS API assigns a default value to a parameter passed to method?
  • @CookieParam
  • @FormParam
  • @DefaultValue
  • @Context
  • @DefaultValue
    9 A web service is a collection of open protocols and standards used for exchanging data between applications or systems.
  • true
  • false
  • none
  • all
  • true
    10 POST opearations should be idempotent.
  • true
  • false
  • none
  • all
  • false
    11 What is the HTTP Code 200 Indicates?
  • Completed
  • Success
  • Error
  • Warning
  • Success
    12 What is WSDL Stands for?
  • Webservice Description Language
  • Webservice Definition Language
  • Webservice Dictionary Language
  • Webservice Document Language
  • Webservice Description Language
    13 What is SOAP stands for ?
  • Simplified Object Access Protocol
  • Select Object Access Protocol
  • Simple Object Access Protocol
  • Sample Object Access Protocol
  • Simple Object Access Protocol
    14 What are the different HTTP Methods available?
  • GET,SET,DELETE,MARK
  • GET,PUT,REMOVE,POST
  • GET,SAVE,PUT,POST
  • GET,HEAD,CONNECT,OPTIONS
  • GET,HEAD,CONNECT,OPTIONS
    15 What are the mark up languages available in REST Services?
  • HTML & VBSCRIPT
  • HTML & XML
  • XML & Java
  • JSON & XML
  • JSON & XML
    16 What is the category of 5XX HTTP Codes belongs to?
  • Server Error
  • Redirection
  • Informational
  • Client Error
  • Server Error
    17 What is the protocol used in REST?
  • HTTP
  • XML
  • SOAP
  • JMX
  • HTTP
    18 What is the HTTP Code Related to Page Not Found?
  • 403
  • 401
  • 404
  • 402
  • 404
    19 What is the Category of the 1XX HTTP Codes belongs to?
  • Informational
  • Success
  • Client Error
  • Redirection
  • Informational
    20 What does the Acronym REST Stands for?
  • Rest Interface
  • Representational Assured API
  • REST Assured API
  • Representational State Transfer
  • Representational State Transfer
    21 What is the Category of 4XX HTTP Codes belongs to?
  • Success
  • Server Error
  • Client Error
  • Informational
  • Client Error
    22 What is the HTTP Code Related to Internal Server Error??
  • 502
  • 501
  • 500
  • 504
  • 500
    23 What is the Category of 2XX HTTP Codes belongs to?
  • Success
  • Server Error
  • Redirection
  • Client Error
  • Success
    24 What is the Category of 3XX HTTP Codes belongs to?
  • Server Error
  • Client Error
  • Success
  • Redirection
  • Redirection