kei-mag / Hakoirimusume

LINE bot for monitoring my rabbit with camera & thermometer.
MIT License
0 stars 0 forks source link

Implement User Authentication with Aikotoba #5

Closed kei-mag closed 3 months ago

kei-mag commented 5 months ago

Functions

Data

Process of authentication

A: user, B: new comer

  1. A request to create new aikotoba.
  2. A got new aikotoba.
  3. A tell aikotoba string to B.
  4. B requests authentication
  5. System replies "Start authentication. Please send me aikotoba".
    (And adds B to UserData database for state management)
  6. B send aikotoba string. If B send correct aikotoba
  7. B is added to user list. [END] If B send wrong aikotoba
  8. System replies "Your aikotoba is not correct. Please ask user to recreate aikotoba."
  9. System variable aikotobaString is set to null.
  10. If B resend the same wrong aikotoba.
  11. System replies "Your aikotoba is not correct. Please ask user to recreate aikotoba."
    (when aikotobaString==null, system always replies 'not correct.')
  12. Back to step 1.