fork download
class Client
    {
        RestClient _client = new RestClient(SettingsContainer.ApiPath.Testers);

        public Client()
        {
            _client.CookieContainer = new System.Net.CookieContainer();
        }

        public string Ping()
        {
            var request = new RestRequest("Ping", Method.GET);

            var response = _client.Execute(request);
            return response.Content;
        }

        public string Authentification(string login, int protocolVersion, string userId, string pushToken)
        {
            var request = new RestRequest("Authentification/{login}/{protocolVersion}/{userId}/{pushToken}", Method.GET);

            request.AddUrlSegment("login", login);
            request.AddUrlSegment("protocolVersion", protocolVersion.ToString());
            request.AddUrlSegment("userId", userId);
            request.AddUrlSegment("pushToken", pushToken);

            var response = _client.Execute(request);

            foreach (var item in response.Cookies)
            {
                var cookie = new System.Net.Cookie()
                {
                    Name = item.Name,
                    Comment = item.Comment,
                    CommentUri = item.CommentUri,
                    Discard = item.Discard,
                    Domain = item.Domain,
                    Expired = item.Expired,
                    Expires = item.Expires,
                    HttpOnly = item.HttpOnly,
                    Path = item.Path,
                    Port = item.Port,
                    Secure = item.Secure,
                    Value = item.Value,
                    Version = item.Version
                };

                _client.CookieContainer.Add(cookie);
            }

            return response.Content;
        }
Compilation error #stdin compilation error #stdout 0s 0KB
stdin
Standard input is empty
compilation info
prog.cs(51,254): error CS1525: Unexpected symbol `end-of-file'
Compilation failed: 1 error(s), 0 warnings
stdout
Standard output is empty