> ## Documentation Index
> Fetch the complete documentation index at: https://klef.ai/docs/llms.txt
> Use this file to discover all available pages before exploring further.

# HttpChannel

> Carries calls to a connector that serves them over HTTP.

```csharp
public sealed class HttpChannel : IConnectorChannel
```

**Implements:** `IConnectorChannel`

## Constructors

```csharp
public HttpChannel(HttpClient client, ConnectorManifest? manifest = null, Func<ConnectionContext, string>? connectionOf = null)
```

Carries calls to a connector that serves them over HTTP.

### Parameters

**client** `HttpClient` *required*

A client for where the connector listens.

**manifest** `ConnectorManifest`

The connector's manifest, when the connector keeps no values and each call carries its auth and settings.

**connectionOf** `Func\<ConnectionContext,String\>`

**Type:** `Func<ConnectionContext,String>`

Names a context's connection, when its id is not the name.

## Methods

### Client()

```csharp
public static HttpClient Client(string listen)
```

A client for a connector listening where `listen` says.

#### Parameters

**listen** `string` *required*

#### Returns

`HttpClient`

### Send()

```csharp
public CallAnswer Send(string name, JsonNode? request)
```

Makes a call that needs no connection.

#### Parameters

**name** `string` *required*

**request** `JsonNode` *required*

#### Returns

`CallAnswer`

### SendAsync()

```csharp
public Task<CallAnswer> SendAsync(string name, JsonNode? request, ConnectionContext context, CancellationToken cancellationToken)
```

Makes a call on a connection.

#### Parameters

**name** `string` *required*

**request** `JsonNode` *required*

**context** `ConnectionContext` *required*

**cancellationToken** `CancellationToken` *required*

#### Returns

`Task<CallAnswer>`

```csharp
public Task<CallAnswer> SendAsync(string name, JsonNode? request, string connection, CancellationToken cancellationToken)
```

Makes a call on a connection the connector holds the values of, named as the connector knows it.

#### Parameters

**name** `string` *required*

**request** `JsonNode` *required*

**connection** `string` *required*

**cancellationToken** `CancellationToken` *required*

#### Returns

`Task<CallAnswer>`


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.