> ## Documentation Index
> Fetch the complete documentation index at: https://mintlify.com/discordplace/discord.place/llms.txt
> Use this file to discover all available pages before exploring further.

# Check Vote Status

> Check whether a user has voted for your bot in the last 24 hours.

Use this endpoint to verify a user's vote status before granting in-bot perks or rewards. A user who voted fewer than 24 hours ago is considered an active voter.

## Endpoint

```
GET /bots/{id}/voters/{user_id}
```

**Authentication:** Required — pass your API key in the `Authorization` header.\
See [Authentication](/api-reference/authentication) for details.

## Path Parameters

<ParamField path="id" type="string" required>
  The Discord snowflake ID of your bot (a 17–20 digit numeric string).

  Example: `123456789012345678`
</ParamField>

<ParamField path="user_id" type="string" required>
  The Discord snowflake ID of the user whose vote status you want to check.

  Example: `987654321098765432`
</ParamField>

## Code Examples

<CodeGroup>
  ```bash curl theme={null}
  curl https://api.discord.place/bots/123456789012345678/voters/987654321098765432 \
    -H "Authorization: YOUR_API_KEY"
  ```

  ```javascript Node.js theme={null}
  const botId = '123456789012345678';
  const userId = '987654321098765432';

  const response = await fetch(
    `https://api.discord.place/bots/${botId}/voters/${userId}`,
    { headers: { 'Authorization': process.env.DISCORD_PLACE_API_KEY } }
  );

  const { voted, vote, lastVote } = await response.json();

  if (voted) {
    console.log(`User voted ${vote} times, last at ${new Date(lastVote).toISOString()}`);
  } else {
    console.log('User has not voted in the last 24 hours.');
  }
  ```
</CodeGroup>

## Responses

### 200 — Success

<ResponseField name="voted" type="boolean" required>
  `true` if the user cast a vote within the last 24 hours, `false` otherwise.
</ResponseField>

<ResponseField name="vote" type="integer" required>
  The user's total cumulative vote count for this bot across all time. Returns `0` if the user has never voted.
</ResponseField>

<ResponseField name="lastVote" type="integer" required>
  Unix timestamp in **milliseconds** of the user's most recent vote. Returns `null` if the user has never voted.

  Example: `1694345400000`
</ResponseField>

```json theme={null}
{
  "voted": true,
  "vote": 12,
  "lastVote": 1694345400000
}
```

### Error Responses

<Expandable title="401 Unauthorized">
  <Tabs>
    <Tab title="Missing key">
      ```json theme={null}
      {
        "success": false,
        "error": "Authorization header is required.",
        "status": 401
      }
      ```
    </Tab>

    <Tab title="Invalid key">
      ```json theme={null}
      {
        "success": false,
        "error": "Invalid API key.",
        "status": 401
      }
      ```
    </Tab>
  </Tabs>
</Expandable>

<Expandable title="404 Not Found">
  ```json theme={null}
  {
    "success": false,
    "error": "Bot not found.",
    "status": 404
  }
  ```
</Expandable>

<Expandable title="429 Too Many Requests">
  This endpoint allows **100 requests per 5 minutes**. See [Rate Limits](/api-reference/rate-limits).

  ```json theme={null}
  {
    "success": false,
    "error": "Too many requests, please try again later.",
    "status": 429
  }
  ```
</Expandable>

## Tips

<Note>
  For real-time vote notifications without polling, set up a [Vote Webhook](/api-reference/bots/webhooks). The webhook fires immediately when a vote is cast, whereas this endpoint requires you to query on demand.
</Note>
