Register a device for passthrough
client.devices.create(DeviceCreateParams { pci_address, name } body, RequestOptionsoptions?): Device { id, bound_to_vfio, created_at, 7 more }
/devices
Register a device for passthrough
Parameters
Returns
Register a device for passthrough
import Hypeman from '@onkernel/hypeman';
const client = new Hypeman({
apiKey: 'My API Key',
});
const device = await client.devices.create({ pci_address: '0000:a2:00.0' });
console.log(device.id);
{
"id": "tz4a98xxat96iws9zmbrgj3a",
"bound_to_vfio": false,
"created_at": "2025-01-15T10:00:00Z",
"device_id": "27b8",
"iommu_group": 82,
"pci_address": "0000:a2:00.0",
"type": "gpu",
"vendor_id": "10de",
"attached_to": null,
"name": "l4-gpu"
}
Returns Examples
{
"id": "tz4a98xxat96iws9zmbrgj3a",
"bound_to_vfio": false,
"created_at": "2025-01-15T10:00:00Z",
"device_id": "27b8",
"iommu_group": 82,
"pci_address": "0000:a2:00.0",
"type": "gpu",
"vendor_id": "10de",
"attached_to": null,
"name": "l4-gpu"
}