How to connect PromptLayer to Grok Bot

Connect Grok Bot to PromptLayer MCP. List failed promptlayer requests today, compare prompt versions by evaluation score, and more using natural language, with authentication handled for you.

PromptLayer logoPromptLayer
Api Key

PromptLayer is a prompt management and observability platform for LLM apps. Use it to version prompts, run evaluations, trace requests, and analyze model behavior.

115 Tools

Introduction

Grok is xAI's assistant, and its bot builder lets you create a personal agent that holds context, runs skills, and connects to the apps you already use through plugins.

This guide explains how to connect PromptLayer to a Grok bot using Composio Connect, which handles OAuth, token refresh, and reliability so you do not have to. You add Composio as a plugin, authenticate once, then ask your bot to work with PromptLayer in plain language.

For exact tool slugs and parameter tables, see the tool catalog in the Composio docs.

Why use Composio?

Composio exposes 2,000+ apps to your Grok bot through a single connection, so you get:

  • Connect to 2,000+ apps with on-demand tool loading, so you do not fill your context window with unnecessary tool definitions.
  • Use programmatic tool calling through a remote workbench, letting the model write its own code to handle complex tool chaining. This reduces back-and-forth for frequent tool calls.
  • Handle large tool responses outside the model context to keep conversations lean.

Connecting PromptLayer to Grok Bot

Once Grok Bot is set up, you connect PromptLayer entirely from its interface, and the whole flow takes under a minute.

Set up Grok Bot

Get access. Grok Bot is included with Cursor Ultra, Cursor Premium Teams, and SuperGrok Heavy. Get the desktop app for macOS or Windows from x.ai/bot and sign in. An iPhone companion app is also available, and your bots sync across devices.

Create a bot. Pick a suggested role or define your own, then give it a short name, one primary job, and a short description of how it should work. Focused bots work best, because a clear role gives the bot more useful context over time.

Connect PromptLayer

1. Add the Composio plugin

Click the button. The Composio listing on x.ai opens and launches Grok Bot for you. If the app does not open on its own, click Add to Grok Bot.

Add to Grok Bot

Composio for Grok Bot listing on x.ai with the Add to Grok Bot button

Grok Bot opens the Composio plugin, showing its connector and skills. Click Add.

Composio plugin sheet in Grok Bot with the Add button

2. Authenticate

Go to the Installed section and click the Composio entry. You'll see its connector and skills listed.

Installed Composio plugin showing the Authenticate button

Click Authenticate. You'll be taken to the Composio consent screen. Review the access it requests and click Authorize. Composio handles the OAuth handshake for you, so you never touch API keys or tokens.

Composio authorization screen with Authorize and Deny

3. Connect your PromptLayer account

Back in the chat, ask your bot to connect to PromptLayer or give it any PromptLayer task.

For example, ask it to:

  • "List failed PromptLayer requests today"
  • "Compare prompt versions by evaluation score"
  • "Run saved PromptLayer prompt with variables"

It will prompt you to authenticate and authorize access.

That's it. Composio's tools are now available in your Grok bot, and your PromptLayer account is ready to use.

What is Grok Bot?

Grok is xAI's assistant, available as a chat interface and a bot builder for creating personal agents that run skills and connect to external apps.

With Composio Connect, your Grok bot can securely access apps like PromptLayer through MCP without you sharing account credentials directly with the agent.

What is the PromptLayer MCP server, and what's possible with it?

The PromptLayer MCP server is an implementation of the Model Context Protocol that connects your AI agent and assistants like Claude, Cursor, etc directly to your PromptLayer account. It provides structured and secure access to your prompts, request logs, workflows, tools, skill collections, and tables, so your agent can find prompt templates, inspect LLM activity, browse workflows, review registered resources, and analyze table data on your behalf.

  • Prompt discovery and inspection: Have your agent search prompt templates and retrieve specific versions, messages, model settings, snippets, or release details for review.
  • Request monitoring and analysis: Instruct your agent to search LLM request logs and inspect recorded inputs, outputs, timing, usage, metadata, tags, and scores.
  • Workflow and tool exploration: Let the agent find workflows and registered tools, then retrieve their definitions without running them.
  • Skill and workspace browsing: Direct your agent to browse folders, registry items, and skill collections, including the files stored in a selected collection.
  • Table data review: Have your agent find tables, inspect their sheets and columns, and read rows with optional schema and execution summaries.

Way Forward

