Exemplo n.º 1
0
        Create_request()
        {
            string path =
                new Utilities.URI.Path()
                .Subdirectory(Request_addresses.Tiers.Delete_tier)
                .Subdirectory(_tier.tierid);
            HttpWebRequest request =
                (HttpWebRequest)WebRequest.Create(
                    URI_builder.Create(
                        Uri.UriSchemeHttps,
                        Base_request_address,
                        path,
                        new Query().Element("access_token",
                                            Token.Access_token)));

            request.Method = "DELETE";
            return(request);
        }
Exemplo n.º 2
0
        Create_request()
        {
            string path =
                new Utilities.URI.Path()
                .Subdirectory(Request_addresses.Tiers.Get_tier_details)
                .Subdirectory(_tierId);
            HttpWebRequest request =
                (HttpWebRequest)WebRequest.Create(
                    URI_builder.Create(
                        Uri.UriSchemeHttps,
                        Base_request_address,
                        path,
                        new Query().Element("access_token",
                                            Token.Access_token)));

            request.Method = WebRequestMethods.Http.Get;
            return(request);
        }
Exemplo n.º 3
0
        Create_request()
        {
            string path =
                new Utilities.URI.Path()
                .Subdirectory(Request_addresses.Tiers.Update_tier_details)
                .Subdirectory(_tier.tierid);
            HttpWebRequest request =
                (HttpWebRequest)WebRequest.Create(
                    URI_builder.Create(
                        Uri.UriSchemeHttps,
                        Base_request_address,
                        path,
                        new Query().Element("access_token",
                                            Token.Access_token)));

            JSON.Serialize_to <Tier>(_tier, request, WebRequestMethods.Http.Put);
            return(request);
        }
Exemplo n.º 4
0
        Create_request()
        {
            string path =
                new Utilities.URI.Path()
                .Subdirectory(Request_addresses.Transactions.Get_PointsInRange)
                .Subdirectory(_pointsInfo.uuid).
                Subdirectory(_pointsInfo.start_date.Value.ToString("yyyy-MM-dd HH:mm:ss")).
                Subdirectory(_pointsInfo.end_date.Value.ToString("yyyy-MM-dd HH:mm:ss")).
                Subdirectory(Convert.ToString(_pointsInfo.points_type));
            HttpWebRequest request =
                (HttpWebRequest)WebRequest.Create(
                    URI_builder.Create(
                        Uri.UriSchemeHttps,
                        Base_request_address,
                        path,
                        new Query().Element("access_token",
                                            Token.Access_token)));

            return(request);
        }
Exemplo n.º 5
0
        Create_request()
        {
            string path =
                new Utilities.URI.Path()
                .Subdirectory(Request_addresses.Members.Update_member_details)
                .Subdirectory(details_.uuid);
            HttpWebRequest request =
                (HttpWebRequest)WebRequest.Create(
                    URI_builder.Create(
                        Uri.UriSchemeHttps,
                        Base_request_address,
                        path,
                        new Query().Element("access_token",
                                            Token.Access_token)));

            MemberProfileConverter profileConverter = new MemberProfileConverter();

            JSON.Register_Converters(new[] { profileConverter });
            JSON.Serialize_to <Member>(details_, request, WebRequestMethods.Http.Put);
            return(request);
        }