public void testAccount()
        {
            string uuid = Guid.NewGuid().ToString();

            Address   address   = new Address("123 Wolfstrasse", "Berlin", "DE", "123123");
            Recipient recipient = new Recipient("individual", "test.create" + uuid + "@example.com", null, "Tom", "Jones", null, null, null, null, null, "1990-01-01", null, null, null, address);

            recipient = gateway.recipient.create(recipient);

            Assert.IsNotNull(recipient);
            Assert.AreEqual("Tom", recipient.firstName);
            Assert.AreEqual("Jones", recipient.lastName);
            Assert.IsNotNull(recipient.email.IndexOf(uuid));
            Assert.IsNotNull(recipient.id);

            RecipientAccount recipientAccount = new RecipientAccount("bank-transfer", "EUR", null, true, "FR", "FR14 2004 1010 0505 0001 3M02 606", "123456");

            recipientAccount = gateway.recipientAccount.create(recipient.id, recipientAccount);
            Assert.IsNotNull(recipientAccount);

            recipientAccount = new RecipientAccount("bank-transfer", "EUR", null, true, "DE", "DE89 3704 0044 0532 0130 00", "123456");
            recipientAccount = gateway.recipientAccount.create(recipient.id, recipientAccount);
            Assert.IsNotNull(recipientAccount);

            Recipient usRecipient = new Recipient("individual", "test.accountCheck" + uuid + "@example.com", null, "Tom", "Jones Check", null, null, null, null, null, "1990-01-01", null, null, null, new Address("719 anderson dr", "Los Altos", "US", "CA", "94024"));

            usRecipient = gateway.recipient.create(usRecipient);
            RecipientAccount recipientCheckAccount = new RecipientAccount
            {
                type    = "check",
                mailing = new MailingAddress("Tom Jones", "719 anderson dr", "Los Altos", "US", "CA", "94024")
            };

            recipientCheckAccount = gateway.recipientAccount.create(usRecipient.id, recipientCheckAccount);
            Assert.IsNotNull(recipientCheckAccount);

            RecipientAccount findAccount = gateway.recipientAccount.find(recipient.id, recipientAccount.id);

            Assert.AreEqual(recipientAccount.iban, findAccount.iban);

            List <RecipientAccount> recipientAccounts = gateway.recipientAccount.findAll(recipient.id);

            Assert.AreEqual(2, recipientAccounts.Count);
            Assert.AreEqual(recipientAccounts[0].currency, "EUR");

            bool response = gateway.recipientAccount.delete(recipient.id, recipientAccount.id);

            Assert.IsTrue(response);

            recipientAccounts = gateway.recipientAccount.findAll(recipient.id);
            Assert.AreEqual(1, recipientAccounts.Count);
        }
        private Recipient createRecipient()
        {
            string    uuid      = Guid.NewGuid().ToString();
            Address   address   = new Address("123 Wolfstrasse", "Berlin", "DE", null, "123123");
            Recipient recipient = new Recipient("individual", "test.create" + uuid + "@example.com", null, "Tom", "Jones", null, null, null, null, null, "1990-01-01", null, null, null, address);

            recipient = gateway.recipient.create(recipient);

            RecipientAccount recipientAccount = new RecipientAccount("bank-transfer", "EUR", null, true, "DE", "DE89 3704 0044 0532 0130 00", "123456");

            recipientAccount = gateway.recipientAccount.create(recipient.id, recipientAccount);

            return(recipient);
        }
        protected static RecipientAccount RecipientAccountJsonHelperToRecipientAccount(RecipientAccountJsonHelper helper)
        {
            RecipientAccount recipientAccount = new RecipientAccount(helper.Type, helper.Currency, helper.Id, helper.Primary, helper.Country, helper.Iban, helper.AccountNum, helper.RecipientAccountId, helper.RouteType, helper.RecipientFees, helper.EmailAddress, helper.AccountHolderName, helper.SwiftBic, helper.BranchId, helper.BankName, helper.BankId, helper.BankAddress, helper.BankCity, helper.BankRegionCode, helper.BankPostalCode);

            return(recipientAccount);
        }