# Nakama MCP for AI Agents AI Agent Connect

> Nakama. Automate your game backend via Nakama to manage authentication, user profiles, social features, and storage directly from any AI agent. It gives you a direct line to your game's infrastructure, letting you handle player data and community management through natural conversation instead of manual dashboard clicking.

## Overview
- **Category:** developer-tools
- **Price:** Free
- **Endpoint:** https://edge.vinkius.com/vk_preview_shRah9nkk4Q2dpnMXiF99Coso93SzYTQrVnA1wUm/ai-agent-connect
- **Tags:** game-backend, multiplayer, social-gaming, leaderboards, real-time

## Description

Connect your Nakama instance to your AI agent to manage your game's backend infrastructure without switching tabs. This Connector lets you talk to your game data like a teammate. If you're tired of digging through logs or manually updating player profiles, you can just ask your agent to do it for you. You can manage friend lists, kick people from groups, or check leaderboard records in seconds. It's a way to make your backend feel like a conversation. By using this Connector through the Vinkius catalog, you get a direct line to your social and real-time game data. You can also trigger custom logic via RPC calls or manage storage objects for player inventories. It turns complex backend operations into simple commands, letting you focus on the game while your agent handles the heavy lifting of data management.

## Tools

### add_friends
Add friends or send invites. Use this to manage social connections between players.

### add_group_members
Add members to a group. Quickly put new users into specific community areas.

### authenticate_device
Authenticate using a device ID. Log users in based on their specific hardware.

### authenticate_email
Authenticate using email and password. Standard login flow for your players.

### block_friends
Block users. Prevent specific players from interacting with each other.

### create_group
Create a new group. Set up new community spaces for your players on the fly.

### delete_friends
Remove friends or reject invites. Clean up social connections for a player.

### delete_storage_objects
Delete storage objects. Wipe specific data from your game's persistent storage.

### get_account
Fetch current user account. Pull the profile information for the logged in user.

### get_channel_history
Get channel message history. Review previous conversations in a specific channel.

### join_tournament
Join a tournament. Register a player for a specific competitive event.

### leave_group
Leave a group. Remove a user from their current group membership.

### list_friends
List friends. See all current friend connections for a user.

### list_groups
List groups. View every group currently active in your game.

### list_leaderboard_records
List leaderboard records. See all scores and rankings on a specific board.

### list_storage_objects
List storage objects. See all items currently saved in your game storage.

### list_tournaments
List tournaments. View all active or upcoming tournaments in your game.

### read_storage_objects
Read storage objects. Fetch game data like inventory or player state.

### refresh_session
Refresh a session token. Renew a user's session without forcing a logout.

### rpc_call
Call an RPC function. Trigger custom server side logic or integrations.

### update_account
Update the current user account. Use this to modify profile details or status quickly.

### write_leaderboard_record
Write a leaderboard record. This adds new scores to your competitive rankings.

### write_storage_objects
Write storage objects. Save new data to your game's persistent storage.

### logout_session
Logout a session. End the current user's active session.

### promote_group_members
Promote group members. Give users higher permissions within a group.

### delete_account
Delete current user account. Permanently remove a user from your system.

### demote_group_members
Demote group members. Reduce the permissions of users in a specific group.

### get_users
Fetch public user profiles. See the public info for all users in your game.

### join_group
Join a group. Add a user to an existing group membership.

### kick_group_members
Kick group members. Remove users from a group immediately for moderation.

### write_tournament_record
Write a tournament record. Add new scores to a specific tournament event.

## Prompt Examples

**Prompt:** 
```
Can you check if the player 'DragonSlayer' is in any groups and show me their last tournament score?
```

**Response:** 
```
I've checked the records for **DragonSlayer**: 

- **Group Membership**: They are currently a member of the **'Elite Raiders'** group.
- **Recent Score**: Their last recorded score was **12,450 points** in the 'Summer Cup' tournament.

Would you like me to promote them to a higher rank in that group?
```

**Prompt:** 
```
I need to remove the user 'TrollFace99' from the 'Public Lounge' group because they are being disruptive.
```

