fwupd-client-sync: fwupd Reference Manual

## fwupd-client-sync fwupd-client-sync |

## Functions

gboolean | fwupd_client_connect ()
GPtrArray * | fwupd_client_get_devices ()
GPtrArray * | fwupd_client_get_plugins ()
GPtrArray * | fwupd_client_get_history ()
GPtrArray * | fwupd_client_get_releases ()
GPtrArray * | fwupd_client_get_downgrades ()
GPtrArray * | fwupd_client_get_upgrades ()
GPtrArray * | fwupd_client_get_details ()
GPtrArray * | fwupd_client_get_details_bytes ()
gboolean | fwupd_client_verify ()
gboolean | fwupd_client_verify_update ()
gboolean | fwupd_client_unlock ()
gboolean | fwupd_client_modify_config ()
gboolean | fwupd_client_activate ()
gboolean | fwupd_client_clear_results ()
FwupdDevice * | fwupd_client_get_results ()
GPtrArray * | fwupd_client_get_host_security_attrs ()
GPtrArray * | fwupd_client_get_host_security_events ()
FwupdDevice * | fwupd_client_get_device_by_id ()
GPtrArray * | fwupd_client_get_devices_by_guid ()
gboolean | fwupd_client_install ()
gboolean | fwupd_client_install_bytes ()
gboolean | fwupd_client_install_release ()
gboolean | fwupd_client_install_release2 ()
gboolean | fwupd_client_update_metadata ()
gboolean | fwupd_client_update_metadata_bytes ()
gboolean | fwupd_client_refresh_remote ()
gboolean | fwupd_client_modify_remote ()
gboolean | fwupd_client_modify_device ()
GHashTable * | fwupd_client_get_report_metadata ()
GPtrArray * | fwupd_client_get_remotes ()
FwupdRemote * | fwupd_client_get_remote_by_id ()
gchar ** | fwupd_client_get_approved_firmware ()
gboolean | fwupd_client_set_approved_firmware ()
gchar ** | fwupd_client_get_blocked_firmware ()
gboolean | fwupd_client_set_blocked_firmware ()
gchar * | fwupd_client_self_sign ()
gboolean | fwupd_client_set_feature_flags ()
GBytes * | fwupd_client_download_bytes ()
gboolean | fwupd_client_download_file ()
GBytes * | fwupd_client_upload_bytes ()

## Description

## Functions

### fwupd_client_connect ()

    gboolean
    fwupd_client_connect (FwupdClient *self,
                          GCancellable *cancellable,
                          GError **error);

Sets up the client ready for use. Most other methods call this for you, and do you only need to call this if you are just watching the client.

[skip]

#### Parameters

self | a FwupdClient |
cancellable | optional GCancellable. | [nullable]
error | optional return location for an error. | [nullable]

#### Returns

`TRUE` for success

Since: 0.7.1

### fwupd_client_get_devices ()

    GPtrArray *
    fwupd_client_get_devices (FwupdClient *self,
                              GCancellable *cancellable,
                              GError **error);

Gets all the devices registered with the daemon.

#### Parameters

self | a FwupdClient |
cancellable | optional GCancellable. | [nullable]
error | optional return location for an error. | [nullable]

#### Returns

results.

[element-type FwupdDevice][transfer container]

Since: 0.9.2

### fwupd_client_get_plugins ()

    GPtrArray *
    fwupd_client_get_plugins (FwupdClient *self,
                              GCancellable *cancellable,
                              GError **error);

Gets all the plugins being used the daemon.

#### Parameters

self | a FwupdClient |
cancellable | optional GCancellable. | [nullable]
error | optional return location for an error. | [nullable]

#### Returns

results.

[element-type FwupdPlugin][transfer container]

Since: 1.5.0

### fwupd_client_get_history ()

    GPtrArray *
    fwupd_client_get_history (FwupdClient *self,
                              GCancellable *cancellable,
                              GError **error);

Gets all the history.

#### Parameters

self | a FwupdClient |
cancellable | optional GCancellable. | [nullable]
error | optional return location for an error. | [nullable]

#### Returns

results.

[element-type FwupdDevice][transfer container]

Since: 1.0.4

### fwupd_client_get_releases ()

    GPtrArray *
    fwupd_client_get_releases (FwupdClient *self,
                               const gchar *device_id,
                               GCancellable *cancellable,
                               GError **error);

Gets all the releases for a specific device

