How to Create Token based Router in Magento2?How to acquire access token for an integration in Magento2Error Using HTTPS to get the authentication token for Magento2 RestMagento2 How to set expiration time for tokenMagento 2 token integration errorHow to Manage API Authentication Lifecycle on Mobile Devices? Magento2Magento 2: Get Admin User Details By Token Rest APIMagento 2 : How to programmatically create and display bearer token on admin screen?How to capture the User ID using magento's customer Token?Magento 2 : Rest Api for access customer id with tokenhow to use Magento2 token

Subgroup generated by a subgroup and a conjugate of it

What is the opposite of "hunger level"?

Build a mob of suspiciously happy lenny faces ( ͡° ͜ʖ ͡°)

Why should I pay for an SSL certificate?

What's a good pattern to calculate a variable only when it is used the first time?

Why is su world executable?

Reducing contention in thread-safe LruCache

What was the intention with the Commodore 128?

programming a recursive formula into Mathematica and find the nth position in the sequence

Pocket Clarketech

What happened after the end of the Truman Show?

Polar contour plot in Mathematica?

Is it alright to say good afternoon Sirs and Madams in a panel interview?

How to train a replacement without them knowing?

C++ Least cost swapping 2

Has there ever been a truly bilingual country prior to the contemporary period?

Do I need to start off my book by describing the character's "normal world"?

Output with the same length always

Alignment of different align environment

How should you gracefully leave a company you helped start?

Designing a prison for a telekinetic race

Get file name and directory in .vimrc file

Icon is not displayed in lwc

Have there ever been other TV shows or Films that told a similiar story to the new 90210 show?



How to Create Token based Router in Magento2?


How to acquire access token for an integration in Magento2Error Using HTTPS to get the authentication token for Magento2 RestMagento2 How to set expiration time for tokenMagento 2 token integration errorHow to Manage API Authentication Lifecycle on Mobile Devices? Magento2Magento 2: Get Admin User Details By Token Rest APIMagento 2 : How to programmatically create and display bearer token on admin screen?How to capture the User ID using magento's customer Token?Magento 2 : Rest Api for access customer id with tokenhow to use Magento2 token






.everyoneloves__top-leaderboard:empty,.everyoneloves__mid-leaderboard:empty,.everyoneloves__bot-mid-leaderboard:empty margin-bottom:0;








0















I want to create Custom API through controller action.



How i can authenticate using token to make secure API.



Example:



http://www.example.com/webapiv1/getItems



http://www.example.com/webapiv1/getOrders










share|improve this question
































    0















    I want to create Custom API through controller action.



    How i can authenticate using token to make secure API.



    Example:



    http://www.example.com/webapiv1/getItems



    http://www.example.com/webapiv1/getOrders










    share|improve this question




























      0












      0








      0








      I want to create Custom API through controller action.



      How i can authenticate using token to make secure API.



      Example:



      http://www.example.com/webapiv1/getItems



      http://www.example.com/webapiv1/getOrders










      share|improve this question
















      I want to create Custom API through controller action.



      How i can authenticate using token to make secure API.



      Example:



      http://www.example.com/webapiv1/getItems



      http://www.example.com/webapiv1/getOrders







      magento2 rest-api webapi






      share|improve this question















      share|improve this question













      share|improve this question




      share|improve this question








      edited Aug 6 at 4:54









      Waqar Ali

      61816 bronze badges




      61816 bronze badges










      asked Aug 6 at 4:48









      Chandra KumarChandra Kumar

      3104 silver badges19 bronze badges




      3104 silver badges19 bronze badges























          1 Answer
          1






          active

          oldest

          votes


















          0














          You can use admin token for authentication
          To generate admin token
          a) Url - http://www.example.com/rest/V1/integration/admin/token
          b) Type - POST
          c) Parameters - username, password
          Username - your-admin-username
          Password - your-passord






          share|improve this answer



























            Your Answer








            StackExchange.ready(function()
            var channelOptions =
            tags: "".split(" "),
            id: "479"
            ;
            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: false,
            noModals: true,
            showLowRepImageUploadWarning: true,
            reputationToPostImages: null,
            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%2fmagento.stackexchange.com%2fquestions%2f284503%2fhow-to-create-token-based-router-in-magento2%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














            You can use admin token for authentication
            To generate admin token
            a) Url - http://www.example.com/rest/V1/integration/admin/token
            b) Type - POST
            c) Parameters - username, password
            Username - your-admin-username
            Password - your-passord






            share|improve this answer





























              0














              You can use admin token for authentication
              To generate admin token
              a) Url - http://www.example.com/rest/V1/integration/admin/token
              b) Type - POST
              c) Parameters - username, password
              Username - your-admin-username
              Password - your-passord






              share|improve this answer



























                0












                0








                0







                You can use admin token for authentication
                To generate admin token
                a) Url - http://www.example.com/rest/V1/integration/admin/token
                b) Type - POST
                c) Parameters - username, password
                Username - your-admin-username
                Password - your-passord






                share|improve this answer













                You can use admin token for authentication
                To generate admin token
                a) Url - http://www.example.com/rest/V1/integration/admin/token
                b) Type - POST
                c) Parameters - username, password
                Username - your-admin-username
                Password - your-passord







                share|improve this answer












                share|improve this answer



                share|improve this answer










                answered Aug 7 at 6:02









                vartika sharmavartika sharma

                336 bronze badges




                336 bronze badges






























                    draft saved

                    draft discarded
















































                    Thanks for contributing an answer to Magento Stack Exchange!


                    • 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%2fmagento.stackexchange.com%2fquestions%2f284503%2fhow-to-create-token-based-router-in-magento2%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







                    Popular posts from this blog

                    Category:9 (number) SubcategoriesMedia in category "9 (number)"Navigation menuUpload mediaGND ID: 4485639-8Library of Congress authority ID: sh85091979ReasonatorScholiaStatistics

                    Circuit construction for execution of conditional statements using least significant bitHow are two different registers being used as “control”?How exactly is the stated composite state of the two registers being produced using the $R_zz$ controlled rotations?Efficiently performing controlled rotations in HHLWould this quantum algorithm implementation work?How to prepare a superposed states of odd integers from $1$ to $sqrtN$?Why is this implementation of the order finding algorithm not working?Circuit construction for Hamiltonian simulationHow can I invert the least significant bit of a certain term of a superposed state?Implementing an oracleImplementing a controlled sum operation

                    Magento 2 “No Payment Methods” in Admin New OrderHow to integrate Paypal Express Checkout with the Magento APIMagento 1.5 - Sales > Order > edit order and shipping methods disappearAuto Invoice Check/Money Order Payment methodAdd more simple payment methods?Shipping methods not showingWhat should I do to change payment methods if changing the configuration has no effects?1.9 - No Payment Methods showing upMy Payment Methods not Showing for downloadable/virtual product when checkout?Magento2 API to access internal payment methodHow to call an existing payment methods in the registration form?