Actions24
- Get Capital District Info
- Get Clan
- Get Clan Capital Info
- Get Clan Capital Raid Log
- Get Clan Members
- Get Clan Rankings
- Get Clan War Log
- Get Current War
- Get CWL Group
- Get CWL War
- Get League Info
- Get League Season Rankings
- Get League Seasons
- Get Location Info
- Get Location Rankings
- Get Locations
- Get Player
- Get Player Achievement Progress
- Get Player Battle Log
- Get Player Rankings
- Get Player Upcoming Chests
- Get War Leagues
- Search Clans
- Verify Player Token
Overview
This node integrates with the Clash of Clans API to retrieve various types of game data related to players, clans, locations, leagues, wars, and more. Specifically, the "Get Player Rankings" operation fetches player ranking information filtered by a specified location. This is useful for scenarios where you want to analyze or display player standings within a particular region or globally.
Practical examples include:
- Displaying top-ranked players in a global leaderboard.
- Tracking player rankings within a specific country or region.
- Integrating player ranking data into dashboards or reports for gaming communities.
Properties
| Name | Meaning |
|---|---|
| Player Tag | The unique identifier of the player whose rankings are to be retrieved. Must start with #. |
| Location ID | The identifier of the location (region) for which to get player rankings. Examples: 32000006 for Global, 32000007 for USA, etc. |
Output
The node outputs JSON data containing detailed player ranking information as returned by the Clash of Clans API. The output structure includes:
operation: The operation performed (getPlayerRankings).url: The full API endpoint URL used for the request.data: The actual response data from the API, which includes player ranking details such as rank, player tag, name, trophies, and other relevant statistics.timestamp: The ISO timestamp when the data was fetched.metadata: Additional metadata including the type of operation (player), API version, and processing timestamp.
No binary data is produced by this operation.
Dependencies
- Requires an API key credential for the Clash of Clans API to authenticate requests.
- The node makes HTTP requests to the official Clash of Clans API endpoint at
https://api.clashofclans.com/v1. - Proper configuration of the API token in n8n credentials is necessary.
Troubleshooting
Common issues:
- Invalid or missing player tag (must start with
#): Ensure the player tag input is correctly formatted. - Incorrect or expired API token: Verify that the API key credential is valid and has not expired.
- Invalid location ID: Use a valid location ID recognized by the Clash of Clans API.
- Network or connectivity problems: Check internet connection and API availability.
- Invalid or missing player tag (must start with
Error messages:
"Operation 'getPlayerRankings' not supported": This indicates an unsupported operation was selected; verify the operation name.- HTTP errors such as 401 Unauthorized or 403 Forbidden usually indicate authentication issues.
- 404 Not Found may indicate invalid player tag or location ID.
To resolve errors, double-check input parameters, ensure valid credentials, and consult the Clash of Clans API documentation for correct IDs and usage.