コード例 #1
0
        private RecipientAccount recipientFactory(string response)
        {
            var tempData = JObject.Parse(response)["account"];
            RecipientAccount recipientAccount = JsonConvert.DeserializeObject <RecipientAccount>(tempData.ToString());

            return(recipientAccount);
        }
コード例 #2
0
        public RecipientAccount create(string recipient_id, RecipientAccount recipientAccount)
        {
            StringBuilder builder = new StringBuilder();

            builder.AppendFormat("/v1/recipients/{0}/accounts", recipient_id);
            string endPoint = builder.ToString();
            string response = this.gateway.client.post(endPoint, recipientAccount);

            return(recipientFactory(response));
        }
コード例 #3
0
 /// <summary>
 /// Deletes a recipient account for the given recipient
 /// </summary>
 /// <param name="recipient_id"></param>
 /// <param name="recipientAccount"></param>
 /// <returns></returns>
 public static bool delete(string recipient_id, RecipientAccount recipientAccount)
 {
     return(delete(recipient_id, recipientAccount.id));
 }
コード例 #4
0
 /// <summary>
 /// Updates a recipient account for the given recipient
 /// </summary>
 /// <param name="recipient_id"></param>
 /// <param name="recipientAccount"></param>
 /// <returns></returns>
 public static RecipientAccount update(string recipient_id, RecipientAccount recipientAccount)
 {
     return(PaymentRails_Configuration.gateway().recipientAccount.update(recipient_id, recipientAccount));
 }