> ## Documentation Index
> Fetch the complete documentation index at: https://tokenlayer-2a53bba4.mintlify.site/llms.txt
> Use this file to discover all available pages before exploring further.

# MCP Tools Reference

> Complete guide to all available Thrust MCP tools

## Overview

The Thrust MCP server provides 10+ specialized tools that enable AI assistants to interact with tokens, social features, and blockchain operations. Each tool is optimized for specific tasks and includes built-in validation and error handling.

<Note>
  All tools require authentication via Bearer token (API key) or OAuth 2.0 flow.
</Note>

***

## Token Operations

### create\_token

Deploy a new token or meme coin on blockchain with custom branding.

**Capabilities:**

* Create tokens on Base or Base Sepolia networks
* Custom name, symbol, and description
* Upload logo, banner, and promotional video
* Add social media links (Twitter, Discord, Telegram, YouTube, Website)
* Tag with hashtags for discovery
* Optional auto-execution (one-step deployment)

**Parameters:**

* `name` (required): Token name (e.g., "Doge Coin", "Rocket Token")
* `symbol` (required): 2-10 character ticker (e.g., "DOGE", "REKT")
* `description` (required): Token description and story
* `image` (required): Logo URL or file path (PNG, JPEG, GIF, WEBP, SVG)
* `chainSlug` (required): "base" or "base-sepolia"
* `banner` (optional): Banner image URL or path
* `video` (optional): Promotional video URL or path
* `links` (optional): Object with social media URLs
* `tags` (optional): Array of hashtags
* `autoExecute` (optional): Auto-deploy on-chain (default: false)
* `userAddress` (optional): Custom wallet address

**Example:**

```typescript theme={null}
{
  name: "Rocket Dog",
  symbol: "RDOG",
  description: "The fastest dog in crypto, heading to the moon!",
  image: "https://example.com/rocket-dog.png",
  chainSlug: "base-sepolia",
  links: {
    twitter: "https://twitter.com/rocketdog",
    website: "https://rocketdog.com"
  },
  tags: ["meme", "dog", "moon"],
  autoExecute: true
}
```

**Response:**

```json theme={null}
{
  "success": true,
  "tokenId": "uuid-here",
  "contractAddress": "0x742d35Cc...",
  "transactionHash": "0x9f3b2c..."
}
```

***

### get\_tokens

Browse and discover tokens with filtering and sorting options.

**Capabilities:**

* Filter by trending, new, popular, or top posts
* Search by hashtag/category
* Pagination support
* Filter verified tokens only
* Get holder counts, vote data, and creator info

**Parameters:**

* `filter` (required): "trending" | "new" | "popular" | "top\_posts"
* `limit` (optional): Max results (1-100, default: 20)
* `offset` (optional): Pagination offset (default: 0)
* `hashtag_name` (optional): Filter by hashtag
* `verified_only` (optional): Only verified tokens (default: false)

**Example:**

```typescript theme={null}
{
  filter: "trending",
  limit: 10,
  hashtag_name: "defi"
}
```

**Response:**

```json theme={null}
{
  "tokens": [
    {
      "id": "uuid",
      "name": "DeFi Token",
      "symbol": "DEFI",
      "contract_address": "0x...",
      "holders_count": 1250,
      "upvote_count": 450,
      "downvote_count": 12,
      "creator": {...}
    }
  ],
  "total": 156
}
```

***

### search\_token

Find a specific token by address, slug, or name.

**Capabilities:**

* Search by contract address (0x...)
* Search by URL-friendly slug
* Partial name matching
* Returns full token details including price and market cap

**Parameters:**

* `input` (required): Contract address, slug, or partial name

**Example:**

```typescript theme={null}
{
  input: "0x742d35Cc6634C0532925a3b844Bc454e4438f44e"
}
// or
{
  input: "rocket-dog"
}
// or
{
  input: "doge"
}
```

**Response:**