**Response:** 
```
I've successfully removed **TrollFace99** from the **'Public Lounge'** group. I can also block them from sending friend requests if you'd like.
```

**Prompt:** 
```
Show me the top 3 scores from the 'Global_High_Scores' leaderboard.
```

**Response:** 
```
| Rank | Player | Score |
| :--- | :--- | :--- |
| 1 | **ShadowWalker** | 50,000 |
| 2 | **PixelQueen** | 48,200 |
| 3 | **NeonKnight** | 47,950 |

Let me know if you want to see more records!
```

## Capabilities

### Kick group members
Remove users from specific groups instantly to manage community behavior.

### Update player accounts
Modify user profiles and account details through simple text commands.

### Write tournament records
Add new entries to competitive leaderboards and tournament lists.

### Manage friend lists
Add, block, or remove friends for your players via the agent.

### Read storage objects
Fetch player state, inventory data, or global game settings.

### Authenticate users
Log players in using emails, device IDs, or social providers.

## Use Cases

### Handling a disruptive player
A LiveOps manager notices a user harassing others. They ask their agent to use kick_group_members to remove the user from the 'General' group immediately.

### Checking player inventory
A developer needs to verify a bug in a player's items. They ask the agent to read_storage_objects for that specific player ID to see their current inventory.

### Updating tournament scores
A tournament admin wants to record a new win. They ask the agent to write_tournament_record for the current event to update the standings.

### Bulk profile updates
A support agent needs to update a player's status. They ask the agent to use update_account to change the player's rank and profile name.

## Benefits

- Manage your community groups instantly by using create_group, add_group_members, and kick_group_members to handle social features without a dashboard.
- Update player accounts quickly with update_account and get_account to modify profiles and status in real time.
- Control competitive play by using write_leaderboard_record and write_tournament_record to update scores as they happen.
- Handle player items and state data using read_storage_objects and list_storage_objects to inspect inventories or global settings.
- Simplify user authentication by using authenticate_email and authenticate_device to manage sessions and logins.
- Execute complex game logic by using rpc_call to trigger custom server side functions or third party integrations.

## How It Works

The bottom line is you get a natural language interface for your entire game backend.

1. Subscribe to the Nakama MCP on Vinkius.
2. Enter your Nakama Server URL and Session Token in your client.
3. Start managing your game backend from Claude, Cursor, or any MCP-compatible client.

## Frequently Asked Questions

**Can I use the Nakama MCP to manage my game's player profiles?**
Yes. You can use it to fetch, update, and delete user profiles through your AI agent. This lets you modify player data using natural language instead of a complex admin panel.

**Does the Nakama MCP support real-time leaderboards?**
Yes. You can ask your agent to list leaderboard records or write new scores to specific boards. It's perfect for managing competitive rankings during live events.

**How does the Nakama MCP handle group management for my game?**
It gives your agent the ability to create groups, add or remove members, and promote or demote users. You can manage your entire community's social structure via chat.

**Can I use Nakama MCP to check player inventory data?**
Yes. By using the storage tools, your agent can read and list storage objects. This is how you check player state, items, or any other persistent data you've saved.

**Is the Nakama MCP good for debugging game backend issues?**
It's excellent for debugging. You can quickly query user accounts, check session statuses, and verify storage objects without needing to run manual database queries.

**Can my AI agent handle user logins with this Connector?**
Yes. The Connector includes tools to authenticate users via email or device IDs. Your agent can handle these login flows and manage active sessions for you.

**Can I register new players using this server?**
Yes. Use `authenticate_email` or `authenticate_device` with the `create` flag set to true. This will register a new account if the credentials don't already exist.

**How do I retrieve a player's virtual wallet or metadata?**
Use the `get_account` tool. It returns the full profile, including the wallet JSON and any linked device identifiers for the authenticated user.

**Can I trigger custom server-side logic?**
Absolutely. Use the `rpc_call` tool by providing the specific Function ID. This allows your AI agent to execute any custom Lua, Go, or TypeScript modules you've deployed.