Evernote API の調査

EvernoteはAPIが豊富だ、という話を聞いたので、調査してみた。

まずは、APIの利用申請が必要らしい。
https://www.evernote.com/about/developer/api/
英語のページだけど、入力する内容も少ないので、まあなんとかなる。

申請するとすぐにconsumer key, consumer secretが
Evernoteアカウントに登録したメールアドレスに送られてくる。

API仕様書は、
https://www.evernote.com/about/developer/api/evernote-api.htm
で確認できます。

API開発のためには、sandbox環境にアカウントを作らないといけないようで、
https://sandbox.evernote.com/Login.action
こちらからできます。

あとは、
http://www.evernote.com/about/developer/api/
にある、Zipをダウンロードして、そこに含まれるサンプルコードを
動かして、、、っておもったら、全然動かないでござる。。。

心が折れたので、ここでやめて、ふて寝する。

$ php EDAMTest.php tanarky sandboxアカウントパスワード
Is my EDAM protocol version up to date?  1

Fatal error: Uncaught exception 'edam_error_EDAMUserException' in /home/satoshi/src/evernote-api-1.14/lib/php/packages/UserStore/UserStore.php:706
Stack trace:
#0 /home/satoshi/src/evernote-api-1.14/lib/php/packages/UserStore/UserStore.php(128): edam_userstore_UserStore_authenticate_result->read(Object(TBinaryProtocol))
#1 /home/satoshi/src/evernote-api-1.14/lib/php/packages/UserStore/UserStore.php(86): UserStoreClient->recv_authenticate()
#2 /home/satoshi/src/evernote-api-1.14/sample/php/EDAMTest/EDAMTest.php(46): UserStoreClient->authenticate('tanarky', 'satoshi', 'en-edamtest', '0123456789abcde...')
#3 {main}
  thrown in /home/satoshi/src/evernote-api-1.14/lib/php/packages/UserStore/UserStore.php on line 706


参考:
Evernote API

人気の投稿