Skip to main content
Glama
n8n MCP Server

n8n MCP Server

by r-ms

n8n_create_credential

Creates a new credential in n8n using a name, type, and field data. Fetch the credential schema first to confirm required fields and avoid configuration errors.

Instructions

Create a new credential in n8n. Use n8n_get_credential_schema first to see required fields. On error, auto-fetches the schema as a hint.

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "name": "<name>",
      "type": "<type>",
      "data": "<data>"
    },
    "name": "n8n_create_credential"
  }
}

Input Schema

NameRequiredDescriptionDefault
dataYesCredential data fields (use n8n_get_credential_schema to see required fields)
nameYesDisplay name for the credential
typeYesCredential type (e.g. 'openAiApi', 'mongoDb')

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A3.8/5.0
Behavior3/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

With no annotations, the description carries the full disclosure burden. It usefully adds a non-obvious behavior (on error the tool auto-fetches the schema as a hint), but says nothing about permissions, whether stored secrets are encrypted, or what the response contains after creation.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Three short sentences, front-loaded with the operation and followed immediately by the prerequisite and the error behavior. No filler, though the error-handling note could be folded in more tightly.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness3/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a write tool that stores credentials, no annotations and no output schema, the description omits return values (e.g., created credential ID) and any safety or permission context. The prerequisite and error behavior partially compensate but do not fully cover the complexity.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema coverage is 100%, so the schema already documents name, type, and data. The description adds only the pointer that data's required fields come from n8n_get_credential_schema, which is useful for the nested object but not significantly beyond the schema text.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

States a specific verb and resource ("Create a new credential in n8n") that is clearly distinct from the read-side siblings n8n_get_credential_schema and n8n_list_credentials. An agent can identify the operation without opening the schema.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines4/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

Gives an explicit prerequisite workflow: call n8n_get_credential_schema first to learn required fields. It does not cover what to do when a credential already exists (e.g., an update path) or any exclusions, so it stops short of full when/when-not guidance.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.