To make the API easier to use, we recommend creating a few fixed parameters that you will use frequently.





To use the OneStepAI API, user authorization is required. This is done using an access token generated on the OSAI website in the Settings tab.


Create a unique name for the token and its expiration date.


The generated token is displayed only once, so make sure you copy it, as you will not be able to see it again once you close the window.


If you lose your old token or your data is leaked, you can always delete your existing tokens and create many more.





Using the token, sign in to the API via /Users/SignIn, the string received is the JWT authorization token that should be in every request.



For easier use, we recommend assigning the JWT token to a global variable.


#Get user information


To check the validity of the code and API connection, we recommend downloading the user information and see if you are getting the correct data.