Skip to content

Add dbus API for adding contact with preset properties

Julian Sparber requested to merge dbus into librem5

The API takes an array of (key, value) pairs.

Supported keys: This can be specified multiple times "email-addresses", "notes", "phone-numbers" Only the last will be stored (because this properies are unique) "alias", "full-name", "nickname"

Not all properites are supported for now because they can't be easily set via dbus because they arn't a string

The API can be used via gdbus as well gdbus call --session --dest org.gnome.Contacts --object-path /org/gnome/Contacts --method org.gtk.Actions.Activate 'new-contact-data' '[<[("email-addresses", "julian@sparber.net"), ("phone-numbers", "+39333333"), ("email-addresses", "secondo@example.com")]>]' '{}'

Upstream MR: https://gitlab.gnome.org/GNOME/gnome-contacts/merge_requests/95

Fixes #22 (closed)

Edited by Julian Sparber

Merge request reports