Hello all,
First of all thanks for assisting, this is driving me insane 🙂
I have a custom connector created. (See attached Swagger file)
It is quite easy, a few vehicle details, like this
{ "data": [ { "id": "8618535", "stocknummer": "8618535-AWD", "kenteken": "53RKJG", "dealer_id": "131384", "externnummer": "", "benamingopinternet": "Nissan Micra 1.2 e-Vision", "photocount": 2, "vin": "SJNFBAK12U1429378", "photolastupdate": 1557945424 } ] }
See the correct response definition
When I test it gives me the correct information back (same as Powershell and Postman)
When I search on a license plate, I get the information back to the collection
I use a collect for now (ClearCollect later)
https://docs.microsoft.com/en-us/powerapps/maker/canvas-apps/create-update-collection
However it returns not all the fields (Yes I know, I clicked twice)
Initially I thought it was due to integers or strings not matching but the schema validation on the connector itself passed.
I already tried a lot of settings, no luck.
Any! suggestions whatsoever are appreciated (also that I maybe must use a different connector)
Kind regards,
John
Solved! Go to Solution.
Hi John,
I would double check that the field names in your definition match the field names in your response. For example, the definition includes the field dealer_id (with an underscore).
The response includes "dealerid" (without an underscore).
I'm also guessing that "benamingopinternet" should be "nameoninternet".
This should hopefully go someway towards helping you resolve this problem.
Hi @jbruijntjes ,
Based on the Response screenshot that you provided, I think there is something wrong with the Response Body payload you typed within your custom connector.
I agree with @timl 's thought almost, the result your Test Operation returned does not match the properties you specified within the Response Body payload in your custom connector. E.g. within Test Operation result, it has dealerid property, but you specify dealer_id property within the Response Body payload in your custom connector.
On your side, please make sure the result the Request action returns must match the properties you specified within the Response Body payload in your custom connector. On your side, you could consider test your Request using Postman, and copy the Response Body data, then paste that into the Response Body payload in your custom connector.
I have made a test on my side, please consider type the following data schema within the Response Body payload:
{ "data": [ { "id": "8618535", "stocknumber": "8618535-AWD", "licenseplate": "53RKJG", "dealerid": "131384", "externalnumber": "", "nameoninternet": "Nissan Micra 1.2 e-Vision", "photocount": 2, "vin": "SJNFBAK12U1429378", "photolastupdate": 1557945424 } ] }
On your side, please go to the Response part of the action, then click "Import from sample", then set the Body field to above Response Body payload.
Please take a try with above solution, then check if the issue is solved.
Best regards,
Hi John,
I would double check that the field names in your definition match the field names in your response. For example, the definition includes the field dealer_id (with an underscore).
The response includes "dealerid" (without an underscore).
I'm also guessing that "benamingopinternet" should be "nameoninternet".
This should hopefully go someway towards helping you resolve this problem.
Hi @jbruijntjes ,
Based on the Response screenshot that you provided, I think there is something wrong with the Response Body payload you typed within your custom connector.
I agree with @timl 's thought almost, the result your Test Operation returned does not match the properties you specified within the Response Body payload in your custom connector. E.g. within Test Operation result, it has dealerid property, but you specify dealer_id property within the Response Body payload in your custom connector.
On your side, please make sure the result the Request action returns must match the properties you specified within the Response Body payload in your custom connector. On your side, you could consider test your Request using Postman, and copy the Response Body data, then paste that into the Response Body payload in your custom connector.
I have made a test on my side, please consider type the following data schema within the Response Body payload:
{ "data": [ { "id": "8618535", "stocknumber": "8618535-AWD", "licenseplate": "53RKJG", "dealerid": "131384", "externalnumber": "", "nameoninternet": "Nissan Micra 1.2 e-Vision", "photocount": 2, "vin": "SJNFBAK12U1429378", "photolastupdate": 1557945424 } ] }
On your side, please go to the Response part of the action, then click "Import from sample", then set the Body field to above Response Body payload.
Please take a try with above solution, then check if the issue is solved.
Best regards,
YES! That was the solution, I was totally blind to it!! Thanks a million! Saved my day.
One thing what I do not get is that my Postman gives a complete different result, you know why.
Hi @jbruijntjes ,
Is the solution I provided above helpful?
If the solution I provided above is helpful, please consider go ahead to click "Accpet as Solution" to identify my Solution as Solved.
In addition, when you test your API within PowerApps, PowerApps may convert your local language (e.g. kenteken => license Plate) into english automatically. So please consider define the properties within your API using english language.
Best regards,
Yes this is the solution.
Thanks for pointing out the auto translation! I now get it!
However it is very strange that it translates dealer_id to dealerid....:S
John
Hi @v-xida-msft
Can you explain how PowerApps would automatically convert something like kenteken into license Plate? How is this possible?
When you call a third party API, you don't really have any control over the property names. Therefore, converting defining everything in English isn't viable in a lot of cases.
Still curious why the translation is happening...
This training provides practical hands-on experience in creating Power Apps solutions in a full-day of instructor-led App creation workshop.
Come together to explore latest innovations in code and application development—and gain insights from experts from around the world.
User | Count |
---|---|
192 | |
67 | |
46 | |
41 | |
22 |
User | Count |
---|---|
252 | |
122 | |
84 | |
80 | |
71 |