public async Task SetActivity( int userId , ImActivity type = ImActivity.Typing ) { await _parent.Executor.ExecAsync( _parent._reqapi.Messages.SetActivity( userId,type ) ).ConfigureAwait(false) ; }
public void SetActivitySync( int userId , ImActivity type = ImActivity.Typing ) { var task = _parent.Executor.ExecAsync( _parent._reqapi.Messages.SetActivity( userId,type ) ); task.Wait(); }
public Request<bool> SetActivity( int userId , ImActivity type = ImActivity.Typing ) { var req = new Request<bool>{ MethodName = "messages.setActivity", Parameters = new Dictionary<string, string> { { "user_id", userId.ToNCString()}, { "type", type.ToNCString().ToSnake()}, } }; req.Token = _parent.CurrentToken; return req; }