Skip to main content
The types in this reference are exported from @telnyx/edge-runtime (TypeScript) and describe version ≥ 0.2.2 — the first release where expirationTtl is applied and list() entries carry sizeBytes/updatedAt. They describe the env binding — the in-function surface. To read or write KV from another language or outside a function, use the REST API.
The KV Runtime API is a single binding type and the small set of option/result types its methods take. A namespace declared as [storage.kv.<NAME>] in func.toml resolves on env.<NAME> as a KvNamespace.

Getting the Binding

Declaring the binding is covered in the Quick Start. The binding resolves at runtime from func.toml; run telnyx-edge types (CLI ≥ v0.2.3) after editing the manifest to regenerate telnyx-env.d.ts, which types env.<NAME> as a KvNamespace.
  • KvNamespace — the method-by-method reference
  • Bindings — how bindings resolve on env
  • REST API — the same operations over HTTP
  • Key Expiration — server-side TTL via expirationTtl, ttl_secs, or --ttl