'AWS App Sync Subscriptions over MQTT is not supported

While using AWS AppSync SDK to add subscription its returning this error, but I got the result in AWS console.

errorType: "BadRequestException"
message: "Subscriptions over MQTT is not supported."

I have seen this similar question and tried the answers that doesn't worked for me. Is there any way to solve this error? looking forward to the suggestions Thank you



Solution 1:[1]

This happens due to de deprecation of MQTT

So instead of configuring createSubscriptionHandshakeLink as createSubscriptionHandshakeLink(url, httpLink) you must use createSubscriptionHandshakeLink({ url, region, auth }) or it will result to using MQTT

ref: https://github.com/awslabs/aws-mobile-appsync-sdk-js/issues/628

Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source
Solution 1 David Giraldo