Effect CommunityEC
Effect Community4w ago
6 replies
MEEKS

Changing the contentType of an API Endpoint in Effect Typescript

Hi, how do i change the contentType of an api endpoint? I'm now using the code below, but that keeps returning application/json instead of application/scim+json
const MyEndpoint = HttpApiEndpoint.get("foo")`/foo`
  .addSuccess(
    MyResultSchema.pipe(
      HttpApiSchema.withEncoding({
        kind: "Json",
        contentType: "application/scim+json", 
      }),
    ),
  )
Was this page helpful?