```json theme={null}
{
  "id": "uuid",
  "name": "Rocket Dog",
  "symbol": "RDOG",
  "contract_address": "0x742d35Cc...",
  "price_usd": "0.0042",
  "market_cap": "420000",
  "description": "The fastest dog in crypto...",
  "image_url": "https://...",
  "holders_count": 350
}
```

***

### trade\_token

Buy or sell tokens with automatic execution.

**Capabilities:**

* Buy with exact USD input or exact token output
* Sell with exact token input or exact USD output
* Auto-switches between RobinSwap (new tokens) and UniswapV3 (graduated)
* Optional auto-execution
* Slippage protection

**Parameters:**

* `tokenId` (required): UUID of token to trade
* `chainSlug` (required): "base" or "base-sepolia"
* `direction` (required): "buy" | "sell"
* `buyAmountUSD` (optional): USD to spend when buying
* `buyAmountToken` (optional): Token amount to receive when buying
* `sellAmountToken` (optional): Token amount to sell
* `sellAmountUSD` (optional): USD to receive when selling
* `autoExecute` (optional): Execute immediately (default: false)
* `userAddress` (optional): Custom wallet address

**Example - Buy:**

```typescript theme={null}
{
  tokenId: "uuid-here",
  chainSlug: "base",
  direction: "buy",
  buyAmountUSD: 100,  // Spend $100
  autoExecute: true
}
```

**Example - Sell:**

```typescript theme={null}
{
  tokenId: "uuid-here",
  chainSlug: "base",
  direction: "sell",
  sellAmountToken: 1000,  // Sell 1000 tokens
  autoExecute: true
}
```

**Response:**

```json theme={null}
{
  "success": true,
  "transactionHash": "0x9f3b2c...",
  "inputAmount": "100",
  "outputAmount": "23809.52",
  "protocol": "RobinSwap"
}
```

***

### quote\_trade\_token

Get a price quote without executing a trade.

**Capabilities:**

* Preview trade amounts before execution
* No gas fees (quote only)
* Real-time pricing
* Shows which protocol will be used

**Parameters:**

* `tokenId` (required): UUID of token
* `chainSlug` (required): "base" or "base-sepolia"
* `direction` (optional): "buy" | "sell" (default: "sell")
* `amount` (optional): Amount to quote (default: 1)
* `inputToken` (optional): "token" | "usdc" (default: "token")

**Example:**

```typescript theme={null}
{
  tokenId: "uuid-here",
  chainSlug: "base",
  direction: "buy",
  amount: 100,
  inputToken: "usdc"  // How many tokens for $100?
}
```

**Response:**

```json theme={null}
{
  "inputAmount": "100",
  "outputAmount": "23809.52",
  "protocol": "RobinSwap",
  "isGraduated": false,
  "timestamp": "2025-11-04T22:30:00Z"
}
```

***

## Social Features

### create\_post

Create posts, replies, or comments with rich media.

**Capabilities:**

* Write posts with text content
* Reply to existing posts (threaded discussions)
* Attach images, videos, GIFs, links
* Create polls with weighted voting
* Tag tokens/coins
* Post to clubs or topics

**Parameters:**

* `content` (required): Post text content
* `parentPostId` (optional): UUID of post to reply to (REQUIRED for replies)
* `taggedCoinId` (optional): Tag a token
* `title` (optional): Post title
* `imageUrl` (optional): Single image URL
* `mediaData` (optional): Array of media attachments
* `pollData` (optional): Poll configuration
* `clubId` (optional): Post to specific club
* `topicId` (optional): Post to specific topic

**Example - Simple Post:**

```typescript theme={null}
{
  content: "Just bought my first RDOG tokens! To the moon! 🚀",
  taggedCoinId: "token-uuid-here"
}
```

**Example - Reply:**

```typescript theme={null}
{
  content: "Great analysis! I agree with your price target.",
  parentPostId: "post-uuid-to-reply-to"
}
```

**Example - Poll:**

