restbatch-requests: Send requests to the server to query the server status or...

Description Usage Arguments Value

Description

request_server

sends general request with authentication tokens ready in the request headers

request_task_list

get list of tasks of your current user ID (userid) from the server

Usage

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
request_server(
  path,
  host = default_host(),
  port = default_port(),
  protocol = default_protocol(),
  body = list(),
  header = list(),
  method = c("POST", "GET"),
  encode = "json",
  timeout = 15
)

request_task_list(
  task_status = "valid",
  host = default_host(allow0 = FALSE),
  port = default_port(),
  protocol = default_protocol(),
  path = "task/list"
)

Arguments

protocol, host, port, path

server location-related configurations, the 'url' of request will be protocol://host:port/path

body

a list of request body

header

additional header key-value pairs

method

method of request; choices are 'POST' and 'GET'

encode

serialization method to encode request body

timeout

maximum waiting time in seconds before aborting the request; default is 15. If the server is off or fails to respond before time running out, the request will result in an error.

task_status

task status to filter

Value

'httr' response. You can use content to check the response contents.


dipterix/restbatch documentation built on Oct. 13, 2021, 8:58 a.m.