Skip to main content

Documentation Index

Fetch the complete documentation index at: https://mintlify.com/VasquezRivero92/Discord_Faceit/llms.txt

Use this file to discover all available pages before exploring further.

/partidas gives any member a live snapshot of every Faceit match the bot is currently tracking for the guild. Matches are read directly from the faceit_active_matches Firestore collection and filtered by m.guild_id === interaction.guildId, so the list reflects only matches relevant to your server — not every match across all guilds the bot serves. The response is public and always up to date at the moment the command is run.

Syntax

/partidas
This command accepts no parameters.

Feature Flag

Guarded by the command_partidas feature flag scoped to the guild. When the flag is false, the bot replies with an ephemeral ❌ Este comando está desactivado por el administrador. and does not query Firestore.

Behavior

  1. Feature flag check — aborts early if disabled.
  2. Firestore query — calls db.getActiveMatches() which retrieves all documents from faceit_active_matches, then filters the result to entries where m.guild_id === interaction.guildId.
  3. Embed construction — each active match is formatted as a description line.
  4. Empty state — if no matches are found after filtering, the embed shows a grey-coloured message inviting members to join the Faceit queue.

Embed Structure

When active matches exist, each entry in the embed description follows this format:
1. [Equipo Alpha vs Equipo Beta](https://www.faceit.com/en/cs2/room/<matchId>)
🗺️ Mapa: `de_dust2` | 📍 Servidor: `EU-WEST` | 🕒 Iniciada: <t:1718000000:R>
  • Team names are hyperlinked to the full match room URL (https://www.faceit.com/en/cs2/room/<matchId>).
  • Map comes from m.map stored when the match was first detected.
  • Server location comes from m.location (uppercased). Defaults to N/A if not set.
  • Start time uses a Discord relative timestamp (<t:unix:R>) computed from Math.floor(m.startedAt / 1000), converting milliseconds to seconds, so it shows values like “3 minutes ago” and updates automatically in the client.

Empty State Embed

FieldValue
Title🟢 Partidas de Faceit Activas
DescriptionNo hay partidas activas en este momento. ¡Únete a la cola del Club en Faceit para empezar a jugar! 🎮
ColorGrey (0x8C8C8C)

Active Matches Embed

FieldValue
Title🟢 Partidas de Faceit Activas
DescriptionOne formatted line pair per active match
ColorGreen (0x00FF55)
FooterSincronizado con Faceit API

Response

The embed is sent as a public reply (ephemeral: false). interaction.deferReply() is called first so the bot has time to query Firestore before responding.
Matches appear in this list only while they have an active document in faceit_active_matches. The bot removes documents when it receives a match-finished webhook event from Faceit, or when a manual match is resolved via the Win/Cancel buttons. Completed matches no longer appear here.

Error Reference

ConditionError message
command_partidas flag is false❌ Este comando está desactivado por el administrador. (ephemeral)
Unexpected DB or formatting error❌ Ocurrió un error al obtener la lista de partidas activas.
For manual (Discord-created) matches started with /crear_sala, the map and location are both stored as Manual since no Faceit room is created. These matches still appear in /partidas and are hyperlinked to their announcement message in the matches channel.

Build docs developers (and LLMs) love