The OpenShift REST API is the nerve center of the platform. Every object, every pod, every deployment flows through it. If you want control, you speak its language.
OpenShift exposes its REST API over HTTPS. It follows Kubernetes conventions but adds its own extensions. Resources are organized by API groups and versions. You interact by sending HTTP requests: GET to list, POST to create, PUT or PATCH to update, DELETE to remove. Authentication runs through OAuth tokens, and RBAC decides what’s allowed.
The /api endpoint holds core Kubernetes resources. /oapi contains the older OpenShift-specific ones, though newer features often live under /apis/<group>/<version>. Each resource has a defined schema in JSON. The API paths map to namespaces, letting you target specific projects or clusters. Responses are clean JSON payloads, ready for parsing or direct consumption.
Paging and watch queries are built in. Use limit and continue to page through large data sets. Append ?watch=true to stream changes in real time. This is essential when building controllers or tools that react fast to events in OpenShift.