---
title: "Start watching a namespace"
method: POST
path: "/v1/namespaces"
tags: ["Namespaces"]
---

# Start watching a namespace

`POST /v1/namespaces`

Start watching a Kubernetes namespace for services to forward

## Request body

- AddNamespaceRequest
  - `namespace` string, required — Kubernetes namespace to watch
  - `context` string — Kubernetes context (defaults to current context)
  - `selector` string — Label selector to filter services

## Response `200`

Namespace watcher started

- Response
  - `success` boolean
  - `data` object
  - `error` ErrorInfo
    - `code` string
    - `message` string
  - `meta` MetaInfo
    - `count` integer
    - `timestamp` string, date-time

## Other responses

- `400` — Invalid request
- `401` — Missing or invalid API key
- `409` — Namespace already being watched

---

[API](https://skmtc.net/txn2/apis/kubefwd-api.md) · [All operations](https://skmtc.net/txn2/apis/kubefwd-api/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/txn2/kubefwd-api/versions/e4f8bfb653cf/schema)
