Skip to content

Commit

Permalink
Initial commit
Browse files Browse the repository at this point in the history
  • Loading branch information
AlexGherardelli committed Jan 11, 2024
0 parents commit 565eb4f
Show file tree
Hide file tree
Showing 208 changed files with 31,350 additions and 0 deletions.
20 changes: 20 additions & 0 deletions .Rbuildignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
^.*\.Rproj$ # Designates the directory as an RStudio Project
^\.Rproj\.user$ # Used by RStudio for temporary files
^README\.Rmd$ # An Rmd file used to generate README.md
^LICENSE\.md$ # Full text of the license
^cran-comments\.md$ # Comments for CRAN submission
^data-raw$ # Code used to create data included in the package
^pkgdown$ # Resources used for the package website
^_pkgdown\.yml$ # Configuration info for the package website
^\.github$ # Contributing guidelines, CoC, issue templates, etc.
^\.Rhistory$
^\.gitignore$
^\.openapi-generator-ignore$
^\.travis\.yml$
^\.lintr$
^\.github$
^\.openapi-generator$
^docs$
^git_push\.sh$
^databridges\.Rcheck$
^\.\.Rcheck$
33 changes: 33 additions & 0 deletions .github/workflows/r-client.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
# This file is automatically generated by openapi-generator (https://openapi-generator.tech)
#
# Based on https://github.com/r-lib/actions/tree/v2/examples
on:
push:
branches: [main, master]
pull_request:
branches: [main, master]

name: R-CMD-check

jobs:
R-CMD-check:
runs-on: ubuntu-latest
env:
R_KEEP_PKG_SOURCE: yes
steps:
- uses: actions/checkout@v2
- uses: r-lib/actions/setup-r@v2
with:
use-public-rspm: true
- uses: r-lib/actions/setup-r-dependencies@v2
with:
extra-packages: any::rcmdcheck, any::roxygen2, any::lintr, local::.
needs: check, roxygen2, lint
- name: Lint
run: lintr::lint_package()
shell: Rscript {0}
- name: Roxygenize
run: |
roxygen2::roxygenize('.', roclets = c('rd', 'collate', 'namespace'))
shell: Rscript {0}
- uses: r-lib/actions/check-r-package@v2
39 changes: 39 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
# ref: https://github.com/github/gitignore/blob/master/R.gitignore

# History files
.Rhistory
.Rapp.history

# Session Data files
.RData

# Example code in package build process
*-Ex.R

# Output files from R CMD build
/*.tar.gz

# Output files from R CMD check
/*.Rcheck/

# RStudio files
.Rproj.user/

# produced vignettes
vignettes/*.html
vignettes/*.pdf

# OAuth2 token, see https://github.com/hadley/httr/releases/tag/v0.3
.httr-oauth

# knitr and R markdown default cache directories
/*_cache/
/cache/

# Temporary files created by R markdown
*.utf8.md
*.knit.md
.Rproj.user
.Rdata
.DS_Store
.quarto
7 changes: 7 additions & 0 deletions .lintr
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
linters: linters_with_defaults(
line_length_linter(160),
object_name_linter = NULL,
cyclocomp_linter = NULL
)
exclusions: list(
)
23 changes: 23 additions & 0 deletions .openapi-generator-ignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
# OpenAPI Generator Ignore
# Generated by openapi-generator https://github.com/openapitools/openapi-generator

# Use this file to prevent files from being overwritten by the generator.
# The patterns follow closely to .gitignore or .dockerignore.

# As an example, the C# client generator defines ApiClient.cs.
# You can make changes and tell OpenAPI Generator to ignore just this file by uncommenting the following line:
#ApiClient.cs

# You can match any string of characters against a directory, file or extension with a single asterisk (*):
#foo/*/qux
# The above matches foo/bar/qux and foo/baz/qux, but not foo/bar/baz/qux

# You can recursively match patterns against a directory, file or extension with a double asterisk (**):
#foo/**/qux
# This matches foo/bar/qux, foo/baz/qux, and foo/bar/baz/qux

