cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
ericonline
Level 10

Why a Different Schema for Same Custom Connector?

This is just bizarre. I have a Custom Connector that calls a weather api. Working great in one application. Added the Connector to a different app and duplicated the inputs. No go.

Most curious is the "hint text". WHY IS IT DIFFERENT FOR ONE APP?

Working app hint text:

image.png

Non-working app hint text:

image.png
Working app schema: 

ClearCollect(
    colWeather,
    weatherAPI.GETHistorical(
        {
            apikey:"<redacted>",
            accept:"application/json",
            'Content-Type':"application/json",
            geocode:
                {
                    lon: Location.Longitude,
                    lat: Location.Latitude
                },
            location_id: "",
            start_time: Text(Now() - 1,DateTimeFormat.UTC),
            end_time:  Text(Now(),DateTimeFormat.UTC), 
            timestep:60,
            fields:
                colSelectedParameters
        }
    )
)

Non-working app schema:

ClearCollect(
    colWeather,
    weatherAPI.GETHistorical(
        {
            apikey:"<redacted>",
            accept:"application/json",
            'Content-Type':"application/json",
            geocode:
                {
                    lon: Location.Longitude,
                    lat: Location.Latitude
                },
            location_id: "",
            start_time: Text(Now() - 1,DateTimeFormat.UTC),
            end_time:  Text(Now(),DateTimeFormat.UTC), 
            timestep:60,
            fields:
                colSelectedParameters
        }
    )
) 

Errors:

  • "No parameter." This function has no optional parameter named 'apikey'."
  • When I comment out apikey, the error moves to:
    • "No parameter." This function has no optional parameter named 'endtime'."
    • And so on...

Its like the schema of the Custom Connector is not visible between apps? Whats going on here?

1 ACCEPTED SOLUTION

Accepted Solutions
ericonline
Level 10

Re: Why a Different Schema for Same Custom Connector?

So I bit the bullet and deleted, re-created the Custom Connector... issue fixed.

3 REPLIES 3
Administrator
Administrator

Re: Why a Different Schema for Same Custom Connector?

@ericonline, I'm not familiar with this API, but do you know if its schema changes under different conditions? For instance, in my Twitter API, the schema changes if a given tweet does not have retweets, so it does not have data for the user of the original tweet. 

Highlighted
ericonline
Level 10

Re: Why a Different Schema for Same Custom Connector?

Hi @Mr-Dang-MSFT ,

Thanks for the reply!

  • I'm making only 1 type of call with this API (a call for historical weather data). Its a paid service so I can't share here.
  • Identical POST bodies in both PowerApps, so I think the schema returned should be identical between apps.
  • Using the same Custom Connector in each app.
  • There is only one Request and one Response defined in the Custom Connector. 
  • There is only one Connection to the API shown in Data/Connections

Thoughts on what I do to troubleshoot?

ericonline
Level 10

Re: Why a Different Schema for Same Custom Connector?

So I bit the bullet and deleted, re-created the Custom Connector... issue fixed.