using PocketSharp.Models; using System; using System.Threading.Tasks; namespace PocketSharp { /// /// PocketClient /// public partial class PocketClient { /// /// Adds a new item to pocket /// /// The URL of the item you want to save /// A comma-separated list of tags to apply to the item /// This can be included for cases where an item does not have a title, which is typical for image or PDF URLs. If Pocket detects a title from the content of the page, this parameter will be ignored. /// If you are adding Pocket support to a Twitter client, please send along a reference to the tweet status id. This allows Pocket to show the original tweet alongside the article. /// A simple representation of the saved item which doesn't contain all data (is only returned by calling the Retrieve method) /// public async Task Add(Uri uri, string[] tags = null, string title = null, string tweetID = null) { AddParameters parameters = new AddParameters() { Uri = uri, Tags = tags, Title = title, TweetID = tweetID }; Add response = await Request("add", parameters.Convert()); return response.Item; } } }