cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Syndicate_Admin
Administrator
Administrator

Multiple Custom Connector Issues

I have created a postman collection that contains two api calls, and via postman, I have them working appropriately. 

 

However I am struggling to apply the headers, the value for the headers, and the raw body, into the custom connector without it requesting that information later on. its never going to change. I don't want to put it every time. 
This is what I have so far: 
The request:

AlaskanPowrUser_1-1629685142515.png

Within those headers, and that body, i have edited them. I have marked them all as required. I have also supplied default values, which is what i want the value of those headers to be. 

When i reach my "Test" portion, I EXPECT this to WORK: 

AlaskanPowrUser_2-1629685229933.png

However, it does not work. you see the 401. I MUST fill in the values for the headers ,and the body, even though i set default values. 

AlaskanPowrUser_3-1629685423399.png

You can see I now successfully receive a 200 response. there is a value in the body I need to retrieve inside of powerapps. But inside powerapps, when I use this custom connector, I expect to be able to Set(varCustomConnectorResponse,CustomConnector.Action()) and retrieve the response value inside of varCustomConnectorResponse

INSTEAD, Powerapps looks like this:

AlaskanPowrUser_4-1629685703556.png

 

It is very much expecting me to supply those fields. 
okay, whatever. I'll hard-code the fields inside my app, right? 

AlaskanPowrUser_5-1629685991919.png

WRONGO! You can see me setting a variable (this is onclick a button btw) to the response of my api call. You can see my error. and instead of the nice detailed messages i get when testing my custom connector, I get "There was an error" inside the powerapp. How useless lol 😞 

WHAT AM I DOING WRONG?! 😞 I've been trying this for 10 hours today. I'm stumped. I feel like im SO CLOSE! 



 

1 REPLY 1
murshed
Microsoft
Microsoft

What kind of auth are you using? Consider defining an auth type instead of hardcoding the value. Also checkout this policy template: https://docs.microsoft.com/en-us/connectors/custom-connectors/policy-templates/setheader/setheader

If this reply answers your question or solves your issue, please ACCEPT AS SOLUTION ☑️. If you find this reply helpful, please consider giving it a LIKE 👍.

Helpful resources

Announcements
MPA Virtual Workshop Carousel 768x460.png

Register for a Free Workshop

Learn to digitize and optimize business processes and connect all your applications to share data in real time.

Power automate tips 768x460 v2.png

Restore a Deleted Flow

Did you know that you could restore a deleted flow? Check out this helpful article.

Microsoft Build 768x460.png

Microsoft Build is May 24-26. Have you registered yet?

Come together to explore latest innovations in code and application development—and gain insights from experts from around the world.

May UG Leader Call Carousel 768x460.png

What difference can a User Group make for you?

At the monthly call, connect with other leaders and find out how community makes your experience even better.

Top Solution Authors
Users online (2,832)