Skip to content

Instantly share code, notes, and snippets.

@sharkpp
Last active February 28, 2016 07:09
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save sharkpp/160c3a25b1f480b7a40e to your computer and use it in GitHub Desktop.
Save sharkpp/160c3a25b1f480b7a40e to your computer and use it in GitHub Desktop.
Twitter ID での仮登録/正式登録の認証方法の提案

※ Haroopad とかで確認してね!

    sequenceDiagram

    participant ユーザー
    participant Twitter
    participant ウェブサイト
    participant データベース

    ユーザー->>ウェブサイト: Twitter ID でサインアップ
    ウェブサイト->>データベース: ユーザーを仮登録
    ウェブサイト->>ユーザー: 仮登録したよ!
    loop 定期的に確認
        ウェブサイト->>Twitter: DMが出せますか?
        alt フォローされていない
            Twitter->>ウェブサイト: だせないよ
        else フォローされている
            Twitter->>ウェブサイト: 出せるよ
        end
    end
    ウェブサイト->>Twitter: DMで正式登録認証アドレスおくるね
    ウェブサイト->>データベース: DM送信した、をメモ
    Twitter->>ユーザー: DMがきたよ
    ユーザー->>ウェブサイト: 正式登録認証アドレスでアクセス
    ウェブサイト->>データベース: ユーザーを正式登録
    ウェブサイト->>ユーザー: 正式登録したよ!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment