Ejemplo n.º 1
0
        /// <summary>
        /// Updates a payment profile for a user.
        /// </summary>
        /// <param name="profileID">The profile ID.</param>
        /// <param name="profile">The profile.</param>
        /// <returns></returns>
        public ANetApiResponse UpdatePaymentProfile(string profileID, PaymentProfile profile)
        {
            var req = new updateCustomerPaymentProfileRequest();

            req.customerProfileId = profileID;
            req.paymentProfile    = profile.ToAPI();

            var response = (updateCustomerPaymentProfileResponse)_gateway.Send(req);

            return(response);
        }
Ejemplo n.º 2
0
        /// <summary>
        /// Updates a payment profile for a user.
        /// </summary>
        /// <param name="profileID">The profile ID.</param>
        /// <param name="profile">The profile.</param>
        /// <returns></returns>
        public bool UpdatePaymentProfile(string profileID, PaymentProfile profile)
        {
            var req = new updateCustomerPaymentProfileRequest();

            req.customerProfileId = profileID;
            req.paymentProfile    = profile.ToAPI();

            if (profile.BillingAddress != null)
            {
                req.paymentProfile.billTo = profile.BillingAddress.ToAPIType();
            }

            var response = (updateCustomerPaymentProfileResponse)_gateway.Send(req);

            return(true);
        }
Ejemplo n.º 3
0
        /// <summary>
        /// Updates a payment profile for a user.
        /// </summary>
        /// <param name="profileID">The profile ID.</param>
        /// <param name="profile">The profile.</param>
        /// <returns></returns>
        public bool UpdatePaymentProfile(string profileID, PaymentProfile profile)
        {
            var req = new updateCustomerPaymentProfileRequest();

            req.customerProfileId = profileID;
            req.paymentProfile = profile.ToAPI();

            var response = (updateCustomerPaymentProfileResponse)_gateway.Send(req);

            return true;
        }
        /// <summary>
        /// Updates a payment profile for a user.
        /// </summary>
        /// <param name="profileID">The profile ID.</param>
        /// <param name="profile">The profile.</param>
        /// <returns></returns>
        public bool UpdatePaymentProfile(string profileID, PaymentProfile profile) {

            var req = new updateCustomerPaymentProfileRequest();
            
            req.customerProfileId = profileID;
            req.paymentProfile = profile.ToAPI();

            if (profile.BillingAddress != null)
                req.paymentProfile.billTo = profile.BillingAddress.ToAPIType();

            var response = (updateCustomerPaymentProfileResponse)_gateway.Send(req);
            
            return true;
        }