Playwright for the Windows desktop, from Bun β drive native GUIs via UI Automation + MCP.
Copy the AI prompt to install this server into Claude Code, Cursor, or another agent β or use 1-click editor setup below.
π‘ Paste into ~/Library/Application Support/Claude/claude_desktop_config.json (macOS) or %APPDATA%\Claude\claude_desktop_config.json (Windows)
Zero-dependency Win32 FFI bindings for Bun on Windows. Each system DLL is a standalone @bun-win32/* package with full type definitions.
Requires Bun >= 1.1.0 and Windows 10+.
After the first call resolves the symbol via dlopen/dlsym, the native function pointer is cached directly on the class. Every subsequent call is a straight pointer invocation through Bun's FFI - no marshaling layer, no runtime type checks, no wrapper overhead. It's the same codepath as calling the C function yourself.
For hot paths, Preload() resolves symbols eagerly so even the first call pays zero binding cost:
[!IMPORTANT] If you destructure before binding, you capture the lazy wrapper instead of the native function.
All type definitions are provided by @bun-win32/core.
Published packages are AI-friendly. Alongside the README.md, each package includes an AI.md file that documents the binding contract, type surface, and source layout so coding agents can use the package correctly.
comctl32 - common controls, image lists, property sheets, DPA/DSA dynamic arrays, flat scroll bars, window subclassingcomdlg32 - common dialogs: Open / Save File, Choose Color, Choose Font, Print, Page Setup, Find / Replace, and CommDlgExtendedErrord2d1 - Direct2D: GPU-accelerated 2D β ID2D1Factory / device-context creation plus Direct2D's native affine-matrix, color-space (sRGB / scRGB), gradient-mesh (Coons-patch), and trig / vector math (D2D1CreateFactory, D2D1MakeRotateMatrix, D2D1ConvertColorSpace, β¦)d3d11 - Direct3D 11 device / swap-chain creation, D3D11-on-12 interop, WinRT IDirect3DDevice / IDirect3DSurface bridgesd3d12 - Direct3D 12 device creation, debug-layer / global-interface access, and root-signature serialize/deserialize (D3D12CreateDevice, D3D12GetDebugInterface, D3D12GetInterface, D3D12SerializeVersionedRootSignature, β¦) β modern GPU/compute/ML pathd3dcompiler_47 - HLSL β DXBC shader compilation, preprocessing, disassembly, reflection, blob part extraction, shader stripping, function linking graphdcomp - DirectComposition device/surface creation (DCompositionCreateDevice/2/3, DCompositionCreateSurfaceHandle) and the Windows-11 compositor-clock frame/statistics surface (DCompositionGetFrameId, DCompositionGetStatistics, DCompositionWaitForCompositorClock, DCompositionBoostCompositorClock) β live compositor heartbeat proven pure-FFIdwmapi - DWM composition, blur, thumbnailsdwrite - DirectWrite factory entry point (DWriteCreateFactory): system font enumeration, text layout, glyph metrics, and pure-FFI ClearType/grayscale glyph rasterization over the IDWriteFactory COM vtabledxcore - DXCore adapter-factory entry point (DXCoreCreateAdapterFactory): DXGI-independent GPU & compute-only MCDM adapter enumeration, hardware IDs, memory pools, and capability/attribute queries over the IDXCoreAdapterFactory/List/Adapter COM vtabledxgi - DXGI adapter enumeration, factory creation, debug interface (CreateDXGIFactory*, DXGIGetDebugInterface1)dxva2 - DDC/CI monitor configuration (brightness, contrast, RGB drive/gain, colour temperature, VCP), physical monitor enumeration, DXVA2 / DXVA-HD video acceleration, OPM video outputgdi32 - graphics device interfacegdiplus - GDI+ flat C API: image load/save (PNG, JPEG, BMP, GIF, TIFF, ICO), antialiased 2D drawing, paths, regions, gradients, brushes, fonts, color matrix effects, metafile recordingglu32 - OpenGL utility functionsmagnification - Magnification API: recolor the entire desktop via a 5x5 color matrix (grayscale, photo-negative, sepia, color-blindness simulation), full-screen zoom/pan transforms, magnifier-control window filtering, and pen/touch input remappingmscms - Image Color Management (ICM): ICC profiles, color transforms, sRGB / Adobe RGB / CMYK conversion via Win32 CMM, display calibration, and the Windows Color System (WCS) profile management APIopengl32 - OpenGL rendering contextuser32 - windows, messages, input, UIuxtheme - visual styles, themed controls, buffered paintingwindowscodecs - Windows Imaging Component (WIC): zero-build image decode/encode (JPEG, PNG, GIF, TIFF, BMP, HEIF), scaling, flip/rotate, pixel-format conversion, palettes, color contexts, and metadata β the full proxy-function surfaceavifil32 - Video for Windows AVIFile API: open/create .avi files, enumerate streams, read/write video, audio, MIDI, and text streams, decode frames to DIBs (AVIStreamGetFrame), mux files from streams, editable-stream cut/copy/pasteavrt - MMCSS multimedia thread scheduling: join system-profile tasks ("Pro Audio", "Games", β¦), raise AVRT priority, query the system-responsiveness reservation, and coordinate thread-ordering groups (AvSetMmThreadCharacteristicsW, AvSetMmThreadPriority, AvQuerySystemResponsiveness, AvRtCreateThreadOrderingGroup) β the low-latency audio/capture scheduling primitivesdinput8 - DirectInput 8: every non-Xbox controller β racing wheels, flight sticks / HOTAS, generic gamepads (DirectInput8Create, GetdfDIJoystick); device enumeration, capabilities, acquisition, and polling over the IDirectInput8 COM vtabledirectml - Vendor-neutral, Direct3D 12-backed machine-learning device creation (DMLCreateDevice, DMLCreateDevice1); creates a real IDMLDevice over an ID3D12Device and decodes its true max feature level over the IDMLDevice COM vtable β DirectML shipped, proven pure-FFI, audit 0 mismatchesdsound - DirectSound: playback / capture device creation & enumeration, full-duplex, and default-device GUID resolution (DirectSoundCreate8, DirectSoundEnumerateW, GetDeviceID, β¦) β synthesize and play PCM end-to-end over the IDirectSound8 / IDirectSoundBuffer COM vtablegameinput - GameInput, the modern unified input model β GameInputCreate Nano-COM factory + Dll* COM-server entries; gamepad / keyboard / mouse / flight & arcade stick / racing wheel / sensor readings over the IGameInput COM vtablemf - Media Foundation pipeline: source resolver, ASF authoring graph (profile / multiplexer / indexer / splitter / stream selector), container media sinks (MP3 / AC-3 / ADTS / MPEG-4 / fragmented-MP4 / 3GP), streaming sinks, video renderer, network credential / proxy, and the protected-environment / signed-library surface (MFCreateSourceResolver, MFCreateASFProfile, MFCreateMPEG4MediaSink, MFGetSupportedSchemes, β¦)mfplat - Media Foundation platform: lifecycle, work queues, MFT registry, media type / sample / byte stream factories (MFStartup, MFTEnumEx, MFCreateAttributes, MFCreateSample)mfreadwrite - Media Foundation source reader / sink writer factories (MFCreateSourceReader*, MFCreateSinkWriter*)mmdevapi - MMDevice / Core Audio class factory, WASAPI async activation (DllGetClassObject, ActivateAudioInterfaceAsync)quartz - DirectShow runtime: HRESULT β text (AMGetErrorTextA/W) and the Filter Graph Manager Dll* COM server (CLSID_FilterGraph β IGraphBuilder); reaches legacy webcams / capture cards / codecs Media Foundation misseswinmm - multimedia audio, MIDI, mixers, timers, joysticks, MCIxaudio2_9 - XAudio2 2.9: low-latency audio engine + voice graph, X3DAudio positional math (matrix / Doppler / LPF solve), and every built-in XAPO β volume meter, reverb, FXEQ / FXMasteringLimiter / FXReverb / FXEcho (XAudio2Create, X3DAudioInitialize, X3DAudioCalculate, CreateAudioVolumeMeter, CreateFX); synthesize and play PCM end-to-end over the IXAudio2 / IXAudio2SourceVoice COM vtablexinput1_4 - XInput 1.4: Xbox controller state, vibration, battery, audio, keystrokexinput9_1_0 - XInput 9.1.0: legacy Xbox controller state, vibration, DirectSound GUIDsbluetoothapis - Bluetooth Classic radio/device discovery, BLE GATT, SDP, authenticationdnsapi - DNS resolution across every record type (A, AAAA, MX, NS, SOA, TXT, SRV, CAA, etc.), name validation, configured server discovery, DNS-SD, mDNS, async queriesfirewallapi - Windows Firewall policy via the FirewallAPI.dll COM server (INetFwPolicy2 profile state through DllGetClassObject) plus the 9 documented network-isolation / AppContainer functions (enumerate, free, config, change subscriptions, connect-failure diagnostics) β all 13 documented exportsfwpuclnt - Windows Filtering Platform: Base Filtering Engine sessions/transactions, provider/sub-layer/layer/callout/filter CRUD + enumeration + change subscriptions, IPsec SA/tunnel/key-manager, IKE/AuthIP SAs, net-event diagnostics, ALE endpoints, Winsock secure-socket extensions β all 199 documented exportshttpapi - HTTP Server API (HTTP.sys): kernel-mode listener powering IIS, request queues, URL groups, server sessions, SSL/TLS config, response caching, HTTP/2 push, request shapingiphlpapi - network adapters, TCP/UDP tables, routingmpr - network drive mapping, UNC connections, resource enumerationnetapi32 - users, groups, shares, domain joinsntdsapi - Active Directory client: directory bind (DsBind*), name-format translation (DsCrackNames), Kerberos SPN forge/register (DsGetSpn, DsClientMakeSpnForTargetServer, DsWriteAccountSpn), site/server/role/DC enumeration, replication control (DsReplicaSync/Add/GetInfo), SID-history migration β all 81 documented exports, SPN + syntactical name-cracking work with no domainsensapi - System Event Notification Service connectivity checks (IsNetworkAlive, IsDestinationReachable)winhttp - HTTP/HTTPS client, WebSockets, proxy auto-detect (WPAD/PAC), TLS configuration, request tracingwininet - WinINet/IE-legacy stack: HTTP/HTTPS, FTP, persistent URL cache, cookie jar (InternetGetCookieEx2, InternetSetCookieEx2), autodial, per-site cookie decisionswlanapi - Native Wifi: interface enumeration, scans, profiles, Wi-Fi Directwldap32 - LDAP client: directory bind/auth, search, modify, add/delete/rename/compare, extended operations, server/client controls, paged / sorted / virtual-list-view results, StartTLS, and the BER (winber) encode/decode primitivesws2_32 - Winsock 2: BSD sockets, DNS, network I/Oprntvpt - Print Ticket / Print Schema: PrintCapabilities, DEVMODE β Print Ticket conversion, merge & validatewinspool - printer management, print jobs, spooler control, driverswtsapi32 - Terminal Services sessions, processes, virtual channels, remote desktopadvapi32 - registry, security descriptors, service controlamsi - Antimalware Scan Interface: submit scripts/buffers to the registered AV provider (Defender) for in-process scanning (AmsiInitialize, AmsiScanBuffer, AmsiScanString, AmsiNotifyOperation) β EICAR detection proven pure-FFI, no shelling outbcrypt - Cryptography Next Gen (CNG): ciphers, hashes, HMAC, PBKDF2, signatures, random bytes, key agreementcredui - credential prompts, username parsing, auth blobs, and SSPI prompt helperscrypt32 - certificate stores, chains, encoding, DPAPIfveapi - BitLocker / Full Volume Encryption (fveapi.dll): all 162 exports β volume open / lock / unlock, protection & conversion status, key packages, recovery-password backup, device-encryption support, and the DMA / HSTI security checksncrypt - CNG Key Storage: persisted keys, RSA/ECDSA/ECDH signing & key agreement, key attestation claims, DPAPI-NG protection descriptors and streamingsecur32 - SSPI authentication, credentials, LSAsspicli - SSPI client-side auth and SASLtbs - TPM Base Services: open a TBS context, submit raw TPM 2.0 command buffers, read the TCG measured-boot log, query device ID / owner-auth (Tbsi_Context_Create, Tbsip_Submit_Command, Tbsi_Get_TCG_Log, GetDeviceID) β TPM2_GetRandom / GetCapability proven pure-FFI against real hardwarewebauthn - WebAuthn / FIDO2: drive the Windows platform authenticator (Windows Hello biometrics + TPM-backed passkeys) β passkey registration & assertion, platform-credential enumeration/deletion, cancellation, and W3C DOMException error mapping (WebAuthNAuthenticatorMakeCredential, WebAuthNAuthenticatorGetAssertion, WebAuthNGetPlatformCredentialList) β a real Windows Hello passkey ceremony proven pure-FFIwinscard - smart card resource manager, reader discovery, status changes, and APDU transportwintrust - Authenticode signature verification (WinVerifyTrust), catalog admin, SIP, and trust-provider helperswscapi - Windows Security Center: aggregate provider health (firewall, antivirus, auto-update, UAC, WSC service) and change registration (WscGetSecurityProviderHealth, WscRegisterForChanges) β live security posture without parsing PowerShellactiveds - Active Directory Service Interfaces (ADSI): bind a directory object by ADsPath to IADs / IADsContainer (ADsGetObject, ADsOpenObject), enumerate container children, and round-trip binary security descriptors β WinNT / LDAP providerscabinet - Compression API (MSZIP / XPRESS / XPRESS-Huffman / LZMS) plus Cabinet (.cab) archive creation and extraction via the FCI / FDI callback interfacescfgmgr32 - device tree traversal, configuration management, device properties, interfaces, resourcescldapi - Cloud Files API (cfapi.h): all 35 documented exports β sync-root register/connect, placeholder create/convert/update/revert, hydrate/dehydrate, transfer keys, pin & in-sync state, placeholder/sync-root info, and platform version β the OneDrive Files On-Demand engine that projects zero-byte-on-disk placeholder files, proven pure-FFIclfsw32 - Common Log File System: all 53 documented user-mode + management exports β dedicated/multiplexed log creation, containers, marshaling areas, durable record reserve/append, archival, the CLFS management policy surface, and the 8-byte by-value CLFS_LSN algebra (LsnCreate/LsnContainer/LsnBlockOffset/LsnRecordSequence) β the kernel write-ahead-log engine behind TxF/TxR, proven pure-FFIclusapi - Failover Cluster API: cluster / node / group / resource / network / netinterface lifecycle, the full open / enum / control families, the cluster registry batch API, and notification ports β all 205 documented exportscombase - Windows Runtime activation core: RoInitialize/RoActivateInstance/RoGetActivationFactory, the full HSTRING string API, fast-pass/preallocated buffers, and the WinRT error-info surface β the pure-FFI path to toast notifications and the rest of the WinRT projectiondbghelp - symbol engine, stack walking, minidumps, image helpers, source-level debuggingdismapi - DISM image servicing: online/offline sessions, optional features, packages, drivers, capabilities, image health (DismInitialize, DismOpenSession, DismGetFeatures, DismCheckImageHealth) β the DISM.exe engine in-process, no spawnfltlib - Filter Manager (fltuser.h): minifilter / instance / volume enumeration, info queries, load/unload, attach/detach, and the minifilter communication-port channel (FilterFindFirst, FilterInstanceFindFirst, FilterVolumeFindFirst, FilterConnectCommunicationPort) β the file-system filter stack fltmc shows, pure-FFIhid - HID device access, feature reports, preparsed data parsingkernel32 - processes, memory, files, console, threadsktmw32 - Kernel Transaction Manager (KTM): create/open transactions, transaction managers, resource managers, and enlistments; two-phase commit/rollback (CreateTransaction, CommitTransaction, RollbackTransaction, CreateResourceManager, CreateEnlistment) β atomic transacted-NTFS / transacted-registry work, pure-FFImi - Windows Management Infrastructure client bootstrap and function-table discoverymsi - Windows Installer: product enumeration, install state, database, patchingntdll - native NT APInormaliz - internationalized domain names, Nameprep, and Unicode normalizationole32 - COM/OLE helpers, monikers, structured storage, clipboard, drag-dropoleacc - Microsoft Active Accessibility (MSAA): resolve IAccessible from a window or screen point, walk the accessibility tree, decode role/state text, marshal objects to/from LRESULToleaut32 - OLE Automation: BSTR, VARIANT, SAFEARRAY, DECIMAL, CURRENCY, type libraries, IDispatch helpers, OLE pictures, full Var*From* conversion familypdh - performance counter queries, logs, and enumerationpowrprof - power schemes, policies, sleep states, battery managementpropsys - Windows Property System: full PROPVARIANT/VARIANT conversion families, vector/array helpers, property keys (PSGetPropertyKeyFromName), property descriptions, property stores/bags, and PropVariantCompareEx (Explorer's value comparator)psapi - process status and module enumerationrasapi32 - Remote Access Service: dial-up/VPN dialing and hang-up, connection enumeration and status, phone-book entry/sub-entry/credentials/dial-params management, autodial, projection info, link/connection statistics, EAP user datarpcrt4 - RPC runtime: UUID generation (random + sequential), client/server bindings, endpoint mapper enumeration, authentication levels, extended error info, protocol sequences, MES pickling, string-binding compose/parse, DceErrorInqTextrstrtmgr - Restart Manager sessions, lock discovery, shutdown, and restart orchestrationsetupapi - device installation, INF parsing, class and interface enumerationshcore - DPI awareness, scale factors, AppUserModelID, random access streams, registry helpers, isolated-container detection, threading refsshell32 - shell operations and file managementshlwapi - shell lightweight utility functionssrclient - System Restore client: create / begin / end restore points (SRSetRestorePointW/A) and remove them (SRRemoveRestorePoint) β RESTOREPOINTINFO / STATEMGRSTATUS pack(1) structstaskschd - Task Scheduler COM server entry points, class factory activation, task enumerationtdh - Trace Data Helper: ETW event decoding (TdhGetEventInformation, TdhFormatProperty), provider / field / event-schema enumeration, value & bitmap maps, manifest loading, and payload filtersuiautomationcore - UI Automation nodes, pattern objects, provider bridging, and event plumbinguserenv - user profiles, environment blocks, and Group Policyversion - file version resources, string tables, installer version helpersvirtdisk - VHD, VHDX, and ISO virtual disk creation, attachment, inspection, and managementvssapi - Volume Shadow Copy Service: the IVssBackupComponents backup engine (CreateVssBackupComponents), writer-metadata examination, shadow-copy presence (IsVolumeSnapshotted), and revert-block policy β the documented vsbackup.h surfacewer - Windows Error Reporting report authoring/stores (WerReportCreate, WerReportSubmit, WerStoreOpen, WerStoreQueryReportMetadataV2) plus the Wait Chain Traversal deadlock-detection API (OpenThreadWaitChainSession, GetThreadWaitChain) β live kernel thread-wait X-ray proven pure-FFIwevtapi - Windows Event Log queries, rendering, subscriptions, channel configuration, publisher metadatawimgapi - Windows Imaging (WIM): create/open .wim archives, capture/apply/enumerate images, mount/unmount/split/export, references, and live progress via a WIMRegisterMessageCallback JSCallback β the DISM.exe/ImageX engine in-processwindowsaccessbridge-64 - Java Access Bridge: classify Java/Swing windows (isJavaWindow), walk the AccessibleContext tree (getAccessibleContextFromHWND / getAccessibleContextInfo / getAccessibleChildFromContext), read text/table/hypertext/value/selection info, drive actions, and register event callbacks β all 97 exports, proven against a live JDK Swing appwinusb - WinUSB device I/O, descriptors, pipes, policies, and isochronous transferswuapi - Windows Update Agent COM server (Dll* entries): the Windows Update object model β IUpdateSession / IUpdateSearcher / update-history enumeration and result decoding over the COM vtableAll packages in this repo are AI-generated using Claude Code. To add bindings for a new DLL:
Replace crypt32 with whatever DLL you're targeting. PROMPT.md uses the scaffold, catalog, runtime-probe, stub-scaffold, and audit scripts to keep the work mechanical, resumable, and less error-prone.
MIT
Showcase your server listing on GitHub or your project documentation. Embed this dynamic SVG badge to highlight official listing status and live engagement.
[](https://allmcps.com/mcp/bun-uia)<a href="https://allmcps.com/mcp/bun-uia"><img src="https://allmcps.com/api/badge/bun-uia?style=directory" alt="Bun Uia on AllMCPs" /></a>