From 11769d65fd3565f2f999ff714f0390a48ff8fa99 Mon Sep 17 00:00:00 2001 From: ceee Date: Sun, 29 Sep 2013 23:22:03 +0200 Subject: [PATCH] update readme --- PocketSharp.Website/index.html | 26 ++++++++++++++++++++------ README.md | 32 +++++++++++++++++++++++++++++--- 2 files changed, 49 insertions(+), 9 deletions(-) diff --git a/PocketSharp.Website/index.html b/PocketSharp.Website/index.html index 9b840f8..c856d26 100644 --- a/PocketSharp.Website/index.html +++ b/PocketSharp.Website/index.html @@ -33,7 +33,7 @@

PocketSharp is a C#.NET class library, that integrates the Pocket API v3

- Current version: 1.4.0
+ Current version: 1.5.0
@ nuget

@@ -48,8 +48,8 @@
@@ -125,6 +125,7 @@ using PocketSharp.Models;

Release History

    +
  • 1.5.0 (2013-09-28) add statistics and registration API
  • 1.4.0 (2013-09-21) rename Retrieve to Get + update IntelliSense documentation + add GetTags method
  • 1.3.0 (2013-09-19) get Item by ID + tag modification bugfixes
  • 1.2.1 (2013-09-18) correct parameter conversion for DateTime and Boolean
  • @@ -152,7 +153,7 @@ using PocketSharp.Models; -
    +

    Authentication

    @@ -188,12 +189,20 @@ Note that GetAccessCode can only be called with an existing req Without it you would always have to redo the authentication process.

    +

    Account Registration

    +

    The RegisterAccount method exists in Pocket API v3, but is currently undocumented. +
    The user cannot authenticate directly after registration, as the account has to be activated via an opt-in link, which is sent to the e-mail address.

    +
    bool isSuccess = await _client.RegisterAccount("myUsername", "me@mymail.com", "mypassword");
    +
    + +

    After registration you have to remind the user to check his/her mail account.

    +
    -
    +
    -

    Retrieve

    +

    Get

    Get list of all items:

    List<PocketItem> items = await _client.Get();
    @@ -226,6 +235,11 @@ Note that GetAccessCode can only be called with an existing req
     // returns favorites only

    The RetrieveFilter Enum is specified as follows:

    enum RetrieveFilter { All, Unread, Archive, Favorite, Article, Video, Image }

    +

    Statistics

    +

    The Pocket API supports retrieval of a simple statistics object.

    +
    PocketStatistics statistics = await client.Statistics();
    +// PocketStatistics: [CountAll], [CountRead], [CountUnread]
    +
    diff --git a/README.md b/README.md index 634b514..fc5463c 100644 --- a/README.md +++ b/README.md @@ -1,17 +1,27 @@ ![PocketSharp](https://raw.github.com/ceee/PocketSharp/master/PocketSharp.Website/Assets/Images/github-header.png) -**PocketSharp** is a C#.NET class library, that integrates the [Pocket API v3](http://getpocket.com/developer) and consists of 4 parts: [Authentication](#authentication), [Retrieve](#retrieve), [Modify](#modify) and [Add](#add). +**PocketSharp** is a C#.NET class library, that integrates the [Pocket API v3](http://getpocket.com/developer). **Website:** [pocketsharp.frontendplay.com](http://pocketsharp.frontendplay.com/)
    **NuGet:** [nuget.org/packages/PocketSharp](https://www.nuget.org/packages/PocketSharp/) + ## Install using NuGet ``` Install-Package PocketSharp ``` +## Components + +- [Get](#get) - Retrieve and search for items +- [Modify](#modify) - Modify items and its tags +- [Add](#add) - Add new items +- [Authentication](#account-authentication) - Authenticate users +- [Registration](#account-registration) - Register new users +- [Statistics](#statistics) - Retrieve account statistics + ## Supported platforms PocketSharp is a **Portable Class Library** (since 1.0.0), therefore it's compatible with multiple platforms: @@ -103,7 +113,7 @@ _client.AccessCode = "[YOU_ACCESS_CODE]";
    **After authentication** you will need to provide the `accessCode`. -## Authentication +## Account Authentication In order to communicate with a Pocket User, you will need a consumer key (which is generated by [creating a new application on Pocket](http://getpocket.com/developer/apps/)) and an **Access Code**. @@ -144,7 +154,16 @@ Note that `GetAccessCode` can only be called with an existing _request code_. If
    Without it you would always have to redo the authentication process. -## Retrieve +## Account Registration + +The `RegisterAccount` method exists in Pocket API v3, but is currently undocumented. +
    The user cannot authenticate directly after registration, as the account has to be activated via an opt-in link, which is sent to the e-mail address. + + bool isSuccess = await _client.RegisterAccount("myUsername", "me@mymail.com", "mypassword"); + +After registration you have to remind the user to check his/her mail account. + +## Get Get list of all items: @@ -281,6 +300,13 @@ Renames a tag for the specified item: bool isSuccess = await _client.RenameTag(myPocketItem, "oldTagName", "newTagName"); +## Statistics + +The Pocket API supports retrieval of a simple statistics object. + + PocketStatistics statistics = await client.Statistics(); + // PocketStatistics: [CountAll], [CountRead], [CountUnread] + --- ## Release History