```typescript theme={null}
{
  content: "What's the next 100x token?",
  pollData: {
    question: "Which token will 100x first?",
    isWeighted: true,
    options: [
      { id: "1", text: "RDOG", emoji: "🐕" },
      { id: "2", text: "MOON", emoji: "🌙" },
      { id: "3", text: "PEPE", emoji: "🐸" }
    ]
  }
}
```

**Response:**

```json theme={null}
{
  "id": "post-uuid",
  "content": "Just bought my first RDOG tokens!...",
  "created_at": "2025-11-04T22:30:00Z",
  "user_id": "user-uuid",
  "upvote_count": 0,
  "reply_count": 0
}
```

***

### get\_token\_posts

View posts from token timelines and communities.

**Capabilities:**

* Get posts for specific tokens or general feed
* Filter by content type (posts, polls, media)
* Sort by trending, new, or popular
* Filter by following or all users
* View your own posts/replies
* Pagination support

**Parameters:**

* `token_id` (optional): Filter posts for specific token
* `category` (optional): "timelines" | "polls" | "media"
* `sort` (optional): "trending" | "new" | "popular"
* `filter` (optional): "following" | "all" (default: "all")
* `view_filter` (optional): "my\_posts" | "my\_replies"
* `limit` (optional): Max results (1-100, default: 20)
* `offset` (optional): Pagination offset (default: 0)

**Example:**

```typescript theme={null}
{
  token_id: "token-uuid",
  category: "timelines",
  sort: "trending",
  limit: 20
}
```

**Response:**

```json theme={null}
{
  "posts": [
    {
      "id": "uuid",
      "content": "This token is going places!",
      "user": {...},
      "upvote_count": 42,
      "reply_count": 8,
      "created_at": "2025-11-04T22:00:00Z",
      "media": [...]
    }
  ],
  "total": 156
}
```

***

### vote

Vote (upvote/downvote) on tokens, posts, polls, or livestreams.

**Capabilities:**

* Upvote or downvote content
* Weighted voting based on token holdings
* Vote on tokens, posts, poll options, livestreams
* Optional voting token for weight calculation

**Parameters:**

* `content_id` (required): UUID of content to vote on
* `content_type` (required): "token" | "post" | "poll\_option" | "livestream"
* `vote_type` (required): "upvote" | "downvote"
* `voting_token_id` (optional): Token for weighted voting
* `post_id` (optional): Required when voting on poll options

**Example - Upvote Post:**

```typescript theme={null}
{
  content_id: "post-uuid",
  content_type: "post",
  vote_type: "upvote"
}
```

**Example - Vote in Poll:**

```typescript theme={null}
{
  content_id: "poll-option-uuid",
  content_type: "poll_option",
  vote_type: "upvote",
  post_id: "poll-post-uuid",
  voting_token_id: "token-uuid"  // Weight vote by holdings
}
```

**Response:**

```json theme={null}
{
  "id": "vote-uuid",
  "content_id": "post-uuid",
  "vote_type": "upvote",
  "created_at": "2025-11-04T22:30:00Z"
}
```

***

## Blockchain Operations

### execute\_transaction

Execute blockchain transactions on-chain.

**Capabilities:**

* Send transactions with custom data
* Automatic gas fee calculation
* Support for Base and Base Sepolia
* Required for deploying tokens (after create\_token)

**Parameters:**

* `to` (required): Recipient address (0x...)
* `amount` (required): Amount in wei (as string)
* `chainSlug` (required): "base" | "base-sepolia"
* `data` (optional): Transaction data (hex string)

**Example:**

```typescript theme={null}
{
  to: "0x742d35Cc6634C0532925a3b844Bc454e4438f44e",
  amount: "1000000000000000000",  // 1 ETH in wei
  chainSlug: "base",
  data: "0x..."
}
```

**Response:**

```json theme={null}
{
  "transactionHash": "0x9f3b2c...",
  "success": true
}
```

