cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
sandeepnmenon
Microsoft
Microsoft

Set an 'expression' as default field in action of custom connector

Scenario:

I want to pass the current time as default parameter in one of the fields of an action of my custom connector.

 

My approach:

In my swagger definition, I have the field defined as

                "startdate": {
                  "type": "string",
                  "description": "Start Date",
                  "title": "Start Date",
                  "x-ms-visibility": "",
                  "default": "utcNow()"
                }

But when I use the action in a flow, the field is shown as

Capture.PNG

When the flow runs, it does not take in the expression value.

 

This is not read as an expression as opposed to when it is added manually by me, where it is displayed as

Capture.PNG

 

 

What change should I make to put expressions as default values.

 

Thanks

Thanks

1 ACCEPTED SOLUTION

Accepted Solutions
sandeepnmenon
Microsoft
Microsoft

Expressions should be enclosed under @{}

As given below

               "startdate": {
                  "type": "string",
                  "description": "Start Date",
                  "title": "Start Date",
                  "x-ms-visibility": "",
                  "default": "@{utcNow()}"
                }

View solution in original post

1 REPLY 1
sandeepnmenon
Microsoft
Microsoft

Expressions should be enclosed under @{}

As given below

               "startdate": {
                  "type": "string",
                  "description": "Start Date",
                  "title": "Start Date",
                  "x-ms-visibility": "",
                  "default": "@{utcNow()}"
                }

Helpful resources

Announcements
Power Platform Conf 2022 768x460.jpg

Join us for Microsoft Power Platform Conference

The first Microsoft-sponsored Power Platform Conference is coming in September. 100+ speakers, 150+ sessions, and what's new and next for Power Platform.

May UG Leader Call Carousel 768x460.png

June User Group Leader Call

Join us on June 28 for our monthly User Group leader call!

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 Designer Feedback_carousel.jpg

Help make Flow Design easier

Are you new to designing flows? What is your biggest struggle with Power Automate Designer? Help us make it more user friendly!

Users online (2,252)