MCPcopy
hub / github.com/anomalyco/opencode / get

Function get

packages/core/src/plugin/provider/opencode.ts:291–295  ·  view source on GitHub ↗
(http: HttpClient.HttpClient, url: string, token: string, schema: S)

Source from the content-addressed store, hash-verified

289}
290
291function get<S extends Schema.Top>(http: HttpClient.HttpClient, url: string, token: string, schema: S) {
292 return HttpClient.filterStatusOk(http)
293 .execute(HttpClientRequest.get(url).pipe(HttpClientRequest.acceptJson, HttpClientRequest.bearerToken(token)))
294 .pipe(Effect.flatMap(HttpClientResponse.schemaBodyJson(schema)))
295}
296
297function post<S extends Schema.Top>(
298 http: HttpClient.HttpClient,

Callers 1

credentialFunction · 0.70

Calls 2

executeMethod · 0.65
getMethod · 0.65

Tested by

no test coverage detected