Skip to main content
Glama
semwalajay83-sem

salesforce-metadata-mcp

Create Named Credential

sf_create_named_credential
Idempotent

Create a named credential to securely store endpoint and authentication details for callouts from Apex or Flows, preventing hardcoded credentials.

Instructions

Creates a Named Credential for making authenticated callouts to external systems from Apex or Flows. Named Credentials store the endpoint URL and authentication details securely, so developers don't hardcode credentials. Supports NoAuthentication, Basic (username/password), OAuth, and more. Use with sf_create_remote_site_setting to also allow the URL.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
labelYesDisplay label
endpointYesEndpoint URL, e.g. 'https://api.example.com'
fullNameYesNamed credential API name, e.g. 'My_External_API'
passwordNoPassword for Password protocol (encrypted at rest)
protocolNoAuthentication protocolNoAuthentication
usernameNoUsername for Password protocol
allowCalloutNoAllow callouts using this credential
allowFormulaNoAllow formulas in HTTP body (enables merge fields)
principalTypeNoNamedUser: shared credentials. PerUserPrincipal: per-user OAuth. Anonymous: no auth.NamedUser
Behavior4/5

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

Annotations already indicate non-read-only, non-destructive, open-world, and idempotent behavior. The description adds meaningful context by stating that credentials are stored securely, listing supported auth protocols, and hinting at the companion remote site setting. It does not contradict the annotations, and it adds value beyond the structured hints.

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

Conciseness5/5

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

The description is three sentences long and front-loaded with the primary purpose. Every sentence adds value: the first defines the tool, the second explains its security benefit, and the third gives a concrete companion tool. No filler or redundancy.

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

Completeness4/5

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

The description covers the high-level purpose, security model, auth protocols, and companion tool, which is strong for a create operation with a rich schema. However, there is no output schema and the description does not mention what the tool returns (e.g., the created credential's ID), leaving that gap for the agent to discover.

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 description coverage is 100%, so parameters are already fully documented with names, types, enums, and examples. The description adds only a broad mention of protocols ('Basic (username/password), OAuth') which mirrors the schema enum. This is helpful but not essential, so the baseline of 3 is appropriate.

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?

The description states a specific verb and resource: 'Creates a Named Credential for making authenticated callouts to external systems from Apex or Flows.' This clearly distinguishes it from other create tools by focusing on callout authentication and credential storage. It also differentiates from the sibling sf_create_remote_site_setting by explaining the complementary relationship.

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?

The description gives clear context for use: authenticated callouts from Apex or Flows, and explicitly says to pair with sf_create_remote_site_setting to also allow the URL. It does not provide explicit 'when not to use' or contrast with alternatives like sf_create_auth_provider, but the intended use case is clear.

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

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/semwalajay83-sem/salesforce-metadata-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server