feat: switch machine apis to new runtime api client

This commit is contained in:
Aarnav Tale
2025-11-04 22:40:23 -05:00
parent a68aedc297
commit d68737e410
22 changed files with 250 additions and 311 deletions
+2 -4
View File
@@ -3,14 +3,12 @@ import { readFile } from 'node:fs/promises';
import { dereference } from '@readme/openapi-parser';
import type { OpenAPIV2 } from 'openapi-types';
import { Agent, type Dispatcher, request } from 'undici';
import type { Key, Machine, PreAuthKey, User } from '~/types';
import log from '~/utils/log';
import endpointSets, { RuntimeApiClient } from './endpoints';
import ResponseError, { friendlyError } from './error';
import { friendlyError } from './error';
import ResponseError from './response-error';
import { detectApiVersion, isAtLeast, type Version } from './version';
export type RuntimeApiClient2 = {};
/**
* A low-level composed interface for interacting with the Headscale API.
* This interface provides direct access to the underlying Undici agent