Users running a non-download version of Vanilla (pulled from github), on branch release/2019.016 or master from the last 2 weeks should upgrade to release/2019.017 or latest master for security reasons. Downloaded official open sources releases are not affected.

How to get access token through api

Hi, I am trying to develop an app using vanilla forums api. I have figured out that we need the access token of a user to post a discussion. I am using version 2 of the api. Can anyone help me with getting a access token of any user. we will have the id of the user, is there any way by which we can get the token/ transient key and token id.

Also, is there any way other than this api(https://docs.vanillaforums.com/help/apiv2/swagger/#/Tokens/get_tokens__id_) to get the token.

Thanks.

Comments

  • Any update on this matter? I'm facing the same problem

  • R_JR_J Cheerleader & Troubleshooter Munich Moderator


    Well, you obviously found that discussion where there is an example.


  • R_JR_J Cheerleader & Troubleshooter Munich Moderator

    I really appreciate that you are searching the forum for solutions. But if you haven't find the answers to the question you are asking here and also in this discussion in that other discussion where you have posted, I begin to doubt that I understood your requirements. From what I can see you have asked three different questions:

    1. How to generate an API token with JavaScript for a user
    2. How to get the token of a user
    3. How to embed the forum in a ReactJS app

    Could you please describe what you have right now and what you need? Maybe instead of polluting three different discussions, you should start a dedicated discussion just for that?


  • MunSemMunSem New
    edited December 2019

    Currently, I'm looking for a solution to integrate vanilla forum into my application with our own user database. I'm trying to use API at first but then I couldn't found any easy solution for SSO (couldn't fully understand how connectjs works). After that, I try to go for embedded approach but I'm also facing difficulties embedding it in Reactjs app. From what I understand now, if I need to call API on behave of an individual user, i need to create a custom plugin (php) with an endpoint and I need to call that endpoint in order to create a access token for a user. If I'm wrong, could you brief me step by step how connectjs works with v2 api in order to achieve SSO? Thanks in advance 😁

Sign In or Register to comment.