dw_list_charts: Lists all charts

View source: R/dw_list_charts.R

dw_list_chartsR Documentation

Lists all charts

Description

Returns all created Datawrapper charts by the current user.

Usage

dw_list_charts(
  api_key = "environment",
  userId = NULL,
  published = NULL,
  search = NULL,
  order = "DESC",
  orderBy = "createdAt",
  limit = NULL
)

Arguments

api_key

Required. A Datawrapper-API-key as character string. Defaults to "environment" - tries to automatically retrieve the key that's stored in the .Reviron-file by datawrapper_auth.

userId

Optional. A numeric. Only return charts created by a certain user id.

published

Optional. A string. Use true or false (lowercase) to use this filter.

search

Optional. A string. Use this filter to search for a certain character string.

order

Optional. A string. DESC by default, might be changed to "ASC".

orderBy

Optional. A string. Is set to "createdAt" by default. Might be changed to: "id", "email", "name".

limit

Optional. A numeric. Defaults to 100. Number of charts to be retrieved.

Value

A tibble of all created charts. Not including all metadata, which can be retrievd for a single chart using dw_retrieve_chart_metadata.

total

Total number of created charts.

next

Returns the API-call for the next page

Author(s)

Benedict Witzenberger, Bob Rudis

Examples


## Not run: dw_list_charts("aBcDE") # uses the preset key in the .Renviron-file

## Not run: response_list <- dw_list_charts() # save list of charts into variable


munichrocker/DatawRappr documentation built on March 20, 2024, 6:08 a.m.