Now that PromptLayer is connected, extend your setup by connecting the other apps you already use every day, so your Grok bot can run true cross-app workflows end to end.

  • Connect Calendar to turn threads into scheduled meetings automatically.
  • Connect Slack or Teams to post summaries, approvals, and alerts where your team works.
  • Connect Notion, Linear, Jira, or Asana to convert requests into tickets, tasks, and docs.
  • Connect Drive, Dropbox, or OneDrive to fetch, file, and share attachments without manual steps.

Start with one workflow you do repeatedly, then keep adding apps as you find new handoffs. With everything behind a single connection, your bot can coordinate multiple tools safely and reliably in one conversation.

TOOLS

Supported Tools

Every PromptLayer action and event your agent gets out of the box.

Add Table Rows

Append one or more rows to a PromptLayer Table sheet in the API key's workspace.

Attach Folder External ID

Attach an external-system identifier to an existing PromptLayer folder.

Attach Prompt Template External ID

Attach an external system identifier to an existing PromptLayer prompt template.

Attach Registered Tool External ID

Attach an external-system identifier to an existing PromptLayer registered tool.

Attach Skill Collection External ID

Attach an external system identifier to a PromptLayer skill collection by UUID.

Attach Workflow External ID

Attach an external-system identifier to an existing PromptLayer workflow.

Cancel Table Sheet Operation

Cancel an active PromptLayer Table sheet recalculation operation.

Cancel Table Sheet Scorecard

Cancel queued or running scorecard work for a PromptLayer table sheet.

Close Trace

Close a PromptLayer trace, permanently preventing further span ingestion for that trace through spans-bulk or OTLP /v1/traces.

Configure Table Sheet Score

Configure scoring for a PromptLayer Table sheet using columns, boolean or numeric scoring, or custom code.

Configure Table Sheet Scorecard

Create or update the active scorecard for a PromptLayer table sheet.

Create Folder

Create a PromptLayer folder at the workspace root or inside a parent folder, optionally attaching external identifiers.

Create Prompt Template Label

Create a release label for a specific version of a PromptLayer prompt template.

Create Registered Tool

Create a PromptLayer registered tool and its initial version in the API key's workspace using an OpenAI function-calling definition.

Create Registered Tool Environment Variable

Create an environment variable scoped to a registered PromptLayer tool, identified by numeric ID or name.

Create Registered Tool Version

Create a new version of an existing PromptLayer registered tool by numeric ID or name using an OpenAI function-calling definition.

Create Skill Collection

Create a PromptLayer skill collection in the API key's workspace, optionally with initial text files, a destination folder, provider, and external IDs.

Create Table

Create a PromptLayer Table in the API key's workspace, optionally in a folder.

Create Table Column

Add a column to a PromptLayer Table sheet in the API key's workspace.

Create Table Sheet

Create a sheet in a PromptLayer Table in the API key's workspace.

Create Table Sheet Operation

Queue recalculation of a PromptLayer Table sheet, optionally selecting columns, zero-based rows, and cell statuses.

Create Table Sheet Version

Create a named snapshot of a PromptLayer Table sheet, or restore an existing version while creating a new version.

Create Workflow

Create a PromptLayer workflow, or a new version of an existing workflow.

Create Workspace Environment Variable

Create a workspace environment variable in the API key's workspace.

Delete Folder Entities

Delete PromptLayer registry entities by ID and type.

Delete Folder External ID

Detach an external identifier from a PromptLayer folder using its folder ID, source namespace, and external ID value.

Delete Prompt Template External ID

Detach an external identifier from a PromptLayer prompt template using its template ID, source namespace, and external ID value.

Delete Prompt Template Label

Delete a PromptLayer prompt template release label by its label ID.

Delete registered tool environment variable

Delete one tool-scoped environment variable from a PromptLayer registered tool identified by its ID or name.

Delete Registered Tool External ID

Detach an external identifier from a PromptLayer registered tool using its tool ID, source namespace, and external ID value.

Delete Skill Collection External ID

Detach one external ID mapping from a PromptLayer skill collection by its UUID, source, and external ID.

Delete Table

Soft delete a PromptLayer Table by UUID, removing it from active list responses.

Delete Table Column

Delete a column and its cells from a PromptLayer Table sheet.

Delete Table Sheet

Soft delete a sheet from a PromptLayer Table, removing it from active sheet list responses.

Delete Table Sheet Scorecard

