arg_spec() and return_spec() are used to create arguments for tableau_handler(). They describe the data type of the arg or return value, and can return a human-readable description that can be used to generate documentation.

arg_spec(
  type = c("character", "integer", "logical", "numeric"),
  desc = "",
  optional = grepl("\\?$", type)
)

return_spec(type = c("character", "integer", "logical", "numeric"), desc = "")

Arguments

type

A string indicating the data type that is required for this argument.

desc

A human-readable description of the argument. Used to generate documentation.

optional

If TRUE, then this argument need not be present in a request. Defaults to TRUE if type ends with a "?" character.

Value

A tableau_arg_spec object, which is a list containing details about the Tableau argument expectations

A tableau_return_spec object, which is a list containing details about the values expected to be returned to Tableau