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
The "Search Clans" operation in this Clash of Clans node allows users to search for clans based on various filtering criteria. This is useful for players or analysts who want to find clans that meet specific requirements, such as clan level, member count, war frequency, or location. For example, a user might want to find highly active clans with a minimum number of members and a certain war frequency to join or analyze competitive clans.
Properties
| Name | Meaning |
|---|---|
| After | Return only clans that occur after this marker (used for pagination) |
| Before | Return only clans that occur before this marker (used for pagination) |
| Label IDs | Comma-separated list of label IDs to filter clans by specific labels |
| Limit | Maximum number of clan results to return |
| Location ID | Filter clans by a specific location ID |
| Max Members | Maximum number of clan members |
| Min Capital Hall Level | Minimum capital hall level required for the clan |
| Min Clan Level | Minimum clan level required |
| Min Clan Points | Minimum clan points required |
| Min Members | Minimum number of clan members |
| Name | Search clans by name (partial or full match) |
| War Frequency | Clan war frequency; options include: Always, Less Than Once Per Week, More Than Once Per Week, Never, Once Per Week, Unknown |
Output
The output JSON contains an object with the following structure:
operation: The operation performed ("searchClans").url: The full API request URL used.data: The response data from the Clash of Clans API containing the list of clans matching the search criteria.timestamp: The ISO timestamp when the request was processed.metadata: Additional metadata including:operationType: Categorized type of operation ("discovery" for this operation).apiVersion: API version used ("v1").processedAt: Timestamp of processing.
The data field will typically contain an array of clan objects returned by the API, each representing a clan matching the search filters.
This node does not output binary data.
Dependencies
- Requires an API key credential for the Clash of Clans API.
- 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 credential in n8n is necessary for authentication.
Troubleshooting
- Common issues:
- Invalid or missing API token will cause authentication errors.
- Providing invalid parameter values (e.g., non-numeric where numbers are expected) may result in API errors.
- Pagination parameters (
after,before) must be valid markers returned by previous API responses.
- Error messages:
- Errors from the API will be thrown if the request is malformed or unauthorized.
- If the node is set to continue on fail, error details will be included in the output JSON for the failed item.
- Resolutions:
- Ensure the API token is correctly configured and has sufficient permissions.
- Validate input parameters before running the node.
- Use correct pagination tokens as provided by prior API calls.
Links and References
- Official Clash of Clans API documentation: https://developer.clashofclans.com/#/documentation
- Clan search API reference: https://developer.clashofclans.com/#/documentation#clans-search