0
@@ -209,25 +209,251 @@ WebService::Hatena::Diary - A Perl Interface for Hatena::Diary AtomPub API
0
WebService::Hatena::Diary is a simple wrapper of Hatena::Diary AtomPub API.
0
This provides CRUD interfaces for Hatena::Diary and it's draft entries.
0
+=head2 new ( I<\%args> )
0
+ my $diary = WebService::Hatena::Diary->new({
0
+ username => $username,
0
+ dusername => $dusername,
0
+ password => $password,
0
+Create a WebService::Hatena::Diary object.
0
+B<dusername> (Optional)
0
+Diary name that you want to manipulate.
0
+Password for your Hatena id.
0
+API mode ( C<blog> | C<draft> ).
0
+ Returns a UserAgent of this API.
0
+Returns a error messages of the last error.
0
+ my @entries = $diary->list;
0
+Returns a LIST of entries of the specified (blog|draft).
0
+Each entry has values blow as a HASH object:
0
+Edit URI is a URI to identify a entry.
0
+Content of a entry as a html format.
0
+YYYY-MM-DD style date of a entry.
0
+=head2 create ( I<\%args> )
0
+ my $edit_uri = $diary->create({
0
+Create a new entry of the specified (blog|draft).
0
+Returns Edit URI of a created entry if succeed.
0
+You have to pass C<date> on a YYYY-MM-DD format.
0
+=head2 retrieve ( I<$edit_uri> )
0
+ my $entry = $diary->retrieve($edit_uri);
0
+Returns a entry specified by an Edit URI as a HASH object like below:
0
+Content of a entry as a html format.
0
+Content of a entry as a hatena syntax format.
0
+YYYY-MM-DD style date of a entry.
0
+=head2 update ( I<$edit_uri>, I<\%args> )
0
+ $diary->update($edit_uri, {
0
+Update a entry specified by an Edit URI.
0
+=head2 delete ( I<$edit_uri> )
0
+ $diary->delete($edit_uri);
0
+Delete a entry specified by an Edit URI.
0
+=head2 publish ( I<$edit_uri> )
0
+ $diary->publish($edit_uri);
0
+Publish a I<draft> entry specified by an Edit URI.
0
+If you publish a draft entry, the entry will be deleted from draft,
0
+and a new I<blog> entry will be created.
0
+If you want to see latest version of this module, please see
0
+L<https://github.com/hakobe/webservice-hatena-diary/tree>
0
Yohei Fushii E<lt>hakobe@gmail.comE<gt>
0
This library is free software; you can redistribute it and/or modify
0
it under the same terms as Perl itself.
0
-=item L<http://d.hatena.ne.jp>
0
+L<http://d.hatena.ne.jp>
0
+L<http://d.hatena.ne.jp/keyword/%A4%CF%A4%C6%A4%CA%A5%C0%A5%A4%A5%A2%A5%EA%A1%BCAtomPub>
0
-=item
L<http://d.hatena.ne.jp/keyword/%A4%CF%A4%C6%A4%CA%A5%C0%A5%A4%A5%A2%A5%EA%A1%BCAtomPub>0
-
=item L<WWW::HatenaDiary>