Soft-delete the active scorecard for a PromptLayer table sheet.

Delete Workflow External ID

Detach an external identifier from a PromptLayer workflow using its workflow ID, source namespace, and external ID value.

Delete workspace environment variable

Delete a PromptLayer workspace environment variable by its integer ID.

Get Prompt Snippet Usage

Get the prompts, version numbers, and labels using a prompt-template snippet by name or numeric ID.

Get Prompt Template

Retrieve a prompt template version, release label, messages, model metadata, snippets, and optionally provider-ready kwargs without executing it.

Get Registered Tool

Retrieve a PromptLayer registered tool definition by ID or name at a selected version or release label without test execution.

Get Request Analytics

Read aggregated PromptLayer request-log analytics, including costs, tokens, latency percentiles, time series, and usage breakdowns.

Get Request Log

Retrieve one PromptLayer request log with its recorded input, output, timing, usage, metadata, tags, and scores.

Get Request Search Suggestions

Get autocomplete suggestions for a PromptLayer request-log search field.

Get Skill Collection

Retrieve a PromptLayer skill collection and its files as JSON at a selected version or release label.

Get Table

Retrieve one PromptLayer Table's metadata and per-sheet row counts by UUID.

Get Table Cell

Retrieve a single cell by UUID from a PromptLayer Table sheet.

Get Table Scorecard Calculation

Get a single scorecard calculation for a PromptLayer table sheet by its calculation UUID.

Get Table Scorecard Row

Get the row-level scorecard breakdown for a zero-based row index in a PromptLayer table sheet, including aggregate score, verdict, step results, and drift or staleness metadata.

Get Table Sheet

Get metadata for one sheet in a PromptLayer Table, including its row count, display order, and current version.

Get Table Sheet Import Operation

Poll the status of an asynchronous PromptLayer Table sheet import using its operation ID.

Get Table Sheet Operation

Poll a PromptLayer Table sheet recalculation operation by its operation ID.

Get Table Sheet Score

Retrieve the current score payload for a PromptLayer table sheet, including calculation status, scoring configuration, per-column results, and aggregate scores.

Get Table Sheet Scorecard

Get the active scorecard for a PromptLayer table sheet, including its evaluation steps, latest and display calculation metadata, summaries, and progress.

Get Table Sheet Score History

Retrieve score-history points across saved versions of a PromptLayer table sheet, with optional history range, resolution, and maximum point count.

Get Table Sheet Version

Retrieve one saved PromptLayer Table sheet version, including its snapshot and recorded changes.

Get Trace

Retrieve a PromptLayer trace by its trace ID, including its spans and any associated request-log IDs.

Get Workflow

Retrieve a PromptLayer workflow definition by ID or name at a specific version or release label without running it.

Get Workflow Execution Results

Retrieve results of an already-started PromptLayer workflow execution.

Import Table Sheet File

Start an asynchronous CSV import into an existing PromptLayer Table sheet.

Import Request Logs Into Table Sheet

Start an asynchronous request-history import into an existing PromptLayer Table sheet.

Ingest OTLP Traces

Ingest OpenTelemetry traces using OTLP JSON, optionally gzip-compressed.

Ingest Spans

Persist a batch of OpenTelemetry-style observability spans and optional associated request logs in PromptLayer without invoking a model.

List Folder Entities

Browse or search PromptLayer folders and registry entities in the API-key workspace, optionally recursively and with metadata.

List Folder External IDs

List all external identifier mappings attached to a PromptLayer folder by its folder ID.

List Prompt Template External IDs

List all external system identifiers attached to a PromptLayer prompt template by its numeric ID.

List Prompt Template Labels

List all release labels for a prompt template by name or numeric ID, including each label's associated version ID and version number.

List Prompt Templates

Search and page through PromptLayer prompt templates and snippets without executing a model.

List Registered Tool Environment Variables

List environment variables for a PromptLayer registered tool by ID or name.

List Registered Tool External IDs

List all external identifier mappings attached to a registered PromptLayer tool by its tool ID.

List Registered Tools

List and filter tools defined in PromptLayer's tool registry without executing them.

List Skill Collection External IDs

List all external system identifier mappings attached to a PromptLayer skill collection by UUID.

List Skill Collections

List and filter PromptLayer skill collections available in the API-key workspace.

List Table Columns

List one page of user and optionally system columns for a PromptLayer Table sheet.

List Table Rows

Read one page of rows and cells from a PromptLayer Table sheet, with optional schema and execution aggregates.

