Beispiel #1
0
        public MisskeyClient(Credential credential, HttpClientHandler innerHandler = null) : base(credential, new MisskeyAuthenticationHandler(innerHandler), RequestMode.Json)
        {
            BinaryParameters = new List <string> {
                "file"
            };

            Aggregation   = new AggregationClient(this);
            Ap            = new ApClient(this);
            Admin         = new AdminClient(this);
            App           = new MisskeyAppClient(this);
            Auth          = new AuthClient(this);
            Blocking      = new BlockingClient(this);
            Charts        = new ChartsClient(this);
            Drive         = new DriveClient(this);
            Federation    = new FederationClient(this);
            Following     = new FollowingClient(this);
            Hashtags      = new HashtagsClient(this);
            I             = new IClient(this);
            Messaging     = new MessagingClient(this);
            Mute          = new MuteClient(this);
            My            = new MyClient(this);
            Notes         = new NotesClient(this);
            Notifications = new NotificationsClient(this);
            Streaming     = new StreamingClient(this);
            Username      = new UsernameClient(this);
            Users         = new UsersClient(this);
        }
Beispiel #2
0
        public MisskeyClient(string domain, string secret = null) : base($"https://{domain}", AuthMode.Myself, RequestMode.Json)
        {
            Domain           = domain;
            ClientSecret     = secret;
            BinaryParameters = new List <string>();

            Aggregation = new AggregationClient(this);
            App         = new MisskeyAppClient(this);
            Auth        = new AuthClient(this);

            RegisterCustomAuthenticator(MisskeyAuthentication);
        }