Can't implement OAuth for Samsung SmartThings Cloud-To-Cloud integration





.everyoneloves__top-leaderboard:empty,.everyoneloves__mid-leaderboard:empty,.everyoneloves__bot-mid-leaderboard:empty{ height:90px;width:728px;box-sizing:border-box;
}







0















I am developing a solution for a product and trying to implement C2C connection. I am in stuck with linking SmartThings with my backend via OAuth.



I get request



{
"lifecycle": "CONFIGURATION",
"executionId": "41d224ba-7de3-77ac-fe87-a56fa6f325c3",
"locale": "en",
"version": "0.1.0",
"client": {
"os": "ios",
"version": "1.6.17",
"language": "uk"
},
"configurationData": {
"installedAppId": "7393625f-64d5-42cb-a52f-7935a677c4bb",
"phase": "PAGE",
"pageId": "linkPage",
"previousPageId": "",
"config": {}
},
"settings": {}
}


And return response, that is rendered in SmartThings App:



{ 
"configurationData": {
"page": {
"pageId": "linkPage",
"nextPageId": "",
"previousPageId": "",
"complete": true,
"name": "Account Linking",
"sections": [ {
"name": "Please, link SmartThings to your XXXXXX account",
"settings": [ {
"id": "linkAccount",
"name": "Link Account",
"type": "OAUTH",
"required": true,
"urlTemplate": "https://xxxxxx.auth.us-east-2.amazoncognito.com/login?response_type=code&client_id=20kucf9dcg5ju9deqeppugqft1&state=7393625f-64d5-42cb-a52f-7935a677c4bb&redirect_uri=https%3A%2F%2Fapi.smartthings.com%2Foauth%2Fcallback"
} ]
} ]
}
}
}


Authentication passes successfully and returns code to callback like that:
https://api.smartthings.com/oauth/callback?code=9dfea1ca-54e8-47e8-ba90-24f20068ad2b&state=7393625f-64d5-42cb-a52f-7935a677c4bb



But the callback returns HTTP 401.



I've read this topic https://community.smartthings.com/t/cloud-to-cloud-oauth-rest-api/118902 and did not find a solution. No more helpful info I could found on the Web.



Has anybody implemented this with success?



The Support is awful - no response for several days.. From my previous Support contacting experience - they can respond after several weeks...



Thank you!










