├── .Rbuildignore ├── .github ├── .gitignore └── workflows │ ├── R-CMD-check.yaml │ ├── pkgdown.yaml │ └── test-coverage.yaml ├── .gitignore ├── DESCRIPTION ├── LICENSE ├── LICENSE.md ├── NAMESPACE ├── NEWS.md ├── PSAWR.Rproj ├── R ├── data.R ├── data_structures.R ├── search.R ├── sysdata.rda └── utils.R ├── README.Rmd ├── README.md ├── _pkgdown.yml ├── codecov.yml ├── cran-comments.md ├── data-raw ├── empty.R └── ps_params.R ├── data └── ps_params.rda ├── inst └── CITATION ├── man ├── figures │ └── logo.png ├── ps_params.Rd ├── search_comments.Rd ├── search_submissions.Rd └── to_epoch.Rd └── tests ├── fixtures ├── search_comments_default.yml └── search_submissions_default.yml ├── testthat.R └── testthat ├── setup-PSAWR.R └── test-search.R /.Rbuildignore: -------------------------------------------------------------------------------- 1 | ^.*\.Rproj$ 2 | ^\.Rproj\.user$ 3 | ^README\.Rmd$ 4 | ^LICENSE\.md$ 5 | ^\.httr-oauth$ 6 | ^data-raw$ 7 | ^\.github$ 8 | ^codecov\.yml$ 9 | ^cran-comments\.md$ 10 | ^CRAN-SUBMISSION$ 11 | ^_pkgdown\.yml$ 12 | ^docs$ 13 | ^pkgdown$ 14 | -------------------------------------------------------------------------------- /.github/.gitignore: -------------------------------------------------------------------------------- 1 | *.html 2 | -------------------------------------------------------------------------------- /.github/workflows/R-CMD-check.yaml: -------------------------------------------------------------------------------- 1 | # Workflow derived from https://github.com/r-lib/actions/tree/v2/examples 2 | # Need help debugging build failures? Start at https://github.com/r-lib/actions#where-to-find-help 3 | on: 4 | push: 5 | branches: [main, master] 6 | pull_request: 7 | branches: [main, master] 8 | 9 | name: R-CMD-check 10 | 11 | jobs: 12 | R-CMD-check: 13 | runs-on: ${{ matrix.config.os }} 14 | 15 | name: ${{ matrix.config.os }} (${{ matrix.config.r }}) 16 | 17 | strategy: 18 | fail-fast: false 19 | matrix: 20 | config: 21 | - {os: macos-latest, r: 'release'} 22 | - {os: windows-latest, r: 'release'} 23 | - {os: ubuntu-latest, r: 'devel', http-user-agent: 'release'} 24 | - {os: ubuntu-latest, r: 'release'} 25 | - {os: ubuntu-latest, r: 'oldrel-1'} 26 | 27 | env: 28 | GITHUB_PAT: ${{ secrets.GITHUB_TOKEN }} 29 | R_KEEP_PKG_SOURCE: yes 30 | 31 | steps: 32 | - uses: actions/checkout@v3 33 | 34 | - uses: r-lib/actions/setup-pandoc@v2 35 | 36 | - uses: r-lib/actions/setup-r@v2 37 | with: 38 | r-version: ${{ matrix.config.r }} 39 | http-user-agent: ${{ matrix.config.http-user-agent }} 40 | use-public-rspm: true 41 | 42 | - uses: r-lib/actions/setup-r-dependencies@v2 43 | with: 44 | extra-packages: any::rcmdcheck 45 | needs: check 46 | 47 | - uses: r-lib/actions/check-r-package@v2 48 | with: 49 | upload-snapshots: true 50 | -------------------------------------------------------------------------------- /.github/workflows/pkgdown.yaml: -------------------------------------------------------------------------------- 1 | # Workflow derived from https://github.com/r-lib/actions/tree/v2/examples 2 | # Need help debugging build failures? Start at https://github.com/r-lib/actions#where-to-find-help 3 | on: 4 | push: 5 | branches: [main, master] 6 | pull_request: 7 | branches: [main, master] 8 | release: 9 | types: [published] 10 | workflow_dispatch: 11 | 12 | name: pkgdown 13 | 14 | jobs: 15 | pkgdown: 16 | runs-on: ubuntu-latest 17 | # Only restrict concurrency for non-PR jobs 18 | concurrency: 19 | group: pkgdown-${{ github.event_name != 'pull_request' || github.run_id }} 20 | env: 21 | GITHUB_PAT: ${{ secrets.GITHUB_TOKEN }} 22 | permissions: 23 | contents: write 24 | steps: 25 | - uses: actions/checkout@v3 26 | 27 | - uses: r-lib/actions/setup-pandoc@v2 28 | 29 | - uses: r-lib/actions/setup-r@v2 30 | with: 31 | use-public-rspm: true 32 | 33 | - uses: r-lib/actions/setup-r-dependencies@v2 34 | with: 35 | extra-packages: any::pkgdown, local::. 36 | needs: website 37 | 38 | - name: Build site 39 | run: pkgdown::build_site_github_pages(new_process = FALSE, install = FALSE) 40 | shell: Rscript {0} 41 | 42 | - name: Deploy to GitHub pages 🚀 43 | if: github.event_name != 'pull_request' 44 | uses: JamesIves/github-pages-deploy-action@v4.4.1 45 | with: 46 | clean: false 47 | branch: gh-pages 48 | folder: docs 49 | -------------------------------------------------------------------------------- /.github/workflows/test-coverage.yaml: -------------------------------------------------------------------------------- 1 | # Workflow derived from https://github.com/r-lib/actions/tree/v2/examples 2 | # Need help debugging build failures? Start at https://github.com/r-lib/actions#where-to-find-help 3 | on: 4 | push: 5 | branches: [main, master] 6 | pull_request: 7 | branches: [main, master] 8 | 9 | name: test-coverage 10 | 11 | jobs: 12 | test-coverage: 13 | runs-on: ubuntu-latest 14 | env: 15 | GITHUB_PAT: ${{ secrets.GITHUB_TOKEN }} 16 | 17 | steps: 18 | - uses: actions/checkout@v3 19 | 20 | - uses: r-lib/actions/setup-r@v2 21 | with: 22 | use-public-rspm: true 23 | 24 | - uses: r-lib/actions/setup-r-dependencies@v2 25 | with: 26 | extra-packages: any::covr 27 | needs: coverage 28 | 29 | - name: Test coverage 30 | run: | 31 | covr::codecov( 32 | quiet = FALSE, 33 | clean = FALSE, 34 | install_path = file.path(Sys.getenv("RUNNER_TEMP"), "package") 35 | ) 36 | shell: Rscript {0} 37 | 38 | - name: Show testthat output 39 | if: always() 40 | run: | 41 | ## -------------------------------------------------------------------- 42 | find ${{ runner.temp }}/package -name 'testthat.Rout*' -exec cat '{}' \; || true 43 | shell: bash 44 | 45 | - name: Upload test results 46 | if: failure() 47 | uses: actions/upload-artifact@v3 48 | with: 49 | name: coverage-test-failures 50 | path: ${{ runner.temp }}/package 51 | -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | .Rproj.user 2 | .Rhistory 3 | .RData 4 | .Ruserdata 5 | .httr-oauth 6 | docs 7 | -------------------------------------------------------------------------------- /DESCRIPTION: -------------------------------------------------------------------------------- 1 | Package: PSAWR 2 | Type: Package 3 | Title: 'Pushshift' API Wrapper for 'Reddit' Submission and Comment Search 4 | Version: 0.1.0 5 | Authors@R: 6 | person(given = "David", 7 | family = "Schoch", 8 | role = c("aut", "cre"), 9 | email = "david@schochastics.net", 10 | comment = c(ORCID = "0000-0003-2952-4812")) 11 | Description: Connects to the API of to search for 'Reddit' comments and submissions. 12 | URL: https://github.com/schochastics/PSAWR/, https://schochastics.github.io/PSAWR/ 13 | BugReports: https://github.com/schochastics/PSAWR/issues 14 | License: MIT + file LICENSE 15 | Encoding: UTF-8 16 | LazyData: true 17 | Depends: 18 | R (>= 3.6) 19 | Imports: 20 | dplyr, 21 | httr, 22 | tibble 23 | RoxygenNote: 7.2.3 24 | Suggests: 25 | covr, 26 | testthat (>= 3.0.0), 27 | vcr (>= 0.6.0) 28 | Config/testthat/edition: 3 29 | -------------------------------------------------------------------------------- /LICENSE: -------------------------------------------------------------------------------- 1 | YEAR: 2022 2 | COPYRIGHT HOLDER: PSRAWR authors 3 | -------------------------------------------------------------------------------- /LICENSE.md: -------------------------------------------------------------------------------- 1 | # MIT License 2 | 3 | Copyright (c) 2022 PSRAWR authors 4 | 5 | Permission is hereby granted, free of charge, to any person obtaining a copy 6 | of this software and associated documentation files (the "Software"), to deal 7 | in the Software without restriction, including without limitation the rights 8 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 9 | copies of the Software, and to permit persons to whom the Software is 10 | furnished to do so, subject to the following conditions: 11 | 12 | The above copyright notice and this permission notice shall be included in all 13 | copies or substantial portions of the Software. 14 | 15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 18 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 19 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 20 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE 21 | SOFTWARE. 22 | -------------------------------------------------------------------------------- /NAMESPACE: -------------------------------------------------------------------------------- 1 | # Generated by roxygen2: do not edit by hand 2 | 3 | export(search_comments) 4 | export(search_submissions) 5 | export(to_epoch) 6 | -------------------------------------------------------------------------------- /NEWS.md: -------------------------------------------------------------------------------- 1 | # PSAWR 0.1.0 2 | 3 | * Added a `NEWS.md` file to track changes to the package. 4 | -------------------------------------------------------------------------------- /PSAWR.Rproj: -------------------------------------------------------------------------------- 1 | Version: 1.0 2 | 3 | RestoreWorkspace: Default 4 | SaveWorkspace: Default 5 | AlwaysSaveHistory: Default 6 | 7 | EnableCodeIndexing: Yes 8 | UseSpacesForTab: Yes 9 | NumSpacesForTab: 2 10 | Encoding: UTF-8 11 | 12 | RnwWeave: Sweave 13 | LaTeX: pdfLaTeX 14 | 15 | AutoAppendNewline: Yes 16 | StripTrailingWhitespace: Yes 17 | 18 | BuildType: Package 19 | PackageUseDevtools: Yes 20 | PackageInstallArgs: --no-multiarch --with-keep.source 21 | -------------------------------------------------------------------------------- /R/data.R: -------------------------------------------------------------------------------- 1 | #' Pushshift.io parameters for all endpoints 2 | #' @format tibble of Endpoint Paramters 3 | #' @source https://pushshift.io/api-parameters/ 4 | "ps_params" 5 | -------------------------------------------------------------------------------- /R/data_structures.R: -------------------------------------------------------------------------------- 1 | parse_comment <- function(comment){ 2 | empty <- empty[["comment"]] 3 | if (is.null(comment)) { 4 | output <- empty 5 | } else{ 6 | singular_fields <- c("archived", "associated_award", "author", "author_flair_background_color", 7 | "author_flair_css_class", "author_flair_template_id", "author_flair_text", 8 | "author_flair_text_color", "author_flair_type", "author_fullname", 9 | "author_patreon_flair", "author_premium", "body", "body_sha1", 10 | "can_gild", "collapsed", "collapsed_because_crowd_control", "collapsed_reason", 11 | "collapsed_reason_code", "comment_type", "controversiality", 12 | "created_utc", "distinguished", "gilded", "id", "is_submitter", 13 | "link_id", "locked", "no_follow", "parent_id", "permalink", "retrieved_utc", 14 | "score", "score_hidden", "send_replies", "stickied", "subreddit", 15 | "subreddit_id", "subreddit_name_prefixed", "subreddit_type", 16 | "top_awarded_type", "total_awards_received", "unrepliable_reason" 17 | ) 18 | singular_list <- lapply(comment[singular_fields], function(x) ifelse(is.null(x), 19 | NA, x)) 20 | names(singular_list) <- singular_fields 21 | output <- tibble::as_tibble(singular_list) 22 | list_fields <- c("all_awardings", "author_flair_richtext", "gildings", "treatment_tags") 23 | for(field in list_fields){ 24 | if(length(comment[[field]])==0){ 25 | output[[field]] <- I(list(list())) 26 | } else{ 27 | output[[field]] <- list(dplyr::bind_rows(comment[[field]])) 28 | } 29 | 30 | } 31 | } 32 | output 33 | } 34 | 35 | parse_submission <- function(submission){ 36 | empty <- empty[["submission"]] 37 | if (is.null(comment)) { 38 | output <- empty 39 | } else{ 40 | singular_fields <- c("allow_live_comments", "author", "author_flair_css_class", 41 | "author_flair_text", "author_flair_type", "author_fullname", 42 | "author_is_blocked", "author_patreon_flair", "author_premium", 43 | "can_mod_post", "contest_mode", "created_utc", "domain", "full_link", 44 | "id", "is_created_from_ads_ui", "is_crosspostable", "is_meta", 45 | "is_original_content", "is_reddit_media_domain", "is_robot_indexable", 46 | "is_self", "is_video", "link_flair_background_color", "link_flair_css_class", 47 | "link_flair_template_id", "link_flair_text", "link_flair_text_color", 48 | "link_flair_type", "locked", "media_only", "no_follow", "num_comments", 49 | "num_crossposts", "over_18", "parent_whitelist_status", "permalink", 50 | "pinned", "pwls", "retrieved_on", "score", "selftext", "send_replies", 51 | "spoiler", "stickied", "subreddit", "subreddit_id", "subreddit_subscribers", 52 | "subreddit_type", "thumbnail", "title", "total_awards_received", 53 | "upvote_ratio", "url", "whitelist_status", "wls") 54 | singular_list <- lapply(submission[singular_fields], function(x) ifelse(is.null(x), 55 | NA, x)) 56 | names(singular_list) <- singular_fields 57 | output <- tibble::as_tibble(singular_list) 58 | list_fields <- c("all_awardings", "author_flair_richtext", "awarders", "gildings", 59 | "link_flair_richtext", "treatment_tags") 60 | for(field in list_fields){ 61 | if(length(submission[[field]])==0){ 62 | output[[field]] <- I(list(list())) 63 | } else{ 64 | output[[field]] <- list(dplyr::bind_rows(submission[[field]])) 65 | } 66 | 67 | } 68 | } 69 | output 70 | } 71 | 72 | v <- function (FUN) { 73 | v_FUN <- function(x) { 74 | dplyr::bind_rows(lapply(x, FUN)) 75 | } 76 | return(v_FUN) 77 | } 78 | -------------------------------------------------------------------------------- /R/search.R: -------------------------------------------------------------------------------- 1 | #' Search Pushshift.io for Reddit comments 2 | #' 3 | #' @param q character, Query term 4 | #' @param subreddit Restrict results to subreddit (use "!" to negate, comma delimited for multiples) 5 | #' @param size integer, Number of results to return 6 | #' @param after integer, Restrict results to those made after this epoch time 7 | #' @param before integer, Restrict results to those made before this epoch time 8 | #' @param parse_date logical, should epoch time be converted to date? defaults to TRUE 9 | #' @param verbose logical, Whether to display messages 10 | #' @param ... Further arguments passed as query parameters. See [ps_params] for all possible parameters. 11 | #' @details Use [to_epoch] to convert a date to epoch time 12 | #' @return tibble of comments 13 | #' @export 14 | #' @examples 15 | #' \dontrun{ 16 | #' # get the last 100 comments with the word 'cats' 17 | #' search_comments(q = "cats", size = 100) 18 | #' } 19 | search_comments <- function(q = "",subreddit = NULL,size = 25,after = NULL,before = NULL,parse_date = TRUE,verbose = TRUE,...){ 20 | params <- handle_params(q = q, subreddit = subreddit,size = size, after = after, before = before,...) 21 | make_get_request(path = "reddit/comment/search",params = params,FUN = v(parse_comment),parse_date = parse_date,verbose = verbose) 22 | } 23 | 24 | #' Search Pushshift.io for Reddit submissions 25 | #' 26 | #' @inheritParams search_comments 27 | #' @details Use [to_epoch] to convert a date to epoch time 28 | #' @return tibble of submissions 29 | #' @export 30 | #' 31 | #' @examples 32 | #' \dontrun{ 33 | #' # get the last 100 submissions with the word 'dogs' in the subreddit 'r/animals' 34 | #' search_submissions(q = "dogs", subreddit = "animals", size = 100) 35 | #' } 36 | search_submissions <- function(q = "",subreddit = NULL,size = 25,after = NULL,before = NULL,parse_date = TRUE,verbose = TRUE,...){ 37 | params <- handle_params(q = q, subreddit = subreddit,size = size, after = after, before = before,...) 38 | make_get_request(path = "reddit/submission/search",params = params,FUN = v(parse_submission),parse_date = parse_date,verbose = verbose) 39 | } 40 | -------------------------------------------------------------------------------- /R/sysdata.rda: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/schochastics/PSAWR/0f9ad4af42acc739da09f5525e82dbb11ca47df0/R/sysdata.rda -------------------------------------------------------------------------------- /R/utils.R: -------------------------------------------------------------------------------- 1 | make_get_request <- function(path,params,FUN,verbose = verbose,parse_date = TRUE){ 2 | url <- httr::parse_url("") 3 | url$hostname <- "api.pushshift.io" 4 | url$scheme <- "https" 5 | #check if paging is needed 6 | n <- params[["size"]] 7 | page_size <- 249 #TODO:is 250 always the limit? seems to fluctuate also 8 | params[["size"]] <- min(params[["size"]],page_size) 9 | pages <- ceiling(n/page_size) 10 | output <- vector("list") 11 | if(!is.null(params[["after"]]) | !is.null(params[["after_id"]])){ 12 | pager <- "after" 13 | } else{ 14 | pager <- "before" 15 | } 16 | i <- 1 17 | nobj <- 0 18 | while(i<=pages | nobj 6 | 7 | ```{r, include = FALSE} 8 | knitr::opts_chunk$set( 9 | collapse = TRUE, 10 | comment = "#>", 11 | fig.path = "man/figures/README-", 12 | out.width = "100%" 13 | ) 14 | ``` 15 | 16 | # PSAWR 17 | 18 | 19 | [![R-CMD-check](https://github.com/schochastics/PSAWR/actions/workflows/R-CMD-check.yaml/badge.svg)](https://github.com/schochastics/PSAWR/actions/workflows/R-CMD-check.yaml) 20 | [![Codecov test coverage](https://codecov.io/gh/schochastics/PSAWR/branch/main/graph/badge.svg)](https://app.codecov.io/gh/schochastics/PSAWR?branch=main) 21 | [![CRAN status](https://www.r-pkg.org/badges/version/PSAWR)](https://CRAN.R-project.org/package=PSAWR) 22 | 23 | 24 | `PSAWR` is a **P**ush**s**ift.io **A**PI **W**rapper written in **R** for comment/submission search 25 | for Reddit. 26 | 27 | **Reddit is revoking the API access of pushshift ([message](https://www.reddit.com/r/modnews/comments/134tjpe/reddit_data_api_update_changes_to_pushshift_access/),2023-05-02) 28 | once this is enforced, the package will probably stop working** 29 | 30 | ## Installation 31 | 32 | You can install the development version of PSAWR like so: 33 | 34 | ``` r 35 | devtools::install_github("schochastics/PSAWR") 36 | ``` 37 | 38 | ## Search comments 39 | 40 | Get the last 100 comments mentioning dogs in the subreddit cats. 41 | ```r 42 | search_coments(q = "dogs", subreddit = "cats", size = 100) 43 | ``` 44 | 45 | ## Search subreddits 46 | Get the last 10 submissions mentioning cats in the subreddit dogs. 47 | ```r 48 | search_submissions(q="cats", subreddit = "dogs",size = 10) 49 | ``` 50 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | # PSAWR 5 | 6 | 7 | 8 | [![R-CMD-check](https://github.com/schochastics/PSAWR/actions/workflows/R-CMD-check.yaml/badge.svg)](https://github.com/schochastics/PSAWR/actions/workflows/R-CMD-check.yaml) 9 | [![Codecov test 10 | coverage](https://codecov.io/gh/schochastics/PSAWR/branch/main/graph/badge.svg)](https://app.codecov.io/gh/schochastics/PSAWR?branch=main) 11 | [![CRAN 12 | status](https://www.r-pkg.org/badges/version/PSAWR)](https://CRAN.R-project.org/package=PSAWR) 13 | 14 | 15 | `PSAWR` is a **P**ush**s**ift.io **A**PI **W**rapper written in **R** 16 | for comment/submission search for Reddit. 17 | 18 | **Reddit is revoking the API access of pushshift 19 | ([message](https://www.reddit.com/r/modnews/comments/134tjpe/reddit_data_api_update_changes_to_pushshift_access/),2023-05-02) 20 | once this is enforced, the package will probably stop working** 21 | 22 | ## Installation 23 | 24 | You can install the development version of PSAWR like so: 25 | 26 | ``` r 27 | devtools::install_github("schochastics/PSAWR") 28 | ``` 29 | 30 | ## Search comments 31 | 32 | Get the last 100 comments mentioning dogs in the subreddit cats. 33 | 34 | ``` r 35 | search_coments(q = "dogs", subreddit = "cats", size = 100) 36 | ``` 37 | 38 | ## Search subreddits 39 | 40 | Get the last 10 submissions mentioning cats in the subreddit dogs. 41 | 42 | ``` r 43 | search_submissions(q="cats", subreddit = "dogs",size = 10) 44 | ``` 45 | -------------------------------------------------------------------------------- /_pkgdown.yml: -------------------------------------------------------------------------------- 1 | url: https://schochastics.github.io/PSAWR/ 2 | template: 3 | bootstrap: 5 4 | bslib: 5 | bg: "#F9F7F7" 6 | fg: "#112D4E" 7 | primary: "#3F72AF" 8 | navbar-color: "#FFFFFF" 9 | base_font: {google: "Roboto"} 10 | heading_font: {google: "Roboto Slab"} 11 | code_font: {google: "JetBrains Mono"} 12 | navbar: 13 | bg: none 14 | type: light 15 | structure: 16 | left: [intro, reference, articles, news] 17 | right: [github] 18 | 19 | -------------------------------------------------------------------------------- /codecov.yml: -------------------------------------------------------------------------------- 1 | comment: false 2 | 3 | coverage: 4 | status: 5 | project: 6 | default: 7 | target: auto 8 | threshold: 1% 9 | informational: true 10 | patch: 11 | default: 12 | target: auto 13 | threshold: 1% 14 | informational: true 15 | -------------------------------------------------------------------------------- /cran-comments.md: -------------------------------------------------------------------------------- 1 | ## Resubmission Initial submission 0.1.0 2 | 3 | Fixed the bibentry and names in single quotes 4 | 5 | *(dontrun examples are used to not make unnecessary API calls)* 6 | 7 | # Test environments 8 | * ubuntu 22.04, R 4.2.2 9 | * win-builder (devel and release) 10 | 11 | ## R CMD check results 12 | 13 | 0 errors | 0 warnings | 1 note 14 | 15 | * This is a new release. 16 | -------------------------------------------------------------------------------- /data-raw/empty.R: -------------------------------------------------------------------------------- 1 | ## code to prepare `empty` dataset goes here 2 | empty <- list() 3 | 4 | empty[["comment"]] <- tibble::tibble( 5 | all_awardings = I(list(list())), 6 | archived = NA, 7 | associated_award = NA_character_, 8 | author = NA_character_, 9 | author_flair_background_color = NA_character_, 10 | author_flair_css_class = NA_character_, 11 | author_flair_richtext = I(list(list())), 12 | author_flair_template_id = NA_character_, 13 | author_flair_text = NA_character_, 14 | author_flair_text_color = NA_character_, 15 | author_flair_type = NA_character_, 16 | author_fullname = NA_character_, 17 | author_patreon_flair = NA, 18 | author_premium = NA, 19 | body = NA_character_, 20 | body_sha1 = NA_character_, 21 | can_gild = NA, 22 | collapsed = NA, 23 | collapsed_because_crowd_control = NA_character_, 24 | collapsed_reason = NA_character_, 25 | collapsed_reason_code = NA_character_, 26 | comment_type = NA_character_, 27 | controversiality = NA_integer_, 28 | created_utc = NA_integer_, 29 | distinguished = NA_character_, 30 | gilded = NA_integer_, 31 | gildings = I(list(list())), 32 | id = NA_character_, 33 | is_submitter = NA, 34 | link_id = NA_character_, 35 | locked = NA, 36 | no_follow = NA , 37 | parent_id = NA_character_, 38 | permalink = NA_character_, 39 | retrieved_utc = NA_integer_, 40 | score = NA_integer_, 41 | score_hidden = NA, 42 | send_replies = NA, 43 | stickied = NA, 44 | subreddit = NA_character_, 45 | subreddit_id = NA_character_, 46 | subreddit_name_prefixed = NA_character_, 47 | subreddit_type = NA_character_, 48 | top_awarded_type = NA_character_, 49 | total_awards_received = NA_integer_, 50 | treatment_tags = I(list(list())), 51 | unrepliable_reason = NA_character_ 52 | ) 53 | 54 | empty[["submission"]] <- tibble::tibble( 55 | all_awardings = I(list(list())), 56 | allow_live_comments = NA, 57 | author = NA_character_, 58 | author_flair_css_class = NA_character_, 59 | author_flair_richtext = I(list(list())), 60 | author_flair_text = NA_character_, 61 | author_flair_type = NA_character_, 62 | author_fullname = NA_character_, 63 | author_is_blocked = NA, 64 | author_patreon_flair = NA, 65 | author_premium = NA, 66 | awarders = I(list(list())), 67 | can_mod_post = NA, 68 | contest_mode = NA, 69 | created_utc = NA_integer_, 70 | domain = NA_character_, 71 | full_link = NA_character_, 72 | gildings = I(list(list())), 73 | id = NA_character_, 74 | is_created_from_ads_ui = NA, 75 | is_crosspostable = NA, 76 | is_meta = NA, 77 | is_original_content = NA, 78 | is_reddit_media_domain = NA, 79 | is_robot_indexable = NA, 80 | is_self = NA, 81 | is_video = NA, 82 | link_flair_background_color = NA_character_, 83 | link_flair_css_class = NA_character_, 84 | link_flair_richtext = I(list(list())), 85 | link_flair_template_id = NA_character_, 86 | link_flair_text = NA_character_, 87 | link_flair_text_color = NA_character_, 88 | link_flair_type = NA_character_, 89 | locked = NA, 90 | media_only = NA, 91 | no_follow = NA, 92 | num_comments = NA_integer_, 93 | num_crossposts = NA_integer_, 94 | over_18 = NA, 95 | parent_whitelist_status = NA_character_, 96 | permalink = NA_character_, 97 | pinned = NA, 98 | pwls = NA_integer_, 99 | retrieved_on = NA_integer_, 100 | score = NA_integer_, 101 | selftext = NA_character_, 102 | send_replies = NA, 103 | spoiler = NA, 104 | stickied = NA, 105 | subreddit = NA_character_, 106 | subreddit_id = NA_character_, 107 | subreddit_subscribers = NA_integer_, 108 | subreddit_type = NA_character_, 109 | thumbnail = NA_character_, 110 | title = NA_character_, 111 | total_awards_received = NA_integer_, 112 | treatment_tags = I(list(list())), 113 | upvote_ratio = NA_real_, 114 | url = NA_character_, 115 | whitelist_status = NA_character_, 116 | wls = NA_integer_ 117 | ) 118 | 119 | usethis::use_data(empty, overwrite = TRUE,internal = TRUE) 120 | 121 | 122 | dd <- data.frame(name=names(tmp[[1]]),class = unname(sapply(tmp[[1]],class))) 123 | -------------------------------------------------------------------------------- /data-raw/ps_params.R: -------------------------------------------------------------------------------- 1 | ## code to prepare `ps_params` dataset goes here 2 | df <- rvest::read_html("https://pushshift.io/api-parameters/") |> 3 | rvest::html_table() 4 | df[[1]]$Endpoint 5 | df[[1]]$Parameter 6 | 7 | ps_params <- df[[1]] 8 | 9 | usethis::use_data(ps_params, overwrite = TRUE) 10 | -------------------------------------------------------------------------------- /data/ps_params.rda: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/schochastics/PSAWR/0f9ad4af42acc739da09f5525e82dbb11ca47df0/data/ps_params.rda -------------------------------------------------------------------------------- /inst/CITATION: -------------------------------------------------------------------------------- 1 | citHeader("To cite PSAWR in publications use:") 2 | 3 | bibentry( 4 | bibtype = "Manual", 5 | title = {"PSAWR: Pushshift API Wrapper for Reddit Submission and Comment Search"}, 6 | author = {"David Schoch"}, 7 | note = {"R package version 0.1.0"}, 8 | year = {"2023"}, 9 | url = {"https://github.com/schochastics/PSAWR"}, 10 | textVersion = paste("Schoch, D., (2023) PSAWR: Pushshift API Wrapper for Reddit Submission and Comment Search. R package version 0.1.0, " 11 | 12 | ) 13 | ) 14 | -------------------------------------------------------------------------------- /man/figures/logo.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/schochastics/PSAWR/0f9ad4af42acc739da09f5525e82dbb11ca47df0/man/figures/logo.png -------------------------------------------------------------------------------- /man/ps_params.Rd: -------------------------------------------------------------------------------- 1 | % Generated by roxygen2: do not edit by hand 2 | % Please edit documentation in R/data.R 3 | \docType{data} 4 | \name{ps_params} 5 | \alias{ps_params} 6 | \title{Pushshift.io parameters for all endpoints} 7 | \format{ 8 | tibble of Endpoint Paramters 9 | } 10 | \source{ 11 | https://pushshift.io/api-parameters/ 12 | } 13 | \usage{ 14 | ps_params 15 | } 16 | \description{ 17 | Pushshift.io parameters for all endpoints 18 | } 19 | \keyword{datasets} 20 | -------------------------------------------------------------------------------- /man/search_comments.Rd: -------------------------------------------------------------------------------- 1 | % Generated by roxygen2: do not edit by hand 2 | % Please edit documentation in R/search.R 3 | \name{search_comments} 4 | \alias{search_comments} 5 | \title{Search Pushshift.io for Reddit comments} 6 | \usage{ 7 | search_comments( 8 | q = "", 9 | subreddit = NULL, 10 | size = 25, 11 | after = NULL, 12 | before = NULL, 13 | parse_date = TRUE, 14 | verbose = TRUE, 15 | ... 16 | ) 17 | } 18 | \arguments{ 19 | \item{q}{character, Query term} 20 | 21 | \item{subreddit}{Restrict results to subreddit (use "!" to negate, comma delimited for multiples)} 22 | 23 | \item{size}{integer, Number of results to return} 24 | 25 | \item{after}{integer, Restrict results to those made after this epoch time} 26 | 27 | \item{before}{integer, Restrict results to those made before this epoch time} 28 | 29 | \item{parse_date}{logical, should epoch time be converted to date? defaults to TRUE} 30 | 31 | \item{verbose}{logical, Whether to display messages} 32 | 33 | \item{...}{Further arguments passed as query parameters. See [ps_params] for all possible parameters.} 34 | } 35 | \value{ 36 | tibble of comments 37 | } 38 | \description{ 39 | Search Pushshift.io for Reddit comments 40 | } 41 | \details{ 42 | Use [to_epoch] to convert a date to epoch time 43 | } 44 | \examples{ 45 | \dontrun{ 46 | # get the last 100 comments with the word 'cats' 47 | search_comments(q = "cats", size = 100) 48 | } 49 | } 50 | -------------------------------------------------------------------------------- /man/search_submissions.Rd: -------------------------------------------------------------------------------- 1 | % Generated by roxygen2: do not edit by hand 2 | % Please edit documentation in R/search.R 3 | \name{search_submissions} 4 | \alias{search_submissions} 5 | \title{Search Pushshift.io for Reddit submissions} 6 | \usage{ 7 | search_submissions( 8 | q = "", 9 | subreddit = NULL, 10 | size = 25, 11 | after = NULL, 12 | before = NULL, 13 | parse_date = TRUE, 14 | verbose = TRUE, 15 | ... 16 | ) 17 | } 18 | \arguments{ 19 | \item{q}{character, Query term} 20 | 21 | \item{subreddit}{Restrict results to subreddit (use "!" to negate, comma delimited for multiples)} 22 | 23 | \item{size}{integer, Number of results to return} 24 | 25 | \item{after}{integer, Restrict results to those made after this epoch time} 26 | 27 | \item{before}{integer, Restrict results to those made before this epoch time} 28 | 29 | \item{parse_date}{logical, should epoch time be converted to date? defaults to TRUE} 30 | 31 | \item{verbose}{logical, Whether to display messages} 32 | 33 | \item{...}{Further arguments passed as query parameters. See [ps_params] for all possible parameters.} 34 | } 35 | \value{ 36 | tibble of submissions 37 | } 38 | \description{ 39 | Search Pushshift.io for Reddit submissions 40 | } 41 | \details{ 42 | Use [to_epoch] to convert a date to epoch time 43 | } 44 | \examples{ 45 | \dontrun{ 46 | # get the last 100 submissions with the word 'dogs' in the subreddit 'r/animals' 47 | search_submissions(q = "dogs", subreddit = "animals", size = 100) 48 | } 49 | } 50 | -------------------------------------------------------------------------------- /man/to_epoch.Rd: -------------------------------------------------------------------------------- 1 | % Generated by roxygen2: do not edit by hand 2 | % Please edit documentation in R/utils.R 3 | \name{to_epoch} 4 | \alias{to_epoch} 5 | \title{convert date to epoch time} 6 | \usage{ 7 | to_epoch(date) 8 | } 9 | \arguments{ 10 | \item{date}{date to be converted} 11 | } 12 | \value{ 13 | epoch time as integer 14 | } 15 | \description{ 16 | convert date to epoch time 17 | } 18 | \examples{ 19 | to_epoch("2022-12-01") 20 | } 21 | -------------------------------------------------------------------------------- /tests/fixtures/search_submissions_default.yml: -------------------------------------------------------------------------------- 1 | http_interactions: 2 | - request: 3 | method: get 4 | uri: https://api.pushshift.io/reddit/submission/search?q=dogs&subreddit=animals&size=10 5 | body: 6 | encoding: '' 7 | string: '' 8 | headers: 9 | Accept: application/json, text/xml, application/xml, */* 10 | response: 11 | status: 12 | status_code: 200 13 | category: Success 14 | reason: OK 15 | message: 'Success: (200) OK' 16 | headers: 17 | date: Wed, 14 Dec 2022 19:31:13 GMT 18 | content-type: application/json 19 | cache-control: public, max-age=2, s-maxage=2 20 | cf-cache-status: EXPIRED 21 | last-modified: Wed, 14 Dec 2022 19:29:22 GMT 22 | report-to: '{"endpoints":[{"url":"https:\/\/a.nel.cloudflare.com\/report\/v3?s=o5pbcGGeJpkaTM%2BzkExXZ0IpJdvwBKzvheiZLGyiILgbjSBDAAY1Gh325HdGKhOXvid%2BrAjBOWzTHerAzVuRNikvBFred8z8vKz9FAnuvXmd%2BIkoxbIwU%2BQ%2F455Ub6ACCq3wsIBECMllJOwbxkrh"}],"group":"cf-nel","max_age":604800}' 23 | nel: '{"success_fraction":0,"report_to":"cf-nel","max_age":604800}' 24 | vary: Accept-Encoding 25 | server: cloudflare 26 | cf-ray: 77995bc5693621bd-DUS 27 | content-encoding: br 28 | alt-svc: h3=":443"; ma=86400, h3-29=":443"; ma=86400 29 | body: 30 | encoding: '' 31 | file: no 32 | string: "{\"data\":[{\"subreddit\":\"Animals\",\"selftext\":\"\",\"author_fullname\":\"t2_ucckqz4s\",\"gilded\":0,\"title\":\"We 33 | meet a lot of poor dogs, Feeding foot to street dogs\",\"link_flair_richtext\":[],\"subreddit_name_prefixed\":\"r/Animals\",\"hidden\":false,\"pwls\":6,\"link_flair_css_class\":null,\"thumbnail_height\":105,\"top_awarded_type\":null,\"hide_score\":true,\"quarantine\":false,\"link_flair_text_color\":\"dark\",\"upvote_ratio\":1.0,\"author_flair_background_color\":null,\"subreddit_type\":\"public\",\"total_awards_received\":0,\"media_embed\":{\"content\":\"<iframe 34 | width=\\\"356\\\" height=\\\"200\\\" src=\\\"https://www.youtube.com/embed/JhXsvP7ySDU?feature=oembed&enablejsapi=1\\\" 35 | frameborder=\\\"0\\\" allow=\\\"accelerometer; autoplay; clipboard-write; 36 | encrypted-media; gyroscope; picture-in-picture\\\" allowfullscreen title=\\\"We 37 | meet a lot of poor dogs, Feeding foot to street dogs\\\"></iframe>\",\"width\":356,\"scrolling\":false,\"height\":200},\"thumbnail_width\":140,\"author_flair_template_id\":null,\"is_original_content\":false,\"secure_media\":{\"type\":\"youtube.com\",\"oembed\":{\"provider_url\":\"https://www.youtube.com/\",\"version\":\"1.0\",\"title\":\"We 38 | meet a lot of poor dogs, Feeding foot to street dogs\",\"type\":\"video\",\"thumbnail_width\":480,\"height\":200,\"width\":356,\"html\":\"<iframe 39 | width=\\\"356\\\" height=\\\"200\\\" src=\\\"https://www.youtube.com/embed/JhXsvP7ySDU?feature=oembed&enablejsapi=1\\\" 40 | frameborder=\\\"0\\\" allow=\\\"accelerometer; autoplay; clipboard-write; 41 | encrypted-media; gyroscope; picture-in-picture\\\" allowfullscreen title=\\\"We 42 | meet a lot of poor dogs, Feeding foot to street dogs\\\"></iframe>\",\"author_name\":\"Puppies 43 | with Loeun\",\"provider_name\":\"YouTube\",\"thumbnail_url\":\"https://i.ytimg.com/vi/JhXsvP7ySDU/hqdefault.jpg\",\"thumbnail_height\":360,\"author_url\":\"https://www.youtube.com/@PuppieswithLoeun\"}},\"is_reddit_media_domain\":false,\"is_meta\":false,\"category\":null,\"secure_media_embed\":{\"content\":\"<iframe 44 | width=\\\"356\\\" height=\\\"200\\\" src=\\\"https://www.youtube.com/embed/JhXsvP7ySDU?feature=oembed&enablejsapi=1\\\" 45 | frameborder=\\\"0\\\" allow=\\\"accelerometer; autoplay; clipboard-write; 46 | encrypted-media; gyroscope; picture-in-picture\\\" allowfullscreen title=\\\"We 47 | meet a lot of poor dogs, Feeding foot to street dogs\\\"></iframe>\",\"width\":356,\"scrolling\":false,\"media_domain_url\":\"https://www.redditmedia.com/mediaembed/zlrk4h\",\"height\":200},\"link_flair_text\":null,\"score\":1,\"is_created_from_ads_ui\":false,\"author_premium\":false,\"thumbnail\":\"https://b.thumbs.redditmedia.com/pF09kQqBP7h8YuzgZzshFMSrYjK1XY6h9t9aGsvMT5U.jpg\",\"edited\":false,\"author_flair_css_class\":null,\"author_flair_richtext\":[],\"gildings\":{},\"post_hint\":\"rich:video\",\"content_categories\":null,\"is_self\":false,\"link_flair_type\":\"text\",\"wls\":6,\"removed_by_category\":\"moderator\",\"author_flair_type\":\"text\",\"domain\":\"youtu.be\",\"allow_live_comments\":false,\"suggested_sort\":null,\"url_overridden_by_dest\":\"https://youtu.be/JhXsvP7ySDU\",\"view_count\":null,\"archived\":false,\"no_follow\":true,\"is_crosspostable\":false,\"pinned\":false,\"over_18\":false,\"preview\":{\"images\":[{\"source\":{\"url\":\"https://external-preview.redd.it/q-dDMGPJNinQ3WBTNIYz8osdFt3eer13FaiyziiHUM8.jpg?auto=webp&v=enabled&s=400f753a4da34889b9952b63bcb3c3f7fc239f3d\",\"width\":480,\"height\":360},\"resolutions\":[{\"url\":\"https://external-preview.redd.it/q-dDMGPJNinQ3WBTNIYz8osdFt3eer13FaiyziiHUM8.jpg?width=108&crop=smart&auto=webp&v=enabled&s=9e506c8a77ef2173866f800d7dc45285d9a73e31\",\"width\":108,\"height\":81},{\"url\":\"https://external-preview.redd.it/q-dDMGPJNinQ3WBTNIYz8osdFt3eer13FaiyziiHUM8.jpg?width=216&crop=smart&auto=webp&v=enabled&s=862e5eecc7176d1aaaae8f75bbe26121492584d3\",\"width\":216,\"height\":162},{\"url\":\"https://external-preview.redd.it/q-dDMGPJNinQ3WBTNIYz8osdFt3eer13FaiyziiHUM8.jpg?width=320&crop=smart&auto=webp&v=enabled&s=02ed994839f341c5e99fde1783f3c6aa7884adc2\",\"width\":320,\"height\":240}],\"variants\":{},\"id\":\"eEFhPR_tDgHazW9WvlfVL3S7ngmCDxkqLWybdW42tVY\"}],\"enabled\":false},\"all_awardings\":[],\"awarders\":[],\"media_only\":false,\"can_gild\":true,\"spoiler\":false,\"locked\":false,\"author_flair_text\":null,\"treatment_tags\":[],\"removed_by\":null,\"distinguished\":null,\"subreddit_id\":\"t5_2qi0c\",\"link_flair_background_color\":\"\",\"id\":\"zlrk4h\",\"is_robot_indexable\":false,\"author\":\"phunsavuth\",\"discussion_type\":null,\"num_comments\":0,\"send_replies\":true,\"whitelist_status\":\"all_ads\",\"contest_mode\":false,\"author_patreon_flair\":false,\"author_flair_text_color\":null,\"permalink\":\"/r/Animals/comments/zlrk4h/we_meet_a_lot_of_poor_dogs_feeding_foot_to_street/\",\"parent_whitelist_status\":\"all_ads\",\"stickied\":false,\"url\":\"https://youtu.be/JhXsvP7ySDU\",\"subreddit_subscribers\":102832,\"created_utc\":1671026101,\"num_crossposts\":0,\"media\":{\"type\":\"youtube.com\",\"oembed\":{\"provider_url\":\"https://www.youtube.com/\",\"version\":\"1.0\",\"title\":\"We 48 | meet a lot of poor dogs, Feeding foot to street dogs\",\"type\":\"video\",\"thumbnail_width\":480,\"height\":200,\"width\":356,\"html\":\"<iframe 49 | width=\\\"356\\\" height=\\\"200\\\" src=\\\"https://www.youtube.com/embed/JhXsvP7ySDU?feature=oembed&enablejsapi=1\\\" 50 | frameborder=\\\"0\\\" allow=\\\"accelerometer; autoplay; clipboard-write; 51 | encrypted-media; gyroscope; picture-in-picture\\\" allowfullscreen title=\\\"We 52 | meet a lot of poor dogs, Feeding foot to street dogs\\\"></iframe>\",\"author_name\":\"Puppies 53 | with Loeun\",\"provider_name\":\"YouTube\",\"thumbnail_url\":\"https://i.ytimg.com/vi/JhXsvP7ySDU/hqdefault.jpg\",\"thumbnail_height\":360,\"author_url\":\"https://www.youtube.com/@PuppieswithLoeun\"}},\"is_video\":false,\"retrieved_utc\":1671026112,\"updated_utc\":1671026113,\"utc_datetime_str\":\"2022-12-14 54 | 13:55:01\"},{\"subreddit\":\"Animals\",\"selftext\":\"\",\"author_fullname\":\"t2_sopxm2h2\",\"gilded\":0,\"title\":\"Pregnant 55 | & Homeless Dogs Rely on Street Dog Feeders to Survive\",\"link_flair_richtext\":[],\"subreddit_name_prefixed\":\"r/Animals\",\"hidden\":false,\"pwls\":6,\"link_flair_css_class\":null,\"thumbnail_height\":93,\"top_awarded_type\":null,\"hide_score\":true,\"quarantine\":false,\"link_flair_text_color\":\"dark\",\"upvote_ratio\":1.0,\"author_flair_background_color\":null,\"subreddit_type\":\"public\",\"total_awards_received\":0,\"media_embed\":{},\"thumbnail_width\":140,\"author_flair_template_id\":null,\"is_original_content\":false,\"secure_media\":null,\"is_reddit_media_domain\":false,\"is_meta\":false,\"category\":null,\"secure_media_embed\":{},\"link_flair_text\":null,\"score\":1,\"is_created_from_ads_ui\":false,\"author_premium\":false,\"thumbnail\":\"https://b.thumbs.redditmedia.com/VCwL6d-P0YcUzKo_AHBa_QLVhjidYFCGO4xOblD8McQ.jpg\",\"edited\":false,\"author_flair_css_class\":null,\"author_flair_richtext\":[],\"gildings\":{},\"post_hint\":\"link\",\"content_categories\":null,\"is_self\":false,\"link_flair_type\":\"text\",\"wls\":6,\"removed_by_category\":null,\"author_flair_type\":\"text\",\"domain\":\"pathofhoperescue.com\",\"allow_live_comments\":false,\"suggested_sort\":null,\"url_overridden_by_dest\":\"https://www.pathofhoperescue.com/blog/pregnant-homeless-dogs-rely-on-street-dog-feeders-to-survive\",\"view_count\":null,\"archived\":false,\"no_follow\":true,\"is_crosspostable\":true,\"pinned\":false,\"over_18\":false,\"preview\":{\"images\":[{\"source\":{\"url\":\"https://external-preview.redd.it/IcsXPDDNWhKvvDmY173y0qj15L_0TBRGF57Q4l8sNJQ.jpg?auto=webp&s=faef511bfbe59028cf4b6d944907a10ac5803120\",\"width\":1500,\"height\":1000},\"resolutions\":[{\"url\":\"https://external-preview.redd.it/IcsXPDDNWhKvvDmY173y0qj15L_0TBRGF57Q4l8sNJQ.jpg?width=108&crop=smart&auto=webp&s=49fd116bea3150fd265515e2c2de5dd21a4ecd62\",\"width\":108,\"height\":72},{\"url\":\"https://external-preview.redd.it/IcsXPDDNWhKvvDmY173y0qj15L_0TBRGF57Q4l8sNJQ.jpg?width=216&crop=smart&auto=webp&s=0f6c89b36b0c50a601e1464a8fafdd751c3eaf1d\",\"width\":216,\"height\":144},{\"url\":\"https://external-preview.redd.it/IcsXPDDNWhKvvDmY173y0qj15L_0TBRGF57Q4l8sNJQ.jpg?width=320&crop=smart&auto=webp&s=dbef3a2ebecc95aa054db5f619774deb2c82967b\",\"width\":320,\"height\":213},{\"url\":\"https://external-preview.redd.it/IcsXPDDNWhKvvDmY173y0qj15L_0TBRGF57Q4l8sNJQ.jpg?width=640&crop=smart&auto=webp&s=9297484b122c71698d6400a0560380e327ff508d\",\"width\":640,\"height\":426},{\"url\":\"https://external-preview.redd.it/IcsXPDDNWhKvvDmY173y0qj15L_0TBRGF57Q4l8sNJQ.jpg?width=960&crop=smart&auto=webp&s=5cc9e9584599fac7b4ca7086d2693dd06e281056\",\"width\":960,\"height\":640},{\"url\":\"https://external-preview.redd.it/IcsXPDDNWhKvvDmY173y0qj15L_0TBRGF57Q4l8sNJQ.jpg?width=1080&crop=smart&auto=webp&s=b3e704ea1cfbea134c9ab3ced8eb3a9f1d7e9977\",\"width\":1080,\"height\":720}],\"variants\":{},\"id\":\"2FOso8OjhbR_I2T_8-cZbJmEi7Q24MNejaU9EGXxHxs\"}],\"enabled\":false},\"all_awardings\":[],\"awarders\":[],\"media_only\":false,\"can_gild\":true,\"spoiler\":false,\"locked\":false,\"author_flair_text\":null,\"treatment_tags\":[],\"removed_by\":null,\"distinguished\":null,\"subreddit_id\":\"t5_2qi0c\",\"link_flair_background_color\":\"\",\"id\":\"zk5d1o\",\"is_robot_indexable\":true,\"author\":\"Brianlovescats\",\"discussion_type\":null,\"num_comments\":0,\"send_replies\":true,\"whitelist_status\":\"all_ads\",\"contest_mode\":false,\"author_patreon_flair\":false,\"author_flair_text_color\":null,\"permalink\":\"/r/Animals/comments/zk5d1o/pregnant_homeless_dogs_rely_on_street_dog_feeders/\",\"parent_whitelist_status\":\"all_ads\",\"stickied\":false,\"url\":\"https://www.pathofhoperescue.com/blog/pregnant-homeless-dogs-rely-on-street-dog-feeders-to-survive\",\"subreddit_subscribers\":102770,\"created_utc\":1670866073,\"num_crossposts\":0,\"media\":null,\"is_video\":false,\"retrieved_utc\":1670866084,\"updated_utc\":1670866084,\"utc_datetime_str\":\"2022-12-12 56 | 17:27:53\"},{\"subreddit\":\"Animals\",\"selftext\":\"\",\"author_fullname\":\"t2_ucckqz4s\",\"gilded\":0,\"title\":\"Feeding 57 | food to three dogs they're skinny and starving\",\"link_flair_richtext\":[],\"subreddit_name_prefixed\":\"r/Animals\",\"hidden\":false,\"pwls\":6,\"link_flair_css_class\":null,\"thumbnail_height\":105,\"top_awarded_type\":null,\"hide_score\":true,\"quarantine\":false,\"link_flair_text_color\":\"dark\",\"upvote_ratio\":1.0,\"author_flair_background_color\":null,\"subreddit_type\":\"public\",\"total_awards_received\":0,\"media_embed\":{\"content\":\"<iframe 58 | width=\\\"356\\\" height=\\\"200\\\" src=\\\"https://www.youtube.com/embed/rlpkm0Hu7Js?feature=oembed&enablejsapi=1\\\" 59 | frameborder=\\\"0\\\" allow=\\\"accelerometer; autoplay; clipboard-write; 60 | encrypted-media; gyroscope; picture-in-picture\\\" allowfullscreen title=\\\"Feeding 61 | food to three dogs they&#39;re skinny and starving\\\"></iframe>\",\"width\":356,\"scrolling\":false,\"height\":200},\"thumbnail_width\":140,\"author_flair_template_id\":null,\"is_original_content\":false,\"secure_media\":{\"type\":\"youtube.com\",\"oembed\":{\"provider_url\":\"https://www.youtube.com/\",\"version\":\"1.0\",\"title\":\"Feeding 62 | food to three dogs they're skinny and starving\",\"type\":\"video\",\"thumbnail_width\":480,\"height\":200,\"width\":356,\"html\":\"<iframe 63 | width=\\\"356\\\" height=\\\"200\\\" src=\\\"https://www.youtube.com/embed/rlpkm0Hu7Js?feature=oembed&enablejsapi=1\\\" 64 | frameborder=\\\"0\\\" allow=\\\"accelerometer; autoplay; clipboard-write; 65 | encrypted-media; gyroscope; picture-in-picture\\\" allowfullscreen title=\\\"Feeding 66 | food to three dogs they&#39;re skinny and starving\\\"></iframe>\",\"author_name\":\"Puppies 67 | with Loeun\",\"provider_name\":\"YouTube\",\"thumbnail_url\":\"https://i.ytimg.com/vi/rlpkm0Hu7Js/hqdefault.jpg\",\"thumbnail_height\":360,\"author_url\":\"https://www.youtube.com/@PuppieswithLoeun\"}},\"is_reddit_media_domain\":false,\"is_meta\":false,\"category\":null,\"secure_media_embed\":{\"content\":\"<iframe 68 | width=\\\"356\\\" height=\\\"200\\\" src=\\\"https://www.youtube.com/embed/rlpkm0Hu7Js?feature=oembed&enablejsapi=1\\\" 69 | frameborder=\\\"0\\\" allow=\\\"accelerometer; autoplay; clipboard-write; 70 | encrypted-media; gyroscope; picture-in-picture\\\" allowfullscreen title=\\\"Feeding 71 | food to three dogs they&#39;re skinny and starving\\\"></iframe>\",\"width\":356,\"scrolling\":false,\"media_domain_url\":\"https://www.redditmedia.com/mediaembed/zjywan\",\"height\":200},\"link_flair_text\":null,\"score\":1,\"is_created_from_ads_ui\":false,\"author_premium\":false,\"thumbnail\":\"https://b.thumbs.redditmedia.com/TERv1J2XQE-atBYB47IE5g1sye5v5QKDKKR2WwgovxM.jpg\",\"edited\":false,\"author_flair_css_class\":null,\"author_flair_richtext\":[],\"gildings\":{},\"post_hint\":\"rich:video\",\"content_categories\":null,\"is_self\":false,\"link_flair_type\":\"text\",\"wls\":6,\"removed_by_category\":\"moderator\",\"author_flair_type\":\"text\",\"domain\":\"youtu.be\",\"allow_live_comments\":false,\"suggested_sort\":null,\"url_overridden_by_dest\":\"https://youtu.be/rlpkm0Hu7Js\",\"view_count\":null,\"archived\":false,\"no_follow\":true,\"is_crosspostable\":false,\"pinned\":false,\"over_18\":false,\"preview\":{\"images\":[{\"source\":{\"url\":\"https://external-preview.redd.it/bnl5CMlPLwgrwSX0S1-D_guiWA6D5TspnPS2xX5xy0o.jpg?auto=webp&s=92fdc86fcce0dd1fab5ae2bece9f5fc6f977b336\",\"width\":480,\"height\":360},\"resolutions\":[{\"url\":\"https://external-preview.redd.it/bnl5CMlPLwgrwSX0S1-D_guiWA6D5TspnPS2xX5xy0o.jpg?width=108&crop=smart&auto=webp&s=962b1dc74b508f9e1d73dbd2883cf373343007d4\",\"width\":108,\"height\":81},{\"url\":\"https://external-preview.redd.it/bnl5CMlPLwgrwSX0S1-D_guiWA6D5TspnPS2xX5xy0o.jpg?width=216&crop=smart&auto=webp&s=81470a96588aec9df8c84875fc650118452a7cda\",\"width\":216,\"height\":162},{\"url\":\"https://external-preview.redd.it/bnl5CMlPLwgrwSX0S1-D_guiWA6D5TspnPS2xX5xy0o.jpg?width=320&crop=smart&auto=webp&s=1c6217e555576f2fb8a082bfc84b1793a8e96ff5\",\"width\":320,\"height\":240}],\"variants\":{},\"id\":\"XHmTwM7oVej4UVW2g7FJ0Tczs1cMHr9hZHmU4I94UVY\"}],\"enabled\":false},\"all_awardings\":[],\"awarders\":[],\"media_only\":false,\"can_gild\":true,\"spoiler\":false,\"locked\":false,\"author_flair_text\":null,\"treatment_tags\":[],\"removed_by\":null,\"distinguished\":null,\"subreddit_id\":\"t5_2qi0c\",\"link_flair_background_color\":\"\",\"id\":\"zjywan\",\"is_robot_indexable\":false,\"author\":\"phunsavuth\",\"discussion_type\":null,\"num_comments\":0,\"send_replies\":true,\"whitelist_status\":\"all_ads\",\"contest_mode\":false,\"author_patreon_flair\":false,\"author_flair_text_color\":null,\"permalink\":\"/r/Animals/comments/zjywan/feeding_food_to_three_dogs_theyre_skinny_and/\",\"parent_whitelist_status\":\"all_ads\",\"stickied\":false,\"url\":\"https://youtu.be/rlpkm0Hu7Js\",\"subreddit_subscribers\":102766,\"created_utc\":1670851125,\"num_crossposts\":0,\"media\":{\"type\":\"youtube.com\",\"oembed\":{\"provider_url\":\"https://www.youtube.com/\",\"version\":\"1.0\",\"title\":\"Feeding 72 | food to three dogs they're skinny and starving\",\"type\":\"video\",\"thumbnail_width\":480,\"height\":200,\"width\":356,\"html\":\"<iframe 73 | width=\\\"356\\\" height=\\\"200\\\" src=\\\"https://www.youtube.com/embed/rlpkm0Hu7Js?feature=oembed&enablejsapi=1\\\" 74 | frameborder=\\\"0\\\" allow=\\\"accelerometer; autoplay; clipboard-write; 75 | encrypted-media; gyroscope; picture-in-picture\\\" allowfullscreen title=\\\"Feeding 76 | food to three dogs they&#39;re skinny and starving\\\"></iframe>\",\"author_name\":\"Puppies 77 | with Loeun\",\"provider_name\":\"YouTube\",\"thumbnail_url\":\"https://i.ytimg.com/vi/rlpkm0Hu7Js/hqdefault.jpg\",\"thumbnail_height\":360,\"author_url\":\"https://www.youtube.com/@PuppieswithLoeun\"}},\"is_video\":false,\"retrieved_utc\":1670851141,\"updated_utc\":1670851142,\"utc_datetime_str\":\"2022-12-12 78 | 13:18:45\"},{\"subreddit\":\"Animals\",\"selftext\":\"✨ WE NEED YOU! ✨\\n\U0001F43E 79 | PLEASE SHARE FAR AND WIDE \U0001F43E\\n\\nI currently run \\\"Your Pet Food 80 | Bank\\\" from my garage in Sheffield, and I am currently providing around 81 | 10,000 pet meals each month. \\n\\nI'm trying to raise some funds so I can 82 | get a storage facility near my house to help with this. \\n\\nIf you'd like 83 | any info, please let me know. \\nWe are on socials, and also on \\nwww.yourpetfoodbank.co.uk 84 | \\n\\n\\nI'm raising money to keep animals in loved homes and out of already 85 | struggling rescue centres. Click to Donate \U0001F447\U0001F447\\n gofund.me/26f85c82\\n\\n#pets 86 | #dogs #cats #petfoodbank #CostOfLivingCrisis #animals\",\"author_fullname\":\"t2_gv3t2fgl\",\"gilded\":0,\"is_gallery\":true,\"title\":\"I'm 87 | trying to keep loved pets at home and out of rescues\",\"link_flair_richtext\":[],\"subreddit_name_prefixed\":\"r/Animals\",\"hidden\":false,\"pwls\":6,\"link_flair_css_class\":null,\"thumbnail_height\":140,\"top_awarded_type\":null,\"hide_score\":true,\"media_metadata\":{\"0jru772jrg5a1\":{\"status\":\"valid\",\"e\":\"Image\",\"m\":\"image/jpg\",\"p\":[{\"y\":81,\"x\":108,\"u\":\"https://preview.redd.it/0jru772jrg5a1.jpg?width=108&crop=smart&auto=webp&s=3764819a84b36330b79947827d6e96219b627093\"},{\"y\":162,\"x\":216,\"u\":\"https://preview.redd.it/0jru772jrg5a1.jpg?width=216&crop=smart&auto=webp&s=9c9d0bbe93ef5acee895e7b113eb228c5e488a57\"},{\"y\":240,\"x\":320,\"u\":\"https://preview.redd.it/0jru772jrg5a1.jpg?width=320&crop=smart&auto=webp&s=33f6469dd90dd952a62bfc15ad01274594a99ca0\"},{\"y\":481,\"x\":640,\"u\":\"https://preview.redd.it/0jru772jrg5a1.jpg?width=640&crop=smart&auto=webp&s=7933c4bb6bfa76cb5a4a324f422ddcd4285cbd9e\"},{\"y\":722,\"x\":960,\"u\":\"https://preview.redd.it/0jru772jrg5a1.jpg?width=960&crop=smart&auto=webp&s=259c4f177782e47b87d60ed5c601b9c299a58a65\"},{\"y\":813,\"x\":1080,\"u\":\"https://preview.redd.it/0jru772jrg5a1.jpg?width=1080&crop=smart&auto=webp&s=e1eb6e6e8f507b0ff52a2915f30164702a53afb3\"}],\"s\":{\"y\":3072,\"x\":4080,\"u\":\"https://preview.redd.it/0jru772jrg5a1.jpg?width=4080&format=pjpg&auto=webp&s=233bd966b00055de0ed0637d467771362f9a1520\"},\"id\":\"0jru772jrg5a1\"},\"gschp0iirg5a1\":{\"status\":\"valid\",\"e\":\"Image\",\"m\":\"image/jpg\",\"p\":[{\"y\":143,\"x\":108,\"u\":\"https://preview.redd.it/gschp0iirg5a1.jpg?width=108&crop=smart&auto=webp&s=8df9dd6d8d3d13f04544ce37c084b2de3ec6bfe0\"},{\"y\":286,\"x\":216,\"u\":\"https://preview.redd.it/gschp0iirg5a1.jpg?width=216&crop=smart&auto=webp&s=b04fd8b665cfd2b29f969f2cfcae685dd1fc76d4\"},{\"y\":425,\"x\":320,\"u\":\"https://preview.redd.it/gschp0iirg5a1.jpg?width=320&crop=smart&auto=webp&s=57efea44f57785dcc3ac3845a3859d41931c72c1\"},{\"y\":850,\"x\":640,\"u\":\"https://preview.redd.it/gschp0iirg5a1.jpg?width=640&crop=smart&auto=webp&s=6c02d72872aad4ffbf1bf19df344a285fd13a0ce\"},{\"y\":1275,\"x\":960,\"u\":\"https://preview.redd.it/gschp0iirg5a1.jpg?width=960&crop=smart&auto=webp&s=fcb78ac3b0e46a31da984b1e09e8e604df293a33\"},{\"y\":1434,\"x\":1080,\"u\":\"https://preview.redd.it/gschp0iirg5a1.jpg?width=1080&crop=smart&auto=webp&s=9ebe24877abd445b56eb91aa390a3401b4ecafb9\"}],\"s\":{\"y\":4080,\"x\":3072,\"u\":\"https://preview.redd.it/gschp0iirg5a1.jpg?width=3072&format=pjpg&auto=webp&s=f43cf20c6d1320017771ae90b73c6fa2f0343ffc\"},\"id\":\"gschp0iirg5a1\"},\"860sfxzirg5a1\":{\"status\":\"valid\",\"e\":\"Image\",\"m\":\"image/png\",\"p\":[{\"y\":131,\"x\":108,\"u\":\"https://preview.redd.it/860sfxzirg5a1.png?width=108&crop=smart&auto=webp&s=a3ea8472c66798b30d7cb7e862617b6673953a8c\"},{\"y\":263,\"x\":216,\"u\":\"https://preview.redd.it/860sfxzirg5a1.png?width=216&crop=smart&auto=webp&s=f63b684bdf57da8c569f4becd770b6ee0f7faeff\"},{\"y\":390,\"x\":320,\"u\":\"https://preview.redd.it/860sfxzirg5a1.png?width=320&crop=smart&auto=webp&s=48887249c42dc2a0db31aac1a37cc7c375f18b1a\"},{\"y\":780,\"x\":640,\"u\":\"https://preview.redd.it/860sfxzirg5a1.png?width=640&crop=smart&auto=webp&s=d00b33cdf0b7fa71feb92d01d4ba4c401ab755bd\"},{\"y\":1171,\"x\":960,\"u\":\"https://preview.redd.it/860sfxzirg5a1.png?width=960&crop=smart&auto=webp&s=2c7f25a10250f8ffae9315539ee43eabc6235ad5\"},{\"y\":1317,\"x\":1080,\"u\":\"https://preview.redd.it/860sfxzirg5a1.png?width=1080&crop=smart&auto=webp&s=cec6301e2c174f407dfb26dd42dff07903ab0920\"}],\"s\":{\"y\":1936,\"x\":1587,\"u\":\"https://preview.redd.it/860sfxzirg5a1.png?width=1587&format=png&auto=webp&s=b92a90bba08eb513c4ed981a9231f932d91236b9\"},\"id\":\"860sfxzirg5a1\"},\"0rsaf6gjrg5a1\":{\"status\":\"valid\",\"e\":\"Image\",\"m\":\"image/jpg\",\"p\":[{\"y\":143,\"x\":108,\"u\":\"https://preview.redd.it/0rsaf6gjrg5a1.jpg?width=108&crop=smart&auto=webp&s=70dc5b16947409d73539e3fb94d20fcb620a2b4c\"},{\"y\":286,\"x\":216,\"u\":\"https://preview.redd.it/0rsaf6gjrg5a1.jpg?width=216&crop=smart&auto=webp&s=e685c764f38395afffca71613d5e94071da59cbd\"},{\"y\":425,\"x\":320,\"u\":\"https://preview.redd.it/0rsaf6gjrg5a1.jpg?width=320&crop=smart&auto=webp&s=d74441057546b4838b30dd05ec5d96bb04206407\"},{\"y\":850,\"x\":640,\"u\":\"https://preview.redd.it/0rsaf6gjrg5a1.jpg?width=640&crop=smart&auto=webp&s=21193d2eee90034b0b5e7934f4b2aaadcef714ce\"},{\"y\":1275,\"x\":960,\"u\":\"https://preview.redd.it/0rsaf6gjrg5a1.jpg?width=960&crop=smart&auto=webp&s=f6587758840c7cf5298716b20bd5606324495f3d\"},{\"y\":1434,\"x\":1080,\"u\":\"https://preview.redd.it/0rsaf6gjrg5a1.jpg?width=1080&crop=smart&auto=webp&s=a2f0b3a7426496003b63bc435248c8be77eb6e20\"}],\"s\":{\"y\":4080,\"x\":3072,\"u\":\"https://preview.redd.it/0rsaf6gjrg5a1.jpg?width=3072&format=pjpg&auto=webp&s=27e61876222c75af5e5f4c7a307cc34ff4c701a0\"},\"id\":\"0rsaf6gjrg5a1\"}},\"quarantine\":false,\"link_flair_text_color\":\"dark\",\"upvote_ratio\":1.0,\"author_flair_background_color\":null,\"domain\":\"reddit.com\",\"media_embed\":{},\"thumbnail_width\":140,\"author_flair_template_id\":null,\"is_original_content\":false,\"secure_media\":null,\"is_reddit_media_domain\":false,\"is_meta\":false,\"category\":null,\"secure_media_embed\":{},\"gallery_data\":{\"items\":[{\"media_id\":\"gschp0iirg5a1\",\"id\":218431337},{\"media_id\":\"860sfxzirg5a1\",\"id\":218431338},{\"media_id\":\"0jru772jrg5a1\",\"id\":218431339},{\"media_id\":\"0rsaf6gjrg5a1\",\"id\":218431340}]},\"link_flair_text\":null,\"score\":1,\"is_created_from_ads_ui\":false,\"author_premium\":false,\"thumbnail\":\"https://b.thumbs.redditmedia.com/mLbDNWcQ3ZHyqi3k-0t2s3HgSmuBrDATuKXP48FDLYw.jpg\",\"edited\":false,\"author_flair_css_class\":null,\"author_flair_richtext\":[],\"gildings\":{},\"content_categories\":null,\"is_self\":false,\"subreddit_type\":\"public\",\"link_flair_type\":\"text\",\"wls\":6,\"removed_by_category\":null,\"author_flair_type\":\"text\",\"total_awards_received\":0,\"allow_live_comments\":false,\"suggested_sort\":null,\"url_overridden_by_dest\":\"https://www.reddit.com/gallery/zjy5x3\",\"view_count\":null,\"archived\":false,\"no_follow\":true,\"is_crosspostable\":true,\"pinned\":false,\"over_18\":false,\"all_awardings\":[],\"awarders\":[],\"media_only\":false,\"can_gild\":true,\"spoiler\":false,\"locked\":false,\"author_flair_text\":null,\"treatment_tags\":[],\"removed_by\":null,\"distinguished\":null,\"subreddit_id\":\"t5_2qi0c\",\"link_flair_background_color\":\"\",\"id\":\"zjy5x3\",\"is_robot_indexable\":true,\"author\":\"spookystarbuck11\",\"discussion_type\":null,\"num_comments\":0,\"send_replies\":true,\"whitelist_status\":\"all_ads\",\"contest_mode\":false,\"author_patreon_flair\":false,\"author_flair_text_color\":null,\"permalink\":\"/r/Animals/comments/zjy5x3/im_trying_to_keep_loved_pets_at_home_and_out_of/\",\"parent_whitelist_status\":\"all_ads\",\"stickied\":false,\"url\":\"https://www.reddit.com/gallery/zjy5x3\",\"subreddit_subscribers\":102765,\"created_utc\":1670849389,\"num_crossposts\":0,\"media\":null,\"is_video\":false,\"retrieved_utc\":1670849404,\"updated_utc\":1670849404,\"utc_datetime_str\":\"2022-12-12 88 | 12:49:49\"},{\"subreddit\":\"Animals\",\"selftext\":\"\",\"author_fullname\":\"t2_1391fk\",\"gilded\":0,\"title\":\"Cat 89 | sitting next to dogs toy\",\"link_flair_richtext\":[],\"subreddit_name_prefixed\":\"r/Animals\",\"hidden\":false,\"pwls\":6,\"link_flair_css_class\":null,\"thumbnail_height\":78,\"top_awarded_type\":null,\"hide_score\":true,\"quarantine\":false,\"link_flair_text_color\":\"dark\",\"upvote_ratio\":1.0,\"author_flair_background_color\":null,\"subreddit_type\":\"public\",\"total_awards_received\":0,\"media_embed\":{},\"thumbnail_width\":140,\"author_flair_template_id\":null,\"is_original_content\":false,\"secure_media\":null,\"is_reddit_media_domain\":false,\"is_meta\":false,\"category\":null,\"secure_media_embed\":{},\"link_flair_text\":null,\"score\":1,\"is_created_from_ads_ui\":false,\"author_premium\":false,\"thumbnail\":\"https://b.thumbs.redditmedia.com/m7V-v4KdzUXM775BOKrEWK9TxNOyNvyvNF88GeaqblI.jpg\",\"edited\":false,\"author_flair_css_class\":null,\"author_flair_richtext\":[],\"gildings\":{},\"post_hint\":\"hosted:video\",\"content_categories\":null,\"is_self\":false,\"link_flair_type\":\"text\",\"wls\":6,\"removed_by_category\":null,\"author_flair_type\":\"text\",\"domain\":\"/r/Animals/comments/zjlee3/cat_sitting_next_to_dogs_toy/\",\"allow_live_comments\":false,\"suggested_sort\":null,\"url_overridden_by_dest\":\"https://v.redd.it/9am7zyyhgf5a1\",\"view_count\":null,\"archived\":false,\"no_follow\":false,\"is_crosspostable\":true,\"pinned\":false,\"over_18\":false,\"preview\":{\"images\":[{\"source\":{\"url\":\"https://external-preview.redd.it/r8SJbaRP6f_yY8HAuQtwmksMKgBdhtbxA76A_9yGPfk.png?format=pjpg&auto=webp&s=18205727e4a5a8962f5a69b04c31e4da1cbba17b\",\"width\":1920,\"height\":1080},\"resolutions\":[{\"url\":\"https://external-preview.redd.it/r8SJbaRP6f_yY8HAuQtwmksMKgBdhtbxA76A_9yGPfk.png?width=108&crop=smart&format=pjpg&auto=webp&s=e4f55a365b8c2561e173d0f96d7c639e9f547771\",\"width\":108,\"height\":60},{\"url\":\"https://external-preview.redd.it/r8SJbaRP6f_yY8HAuQtwmksMKgBdhtbxA76A_9yGPfk.png?width=216&crop=smart&format=pjpg&auto=webp&s=39cd77d5ba8fe85bdb698a3b3a5e274218cc3c25\",\"width\":216,\"height\":121},{\"url\":\"https://external-preview.redd.it/r8SJbaRP6f_yY8HAuQtwmksMKgBdhtbxA76A_9yGPfk.png?width=320&crop=smart&format=pjpg&auto=webp&s=6ec4445b6d33b691b32242a17f69bca26ecef4d1\",\"width\":320,\"height\":180},{\"url\":\"https://external-preview.redd.it/r8SJbaRP6f_yY8HAuQtwmksMKgBdhtbxA76A_9yGPfk.png?width=640&crop=smart&format=pjpg&auto=webp&s=3002b20567c282be5b4dbb294731994e969e9ddf\",\"width\":640,\"height\":360},{\"url\":\"https://external-preview.redd.it/r8SJbaRP6f_yY8HAuQtwmksMKgBdhtbxA76A_9yGPfk.png?width=960&crop=smart&format=pjpg&auto=webp&s=c50137b83c8fd610c0cc98a8fe8b84a0f968c264\",\"width\":960,\"height\":540},{\"url\":\"https://external-preview.redd.it/r8SJbaRP6f_yY8HAuQtwmksMKgBdhtbxA76A_9yGPfk.png?width=1080&crop=smart&format=pjpg&auto=webp&s=eeb18ce2285f849ce78f6e0a0b13e5f8e4180fca\",\"width\":1080,\"height\":607}],\"variants\":{},\"id\":\"-snCgoLEbw0vPxMV3vwQ1Ti7_8gkHYQOs7ZQGg1Pvxs\"}],\"enabled\":false},\"all_awardings\":[],\"awarders\":[],\"media_only\":false,\"can_gild\":true,\"spoiler\":false,\"locked\":false,\"author_flair_text\":null,\"treatment_tags\":[],\"removed_by\":null,\"distinguished\":null,\"subreddit_id\":\"t5_2qi0c\",\"link_flair_background_color\":\"\",\"id\":\"zjlee3\",\"is_robot_indexable\":true,\"author\":\"Nonatheman\",\"discussion_type\":null,\"num_comments\":0,\"send_replies\":true,\"whitelist_status\":\"all_ads\",\"contest_mode\":false,\"author_patreon_flair\":false,\"author_flair_text_color\":null,\"permalink\":\"/r/Animals/comments/zjlee3/cat_sitting_next_to_dogs_toy/\",\"parent_whitelist_status\":\"all_ads\",\"stickied\":false,\"url\":\"https://v.redd.it/9am7zyyhgf5a1\",\"subreddit_subscribers\":102752,\"created_utc\":1670815600,\"num_crossposts\":0,\"media\":null,\"is_video\":true,\"retrieved_utc\":1670815613,\"updated_utc\":1670815613,\"utc_datetime_str\":\"2022-12-12 90 | 03:26:40\"},{\"subreddit\":\"Animals\",\"selftext\":\"\",\"author_fullname\":\"t2_ucckqz4s\",\"gilded\":0,\"title\":\"Feeding 91 | food to four dogs and three puppies where are poor pets\",\"link_flair_richtext\":[],\"subreddit_name_prefixed\":\"r/Animals\",\"hidden\":false,\"pwls\":6,\"link_flair_css_class\":null,\"thumbnail_height\":105,\"top_awarded_type\":null,\"hide_score\":true,\"quarantine\":false,\"link_flair_text_color\":\"dark\",\"upvote_ratio\":1.0,\"author_flair_background_color\":null,\"subreddit_type\":\"public\",\"total_awards_received\":0,\"media_embed\":{\"content\":\"<iframe 92 | width=\\\"356\\\" height=\\\"200\\\" src=\\\"https://www.youtube.com/embed/znGKBCpXPCY?feature=oembed&enablejsapi=1\\\" 93 | frameborder=\\\"0\\\" allow=\\\"accelerometer; autoplay; clipboard-write; 94 | encrypted-media; gyroscope; picture-in-picture\\\" allowfullscreen title=\\\"Feeding 95 | food to four dogs and three puppies where are poor pets\\\"></iframe>\",\"width\":356,\"scrolling\":false,\"height\":200},\"thumbnail_width\":140,\"author_flair_template_id\":null,\"is_original_content\":false,\"secure_media\":{\"type\":\"youtube.com\",\"oembed\":{\"provider_url\":\"https://www.youtube.com/\",\"version\":\"1.0\",\"title\":\"Feeding 96 | food to four dogs and three puppies where are poor pets\",\"type\":\"video\",\"thumbnail_width\":480,\"height\":200,\"width\":356,\"html\":\"<iframe 97 | width=\\\"356\\\" height=\\\"200\\\" src=\\\"https://www.youtube.com/embed/znGKBCpXPCY?feature=oembed&enablejsapi=1\\\" 98 | frameborder=\\\"0\\\" allow=\\\"accelerometer; autoplay; clipboard-write; 99 | encrypted-media; gyroscope; picture-in-picture\\\" allowfullscreen title=\\\"Feeding 100 | food to four dogs and three puppies where are poor pets\\\"></iframe>\",\"author_name\":\"Puppies 101 | with Loeun\",\"provider_name\":\"YouTube\",\"thumbnail_url\":\"https://i.ytimg.com/vi/znGKBCpXPCY/hqdefault.jpg\",\"thumbnail_height\":360,\"author_url\":\"https://www.youtube.com/@PuppieswithLoeun\"}},\"is_reddit_media_domain\":false,\"is_meta\":false,\"category\":null,\"secure_media_embed\":{\"content\":\"<iframe 102 | width=\\\"356\\\" height=\\\"200\\\" src=\\\"https://www.youtube.com/embed/znGKBCpXPCY?feature=oembed&enablejsapi=1\\\" 103 | frameborder=\\\"0\\\" allow=\\\"accelerometer; autoplay; clipboard-write; 104 | encrypted-media; gyroscope; picture-in-picture\\\" allowfullscreen title=\\\"Feeding 105 | food to four dogs and three puppies where are poor pets\\\"></iframe>\",\"width\":356,\"scrolling\":false,\"media_domain_url\":\"https://www.redditmedia.com/mediaembed/ziy2t8\",\"height\":200},\"link_flair_text\":null,\"score\":1,\"is_created_from_ads_ui\":false,\"author_premium\":false,\"thumbnail\":\"https://b.thumbs.redditmedia.com/Oacq4jDz59nEMdaGiX79jILm8zqa76OPlQtj5gQYLOs.jpg\",\"edited\":false,\"author_flair_css_class\":null,\"author_flair_richtext\":[],\"gildings\":{},\"post_hint\":\"rich:video\",\"content_categories\":null,\"is_self\":false,\"link_flair_type\":\"text\",\"wls\":6,\"removed_by_category\":\"moderator\",\"author_flair_type\":\"text\",\"domain\":\"youtu.be\",\"allow_live_comments\":false,\"suggested_sort\":null,\"url_overridden_by_dest\":\"https://youtu.be/znGKBCpXPCY\",\"view_count\":null,\"archived\":false,\"no_follow\":true,\"is_crosspostable\":false,\"pinned\":false,\"over_18\":false,\"preview\":{\"images\":[{\"source\":{\"url\":\"https://external-preview.redd.it/wlfMSHXnlemqSuAwPkfnL3AJVXTsHooJUULwRcJEGXI.jpg?auto=webp&s=a66c048d317b02b7cf2cebd4c2dcd0db1e5afd81\",\"width\":480,\"height\":360},\"resolutions\":[{\"url\":\"https://external-preview.redd.it/wlfMSHXnlemqSuAwPkfnL3AJVXTsHooJUULwRcJEGXI.jpg?width=108&crop=smart&auto=webp&s=fe3a4b28edf151b39a06f72cbf586917e39b2c7e\",\"width\":108,\"height\":81},{\"url\":\"https://external-preview.redd.it/wlfMSHXnlemqSuAwPkfnL3AJVXTsHooJUULwRcJEGXI.jpg?width=216&crop=smart&auto=webp&s=4f83bfb8e8db783bbb4061b49d9df26ea4b5265d\",\"width\":216,\"height\":162},{\"url\":\"https://external-preview.redd.it/wlfMSHXnlemqSuAwPkfnL3AJVXTsHooJUULwRcJEGXI.jpg?width=320&crop=smart&auto=webp&s=d5b521695079bd96b5a24d15166554a08be9a457\",\"width\":320,\"height\":240}],\"variants\":{},\"id\":\"tm8C1ysgBC690y6pJYCeKny-jmr7gkJ_Ux6sMMZR5yk\"}],\"enabled\":false},\"all_awardings\":[],\"awarders\":[],\"media_only\":false,\"can_gild\":true,\"spoiler\":false,\"locked\":false,\"author_flair_text\":null,\"treatment_tags\":[],\"removed_by\":null,\"distinguished\":null,\"subreddit_id\":\"t5_2qi0c\",\"link_flair_background_color\":\"\",\"id\":\"ziy2t8\",\"is_robot_indexable\":false,\"author\":\"phunsavuth\",\"discussion_type\":null,\"num_comments\":0,\"send_replies\":true,\"whitelist_status\":\"all_ads\",\"contest_mode\":false,\"author_patreon_flair\":false,\"author_flair_text_color\":null,\"permalink\":\"/r/Animals/comments/ziy2t8/feeding_food_to_four_dogs_and_three_puppies_where/\",\"parent_whitelist_status\":\"all_ads\",\"stickied\":false,\"url\":\"https://youtu.be/znGKBCpXPCY\",\"subreddit_subscribers\":102731,\"created_utc\":1670775396,\"num_crossposts\":0,\"media\":{\"type\":\"youtube.com\",\"oembed\":{\"provider_url\":\"https://www.youtube.com/\",\"version\":\"1.0\",\"title\":\"Feeding 106 | food to four dogs and three puppies where are poor pets\",\"type\":\"video\",\"thumbnail_width\":480,\"height\":200,\"width\":356,\"html\":\"<iframe 107 | width=\\\"356\\\" height=\\\"200\\\" src=\\\"https://www.youtube.com/embed/znGKBCpXPCY?feature=oembed&enablejsapi=1\\\" 108 | frameborder=\\\"0\\\" allow=\\\"accelerometer; autoplay; clipboard-write; 109 | encrypted-media; gyroscope; picture-in-picture\\\" allowfullscreen title=\\\"Feeding 110 | food to four dogs and three puppies where are poor pets\\\"></iframe>\",\"author_name\":\"Puppies 111 | with Loeun\",\"provider_name\":\"YouTube\",\"thumbnail_url\":\"https://i.ytimg.com/vi/znGKBCpXPCY/hqdefault.jpg\",\"thumbnail_height\":360,\"author_url\":\"https://www.youtube.com/@PuppieswithLoeun\"}},\"is_video\":false,\"retrieved_utc\":1670775412,\"updated_utc\":1670775412,\"utc_datetime_str\":\"2022-12-11 112 | 16:16:36\"},{\"subreddit\":\"Animals\",\"selftext\":\"[removed]\",\"author_fullname\":\"t2_uv2p162p\",\"gilded\":0,\"title\":\"The 113 | dogs\",\"link_flair_richtext\":[],\"subreddit_name_prefixed\":\"r/Animals\",\"hidden\":false,\"pwls\":6,\"link_flair_css_class\":null,\"thumbnail_height\":78,\"top_awarded_type\":null,\"hide_score\":true,\"quarantine\":false,\"link_flair_text_color\":\"dark\",\"upvote_ratio\":1.0,\"author_flair_background_color\":null,\"subreddit_type\":\"public\",\"total_awards_received\":0,\"media_embed\":{},\"thumbnail_width\":140,\"author_flair_template_id\":null,\"is_original_content\":false,\"secure_media\":null,\"is_reddit_media_domain\":true,\"is_meta\":false,\"category\":null,\"secure_media_embed\":{},\"link_flair_text\":null,\"score\":1,\"is_created_from_ads_ui\":false,\"author_premium\":false,\"thumbnail\":\"https://b.thumbs.redditmedia.com/x9WDDgXZnKXPGSKr8J7cJ5efu-La0-oZmaumIvjFZLY.jpg\",\"edited\":false,\"author_flair_css_class\":null,\"author_flair_richtext\":[],\"gildings\":{},\"post_hint\":\"image\",\"content_categories\":null,\"is_self\":false,\"link_flair_type\":\"text\",\"wls\":6,\"removed_by_category\":\"moderator\",\"author_flair_type\":\"text\",\"domain\":\"i.redd.it\",\"allow_live_comments\":false,\"suggested_sort\":null,\"url_overridden_by_dest\":\"https://i.redd.it/vrhr9jij825a1.jpg\",\"view_count\":null,\"archived\":false,\"no_follow\":true,\"is_crosspostable\":false,\"pinned\":false,\"over_18\":false,\"preview\":{\"images\":[{\"source\":{\"url\":\"https://preview.redd.it/vrhr9jij825a1.jpg?auto=webp&s=bbcff755958703d90bd6aaa551a559765b7f9705\",\"width\":4032,\"height\":2268},\"resolutions\":[{\"url\":\"https://preview.redd.it/vrhr9jij825a1.jpg?width=108&crop=smart&auto=webp&s=9c85572e31c3be485166160e42dd63dcc51a3bde\",\"width\":108,\"height\":60},{\"url\":\"https://preview.redd.it/vrhr9jij825a1.jpg?width=216&crop=smart&auto=webp&s=b9189d15c285e7dc899e738af5cc5d0178c0ec04\",\"width\":216,\"height\":121},{\"url\":\"https://preview.redd.it/vrhr9jij825a1.jpg?width=320&crop=smart&auto=webp&s=0ed0890b3ac3b8fa6b3157f95c246659569a3d2c\",\"width\":320,\"height\":180},{\"url\":\"https://preview.redd.it/vrhr9jij825a1.jpg?width=640&crop=smart&auto=webp&s=db47134b6d2a3861ebfcb489c59ca16c8fb13d6f\",\"width\":640,\"height\":360},{\"url\":\"https://preview.redd.it/vrhr9jij825a1.jpg?width=960&crop=smart&auto=webp&s=6c670f4bd2f9c8a464b8467c36b2e3fbe964b7d9\",\"width\":960,\"height\":540},{\"url\":\"https://preview.redd.it/vrhr9jij825a1.jpg?width=1080&crop=smart&auto=webp&s=01eae876f5e7c10dd23155c24cb15d45464a660e\",\"width\":1080,\"height\":607}],\"variants\":{},\"id\":\"6i6ZDWQLDw3gPbc-MZMiDGtEtDQ8949Rj5yAm8Hea8I\"}],\"enabled\":true},\"all_awardings\":[],\"awarders\":[],\"media_only\":false,\"can_gild\":true,\"spoiler\":false,\"locked\":false,\"author_flair_text\":null,\"treatment_tags\":[],\"removed_by\":null,\"distinguished\":null,\"subreddit_id\":\"t5_2qi0c\",\"link_flair_background_color\":\"\",\"id\":\"zhljto\",\"is_robot_indexable\":false,\"author\":\"chebe_6262\",\"discussion_type\":null,\"num_comments\":0,\"send_replies\":true,\"whitelist_status\":\"all_ads\",\"contest_mode\":false,\"author_patreon_flair\":false,\"author_flair_text_color\":null,\"permalink\":\"/r/Animals/comments/zhljto/the_dogs/\",\"parent_whitelist_status\":\"all_ads\",\"stickied\":false,\"url\":\"https://i.redd.it/vrhr9jij825a1.jpg\",\"subreddit_subscribers\":102678,\"created_utc\":1670655502,\"num_crossposts\":0,\"media\":null,\"is_video\":false,\"retrieved_utc\":1670655515,\"updated_utc\":1670655515,\"utc_datetime_str\":\"2022-12-10 114 | 06:58:22\"},{\"subreddit\":\"Animals\",\"selftext\":\"\",\"author_fullname\":\"t2_utwd45fr\",\"gilded\":0,\"title\":\"Do 115 | high pitch frequency devices like this actually work to stop dogs barking?\",\"link_flair_richtext\":[],\"subreddit_name_prefixed\":\"r/Animals\",\"hidden\":false,\"pwls\":6,\"link_flair_css_class\":null,\"thumbnail_height\":null,\"top_awarded_type\":null,\"hide_score\":true,\"quarantine\":false,\"link_flair_text_color\":\"dark\",\"upvote_ratio\":1.0,\"author_flair_background_color\":null,\"subreddit_type\":\"public\",\"total_awards_received\":0,\"media_embed\":{},\"thumbnail_width\":null,\"author_flair_template_id\":null,\"is_original_content\":false,\"secure_media\":null,\"is_reddit_media_domain\":false,\"is_meta\":false,\"category\":null,\"secure_media_embed\":{},\"link_flair_text\":null,\"score\":1,\"is_created_from_ads_ui\":false,\"author_premium\":false,\"thumbnail\":\"default\",\"edited\":false,\"author_flair_css_class\":null,\"author_flair_richtext\":[],\"gildings\":{},\"content_categories\":null,\"is_self\":false,\"link_flair_type\":\"text\",\"wls\":6,\"removed_by_category\":\"moderator\",\"author_flair_type\":\"text\",\"domain\":\"a.co\",\"allow_live_comments\":false,\"suggested_sort\":null,\"url_overridden_by_dest\":\"https://a.co/d/7qfF0yK\",\"view_count\":null,\"archived\":false,\"no_follow\":true,\"is_crosspostable\":false,\"pinned\":false,\"over_18\":false,\"all_awardings\":[],\"awarders\":[],\"media_only\":false,\"can_gild\":true,\"spoiler\":false,\"locked\":false,\"author_flair_text\":null,\"treatment_tags\":[],\"removed_by\":null,\"distinguished\":null,\"subreddit_id\":\"t5_2qi0c\",\"link_flair_background_color\":\"\",\"id\":\"zgi7k1\",\"is_robot_indexable\":false,\"author\":\"Frank_SustainAMustly\",\"discussion_type\":null,\"num_comments\":0,\"send_replies\":true,\"whitelist_status\":\"all_ads\",\"contest_mode\":false,\"author_patreon_flair\":false,\"author_flair_text_color\":null,\"permalink\":\"/r/Animals/comments/zgi7k1/do_high_pitch_frequency_devices_like_this/\",\"parent_whitelist_status\":\"all_ads\",\"stickied\":false,\"url\":\"https://a.co/d/7qfF0yK\",\"subreddit_subscribers\":102625,\"created_utc\":1670547774,\"num_crossposts\":0,\"media\":null,\"is_video\":false,\"retrieved_utc\":1670547794,\"updated_utc\":1670547795,\"utc_datetime_str\":\"2022-12-09 116 | 01:02:54\"},{\"subreddit\":\"Animals\",\"selftext\":\"\",\"author_fullname\":\"t2_dlc5ungg\",\"gilded\":0,\"title\":\"Please 117 | I need help I found a horrible channel about dogs being ki*led (and making 118 | fun of it), I've already report it but nothing changed. https://www.youtube.com/watch?v=dmEGH97LcPo&t=29s\",\"link_flair_richtext\":[],\"subreddit_name_prefixed\":\"r/Animals\",\"hidden\":false,\"pwls\":6,\"link_flair_css_class\":null,\"thumbnail_height\":91,\"top_awarded_type\":null,\"hide_score\":true,\"quarantine\":false,\"link_flair_text_color\":\"dark\",\"upvote_ratio\":1.0,\"author_flair_background_color\":null,\"subreddit_type\":\"public\",\"total_awards_received\":0,\"media_embed\":{},\"thumbnail_width\":140,\"author_flair_template_id\":null,\"is_original_content\":false,\"secure_media\":null,\"is_reddit_media_domain\":true,\"is_meta\":false,\"category\":null,\"secure_media_embed\":{},\"link_flair_text\":null,\"score\":1,\"is_created_from_ads_ui\":false,\"author_premium\":false,\"thumbnail\":\"https://a.thumbs.redditmedia.com/ZYpFEkkhG1k2jgDvCtXD0NExB-ytCfRJFsgir0asJD4.jpg\",\"edited\":false,\"author_flair_css_class\":null,\"author_flair_richtext\":[],\"gildings\":{},\"post_hint\":\"image\",\"content_categories\":null,\"is_self\":false,\"link_flair_type\":\"text\",\"wls\":6,\"removed_by_category\":\"reddit\",\"author_flair_type\":\"text\",\"domain\":\"i.redd.it\",\"allow_live_comments\":false,\"suggested_sort\":null,\"url_overridden_by_dest\":\"https://i.redd.it/verhec5mdi4a1.png\",\"view_count\":null,\"archived\":false,\"no_follow\":true,\"is_crosspostable\":false,\"pinned\":false,\"over_18\":false,\"preview\":{\"images\":[{\"source\":{\"url\":\"https://preview.redd.it/verhec5mdi4a1.png?auto=webp&s=54959cdd5fda51438d838d230d5b718d6afda5d4\",\"width\":633,\"height\":412},\"resolutions\":[{\"url\":\"https://preview.redd.it/verhec5mdi4a1.png?width=108&crop=smart&auto=webp&s=3142d1fce99311c1a9c91e96651a488761d13e3f\",\"width\":108,\"height\":70},{\"url\":\"https://preview.redd.it/verhec5mdi4a1.png?width=216&crop=smart&auto=webp&s=20068bbf7ea1167277dc2afc0413fb08a6338aa4\",\"width\":216,\"height\":140},{\"url\":\"https://preview.redd.it/verhec5mdi4a1.png?width=320&crop=smart&auto=webp&s=144d595d2551cae69e64558b55cdae14d50db37f\",\"width\":320,\"height\":208}],\"variants\":{},\"id\":\"t783fM8OvssRh2wx1iQH5Ih0d96_3lq5Rytv6IK_f5g\"}],\"enabled\":true},\"all_awardings\":[],\"awarders\":[],\"media_only\":false,\"can_gild\":true,\"spoiler\":false,\"locked\":false,\"author_flair_text\":null,\"treatment_tags\":[],\"removed_by\":null,\"distinguished\":null,\"subreddit_id\":\"t5_2qi0c\",\"link_flair_background_color\":\"\",\"id\":\"zf6w6v\",\"is_robot_indexable\":false,\"author\":\"Ashamed_Art_8308\",\"discussion_type\":null,\"num_comments\":0,\"send_replies\":true,\"whitelist_status\":\"all_ads\",\"contest_mode\":false,\"author_patreon_flair\":false,\"author_flair_text_color\":null,\"permalink\":\"/r/Animals/comments/zf6w6v/please_i_need_help_i_found_a_horrible_channel/\",\"parent_whitelist_status\":\"all_ads\",\"stickied\":false,\"url\":\"https://i.redd.it/verhec5mdi4a1.png\",\"subreddit_subscribers\":102580,\"created_utc\":1670433091,\"num_crossposts\":0,\"media\":null,\"is_video\":false,\"retrieved_utc\":1670433103,\"updated_utc\":1670433104,\"utc_datetime_str\":\"2022-12-07 119 | 17:11:31\"},{\"subreddit\":\"Animals\",\"selftext\":\"\",\"author_fullname\":\"t2_dlc5ungg\",\"gilded\":0,\"title\":\"Please, 120 | I need help. I found a horrible channel about dogs being killed and making 121 | fun of them. I've already been reporting it for a few weeks now, but nothing 122 | changed. Look at it by yourself: https://youtu.be/mZJ_mvOGtyY https://www.youtube.com/@tarcisiasiniscalchi6641\",\"link_flair_richtext\":[],\"subreddit_name_prefixed\":\"r/Animals\",\"hidden\":false,\"pwls\":6,\"link_flair_css_class\":null,\"thumbnail_height\":91,\"top_awarded_type\":null,\"hide_score\":true,\"quarantine\":false,\"link_flair_text_color\":\"dark\",\"upvote_ratio\":1.0,\"author_flair_background_color\":null,\"subreddit_type\":\"public\",\"total_awards_received\":0,\"media_embed\":{},\"thumbnail_width\":140,\"author_flair_template_id\":null,\"is_original_content\":false,\"secure_media\":null,\"is_reddit_media_domain\":true,\"is_meta\":false,\"category\":null,\"secure_media_embed\":{},\"link_flair_text\":null,\"score\":1,\"is_created_from_ads_ui\":false,\"author_premium\":false,\"thumbnail\":\"https://b.thumbs.redditmedia.com/4RG6Y5_dTxNbZhZSVimC0kwj2jN2OgDfufKQ8poiyVE.jpg\",\"edited\":false,\"author_flair_css_class\":null,\"author_flair_richtext\":[],\"gildings\":{},\"post_hint\":\"image\",\"content_categories\":null,\"is_self\":false,\"link_flair_type\":\"text\",\"wls\":6,\"removed_by_category\":\"reddit\",\"author_flair_type\":\"text\",\"domain\":\"i.redd.it\",\"allow_live_comments\":false,\"suggested_sort\":null,\"url_overridden_by_dest\":\"https://i.redd.it/d14g6ayqci4a1.png\",\"view_count\":null,\"archived\":false,\"no_follow\":true,\"is_crosspostable\":false,\"pinned\":false,\"over_18\":false,\"preview\":{\"images\":[{\"source\":{\"url\":\"https://preview.redd.it/d14g6ayqci4a1.png?auto=webp&s=48d6bcdf3f5d254b446ade5c0a9872a1d65469a0\",\"width\":633,\"height\":412},\"resolutions\":[{\"url\":\"https://preview.redd.it/d14g6ayqci4a1.png?width=108&crop=smart&auto=webp&s=7b308871e0e35d8d38a4e2fca0c6f904398c76de\",\"width\":108,\"height\":70},{\"url\":\"https://preview.redd.it/d14g6ayqci4a1.png?width=216&crop=smart&auto=webp&s=e29654c81f8ec682f0d61507532725de3e3485d5\",\"width\":216,\"height\":140},{\"url\":\"https://preview.redd.it/d14g6ayqci4a1.png?width=320&crop=smart&auto=webp&s=b39f13de44762cb9ddf573e8ae1c62cdfd4282c8\",\"width\":320,\"height\":208}],\"variants\":{},\"id\":\"Z87SCfjWkRkL9durVoeGGgYNm8RMjrlR9BwFK0wOMzY\"}],\"enabled\":true},\"all_awardings\":[],\"awarders\":[],\"media_only\":false,\"can_gild\":true,\"spoiler\":false,\"locked\":false,\"author_flair_text\":null,\"treatment_tags\":[],\"removed_by\":null,\"distinguished\":null,\"subreddit_id\":\"t5_2qi0c\",\"link_flair_background_color\":\"\",\"id\":\"zf6rjp\",\"is_robot_indexable\":false,\"author\":\"Ashamed_Art_8308\",\"discussion_type\":null,\"num_comments\":0,\"send_replies\":true,\"whitelist_status\":\"all_ads\",\"contest_mode\":false,\"author_patreon_flair\":false,\"author_flair_text_color\":null,\"permalink\":\"/r/Animals/comments/zf6rjp/please_i_need_help_i_found_a_horrible_channel/\",\"parent_whitelist_status\":\"all_ads\",\"stickied\":false,\"url\":\"https://i.redd.it/d14g6ayqci4a1.png\",\"subreddit_subscribers\":102580,\"created_utc\":1670432829,\"num_crossposts\":0,\"media\":null,\"is_video\":false,\"retrieved_utc\":1670432846,\"updated_utc\":1670432847,\"utc_datetime_str\":\"2022-12-07 123 | 17:07:09\"}],\"error\":null,\"metadata\":{\"es\":{\"took\":40,\"timed_out\":false,\"_shards\":{\"total\":4,\"successful\":4,\"skipped\":0,\"failed\":0},\"hits\":{\"total\":{\"value\":25,\"relation\":\"eq\"},\"max_score\":null}},\"es_query\":{\"size\":10,\"query\":{\"bool\":{\"must\":[{\"bool\":{\"must\":[{\"simple_query_string\":{\"fields\":[\"title\",\"selftext\"],\"query\":\"dogs\",\"default_operator\":\"and\"}},{\"range\":{\"created_utc\":{\"gte\":1668454272000}}}]}},{\"bool\":{\"should\":[{\"match\":{\"subreddit\":\"animals\"}}],\"minimum_should_match\":1}}]}},\"aggs\":{},\"sort\":{\"created_utc\":\"desc\"}},\"es_query2\":\"{\\\"size\\\":10,\\\"query\\\":{\\\"bool\\\":{\\\"must\\\":[{\\\"bool\\\":{\\\"must\\\":[{\\\"simple_query_string\\\":{\\\"fields\\\":[\\\"title\\\",\\\"selftext\\\"],\\\"query\\\":\\\"dogs\\\",\\\"default_operator\\\":\\\"and\\\"}},{\\\"range\\\":{\\\"created_utc\\\":{\\\"gte\\\":1668454272000}}}]}},{\\\"bool\\\":{\\\"should\\\":[{\\\"match\\\":{\\\"subreddit\\\":\\\"animals\\\"}}],\\\"minimum_should_match\\\":1}}]}},\\\"aggs\\\":{},\\\"sort\\\":{\\\"created_utc\\\":\\\"desc\\\"}}\"}}" 124 | recorded_at: 2022-12-14 19:31:14 GMT 125 | recorded_with: vcr/1.1.0, webmockr/0.8.2 126 | -------------------------------------------------------------------------------- /tests/testthat.R: -------------------------------------------------------------------------------- 1 | # This file is part of the standard setup for testthat. 2 | # It is recommended that you do not modify it. 3 | # 4 | # Where should you do additional test configuration? 5 | # Learn more about the roles of various files in: 6 | # * https://r-pkgs.org/tests.html 7 | # * https://testthat.r-lib.org/reference/test_package.html#special-files 8 | 9 | library(testthat) 10 | library(PSAWR) 11 | 12 | test_check("PSAWR") 13 | -------------------------------------------------------------------------------- /tests/testthat/setup-PSAWR.R: -------------------------------------------------------------------------------- 1 | library("vcr") 2 | vcr::vcr_configure( 3 | dir = vcr::vcr_test_path("fixtures") 4 | ) 5 | vcr::check_cassette_names() 6 | -------------------------------------------------------------------------------- /tests/testthat/test-search.R: -------------------------------------------------------------------------------- 1 | test_that("search_comments", { 2 | vcr::use_cassette("search_comments_default", { 3 | x <- search_comments(q = "cats", size = 100,verbose = FALSE) 4 | }) 5 | expect_true(nrow(x) == 100) 6 | expect_true("tbl_df" %in% class(x)) 7 | }) 8 | 9 | test_that("search_submissions", { 10 | vcr::use_cassette("search_submissions_default", { 11 | x <- search_submissions(q = "dogs", subreddit = "animals", size = 10,verbose = FALSE) 12 | }) 13 | expect_true(nrow(x) == 10) 14 | expect_true("tbl_df" %in% class(x)) 15 | }) 16 | --------------------------------------------------------------------------------