# You can also negate patterns with an exclamation (!).
# For example, you can ignore all files in a docs folder with the file extension .md:
#docs/*.md
# Then explicitly reverse the ignore rule for a single file:
#!docs/README.md
206 changes: 206 additions & 0 deletions .openapi-generator/FILES
Original file line number Diff line number Diff line change
@@ -0,0 +1,206 @@
.Rbuildignore
.github/workflows/r-client.yaml
.gitignore
.lintr
.openapi-generator-ignore
.travis.yml
DESCRIPTION
NAMESPACE
README.md
R/api_client.R
R/api_response.R
R/bad_request_dto.R
R/commodities_api.R
R/commodity_dto.R
R/commodity_price_dto.R
R/commodity_processing_dto.R
R/commodity_quality_dto.R
R/commodity_units_api.R
R/coordinate.R
R/coordinate_sequence.R
R/coordinate_sequence_factory.R
R/currency_api.R
R/currency_dto.R
R/databridges_api.R
R/dimension.R
R/economic_data_api.R
R/economic_indicator_property.R
R/economic_indicator_property_paged_result.R
R/envelope.R
R/food_security_api.R
R/geometry.R
R/geometry_factory.R
R/gorp_api.R
R/gorp_value_with_changes.R
R/gorp_value_with_changes_paged_result.R
R/i_attributes_table.R
R/i_feature.R
R/ipc_value.R
R/ipc_value_paged_result.R
R/market_prices_api.R
R/markets_api.R
R/mfi_processed_data_dto.R
R/nearby_markets_dto.R
R/nts_geometry_services.R
R/ogc_geometry_type.R
R/ordinates.R
R/paged_commodity_list_dto.R
R/paged_commodity_price_list_dto.R
R/paged_commodity_weekly_aggregated_price_list_dto.R
R/paged_currency_list_dto.R
R/paged_processed_data_dto.R
R/paged_survey_list_dto.R
R/paged_xls_form_list_dto.R
R/point.R
R/precision_model.R
R/precision_models.R
R/problem_details.R
R/rpme_api.R
R/rpme_assessment.R
R/rpme_assessment_paged_result.R
R/rpme_output_values.R
R/rpme_variable.R
R/rpme_variable_paged_result.R
R/survey_details_dto.R
R/survey_list_dto.R
R/surveys_api.R
R/usd_indirect_quotation.R
R/usd_indirect_quotation_paged_result.R
R/view_extended_aggregated_price.R
R/view_extended_aggregated_price_paged_result.R
R/view_extended_alps_value.R
R/view_extended_alps_value_paged_result.R
R/weekly_aggregated_price.R
R/xls_form_definition_dto.R
R/xls_form_dto.R
R/xls_forms_api.R
docs/BadRequestDTO.md
docs/CommoditiesApi.md
docs/CommodityDTO.md
docs/CommodityPriceDTO.md
docs/CommodityProcessingDTO.md
docs/CommodityQualityDTO.md
docs/CommodityUnitsApi.md
docs/Coordinate.md
docs/CoordinateSequence.md
docs/CoordinateSequenceFactory.md
docs/CurrencyApi.md
docs/CurrencyDTO.md
docs/Dimension.md
docs/EconomicDataApi.md
docs/EconomicIndicatorProperty.md
docs/EconomicIndicatorPropertyPagedResult.md
docs/Envelope.md
docs/FoodSecurityApi.md
docs/Geometry.md
docs/GeometryFactory.md
docs/GorpApi.md
docs/GorpValueWithChanges.md
docs/GorpValueWithChangesPagedResult.md
docs/IAttributesTable.md
docs/IFeature.md
docs/IpcValue.md
docs/IpcValuePagedResult.md
docs/MFIProcessedDataDTO.md
docs/MarketPricesApi.md
docs/MarketsApi.md
docs/NearbyMarketsDTO.md
docs/NtsGeometryServices.md
docs/OgcGeometryType.md
docs/Ordinates.md
docs/PagedCommodityListDTO.md
docs/PagedCommodityPriceListDTO.md
docs/PagedCommodityWeeklyAggregatedPriceListDTO.md
docs/PagedCurrencyListDTO.md
docs/PagedProcessedDataDTO.md
docs/PagedSurveyListDTO.md
docs/PagedXlsFormListDTO.md
docs/Point.md
docs/PrecisionModel.md
docs/PrecisionModels.md
docs/ProblemDetails.md
docs/RpmeApi.md
docs/RpmeAssessment.md
docs/RpmeAssessmentPagedResult.md
docs/RpmeOutputValues.md
docs/RpmeVariable.md
docs/RpmeVariablePagedResult.md
docs/SurveyDetailsDTO.md
docs/SurveyListDTO.md
docs/SurveysApi.md
docs/UsdIndirectQuotation.md
docs/UsdIndirectQuotationPagedResult.md
docs/ViewExtendedAggregatedPrice.md
docs/ViewExtendedAggregatedPricePagedResult.md
docs/ViewExtendedAlpsValue.md
docs/ViewExtendedAlpsValuePagedResult.md
docs/WeeklyAggregatedPrice.md
docs/XlsFormDTO.md
docs/XlsFormDefinitionDTO.md
docs/XlsFormsApi.md
git_push.sh
tests/testthat.R
tests/testthat/test_bad_request_dto.R
tests/testthat/test_commodities_api.R
tests/testthat/test_commodity_dto.R
tests/testthat/test_commodity_price_dto.R
tests/testthat/test_commodity_processing_dto.R
tests/testthat/test_commodity_quality_dto.R
tests/testthat/test_commodity_units_api.R
tests/testthat/test_coordinate.R
tests/testthat/test_coordinate_sequence.R
tests/testthat/test_coordinate_sequence_factory.R
tests/testthat/test_currency_api.R
tests/testthat/test_currency_dto.R
tests/testthat/test_dimension.R
tests/testthat/test_economic_data_api.R
tests/testthat/test_economic_indicator_property.R
tests/testthat/test_economic_indicator_property_paged_result.R
tests/testthat/test_envelope.R
tests/testthat/test_food_security_api.R
tests/testthat/test_geometry.R
tests/testthat/test_geometry_factory.R
tests/testthat/test_gorp_api.R
tests/testthat/test_gorp_value_with_changes.R
tests/testthat/test_gorp_value_with_changes_paged_result.R
tests/testthat/test_i_attributes_table.R
tests/testthat/test_i_feature.R
tests/testthat/test_ipc_value.R
tests/testthat/test_ipc_value_paged_result.R
tests/testthat/test_market_prices_api.R
tests/testthat/test_markets_api.R
tests/testthat/test_mfi_processed_data_dto.R
tests/testthat/test_nearby_markets_dto.R
tests/testthat/test_nts_geometry_services.R
tests/testthat/test_ogc_geometry_type.R
tests/testthat/test_ordinates.R
tests/testthat/test_paged_commodity_list_dto.R
tests/testthat/test_paged_commodity_price_list_dto.R
tests/testthat/test_paged_commodity_weekly_aggregated_price_list_dto.R
tests/testthat/test_paged_currency_list_dto.R
tests/testthat/test_paged_processed_data_dto.R
tests/testthat/test_paged_survey_list_dto.R
tests/testthat/test_paged_xls_form_list_dto.R
tests/testthat/test_point.R
tests/testthat/test_precision_model.R
tests/testthat/test_precision_models.R
tests/testthat/test_problem_details.R
tests/testthat/test_rpme_api.R
tests/testthat/test_rpme_assessment.R
tests/testthat/test_rpme_assessment_paged_result.R
tests/testthat/test_rpme_output_values.R
tests/testthat/test_rpme_variable.R
tests/testthat/test_rpme_variable_paged_result.R
tests/testthat/test_survey_details_dto.R
tests/testthat/test_survey_list_dto.R
tests/testthat/test_surveys_api.R
tests/testthat/test_usd_indirect_quotation.R
tests/testthat/test_usd_indirect_quotation_paged_result.R
tests/testthat/test_view_extended_aggregated_price.R
tests/testthat/test_view_extended_aggregated_price_paged_result.R
tests/testthat/test_view_extended_alps_value.R
tests/testthat/test_view_extended_alps_value_paged_result.R
tests/testthat/test_weekly_aggregated_price.R
tests/testthat/test_xls_form_definition_dto.R
tests/testthat/test_xls_form_dto.R
tests/testthat/test_xls_forms_api.R
1 change: 1 addition & 0 deletions .openapi-generator/VERSION
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
7.2.0
18 changes: 18 additions & 0 deletions .travis.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
# ref: https://docs.travis-ci.com/user/languages/r/
language: r
cache:
directories:
- /home/travis/R/Library
r_packages:
- jsonlite
- httr2
- testthat
# uncomment below to install deps with devtools
#install:
#- R -e 'devtools::install_deps(dep = T)'
script:
- R CMD build .
- R CMD check *tar.gz
- R CMD INSTALL *tar.gz
after_failure:
- cat ${TRAVIS_BUILD_DIR}/namsor.Rcheck/tests/testthat.Rout.fail
15 changes: 15 additions & 0 deletions DESCRIPTION
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
Package: DataBridgesAPIr
Title: R Package Client for VAM-Data-Bridges
Version: 1.0.0
Author: person("VAM-INFO", email = "wfp.economicanalysis@wfp.org", role = c("aut", "cre"))
Maintainer: VAM-INFO <wfp.economicanalysis@wfp.org>
Description: API Documentation of the **DataBridges** platform: https://databridges.vam.wfp.org/. For API discussions and details: #api-integration-vam-data-bridges on Slack, [Teams channel](https://teams.microsoft.com/l/team/19%3a4ca595f7681f4ffa8a86b7af58832e8d%40thread.skype/conversations?groupId=cbd1e508-c6e8-459d-96b7-6cac3039c42c&tenantId=462ad9ae-d7d9-4206-b874-71b1e079776f) **API Integration** - This endpoint uses [Hey Jude](https://docs.api.wfp.org/providers/#api-patterns) pattern
URL: https://github.com/GIT_USER_ID/GIT_REPO_ID
BugReports: https://github.com/GIT_USER_ID/GIT_REPO_ID/issues
Depends: R (>= 3.3)
Encoding: UTF-8
License: Unlicense
LazyData: true
Suggests: testthat
Imports: jsonlite, httr2, R6, base64enc, stringr
RoxygenNote: 7.2.1
Loading

0 comments on commit 565eb4f

Please sign in to comment.