Skip to content

Get

Performs the request using the GET method.

1
myRestRequest.Get():RestResponse

Returns

A RestResponse instance containing the server's response.

Remarks

This method expects the response status code to be OK (200) or No Content (204), unless RestRequest.Expect is used.

Examples

Download a file as Base64

1
2
3
4
5
var pdf = $Rest.Create('https://api.example.com/')
    .Request('invoices/{id}/pdf')
    .AddUrlParameter('id', $Xml.Evaluate('InvoiceId'))
    .Get()
    .ToBase64();

See Also