2024夏休み旅行 神戸・2日目【前編】 zfinchyan.hatenablog.com ↑1日目はこちら 6:50 わたしと夫だけ先に起床 前日に買っておいたお芋のパンで朝ごはん 昨日の疲れからか、なかなか息子たちが起きてこなかったので、ゆっくり寝かせてから10:00にホテルの下にあるプレイゾーンに行って、パターゴルフやバス…
AppBank の主任です。 Dropbox や Evernote のデータにアクセスするアプリ・Twitter クライアントに欠かせないのが「OAuth 認証」。アプリのアップデートで「OAuth 認証に対応しました」という形で書かれている事が多いのですが、それが何なのかという説明はありません。 かといって、何か使い勝手が大きく変わる訳でもありません。違いと言えば、最初に起動した際に Twitter などのページへ移動してログインするくらいです。しかし、このちょっとした違いがあなたのアカウントを不正利用から守ることに繋がります。 そこで今回は「OAuth 認証」について、分かりやすく解説いたします。 OAuth認証が使われる場面 Twitter などのウェブサービスにアプリが初めてアクセスする時に、以下のような画面が表示されます。アプリがウェブサービスへのアクセスを許可してほしいからです
この記事以降 Twitter API の仕様が変わっており、このままでは正しく機能しない場合があると思います。近いうちに今のやり方を書くので、それまで参考程度にご覧ください。 Twitter API の OAuth でひととおりやってみた。 忘れないようにメモ。 大雑把な流れ Twitter にアプリケーションを登録する。 Consumer Key と Consumer secret を取得する。 リクエストトークンを取得する。 認証用 URL を取得する。 ユーザーから承認を受ける(bot の場合は自分でやる)。 アクセストークンを取得する。 API にアクセスする。 以下、やった作業の手順です。 事前準備 HTTP_OAuth を使えるようにする OAuth の通信部分そのものは PEAR の HTTP_OAuth を使うことにしたので これをインストールする。 一番めんどくさい部分を
Googleあたりで「Twitter アプリケーション 作成」とでも入力して調べようと思ったら、Twitterのデザインがリニューアルされてからの紹介記事が少なかったので、不完全ですが、Twitterアプリケーション登録の流れを記述します。 これは既にTwitterのデベロッパー登録が済ませてあることを前提としてある記事ですので、新規登録では多少違う点があるかもしれません。その際はコメントなりTwitterなりで「ちがうじゃねーかバカヤロー」とでも申し付け下さい。デベロッパー登録を済ませていないアカウントで確認しましたが問題なく行えました。 まずはここにアクセスします。Twitterアカウントでログインしましょう。 すると次のような画面が出ます。 「Create new application」を選択し、アプリケーションを作成しましょう。 さて、次のような画面が表示されます。 赤い
リリース、障害情報などのサービスのお知らせ
最新の人気エントリーの配信
処理を実行中です
j次のブックマーク
k前のブックマーク
lあとで読む
eコメント一覧を開く
oページを開く