List Tables

Search and page through PromptLayer Tables by folder, name, or referenced prompt.

List Table Scorecard Rows

List one page of row-level scorecard summaries for a PromptLayer table sheet.

List Table Sheet Operations

List active recalculation operations and cell status counts for a PromptLayer Table sheet in the API key's workspace.

List Table Sheets

List one page of sheets in a PromptLayer Table, optionally filtering by referenced prompt.

List Table Sheet Versions

List one page of saved versions for a PromptLayer Table sheet in the API key's workspace.

List Workflow External IDs

List all external system identifiers attached to a PromptLayer workflow by its numeric ID.

List Workflow Labels

List all release labels for a PromptLayer workflow by ID or name, including the version ID and version number each label points to.

List Workflows

Search and page through PromptLayer workflows without running them.

List Workspace Env Vars

List environment variables for the API key's PromptLayer workspace.

Log Request

Log an existing model request and response in PromptLayer with timing, usage, cost, tags, metadata, and optional prompt association.

Migrate Table Sheet Legacy Score

Convert a PromptLayer Table sheet's existing legacy score configuration into scorecard criteria.

Move Folder Entities

Move PromptLayer registry entities into a destination folder or to the workspace root.

Move Prompt Template Label

Move an existing PromptLayer release label to a different version of the same prompt template.

Patch Prompt Template Version

Create a new version of an existing PromptLayer template by patching its latest version, a specific version, or a release label.

Patch Workflow

Partially update a PromptLayer workflow by ID or name, creating a new version from the latest or a specified base version.

Publish Prompt Template

Publish a PromptLayer registry prompt template and a new version of its chat or completion content.

Query Request Analytics

Read custom aggregate analytics over PromptLayer request logs.

Query Trace Analytics

Read custom aggregate analytics over PromptLayer traces and spans with recursive filters.

Recalculate Table Cell

Trigger recalculation for one PromptLayer Table cell.

Recalculate Table Cells

Trigger recalculation for a batch of PromptLayer Table cells by ID.

Recalculate Table Sheet Score

Queue recalculation of an existing PromptLayer Table sheet score configuration.

Recalculate Table Sheet Scorecard

Queue recalculation of an existing PromptLayer table sheet scorecard, optionally limited to row indices and step UUIDs.

Render Prompt Template

Retrieve a prompt template by name or ID and render provider-ready llm_kwargs with input_variables using POST.

Resolve Folder ID

Resolve a PromptLayer folder's ID from its dot-separated folder path within a specified workspace.

Run Workflow

Start an execution of a PromptLayer workflow by name, using its latest version or one specified label or version number.

Save Skill Collection Version

Create a new saved version of a PromptLayer skill collection by UUID, name, or root path.

Search Request Logs

Search PromptLayer request logs by text or structured filters and return one rate-limited page sorted by operational fields.

Test Execute Registered Tool

Execute a PromptLayer registered tool's code in its sandbox by ID or name, optionally selecting a version or label and testing unsaved code or a tool definition.

Track Group

Associate an existing PromptLayer request log with an existing group using their integer IDs.

Track Metadata

Associate custom metadata with an existing PromptLayer request log using its request ID.

Track Prompt

Associate an existing PromptLayer request log with a named prompt template, optionally specifying its version or release label and the variables used to render it.

Track Score

Record a score from 0 to 100 on an existing PromptLayer request log.

Update Folder

Rename an existing PromptLayer folder by ID.

Update Registered Tool Environment Variable

Replace the stored value of an existing PromptLayer registered tool environment variable by tool ID or name and variable ID.

Update Skill Collection

Rename a PromptLayer skill collection identified by UUID, name, or root path.

Update Table

Update a PromptLayer Table's title or folder by UUID.

Update Table Cell

Edit the display value or structured value of a PromptLayer table cell.

Update Table Column

Update a PromptLayer Table sheet column's title, configuration, or dependencies.

Update Table Sheet

Update a PromptLayer Table sheet's title or zero-based display position.

Update Workspace Environment Variable

Replace the stored value of an existing PromptLayer workspace environment variable by ID.

Upsert Prompt Template by External ID

Create or update a PromptLayer registry prompt template identified by an external source and ID.

FAQ

Frequently asked questions

Start with PromptLayer.It takes 30 seconds.

Managed auth, hosted MCP servers, and every PromptLayer tool your agent needs.Free to start.

Start building