<Warning>
  This tool executes real blockchain transactions. Always verify transaction details before confirming!
</Warning>

***

## Discovery & Search

### get\_hashtag\_token

Look up the token associated with a hashtag.

**Capabilities:**

* Find tokens by hashtag name
* Get token details for hashtag communities
* Useful for trading hashtag tokens

**Parameters:**

* `hashtag_name` (required): Hashtag without # symbol

**Example:**

```typescript theme={null}
{
  hashtag_name: "defi"
}
```

**Response:**

```json theme={null}
{
  "token": {
    "id": "uuid",
    "name": "DeFi Token",
    "symbol": "DEFI",
    "contract_address": "0x...",
    "hashtag": "defi"
  }
}
```

***

## Tool Combinations

AI assistants can chain multiple tools together for complex workflows:

### Example: Research → Buy Flow

```
1. search_token("rocket dog")
2. get_token_posts(token_id)  // Research sentiment
3. quote_trade_token(...)      // Check price
4. trade_token(..., autoExecute: true)  // Execute buy
```

### Example: Create → Promote Flow

```
1. create_token(..., autoExecute: true)
2. create_post("Check out my new token!", taggedCoinId)
3. get_tokens(filter: "new")  // See if it appears in feed
```

### Example: Community Engagement

```
1. get_tokens(filter: "trending")
2. get_token_posts(token_id, sort: "popular")
3. create_post("Great community!", parentPostId)  // Reply
4. vote(post_id, "upvote")
```

***

## Error Handling

All MCP tools return standardized error responses:

```json theme={null}
{
  "error": "Error message",
  "code": "ERROR_CODE",
  "details": {...}
}
```

**Common Error Codes:**

* `AUTHENTICATION_FAILED` - Invalid API key or OAuth token
* `INSUFFICIENT_BALANCE` - Not enough funds for transaction
* `INVALID_PARAMETERS` - Missing or invalid parameters
* `NETWORK_ERROR` - Blockchain network issues
* `RATE_LIMIT_EXCEEDED` - Too many requests
* `TOKEN_NOT_FOUND` - Token doesn't exist
* `TRANSACTION_FAILED` - On-chain transaction reverted

***

## Rate Limits

* **Anonymous**: 10 requests/minute
* **Authenticated**: 100 requests/minute
* **Premium**: 1000 requests/minute

<Tip>
  The MCP server automatically handles rate limiting and will queue requests when necessary.
</Tip>

***

## Best Practices

<AccordionGroup>
  <Accordion title="Always Quote Before Trading">
    Use `quote_trade_token` before `trade_token` to preview amounts and avoid surprises.
  </Accordion>

  <Accordion title="Use autoExecute Carefully">
    Set `autoExecute: false` when learning. Only use `autoExecute: true` when you understand the action.
  </Accordion>

  <Accordion title="Test on Testnet First">
    Use Base Sepolia for testing token creation and trading before mainnet.
  </Accordion>

  <Accordion title="Include Context in Searches">
    Provide as much context as possible when searching tokens (symbol, name, or address).
  </Accordion>

  <Accordion title="Tag Tokens in Posts">
    Always use `taggedCoinId` when posting about tokens to increase visibility.
  </Accordion>

  <Accordion title="Use Weighted Voting">
    Specify `voting_token_id` to give your votes more weight based on holdings.
  </Accordion>
</AccordionGroup>

***

## Next Steps

<CardGroup cols={2}>
  <Card title="Example Prompts" icon="comments" href="/mcp-examples">
    Get inspired with ready-to-use examples
  </Card>

  <Card title="API Reference" icon="book" href="/api-reference">
    Explore the underlying REST API
  </Card>

  <Card title="Quickstart Guide" icon="rocket" href="/mcp-quickstart">
    Set up your first MCP connection
  </Card>

  <Card title="Support" icon="life-ring" href="mailto:support@onthrust.com">
    Get help from our team
  </Card>
</CardGroup>
