So, I am using 3rd party solution otpless
to onboard user. Now, the things is this 3rd party sol does not generate session token. So, I will be using this service to simply verify user but I generate session I want to use appwrite... So, any suggestion?
there response body, json
{
"statusCode": 200,
"data": {
"userMobile": "911234567890",
"userName": "OTPless",
"timestamp": "2023-03-24T11:28:38.148973Z"
},
"user": {
"waId": "test1234",
"waNumber": "911234567890",
"waName": "OTPless",
"timestamp": "2023-03-24T11:28:38.148798Z"
},
"success": true,
"ok": true,
"status": "SUCCESS"
}
Hi, first of all, if the userMobile
is confidential - please try removing it from your sample response body for the sake of privacy, second, let me look into the best way to do this but a suggestion might be to make a function that gets triggered when OTPless indicates a login and an account is created using createAccount for storing sessions - although that might be tough given there are no tokens in response you sent
ahh, no not it's random phone... btw again I will mask it
awesome! good to know
Can you send us some link to docs about server integration so we can check how it can integrate with Appwrite
actually, they seems be asking for business email, but I can do one things I can copy paste the state that they asked to follow...
I had used bitecope support email ( steps seems fairly simple) ... they prettry much support all the frontend sdks
they simply asked to call, this curl url....curl
curl --location --request POST 'https://companyName.authlink.me' \
--header 'clientId: test1234' \
--header 'clientSecret: test1234' \
--header 'Content-Type: application/json' \
--data-raw '{
"waId": "test1234"
}'
they mainly only 3 response status, 101, 200 & 500 only
on 200 this is the body
any suggestion or thoughts on this would be very helpful π
but for now I have implemented the google OAuth
Honestly, the best thing to do would be to onboard this as one of our phone auth providers.
We actually had a PR for adding whatsapp auth via 360dialog: https://github.com/appwrite/appwrite/pull/4536
like jyoti said, you can't send headers or cookies back from functions so you can't really make a normal appwrite session...
mm yaa, agree... I guess no worries for now I was just wondering here and there for last couple of days figuring out which Auth to go and hwo ..have settled with Google Auth and I hope in future WhatsApp ( hopefully if possible in next release get added) and any way in meantime will try to figure out phone number provider
btw can like Otpless team also request for PR?
If so I will try to nudge them to support appwrite
in order to work with us, the provider would need to have an API to send a code that we generate. My concern is otpless doesn't allow that. it seems like they generate the OTP themselves?
mm not sure, but as per current so flow is like there buttons user clicks they launched WhatsApp, the user clicks on send button with fixed message template and send in response get link, when user clicks on link then user get redirected back to the App... The good part that i like is link is binded with devices so if user forward the link it gets expired...
anyway for now I guess we can consider this thread closed... I guess I will inform Otpless team if there is any possibility they can try to integrate appwrite somehow...
ya...probably not
it's almost ~1 AM here so will go sleep, from morning there would be quite few questions that i already have in mind to ask π π
Recommended threads
- Attributes Confusion
```import 'package:appwrite/models.dart'; class OrdersModel { String id, email, name, phone, status, user_id, address; int discount, total, created_at; L...
- I recently applied for the free plan und...
I recently applied for the free plan under the GitHub Student Developer Pack. However, my billing status still shows $15, and it mentions that this amount will ...
- How to Avoid Double Requests in function...
I'm currently using Appwrite's `functions.createExecution` in my project. I want to avoid double requests when multiple actions (like searching or pagination) a...