Introduction
In this article, I will show you how to create a custom connector inside the power platform from scratch. Custom connectors help us to create our own connectors for any web API that has a REST/API. We can create triggers and actions based on our requirements and it’s reusable.
Prerequisites
We need any Web API currently I am using Holiday web API which is free for developer
Steps to create a custom connector
Step 1
Open your power automate.
Step 2
From the left navigation panel expands the Data menu and select Custom connectors.
![custom connector inside the power platform]()
Step 3
Expand New custom connector and select Create from blank.
![custom connector inside the power platform]()
Step 4
Add the connector name in the below box and do click on the Continue button.
![custom connector inside the power platform]()
Step 5
When you click on the continue button you will be redirected to another screen as below
.![custom connector inside the power platform]()
Inside the custom connector, we have 5 different stages or menus so let’s start with the first one.
Step 6
Let’s start with the General tab. In this tab you can upload your logo, you can set your Icon background color, can describe your connector then you need to select Scheme and Host as below image
![custom connector inside the power platform]()
Name |
Value |
Icon background color |
#007ee5 |
Description |
any text |
Scheme |
HTTPS |
Host |
As per your API (I have selected holiday API) |
Step 7
Click on Create connector
![custom connector inside the power platform]()
Step 8
Select the Security tab
![custom connector inside the power platform]()
Step 9
Select the Edit button from Authentication type.
![custom connector inside the power platform]()
Step 10
Select Authentication type from the drop-down, I am selecting API Key as per web API.
![custom connector inside the power platform]()
Step 11
Add details in the below dialog box
![custom connector inside the power platform]()
Name |
Value |
Parameter label |
API Key |
Parameter name |
key (label name is the same as your query parameter in WEB API) |
Parameter location |
Query |
Step 12
Click on the Update Connector button.
![custom connector inside the power platform]()
Step 13
Select the Definition tab
![custom connector inside the power platform]()
Step 14
Select the New Action button as below screen.
![custom connector inside the power platform]()
Step 15
Enter details in the General box
![custom connector inside the power platform]()
Name |
Value |
Summary |
You can enter as you want |
Description |
As per your requirement |
Operation ID |
Holiday(Is a unique string) |
Visibility |
None |
Step 16
Select Import from a sample from Request.
![custom connector inside the power platform]()
Step 17
New side panel will open and the inside panel and add value.
Select the GET method and past your web API URL and click on Import.
![custom connector inside the power platform]()
Step 18
When you click on the import button below the three-parameter, are added to the request section
![custom connector inside the power platform]()
Step 19
Expand Key Parameter and Delete the Key parameter because we have already added a key to our security section
![custom connector inside the power platform]()
Step 20
Select country Parmenter and select edit button
![custom connector inside the power platform]()
Step 21
You can pass the summary description and required fields
![custom connector inside the power platform]()
Step 22
Close the parameter section and go to response section and click on Add default response button
![custom connector inside the power platform]()
Step 23
Below panel will open inside the body pass sample JSON for response and click on import
![custom connector inside the power platform]()
Step 24
Now your definition section is done click on the 5 Test tab for testing our custom connector
![custom connector inside the power platform]()
Step 25
Click on the New connection button
![custom connector inside the power platform]()
Step 26
New windows will be open inside this past your API key and click on create a connection
![custom connector inside the power platform]()
Step 27
Once you click on the connection your windows will be closed and from test, tab click on the refresh button
![custom connector inside the power platform]()
Step 28
Once you click on the refresh button new connection, will be added to the connection section
![custom connector inside the power platform]()
Step 29
Inside the desperation pass your county and year and click on the Test operation button
![custom connector inside the power platform]()
Output
You will get your result in the body inside Response section
![custom connector inside the power platform]()
Conclusion
This is how we can easily create custom connectors and we test custom connector