search.inputs: Search for PEcAn Models from the database

View source: R/search.inputs.R

search.inputsR Documentation

Search for PEcAn Models from the database

Description

Search PEcAn Input files from the database using search based on model_id & site_id Hits the ⁠/api/inputs/⁠ API endpoint with relevant query parameters

Usage

search.inputs(
  server,
  model_id = NULL,
  site_id = NULL,
  format_id = NULL,
  host_id = NULL,
  offset = 0,
  limit = 50
)

Arguments

server

Server object obtained using the connect() function

model_id

ID of the model associated with the input, Default: NULL (Returns all models)

site_id

ID of the model associated with the input, Default: NULL (Returns all sites)

format_id

ID of the format associated with the input, Default: NULL (Returns all formats)

host_id

ID of the host containing the input, Default: NULL (Returns all hosts)

offset

The number of workflows to skip before starting to collect the result set.

limit

The number of workflows to return (Available values : 10, 20, 50, 100, 500)

Value

Response obtained from the ⁠/api/inputs/⁠ endpoint with relevant query parameters

Author(s)

Tezan Sahu

Examples

server <- connect(url="http://pecan.localhost:80", username="carya", password="illinois")

# Get details of all inputs
res1 <- search.inputs(server)

# Get details of all inputs for the SIPNET ssr model (id = 1000000022)
res2 <- search.inputs(server, model_id="1000000022")

# Get details of all inputs for the SIPNET ssr model (id = 1000000022) & Niwor Ridge site (id = 772)
res3 <- search.inputs(server, model_id="1000000022", site_id="772")

PecanProject/rpecanapi documentation built on April 2, 2024, 8:17 a.m.