How to Enable and Test External Credentials in Salesforce

Table of Contents

Salesforce’s new External Credentials model is a critical part of integration security moving forward, especially after the changes rolled out in Salesforce Summer ’25.  

Instead of embedding sensitive tokens or hardcoding values in Apex, you can now securely authorize callouts using External Credentials, Principals, and Named Credentials, with better control and auditing. 

In this guide, we’ll walk you through the step-by-step setup of External Credentials and Named Credentials with No Authentication and test the integration using the Developer Console.  

This is ideal for devs and architects who want secure, flexible callouts to external APIs usingSalesforce’s updated integration security model.

Step-by-Step Guide to Set Up External Credentials in Salesforce

Step 1: Create a New External Credential 

  1. Go to Setup 
  2. In the Quick Find box, search for Named Credentials 
  3. Click on the External Credentials tab 
  4. Click “New” 

Now fill out the form: 

  • Label: (Enter a descriptive label, e.g., NewEC) 
  • Name: (Auto-filled or enter as desired, e.g, NewEC) 
  • Authentication Protocol: Select No Authentication 

Click Save

 Step 2: Add a Principal to the External Credential 

Once saved, scroll down to the Principals related list: 

  1. Click “New.” 
  2. Add parameter name. Say, for instance, NewECPrincipal. 
  3. Click Save

Step 3: Create a New Named Credential 

  1. Go back to Named Credentials tab in the same setup screen 
  2. Click “New.” 
  3. Fill in the fields: 
  • Label: (e.g., NewNC) 
  • Name: (e.g., NewNC
  • URL: Enter your API endpoint.  
  • Click the checkbox for Enable for Callouts 
  • Under Authentication, select the External Credential you just created 

Click Save 

 Step 4: Enable Principal Access for Your Profile 

  1. Go to Setup → Profiles 
  2. Select the profile of the user making the callout, say System Administrator 
  3. Scroll down and click on “Enabled External Credential Principal Access.” 
  4. Click Edit 
  5. In the Available list, locate the External Credential → Principal pair you created 
  6. Move it to the Enabled list 
  7. Click Save 

This allows the user profile to use the Named Credential. 

 Step 5: Test the Named Credential in Developer Console 

  1. Go to the Developer Console 
  2. Open Debug → Open Execute Anonymous Window 
  3. Paste the following code: 

HttpRequest req = new HttpRequest();
    req.setEndpoint(‘callout:New_NC’); // Named Credential
    req.setMethod(‘GET’);
    Http http = new Http();
    HttpResponse res = http.send(req); 

System.debug(res.getStatusCode()); 

Note: Replace ‘Your_Named_Credential_Name’ with the actual Name (not Label) of the Named Credential you created. 

  1. Run the code 
  2. Go to Debug Logs → View Last Log 

Congratulations! Everything is configured properly. You’ll now see a response from the external API.

What’s there in Salesforce Summer ’25 Changes 

The Salesforce Summer ’25 features introduced more secure, granular controls for integrations via External Credentials and Principal Mapping. It’s now considered best practice over storing tokens in custom metadata or code. 

External Credentials in Salesforce let you manage integrations with different auth methods (including “No Authentication”) while ensuring you only expose access to trusted profiles or permission sets. 

Conclusion 

This guide shows you exactly how to set up and test External Credentials and Named Credentials in Salesforce the right way using the updated Summer ’25 features. It’s a cleaner, safer way to manage integrations and avoids the mess of hardcoded tokens. 

Want to customize this solution for your org? Or need help implementing it across multiple integrations?
Reach out today, and let’s get it done right!

Tags: #External Credentials in Salesforce, #Salesforce Summer ’25 features

Featured Reads

Meet Mr. Sync

Meet Mr. Sync: The Wolf Who Leads Synexc’s Pack into the Future of CRM

give a video where there is a man wiht the

Colors, Culture & Blessings

When Lord Ganesha Came to Synexc: A Day of Colors, Culture and Blessings

“Where there is devotion, there is joy. Where there is

Colors, Conversations, and Connections: How Synexc Celebrated Friendship Day with Heart

“Friendship is the golden thread that ties the heart of

What Really Shapes Company Culture: Performance Review or Fun Fridays?

The culture in corporate usually associates itself with big moments,

Salesforce Appexchange

The New AppExchange Security Review: How to Protect Data and Pass in 2025

Should you worry about Salesforce security in 2025? Amidst the

Custom App on Salesforce AppExchange

Top Benefits of Building a Custom App on Salesforce AppExchange

Most businesses start using Salesforce with the basics, such as

Salesforce AppExchange Development Services: What You Need to Know and How to choose the right partner

Explore the full process of custom Salesforce app development for

Salesforce Integration

Salesforce Integration Best Practices to Prevent Data Breaches

Companies invest in Salesforce integration services with a simple goal

Salesforce Support Services

Why Businesses Struggle Without Managed Salesforce Support Services

Salesforce is powerful. No debate there. But here is the

implement Salesforce CRM

The Role of a Salesforce CRM Implementation Consultant in Digital Transformation

Around the world, the process of going digital underwent a

Salesforce Winter

Salesforce Winter 26 Release: Key Enhancements To Watch

While Summer ’25 is still fresh, it’s time to shift

Salesforce Consulting Services: How to Find the Right Consultants on AppExchange

Finding the right Salesforce consultant on AppExchange starts with asking

Why Hiring a Salesforce CRM Implementation Consultant Is Critical to Your CRM Success

Hiring a Salesforce CRM implementation consultant ensures you avoid costly

IT Staff Augmentation Services: The Smarter Way to Scale Tech Teams

IT Staff augmentation isn’t just about filling gaps; it’s about

Agentforce for Smarter

How to Add Web Search to Agentforce for Smarter AI Responses

Agentforce is already powerful at automating tasks and answering queries

Prompt Builder vs Apex in Salesforce Summer 25: What to Use for AI Automation

Salesforce Summer ’25 Release brings significant improvements across the platform,

How to Enable and Test External Credentials in Salesforce

Salesforce’s new External Credentials model is a critical part of

How to Auto-Generate Meeting Summaries Natively in Salesforce with Apex and Flow

Meetings are important, but what’s even more important is what

Want More Than Just Reading?

Talk to our consultants about how we can 
implement what you just read.