Skip to content
Back to top
View this page

# Convenience Libraries

Using the XDG Portals D-Bus APIs directly is often difficult and error-prone. Fortunately, there are convenience libraries available that significantly ease the development of apps:

- ASHPD: a Rust crate that provides the APIs to interact with portals in idiomatic Rust. It has support for GTK4, direct X11 windows, and direct Wayland surfaces.

- libportal: small C library that provides a GObject API to interact with portals. It provides language bindings to a variety of other languages, such as Python, JavaScript, Vala, and more. It has support for GTK3, GTK4, Qt 5, and Qt 6.

- portal: a Go module that provides native APIs for interacting with portals from idiomatic Go code. It aims to be both toolkit agnostic and easy to use.

- Stargate: a Kotlin JVM library that provides idiomatic Kotlin access to all XDG portals. It is compatible with all desktop environments, and a GTK4 example application built with Java-GI is included.

- xdg_desktop_portal: a native Dart package to interact with portals in Dart and Flutter.