How to use global shortcuts

I saw xdg-desktop-portal now supports global shortcuts, since I don’t know how to use dbus, I was looking for info about an app that used it, so I could look at the source code and find out, or bette yet get an example here.
I looked at libportal which would do just the trick but it doesn’t seem to support shortcuts at the moment.