R: Helper function to get the HTTP request options for a...

labkey.getRequestOptions {Rlabkey} | R Documentation

## Helper function to get the HTTP request options for a specific method type.

### Description

The internal functions for labkey.get() and labkey.post() use this labkey.getRequestOptions() helper to build up the HTTP request options for things like CSRF, CURL options, and authentication properties. This function is also exposed for general use if you would like to make your own HTTP request but need to use those request options as set in your session context.

### Usage

    labkey.getRequestOptions(method = 'GET', encoding = NULL)

### Arguments

`method` | a string specifying the HTTP method for the request options you want to get
`encoding` | a string specifying the type of encoding to add to the header properties, defaults to UTF-8 when NULL

### Author(s)

Cory Nathe

### Examples

    library(Rlabkey)
    labkey.getRequestOptions()

[Package Rlabkey version 2.7.0 Index]