data-transformation
Process and format Free Fire API responses for different use cases including Discord bots, web dashboards, and calculating derived metrics
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
菜单
Process and format Free Fire API responses for different use cases including Discord bots, web dashboards, and calculating derived metrics
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
基于 SOC 职业分类
Implement secure authentication patterns for Free Fire API using header or query parameter authentication with proper API key handling
Implement comprehensive error handling and retry logic for Free Fire API calls including rate limiting, network errors, and exponential backoff
Generate Free Fire API integration code examples in multiple programming languages including Python, JavaScript, PHP, cURL, Java, Go, and Ruby
Validate input parameters before making Free Fire API calls including UID format, region values, language codes, and map codes
Implement caching strategies to reduce Free Fire API calls and avoid rate limits with TTL-based cache management
| name | data-transformation |
| description | Process and format Free Fire API responses for different use cases including Discord bots, web dashboards, and calculating derived metrics |
This skill helps AI agents process and format API responses for different use cases.
AI agents should:
def format_player_stats(stats_data):
"""Transform raw stats into readable format"""
player_stats = stats_data['data']
formatted = {
'player_id': player_stats['uid'],
'solo': {
'win_rate': f"{(player_stats['solo']['wins'] / player_stats['solo']['gamesPlayed'] * 100):.1f}%",
'kd_ratio': f"{player_stats['solo']['kd']:.2f}",
'total_kills': player_stats['solo']['kills']
},
'duo': {
'win_rate': f"{(player_stats['duo']['wins'] / player_stats['duo']['gamesPlayed'] * 100):.1f}%",
'kd_ratio': f"{player_stats['duo']['kd']:.2f}",
'total_kills': player_stats['duo']['kills']
},
'squad': {
'win_rate': f"{(player_stats['squad']['wins'] / player_stats['squad']['gamesPlayed'] * 100):.1f}%",
'kd_ratio': f"{player_stats['squad']['kd']:.2f}",
'total_kills': player_stats['squad']['kills']
}
}
return formatted
import discord
def create_player_embed(player_data):
"""Create Discord embed from player data"""
embed = discord.Embed(
title=f"🎮 {player_data['name']}",
description=f"Level {player_data['level']} | {player_data['region'].upper()}",
color=0x00ff00
)
embed.add_field(name="UID", value=player_data['uid'], inline=True)
embed.add_field(name="Rank", value=player_data['rank'], inline=True)
embed.add_field(name="Clan", value=player_data.get('clan', 'None'), inline=True)
if 'stats' in player_data:
embed.add_field(
name="📊 Stats",
value=f"Wins: {player_data['stats']['wins']}\nKills: {player_data['stats']['kills']}",
inline=False
)
return embed
Calculate and format these metrics:
(wins / gamesPlayed) * 100kills / deathskills / gamesPlayed(headshots / kills) * 100(survivals / gamesPlayed) * 100(top3 / gamesPlayed) * 100