Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/christopherkenny/clash

Access the Clash of Clans API
https://github.com/christopherkenny/clash

Last synced: 28 days ago
JSON representation

Access the Clash of Clans API

Awesome Lists containing this project

README

        

---
output: github_document
---

```{r, include = FALSE}
knitr::opts_chunk$set(
collapse = TRUE,
comment = "#>",
fig.path = "man/figures/README-",
out.width = "100%"
)
```

# clash clash website

[![R-CMD-check](https://github.com/christopherkenny/clash/actions/workflows/R-CMD-check.yaml/badge.svg)](https://github.com/christopherkenny/clash/actions/workflows/R-CMD-check.yaml)
[![clash status badge](https://christopherkenny.r-universe.dev/badges/clash)](https://christopherkenny.r-universe.dev/clash)
[![Lifecycle: stable](https://img.shields.io/badge/lifecycle-stable-brightgreen.svg)](https://lifecycle.r-lib.org/articles/stages.html#stable)

`clash` provides an R interface to the [Clash of Clans
API](https://developer.clashofclans.com/#/).

## Installation

You can install the development version of `clash` from
[GitHub](https://github.com/) with:

``` r
# install.packages("remotes")
remotes::install_github("christopherkenny/clash")
```

## Example

Current endpoints are included for cards, rankings, tournaments, players, and clans.

To get a player’s data, we can use:

```{r example}
library(clash)

coc_get_player('92GCQQYP')
```

To get a clan, we can use:

```{r}
clan <- coc_get_clan('8UC2J9OY')
clan
```
This returns clan-level attributes, such as lists of members in the clan:

```{r}
clan$member_list
```

## Disclaimer

**This content is not affiliated with, endorsed, sponsored, or
specifically approved by Supercell and Supercell is not responsible for
it. For more information see Supercell’s Fan Content Policy:
\.**