retrieveProjects: Helper function that retrieves all the projectName options...

Description Usage Arguments Details Value Examples

View source: R/retrieveProjects.R

Description

Helper function that retrieves all the projectName options which a user has access to, from janus.

Usage

1
retrieveProjects(target, verbose = FALSE)

Arguments

target

A list, which can be created using magmaRset, containing your authorization 'token' (a string), a 'url' of magma to target (a string), and optional 'opts' for specifying additions parameters for curl requests (a named list).

verbose

Logical. Sets whether to report the status of the '/projects' curl request sent to janus.

Details

This function takes in the user's target containing their authorization token, and a url targeting either magma or janus. It then converts the given url to target janus, and makes a curl request to <janus-url>/projects in order to return which projects a user can access.

Value

A data.frame where elements of the 'project_name' column reflect what can be given to projectName inputs of other magmaR functions.

Examples

1
2
3
if (interactive()) {
    retrieveProjects(target = magmaRset())
}

magmaR documentation built on Oct. 2, 2021, 5:08 p.m.