-
-
Notifications
You must be signed in to change notification settings - Fork 86
Update de dependências e higiene do pacote. #1768
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: master
Are you sure you want to change the base?
Changes from all commits
e21ff30
8a66b94
67f5e01
89f2d25
bfa094d
1ede8a5
e54d728
6fbc7b3
6cf38bc
eb14695
3c7e7eb
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,10 +1,14 @@ | ||
^renv$ | ||
^renv\.lock$ | ||
^renv/ | ||
^rbdd\.Rproj$ | ||
^\.Rproj\.user$ | ||
^LICENSE\.md$ | ||
^keys\.env$ | ||
^basedosdados\.Rproj$ | ||
^basedosdados_0\.0\.3\.tar\.gz$ | ||
^Changelog.md$ | ||
^basedosdados_.*\.tar\.gz$ | ||
^Changelog\.md$ | ||
^README\.Rmd$ | ||
^\.Rhistory$ | ||
^\.Rprofile$ | ||
^\.\.Rcheck$ |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,2 +1,6 @@ | ||
.Rproj.user | ||
inst/doc | ||
..Rcheck/ | ||
*.tar.gz | ||
.Rhistory | ||
.Rprofile |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,9 @@ | ||
Package: basedosdados | ||
Title: 'Base Dos Dados' R Client | ||
Version: 0.2.3 | ||
Authors@R: | ||
Author: Pedro Cavalcante [aut, cre], Daniel Herszenhut [aut] (<https://orcid.org/0000-0001-8066-1105>), Rodrigo Dornelles [aut] (<https://orcid.org/0000-0003-3709-4760>) | ||
Maintainer: Pedro Cavalcante <[email protected]> | ||
Authors@R: | ||
c(person(given = "Pedro", | ||
family = "Cavalcante", | ||
role = c("aut", "cre"), | ||
|
@@ -20,8 +22,8 @@ Description: An R interface to the 'Base dos Dados' API <https://basedosdados.or | |
License: MIT + file LICENSE | ||
Encoding: UTF-8 | ||
Roxygen: list(markdown = TRUE) | ||
RoxygenNote: 7.2.3 | ||
Imports: | ||
RoxygenNote: 7.3.2 | ||
Imports: | ||
purrr (>= 0.3.4), | ||
dplyr (>= 1.0.6), | ||
tibble (>= 3.1.1), | ||
|
@@ -39,7 +41,6 @@ Imports: | |
dbplyr (>= 2.1.1), | ||
scales (>= 1.1.1), | ||
DBI (>= 1.1.1), | ||
typed (>= 0.0.1), | ||
methods | ||
Suggests: | ||
rmarkdown, | ||
|
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,38 @@ | ||
#' Abstraction of an http request to the API | ||
#' @param endpoint which endpoint to request. | ||
#' @param query querystring passed as argument to the GEt request. | ||
#' @export | ||
#' @examples | ||
#' \dontrun{ | ||
#' | ||
#' bd_request( | ||
#' endpoint = "dataset_search", | ||
#' query = list( | ||
#' resource_type = "bdm_table", | ||
#' q = search_term, | ||
#' page_size = 100)) | ||
#' | ||
#' bd_request( | ||
#' endpoint = "bdm_dataset_show", | ||
#' query = list( | ||
#' dataset_id = dataset_id) | ||
#' | ||
#'} | ||
#'@return A httr::response() object. | ||
|
||
|
||
bd_request <- function( | ||
endpoint, | ||
query = list()) { | ||
|
||
base_url <- "https://basedosdados.org/api/3/action/bd_" | ||
target_endpoint <- paste0(base_url, endpoint) | ||
|
||
httr::GET( | ||
target_endpoint, | ||
encode = 'json', | ||
query = query) %>% | ||
httr::content() %>% | ||
purrr::pluck("result") | ||
|
||
} |
This file was deleted.
This file was deleted.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Uh oh!
There was an error while loading. Please reload this page.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Esse API não exite, certo @rdahis? Usamos https://backend.basedosdados.org/api/v1/graphql
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Certo! Essa era a api do ckan