Description Usage Arguments Examples
Use this to POST a request to an operation. The operations should simply be specified as a path in the API i.e. "/datasets/search" to search datasets. The body can be json or an R list. Use the search_* functions for a simpler interface.
1 | post_ga4gh(client, operation, body)
|
client |
A ga4gh_client object |
operation |
The API operation to POST to as a string. Eg "/datasets/search" |
body |
The body of the POST either as JSON or a list (which will be converted to json by httr) |
1 2 3 4 5 6 7 8 9 10 11 12 13 | ## Create a client
ref_client <- ga4gh_client("http://1kgenomes.ga4gh.org", api_location = "", log_level = 1)
## A request body as a list
body_list <- list(pageSize = 2)
## Not run:
## Post to the /datasets/search operation
datasets_list <- ref_client %>% post_ga4gh("/datasets/search", body_list) %>% content
datasets_list
## End(Not run)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.