# Endpoints

EndpointsEndpoints is a collection of endpoints that implement the actual service.apiVersion: v1import "k8s.io/api/core/v1"EndpointsEndpoints is a collection of endpoints that implement the actual service. Example:Name: "mysvc", Subsets: [ { Addresses: [{"ip": "10.10.1.1"}, {"ip": "10.10.2.2"}], Ports: [{"name": "a", "port": 8675}, {"name": "b", "port": 309}] }, { Addresses: [{"ip": "10.10.3.3"}], Ports: [{"name": "a", "port": 93}, {"name": "b", "port": 76}] }, ]Endpoints is a legacy API and does not contain information about all Service features. Use discoveryv1.EndpointSlice for complete information about Service endpoints.Deprecated: This API is deprecated in v1.33+. Use discoveryv1.EndpointSlice.apiVersion: v1kind: Endpointsmetadata (ObjectMeta)Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadatasubsets ([]EndpointSubset)Atomic: will be replaced during a mergeThe set of all endpoints is the union of all subsets. Addresses are placed into subsets according to the IPs they share. A single address with multiple ports, some of which are ready and some of which are not (because they come from different containers) will result in the address being displayed in different subsets for the different ports. No address will appear in both Addresses and NotReadyAddresses in the same subset. Sets of addresses and ports that comprise a service.*EndpointSubset is a group of addresses with a common set of ports. The expanded set of endpoints is the Cartesian product of Addresses x Ports. For example, given:{ Addresses: [{"ip": "10.10.1.1"}, {"ip": "10.10.2.2"}], Ports: [{"name": "a", "port": 8675}, {"name": "b", "port": 309}] }The resulting set of endpoints can be viewed as:a: [ 10.10.1.1:8675, 10.10.2.2:8675 ], b: [ 10.10.1.1:309, 10.10.2.2:309 ]Deprecated: This API is deprecated in v1.33+.*subsets.addresses ([]EndpointAddress)Atomic: will be replaced during a mergeIP addresses which offer the related ports that are marked as ready. These endpoints should be considered safe for load balancers and clients to utilize.EndpointAddress is a tuple that describes single IP address. Deprecated: This API is deprecated in v1.33+.subsets.addresses.ip (string), requiredThe IP of this endpoint. May not be loopback (127.0.0.0/8 or ::1), link-local (169.254.0.0/16 or fe80::/10), or link-local multicast (224.0.0.0/24 or ff02::/16).subsets.addresses.hostname (string)The Hostname of this endpointsubsets.addresses.nodeName (string)Optional: Node hosting this endpoint. This can be used to determine endpoints local to a node.subsets.addresses.targetRef (ObjectReference)Reference to object providing the endpoint.subsets.notReadyAddresses ([]EndpointAddress)Atomic: will be replaced during a mergeIP addresses which offer the related ports but are not currently marked as ready because they have not yet finished starting, have recently failed a readiness check, or have recently failed a liveness check.EndpointAddress is a tuple that describes single IP address. Deprecated: This API is deprecated in v1.33+.subsets.notReadyAddresses.ip (string), requiredThe IP of this endpoint. May not be loopback (127.0.0.0/8 or ::1), link-local (169.254.0.0/16 or fe80::/10), or link-local multicast (224.0.0.0/24 or ff02::/16).subsets.notReadyAddresses.hostname (string)The Hostname of this endpointsubsets.notReadyAddresses.nodeName (string)Optional: Node hosting this endpoint. This can be used to determine endpoints local to a node.subsets.notReadyAddresses.targetRef (ObjectReference)Reference to object providing the endpoint.subsets.ports ([]EndpointPort)Atomic: will be replaced during a mergePort numbers available on the related IP addresses.EndpointPort is a tuple that describes a single port. Deprecated: This API is deprecated in v1.33+.subsets.ports.port (int32), requiredThe port number of the endpoint.subsets.ports.protocol (string)The IP protocol for this port. Must be UDP, TCP, or SCTP. Default is TCP.subsets.ports.name (string)The name of this port. This must match the 'name' field in the corresponding ServicePort. Must be a DNS_LABEL. Optional only if one port is defined.subsets.ports.appProtocol (string)The application protocol for this port. This is used as a hint for implementations to offer richer behavior for protocols that they understand. This field follows standard Kubernetes label syntax. Valid values are either:Un-prefixed protocol names - reserved for IANA standard service names (as per RFC-6335 and https://www.iana.org/assignments/service-names).Kubernetes-defined prefixed names:'kubernetes.io/h2c' - HTTP/2 prior knowledge over cleartext as described in https://www.rfc-editor.org/rfc/rfc9113.html#name-starting-http-2-with-prior-'kubernetes.io/ws' - WebSocket over cleartext as described in https://www.rfc-editor.org/rfc/rfc6455'kubernetes.io/wss' - WebSocket over TLS as described in https://www.rfc-editor.org/rfc/rfc6455Other protocols should use implementation-defined prefixed names such as mycompany.com/my-custom-protocol.EndpointsListEndpointsList is a list of endpoints. Deprecated: This API is deprecated in v1.33+.apiVersion: v1kind: EndpointsListmetadata (ListMeta)Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kindsitems ([]Endpoints), requiredList of endpoints.Operationsget read the specified EndpointsHTTP RequestGET /api/v1/namespaces/{namespace}/endpoints/{name}Parametersname (in path): string, requiredname of the Endpointsnamespace (in path): string, requirednamespacepretty (in query): stringprettyResponse200 (Endpoints): OK401: Unauthorizedlist list or watch objects of kind EndpointsHTTP RequestGET /api/v1/namespaces/{namespace}/endpointsParametersnamespace (in path): string, requirednamespaceallowWatchBookmarks (in query): booleanallowWatchBookmarkscontinue (in query): stringcontinuefieldSelector (in query): stringfieldSelectorlabelSelector (in query): stringlabelSelectorlimit (in query): integerlimitpretty (in query): stringprettyresourceVersion (in query): stringresourceVersionresourceVersionMatch (in query): stringresourceVersionMatchsendInitialEvents (in query): booleansendInitialEventstimeoutSeconds (in query): integertimeoutSecondswatch (in query): booleanwatchResponse200 (EndpointsList): OK401: Unauthorizedlist list or watch objects of kind EndpointsHTTP RequestGET /api/v1/endpointsParametersallowWatchBookmarks (in query): booleanallowWatchBookmarkscontinue (in query): stringcontinuefieldSelector (in query): stringfieldSelectorlabelSelector (in query): stringlabelSelectorlimit (in query): integerlimitpretty (in query): stringprettyresourceVersion (in query): stringresourceVersionresourceVersionMatch (in query): stringresourceVersionMatchsendInitialEvents (in query): booleansendInitialEventstimeoutSeconds (in query): integertimeoutSecondswatch (in query): booleanwatchResponse200 (EndpointsList): OK401: Unauthorizedcreate create EndpointsHTTP RequestPOST /api/v1/namespaces/{namespace}/endpointsParametersnamespace (in path): string, requirednamespacebody: Endpoints, requireddryRun (in query): stringdryRunfieldManager (in query): stringfieldManagerfieldValidation (in query): stringfieldValidationpretty (in query): stringprettyResponse200 (Endpoints): OK201 (Endpoints): Created202 (Endpoints): Accepted401: Unauthorizedupdate replace the specified EndpointsHTTP RequestPUT /api/v1/namespaces/{namespace}/endpoints/{name}Parametersname (in path): string, requiredname of the Endpointsnamespace (in path): string, requirednamespacebody: Endpoints, requireddryRun (in query): stringdryRunfieldManager (in query): stringfieldManagerfieldValidation (in query): stringfieldValidationpretty (in query): stringprettyResponse200 (Endpoints): OK201 (Endpoints): Created401: Unauthorizedpatch partially update the specified EndpointsHTTP RequestPATCH /api/v1/namespaces/{namespace}/endpoints/{name}Parametersname (in path): string, requiredname of the Endpointsnamespace (in path): string, requirednamespacebody: Patch, requireddryRun (in query): stringdryRunfieldManager (in query): stringfieldManagerfieldValidation (in query): stringfieldValidationforce (in query): booleanforcepretty (in query): stringprettyResponse200 (Endpoints): OK201 (Endpoints): Created401: Unauthorizeddelete delete EndpointsHTTP RequestDELETE /api/v1/namespaces/{namespace}/endpoints/{name}Parametersname (in path): string, requiredname of the Endpointsnamespace (in path): string, requirednamespacebody: DeleteOptionsdryRun (in query): stringdryRungracePeriodSeconds (in query): integergracePeriodSecondsignoreStoreReadErrorWithClusterBreakingPotential (in query): booleanignoreStoreReadErrorWithClusterBreakingPotentialpretty (in query): stringprettypropagationPolicy (in query): stringpropagationPolicyResponse200 (Status): OK202 (Status): Accepted401: Unauthorizeddeletecollection delete collection of EndpointsHTTP RequestDELETE /api/v1/namespaces/{namespace}/endpointsParametersnamespace (in path): string, requirednamespacebody: DeleteOptionscontinue (in query): stringcontinuedryRun (in query): stringdryRunfieldSelector (in query): stringfieldSelectorgracePeriodSeconds (in query): integergracePeriodSecondsignoreStoreReadErrorWithClusterBreakingPotential (in query): booleanignoreStoreReadErrorWithClusterBreakingPotentiallabelSelector (in query): stringlabelSelectorlimit (in query): integerlimitpretty (in query): stringprettypropagationPolicy (in query): stringpropagationPolicyresourceVersion (in query): stringresourceVersionresourceVersionMatch (in query): stringresourceVersionMatchsendInitialEvents (in query): booleansendInitialEventstimeoutSeconds (in query): integertimeoutSecondsResponse200 (Status): OK401: UnauthorizedThis page is automatically generated.If you plan to report an issue with this page, mention that the page is auto-generated in your issue description. The fix may need to happen elsewhere in the Kubernetes project.