Programming MCQs Feed

📊 Trishul API
Q. What is the main difference between mono and flux methods?
  • (A) Mono is async, flux is sync
  • (B) Flux only supports GET
  • (C) Flux methods expect array data, mono supports mixed
  • (D) Mono does not support headers
💬 Discuss
✅ Correct Answer: (C) Flux methods expect array data, mono supports mixed

Explanation: Flux methods use array type for data, mono supports mixed types.

📊 Trishul API
Q. Which method is used for GET request (mono variant)?
  • (A) get()
  • (B) get_mono()
  • (C) fetch()
  • (D) request_get()
💬 Discuss
✅ Correct Answer: (B) get_mono()

Explanation: get_mono() performs GET request.

📊 Trishul API
Q. Which method is used for POST request (flux variant)?
  • (A) post()
  • (B) post_mono()
  • (C) post_flux()
  • (D) send_post()
💬 Discuss
✅ Correct Answer: (C) post_flux()

Explanation: post_flux() is used for flux POST.

📊 Trishul API
Q. Which parameter type is required for headers in all methods?
  • (A) array
  • (B) string
  • (C) TrishulClientHeader
  • (D) object
💬 Discuss
✅ Correct Answer: (C) TrishulClientHeader

Explanation: Headers must be passed as TrishulClientHeader object.

📊 Trishul API
Q. Which method internally executes the HTTP request?
  • (A) execute()
  • (B) __makeCurlRequest()
  • (C) requestHandler()
  • (D) curl_exec()
💬 Discuss
✅ Correct Answer: (B) __makeCurlRequest()

Explanation: Private helper method handles actual request.

📊 Trishul API
Q. What is the visibility of __makeCurlRequest()?
  • (A) public
  • (B) protected
  • (C) private
  • (D) static
💬 Discuss
✅ Correct Answer: (C) private

Explanation: It is a private helper method.

📊 Trishul API
Q. Which method is used to send DELETE request (flux variant)?
  • (A) delete()
  • (B) delete_mono()
  • (C) delete_flux()
  • (D) remove_flux()
💬 Discuss
✅ Correct Answer: (C) delete_flux()

Explanation: delete_flux() handles DELETE requests.

📊 Trishul API
Q. What is special about delete_flux() data parameter?
  • (A) Mandatory
  • (B) Not used in implementation
  • (C) Only string allowed
  • (D) Required for all requests
💬 Discuss
✅ Correct Answer: (B) Not used in implementation

Explanation: Docs mention data is currently not used.

📊 Trishul API
Q. Which method supports sending mixed data type?
  • (A) post_flux()
  • (B) put_flux()
  • (C) post_mono()
  • (D) delete_flux()
💬 Discuss
✅ Correct Answer: (C) post_mono()

Explanation: Mono variants accept mixed data.

📊 Trishul API
Q. What is the return type of TrishulClient methods?
  • (A) Boolean
  • (B) PDO
  • (C) Response from server
  • (D) JSON only
💬 Discuss
✅ Correct Answer: (C) Response from server

Explanation: Methods return server response.