> ## Documentation Index
> Fetch the complete documentation index at: https://docs.open-metadata.org/llms.txt
> Use this file to discover all available pages before exploring further.

# Followers & Votes

> Manage followers and votes for tables

# Followers & Votes

Manage followers and votes for table entities. Followers receive notifications about changes. Votes help surface popular or important tables.

## Followers

### Add Follower

`PUT /v1/tables/{id}/followers`

<ParamField path="id" type="string" required>
  UUID of the table.
</ParamField>

<ParamField body="id" type="string" required>
  UUID of the user to add as a follower (sent as request body string).
</ParamField>

### Remove Follower

`DELETE /v1/tables/{id}/followers/{userId}`

<ParamField path="id" type="string" required>
  UUID of the table.
</ParamField>

<ParamField path="userId" type="string" required>
  UUID of the user to remove.
</ParamField>

## Votes

### Add or Update Vote

`PUT /v1/tables/{id}/vote`

<ParamField path="id" type="string" required>
  UUID of the table.
</ParamField>

<ParamField body="updatedVoteType" type="string" required>
  Vote type: `votedUp`, `votedDown`, or `unVoted`.
</ParamField>

<RequestExample dropdown>
  ```python PUT /v1/tables/{id}/followers theme={null}
  from metadata.sdk import configure
  from metadata.sdk.entities import Tables

  configure(
      host="https://your-company.open-metadata.org/api",
      jwt_token="your-jwt-token"
  )

  table_id = "a1b2c3d4-e5f6-7890-abcd-ef1234567890"
  user_id = "user-uuid-here"

  # Add a follower
  table = Tables.add_followers(table_id, [user_id])
  print(f"Followers: {len(table.followers)}")

  # Remove a follower
  table = Tables.remove_followers(table_id, [user_id])

  # Add a vote
  table = Tables.add_vote(table_id, vote_type="votedUp")

  # Remove a vote
  table = Tables.remove_vote(table_id)
  ```

  ```java PUT /v1/tables/{id}/followers theme={null}
  import static org.openmetadata.sdk.fluent.Tables.*;

  String tableId = "a1b2c3d4-e5f6-7890-abcd-ef1234567890";

  // Add a follower
  Tables.addFollower(tableId, "user-uuid-here");

  // Remove a follower
  Tables.removeFollower(tableId, "user-uuid-here");

  // Add a vote
  Tables.vote(tableId, "votedUp");

  // Remove a vote
  Tables.vote(tableId, "unVoted");
  ```

  ```bash PUT /v1/tables/{id}/followers theme={null}
  # Add a follower
  curl -X PUT "{base_url}/api/v1/tables/455e3d9d-dbbf-455e-b3be-7191daa825f3/followers" \
    -H "Authorization: Bearer {access_token}" \
    -H "Content-Type: application/json" \
    -d '"2e7fc52a-57d3-4c0e-8a90-1b77c5a6b8e4"'

  # Remove a follower
  curl -X DELETE "{base_url}/api/v1/tables/455e3d9d-dbbf-455e-b3be-7191daa825f3/followers/2e7fc52a-57d3-4c0e-8a90-1b77c5a6b8e4" \
    -H "Authorization: Bearer {access_token}"

  # Add a vote
  curl -X PUT "{base_url}/api/v1/tables/455e3d9d-dbbf-455e-b3be-7191daa825f3/vote" \
    -H "Authorization: Bearer {access_token}" \
    -H "Content-Type: application/json" \
    -d '{"updatedVoteType": "votedUp"}'

  # Remove a vote
  curl -X PUT "{base_url}/api/v1/tables/455e3d9d-dbbf-455e-b3be-7191daa825f3/vote" \
    -H "Authorization: Bearer {access_token}" \
    -H "Content-Type: application/json" \
    -d '{"updatedVoteType": "unVoted"}'
  ```
</RequestExample>

<ResponseExample>
  ```json Response (Add Follower) theme={null}
  {
    "id": "455e3d9d-dbbf-455e-b3be-7191daa825f3",
    "name": "agent_performance_summary",
    "fullyQualifiedName": "sample_data.ecommerce_db.shopify.agent_performance_summary",
    "followers": [
      {
        "id": "2e7fc52a-57d3-4c0e-8a90-1b77c5a6b8e4",
        "type": "user",
        "name": "admin"
      }
    ]
  }
  ```
</ResponseExample>

***

## Error Handling

| Code  | Error Type     | Description                             |
| ----- | -------------- | --------------------------------------- |
| `401` | `UNAUTHORIZED` | Invalid or missing authentication token |
| `403` | `FORBIDDEN`    | User lacks permission                   |
| `404` | `NOT_FOUND`    | Table or user does not exist            |
