Hacker News new | ask | show | jobs
by fjasdfwa 358 days ago
kube-apiserver uses a JSON REST API. You can use whatever serializes to JSON. YAML is the most common and already works directly with kubectl.

I personally use TypeScript since it has unions and structural typing with native JSON support but really anything can work.

1 comments

Fun fact, while digging into the sibling comment's complaint about the OpenAPI spec, I learned that it actually advertises multiple content-types:

  application/json
  application/json;stream=watch
  application/vnd.kubernetes.protobuf
  application/vnd.kubernetes.protobuf;stream=watch
  application/yaml
which I presume all get coerced into protobuf before being actually interpreted