Seeking up-to-date examples for working with HTTP Client in @effect/platform

Hi, do you know where I could find some up-to-date examples for working with HTTP Client in @effect/platform?

After copying the example from https://github.com/Effect-TS/platform :
import { Effect } from "effect";
import * as Http from "@effect/platform/HttpClient";

// $ExectType Http.request.ClientRequest
const req = Http.request.get("https://jsonplaceholder.typicode.com/posts/1");

// $ExectType Effect<never, Http.error.HttpClientError, unknown>
const program = req.pipe(
  Http.client.fetch(),
  Effect.flatMap((res) => res.json)
);

// Execute the program and handle the result
Effect.runPromise(program).then(console.log, console.error);

I get this type error:
image.png
Was this page helpful?