#### Parameters

self | a FwupdClient |
device_id | the device ID. | [not nullable]
cancellable | optional GCancellable. | [nullable]
error | optional return location for an error. | [nullable]

#### Returns

results.

[element-type FwupdRelease][transfer container]

Since: 0.9.3

### fwupd_client_get_downgrades ()

    GPtrArray *
    fwupd_client_get_downgrades (FwupdClient *self,
                                 const gchar *device_id,
                                 GCancellable *cancellable,
                                 GError **error);

Gets all the downgrades for a specific device.

#### Parameters

self | a FwupdClient |
device_id | the device ID. | [not nullable]
cancellable | optional GCancellable. | [nullable]
error | optional return location for an error. | [nullable]

#### Returns

results.

[element-type FwupdRelease][transfer container]

Since: 0.9.8

### fwupd_client_get_upgrades ()

    GPtrArray *
    fwupd_client_get_upgrades (FwupdClient *self,
                               const gchar *device_id,
                               GCancellable *cancellable,
                               GError **error);

Gets all the upgrades for a specific device.

#### Parameters

self | a FwupdClient |
device_id | the device ID. | [not nullable]
cancellable | optional GCancellable. | [nullable]
error | optional return location for an error. | [nullable]

#### Returns

results.

[element-type FwupdRelease][transfer container]

Since: 0.9.8

### fwupd_client_get_details ()

    GPtrArray *
    fwupd_client_get_details (FwupdClient *self,
                              const gchar *filename,
                              GCancellable *cancellable,
                              GError **error);

Gets details about a specific firmware file.

#### Parameters

self | a FwupdClient |
filename | the firmware filename, e.g. `firmware.cab` |
cancellable | optional GCancellable. | [nullable]
error | optional return location for an error. | [nullable]

#### Returns

an array of results.

[transfer container][element-type FwupdDevice]

Since: 1.0.0

### fwupd_client_get_details_bytes ()

    GPtrArray *
    fwupd_client_get_details_bytes (FwupdClient *self,
                                    GBytes *bytes,
                                    GCancellable *cancellable,
                                    GError **error);

Gets details about a specific firmware file.

#### Parameters

self | a FwupdClient |
bytes | the firmware archive |
cancellable | optional GCancellable. | [nullable]
error | optional return location for an error. | [nullable]

#### Returns

an array of results.

[transfer container][element-type FwupdDevice]

Since: 1.5.0

### fwupd_client_verify ()

    gboolean
    fwupd_client_verify (FwupdClient *self,
                         const gchar *device_id,
                         GCancellable *cancellable,
                         GError **error);

Verify a specific device.

#### Parameters

self | a FwupdClient |
device_id | the device ID. | [not nullable]
cancellable | optional GCancellable. | [nullable]
error | optional return location for an error. | [nullable]

#### Returns

`TRUE` for verification success

Since: 0.7.0

### fwupd_client_verify_update ()

    gboolean
    fwupd_client_verify_update (FwupdClient *self,
                                const gchar *device_id,
                                GCancellable *cancellable,
                                GError **error);

Update the verification record for a specific device.

#### Parameters

self | a FwupdClient |
device_id | the device ID. | [not nullable]
cancellable | optional GCancellable. | [nullable]
error | optional return location for an error. | [nullable]

#### Returns

`TRUE` for verification success

Since: 0.8.0

### fwupd_client_unlock ()

    gboolean
    fwupd_client_unlock (FwupdClient *self,
                         const gchar *device_id,
                         GCancellable *cancellable,
                         GError **error);

Unlocks a specific device so firmware can be read or wrote.

#### Parameters

self | a FwupdClient |
device_id | the device ID. | [not nullable]
cancellable | optional GCancellable. | [nullable]
error | optional return location for an error. | [nullable]

#### Returns

`TRUE` for success

Since: 0.7.0

### fwupd_client_modify_config ()

    gboolean
    fwupd_client_modify_config (FwupdClient *self,
                                const gchar *key,
                                const gchar *value,
                                GCancellable *cancellable,
                                GError **error);

Modifies a daemon config option. The daemon will only respond to this request with proper permissions.

#### Parameters

self | a FwupdClient |
key | config key, e.g. `DisabledPlugins` |
value | config value, e.g. `*` |
cancellable | optional GCancellable. | [nullable]
error | optional return location for an error. | [nullable]

#### Returns

`TRUE` for success

Since: 1.2.8

