### Constructor

# Rest Proxy new_with_authentication

#### Declaration [src]

    RestProxy*
    rest_proxy_new_with_authentication (
      const gchar* url_format,
      gboolean binding_required,
      const gchar* username,
      const gchar* password
    )

#### Description [src]

Create a new `RestProxy` for the specified endpoint `url_format`, using the “GET” method.

Set `binding_required` to `TRUE` if the URL contains string formatting operations (for example “http://foo.com/%s”. These must be expanded using `rest_proxy_bind()` before invoking the proxy.

#### Parameters

`url_format`

  Type: `const gchar*`

  The endpoint URL.

  The data is owned by the caller of the function.
  The value is a NUL terminated UTF-8 string.

`binding_required`

  Type: `gboolean`

  Whether the URL needs to be bound before calling.

`username`

  Type: `const gchar*`

  The username provided by the user or client.

  The data is owned by the caller of the function.
  The value is a NUL terminated UTF-8 string.

`password`

  Type: `const gchar*`

  The password provided by the user or client.

  The data is owned by the caller of the function.
  The value is a NUL terminated UTF-8 string.

#### Return value

Type: `RestProxy`

A new `RestProxy`.

The caller of the function takes ownership of the data, and is responsible for freeing it.