share|improve this question





























    0















    I am developing a solution for a product and trying to implement C2C connection. I am in stuck with linking SmartThings with my backend via OAuth.



    I get request



    {
    "lifecycle": "CONFIGURATION",
    "executionId": "41d224ba-7de3-77ac-fe87-a56fa6f325c3",
    "locale": "en",
    "version": "0.1.0",
    "client": {
    "os": "ios",
    "version": "1.6.17",
    "language": "uk"
    },
    "configurationData": {
    "installedAppId": "7393625f-64d5-42cb-a52f-7935a677c4bb",
    "phase": "PAGE",
    "pageId": "linkPage",
    "previousPageId": "",
    "config": {}
    },
    "settings": {}
    }


    And return response, that is rendered in SmartThings App:



    { 
    "configurationData": {
    "page": {
    "pageId": "linkPage",
    "nextPageId": "",
    "previousPageId": "",
    "complete": true,
    "name": "Account Linking",
    "sections": [ {
    "name": "Please, link SmartThings to your XXXXXX account",
    "settings": [ {
    "id": "linkAccount",
    "name": "Link Account",
    "type": "OAUTH",
    "required": true,
    "urlTemplate": "https://xxxxxx.auth.us-east-2.amazoncognito.com/login?response_type=code&client_id=20kucf9dcg5ju9deqeppugqft1&state=7393625f-64d5-42cb-a52f-7935a677c4bb&redirect_uri=https%3A%2F%2Fapi.smartthings.com%2Foauth%2Fcallback"
    } ]
    } ]
    }
    }
    }


    Authentication passes successfully and returns code to callback like that:
    https://api.smartthings.com/oauth/callback?code=9dfea1ca-54e8-47e8-ba90-24f20068ad2b&state=7393625f-64d5-42cb-a52f-7935a677c4bb



    But the callback returns HTTP 401.



    I've read this topic https://community.smartthings.com/t/cloud-to-cloud-oauth-rest-api/118902 and did not find a solution. No more helpful info I could found on the Web.



    Has anybody implemented this with success?



    The Support is awful - no response for several days.. From my previous Support contacting experience - they can respond after several weeks...



    Thank you!










    share|improve this question

























      0












      0








      0








      I am developing a solution for a product and trying to implement C2C connection. I am in stuck with linking SmartThings with my backend via OAuth.



      I get request



      {
      "lifecycle": "CONFIGURATION",
      "executionId": "41d224ba-7de3-77ac-fe87-a56fa6f325c3",
      "locale": "en",
      "version": "0.1.0",
      "client": {
      "os": "ios",
      "version": "1.6.17",
      "language": "uk"
      },
      "configurationData": {
      "installedAppId": "7393625f-64d5-42cb-a52f-7935a677c4bb",
      "phase": "PAGE",
      "pageId": "linkPage",
      "previousPageId": "",
      "config": {}
      },
      "settings": {}
      }


      And return response, that is rendered in SmartThings App:



      { 
      "configurationData": {
      "page": {
      "pageId": "linkPage",
      "nextPageId": "",
      "previousPageId": "",
      "complete": true,
      "name": "Account Linking",
      "sections": [ {
      "name": "Please, link SmartThings to your XXXXXX account",
      "settings": [ {
      "id": "linkAccount",
      "name": "Link Account",
      "type": "OAUTH",
      "required": true,
      "urlTemplate": "https://xxxxxx.auth.us-east-2.amazoncognito.com/login?response_type=code&client_id=20kucf9dcg5ju9deqeppugqft1&state=7393625f-64d5-42cb-a52f-7935a677c4bb&redirect_uri=https%3A%2F%2Fapi.smartthings.com%2Foauth%2Fcallback"
      } ]
      } ]
      }
      }
      }


      Authentication passes successfully and returns code to callback like that:
      https://api.smartthings.com/oauth/callback?code=9dfea1ca-54e8-47e8-ba90-24f20068ad2b&state=7393625f-64d5-42cb-a52f-7935a677c4bb



      But the callback returns HTTP 401.



      I've read this topic https://community.smartthings.com/t/cloud-to-cloud-oauth-rest-api/118902 and did not find a solution. No more helpful info I could found on the Web.



      Has anybody implemented this with success?



      The Support is awful - no response for several days.. From my previous Support contacting experience - they can respond after several weeks...



      Thank you!










      share|improve this question














      I am developing a solution for a product and trying to implement C2C connection. I am in stuck with linking SmartThings with my backend via OAuth.



      I get request



      {
      "lifecycle": "CONFIGURATION",
      "executionId": "41d224ba-7de3-77ac-fe87-a56fa6f325c3",
      "locale": "en",
      "version": "0.1.0",
      "client": {
      "os": "ios",
      "version": "1.6.17",
      "language": "uk"
      },
      "configurationData": {
      "installedAppId": "7393625f-64d5-42cb-a52f-7935a677c4bb",
      "phase": "PAGE",
      "pageId": "linkPage",
      "previousPageId": "",
      "config": {}
      },
      "settings": {}
      }


      And return response, that is rendered in SmartThings App:



      { 
      "configurationData": {
      "page": {
      "pageId": "linkPage",
      "nextPageId": "",
      "previousPageId": "",
      "complete": true,
      "name": "Account Linking",
      "sections": [ {
      "name": "Please, link SmartThings to your XXXXXX account",
      "settings": [ {
      "id": "linkAccount",
      "name": "Link Account",
      "type": "OAUTH",
      "required": true,
      "urlTemplate": "https://xxxxxx.auth.us-east-2.amazoncognito.com/login?response_type=code&client_id=20kucf9dcg5ju9deqeppugqft1&state=7393625f-64d5-42cb-a52f-7935a677c4bb&redirect_uri=https%3A%2F%2Fapi.smartthings.com%2Foauth%2Fcallback"
      } ]
      } ]
      }
      }
      }


      Authentication passes successfully and returns code to callback like that:
      https://api.smartthings.com/oauth/callback?code=9dfea1ca-54e8-47e8-ba90-24f20068ad2b&state=7393625f-64d5-42cb-a52f-7935a677c4bb



      But the callback returns HTTP 401.



      I've read this topic https://community.smartthings.com/t/cloud-to-cloud-oauth-rest-api/118902 and did not find a solution. No more helpful info I could found on the Web.



      Has anybody implemented this with success?



      The Support is awful - no response for several days.. From my previous Support contacting experience - they can respond after several weeks...



      Thank you!







      oauth smartthings






      share|improve this question













      share|improve this question











      share|improve this question




      share|improve this question










      asked Nov 23 '18 at 14:13









      atlascoderatlascoder

      8121022




      8121022
























          1 Answer
          1






          active

          oldest

          votes


















          0














          This is a bug of iOS SmartThings application, Android works fine.
          https://community.smartthings.com/t/cant-implement-oauth-for-cloud-to-cloud/143258/7






          share|improve this answer
























            Your Answer






            StackExchange.ifUsing("editor", function () {
            StackExchange.using("externalEditor", function () {
            StackExchange.using("snippets", function () {
            StackExchange.snippets.init();
            });
            });
            }, "code-snippets");

            StackExchange.ready(function() {
            var channelOptions = {
            tags: "".split(" "),
            id: "1"
            };
            initTagRenderer("".split(" "), "".split(" "), channelOptions);

            StackExchange.using("externalEditor", function() {
            // Have to fire editor after snippets, if snippets enabled
            if (StackExchange.settings.snippets.snippetsEnabled) {
            StackExchange.using("snippets", function() {
            createEditor();
            });
            }
            else {
            createEditor();
            }
            });

            function createEditor() {
            StackExchange.prepareEditor({
            heartbeatType: 'answer',
            autoActivateHeartbeat: false,
            convertImagesToLinks: true,
            noModals: true,
            showLowRepImageUploadWarning: true,
            reputationToPostImages: 10,
            bindNavPrevention: true,
            postfix: "",
            imageUploader: {
            brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
            contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
            allowUrls: true
            },
            onDemand: true,
            discardSelector: ".discard-answer"
            ,immediatelyShowMarkdownHelp:true
            });


            }
            });














            draft saved

            draft discarded


















            StackExchange.ready(
            function () {
            StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f53448264%2fcant-implement-oauth-for-samsung-smartthings-cloud-to-cloud-integration%23new-answer', 'question_page');
            }
            );

            Post as a guest















            Required, but never shown

























            1 Answer
            1






            active

            oldest

            votes








            1 Answer
            1






            active

            oldest

            votes









            active

            oldest

            votes






            active

            oldest

            votes









            0














            This is a bug of iOS SmartThings application, Android works fine.
            https://community.smartthings.com/t/cant-implement-oauth-for-cloud-to-cloud/143258/7






            share|improve this answer




























              0














              This is a bug of iOS SmartThings application, Android works fine.
              https://community.smartthings.com/t/cant-implement-oauth-for-cloud-to-cloud/143258/7






              share|improve this answer


























                0












                0








                0







                This is a bug of iOS SmartThings application, Android works fine.
                https://community.smartthings.com/t/cant-implement-oauth-for-cloud-to-cloud/143258/7






                share|improve this answer













                This is a bug of iOS SmartThings application, Android works fine.
                https://community.smartthings.com/t/cant-implement-oauth-for-cloud-to-cloud/143258/7







                share|improve this answer












                share|improve this answer



                share|improve this answer










                answered Dec 16 '18 at 9:43









                atlascoderatlascoder

                8121022




                8121022
































                    draft saved

                    draft discarded




















































                    Thanks for contributing an answer to Stack Overflow!


                    • Please be sure to answer the question. Provide details and share your research!

                    But avoid



                    • Asking for help, clarification, or responding to other answers.

                    • Making statements based on opinion; back them up with references or personal experience.


                    To learn more, see our tips on writing great answers.




                    draft saved


                    draft discarded














                    StackExchange.ready(
                    function () {
                    StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f53448264%2fcant-implement-oauth-for-samsung-smartthings-cloud-to-cloud-integration%23new-answer', 'question_page');
                    }
                    );

                    Post as a guest















                    Required, but never shown





















































                    Required, but never shown














                    Required, but never shown












                    Required, but never shown







                    Required, but never shown

































                    Required, but never shown














                    Required, but never shown












                    Required, but never shown







                    Required, but never shown







                    這個網誌中的熱門文章

                    Tangent Lines Diagram Along Smooth Curve

                    Yusuf al-Mu'taman ibn Hud

                    Zucchini