MCPcopy Create free account
hub / github.com/Effect-TS/effect / json

Method json

packages/platform/deno/src/DenoHttpServer.ts:395–404  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

393 ))
394 }
395 get json(): Effect.Effect<Schema.Json, Error.HttpServerError> {
396 return Effect.flatMap(this.text, (_) =>
397 Effect.try({
398 try: () => JSON.parse(_) as Schema.Json,
399 catch: (cause) =>
400 new Error.HttpServerError({
401 reason: new Error.RequestParseError({ request: this, cause })
402 })
403 }))
404 }
405 get urlParamsBody(): Effect.Effect<UrlParams.UrlParams, Error.HttpServerError> {
406 return Effect.flatMap(this.text, (_) =>
407 Effect.try({

Callers 1

Calls 1

parseMethod · 0.45

Tested by

no test coverage detected