Description Usage Arguments Details Value Author(s) References
This is the workhorse function that makes authenticated HTTP requests to the MTurk API. It is not exported as of v0.5.
1 2 3 4 5 6 7 8 9 10 | request(operation, GETparameters = NULL,
keypair = c(Sys.getenv("AWS_ACCESS_KEY_ID"),
Sys.getenv("AWS_SECRET_ACCESS_KEY")),
browser = getOption('MTurkR.browser', FALSE),
log.requests = getOption('MTurkR.log', TRUE),
sandbox = getOption('MTurkR.sandbox', FALSE),
verbose = getOption('MTurkR.verbose', TRUE),
validation.test = getOption('MTurkR.test', FALSE),
service = "AWSMechanicalTurkRequester",
version = NULL)
|
operation |
The MTurk API operation to be performed. |
GETparameters |
An optional character string containing URL query parameters that specify options for the request. |
keypair |
A two-element character vector containing an AWS Access Key ID and an AWS Secret Access Key. The easiest way to do this is to specify AWS_ACCESS_KEY_ID and AWS_SECRET_ACCESS_KEY environment variables using |
browser |
Optionally open the request in the default web browser, rather than opening in R. Default is |
log.requests |
A logical specifying whether API requests should be logged. Default is |
sandbox |
Optionally execute the request in the MTurk sandbox rather than the live server. Default is |
verbose |
Whether errors produced by the MTurk API request should be printed. |
validation.test |
Currently a logical that causes |
service |
The MTurk service to which the authenticated request will be sent. Supplied only for advanced users. |
version |
The version of the MTurk API to use. |
This is an internal function that executes MTurk API requests. It is made available for use by advanced users to execute custom API requests.
A list of class “MTurkResponse” containing:
operation |
A character string identifying the MTurk API operation performed. |
request.id |
The Request ID created by the API request. |
request.url |
The URL of the MTurk API REST request. |
valid |
A logical indicating whether or not the request was valid and thus executed as intended. |
xml |
A character string containing the XML API response. |
Thomas J. Leeper
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.