### fwupd_client_activate ()

    gboolean
    fwupd_client_activate (FwupdClient *self,
                           GCancellable *cancellable,
                           const gchar *device_id,
                           GError **error);

Activates up a device, which normally means the device switches to a new firmware version. This should only be called when data loss cannot occur.

#### Parameters

self | a FwupdClient |
cancellable | optional GCancellable. | [nullable]
device_id | a device |
error | optional return location for an error. | [nullable]

#### Returns

`TRUE` for success

Since: 1.2.6

### fwupd_client_clear_results ()

    gboolean
    fwupd_client_clear_results (FwupdClient *self,
                                const gchar *device_id,
                                GCancellable *cancellable,
                                GError **error);

Clears the results for a specific device.

#### Parameters

self | a FwupdClient |
device_id | the device ID. | [not nullable]
cancellable | optional GCancellable. | [nullable]
error | optional return location for an error. | [nullable]

#### Returns

`TRUE` for success

Since: 0.7.0

### fwupd_client_get_results ()

    FwupdDevice *
    fwupd_client_get_results (FwupdClient *self,
                              const gchar *device_id,
                              GCancellable *cancellable,
                              GError **error);

Gets the results of a previous firmware update for a specific device.

#### Parameters

self | a FwupdClient |
device_id | the device ID. | [not nullable]
cancellable | optional GCancellable. | [nullable]
error | optional return location for an error. | [nullable]

#### Returns

a device, or `NULL` for failure.

[transfer full]

Since: 0.7.0

### fwupd_client_get_host_security_attrs ()

    GPtrArray *
    fwupd_client_get_host_security_attrs (FwupdClient *self,
                                          GCancellable *cancellable,
                                          GError **error);

Gets all the host security attributes from the daemon.

#### Parameters

self | a FwupdClient |
cancellable | optional GCancellable. | [nullable]
error | optional return location for an error. | [nullable]

#### Returns

attributes.

[element-type FwupdSecurityAttr][transfer container]

Since: 1.5.0

### fwupd_client_get_host_security_events ()

    GPtrArray *
    fwupd_client_get_host_security_events (FwupdClient *self,
                                           guint limit,
                                           GCancellable *cancellable,
                                           GError **error);

Gets all the host security events from the daemon.

#### Parameters

self | a FwupdClient |
limit | maximum number of events, or 0 for no limit |
cancellable | optional GCancellable. | [nullable]
error | optional return location for an error. | [nullable]

#### Returns

attributes.

[element-type FwupdSecurityAttr][transfer container]

Since: 1.7.1

### fwupd_client_get_device_by_id ()

    FwupdDevice *
    fwupd_client_get_device_by_id (FwupdClient *self,
                                   const gchar *device_id,
                                   GCancellable *cancellable,
                                   GError **error);

Gets a device by its device ID.

#### Parameters

self | a FwupdClient |
device_id | the device ID, e.g. `usb:00:01:03:03` |
cancellable | optional GCancellable. | [nullable]
error | optional return location for an error. | [nullable]

#### Returns

a device or `NULL`.

[transfer full]

Since: 0.9.3

### fwupd_client_get_devices_by_guid ()

    GPtrArray *
    fwupd_client_get_devices_by_guid (FwupdClient *self,
                                      const gchar *guid,
                                      GCancellable *cancellable,
                                      GError **error);

Gets any devices that provide a specific GUID. An error is returned if no devices contains this GUID.

#### Parameters

self | a FwupdClient |
guid | the GUID, e.g. `e22c4520-43dc-5bb3-8245-5787fead9b63` |
cancellable | optional GCancellable. | [nullable]
error | optional return location for an error. | [nullable]

#### Returns

devices or `NULL`.

[element-type FwupdDevice][transfer container]

Since: 1.4.1

### fwupd_client_install ()

    gboolean
    fwupd_client_install (FwupdClient *self,
                          const gchar *device_id,
                          const gchar *filename,
                          FwupdInstallFlags install_flags,
                          GCancellable *cancellable,
                          GError **error);

Install a file onto a specific device.

#### Parameters

self | a FwupdClient |
device_id | the device ID. | [not nullable]
filename | the filename to install |
install_flags | install flags, e.g. `FWUPD_INSTALL_FLAG_ALLOW_REINSTALL` |
cancellable | optional GCancellable. | [nullable]
error | optional return location for an error. | [nullable]

#### Returns

`TRUE` for success

Since: 0.7.0

### fwupd_client_install_bytes ()

    gboolean
    fwupd_client_install_bytes (FwupdClient *self,
                                const gchar *device_id,
                                GBytes *bytes,
                                FwupdInstallFlags install_flags,
                                GCancellable *cancellable,
                                GError **error);

Install firmware onto a specific device.

#### Parameters

self | a FwupdClient |
device_id | the device ID. | [not nullable]
bytes | cabinet archive |
install_flags | install flags, e.g. `FWUPD_INSTALL_FLAG_ALLOW_REINSTALL` |
cancellable | optional GCancellable. | [nullable]
error | optional return location for an error. | [nullable]

#### Returns

`TRUE` for success

Since: 1.4.5

### fwupd_client_install_release ()

    gboolean
    fwupd_client_install_release (FwupdClient *self,
                                  FwupdDevice *device,
                                  FwupdRelease *release,
                                  FwupdInstallFlags install_flags,
                                  GCancellable *cancellable,
                                  GError **error);

`fwupd_client_install_release` has been deprecated since version 1.5.6 and should not be used in newly-written code.

Installs a new release on a device, downloading the firmware if required.

#### Parameters

self | a FwupdClient |
device | a device |
release | a release |
install_flags | install flags, e.g. `FWUPD_INSTALL_FLAG_ALLOW_REINSTALL` |
cancellable | optional GCancellable. | [nullable]
error | optional return location for an error. | [nullable]

#### Returns

`TRUE` for success

Since: 1.4.5

### fwupd_client_install_release2 ()

    gboolean
    fwupd_client_install_release2 (FwupdClient *self,
                                   FwupdDevice *device,
                                   FwupdRelease *release,
                                   FwupdInstallFlags install_flags,
                                   FwupdClientDownloadFlags download_flags,
                                   GCancellable *cancellable,
                                   GError **error);

Installs a new release on a device, downloading the firmware if required.

#### Parameters

self | a FwupdClient |
device | a device |
release | a release |
install_flags | install flags, e.g. `FWUPD_INSTALL_FLAG_ALLOW_REINSTALL` |
download_flags | download flags, e.g. `FWUPD_CLIENT_DOWNLOAD_FLAG_NONE` |
cancellable | optional GCancellable. | [nullable]
error | optional return location for an error. | [nullable]

#### Returns

`TRUE` for success

Since: 1.5.6

### fwupd_client_update_metadata ()

    gboolean
    fwupd_client_update_metadata (FwupdClient *self,
                                  const gchar *remote_id,
                                  const gchar *metadata_fn,
                                  const gchar *signature_fn,
                                  GCancellable *cancellable,
                                  GError **error);

Updates the metadata. This allows a session process to download the metadata and metadata signing file to be passed into the daemon to be checked and parsed.

The `remote_id` allows the firmware to be tagged so that the remote can be matched when the firmware is downloaded.

#### Parameters

self | a FwupdClient |
remote_id | the remote ID, e.g. `lvfs-testing` |
metadata_fn | the XML metadata filename |
signature_fn | the GPG signature file |
cancellable | optional GCancellable. | [nullable]
error | optional return location for an error. | [nullable]

#### Returns

`TRUE` for success

Since: 1.0.0

### fwupd_client_update_metadata_bytes ()

    gboolean
    fwupd_client_update_metadata_bytes (FwupdClient *self,
                                        const gchar *remote_id,
                                        GBytes *metadata,
                                        GBytes *signature,
                                        GCancellable *cancellable,
                                        GError **error);

Updates the metadata. This allows a session process to download the metadata and metadata signing file to be passed into the daemon to be checked and parsed.

The `remote_id` allows the firmware to be tagged so that the remote can be matched when the firmware is downloaded.

#### Parameters

self | a FwupdClient |
remote_id | remote ID, e.g. `lvfs-testing` |
metadata | XML metadata data |
signature | signature data |
cancellable | optional GCancellable. | [nullable]
error | optional return location for an error. | [nullable]

#### Returns

`TRUE` for success

Since: 1.4.5

### fwupd_client_refresh_remote ()

    gboolean
    fwupd_client_refresh_remote (FwupdClient *self,
                                 FwupdRemote *remote,
                                 GCancellable *cancellable,
                                 GError **error);

Refreshes a remote by downloading new metadata.

#### Parameters

self | a FwupdClient |
remote | a FwupdRemote |
cancellable | optional GCancellable. | [nullable]
error | optional return location for an error. | [nullable]

#### Returns

`TRUE` for success

Since: 1.4.5

### fwupd_client_modify_remote ()

    gboolean
    fwupd_client_modify_remote (FwupdClient *self,
                                const gchar *remote_id,
                                const gchar *key,
                                const gchar *value,
                                GCancellable *cancellable,
                                GError **error);

Modifies a system remote in a specific way.

NOTE: User authentication may be required to complete this action.

#### Parameters

self | a FwupdClient |
remote_id | the remote ID, e.g. `lvfs-testing` |
key | the key, e.g. `Enabled` |
value | the key, e.g. `true` |
cancellable | optional GCancellable. | [nullable]
error | optional return location for an error. | [nullable]

#### Returns

`TRUE` for success

Since: 0.9.8

### fwupd_client_modify_device ()

    gboolean
    fwupd_client_modify_device (FwupdClient *self,
                                const gchar *device_id,
                                const gchar *key,
                                const gchar *value,
                                GCancellable *cancellable,
                                GError **error);

Modifies a device in a specific way. Not all properties on the FwupdDevice are settable by the client, and some may have other restrictions on `value` .

NOTE: User authentication may be required to complete this action.

#### Parameters

self | a FwupdClient |
device_id | the device ID. | [not nullable]
key | the key, e.g. `Flags`. | [not nullable]
value | the key, e.g. `reported`. | [not nullable]
cancellable | optional GCancellable. | [nullable]
error | optional return location for an error. | [nullable]

#### Returns

`TRUE` for success

Since: 1.0.4

### fwupd_client_get_report_metadata ()

    GHashTable *
    fwupd_client_get_report_metadata (FwupdClient *self,
                                      GCancellable *cancellable,
                                      GError **error);

Gets all the report metadata from the daemon.

#### Parameters

self | a FwupdClient |
cancellable | optional GCancellable. | [nullable]
error | optional return location for an error. | [nullable]

#### Returns

attributes.

[transfer container]

Since: 1.5.0

### fwupd_client_get_remotes ()

    GPtrArray *
    fwupd_client_get_remotes (FwupdClient *self,
                              GCancellable *cancellable,
                              GError **error);

Gets the list of remotes that have been configured for the system.

#### Parameters

self | a FwupdClient |
cancellable | optional GCancellable. | [nullable]
error | optional return location for an error. | [nullable]

#### Returns

list of remotes, or `NULL`.

[element-type FwupdRemote][transfer container]

Since: 0.9.3

### fwupd_client_get_remote_by_id ()

    FwupdRemote *
    fwupd_client_get_remote_by_id (FwupdClient *self,
                                   const gchar *remote_id,
                                   GCancellable *cancellable,
                                   GError **error);

Gets a specific remote that has been configured for the system.

#### Parameters

self | a FwupdClient |
remote_id | the remote ID, e.g. `lvfs-testing` |
cancellable | optional GCancellable. | [nullable]
error | optional return location for an error. | [nullable]

#### Returns

a FwupdRemote, or `NULL` if not found.

[transfer full]

Since: 0.9.3

### fwupd_client_get_approved_firmware ()

    gchar **
    fwupd_client_get_approved_firmware (FwupdClient *self,
                                        GCancellable *cancellable,
                                        GError **error);

Gets the list of approved firmware.

#### Parameters

self | a FwupdClient |
cancellable | optional GCancellable. | [nullable]
error | optional return location for an error. | [nullable]

#### Returns

checksums, or `NULL` for error.

[transfer full]

Since: 1.2.6

### fwupd_client_set_approved_firmware ()

    gboolean
    fwupd_client_set_approved_firmware (FwupdClient *self,
                                        gchar **checksums,
                                        GCancellable *cancellable,
                                        GError **error);

Sets the list of approved firmware.

#### Parameters

self | a FwupdClient |
checksums | Array of checksums. | [not nullable]
cancellable | optional GCancellable. | [nullable]
error | optional return location for an error. | [nullable]

#### Returns

`TRUE` for success

Since: 1.2.6

### fwupd_client_get_blocked_firmware ()

    gchar **
    fwupd_client_get_blocked_firmware (FwupdClient *self,
                                       GCancellable *cancellable,
                                       GError **error);

Gets the list of blocked firmware.

#### Parameters

self | a FwupdClient |
cancellable | optional GCancellable. | [nullable]
error | optional return location for an error. | [nullable]

#### Returns

checksums, or `NULL` for error.

[transfer full]

Since: 1.4.6

### fwupd_client_set_blocked_firmware ()

    gboolean
    fwupd_client_set_blocked_firmware (FwupdClient *self,
                                       gchar **checksums,
                                       GCancellable *cancellable,
                                       GError **error);

Sets the list of approved firmware.

#### Parameters

self | a FwupdClient |
checksums | Array of checksums |
cancellable | optional GCancellable. | [nullable]
error | optional return location for an error. | [nullable]

#### Returns

`TRUE` for success

Since: 1.4.6

### fwupd_client_self_sign ()

    gchar *
    fwupd_client_self_sign (FwupdClient *self,
                            const gchar *value,
                            FwupdSelfSignFlags flags,
                            GCancellable *cancellable,
                            GError **error);

Signs the data using the client self-signed certificate.

#### Parameters

self | a FwupdClient |
value | a string to sign, typically a JSON blob. | [not nullable]
flags | signing flags, e.g. `FWUPD_SELF_SIGN_FLAG_ADD_TIMESTAMP` |
cancellable | optional GCancellable. | [nullable]
error | optional return location for an error. | [nullable]

#### Returns

a signature, or `NULL` for failure

Since: 1.2.6

### fwupd_client_set_feature_flags ()

    gboolean
    fwupd_client_set_feature_flags (FwupdClient *self,
                                    FwupdFeatureFlags feature_flags,
                                    GCancellable *cancellable,
                                    GError **error);

Sets the features the client supports. This allows firmware to depend on specific front-end features, for instance showing the user an image on how to detach the hardware.

Clients can call this none or multiple times.

#### Parameters

self | a FwupdClient |
feature_flags | feature flags, e.g. `FWUPD_FEATURE_FLAG_UPDATE_TEXT` |
cancellable | optional GCancellable. | [nullable]
error | optional return location for an error. | [nullable]

#### Returns

`TRUE` for success

Since: 1.4.5

### fwupd_client_download_bytes ()

    GBytes *
    fwupd_client_download_bytes (FwupdClient *self,
                                 const gchar *url,
                                 FwupdClientDownloadFlags flags,
                                 GCancellable *cancellable,
                                 GError **error);

Downloads data from a remote server. The [method`Client.set_user_agent` ] function should be called before this method is used.

#### Parameters

self | a FwupdClient |
url | the remote URL. | [not nullable]
flags | download flags, e.g. `FWUPD_CLIENT_DOWNLOAD_FLAG_NONE` |
cancellable | optional GCancellable. | [nullable]
error | optional return location for an error. | [nullable]

#### Returns

downloaded data, or `NULL` for error.

[transfer full]

Since: 1.4.5

### fwupd_client_download_file ()

    gboolean
    fwupd_client_download_file (FwupdClient *self,
                                const gchar *url,
                                GFile *file,
                                FwupdClientDownloadFlags flags,
                                GCancellable *cancellable,
                                GError **error);

Downloads data from a remote server. The [method`Client.set_user_agent` ] function should be called before this method is used.

#### Parameters

self | a FwupdClient |
url | the remote URL. | [not nullable]
file | a file. | [not nullable]
flags | download flags, e.g. `FWUPD_CLIENT_DOWNLOAD_FLAG_NONE` |
cancellable | optional GCancellable. | [nullable]
error | optional return location for an error. | [nullable]

#### Returns

`TRUE` if the file was written

Since: 1.5.2

### fwupd_client_upload_bytes ()

    GBytes *
    fwupd_client_upload_bytes (FwupdClient *self,
                               const gchar *url,
                               const gchar *payload,
                               const gchar *signature,
                               FwupdClientUploadFlags flags,
                               GCancellable *cancellable,
                               GError **error);

Uploads data to a remote server. The [method`Client.set_user_agent` ] function should be called before this method is used.

#### Parameters

self | a FwupdClient |
url | the remote URL. | [not nullable]
payload | payload string. | [not nullable]
signature | signature string. | [nullable]
flags | download flags, e.g. `FWUPD_CLIENT_DOWNLOAD_FLAG_NONE` |
cancellable | optional GCancellable. | [nullable]
error | optional return location for an error. | [nullable]

#### Returns

response data, or `NULL` for error.

[transfer full]

Since: 1.4.5