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

Function defaultContentType

packages/platform/src/HttpApiSchema.ts:480–495  ·  view source on GitHub ↗
(encoding: Encoding["kind"])

Source from the content-addressed store, hash-verified

478 }) as any
479
480const defaultContentType = (encoding: Encoding["kind"]) => {
481 switch (encoding) {
482 case "Json": {
483 return "application/json"
484 }
485 case "UrlParams": {
486 return "application/x-www-form-urlencoded"
487 }
488 case "Uint8Array": {
489 return "application/octet-stream"
490 }
491 case "Text": {
492 return "text/plain"
493 }
494 }
495}
496
497/**
498 * @since 1.0.0

Callers 1

HttpApiSchema.tsFile · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected