Node-SDK is a TypeScript library to access Docker engine API (a.k.a "Moby").
npm install @docker/node-sdk
import { DockerClient } from '@docker/node-sdk';
const docker = await DockerClient.fromDockerConfig();
const containers = await docker.containerList({ all: true });
console.dir(containers);
Licensed under Apache License version 2.0 Copyright 2025, Docker Inc
tl;dr: You're free to use this code, make any changes you need, have fun with it. Contributions are welcome if you miss something.
- ContainerList
- ContainerCreate
- ContainerInspect
- ContainerTop
- ContainerLogs
- ContainerChanges
- ContainerExport
- ContainerStats
- ContainerResize
- ContainerStart
- ContainerStop
- ContainerRestart
- ContainerKill
- ContainerUpdate
- ContainerRename
- ContainerPause
- ContainerUnpause
- ContainerAttach
- ContainerAttachWebsocket
- ContainerWait
- ContainerDelete
- ContainerArchiveInfo
- ContainerArchive
- PutContainerArchive
- ContainerPrune
- ImageList
- ImageBuild
- BuildPrune
- ImageCreate
- ImageInspect
- ImageHistory
- ImagePush
- ImageTag
- ImageDelete
- ImageSearch
- ImagePrune
- ImageCommit
- ImageGet
- ImageGetAll
- ImageLoad
- NetworkList
- NetworkInspect
- NetworkDelete
- NetworkCreate
- NetworkConnect
- NetworkDisconnect
- NetworkPrune
- VolumeList
- VolumeCreate
- VolumeInspect
- VolumeUpdate
- VolumeDelete
- VolumePrune
- ContainerExec
- ExecStart
- ExecResize
- ExecInspect
- PluginList
- GetPluginPrivileges
- PluginPull
- PluginInspect
- PluginDelete
- PluginEnable
- PluginDisable
- PluginUpgrade
- PluginCreate
- PluginPush
- PluginSet
- SystemAuth
- SystemInfo
- SystemVersion
- SystemPing
- SystemPingHead
- SystemEvents
- SystemDataUsage
- DistributionInspect
- Session
- SwarmInspect
- SwarmInit
- SwarmJoin
- SwarmLeave
- SwarmUpdate
- SwarmUnlockkey
- SwarmUnlock
- NodeList
- NodeInspect
- NodeDelete
- NodeUpdate
- ServiceList
- ServiceCreate
- ServiceInspect
- ServiceDelete
- ServiceUpdate
- ServiceLogs
- TaskList
- TaskInspect
- TaskLogs
- SecretList
- SecretCreate
- SecretInspect
- SecretDelete
- SecretUpdate
- ConfigList
- ConfigCreate
- ConfigInspect
- ConfigDelete
- ConfigUpdate