MCPcopy Index your code
hub / github.com/code-dot-org/code-dot-org / get

Function get

apps/src/util/HttpClient.ts:115–121  ·  view source on GitHub ↗

* Performs a GET request to the given endpoint. Use fetchJson * to automatically unwrap the response JSON as a typed object.

(
  endpoint: string,
  useAuthenticityToken = false,
  headers: Record<string, string> = {}
)

Source from the content-addressed store, hash-verified

113 * to automatically unwrap the response JSON as a typed object.
114 */
115async function get(
116 endpoint: string,
117 useAuthenticityToken = false,
118 headers: Record<string, string> = {}
119): Promise<Response> {
120 return sendRequest('GET', endpoint, undefined, useAuthenticityToken, headers);
121}
122
123async function put(
124 endpoint: string,

Callers 15

routes.rbFile · 0.50
requiredMethod · 0.50
get_multiMethod · 0.50
get!Method · 0.50
[]Method · 0.50
method_missingMethod · 0.50
lazyMethod · 0.50
get_or_postMethod · 0.50
get_user_metricsMethod · 0.50
allMethod · 0.50
GraphicsAppForTestClass · 0.50
assert_image_urlMethod · 0.50

Calls 1

sendRequestFunction · 0.85

Tested by 15

assert_image_urlMethod · 0.40
assert_animated_imageMethod · 0.40
test_optimize_imageMethod · 0.40
test_optimize_anigifMethod · 0.40
test_dcdo_pixel_maxMethod · 0.40
test_no_cookiesMethod · 0.40
test_all_cookiesMethod · 0.40
test_graphicsMethod · 0.40
list_objectsMethod · 0.40