ExValorantAPIClient v0.1.0 ExValorantAPIClient View Source
This module is Valorant API wrapper public interface.
Since the API is not yet available to the public, I have not confirmed that this module works properly.
Link to this section Summary
Functions
Get Account data by puuid.
Get Account data by game_name and tag_line.
Get active shard for a player.(???)
Get content optionally filtered by locale.
Get match by id.
Get metchlist for games played by puuid
Create api client.
Link to this section Functions
Specs
get_account_by_puuid(Tesla.Client.t(), String.t(), keyword()) :: Tesla.Env.result()
Get Account data by puuid.
Options
region
- Change region.
Example
ExValorantAPIClient.get_account_by_puuid(client, "your_puuid")
get_account_by_riot_id(client, game_name, tag_line, opts \\ [])
View Source (since 0.1.0)Get Account data by game_name and tag_line.
Options
region
- Change region.
Example
# ExValorantAPIClient.get_account_by_riot_id(client, "your_game_name", "your_tag_line")
umm...
get_active_shards_for_a_player(client, game, puuid, opts \\ [])
View Source (since 0.1.0)Get active shard for a player.(???)
Options
region
- Change region.
Example
ExValorantAPIClient.get_active_shards_for_a_player(client, "val or lor", "your_puuid")
get_content_optionally_filtered_by_locale(client, opts \\ [])
View Source (since 0.1.0)Specs
get_content_optionally_filtered_by_locale(Tesla.Client.t(), keyword()) :: Tesla.Env.result()
Get content optionally filtered by locale.
Options
region
- Change region.
Example
ExValorantAPIClient.get_content_optionally_filtered_by_locale(client)
Specs
get_match_by_id(Tesla.Client.t(), String.t(), keyword()) :: Tesla.Env.result()
Get match by id.
Options
region
- Change region.
Example
ExValorantAPIClient.get_match_by_id(client, "match_id")
get_matchlist_for_games_played_by_puuid(client, puuid, opts \\ [])
View Source (since 0.1.0)Specs
get_matchlist_for_games_played_by_puuid(Tesla.Client.t(), String.t(), keyword()) :: Tesla.Env.result()
Get metchlist for games played by puuid
Options
region
- Change region.
Example
ExValorantAPIClient.get_matchlist_for_games_played_by_puuid(client, "your_puuid")
Create api client.
Examples
iex> client = ExValorantAPIClient("your_api_key")
%Tesla.Client{
adapter: nil,
fun: nil,
post: [],
pre: [
{Tesla.Middleware.DecompressResponse, :call, [[]]},
{Tesla.Middleware.JSON, :call, [[engine: Jason]]},
{Tesla.Middleware.BaseUrl, :call, ["https://americas.api.riotgames.com"]},
{Tesla.Middleware.Headers, :call, [[{"X-Riot-Token", "your_api_key"}]]}
]
}
This method sets the americas region by default. If you want to chang default region, please set opts.
client = ExValorantAPIClient.new("your_api_key", default_region: "asia") # or europe
%Tesla.Client{
adapter: nil,
fun: nil,
post: [],
pre: [
{Tesla.Middleware.DecompressResponse, :call, [[]]},
{Tesla.Middleware.JSON, :call, [[engine: Jason]]},
{Tesla.Middleware.BaseUrl, :call, ["https://asia.api.riotgames.com"]},
{Tesla.Middleware.Headers, :call, [[{"X-Riot-Token", "your_api_key"}]]}
]
}