1 month ago

integration server

Posted 1 month ago by Aronaman

hello guys it is the first time, i need some ideas.

there is a desktop application made using vb and I made a web app, my client wants to integrate the local DB connect with the cloud server.

what I did so far (conceptual)

create API (REST API in .Net ) for desktop application and define endpoints. then i create a restful API for the web app(laravel), then i think every user should have an API key, so i create the column "access_key" inside the user table in laravel then i generate 10 unique random digits and save it inside user table in access_key column for every user, after that i create a middleware "apiKey" check the access key belongs to the user. after that, i define the API route with the middleware.

my question is: #1my method is recommended?? or should I use laravel passport and generate personal access token??, if so where should i save personal access token in laravel ?

#2 the integration planed in both directions so, i should prepare a form in desktop to save the access_key inside the desktop configuration ?? same access_key for same user on web and desktop. on both endpoint e.g https://server.larave/api/create/access_key=As1sdgddfsdrt (it is from desktop to web) and https://desktop/api/4/update/access_key=As1sdgddfsdrt (it is from web to desktop) ??

i know i make it more complex, can any body help me thanks

Please sign in or create an account to participate in this conversation.