Recurly.Account.InvoicePendingCharges C# (CSharp) Method

InvoicePendingCharges() public method

Posts pending charges on an account
public InvoicePendingCharges ( ) : Invoice
return Invoice
        public Invoice InvoicePendingCharges()
        {
            var i = new Invoice();
            Client.Instance.PerformRequest(Client.HttpRequestMethod.Post,
                UrlPrefix + Uri.EscapeUriString(AccountCode) + "/invoices",
                i.ReadXml);

            return i;
        }

Usage Example

        public void ListAdjustments()
        {
            Account acct = new Account(Factories.GetMockAccountName());
            acct.Create();

            Adjustment a = acct.CreateAdjustment("Charge", 5000, "USD", 1);
            a.Create();

            a = acct.CreateAdjustment("Credit", -1492, "USD", 1);
            a.Create();

            acct.InvoicePendingCharges();

            AdjustmentList adjustments = acct.GetAdjustments();
            Assert.IsTrue(adjustments.Count == 2);
        }
All Usage Examples Of Recurly.Account::InvoicePendingCharges