interface · Browser and Node

# AirtimePolicy

A link's airtime budget: a sliding window with a ceiling, and a per-frame cap (dwell time).

`@toip-tools/mesh-transport` · [View source](https://github.com/yourbuddyconner/toip-tools/blob/main/packages/mesh-transport/src/airtime.ts#L18)

Import:

```ts
import { type AirtimePolicy } from "@toip-tools/mesh-transport";
```

## Declaration

interface:

```ts
interface AirtimePolicy {
  windowMs: number;
  /** Share of the window this node may transmit: a legal duty cycle, or our fair share. */
  maxFraction: number;
  /** Longest single transmission allowed. */
  maxFrameMs?: number;
  /** Share of the budget kept back for ACKs and receipts. Default 0.1. */
  ackReserve?: number;
}
```

## Properties

**`windowMs` (required)**

`number`

**`maxFraction` (required)**

`number`

Share of the window this node may transmit: a legal duty cycle, or our fair share.

**`maxFrameMs` (optional)**

`number | undefined`

Longest single transmission allowed.

**`ackReserve` (optional)**

`number | undefined`

Share of the budget kept back for ACKs and receipts. Default 0.1.

[Usage guide](https://toip.tools/toolkit/mesh-transport/#usage) · [Error handling](https://toip.tools/toolkit/mesh-transport/#errors) · [All exports](https://toip.tools/toolkit/mesh-transport/api/)

---

This is the Markdown version of https://toip.tools/toolkit/mesh-transport/api/AirtimePolicy/. An index of the documentation for AI assistants is at https://toip.tools/llms.txt.
