0

List Kubernetes types

by
Published Oct 17, 2025

Returns Kubernetes types and prices, including any region-specific rates. > --- - __CLI__. ``` linode-cli lke types ``` [Learn more...](https://techdocs.akamai.com/cloud-computing/docs/getting-started-with-the-linode-cli)

Script linode Verified

The script

Submitted by hugo697 Bun
Verified 235 days ago
1
//native
2
type Linode = {
3
  token: string;
4
};
5
/**
6
 * List Kubernetes types
7
 * Returns Kubernetes types and prices, including any region-specific rates.
8

9

10
>
11

12
---
13

14

15
- __CLI__.
16

17
    ```
18
    linode-cli lke types
19
    ```
20

21
    [Learn more...](https://techdocs.akamai.com/cloud-computing/docs/getting-started-with-the-linode-cli)
22
 */
23
export async function main(auth: Linode, apiVersion: "v4" | "v4beta") {
24
  const url = new URL(`https://api.linode.com/${apiVersion}/lke/types`);
25

26
  const response = await fetch(url, {
27
    method: "GET",
28
    headers: {
29
      Authorization: "Bearer " + auth.token,
30
    },
31
    body: undefined,
32
  });
33
  if (!response.ok) {
34
    const text = await response.text();
35
    throw new Error(`${response.status} ${text}`);
36
  }
37
  return await response.json();
38
}
39