public MastodonClient(string domain) : base($"https://{domain}", AuthMode.OAuth2, RequestMode.FormUrlEncoded) { Domain = domain; BinaryParameters = new List <string> { "avatar", "header", "file" }; Account = new AccountsClient(this); Apps = new AppsClient(this); Auth = new AuthClient(this); Blocks = new BlocksClient(this); CustomEmojis = new CustomEmojisClient(this); DomainBlocks = new DomainBlocksClient(this); Endorsements = new EndorsementsClient(this); Favorites = new FavoritesClient(this); Filters = new FiltersClient(this); FollowRequests = new FollowRequestsClient(this); Follows = new FollowsClient(this); Instance = new InstanceClient(this); Lists = new ListsClient(this); Media = new MediaClient(this); Notifications = new NotificationsClient(this); Push = new PushClient(this); Reports = new ReportsClient(this); SearchV1 = new SearchV1Client(this); SearchV2 = new SearchV2Client(this); Statuses = new StatusesClient(this); Streaming = new StreamingClient(this); Suggestions = new SuggestionsClient(this); Timelines = new TimelinesClient(this); }
public MastodonClient(Credential credential, HttpClientHandler innerHandler = null) : base(credential, new OAuth2HttpClientHandler(innerHandler), RequestMode.FormUrlEncoded) { BinaryParameters = new List <string> { "avatar", "header", "file" }; Account = new AccountsClient(this); Apps = new AppsClient(this); Auth = new AuthClient(this); Blocks = new BlocksClient(this); Conversations = new ConversationsClient(this); CustomEmojis = new CustomEmojisClient(this); DomainBlocks = new DomainBlocksClient(this); Endorsements = new EndorsementsClient(this); Favorites = new FavoritesClient(this); Filters = new FiltersClient(this); FollowRequests = new FollowRequestsClient(this); Follows = new FollowsClient(this); Instance = new InstanceClient(this); Lists = new ListsClient(this); Media = new MediaClient(this); Notifications = new NotificationsClient(this); Push = new PushClient(this); Reports = new ReportsClient(this); ScheduledStatuses = new ScheduledStatusesClient(this); SearchV1 = new SearchV1Client(this); SearchV2 = new SearchV2Client(this); Statuses = new StatusesClient(this); Streaming = new StreamingClient(this); Suggestions = new SuggestionsClient(this); Timelines = new TimelinesClient(this); }