Full Code of XeroAPI/Xero-Net for AI

master 9dd5645f3cc4 cached
799 files
9.7 MB
2.6M tokens
3245 symbols
1 requests
Copy disabled (too large) Download .txt
Showing preview only (10,345K chars total). Download the full file to get everything.
Repository: XeroAPI/Xero-Net
Branch: master
Commit: 9dd5645f3cc4
Files: 799
Total size: 9.7 MB

Directory structure:
gitextract_xmz3hwlp/

├── .gitignore
├── CoreTests/
│   ├── ApiWrapperTest.cs
│   ├── App.config
│   ├── CoreTests.csproj
│   ├── Integration/
│   │   ├── Accounts/
│   │   │   ├── Create.cs
│   │   │   ├── Find.cs
│   │   │   └── Update.cs
│   │   ├── Allocations/
│   │   │   └── Add.cs
│   │   ├── Attachments/
│   │   │   └── Attachments.cs
│   │   ├── BankTransactionTest.cs
│   │   ├── BankTransactions/
│   │   │   ├── BankTransactionTest.cs
│   │   │   ├── Create.cs
│   │   │   ├── Find.cs
│   │   │   └── Update.cs
│   │   ├── BankTransfers/
│   │   │   ├── BankTransfersTest.cs
│   │   │   ├── Create.cs
│   │   │   └── Find.cs
│   │   ├── BatchPayment/
│   │   │   ├── BatchPaymentsTest.cs
│   │   │   └── Create.cs
│   │   ├── ContactGroups/
│   │   │   ├── Add_Contact.cs
│   │   │   ├── ContactGroupsTest.cs
│   │   │   ├── Create.cs
│   │   │   ├── Delete.cs
│   │   │   ├── Find.cs
│   │   │   ├── Remove_Contact.cs
│   │   │   └── Update.cs
│   │   ├── Contacts/
│   │   │   ├── ContactsTest.cs
│   │   │   ├── Create.cs
│   │   │   ├── Find.cs
│   │   │   └── Update.cs
│   │   ├── CreditNotes/
│   │   │   ├── Create.cs
│   │   │   ├── CreditNotesTest.cs
│   │   │   ├── Find.cs
│   │   │   └── Update.cs
│   │   ├── ExpenseClaims/
│   │   │   ├── Create.cs
│   │   │   ├── ExpenseClaimTest.cs
│   │   │   └── Update.cs
│   │   ├── Files/
│   │   │   ├── Associations/
│   │   │   │   └── AssociationTest.cs
│   │   │   ├── Files/
│   │   │   │   └── AddFileTest.cs
│   │   │   ├── Folders/
│   │   │   │   └── AddFolderTest.cs
│   │   │   ├── Inbox/
│   │   │   │   └── InboxTest.cs
│   │   │   └── Support/
│   │   │       ├── DataItem.cs
│   │   │       ├── DiskFile.cs
│   │   │       ├── File.cs
│   │   │       └── FilesTest.cs
│   │   ├── General/
│   │   │   ├── Errors.cs
│   │   │   ├── FindingAllItems.cs
│   │   │   └── QueryStrings.cs
│   │   ├── HistoryAndNotes/
│   │   │   ├── CreateNotes.cs
│   │   │   ├── Find.cs
│   │   │   └── HistoryAndNotesTest.cs
│   │   ├── Invoices/
│   │   │   ├── Create.cs
│   │   │   ├── Find.cs
│   │   │   ├── InvoicesTest.cs
│   │   │   ├── OnlineInvoiceUrl.cs
│   │   │   └── SummarizeErrors.cs
│   │   ├── Items/
│   │   │   ├── Create.cs
│   │   │   ├── Delete.cs
│   │   │   ├── TrackedItems/
│   │   │   │   ├── Create.cs
│   │   │   │   ├── Find.cs
│   │   │   │   ├── TrackedInventoryTest.cs
│   │   │   │   ├── Update.cs
│   │   │   │   └── Using_tracked_items.cs
│   │   │   └── Update.cs
│   │   ├── Journals/
│   │   │   └── Find.cs
│   │   ├── LinkedTransactions/
│   │   │   ├── Create.cs
│   │   │   ├── Delete.cs
│   │   │   ├── Find.cs
│   │   │   ├── LinkedTransactionTest.cs
│   │   │   └── Update.cs
│   │   ├── ManualJournals/
│   │   │   ├── Create.cs
│   │   │   ├── Find.cs
│   │   │   ├── ManualJournalsTest.cs
│   │   │   └── Update.cs
│   │   ├── Organisation/
│   │   │   └── Find.cs
│   │   ├── Overpayments/
│   │   │   └── Find.cs
│   │   ├── Payments/
│   │   │   ├── Create.cs
│   │   │   ├── CreateForeignCurrency.cs
│   │   │   ├── Delete.cs
│   │   │   ├── Find.cs
│   │   │   └── PaymentsTest.cs
│   │   ├── Pdf/
│   │   │   └── Get.cs
│   │   ├── Prepayments/
│   │   │   └── Find.cs
│   │   ├── PurchaseOrders/
│   │   │   ├── Create.cs
│   │   │   ├── Find.cs
│   │   │   └── Update.cs
│   │   ├── Receipts/
│   │   │   ├── Create.cs
│   │   │   ├── ReceiptTest.cs
│   │   │   └── Update.cs
│   │   ├── Reports/
│   │   │   └── Find.cs
│   │   ├── Setup/
│   │   │   └── Create.cs
│   │   ├── TaxRates/
│   │   │   ├── Create.cs
│   │   │   ├── TaxRateTest.cs
│   │   │   └── Update.cs
│   │   └── TrackingCategories/
│   │       ├── AddTrackingOption.cs
│   │       ├── Adding/
│   │       │   └── CreateTrackingCategories.cs
│   │       ├── ArchiveTrackingCategory.cs
│   │       ├── CreateTrackingCategories.cs
│   │       ├── Delete.cs
│   │       ├── GetTrackingCategories.cs
│   │       ├── GetTrackingCategoriesIncludingArchieved.cs
│   │       ├── Options/
│   │       │   └── AddTrackingOption.cs
│   │       ├── TrackingCategoriesTest.cs
│   │       ├── UpdateTrackingCategory.cs
│   │       └── UpdateTrackingOptions.cs
│   ├── README.md
│   ├── Random.cs
│   ├── Resources/
│   │   └── cert/
│   │       └── public_privatekey.txt
│   ├── Unit/
│   │   ├── Contacts.cs
│   │   ├── ExceptionTests.cs
│   │   ├── FourDecimalPlaces.cs
│   │   ├── QueryStrings.cs
│   │   ├── RateLimiterTest.cs
│   │   ├── SalesTaxBasisTypeTest.cs
│   │   ├── SalesTaxPeriodTypeTest.cs
│   │   ├── SummarizeErrors.cs
│   │   ├── TrackingCategories.cs
│   │   └── UrlEncoder.cs
│   └── packages.config
├── PayrollTests.AU/
│   ├── ApiWrapperTest.cs
│   ├── App.config
│   ├── Integration/
│   │   ├── Employees/
│   │   │   ├── Create.cs
│   │   │   ├── EmployeesTest.cs
│   │   │   ├── Find.cs
│   │   │   └── Update.cs
│   │   ├── LeaveApplications/
│   │   │   ├── Create.cs
│   │   │   ├── Find.cs
│   │   │   └── LeaveApplicationTest.cs
│   │   ├── PayItems/
│   │   │   ├── Create.cs
│   │   │   ├── Find.cs
│   │   │   └── PayItemsTest.cs
│   │   ├── PayrollCalendars/
│   │   │   ├── Create.cs
│   │   │   └── Find.cs
│   │   ├── Payrun/
│   │   │   ├── Create.cs
│   │   │   ├── Find.cs
│   │   │   └── PayrunTest.cs
│   │   ├── Settings/
│   │   │   └── Find.cs
│   │   ├── SuperFundProducts/
│   │   │   └── Find.cs
│   │   ├── SuperFunds/
│   │   │   ├── Create.cs
│   │   │   └── Update.cs
│   │   ├── TimeSheets/
│   │   │   ├── Create.cs
│   │   │   ├── Find.cs
│   │   │   └── TimesheetTest.cs
│   │   └── ValidationErrors/
│   │       └── AUPayrollValidationErrors.cs
│   ├── PayrollTests.AU.csproj
│   ├── Properties/
│   │   └── AssemblyInfo.cs
│   ├── README.md
│   ├── Resources/
│   │   └── cert/
│   │       └── public_privatekey.txt
│   └── packages.config
├── PayrollTests.US/
│   ├── ApiWrapperTest.cs
│   ├── App.config
│   ├── Integration/
│   │   ├── Employees/
│   │   │   ├── Create.cs
│   │   │   ├── EmployeesTest.cs
│   │   │   ├── Find.cs
│   │   │   └── Update.cs
│   │   └── PaySchedules/
│   │       ├── Create.cs
│   │       ├── Find.cs
│   │       └── PaySchedulesTest.cs
│   ├── PayrollTests.US.csproj
│   ├── Properties/
│   │   └── AssemblyInfo.cs
│   ├── README.md
│   ├── Resources/
│   │   └── cert/
│   │       └── public_privatekey.txt
│   └── packages.config
├── README.md
├── UpgradeLog.htm
├── Xero.Api/
│   ├── Common/
│   │   ├── CoreData.cs
│   │   ├── Extensions.cs
│   │   ├── HasUpdatedDate.cs
│   │   ├── IHasAttachment.cs
│   │   ├── IHasId.cs
│   │   ├── IPageableEndpoint.cs
│   │   ├── IXeroReadEndpoint.cs
│   │   ├── MimeTypes.cs
│   │   ├── QueryGenerator.cs
│   │   ├── XeroApi.cs
│   │   ├── XeroReadEndpoint.cs
│   │   ├── XeroRequest.cs
│   │   └── XeroResponse.cs
│   ├── Core/
│   │   ├── Endpoints/
│   │   │   ├── AccountsEndpoint.cs
│   │   │   ├── AllocationEndpoint.cs
│   │   │   ├── AssociationsEndpoint.cs
│   │   │   ├── AttachmentsEndpoint.cs
│   │   │   ├── BankTransactionsEndpoint.cs
│   │   │   ├── BankTransfersEndpoint.cs
│   │   │   ├── Base/
│   │   │   │   ├── FourDecimalPlacesEndpoint.cs
│   │   │   │   ├── IXeroCreateEndpoint.cs
│   │   │   │   ├── IXeroUpdateEndpoint.cs
│   │   │   │   ├── XeroCreateEndpoint.cs
│   │   │   │   └── XeroUpdateEndpoint.cs
│   │   │   ├── BatchPaymentsEndpoint.cs
│   │   │   ├── BrandingThemesEndpoint.cs
│   │   │   ├── ContactGroupEndpoint.cs
│   │   │   ├── ContactsEndpoint.cs
│   │   │   ├── CreditNotesEndpoint.cs
│   │   │   ├── CurrenciesEndpoint.cs
│   │   │   ├── EmployeesEndpoint.cs
│   │   │   ├── ExpenseClaimsEndpoint.cs
│   │   │   ├── FilesEndpoint.cs
│   │   │   ├── FoldersEndpoint.cs
│   │   │   ├── HistoryAndNotesEndpoint.cs
│   │   │   ├── InboxEndpoint.cs
│   │   │   ├── InvoicesEndpoint.cs
│   │   │   ├── ItemsEndpoint.cs
│   │   │   ├── JournalsEndpoint.cs
│   │   │   ├── LinkedTransactionsEndpoint.cs
│   │   │   ├── ManualJournalsEndpoint.cs
│   │   │   ├── OrganisationEndpoint.cs
│   │   │   ├── OverpaymentsEndpoint.cs
│   │   │   ├── PaymentsEndpoint.cs
│   │   │   ├── PdfEndpoint.cs
│   │   │   ├── PrepaymentsEndpoint.cs
│   │   │   ├── PurchaseOrdersEndpoint.cs
│   │   │   ├── ReceiptsEndpoint.cs
│   │   │   ├── RepeatingInvoicesEndpoint.cs
│   │   │   ├── ReportsEndpoint.cs
│   │   │   ├── SetupEndpoint.cs
│   │   │   ├── TaxRatesEndpoint.cs
│   │   │   ├── TrackingCategoriesEndpoint.cs
│   │   │   └── UsersEndpoint.cs
│   │   ├── File/
│   │   │   └── BinaryFile.cs
│   │   ├── IXeroCoreApi.cs
│   │   ├── Model/
│   │   │   ├── Account.cs
│   │   │   ├── Address.cs
│   │   │   ├── Allocation.cs
│   │   │   ├── AllocationBase.cs
│   │   │   ├── Association.cs
│   │   │   ├── Attachment.cs
│   │   │   ├── Balance.cs
│   │   │   ├── Balances.cs
│   │   │   ├── BankTransaction.cs
│   │   │   ├── BankTransfer.cs
│   │   │   ├── BatchPayment.cs
│   │   │   ├── BatchPaymentContactDefaults.cs
│   │   │   ├── BatchPaymentPayment.cs
│   │   │   ├── BrandingTheme.cs
│   │   │   ├── Contact.cs
│   │   │   ├── ContactCisSetting.cs
│   │   │   ├── ContactGroup.cs
│   │   │   ├── ContactPerson.cs
│   │   │   ├── ContactTrackingCategory.cs
│   │   │   ├── CreditNote.cs
│   │   │   ├── CreditNoteAllocation.cs
│   │   │   ├── Currency.cs
│   │   │   ├── Employee.cs
│   │   │   ├── EnumExtensions.cs
│   │   │   ├── ExpenseClaim.cs
│   │   │   ├── ExternalLink.cs
│   │   │   ├── File.cs
│   │   │   ├── FilePage.cs
│   │   │   ├── FilesUser.cs
│   │   │   ├── Folder.cs
│   │   │   ├── HistoryRecord.cs
│   │   │   ├── Invoice.cs
│   │   │   ├── Item.cs
│   │   │   ├── ItemDetails.cs
│   │   │   ├── ItemTracking.cs
│   │   │   ├── ItemTrackingCategory.cs
│   │   │   ├── Journal.cs
│   │   │   ├── Line.cs
│   │   │   ├── LineItem.cs
│   │   │   ├── LinkedTransaction.cs
│   │   │   ├── ManualJournal.cs
│   │   │   ├── OnlineInvoice.cs
│   │   │   ├── Option.cs
│   │   │   ├── Organisation.cs
│   │   │   ├── OrganisationCisSetting.cs
│   │   │   ├── Overpayment.cs
│   │   │   ├── OverpaymentAllocation.cs
│   │   │   ├── Payment.cs
│   │   │   ├── PaymentTerms.cs
│   │   │   ├── Phone.cs
│   │   │   ├── Prepayment.cs
│   │   │   ├── PrepaymentAllocation.cs
│   │   │   ├── PurchaseDetails.cs
│   │   │   ├── PurchaseOrder.cs
│   │   │   ├── Receipt.cs
│   │   │   ├── RepeatingInvoice.cs
│   │   │   ├── Reports/
│   │   │   │   ├── Report.cs
│   │   │   │   ├── ReportAttribute.cs
│   │   │   │   ├── ReportCell.cs
│   │   │   │   ├── ReportCellAttribute.cs
│   │   │   │   ├── ReportField.cs
│   │   │   │   └── ReportRow.cs
│   │   │   ├── SalesDetails.cs
│   │   │   ├── Schedule.cs
│   │   │   ├── Setup/
│   │   │   │   ├── AccountImportResult.cs
│   │   │   │   ├── ContactImportResult.cs
│   │   │   │   ├── ConversionBalance.cs
│   │   │   │   ├── ConversionDate.cs
│   │   │   │   ├── ConversionDetails.cs
│   │   │   │   ├── ImportSummary.cs
│   │   │   │   ├── OrganisationImportResult.cs
│   │   │   │   └── Setup.cs
│   │   │   ├── Status/
│   │   │   │   ├── AccountStatus.cs
│   │   │   │   ├── BankTransactionStatus.cs
│   │   │   │   ├── BatchPaymentStatus.cs
│   │   │   │   ├── ContactStatus.cs
│   │   │   │   ├── EmployeeStatus.cs
│   │   │   │   ├── ExpenseClaimStatus.cs
│   │   │   │   ├── InvoiceStatus.cs
│   │   │   │   ├── LinkedTransactionStatus.cs
│   │   │   │   ├── ManualJournalStatus.cs
│   │   │   │   ├── OrganisationStatus.cs
│   │   │   │   ├── OverpaymentStatus.cs
│   │   │   │   ├── PaymentStatus.cs
│   │   │   │   ├── PrepaymentStatus.cs
│   │   │   │   ├── PurchaseOrderStatus.cs
│   │   │   │   ├── ReceiptStatus.cs
│   │   │   │   ├── TaxRateStatus.cs
│   │   │   │   ├── TrackingCategoryStatus.cs
│   │   │   │   ├── TrackingOptionStatus.cs
│   │   │   │   └── ValidationStatus.cs
│   │   │   ├── TaxComponent.cs
│   │   │   ├── TaxRate.cs
│   │   │   ├── Terms.cs
│   │   │   ├── TrackingCategory.cs
│   │   │   ├── Types/
│   │   │   │   ├── AccountClassType.cs
│   │   │   │   ├── AccountType.cs
│   │   │   │   ├── AddressType.cs
│   │   │   │   ├── AttachmentEndpointType.cs
│   │   │   │   ├── BankAccountType.cs
│   │   │   │   ├── BankTransactionType.cs
│   │   │   │   ├── BatchPaymentType.cs
│   │   │   │   ├── BudgetSummaryTimeframeType.cs
│   │   │   │   ├── CreditNoteType.cs
│   │   │   │   ├── ExternalLinkType.cs
│   │   │   │   ├── HistoryAndNotesEndpointCreateType.cs
│   │   │   │   ├── HistoryAndNotesEndpointRetrieveType.cs
│   │   │   │   ├── InvoiceType.cs
│   │   │   │   ├── LineAmountType.cs
│   │   │   │   ├── LinkedTransactionType.cs
│   │   │   │   ├── NamedReportType.cs
│   │   │   │   ├── ObjectGroupType.cs
│   │   │   │   ├── ObjectType.cs
│   │   │   │   ├── OrganisationClass.cs
│   │   │   │   ├── OrganisationEdition.cs
│   │   │   │   ├── OrganisationType.cs
│   │   │   │   ├── OrganisationVersion.cs
│   │   │   │   ├── OverpaymentType.cs
│   │   │   │   ├── PaymentTermType.cs
│   │   │   │   ├── PaymentType.cs
│   │   │   │   ├── PdfEndpointType.cs
│   │   │   │   ├── PhoneType.cs
│   │   │   │   ├── PrepaymentType.cs
│   │   │   │   ├── ReportRowType.cs
│   │   │   │   ├── ReportTaxType.cs
│   │   │   │   ├── SalesTaxBasisType.cs
│   │   │   │   ├── SalesTaxPeriodType.cs
│   │   │   │   ├── SourceType.cs
│   │   │   │   ├── SystemAccountType.cs
│   │   │   │   ├── UnitType.cs
│   │   │   │   └── UserRole.cs
│   │   │   └── User.cs
│   │   ├── Request/
│   │   │   ├── AccountsRequest.cs
│   │   │   ├── BankTransactionsRequest.cs
│   │   │   ├── BankTransfersRequest.cs
│   │   │   ├── BatchPaymentsRequest.cs
│   │   │   ├── ContactGroupsRequest.cs
│   │   │   ├── ContactsRequest.cs
│   │   │   ├── CreditNotesRequest.cs
│   │   │   ├── CurrenciesRequest.cs
│   │   │   ├── EmployeesRequest.cs
│   │   │   ├── ExpenseClaimsRequest.cs
│   │   │   ├── FilesRequest.cs
│   │   │   ├── HistoryRecordsRequest.cs
│   │   │   ├── InvoicesRequest.cs
│   │   │   ├── ItemsRequest.cs
│   │   │   ├── LinkedTransactionsRequest.cs
│   │   │   ├── ManualJournalsRequest.cs
│   │   │   ├── OnlineInvoicesRequest.cs
│   │   │   ├── PaymentsRequest.cs
│   │   │   ├── PurchaseOrdersRequest.cs
│   │   │   ├── ReceiptsRequest.cs
│   │   │   ├── SetupRequest.cs
│   │   │   ├── TaxRatesRequest.cs
│   │   │   └── TrackingCategoriesRequest.cs
│   │   ├── Response/
│   │   │   ├── AccountsResponse.cs
│   │   │   ├── AttachmentsResponse.cs
│   │   │   ├── BankTransactionsResponse.cs
│   │   │   ├── BankTransfersResponse.cs
│   │   │   ├── BatchPaymentsResponse.cs
│   │   │   ├── BrandingThemesResponse.cs
│   │   │   ├── ContactCisSettingsResponse.cs
│   │   │   ├── ContactGroupsResponse.cs
│   │   │   ├── ContactsResponse.cs
│   │   │   ├── CreditNotesResponse.cs
│   │   │   ├── CurrenciesResponse.cs
│   │   │   ├── EmployeesResponse.cs
│   │   │   ├── ExpenseClaimsResponse.cs
│   │   │   ├── FilesResponse.cs
│   │   │   ├── FoldersResponse.cs
│   │   │   ├── HistoryRecordsResponse.cs
│   │   │   ├── InboxResponse.cs
│   │   │   ├── InvoicesResponse.cs
│   │   │   ├── ItemsResponse.cs
│   │   │   ├── JournalsResponse.cs
│   │   │   ├── LinkedTransactionsResponse.cs
│   │   │   ├── ManualJournalsResponse.cs
│   │   │   ├── OnlineInvoicesResponse.cs
│   │   │   ├── OptionsResponse.cs
│   │   │   ├── OrganisationCisSettingsResponse.cs
│   │   │   ├── OrganisationResponse.cs
│   │   │   ├── OverpaymentsResponse.cs
│   │   │   ├── PaymentsResponse.cs
│   │   │   ├── PrepaymentsResponse.cs
│   │   │   ├── PurchaseOrdersResponse.cs
│   │   │   ├── ReceiptsResponse.cs
│   │   │   ├── RepeatingInvoicesResponse.cs
│   │   │   ├── ReportsResponse.cs
│   │   │   ├── SetupResponse.cs
│   │   │   ├── TaxRatesResponse.cs
│   │   │   ├── TrackingCategoriesResponse.cs
│   │   │   └── UsersResponse.cs
│   │   └── XeroCoreApi.cs
│   ├── Infrastructure/
│   │   ├── Exceptions/
│   │   │   ├── ApiException.cs
│   │   │   ├── BadRequestException.cs
│   │   │   ├── NotAvailableException.cs
│   │   │   ├── NotFoundException.cs
│   │   │   ├── RateExceededException.cs
│   │   │   ├── UnauthorizedException.cs
│   │   │   ├── ValidationException.cs
│   │   │   └── XeroApiException.cs
│   │   ├── Http/
│   │   │   ├── HttpClient.cs
│   │   │   ├── Response.cs
│   │   │   └── XeroHttpClient.cs
│   │   ├── Interfaces/
│   │   │   ├── IAuthenticationToken.cs
│   │   │   ├── IAuthenticator.cs
│   │   │   ├── IConsumer.cs
│   │   │   ├── IJsonObjectMapper.cs
│   │   │   ├── ITokenStore.cs
│   │   │   ├── IUser.cs
│   │   │   ├── IXeroRequest.cs
│   │   │   ├── IXeroResponse.cs
│   │   │   └── IXmlObjectMapper.cs
│   │   ├── Model/
│   │   │   ├── DataContractBase.cs
│   │   │   ├── ValidationError.cs
│   │   │   └── Warning.cs
│   │   ├── OAuth/
│   │   │   ├── ApiUser.cs
│   │   │   ├── Consumer.cs
│   │   │   ├── OAuthException.cs
│   │   │   ├── OAuthTokens.cs
│   │   │   ├── Signing/
│   │   │   │   ├── HmacSha1Signer.cs
│   │   │   │   └── RsaSha1Signer.cs
│   │   │   ├── Token.cs
│   │   │   └── UnexpectedOauthResponseException.cs
│   │   ├── RateLimiter/
│   │   │   ├── IRateLimiter.cs
│   │   │   └── RateLimiter.cs
│   │   └── ThirdParty/
│   │       ├── Dust/
│   │       │   ├── ConsumerKey.cs
│   │       │   ├── Core/
│   │       │   │   ├── Request.cs
│   │       │   │   ├── SignatureBaseString.cs
│   │       │   │   └── SignatureBaseStringParts/
│   │       │   │       ├── Earl/
│   │       │   │       │   └── EarlPart.cs
│   │       │   │       ├── Parameters/
│   │       │   │       │   ├── Name.cs
│   │       │   │       │   ├── Nonce/
│   │       │   │       │   │   ├── DefaultNonceSequence.cs
│   │       │   │       │   │   └── NonceSequence.cs
│   │       │   │       │   ├── OAuthParameters.cs
│   │       │   │       │   ├── Parameter.cs
│   │       │   │       │   ├── ParameterEncoding.cs
│   │       │   │       │   ├── ParameterPart.cs
│   │       │   │       │   ├── Parameters.cs
│   │       │   │       │   ├── RequestParameters.cs
│   │       │   │       │   └── Timestamp/
│   │       │   │       │       ├── DefaultTimestampSequence.cs
│   │       │   │       │       └── TimestampSequence.cs
│   │       │   │       └── Verb/
│   │       │   │           └── VerbPart.cs
│   │       │   ├── HmacSha1.cs
│   │       │   ├── Http/
│   │       │   │   └── AuthorizationHeader.cs
│   │       │   ├── Lang/
│   │       │   │   └── ObjectExtensions.cs
│   │       │   ├── RsaSha1.cs
│   │       │   └── TokenKey.cs
│   │       ├── HttpUtility/
│   │       │   ├── HttpEncoder.cs
│   │       │   ├── HttpUtility.cs
│   │       │   └── UrlEncoder.cs
│   │       └── ServiceStack.Text/
│   │           ├── AssemblyUtils.cs
│   │           ├── CollectionExtensions.cs
│   │           ├── Common/
│   │           │   ├── DateTimeSerializer.cs
│   │           │   ├── DeserializeArray.cs
│   │           │   ├── DeserializeBuiltin.cs
│   │           │   ├── DeserializeCollection.cs
│   │           │   ├── DeserializeDictionary.cs
│   │           │   ├── DeserializeDynamic.cs
│   │           │   ├── DeserializeKeyValuePair.cs
│   │           │   ├── DeserializeListWithElements.cs
│   │           │   ├── DeserializeSpecializedCollections.cs
│   │           │   ├── DeserializeType.cs
│   │           │   ├── DeserializeTypeRef.cs
│   │           │   ├── DeserializeTypeRefJson.cs
│   │           │   ├── DeserializeTypeRefJsv.cs
│   │           │   ├── DeserializeTypeUtils.cs
│   │           │   ├── ITypeSerializer.cs
│   │           │   ├── JsDelegates.cs
│   │           │   ├── JsReader.cs
│   │           │   ├── JsState.cs
│   │           │   ├── JsWriter.cs
│   │           │   ├── ParseUtils.cs
│   │           │   ├── StaticParseMethod.cs
│   │           │   ├── WriteDictionary.cs
│   │           │   ├── WriteLists.cs
│   │           │   └── WriteType.cs
│   │           ├── Controller/
│   │           │   ├── CommandProcessor.cs
│   │           │   └── PathInfo.cs
│   │           ├── CsvAttribute.cs
│   │           ├── CsvConfig.cs
│   │           ├── CsvSerializer.cs
│   │           ├── CsvStreamExtensions.cs
│   │           ├── CsvWriter.cs
│   │           ├── DateTimeExtensions.cs
│   │           ├── DynamicJson.cs
│   │           ├── DynamicProxy.cs
│   │           ├── Env.cs
│   │           ├── HashSet.cs
│   │           ├── ITracer.cs
│   │           ├── ITypeSerializer.Generic.cs
│   │           ├── JsConfig.cs
│   │           ├── JsConfigScope.cs
│   │           ├── Json/
│   │           │   ├── JsonReader.Generic.cs
│   │           │   ├── JsonTypeSerializer.cs
│   │           │   ├── JsonUtils.cs
│   │           │   └── JsonWriter.Generic.cs
│   │           ├── JsonObject.cs
│   │           ├── JsonSerializer.Generic.cs
│   │           ├── JsonSerializer.cs
│   │           ├── Jsv/
│   │           │   ├── JsvDeserializeType.cs
│   │           │   ├── JsvReader.Generic.cs
│   │           │   ├── JsvSerializer.Generic.cs
│   │           │   ├── JsvTypeSerializer.cs
│   │           │   └── JsvWriter.Generic.cs
│   │           ├── JsvFormatter.cs
│   │           ├── ListExtensions.cs
│   │           ├── MapExtensions.cs
│   │           ├── Marc/
│   │           │   ├── Link.cs
│   │           │   ├── ObjectAccessor.cs
│   │           │   └── TypeAccessor.cs
│   │           ├── QueryStringSerializer.cs
│   │           ├── Reflection/
│   │           │   └── StaticAccessors.cs
│   │           ├── ReflectionExtensions.cs
│   │           ├── StreamExtensions.cs
│   │           ├── StringExtensions.cs
│   │           ├── Support/
│   │           │   ├── AssemblyTypeDefinition.cs
│   │           │   ├── DoubleConverter.cs
│   │           │   └── TypePair.cs
│   │           ├── SystemTime.cs
│   │           ├── TextExtensions.cs
│   │           ├── Tracer.cs
│   │           ├── TranslateListWithElements.cs
│   │           ├── TypeConfig.cs
│   │           ├── TypeSerializer.Generic.cs
│   │           ├── TypeSerializer.cs
│   │           ├── WebRequestExtensions.cs
│   │           └── XmlSerializer.cs
│   ├── Payroll/
│   │   ├── America/
│   │   │   ├── Endpoints/
│   │   │   │   ├── EmployeesEndpoint.cs
│   │   │   │   ├── PayItemsEndpoint.cs
│   │   │   │   ├── PayRunsEndpoint.cs
│   │   │   │   ├── PaySchedulesEndpoint.cs
│   │   │   │   ├── PayStubsEndpoint.cs
│   │   │   │   ├── SettingsEndpoint.cs
│   │   │   │   ├── TimesheetsEndpoint.cs
│   │   │   │   └── WorkLocationsEndpoint.cs
│   │   │   ├── Model/
│   │   │   │   ├── Account.cs
│   │   │   │   ├── Address.cs
│   │   │   │   ├── BankAccount.cs
│   │   │   │   ├── BenefitLine.cs
│   │   │   │   ├── BenefitType.cs
│   │   │   │   ├── DeductionLine.cs
│   │   │   │   ├── DeductionType.cs
│   │   │   │   ├── EarningsLine.cs
│   │   │   │   ├── EarningsType.cs
│   │   │   │   ├── Employee.cs
│   │   │   │   ├── HomeAddress.cs
│   │   │   │   ├── MailingAddress.cs
│   │   │   │   ├── OpeningBalances.cs
│   │   │   │   ├── PayItems.cs
│   │   │   │   ├── PayRun.cs
│   │   │   │   ├── PaySchedule.cs
│   │   │   │   ├── PayStub.cs
│   │   │   │   ├── PayTemplate.cs
│   │   │   │   ├── PaymentMethod.cs
│   │   │   │   ├── ReimbursementLine.cs
│   │   │   │   ├── ReimbursementType.cs
│   │   │   │   ├── SalaryAndWage.cs
│   │   │   │   ├── Settings.cs
│   │   │   │   ├── TimeOffType.cs
│   │   │   │   ├── Timesheet.cs
│   │   │   │   ├── TimesheetLine.cs
│   │   │   │   ├── Types/
│   │   │   │   │   ├── AccountType.cs
│   │   │   │   │   ├── BenefitCategoryType.cs
│   │   │   │   │   ├── CalculationType.cs
│   │   │   │   │   ├── DeductionCategoryType.cs
│   │   │   │   │   ├── EarningsCategoryType.cs
│   │   │   │   │   ├── EmploymentBasisType.cs
│   │   │   │   │   ├── PaymentMethodType.cs
│   │   │   │   │   ├── RateType.cs
│   │   │   │   │   ├── SalaryWagesType.cs
│   │   │   │   │   ├── ScheduleType.cs
│   │   │   │   │   ├── State.cs
│   │   │   │   │   ├── TimeOffCategoryType.cs
│   │   │   │   │   └── UnitType.cs
│   │   │   │   └── WorkLocation.cs
│   │   │   ├── Request/
│   │   │   │   ├── EmployeesRequest.cs
│   │   │   │   ├── PayItemsRequest.cs
│   │   │   │   ├── PayRunsRequest.cs
│   │   │   │   ├── PaySchedulesRequest.cs
│   │   │   │   ├── PayStubsRequest.cs
│   │   │   │   ├── TimesheetsRequest.cs
│   │   │   │   └── WorkLocationsRequest.cs
│   │   │   └── Response/
│   │   │       ├── EmployeesResponse.cs
│   │   │       ├── PayItemsResponse.cs
│   │   │       ├── PayRunsResponse.cs
│   │   │       ├── PaySchedulesResponse.cs
│   │   │       ├── PayStubsResponse.cs
│   │   │       ├── SettingsResponse.cs
│   │   │       ├── TimesheetsResponse.cs
│   │   │       └── WorkLocationsResponse.cs
│   │   ├── AmericanPayroll.cs
│   │   ├── Australia/
│   │   │   ├── Endpoints/
│   │   │   │   ├── EmployeesEndpoint.cs
│   │   │   │   ├── LeaveApplicationsEndpoint.cs
│   │   │   │   ├── PayItemsEndpoint.cs
│   │   │   │   ├── PayRunsEndpoint.cs
│   │   │   │   ├── PayrollCalendarsEndpoint.cs
│   │   │   │   ├── PayslipsEndpoint.cs
│   │   │   │   ├── SettingsEndpoint.cs
│   │   │   │   ├── SuperFundProductsEndpoint.cs
│   │   │   │   ├── SuperFundsEndpoint.cs
│   │   │   │   └── TimesheetsEndpoint.cs
│   │   │   ├── Model/
│   │   │   │   ├── Account.cs
│   │   │   │   ├── BankAccount.cs
│   │   │   │   ├── DeductionLine.cs
│   │   │   │   ├── DeductionType.cs
│   │   │   │   ├── EarningsLine.cs
│   │   │   │   ├── EarningsRate.cs
│   │   │   │   ├── Employee.cs
│   │   │   │   ├── HomeAddress.cs
│   │   │   │   ├── LeaveAccuralLine.cs
│   │   │   │   ├── LeaveApplication.cs
│   │   │   │   ├── LeaveBalance.cs
│   │   │   │   ├── LeaveEarningsLine.cs
│   │   │   │   ├── LeaveLine.cs
│   │   │   │   ├── LeavePeriod.cs
│   │   │   │   ├── LeaveType.cs
│   │   │   │   ├── OpeningBalances.cs
│   │   │   │   ├── PayItems.cs
│   │   │   │   ├── PayRun.cs
│   │   │   │   ├── PayTemplate.cs
│   │   │   │   ├── PayrollCalendar.cs
│   │   │   │   ├── Payslip.cs
│   │   │   │   ├── PayslipEarningsLine.cs
│   │   │   │   ├── ReimbursementLine.cs
│   │   │   │   ├── ReimbursementType.cs
│   │   │   │   ├── Settings.cs
│   │   │   │   ├── Status/
│   │   │   │   │   ├── EmploymentStatus.cs
│   │   │   │   │   ├── LeavePeriodStatus.cs
│   │   │   │   │   ├── ResidencyStatusType.cs
│   │   │   │   │   └── TimesheetStatus.cs
│   │   │   │   ├── SuperFund.cs
│   │   │   │   ├── SuperFundProduct.cs
│   │   │   │   ├── SuperLine.cs
│   │   │   │   ├── SuperMembership.cs
│   │   │   │   ├── SuperannuationLine.cs
│   │   │   │   ├── TaxDeclaration.cs
│   │   │   │   ├── TaxLine.cs
│   │   │   │   ├── Timesheet.cs
│   │   │   │   ├── TimesheetEarningsLine.cs
│   │   │   │   ├── TimesheetLine.cs
│   │   │   │   └── Types/
│   │   │   │       ├── CalendarType.cs
│   │   │   │       ├── DeductionCalculationType.cs
│   │   │   │       ├── EarningsRateCalculationType.cs
│   │   │   │       ├── EarningsType.cs
│   │   │   │       ├── EmploymentBasisType.cs
│   │   │   │       ├── LeaveCalculationType.cs
│   │   │   │       ├── LeaveContributionType.cs
│   │   │   │       ├── PaymentFrequencyType.cs
│   │   │   │       ├── RateType.cs
│   │   │   │       ├── State.cs
│   │   │   │       ├── SuperannuationCalculationType.cs
│   │   │   │       ├── SuperannuationContributionType.cs
│   │   │   │       ├── SuperfundType.cs
│   │   │   │       └── TaxFileNumberExemptionType.cs
│   │   │   ├── Request/
│   │   │   │   ├── EmployeesRequest.cs
│   │   │   │   ├── LeaveApplicationsRequest.cs
│   │   │   │   ├── PayItemsRequest.cs
│   │   │   │   ├── PayRunsRequest.cs
│   │   │   │   ├── PayrollCalendarsRequest.cs
│   │   │   │   ├── PayslipRequest.cs
│   │   │   │   ├── SuperFundsRequest.cs
│   │   │   │   └── TimesheetsRequest.cs
│   │   │   └── Response/
│   │   │       ├── EmployeesResponse.cs
│   │   │       ├── LeaveApplicationsResponse.cs
│   │   │       ├── PayItemsResponse.cs
│   │   │       ├── PayRunsResponse.cs
│   │   │       ├── PayrollCalendarResponse.cs
│   │   │       ├── PayslipsResponse.cs
│   │   │       ├── SettingsResponse.cs
│   │   │       ├── SuperFundProductsResponse.cs
│   │   │       ├── SuperFundsResponse.cs
│   │   │       └── TimesheetsResponse.cs
│   │   ├── AustralianPayroll.cs
│   │   └── Common/
│   │       ├── Model/
│   │       │   ├── Account.cs
│   │       │   ├── NumberOfUnits.cs
│   │       │   ├── PayNotice.cs
│   │       │   ├── PayRun.cs
│   │       │   ├── PayrollSettingsTrackingCategories.cs
│   │       │   ├── Status/
│   │       │   │   └── PayRunStatus.cs
│   │       │   └── TrackingCategory.cs
│   │       ├── PayrollApi.cs
│   │       └── PayrollEndpoint.cs
│   ├── Properties/
│   │   └── AssemblyInfo.cs
│   ├── README.md
│   ├── Serialization/
│   │   └── DefaultMapper.cs
│   ├── Xero.Api.csproj
│   └── packages.config
├── Xero.Api.Example.Applications/
│   ├── Partner/
│   │   ├── AmericanPayroll.cs
│   │   ├── AustralianPayroll.cs
│   │   ├── Core.cs
│   │   ├── PartnerAuthenticator.cs
│   │   ├── PartnerMvcAuthenticator.cs
│   │   └── Settings.cs
│   ├── Private/
│   │   ├── AmericanPayroll.cs
│   │   ├── AustralianPayroll.cs
│   │   ├── Core.cs
│   │   ├── PrivateAuthenticator.cs
│   │   └── Settings.cs
│   ├── Properties/
│   │   └── AssemblyInfo.cs
│   ├── Public/
│   │   ├── AmericanPayroll.cs
│   │   ├── AustralianPayroll.cs
│   │   ├── Core.cs
│   │   ├── IMvcAuthenticator.cs
│   │   ├── PublicAuthenticator.cs
│   │   ├── PublicMvcAuthenticator.cs
│   │   ├── RenewTokenException.cs
│   │   └── Settings.cs
│   ├── TokenStoreAuthenticator.cs
│   └── Xero.Api.Example.Applications.csproj
├── Xero.Api.Example.Counts/
│   ├── App.config
│   ├── Lister.cs
│   ├── Program.cs
│   ├── Properties/
│   │   └── AssemblyInfo.cs
│   ├── README.md
│   ├── Resources/
│   │   └── cert/
│   │       └── public_privatekey.txt
│   └── Xero.Api.Example.Counts.csproj
├── Xero.Api.Example.Creation/
│   ├── ApiDataCreation.cs
│   ├── App.config
│   ├── Creator/
│   │   ├── Creator.cs
│   │   ├── Name.cs
│   │   └── PlaceName.cs
│   ├── Program.cs
│   ├── Properties/
│   │   └── AssemblyInfo.cs
│   ├── README.md
│   ├── Resources/
│   │   └── cert/
│   │       └── public_privatekey.txt
│   ├── Xero.Api.Example.Creation.csproj
│   └── data/
│       ├── Descriptions.txt
│       ├── Given.txt
│       ├── Surnames.txt
│       ├── place_index.txt
│       └── street_index.txt
├── Xero.Api.Example.MVC/
│   ├── App_Start/
│   │   ├── FilterConfig.cs
│   │   ├── RouteConfig.cs
│   │   └── WebApiConfig.cs
│   ├── Content/
│   │   └── Site.css
│   ├── Controllers/
│   │   ├── HomeController.cs
│   │   └── OrganisationController.cs
│   ├── Global.asax
│   ├── Global.asax.cs
│   ├── Helpers/
│   │   └── XeroApiHelper.cs
│   ├── Properties/
│   │   └── AssemblyInfo.cs
│   ├── README.md
│   ├── Stores/
│   │   ├── MemoryAccessTokenStore.cs
│   │   └── MemoryRequestTokenStore.cs
│   ├── Views/
│   │   ├── Home/
│   │   │   ├── Authorize.cshtml
│   │   │   ├── Connect.cshtml
│   │   │   ├── Index.cshtml
│   │   │   └── NoAuthorized.cshtml
│   │   ├── Organisation/
│   │   │   └── Index.cshtml
│   │   ├── Shared/
│   │   │   ├── Error.cshtml
│   │   │   └── _Layout.cshtml
│   │   ├── Web.config
│   │   └── _ViewStart.cshtml
│   ├── Web.Debug.config
│   ├── Web.Release.config
│   ├── Web.config
│   ├── Xero.Api.Example.MVC.csproj
│   ├── Xero.Api.Example.MVC.sln
│   └── packages.config
├── Xero.Api.Example.Mocks/
│   ├── App.config
│   ├── ContactManagerAndTests/
│   │   ├── ContactManager.cs
│   │   └── ContactManagerTests.cs
│   ├── Lister.cs
│   ├── Program.cs
│   ├── Properties/
│   │   └── AssemblyInfo.cs
│   ├── Xero.Api.Example.Mocks.csproj
│   └── packages.config
├── Xero.Api.Example.TokenStores/
│   ├── Dapper/
│   │   └── Dapper.cs
│   ├── MemoryTokenStore.cs
│   ├── Properties/
│   │   └── AssemblyInfo.cs
│   ├── SqliteTokenStore.cs
│   ├── Xero.Api.Example.TokenStores.csproj
│   ├── app.config
│   └── packages.config
├── Xero.Api.sln
├── build.bat
├── minimal.nuspec
└── nuget.nuspec

================================================
FILE CONTENTS
================================================

================================================
FILE: .gitignore
================================================
################################################################################
# This .gitignore file was automatically created by Microsoft(R) Visual Studio.
################################################################################

/packages
*/bin/Debug
*/obj/Debug
*/bin
_ReSharper*
*.user
*.suo
*.pfx
*.pem
*.cer
*.user
*.aps
*.pch
*.vspscc
*_i.c
*_p.c
*.ncb
*.suo
*.bak
*.cache
*.ilk
*.log
[Bb]in
[Dd]ebug*/
*.sbr
obj/
[Rr]elease*/
_ReSharper*/
[Pp]ackages/
out/
*.orig

*.nupkg
/.vs
*.DotSettings
*.lnk

================================================
FILE: CoreTests/ApiWrapperTest.cs
================================================
using System.Linq;
using Xero.Api.Core;
using Xero.Api.Core.Model;

namespace CoreTests
{
    public class ApiWrapperTest
    {
        public ApiWrapperTest()
        {
            System.Net.ServicePointManager.SecurityProtocol = System.Net.SecurityProtocolType.Tls12;
        }

        private IXeroCoreApi _api;

        protected Account BankAccount { get; set; }
        protected Account Account { get; set; }
        
        protected IXeroCoreApi Api
        {
            get { return _api ?? (_api = CreateCoreApi()); }
        }

        private static IXeroCoreApi CreateCoreApi()
        {
            return new Xero.Api.Example.Applications.Private.Core
            {
                UserAgent = "Xero Api - Integration tests"
            };
        }

        protected void SetUp()
        {
            BankAccount = Given_a_bank_account();
            Account = Given_an_account();
        }

        protected Account Given_a_bank_account()
        {
            return Api.Accounts.Where("Type == \"BANK\"").Find().First();
        }

        protected Account Given_an_account()
        {
            return Api.Accounts.Where("Type != \"BANK\"").Find().First();
        }
    }
}


================================================
FILE: CoreTests/App.config
================================================
<?xml version="1.0" encoding="utf-8"?>
<configuration>
  <startup>
    <supportedRuntime version="v4.0" sku=".NETFramework,Version=v4.5.1"/>
  </startup>

  <appSettings>
    <add key="BaseUrl" value="https://api.xero.com"/>
    <add key="ConsumerKey" value="MEQS3OLPBG4DKNI52N9U8Z5VYEXXXX"/>
    <add key="ConsumerSecret" value="6FJIDKHKKMTNOMR8EVYGKXYIXXXXXX"/>
    <add key="CallbackUrl" value="localhost"/>
    <add key="SigningCertificate" value="..\..\resources\cert\public_privatekey.pfx"/>
    <add key="SigningCertificatePassword" value=""/>
  </appSettings>
</configuration>

================================================
FILE: CoreTests/CoreTests.csproj
================================================
<?xml version="1.0" encoding="utf-8"?>
<Project ToolsVersion="12.0" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
  <Import Project="$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props" Condition="Exists('$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props')" />
  <PropertyGroup>
    <Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
    <Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
    <ProjectGuid>{6E24F214-40CC-4891-8028-A068CD7CD4BD}</ProjectGuid>
    <OutputType>Library</OutputType>
    <AppDesignerFolder>Properties</AppDesignerFolder>
    <RootNamespace>CoreTests</RootNamespace>
    <AssemblyName>CoreTests</AssemblyName>
    <TargetFrameworkVersion>v4.5.1</TargetFrameworkVersion>
    <FileAlignment>512</FileAlignment>
    <SolutionDir Condition="$(SolutionDir) == '' Or $(SolutionDir) == '*Undefined*'">..\</SolutionDir>
    <TargetFrameworkProfile />
  </PropertyGroup>
  <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
    <PlatformTarget>AnyCPU</PlatformTarget>
    <DebugSymbols>true</DebugSymbols>
    <DebugType>full</DebugType>
    <Optimize>false</Optimize>
    <OutputPath>bin\Debug\</OutputPath>
    <DefineConstants>DEBUG;TRACE</DefineConstants>
    <ErrorReport>prompt</ErrorReport>
    <WarningLevel>4</WarningLevel>
    <LangVersion>5</LangVersion>
    <Prefer32Bit>false</Prefer32Bit>
  </PropertyGroup>
  <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">
    <PlatformTarget>AnyCPU</PlatformTarget>
    <DebugType>pdbonly</DebugType>
    <Optimize>true</Optimize>
    <OutputPath>bin\Release\</OutputPath>
    <DefineConstants>TRACE</DefineConstants>
    <ErrorReport>prompt</ErrorReport>
    <WarningLevel>4</WarningLevel>
    <Prefer32Bit>false</Prefer32Bit>
  </PropertyGroup>
  <PropertyGroup>
    <StartupObject />
  </PropertyGroup>
  <ItemGroup>
    <Content Include="Resources\cert\public_privatekey.txt" />
    <Content Include="Resources\images\connect_xero_button_blue - Copy.png">
      <CopyToOutputDirectory>Always</CopyToOutputDirectory>
    </Content>
    <Content Include="Resources\images\connect_xero_button_blue.png">
      <CopyToOutputDirectory>Always</CopyToOutputDirectory>
    </Content>
    <None Include="App.config">
      <SubType>Designer</SubType>
    </None>
    <None Include="packages.config" />
    <None Include="README.md" />
  </ItemGroup>
  <ItemGroup>
    <Reference Include="nunit.core, Version=2.6.4.14350, Culture=neutral, PublicKeyToken=96d09a1eb7f44a77, processorArchitecture=MSIL">
      <HintPath>..\packages\NUnitTestAdapter.2.0.0\lib\nunit.core.dll</HintPath>
      <Private>False</Private>
    </Reference>
    <Reference Include="nunit.core.interfaces, Version=2.6.4.14350, Culture=neutral, PublicKeyToken=96d09a1eb7f44a77, processorArchitecture=MSIL">
      <HintPath>..\packages\NUnitTestAdapter.2.0.0\lib\nunit.core.interfaces.dll</HintPath>
      <Private>False</Private>
    </Reference>
    <Reference Include="nunit.framework">
      <HintPath>..\packages\NUnit.2.6.3\lib\nunit.framework.dll</HintPath>
    </Reference>
    <Reference Include="nunit.util, Version=2.6.4.14350, Culture=neutral, PublicKeyToken=96d09a1eb7f44a77, processorArchitecture=MSIL">
      <HintPath>..\packages\NUnitTestAdapter.2.0.0\lib\nunit.util.dll</HintPath>
      <Private>False</Private>
    </Reference>
    <Reference Include="NUnit.VisualStudio.TestAdapter, Version=2.0.0.0, Culture=neutral, PublicKeyToken=4cb40d35494691ac, processorArchitecture=MSIL">
      <HintPath>..\packages\NUnitTestAdapter.2.0.0\lib\NUnit.VisualStudio.TestAdapter.dll</HintPath>
      <Private>False</Private>
    </Reference>
    <Reference Include="System" />
  </ItemGroup>
  <ItemGroup>
    <Compile Include="Integration\Accounts\Update.cs" />
    <Compile Include="Integration\Accounts\Find.cs" />
    <Compile Include="Integration\Allocations\Add.cs" />
    <Compile Include="Integration\BankTransactions\BankTransactionTest.cs" />
    <Compile Include="Integration\BankTransactions\Create.cs" />
    <Compile Include="Integration\BankTransactions\Find.cs" />
    <Compile Include="Integration\BankTransactions\Update.cs" />
    <Compile Include="Integration\BankTransfers\BankTransfersTest.cs" />
    <Compile Include="Integration\BankTransfers\Create.cs" />
    <Compile Include="Integration\BankTransfers\Find.cs" />
    <Compile Include="Integration\BatchPayment\Create.cs" />
    <Compile Include="Integration\BatchPayment\BatchPaymentsTest.cs" />
    <Compile Include="Integration\ContactGroups\Add_Contact.cs" />
    <Compile Include="Integration\ContactGroups\ContactGroupsTest.cs" />
    <Compile Include="Integration\ContactGroups\Create.cs" />
    <Compile Include="Integration\ContactGroups\Delete.cs" />
    <Compile Include="Integration\ContactGroups\Find.cs" />
    <Compile Include="Integration\ContactGroups\Remove_Contact.cs" />
    <Compile Include="Integration\ContactGroups\Update.cs" />
    <Compile Include="Integration\Contacts\ContactsTest.cs" />
    <Compile Include="Integration\Contacts\Create.cs" />
    <Compile Include="Integration\Contacts\Find.cs" />
    <Compile Include="Integration\Contacts\Update.cs" />
    <Compile Include="Integration\CreditNotes\Create.cs" />
    <Compile Include="Integration\CreditNotes\CreditNotesTest.cs" />
    <Compile Include="Integration\CreditNotes\Find.cs" />
    <Compile Include="Integration\CreditNotes\Update.cs" />
    <Compile Include="Integration\ExpenseClaims\ExpenseClaimTest.cs" />
    <Compile Include="Integration\ExpenseClaims\Create.cs" />
    <Compile Include="Integration\ExpenseClaims\Update.cs" />
    <Compile Include="Integration\Files\Associations\AssociationTest.cs" />
    <Compile Include="Integration\Files\Folders\AddFolderTest.cs" />
    <Compile Include="Integration\Files\Inbox\InboxTest.cs" />
    <Compile Include="Integration\Files\Support\DataItem.cs" />
    <Compile Include="Integration\Files\Support\DiskFile.cs" />
    <Compile Include="Integration\Files\Support\File.cs" />
    <Compile Include="Integration\Files\Support\FilesTest.cs" />
    <Compile Include="Integration\Files\Files\AddFileTest.cs" />
    <Compile Include="Integration\HistoryAndNotes\CreateNotes.cs" />
    <Compile Include="Integration\HistoryAndNotes\Find.cs" />
    <Compile Include="Integration\HistoryAndNotes\HistoryAndNotesTest.cs" />
    <Compile Include="Integration\Invoices\Find.cs" />
    <Compile Include="Integration\Invoices\InvoicesTest.cs" />
    <Compile Include="Integration\Invoices\OnlineInvoiceUrl.cs" />
    <Compile Include="Integration\Invoices\SummarizeErrors.cs" />
    <Compile Include="Integration\Items\Create.cs" />
    <Compile Include="Integration\Items\TrackedItems\Create.cs" />
    <Compile Include="Integration\Items\TrackedItems\Find.cs" />
    <Compile Include="Integration\Items\TrackedItems\TrackedInventoryTest.cs" />
    <Compile Include="Integration\Items\TrackedItems\Update.cs" />
    <Compile Include="Integration\Items\TrackedItems\Using_tracked_items.cs" />
    <Compile Include="Integration\Items\Delete.cs" />
    <Compile Include="Integration\Items\Update.cs" />
    <Compile Include="Integration\Journals\Find.cs" />
    <Compile Include="Integration\LinkedTransactions\Create.cs" />
    <Compile Include="Integration\LinkedTransactions\Delete.cs" />
    <Compile Include="Integration\LinkedTransactions\Find.cs" />
    <Compile Include="Integration\LinkedTransactions\LinkedTransactionTest.cs" />
    <Compile Include="Integration\LinkedTransactions\Update.cs" />
    <Compile Include="Integration\ManualJournals\Create.cs" />
    <Compile Include="Integration\ManualJournals\Find.cs" />
    <Compile Include="Integration\ManualJournals\ManualJournalsTest.cs" />
    <Compile Include="Integration\ManualJournals\Update.cs" />
    <Compile Include="Integration\Organisation\Find.cs" />
    <Compile Include="Integration\Payments\Create.cs" />
    <Compile Include="Integration\Payments\CreateForeignCurrency.cs" />
    <Compile Include="Integration\Payments\Delete.cs" />
    <Compile Include="Integration\Payments\Find.cs" />
    <Compile Include="Integration\Payments\PaymentsTest.cs" />
    <Compile Include="Integration\Pdf\Get.cs" />
    <Compile Include="Integration\Overpayments\Find.cs" />
    <Compile Include="Integration\Prepayments\Find.cs" />
    <Compile Include="Integration\PurchaseOrders\Create.cs" />
    <Compile Include="Integration\PurchaseOrders\Find.cs" />
    <Compile Include="Integration\PurchaseOrders\Update.cs" />
    <Compile Include="Integration\Receipts\Create.cs" />
    <Compile Include="Integration\Receipts\Update.cs" />
    <Compile Include="Integration\Receipts\ReceiptTest.cs" />
    <Compile Include="Integration\Reports\Find.cs" />
    <Compile Include="Integration\Setup\Create.cs" />
    <Compile Include="Integration\TaxRates\Update.cs" />
    <Compile Include="Integration\TaxRates\TaxRateTest.cs" />
    <Compile Include="Integration\TrackingCategories\Delete.cs" />
    <Compile Include="Integration\TrackingCategories\GetTrackingCategoriesIncludingArchieved.cs" />
    <Compile Include="Integration\TrackingCategories\ArchiveTrackingCategory.cs" />
    <Compile Include="Integration\TrackingCategories\UpdateTrackingOptions.cs" />
    <Compile Include="Integration\TrackingCategories\GetTrackingCategories.cs" />
    <Compile Include="Integration\TrackingCategories\UpdateTrackingCategory.cs" />
    <Compile Include="Integration\TrackingCategories\AddTrackingOption.cs" />
    <Compile Include="Integration\TrackingCategories\CreateTrackingCategories.cs" />
    <Compile Include="Integration\TrackingCategories\TrackingCategoriesTest.cs" />
    <Compile Include="Random.cs" />
    <Compile Include="Integration\Invoices\Create.cs" />
    <Compile Include="Integration\Accounts\Create.cs" />
    <Compile Include="Integration\General\FindingAllItems.cs" />
    <Compile Include="Integration\Attachments\Attachments.cs" />
    <Compile Include="Integration\General\Errors.cs" />
    <Compile Include="Integration\TaxRates\Create.cs" />
    <Compile Include="Unit\ExceptionTests.cs" />
    <Compile Include="Unit\RateLimiterTest.cs" />
    <Compile Include="Unit\SummarizeErrors.cs" />
    <Compile Include="Unit\UrlEncoder.cs" />
    <Compile Include="Unit\Contacts.cs" />
    <Compile Include="Unit\FourDecimalPlaces.cs" />
    <Compile Include="Unit\QueryStrings.cs" />
    <Compile Include="ApiWrapperTest.cs" />
    <Compile Include="Integration\General\QueryStrings.cs" />
    <Compile Include="Unit\SalesTaxBasisTypeTest.cs" />
    <Compile Include="Unit\SalesTaxPeriodTypeTest.cs" />
    <Compile Include="Unit\TrackingCategories.cs" />
  </ItemGroup>
  <ItemGroup>
    <ProjectReference Include="..\Xero.Api.Example.Applications\Xero.Api.Example.Applications.csproj">
      <Project>{d799e8cc-0917-465d-80df-f8355201d13f}</Project>
      <Name>Xero.Api.Example.Applications</Name>
    </ProjectReference>
    <ProjectReference Include="..\Xero.Api\Xero.Api.csproj">
      <Project>{2EB9F8BA-CCFF-4B43-99A0-5130D368C78F}</Project>
      <Name>Xero.Api</Name>
    </ProjectReference>
  </ItemGroup>
  <ItemGroup>
    <Service Include="{82A7F48D-3B50-4B1E-B82E-3ADA8210C358}" />
  </ItemGroup>
  <ItemGroup />
  <Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
  <Import Project="$(SolutionDir)\.nuget\NuGet.targets" Condition="Exists('$(SolutionDir)\.nuget\NuGet.targets')" />
  <!-- To modify your build process, add your task inside one of the targets below and uncomment it. 
       Other similar extension points exist, see Microsoft.Common.targets.
  <Target Name="BeforeBuild">
  </Target>
  <Target Name="AfterBuild">
  </Target>
  -->
</Project>

================================================
FILE: CoreTests/Integration/Accounts/Create.cs
================================================
using NUnit.Framework;
using Xero.Api.Core.Model;
using Xero.Api.Core.Model.Types;
using Xero.Api.Infrastructure.Exceptions;

namespace CoreTests.Integration.Accounts
{
    [TestFixture]
    public class Create : ApiWrapperTest
    {
        [Test]
        public void create_account()
        {
            Assert.DoesNotThrow(() => Api.Create(new Account
            {
              Code = Random.GetRandomString(10),
              Type = AccountType.Overheads,
              Description = "Consultant charges",
              Name = "Consultation " + Random.GetRandomString(10)
            }));

        }

        [Test]
        public void create_bank_account()
        {
            Assert.DoesNotThrow(() => Api.Create(new Account
            {
                Code = Random.GetRandomString(10),
                Name = "Cheque " + Random.GetRandomString(10),
                Type = AccountType.Bank,
                BankAccountNumber = "02-3467-474288",
            }));
        }

        [Test]
        public void incorrect_types_are_rejected()
        {
            Assert.Throws<ValidationException>(() => Api.Create(new Account
            {
                Code = Random.GetRandomString(10),
                Type = AccountType.Expense,
                Description = "Income from other sales",
                Name = "Other Sales",
                TaxType = "OUTPUT2"
            }));
        }
    }
}


================================================
FILE: CoreTests/Integration/Accounts/Find.cs
================================================
using System;
using System.Linq;
using System.Runtime.Hosting;
using NUnit.Framework;
using Xero.Api.Core.Model;
using Xero.Api.Core.Model.Types;

namespace CoreTests.Integration.Accounts
{
    [TestFixture]
    public class Find : ApiWrapperTest
    {
        [Test]
        public void find_by_value()
        {
            var type = Api.Accounts
                .Where("Type == \"OVERHEADS\"")
                .Find()
                .ToList().First().Type;

            Assert.AreEqual(AccountType.Overheads, type);
        }

        [Test]
        public void find_by_id()
        {
            var expected = Api.Accounts
                .Where("Type == \"REVENUE\"")
                .Find()
                .First()
                .Id;
          
            var id = Api.Accounts.Find(expected).Id;
            
            Assert.AreEqual(expected, id);
        }

        [Test]
        public void finding_a_non_system_account_has_null_SystemAccount()
        {
            var newNonSystemAccount = Api.Create(new Account
            {
                Code = Random.GetRandomString(10),
                Type = AccountType.OtherIncome,
                Description = "Consultation " + Random.GetRandomString(10),
                Name = "Consultation " + Random.GetRandomString(10)             
            });

            var account = Api.Accounts.Find(newNonSystemAccount.Id);

            Assert.AreEqual(null, account.SystemAccount);
        }

         [Test]
        public void find_accounts_ifmodifiedsince()
        {
            var newNonSystemAccount = Api.Create(new Account
            {
                Code = Random.GetRandomString(10),
                Type = AccountType.OtherIncome,
                Description = "Consultation " + Random.GetRandomString(10),
                Name = "Consultation " + Random.GetRandomString(10)
            });

            var accounts = Api.Accounts
                .ModifiedSince(DateTime.Now.AddMinutes(-1))
                .Find();

            Assert.True(accounts.Any());
        }
    }
}


================================================
FILE: CoreTests/Integration/Accounts/Update.cs
================================================
using System;
using NUnit.Framework;
using Xero.Api.Core.Model;
using Xero.Api.Core.Model.Status;
using Xero.Api.Core.Model.Types;

namespace CoreTests.Integration.Accounts
{
    public class Update : ApiWrapperTest
    {
        [Test]
        public void Update_account()
        {
            var expectedDescription = "Updated Account" + Guid.NewGuid();

            var account = CreateAccount();

            account.Description = expectedDescription;

            Api.Accounts.Update(account);

            var updated = Api.Accounts.Find(account.Id);

            Assert.True(updated.Description == expectedDescription);
        }


        [Test]
        public void Archive_account()
        {
            var account = CreateAccount();

            Api.Accounts.Update(new Account
            {
                Id = account.Id,
                Status = AccountStatus.Archived
            });

            var updated = Api.Accounts.Find(account.Id);

            Assert.True(updated.Status == AccountStatus.Archived);
        }

        private Account CreateAccount()
        {
            var code = "1234" + Guid.NewGuid();

            return Api.Accounts.Create(new Account
            {
                Code = code.Substring(0, 10),
                Name = "New Account " + Guid.NewGuid(),
                Type = AccountType.Sales
            });
        }

    }
}


================================================
FILE: CoreTests/Integration/Allocations/Add.cs
================================================
using System;
using System.Linq;
using CoreTests.Integration.Invoices;
using NUnit.Framework;
using Xero.Api.Core.Model;
using Xero.Api.Core.Model.Types;

namespace CoreTests.Integration.Allocations
{
    [TestFixture]
    public class Add : ApiWrapperTest
    {
        [Test]
        public void allocation_to_invoice()
        {
            var creditNote = new CreditNotes.CreditNotesTest().Given_an_authorised_creditnote(CreditNoteType.AccountsReceivable);
            var invoice = new Create().Given_an_authorised_invoice(InvoiceType.AccountsReceivable);
            var expected = Math.Min(creditNote.Total.GetValueOrDefault(), invoice.Total.GetValueOrDefault());

            var result = Api.Allocations.Add(new Allocation
                {
                    AppliedAmount = expected,
                    CreditNote = creditNote,
                    Invoice = invoice
                });

            Assert.AreEqual(expected, result.Amount);
            Assert.AreEqual(invoice.Id, result.Invoice.Id);
            Assert.AreEqual(creditNote.Id, result.CreditNote.Id);
        }

        [Test]
        public void allocation_to_invoice_minimal()
        {            
            var creditNote = new CreditNotes.CreditNotesTest().Given_an_authorised_creditnote();
            var invoice = new Create().Given_an_authorised_invoice();
            var expected = Math.Min(creditNote.Total.GetValueOrDefault(), invoice.Total.GetValueOrDefault());

            var result = Api.Allocations.Add(new Allocation
            {
                AppliedAmount = expected,
                CreditNote = new CreditNote { Id = creditNote.Id },
                Invoice = new Invoice { Id = invoice.Id }
            });

            Assert.AreEqual(expected, result.Amount);
            Assert.AreEqual(invoice.Id, result.Invoice.Id);
            Assert.AreEqual(creditNote.Id, result.CreditNote.Id);
        }


        [Test]
        public void allocation_on_creditnote()
        {
            var creditNote = new CreditNotes.CreditNotesTest().Given_an_authorised_creditnote();
            var invoice = new Create().Given_an_authorised_invoice();
            var expected = Math.Min(creditNote.Total.GetValueOrDefault(), invoice.Total.GetValueOrDefault());

            Api.Allocations.Add(new Allocation
            {
                AppliedAmount = expected,
                CreditNote = new CreditNote { Id = creditNote.Id },
                Invoice = new Invoice { Id = invoice.Id }
            });

            creditNote = Api.CreditNotes.Find(creditNote.Id);
            
            Assert.AreEqual(1, creditNote.Allocations.Count);
            Assert.AreEqual(expected, creditNote.Allocations.First().Amount);
        }

        [Test]
        public void allocation_on_prepayment()
        {
            var transaction = new BankTransactions.BankTransactionTest().Given_a_bank_transaction(BankTransactionType.SpendPrepayment);
            var invoice = new Create().Given_an_authorised_invoice();
            var expected = Math.Min(transaction.Total.GetValueOrDefault(), invoice.Total.GetValueOrDefault());

            Api.Allocations.Add(new PrepaymentAllocation
            {
                AppliedAmount = expected,
                Prepayment = new Prepayment { Id = transaction.PrepaymentID.GetValueOrDefault() },
                Invoice = new Invoice { Id = invoice.Id }
            });

            var prepayment = Api.Prepayments.Find(transaction.PrepaymentID.GetValueOrDefault());

            Assert.AreEqual(1, prepayment.Allocations.Count);
            Assert.AreEqual(expected, prepayment.Allocations.First().Amount);
        }

        [Test]
        public void allocation_on_overpayment()
        {
            var transaction = new BankTransactions.BankTransactionTest().Given_an_overpayment(BankTransactionType.SpendOverpayment);
            var invoice = new Create().Given_an_authorised_invoice();
            var expected = Math.Min(transaction.Total.GetValueOrDefault(), invoice.Total.GetValueOrDefault());

            Api.Allocations.Add(new OverpaymentAllocation
            {
                AppliedAmount = expected,
                Overpayment = new Overpayment { Id = transaction.OverpaymentID.GetValueOrDefault() },
                Invoice = new Invoice { Id = invoice.Id }
            });

            var overpayment = Api.Overpayments.Find(transaction.OverpaymentID.GetValueOrDefault());

            Assert.AreEqual(1, overpayment.Allocations.Count);
            Assert.AreEqual(expected, overpayment.Allocations.First().Amount);
        }

        [Test]
        public void Credit_notes_show_up_on_invoices()
        {
            var creditNote = new CreditNotes.CreditNotesTest().Given_an_authorised_creditnote();
            var invoice = new Create().Given_an_authorised_invoice();
            var amount = Math.Min(creditNote.Total.GetValueOrDefault(), invoice.Total.GetValueOrDefault());

            Api.Allocations.Add(new Allocation
            {
                AppliedAmount = amount,
                CreditNote = new CreditNote { Id = creditNote.Id },
                Invoice = new Invoice { Id = invoice.Id }
            });

            invoice = Api.Invoices.Find(invoice.Id);

            Assert.AreEqual(1, invoice.CreditNotes.Count);
            Assert.AreEqual(creditNote.Id, invoice.CreditNotes.First().Id);
            
        }

        [Test]
        public void Prepayments_show_on_invoices()
        {
            var transaction = new BankTransactions.BankTransactionTest().Given_a_bank_transaction(BankTransactionType.SpendPrepayment);
            var invoice = new Create().Given_an_authorised_invoice();
            var expected = Math.Min(transaction.Total.GetValueOrDefault(), invoice.Total.GetValueOrDefault());

            Api.Allocations.Add(new PrepaymentAllocation
            {
                AppliedAmount = expected,
                Prepayment = new Prepayment { Id = transaction.PrepaymentID.GetValueOrDefault() },
                Invoice = new Invoice { Id = invoice.Id }
            });

            invoice = Api.Invoices.Find(invoice.Id);

            Assert.AreEqual(1, invoice.Prepayments.Count);
            Assert.AreEqual(transaction.PrepaymentID.GetValueOrDefault(), invoice.Prepayments.First().Id);
        }

        [Test]
        public void Overpayments_show_on_invoices()
        {
            var transaction = new BankTransactions.BankTransactionTest().Given_an_overpayment(BankTransactionType.SpendOverpayment);
            var invoice = new Create().Given_an_authorised_invoice();
            var expected = Math.Min(transaction.Total.GetValueOrDefault(), invoice.Total.GetValueOrDefault());

            Api.Allocations.Add(new OverpaymentAllocation
            {
                AppliedAmount = expected,
                Overpayment = new Overpayment { Id = transaction.OverpaymentID.GetValueOrDefault() },
                Invoice = new Invoice { Id = invoice.Id }
            });

            invoice = Api.Invoices.Find(invoice.Id);

            Assert.AreEqual(1, invoice.Overpayments.Count);
            Assert.AreEqual(transaction.OverpaymentID.GetValueOrDefault(), invoice.Overpayments.First().Id);
        }
    }
}


================================================
FILE: CoreTests/Integration/Attachments/Attachments.cs
================================================
using System;
using System.Collections.Generic;
using System.IO;
using System.Linq;
using NUnit.Framework;
using Xero.Api.Core.Model;
using Xero.Api.Core.Model.Types;
using File = System.IO.File;

namespace CoreTests.Integration.Attachments
{
    public class Attachments : ApiWrapperTest
    {
        private const string ImagePath = @"resources\images\connect_xero_button_blue.png";
        private const string ImageWithSpacesPath = @"resources\images\connect_xero_button_blue - Copy.png";

        [Test]
        public void adding_attachment_to_invoice()
        {
            var attachment = Given_attachment_on_invoice();
            
            Assert.IsTrue(attachment.Id != Guid.Empty);
        }

        [Test]
        public void listing_attachments()
        {
            var id = Given_invoice_with_no_attachments();
            CreateAttachment(id, AttachmentEndpointType.Invoices);

            var attachments = Api.Attachments.List(AttachmentEndpointType.Invoices, id).ToList();

            Assert.IsTrue(attachments.Any());
            Assert.IsTrue(attachments.First().Id != Guid.Empty);
        }

        [Test]
        public void getting_attachment()
        {
            var id = Given_invoice_with_no_attachments();
            var sourceFile = new FileInfo(ImagePath);

            var attachment = CreateAttachment(id, AttachmentEndpointType.Invoices, sourceFile);

            Assert.AreEqual(attachment.ContentLength, sourceFile.Length);
            Assert.AreEqual(attachment.FileName, sourceFile.Name);
        }

        [Test]
        public void saving_attachments()
        {
            var sourceFile = new FileInfo(ImagePath);

            var id = Given_invoice_with_no_attachments();
            var attachment = CreateAttachment(id, AttachmentEndpointType.Invoices);

            attachment = GetAttachment(id, AttachmentEndpointType.Invoices, attachment.FileName);
            
            var path = Path.GetTempFileName();
            attachment.Save(path);
            
            var targetFile = new FileInfo(path);

            Assert.AreEqual(sourceFile.Length, targetFile.Length);

            // Clean up after yourself!
            File.Delete(path);
        }

        [Test]
        public void saving_attachment_online_invoice_accrec()
        {
            var attachment = Given_attachment_on_invoice(true);
            
            Assert.AreEqual(true, attachment.IncludeOnline);
        }

        [Test]
        public void saving_attachment_online_invoice_accpay()
        {
            var attachment = Given_attachment_on_invoice();

            Assert.AreEqual(false, attachment.IncludeOnline);
        }

        [Test]
        public void saving_attachment_online_credit_note()
        {
            var attachment = Given_attachment_on_credit_note(true);

            Assert.AreEqual(true, attachment.IncludeOnline);
        }

        [Test]
        public void saving_attachment_credit_note()
        {
            var attachment = Given_attachment_on_credit_note();

            Assert.AreEqual(false, attachment.IncludeOnline);
        }

        [Test]
        public void can_save_attachments_with_spaces_in_the_name()
        {
            var attachment = Given_an_attachment_with_a_space_in_the_name_on_an_invoice();

            Assert.AreEqual(false, attachment.IncludeOnline);
        }

        private Attachment Given_attachment_on_invoice(bool includeOnline = false)
        {
            return CreateAttachment(Given_invoice_with_no_attachments(includeOnline), AttachmentEndpointType.Invoices, includeOnline);
        }

        private Attachment Given_an_attachment_with_a_space_in_the_name_on_an_invoice(bool includeOnline = false)
        {
            return CreateAttachment(Given_invoice_with_no_attachments(includeOnline), AttachmentEndpointType.Invoices, new FileInfo(ImageWithSpacesPath), includeOnline);
        }

        private Attachment Given_attachment_on_credit_note(bool includeOnline = false)
        {
            return CreateAttachment(Given_credit_note_with_no_attachments(), AttachmentEndpointType.CreditNotes, includeOnline);
        }


        private Attachment CreateAttachment(Guid id, AttachmentEndpointType type, bool includeOnline = false)
        {
            return CreateAttachment(id, type, new FileInfo(ImagePath), includeOnline);
        }

        private Attachment CreateAttachment(Guid id, AttachmentEndpointType type, FileInfo sourceFile, bool includeOnline = false)
        {
            return Api.Attachments.AddOrReplace(new Attachment(sourceFile), type, id, includeOnline);            
        }

        private Attachment GetAttachment(Guid id, AttachmentEndpointType type, string fileName)
        {
            return Api.Attachments.Get(type, id, fileName);
        }

        private Guid Given_invoice_with_no_attachments(bool accRec = false)
        {
            return Api.Create(new Invoice
            {
                Contact = new Contact { Name = "Richard" },
                Type = accRec ? InvoiceType.AccountsReceivable : InvoiceType.AccountsPayable,
                LineItems = new List<LineItem>
                {
                    new LineItem
                    {
                        Description = "Nothing to see",
                        LineAmount = 100.0m
                    }
                }
            }).Id;
        }

        private Guid Given_credit_note_with_no_attachments()
        {
            return Api.CreditNotes.Create(new CreditNote
            {
                Contact = new Contact {Name = "Apple Computers Ltd"},
                Type = CreditNoteType.AccountsReceivable,
                LineAmountTypes = LineAmountType.Exclusive,
                LineItems = new List<LineItem>
                {
                    new LineItem
                    {
                        AccountCode = "720",
                        Description = "MacBook - White",
                        UnitAmount = 1995.00m
                    }
                }
            }).Id;
        }
    }
}


================================================
FILE: CoreTests/Integration/BankTransactionTest.cs
================================================
using System;
using System.Collections.Generic;
using System.Linq;
using Xero.Api.Core.Model;
using Xero.Api.Core.Model.Types;

namespace Tests.Integration.BankTransactions
{
    public class BankTransactionTest : ApiWrapperTest
    {

        public BankTransaction NewBankTransaction()
        {
            var newBankTransaction = new BankTransaction
            {
                Type = BankTransactionType.Spend,
                Contact = new Contact { Name = "ABC Bank" },
                LineItems = new List<LineItem>
                    {
                        new LineItem
                        {
                            Description = "Yearly Bank Account Fee",
                            Quantity = 1m,
                            UnitAmount = 20.00m,
                            AccountCode = "404"
                        }
                    },
                BankAccount = new Account { Id = FindBankAccountGuid() }
            };

            return newBankTransaction;
        }



        public Guid FindBankAccountGuid()
        {
            var bankAccount = Api.Accounts.Where("Type == \"BANK\"").Find().FirstOrDefault();

            if (bankAccount != null)
            {
                return bankAccount.Id;
            }

            return Guid.Empty;
        }
    }
}


================================================
FILE: CoreTests/Integration/BankTransactions/BankTransactionTest.cs
================================================
using System;
using System.Collections.Generic;
using System.Linq;
using Xero.Api.Core.Model;
using Xero.Api.Core.Model.Types;

namespace CoreTests.Integration.BankTransactions
{
    public class BankTransactionTest : ApiWrapperTest
    {
        public BankTransaction Given_a_bank_transaction()
        {
            return Given_a_bank_transaction(BankTransactionType.Spend);
        }

        public BankTransaction Given_a_bank_transaction(BankTransactionType type)
        {
            return Api.Create(new BankTransaction
            {
                Type = type,
                Contact = new Contact { Name = "ABC Bank" },
                LineItems = new List<LineItem>
                {
                    new LineItem
                    {
                        Description = "Yearly Bank Account Fee",
                        Quantity = 1m,
                        UnitAmount = 20.00m,
                        AccountCode = "404"
                    }
                },
                BankAccount = new Account { Id = FindBankAccountGuid() }
            });
        }

        public BankTransaction Given_an_overpayment(BankTransactionType type)
        {
            return Api.Create(new BankTransaction
            {
                Type = type,
                Contact = new Contact { Name = "ABC Bank" },
                LineAmountTypes = LineAmountType.NoTax,
                LineItems = new List<LineItem>
                {
                    new LineItem
                    {
                        Description = "Yearly Bank Account Fee",
                        UnitAmount = 20.00m,
                        AccountCode = "800"
                    }
                },
                BankAccount = new Account { Id = FindBankAccountGuid() }
            });
        }

        public Guid FindBankAccountGuid()
        {
            var bankAccount = Api.Accounts.Where("Type == \"BANK\"").Find().FirstOrDefault();

            if (bankAccount != null)
            {
                return bankAccount.Id;
            }

            return Guid.Empty;
        }
    }
}


================================================
FILE: CoreTests/Integration/BankTransactions/Create.cs
================================================
using NUnit.Framework;

namespace CoreTests.Integration.BankTransactions
{
    [TestFixture]
    public class Create : BankTransactionTest
    {
        [Test]
        public void create_bank_transactions()
        {
            var name = Given_a_bank_transaction()
                .Contact
                .Name;

            Assert.AreEqual("ABC Bank", name);
        }
    }
}


================================================
FILE: CoreTests/Integration/BankTransactions/Find.cs
================================================
using System;
using System.Linq;
using NUnit.Framework;

namespace CoreTests.Integration.BankTransactions
{
    [TestFixture]
    public class Find : BankTransactionTest
    {
        [Test]
        public void find_bank_transactions_where_filter()
        {
            Assert.DoesNotThrow(() => Api.BankTransactions
                .Where("Type == \"SPEND\"")
                .And("Status == \"AUTHORISED\"")
                .Find());
        }

        [Test]
        public void find_bank_transactions_ifmodifiedsince()
        {
            Given_a_bank_transaction();

            var bankTransaction = Api.BankTransactions
                .ModifiedSince(DateTime.Today.AddDays(-1).Date)
                .Find();

            Assert.IsNotNull(bankTransaction);
        }

        [Test]
        public void find_bank_transactions_individual()
        {
            var expected = Given_a_bank_transaction().Id;

            var id = Api.BankTransactions.Find(expected).Id;

            Assert.AreEqual(expected, id);
        }

        [Test]
        public void find_by_page()
        {
            Given_a_bank_transaction();
            var bankTrans = Api.BankTransactions.Page(1).Find();

            Assert.Greater(bankTrans.Count(), 0);
        }
    }
}


================================================
FILE: CoreTests/Integration/BankTransactions/Update.cs
================================================
using System.Collections.Generic;
using NUnit.Framework;
using Xero.Api.Core.Model;

namespace CoreTests.Integration.BankTransactions
{
    [TestFixture]
    public class Update : BankTransactionTest
    {
        [Test]
        public void update_bank_transaction()
        {
            var bt = Given_a_bank_transaction();

            var updatedTransaction = Api.Update(new BankTransaction
            {
                Id = bt.Id,
                BankAccount = new Account { Id = FindBankAccountGuid() },
                LineItems = new List<LineItem>
                    {
                        new LineItem
                        {
                            UnitAmount = 100m,
                            Quantity = 2m,
                            Description = bt.LineItems[0].Description,
                            AccountCode = bt.LineItems[0].AccountCode
                        }
                    }
            });

            Assert.AreEqual(100, updatedTransaction.LineItems[0].UnitAmount);
            Assert.AreEqual(2, updatedTransaction.LineItems[0].Quantity);
            Assert.AreEqual(200, updatedTransaction.LineItems[0].LineAmount);
        }
    }
}


================================================
FILE: CoreTests/Integration/BankTransfers/BankTransfersTest.cs
================================================
using System;
using System.Collections.Generic;
using System.Linq;
using Xero.Api.Core.Model;

namespace CoreTests.Integration.BankTransfers
{
    public abstract class BankTransfersTest : ApiWrapperTest
    {

        public BankTransfer Given_a_bank_transfer(Decimal amount)
        {
            var accountIds = get_bankaccount_ids();
   
            var newBankTransfer = new BankTransfer
            {
                FromBankAccount = new Account { Id = accountIds[0] },
                ToBankAccount = new Account { Id = accountIds[1] },
                Amount = amount
            };
            
            return Api.Create(newBankTransfer);
        }


        public IList<Guid> get_bankaccount_ids()
        {
            return Api.Accounts.Where("Type == \"BANK\"")
                .Find()
                .Select(p => p.Id)
                .ToList();
        }
    }
}


================================================
FILE: CoreTests/Integration/BankTransfers/Create.cs
================================================
using NUnit.Framework;

namespace CoreTests.Integration.BankTransfers
{
    [TestFixture]
    public class Create : BankTransfersTest
    {
        [Test]
        public void create_bank_transfer()
        {
            const decimal expected = 10m;
            var accounts = get_bankaccount_ids();

            var bankTransfer = Given_a_bank_transfer(expected);
            
            Assert.AreEqual(expected, bankTransfer.Amount);
            Assert.AreEqual(accounts[0], bankTransfer.FromBankAccount.Id);
            Assert.AreEqual(accounts[1], bankTransfer.ToBankAccount.Id);
        }
    }
}


================================================
FILE: CoreTests/Integration/BankTransfers/Find.cs
================================================
using System;
using System.Linq;
using NUnit.Framework;

namespace CoreTests.Integration.BankTransfers
{
    [TestFixture]
    public class Find : BankTransfersTest
    {
        [Test]
        public void find_bank_transfers()
        {
            Given_a_bank_transfer(10m);

            var allTransfers = Api.BankTransfers.Find();

            Assert.Greater(allTransfers.Count(), 0);
        }

        [Test]
        public void find_bank_transfers_individual()
        {
            var expected = Given_a_bank_transfer(25m).Id;

            var id = Api.BankTransfers.Find(expected).Id;

            Assert.AreEqual(expected, id);
        }

        [Test]
        public void find_bank_transfers_ifmodifiedsince()
        {
            Given_a_bank_transfer(25m);

            var date = DateTime.Today.AddDays(-4);
            var bankTransfers = Api.BankTransfers.ModifiedSince(date).Find();

            Assert.Greater(bankTransfers.Count(), 0);
        }
    }
}


================================================
FILE: CoreTests/Integration/BatchPayment/BatchPaymentsTest.cs
================================================
using System;
using System.Collections.Generic;
using Xero.Api.Core.Model;
using Xero.Api.Core.Model.Status;
using Xero.Api.Core.Model.Types;

namespace CoreTests.Integration.BatchPayments
{
    public abstract class BatchPaymentsTest : ApiWrapperTest
    {
        protected BatchPayment Given_a_batch_payment(decimal invoiceAmount, DateTime date, decimal amount, bool isReconciled = false)
        {
			var batchPayment = CreateBatchPayment(invoiceAmount, date, amount, isReconciled);

			return Api.BatchPayments.Create(batchPayment);
        }

        protected BatchPayment CreateBatchPayment(decimal invoiceAmount, DateTime date, decimal amount, bool isReconciled = false)
        {
            var invoice = Given_an_invoice(invoiceAmount, Account.Code);
            var bankCode = BankAccount.Id;

            var payment = new BatchPayment
			{
				Account = new Account { Id = bankCode },
				Date = date,
				Payments = new List<BatchPaymentPayment> { new BatchPaymentPayment {
					Amount = amount,
					Invoice = new Invoice { Id = invoice.Id},
					BankAccountNumber = BankAccount.BankAccountNumber,
				}}
            };

            if (isReconciled)
            {
                payment.IsReconciled = true;
            }

            return payment;
        }

		private Invoice Given_an_invoice(decimal amount = 100m, string accountCode = "100")
		{
			return Api.Create(new Invoice
			{
				Contact = new Contact { Name = "Richard" },
				Number = Random.GetRandomString(10),
				Type = InvoiceType.AccountsPayable,
				Date = DateTime.UtcNow,
				DueDate = DateTime.UtcNow.AddDays(90),
				LineAmountTypes = LineAmountType.Inclusive,
				Status = InvoiceStatus.Authorised,
				LineItems = new List<LineItem>
				{
					new LineItem
					{
						AccountCode = accountCode,
						Description = "Good value item",
						LineAmount = amount
					}
				}
			});
		}

    }
}

================================================
FILE: CoreTests/Integration/BatchPayment/Create.cs
================================================
using System;
using System.Collections.Generic;
using System.Linq;
using NUnit.Framework;
using Xero.Api.Core.Model;

namespace CoreTests.Integration.BatchPayments
{
    [TestFixture]
    public class Create : BatchPaymentsTest
    {
        [TestFixtureSetUp]
        public void CreateBatchPaymentsSetUp()
        {
            SetUp();
        }

        [Test]
        public void create_simple_batch_payment()
        {
            var date = DateTime.UtcNow;
            const decimal expectedTotal = 32.6m;
            const decimal invoiceAmount = 100;

			var batchPayment = Given_a_batch_payment(invoiceAmount, date, expectedTotal);

			Assert.IsNotNull(batchPayment);

			Assert.AreEqual(expectedTotal, batchPayment.Total);
			Assert.AreEqual(date.Date, batchPayment.Date);


		}

    }
}


================================================
FILE: CoreTests/Integration/ContactGroups/Add_Contact.cs
================================================
using NUnit.Framework;
using System;
using Xero.Api.Infrastructure.Exceptions;

namespace CoreTests.Integration.ContactGroups
{
    [TestFixture]
    public class Add_Contact : ContactGroupsTest
    {
        [Test]
        public void Can_I_add_a_contact_to_a_contactgroup()
        {
            var contactgroup = Given_a_contactgroup();

            Api.ContactGroups[contactgroup.Id].Add(Given_a_contact());
        }

        [Test]
        public void But_not_with_a_group_like_this()
        {
            Assert.Throws<NotFoundException>(() =>
            {
                Api.ContactGroups[Guid.Empty].Add(Given_a_contact());

            });
        }

    }
}


================================================
FILE: CoreTests/Integration/ContactGroups/ContactGroupsTest.cs
================================================
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using Xero.Api.Core.Model;

namespace CoreTests.Integration.ContactGroups
{
    public abstract class ContactGroupsTest : ApiWrapperTest
    {
        // need a contact in the system to use contact groups with.
        protected Contact Given_a_contact()
        {
            var contact = Api.Create(new Contact
            {
                Name = "Peter " + Guid.NewGuid().ToString("N")
            });
            return contact;
        }
        protected ContactGroup Given_a_contactgroup()
        {
            var group = Api.ContactGroups.Add(new ContactGroup
            {
                Name = "Nice People " + Guid.NewGuid()

            });

            return group;
        }
        
      
    }
}



================================================
FILE: CoreTests/Integration/ContactGroups/Create.cs
================================================
using NUnit.Framework;

namespace CoreTests.Integration.ContactGroups
{
    [TestFixture]
    public class Create : ContactGroupsTest
    {
        [Test]
        public void Can_I_create_a_contactgroup()
        {
           var name= Given_a_contactgroup().Name;
           
            Assert.IsTrue(name.StartsWith("Nice People"));

        }
    }
}


================================================
FILE: CoreTests/Integration/ContactGroups/Delete.cs
================================================
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using NUnit.Framework;
using Xero.Api.Core.Model;

namespace CoreTests.Integration.ContactGroups
{
    [TestFixture]
    public class Delete : ContactGroupsTest
    {
        [Test]
        public void Can_I_remove_the_contactgroup()
        {
            var contactgroup = Given_a_contactgroup();

            contactgroup.Status = "DELETED";

            var group = Api.Update(contactgroup);

            Assert.IsTrue(group.Status == "DELETED" );
        }

        [Test]
        public void Can_I_empty_the_contactgroup_of_contacts()
        {
            var contactgroup = Given_a_contactgroup();

            List<Contact> contacts = new List<Contact>();
            contacts.Add(Given_a_contact());
            contacts.Add(Given_a_contact());
            contacts.Add(Given_a_contact());
            contacts.Add(Given_a_contact());
            contacts.Add(Given_a_contact());

            Api.ContactGroups[contactgroup.Id].AddRange(contacts);

            Api.ContactGroups[contactgroup.Id].Clear();
        }
    }
}


================================================
FILE: CoreTests/Integration/ContactGroups/Find.cs
================================================
using System.Linq;
using NUnit.Framework;

namespace CoreTests.Integration.ContactGroups
{
    [TestFixture]
    public class Find : ContactGroupsTest
    {
        [Test]
        public void Can_Find_Contact_Group()
        {
            var contactGroup = Given_a_contactgroup();

            var foundContactGroup = Api.ContactGroups.Find(contactGroup.Id);

            Assert.IsTrue(foundContactGroup.Name.StartsWith("Nice People"));
        }

        [Test]
        public void Can_Find_Contacts_in_Contact_Group()
        {
            var contactGroup = Given_a_contactgroup();

            var contact = Given_a_contact();

            Api.ContactGroups[contactGroup.Id].Add(contact);

            var foundContactGroup = Api.ContactGroups.Find(contactGroup.Id);

            Assert.IsTrue(foundContactGroup.Name.StartsWith("Nice People"));
            Assert.IsTrue(foundContactGroup.Contacts.FirstOrDefault().Name.StartsWith("Peter"));
        }
    }
}


================================================
FILE: CoreTests/Integration/ContactGroups/Remove_Contact.cs
================================================
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using NUnit.Framework;

namespace CoreTests.Integration.ContactGroups
{
    [TestFixture]
    public class Remove_Contact : ContactGroupsTest
    {
        [Test]
        public void Can_remove_a_contact_from_a_contact_group()
        {
            var contactgroup = Given_a_contactgroup();

            var contact = Given_a_contact();

            Api.ContactGroups[contactgroup.Id].Add(contact);
            
            Api.ContactGroups[contactgroup.Id].Remove(contact.Id);

        }
    }
}


================================================
FILE: CoreTests/Integration/ContactGroups/Update.cs
================================================
using NUnit.Framework;
using System;
using System.Collections.Generic;
using Xero.Api.Core.Model;

namespace CoreTests.Integration.ContactGroups
{
    [TestFixture]
    public class Update : ContactGroupsTest
    {
        [Test]
        public void Can_I_change_the_name_of_a_contactgroup()
        {
            var contactgroup = Given_a_contactgroup();

            var newName = "Marketing Group" + Guid.NewGuid();

            contactgroup.Name = newName;
            
            var result =  Api.Update(contactgroup);

            Assert.IsTrue(result.Name.StartsWith("Marketing Group"));
        }

        [Test]
        protected void Can_I_append_contacts_to_a_contactgroup()
        {
            var contactgroup = Given_a_contactgroup();

            List<Contact> assign_1_contacts = new List<Contact>();

            assign_1_contacts.Add(Given_a_contact());

            Api.ContactGroups[contactgroup.Id].AddRange(assign_1_contacts);

            List<Contact> assign_4_more_contacts = new List<Contact>();
            assign_4_more_contacts.Add(Given_a_contact());
            assign_4_more_contacts.Add(Given_a_contact());
            assign_4_more_contacts.Add(Given_a_contact());
            assign_4_more_contacts.Add(Given_a_contact());

            Api.ContactGroups[contactgroup.Id].AddRange(assign_4_more_contacts);
            
        }
    }
}


================================================
FILE: CoreTests/Integration/Contacts/ContactsTest.cs
================================================
using System;
using System.Linq;
using Xero.Api.Core.Model;
using Xero.Api.Core.Model.Status;

namespace CoreTests.Integration.Contacts
{
    public abstract  class ContactsTest : ApiWrapperTest
    {
        private TrackingCategory trackingCat;
        private bool wasTCCreated = false;

        protected Contact Given_a_contact()
        {
            var contact = Api.Create(new Contact
            {
                Name = "Peter " + Random.GetRandomString(10)
            });
            return contact;
        }

        protected TrackingCategory findOrCreateTC(string OptionName, string TCName)
        {
            trackingCat = Api.TrackingCategories.GetAll().FirstOrDefault();
            if (trackingCat == null || trackingCat.Options.FirstOrDefault() == null)
            {
                var option1 = new Option()
                {
                    Id = Guid.Empty,
                    Name = OptionName,
                    Status = TrackingOptionStatus.Active
                };


                trackingCat = Api.TrackingCategories.Create(new TrackingCategory()
                {
                    Name = TCName,
                    Status = TrackingCategoryStatus.Active
                });


                Api.TrackingCategories[trackingCat.Id].Add(option1);

                trackingCat = Api.TrackingCategories.GetByID(trackingCat.Id);
                wasTCCreated = true;
            }
            return trackingCat;
        }

        protected void deleteCreatedTC(TrackingCategory tc)
        {
            if (wasTCCreated)
            {
                Api.TrackingCategories.Delete(trackingCat);
                wasTCCreated = false;
            }
        }
    }
}


================================================
FILE: CoreTests/Integration/Contacts/Create.cs
================================================
using System;
using System.Collections.Generic;
using System.Linq;
using NUnit.Framework;
using Xero.Api.Core.Model;
using Xero.Api.Core.Model.Status;

namespace CoreTests.Integration.Contacts
{
    [TestFixture]
    public class Create : ContactsTest
    {
        [Test]
        public void create_contact()
        {
            var name = Given_a_contact().Name;

            Assert.IsTrue(name.StartsWith("Peter"));
        }

        [Test]
        public void create_many_contact()
        {
            var contacts = Api.Create(new List<Contact>
            {
                new Contact
                {
                    Name = "John " + Random.GetRandomString(10)
                },
                new Contact
                {
                    Name = "Paul" + Random.GetRandomString(10)
                },
                new Contact
                {
                    Name = "George" + Random.GetRandomString(10)
                },
                new Contact
                {
                    Name = "Ringo" + Random.GetRandomString(10)
                }
            });

            Assert.AreEqual(4, contacts.Count());
        }

        [Test]
        public void create_complex_contact()
        {
            Api.Contacts.SummarizeErrors(true);

            var expectedAccountNumber = "AccountNumber" + Random.GetRandomString(10);


            var contact = Api.Create(new Contact
            {
                Name = "24 locks " + Random.GetRandomString(10),
                FirstName = "Ben",
                LastName = "Bowden",
                EmailAddress = "ben.bowden@24locks.com",
                AccountNumber = expectedAccountNumber,

                ContactPersons = new List<ContactPerson>
                {
                    new ContactPerson
                    {
                        FirstName = "John",
                        LastName = "Smith",
                        EmailAddress = "john.smith@24locks.com",
                        IncludeInEmails = true
                    }
                }
            });

            Assert.AreEqual("Ben", contact.FirstName);
            Assert.AreEqual("John", contact.ContactPersons[0].FirstName);
            Assert.AreEqual(expectedAccountNumber, contact.AccountNumber);
        }

        [Test]
        public void create_contact_with_tracking()
        {
            //Test will create a Tracking Category and use it if there are none available.
            var TCName = "Luke Skywalker" + Guid.NewGuid();
            var OptionName = "Yoda " + Guid.NewGuid();

            var trackingCat = findOrCreateTC(TCName, OptionName);

            var contact = Api.Create(new Contact
            {
                Name = "24 locks " + Random.GetRandomString(10),
                FirstName = "Ben",
                LastName = "Bowden",
                EmailAddress = "ben.bowden@24locks.com",
                PurchasesTrackingCategories = new List<PurchasesTrackingCategory>(){
                    new PurchasesTrackingCategory()
                    {
                        Name = trackingCat.Name,
                        Option = trackingCat.Options.FirstOrDefault().Name
                    }
                },
                ContactPersons = new List<ContactPerson>
                {
                    new ContactPerson
                    {
                        FirstName = "John",
                        LastName = "Smith",
                        EmailAddress = "john.smith@24locks.com",
                        IncludeInEmails = true
                    }
                }
            });

            deleteCreatedTC(trackingCat);

            Assert.AreEqual("Ben", contact.FirstName);
            Assert.AreEqual("John", contact.ContactPersons[0].FirstName);
            Assert.True(TCName == contact.PurchasesTrackingCategories.FirstOrDefault().Name || trackingCat.Name == contact.PurchasesTrackingCategories.FirstOrDefault().Name);
            Assert.True(OptionName == contact.PurchasesTrackingCategories.FirstOrDefault().Option || contact.PurchasesTrackingCategories.FirstOrDefault().Option == trackingCat.Options.FirstOrDefault().Name);
        }
    }
}


================================================
FILE: CoreTests/Integration/Contacts/Find.cs
================================================
using System;
using System.Linq;
using NUnit.Framework;
using Xero.Api.Core.Model.Status;

namespace CoreTests.Integration.Contacts
{
    [TestFixture]
    public class Find : ContactsTest
    {
        [Test]
        public void find_by_page()
        {
            Given_a_contact();

            Assert.True(Api.Contacts.Page(1).Find().Any());
        }

        [Test]
        public void find_by_id()
        {
            var expected = Given_a_contact().Id;
            
            var id = Api.Contacts
                .Find(expected)
                .Id;

            Assert.AreEqual(expected, id);
        }

        [Test]
        public void find_by_id_list()
        {
            var created = Given_a_contact();
            var contacts = Api.Contacts.Ids(new[] { created.Id }).Find().ToList();

            Assert.AreEqual(1, contacts.Count());
            Assert.AreEqual(created.Id, contacts.First().Id);
        }

        [Test]
        public void find_by_value()
        {
            var expected = Given_a_contact().Name;

            var name = Api.Contacts
                .Where(string.Format("Name == \"{0}\"", expected))
                .Find()
                .Select(p => p.Name);                

            Assert.True(name.All(p => p == expected));
        }

        [Test]
        public void find_by_contains_value()
        {
            var expected = Given_a_contact().Name;

            var contacts = Api.Contacts
                .Where(string.Format("Name.Contains(\"{0}\")", expected))
                .Find()
                .Select(p => p.Name);

            Assert.True(contacts.All(p => p.Contains(expected)));            
        }

        [Test]
        public void find_by_status()
        {
            Given_a_contact();

            var status = Api.Contacts
                .Where("ContactStatus == \"ACTIVE\"")
                .Find()
                .Select(p => p.ContactStatus);                

            Assert.True(status.All(p => p == ContactStatus.Active));
        }

        [Test]
        public void find_by_updated_date()
        {
            var expected = Given_a_contact().Id;
            var date = DateTime.Today.AddDays(-5);

            var contacts = Api.Contacts
                .ModifiedSince(date)
                .OrderByDescending("UpdatedDateUTC")                
                .Find()
                .Select(p => p.Id)
                .ToList();

            Assert.Greater(contacts.Count(), 0);
            Assert.Contains(expected, contacts);
        }
        
        [Test]
        public void find_by_dateRange()
        {
            var expected = Given_a_contact().Id;
            var fromDate = DateTime.Today.AddDays(-1);
            var toDate = DateTime.Today.AddDays(1);

            var contacts = Api.Contacts
                .Where(string.Format("UpdatedDateUTC >= DateTime.Parse(\"{0}\")", fromDate.ToString("yyyy-MM-dd")))
                .And(string.Format("UpdatedDateUTC <= DateTime.Parse(\"{0}\")", toDate.ToString("yyyy-MM-dd")))
                .OrderByDescending("UpdatedDateUTC")
                .Find()
                .Select(p => p.Id)
                .ToList();

            Assert.Greater(contacts.Count(), 0);
            Assert.Contains(expected, contacts);
        }
    }
}


================================================
FILE: CoreTests/Integration/Contacts/Update.cs
================================================
using System;
using System.Collections.Generic;
using System.Linq;
using NUnit.Framework;
using Xero.Api.Core.Model;
using Xero.Api.Core.Model.Types;

namespace CoreTests.Integration.Contacts
{
    public class Update : ContactsTest
    {
        [Test]
        public void update_contact()
        {
            var id = Given_a_contact().Id;

            var changes = new Contact
            {
                Id = id,

                ContactNumber = "ID001" + Guid.NewGuid().ToString("N"),
                Name = "ABC Limited " + Guid.NewGuid().ToString("N"),
                FirstName = "John",
                LastName = "Smith",
                EmailAddress = "john.smith@gmail.com",
                BankAccountDetails = "01-0123-0123456-00",
                TaxNumber = "12-345-678",
                AccountsReceivableTaxType = "OUTPUT",
                AccountsPayableTaxType = "INPUT",
                DefaultCurrency = "NZD",
                Addresses = new List<Address>
                    {
                        new Address
                        {
                            AddressType = AddressType.PostOfficeBox,
                            AddressLine1 = "P O Box 123",
                            City = "Wellington",
                            PostalCode = "6011"
                        }
                    }
            };

            var updated = Api.Update(changes);

            Assert.IsTrue(updated.Name.StartsWith("ABC"));
            Assert.IsTrue(updated.ContactNumber.StartsWith("ID001"));
            Assert.AreEqual("John", updated.FirstName);
            Assert.AreEqual("Smith", updated.LastName);
            Assert.AreEqual("john.smith@gmail.com", updated.EmailAddress);
            Assert.AreEqual("01-0123-0123456-00", updated.BankAccountDetails);
            Assert.AreEqual("NZD", updated.DefaultCurrency);
            Assert.AreEqual("Wellington", updated.Addresses.Single(p => p.AddressType == AddressType.PostOfficeBox).City);
        }
    }
}


================================================
FILE: CoreTests/Integration/CreditNotes/Create.cs
================================================
using NUnit.Framework;
using Xero.Api.Core.Model.Types;

namespace CoreTests.Integration.CreditNotes
{
    [TestFixture]
    public class Create : CreditNotesTest
    {
        [Test]
        public void create_creditnote()
        {
            const CreditNoteType expected = CreditNoteType.AccountsReceivable;

            var type = Given_a_creditnote(type: expected).Type;

            Assert.AreEqual(expected, type);
        }
    }
}
   


================================================
FILE: CoreTests/Integration/CreditNotes/CreditNotesTest.cs
================================================
using System;
using System.Collections.Generic;
using Xero.Api.Core.Model;
using Xero.Api.Core.Model.Status;
using Xero.Api.Core.Model.Types;

namespace CoreTests.Integration.CreditNotes
{
    public class CreditNotesTest : ApiWrapperTest
    {
        public CreditNote Given_an_authorised_creditnote(CreditNoteType type = CreditNoteType.AccountsPayable)
        {
            return Given_a_creditnote(type: type, status: InvoiceStatus.Authorised);
        }

        public CreditNote Given_a_draft_creditnote(CreditNoteType type = CreditNoteType.AccountsPayable)
        {
            return Given_a_creditnote(type: type);
        }

        public CreditNote Given_a_creditnote(string contactName = "Apple Computers Ltd", CreditNoteType type = CreditNoteType.AccountsPayable, InvoiceStatus status = InvoiceStatus.Draft)
        {
            return Api.CreditNotes.Create(new CreditNote
            {
                Contact = new Contact { Name = contactName },
                Type = type,
                Date = DateTime.UtcNow,
                LineAmountTypes = LineAmountType.Exclusive,
                Status = status,
                LineItems = new List<LineItem>
                {
                    new LineItem
                    {
                        AccountCode = "720",
                        Description = "MacBook - White",
                        UnitAmount = 1995.00m
                    }
                }
            });
        }
    }
}


================================================
FILE: CoreTests/Integration/CreditNotes/Find.cs
================================================
using System.Linq;
using NUnit.Framework;
using Xero.Api.Core.Model.Types;

namespace CoreTests.Integration.CreditNotes
{
    [TestFixture]
    public class Find : CreditNotesTest
    {
        [Test]
        public void find_all_creditnotes()
        {
            Given_a_creditnote();

            Assert.True(Api.CreditNotes.Find().Any());
        }

        [Test]
        public void find_by_id()
        {
            var expected = Given_a_creditnote().Id;
            var id = Api.CreditNotes.Find(expected).Id;

            Assert.AreEqual(expected, id);
        }

        [Test]
        public void find_by_value()
        {
            Given_a_creditnote();

            var creditnote = Api.CreditNotes
                .Where("Type == \"ACCPAYCREDIT\"")
                .Find()
                .First()
                .Type;

            Assert.AreEqual(CreditNoteType.AccountsPayable, creditnote);
        }

        [Test]
        public void find_orderby_value()
        {
            Given_a_creditnote();

            var creditNote = Api.CreditNotes
                .OrderBy("Type")
                .Find()
                .First()
                .Type;

            Assert.AreEqual(CreditNoteType.AccountsPayable, creditNote);
        }
    }
}


================================================
FILE: CoreTests/Integration/CreditNotes/Update.cs
================================================
using System.Collections.Generic;
using NUnit.Framework;
using Xero.Api.Core.Model;
using Xero.Api.Core.Model.Status;

namespace CoreTests.Integration.CreditNotes
{
    [TestFixture]
    public class Update : CreditNotesTest
    {
        [Test]
        public void delete_draft_creditnote()
        {
            const InvoiceStatus expected = InvoiceStatus.Deleted;
            var creditnote = Given_a_creditnote();

            creditnote.Status = expected;

            var status = Api.Update(creditnote).Status;

            Assert.AreEqual(expected, status);
        }

        [Test]
        public void update_creditnote_lineitems()
        {
            var creditnote = Given_a_creditnote();

            var updatedCreditnote = Api.Update(new CreditNote
            {
                Id = creditnote.Id,
                LineItems = new List<LineItem>
                    {
                        new LineItem
                        {
                            Description = creditnote.LineItems[0].Description,
                            Quantity = 2m,
                            UnitAmount = 100m,
                            AccountCode = creditnote.LineItems[0].AccountCode
                        }
                    }
            });

            Assert.AreEqual(100m, updatedCreditnote.LineItems[0].UnitAmount);
            Assert.AreEqual(2m, updatedCreditnote.LineItems[0].Quantity);
            Assert.AreEqual(200m, updatedCreditnote.LineItems[0].LineAmount);
        }
    }
}


================================================
FILE: CoreTests/Integration/ExpenseClaims/Create.cs
================================================
using System.Linq;
using NUnit.Framework;

namespace CoreTests.Integration.ExpenseClaims
{
    [TestFixture]
    public class Create : ExpenseClaimTest
    {
        [Test]
        public void create_expense_claim()
        {
            var user = Api.Users.Find().First();

            var receipt1 = Given_a_receipt(user.Id, Random.GetRandomString(10), Random.GetRandomString(30), 20m, "420");
            var receipt2 = Given_a_receipt(user.Id, Random.GetRandomString(10), Random.GetRandomString(30), 50m, "420");

            var claim = Given_an_expense_claim(user.Id, receipt1.Id, receipt2.Id);

            Assert.AreEqual(70m, claim.Total);
        }
    }
}


================================================
FILE: CoreTests/Integration/ExpenseClaims/ExpenseClaimTest.cs
================================================
using System;
using System.Collections.Generic;
using Xero.Api.Core.Model;
using Xero.Api.Core.Model.Status;
using Xero.Api.Core.Model.Types;

namespace CoreTests.Integration.ExpenseClaims
{
    public abstract class ExpenseClaimTest : ApiWrapperTest
    {
        public Receipt Given_a_receipt(Guid userId, string contactName, string description, decimal amount, string account)
        {
            return Api.Create(new Receipt
            {
                Date = DateTime.UtcNow.Date,
                Contact = new Contact { Name = contactName },
                LineAmountTypes = LineAmountType.Inclusive,
                Status = ReceiptStatus.Draft,
                LineItems = new List<LineItem>
                {
                    new LineItem
                    {
                        Description = description,
                        UnitAmount = amount,
                        AccountCode = account
                    }
                },
                Total = amount,
                User = new User
                {
                    Id = userId
                }
            });
        }

        public ExpenseClaim Given_an_expense_claim(Guid userId, Guid receiptId1, Guid receiptId2)
        {
            return Api.Create(new ExpenseClaim
            {
                User = new User
                {
                    Id = userId
                },
                Receipts = new List<Receipt>
                {
                    new Receipt
                    {
                        Id = receiptId1
                    },
                    new Receipt
                    {
                        Id = receiptId2
                    },
                }                
            });
        }
    }
}


================================================
FILE: CoreTests/Integration/ExpenseClaims/Update.cs
================================================
using System.Linq;
using NUnit.Framework;
using Xero.Api.Core.Model;
using Xero.Api.Core.Model.Status;

namespace CoreTests.Integration.ExpenseClaims
{
    [TestFixture]
    public class Update : ExpenseClaimTest
    {
        [Test]
        public void authorise_expense_claim()
        {
            var user = Api.Users.Find().First();

            var receipt1 = Given_a_receipt(user.Id, Random.GetRandomString(10), Random.GetRandomString(30), 20m, "420");
            var receipt2 = Given_a_receipt(user.Id, Random.GetRandomString(10), Random.GetRandomString(30), 50m, "420");

            var claim = Given_an_expense_claim(user.Id, receipt1.Id, receipt2.Id);

            var authorised = Api.Update(
                new ExpenseClaim
                {
                    Id = claim.Id,
                    Status = ExpenseClaimStatus.Authorised
                });

            Assert.AreEqual(ExpenseClaimStatus.Authorised, authorised.Status);
        }

        [Test]
        public void void_expense_claim()
        {
            var user = Api.Users.Find().First();

            var receipt1 = Given_a_receipt(user.Id, Random.GetRandomString(10), Random.GetRandomString(30), 20m, "420");
            var receipt2 = Given_a_receipt(user.Id, Random.GetRandomString(10), Random.GetRandomString(30), 50m, "420");

            var claim = Given_an_expense_claim(user.Id, receipt1.Id, receipt2.Id);

            var authorised = Api.Update(
                new ExpenseClaim
                {
                    Id = claim.Id,
                    Status = ExpenseClaimStatus.Authorised
                });

            var voided = Api.Update(
                new ExpenseClaim
                {
                    Id = authorised.Id,
                    Status = ExpenseClaimStatus.Voided
                });

            Assert.AreEqual(ExpenseClaimStatus.Voided, voided.Status);
        }
    }
}

================================================
FILE: CoreTests/Integration/Files/Associations/AssociationTest.cs
================================================
using System;
using System.Diagnostics;
using System.Linq;
using NUnit.Framework;
using Xero.Api.Core.Model;
using Xero.Api.Core.Model.Types;

namespace CoreTests.Integration.Files.Associations
{
    [TestFixture]
    public class AssociationTest : ApiWrapperTest
    {
        private Guid FindAFileId()
        {
            var file = Api.Files.Find().FirstOrDefault();
            return file == null ? Guid.Empty : file.Id;
        }

        private Guid FindAnInvoiceId()
        {
            var invoice = Api.Invoices.Find().FirstOrDefault();
            return invoice == null ? Guid.Empty : invoice.Id;
        }

        [Test]
        public void AssociationsForFile()
        {
            Assert.DoesNotThrow(() =>
            {
                var fileId = FindAFileId();
                var list = Api.Associations.Find(fileId);
                Debug.WriteLine("Found {0} associations for file {1}.", list.Count(), fileId);
            });
        }

        [Test]
        public void AssociationsForObject()
        {
            Assert.DoesNotThrow(() =>
            {
                var objectId = FindAnInvoiceId();
                var list = Api.Associations.FindForObject(objectId);
                Debug.WriteLine("Found {0} associations for object {0}.", list.Count(), objectId);
            });
        }

        // This is not a great test - but it needs to run in sequence and clean up after itself
        // (if it happens to be working with an association that should already exist, then we have a problem...)
        [Test]
        public void AssociationCreateFindAndDelete()
        {
            var fileId = FindAFileId();
            var objectId = FindAnInvoiceId();

            Assert.DoesNotThrow(() =>
            {
                var toCreate = new Association
                {
                    FileId = fileId,
                    ObjectId = objectId,
                    ObjectGroup = ObjectGroupType.Invoice
                };
                var created = Api.Associations.Create(toCreate);
                Debug.WriteLine("Created {0}", created);
            });

            Assert.DoesNotThrow(() =>
            {
                var found = Api.Associations.Find(fileId, objectId);
                Debug.WriteLine("Found {0}", found);
            });

            Assert.DoesNotThrow(() =>
            {
                var toDelete = new Association
                {
                    FileId = fileId,
                    ObjectId = objectId,
                    ObjectGroup = ObjectGroupType.Invoice
                };
                Api.Associations.Delete(toDelete);
                Debug.WriteLine("Deleted {0}", toDelete);
            });
        }
    }
}

================================================
FILE: CoreTests/Integration/Files/Files/AddFileTest.cs
================================================
using System;
using System.Collections;
using System.Net;
using CoreTests.Integration.Files.Support;
using NUnit.Framework;
using Xero.Api.Core.Model;
using File = Xero.Api.Core.Model.File;

namespace CoreTests.Integration.Files.Files
{
    [TestFixture]
    public class AddFileTest : FilesTest
    {
      
        
        [Test]
        public void can_get_all_files_like_this()
        {
            var result = Api.Files.Find();

            Assert.True(result != null);
        }

        [Test]
        public void can_get_the_content_of_a_file_like_this()
        {
            var filename = "My Test File " + Guid.NewGuid() + ".png";

            var inboxId = Api.Inbox.InboxFolder.Id;

            var id = Given_a_file_in(inboxId, filename);

            var content = Api.Files.GetContent(id,"image/png");
            
            Assert.IsTrue(StructuralComparisons.StructuralEqualityComparer.Equals(content,exampleFile));
        }
        
       [Test]
        public void can_remove_a_file_like_this()
        {
            var inboxId = Api.Inbox.InboxFolder.Id;

            var result = Given_a_file_in(inboxId, "Test " + Guid.NewGuid()  + ".png");

            Api.Files.Remove(result);

            var notfound= Api.Files[result];  

            Assert.IsNull(notfound);

        }

       [Test]
       public void can_rename_a_file_like_this()
       {
           var inboxId = Api.Inbox.InboxFolder.Id;

           var result = Given_a_file_in(inboxId, "Test " + Guid.NewGuid()  + ".png");

           var copy = Api.Files[result];

           var NewName = "someother name";

           var updateResult = Api.Files.Rename(copy.Id, NewName);

           Assert.IsTrue(updateResult.Name == NewName);

       }

       [Test]
       public void can_move_a_file_like_this()
       {
           var inboxId = Api.Inbox.InboxFolder.Id;

           var result = Given_a_file_in(inboxId, "Test " + Guid.NewGuid() + ".png");

           var newFolder = Api.Folders.Add("stuff");

           var updateResult = Api.Files.Move(result, newFolder.Id);

           Assert.IsTrue(updateResult.FolderId == newFolder.Id);

       }
        
       [Test]
       public void cannot_add_a_file_with_bad_filename_charactors()
       {
           var inboxId = Api.Inbox.InboxFolder.Id;

           char[] badchar = System.IO.Path.GetInvalidFileNameChars();

           var filename = "Inbox file " + badchar[0] + badchar[3] + badchar[2] + ".png"; ;

           Assert.Throws<WebException>(() =>
           {
               Api.Files.Add( inboxId, create_file_with_name(filename), exampleFile);
           });
       }

       private File create_file_with_name(string filename)
       {
           return new Xero.Api.Core.Model.File()
           {
               Name = filename,
               FileName = filename,
               Mimetype = "image/png",
               User = new FilesUser()
               {
                   FirstName = "Bart",
                   LastName = "Simpson",
                   FullName = "Bart Simpson",
                   Name = "Bart@gmail.com"
               }
           };
       }
    }

}


================================================
FILE: CoreTests/Integration/Files/Folders/AddFolderTest.cs
================================================
using System;
using CoreTests.Integration.Files.Support;
using NUnit.Framework;

namespace CoreTests.Integration.Files.Folders
{
    public class AddFolderTest : FilesTest
    {

        [Test]
        public void can_create_a_folder_like_this()
        {
            var result = Api.Folders.Add("Test Folder" + Guid.NewGuid());
        }


        [Test]
        public void can_get_all_folders_like_this()
        {

            var allFolders = Api.Folders.Folders;

            Assert.True(allFolders[0].Name == "Inbox");

            Assert.True(allFolders[1].Name == "Contracts");

        }

        [Test]
        public void can_remove_a_folder_like_this()
        {

            var folder = Api.Folders.Add("Test Folder" + Guid.NewGuid());

            Api.Folders.Remove(folder.Id); // Hint ->folder is empty

        }
        
      }
}

================================================
FILE: CoreTests/Integration/Files/Inbox/InboxTest.cs
================================================
using System;
using CoreTests.Integration.Files.Support;
using NUnit.Framework;
using Xero.Api.Core.Model;
using File = Xero.Api.Core.Model.File;

namespace CoreTests.Integration.Files.Inbox
{
    [TestFixture]
    public class InboxTest : FilesTest
    {

        [Test]
        public void can_get_the_inbox_like_this()
        {
            var inbox = Api.Inbox.InboxFolder;

            Assert.IsTrue(inbox.Name == "Inbox");

            Assert.IsTrue(inbox.IsInbox);
        }

        [Test]
        public void can_add_a_file_to_inbox_like_this()
        {
            var filename = "Inbox file " + Guid.NewGuid() + ".png";

            var result = Api.Inbox.Add(create_file_with_name(filename), exampleFile);

            var file = Api.Files[result.Id];

            Assert.IsTrue(file.Mimetype == "image/png");
            Assert.IsTrue(file.Name == filename);

        }

        [Test]
        public void can_remove_a_file_like_this()
        {
            var inboxId = Api.Inbox.InboxFolder.Id;

            var result = Given_a_file_in(inboxId, "Test " + Guid.NewGuid() + ".png");

            Api.Inbox.Remove(result);

            var notfound = Api.Inbox[result];

            Assert.IsNull(notfound);

        }

       

        private File create_file_with_name(string filename)
        {
            return new Xero.Api.Core.Model.File()
            {
                Name = filename,
                FileName = filename,
                Mimetype = "image/png",
                User = new FilesUser()
                {
                    FirstName = "Bart",
                    LastName = "Simpson",
                    FullName = "Bart Simpson",
                    Name = "Bart@gmail.com"
                }
            };
        }


    }
}

================================================
FILE: CoreTests/Integration/Files/Support/DataItem.cs
================================================
using System;
using System.IO;

namespace CoreTests.Integration.Files.Support
{
    public class DataItem : IDisposable
    {
        public String ContentType { get; set; }
        public Stream Content { get; private set; }

        public DataItem(FileInfo file, String contentType = "unknown")
        {
            Content = file.OpenRead();
            ContentType = contentType;
        }

        public DataItem(Byte[] data, String contentType = "unknown")
        {
            ContentType = contentType;
            Content = new MemoryStream(data);
        }

        public void Dispose()
        {
            if (Content != null)
            {
                Content.Close();
            }
        }
    }
}

================================================
FILE: CoreTests/Integration/Files/Support/DiskFile.cs
================================================
using System.IO;

namespace CoreTests.Integration.Files.Support
{
    public class DiskFile : File
    {
        public string Name { get; private set; }
        public string Path { get; private set; }
        public int ContentLength { get; private set; }

        public DiskFile(string name)
            : this(name, name)
        { }

        public DiskFile(string name, string path)
        {
            Name = name;
            Path = string.Format("resources\\images\\{0}", path);
            ContentLength = (int)new FileInfo(Path).Length;
        }
    }
}

================================================
FILE: CoreTests/Integration/Files/Support/File.cs
================================================
namespace CoreTests.Integration.Files.Support
{
    public interface File
    {
        string Name { get; }
        string Path { get; }
        int ContentLength { get; }
    }
}

================================================
FILE: CoreTests/Integration/Files/Support/FilesTest.cs
================================================
using System;
using System.IO;
using Xero.Api.Core.Model;

namespace CoreTests.Integration.Files.Support
{
    public class FilesTest : ApiWrapperTest
    {
        protected byte[] exampleFile;
        private const string ImagePath = @"connect_xero_button_blue.png";

        public FilesTest()
        {
            exampleFile = GetFileBytes("xero", ImagePath);
        }
        
        private Xero.Api.Core.Model.File create_file_with_name(string filename)
        {
            return new Xero.Api.Core.Model.File()
            {
                Name = filename,
                FileName = filename,
                Mimetype = "image/png",
                User = new FilesUser()
                {
                    FirstName = "Bart",
                    LastName = "Simpson",
                    FullName = "Bart Simpson",
                    Name = "Bart@gmail.com"
                }
            };
        }

        protected Guid Given_a_file_in(Guid folderId, string filename)
        {
            var file = create_file_with_name(filename);

            return Given_a_file_in(folderId, file);

        }

        protected Guid Given_a_file_in(Guid folderId)
        {
            var filename = "Test" + Guid.NewGuid() + ".png";

            return Given_a_file_in(folderId, create_file_with_name(filename));    
        }

        protected Guid Given_a_file_in(Guid folderId,Xero.Api.Core.Model.File file )
        {
            var result = Api.Files.Add(folderId, file, exampleFile);

            return result.Id ;
        }
        
        internal static byte[] GetFileBytes(string name, string fileName)
        {
            var file = new FileInfo(new DiskFile(name, fileName).Path);

            var data = new DataItem(file);
            byte[] bytes;

            using (var ms = new MemoryStream())
            {
                data.Content.CopyTo(ms);
                bytes = ms.ToArray();
            }

            return bytes;
        }
    }
}

================================================
FILE: CoreTests/Integration/General/Errors.cs
================================================
using System.Collections.Generic;
using NUnit.Framework;
using Xero.Api.Core.Model;
using Xero.Api.Infrastructure.Exceptions;

namespace CoreTests.Integration.General
{
    [TestFixture]
    public class Errors : ApiWrapperTest
    {
        [Test]
        public void not_found()
        {
            Assert.Throws<NotFoundException>(() => Api.Invoices.Find("ThisIsNotThere"));
        }

        [Test]
        public void bad_query()
        {
            Assert.Throws<BadRequestException>(() => Api.Invoices.Where("Bob == Robert").Find());
        }

        [Test]
        public void validation_error()
        {
            Assert.Throws<ValidationException>(() => Api.Invoices.Create(new Invoice
            {
                LineItems = new List<LineItem>
                {
                    new LineItem
                    {
                        LineAmount = 101.01M
                    }
                }
            }));
        }
    }
}


================================================
FILE: CoreTests/Integration/General/FindingAllItems.cs
================================================
using NUnit.Framework;

namespace CoreTests.Integration.General
{
    [TestFixture]
    public class FindingAllItems : ApiWrapperTest
    {
        [Test]
        public void get_accounts()
        {
            Assert.DoesNotThrow(() => Api.Accounts.Find());
        }

        [Test]
        public void get_bank_transactions()
        {
            Assert.DoesNotThrow(() => Api.BankTransactions.Find());
        }

        [Test]
        public void get_bank_transfers()
        {
            Assert.DoesNotThrow(() => Api.BankTransfers.Find());
        }

        [Test]
        public void get_branding_themes()
        {
            Assert.DoesNotThrow(() => Api.BrandingThemes.Find());
        }

        [Test]
        public void get_contacts()
        {
            Assert.DoesNotThrow(() => Api.Contacts.Find());
        }

        [Test]
        public void get_credit_notes()
        {
            Assert.DoesNotThrow(() => Api.CreditNotes.Find());
        }

        [Test]
        public void get_currencies()
        {
            Assert.DoesNotThrow(() => Api.Currencies.Find());
        }

        [Test]
        public void get_employees()
        {
            Assert.DoesNotThrow(() => Api.Employees.Find());
        }

        [Test]
        public void get_expense_claims()
        {
            Assert.DoesNotThrow(() => Api.ExpenseClaims.Find());
        }

        [Test]
        public void get_invoices()
        {
            Assert.DoesNotThrow(() => Api.Invoices.Find());
        }

        [Test]
        public void get_items()
        {
            Assert.DoesNotThrow(() => Api.Items.Find());
        }

        [Test]
        public void get_journals()
        {
            Assert.DoesNotThrow(() => Api.Journals.Find());
        }

        [Test]
        public void get_manual_journals()
        {
            Assert.DoesNotThrow(() => Api.ManualJournals.Find());
        }

        [Test]
        public void get_payments()
        {
            Assert.DoesNotThrow(() => Api.Payments.Find());
        }

        [Test]
        public void get_receipts()
        {
            Assert.DoesNotThrow(() => Api.Receipts.Find());
        }

        [Test]
        public void get_repeating_invoices()
        {
            Assert.DoesNotThrow(() => Api.RepeatingInvoices.Find());
        }

        [Test]
        public void get_tax_rates()
        {
            Assert.DoesNotThrow(() => Api.TaxRates.Find());
        }

        [Test]
        public void get_tracking_categories()
        {
            Assert.DoesNotThrow(() => Api.TrackingCategories.Find());
        }

        [Test]
        public void get_users()
        {
            Assert.DoesNotThrow(() => Api.Users.Find());
        }        
    }
}


================================================
FILE: CoreTests/Integration/General/QueryStrings.cs
================================================
using System;
using NUnit.Framework;

namespace CoreTests.Integration.General
{
    [TestFixture]
    public class QueryStrings : ApiWrapperTest
    {
        [Test]
        public void query_string_is_as_expected()
        {
            Assert.DoesNotThrow(() => Api.Invoices.Where("Status == \"ACTIVE\"").Find());            
        }

        [Test]
        public void complex_query_string_is_as_expected()
        {
            var startDate = DateTime.UtcNow.AddDays(-30).Date.ToString("yyyy-MM-dd");
            var endDate = DateTime.UtcNow.Date.ToString("yyyy-MM-dd");

            Assert.DoesNotThrow(() => Api.Invoices.Where("Status == \"ACTIVE\"")
                .And(string.Format("DueDate >= DateTime.Parse(\"{0}\")", startDate))
                .And(string.Format("DueDate <= DateTime.Parse(\"{0}\")", endDate))
                .OrderByDescending("DueDate").Find());
        }

        [Test]
        public void contact_query_string_is_as_expected()
        {
            Assert.DoesNotThrow(() => Api.Contacts.IncludeArchived(true).Find());
        }
    }
}


================================================
FILE: CoreTests/Integration/HistoryAndNotes/CreateNotes.cs
================================================
using NUnit.Framework;

namespace CoreTests.Integration.HistoryAndNotes
{
    public class CreateNotes : HistoryAndNotesTest
    {
        [Test]
        public void Can_create_notes()
        {
            const string details = "Details";

            Given_a_contact();

            Given_a_note_with_these_details(details);

            When_I_retrieve_history_and_notes_for_the_contact();

            Then_there_is_a_note_with_the_correct_details(details);
        }
    }
}


================================================
FILE: CoreTests/Integration/HistoryAndNotes/Find.cs
================================================
using NUnit.Framework;

namespace CoreTests.Integration.HistoryAndNotes
{
    public class Find : HistoryAndNotesTest
    {
        [Test]
        public void Can_fetch_history_and_notes()
        {
            Given_a_contact();

            When_I_retrieve_history_and_notes_for_the_contact();

            Then_there_are_some_history_records();
        }
    }
}


================================================
FILE: CoreTests/Integration/HistoryAndNotes/HistoryAndNotesTest.cs
================================================
using System;
using System.Collections.Generic;
using System.Linq;
using NUnit.Framework;
using Xero.Api.Core.Model;
using Xero.Api.Core.Model.Types;

namespace CoreTests.Integration.HistoryAndNotes
{
    public class HistoryAndNotesTest : ApiWrapperTest
    {
        private Contact _contact;
        private IEnumerable<HistoryRecord> _historyRecords;
        
        protected void Given_a_contact()
        {
            _contact = Api.Contacts.Create(new Contact { Name = Guid.NewGuid().ToString() });
        }

        protected void Given_a_note_with_these_details(string details)
        {
            Api.HistoryAndNotes.CreateNote(HistoryAndNotesEndpointCreateType.Contacts, _contact.Id,
                new HistoryRecord
                {
                    Details = details
                });
        }

        protected void When_I_retrieve_history_and_notes_for_the_contact()
        {
            _historyRecords = Api.HistoryAndNotes.Find(HistoryAndNotesEndpointRetrieveType.Contacts, _contact.Id);
        }

        protected void Then_there_are_some_history_records()
        {
            Assert.True(_historyRecords.Any(), "Expected some history records to be returned, but there were none");
        }

        protected void Then_there_is_a_note_with_the_correct_details(string details)
        {
            Assert.True(_historyRecords.Any(it => it.Details == details), "Expected a note with the expected details to be returned but it was not");
        }
    }
}


================================================
FILE: CoreTests/Integration/Invoices/Create.cs
================================================
using System;
using System.Collections.Generic;
using System.Linq;
using NUnit.Framework;
using Xero.Api.Core.Model;
using Xero.Api.Core.Model.Status;
using Xero.Api.Core.Model.Types;

namespace CoreTests.Integration.Invoices
{
    [TestFixture]
    public class Create : InvoicesTest
    {
        [Test]
        public void simple_create_works()
        {
            var invoice = Given_an_invoice();

            Assert.True(invoice.Id != Guid.Empty);
        }

        [Test]
        public void description_only_items_work()
        {
            const InvoiceType expected = InvoiceType.AccountsPayable;
            var type = Given_a_description_only_invoice().Type;

            Assert.AreEqual(expected, type);
        }

        [Test]
        public void accounts_receivable()
        {
            const InvoiceType expected = InvoiceType.AccountsReceivable;
            var type = Given_a_description_only_invoice(expected).Type;

            Assert.AreEqual(expected, type);
        }

        [Test]
        public void lineItemId_is_returned()
        {
            var invoce = Given_an_invoice();

            Assert.NotNull(invoce.LineItems.FirstOrDefault().LineItemId);
        }

        [Test]
        public void multiple_lineitems()
        {
            var invoice = Api.Create(new Invoice
            {
                Contact = new Contact { Name = "ABC Limited" },
                Type = InvoiceType.AccountsReceivable,
                LineItems = new List<LineItem>
                {
                    new LineItem
                    {
                        AccountCode = "200",
                        Description = "Good value item",
                        UnitAmount = 25.6m,
                        Quantity = 1m
                    },
                    new LineItem
                    {
                        AccountCode = "200",
                        Description = "Another good value item",
                        UnitAmount = 125.65m,
                        Quantity = 5m
                    }
                }
            });

            Assert.True(invoice.Id != Guid.Empty);
            Assert.AreEqual(InvoiceType.AccountsReceivable, invoice.Type);
			Assert.AreEqual(2, invoice.LineItems.Count());
        }

        [Test]
        public void multiple_invoices()
        {
            var invoices = Api.Create(new[]
            {
                new Invoice
                {
                    Contact = new Contact { Name = "ABC Limited" },
                    Type = InvoiceType.AccountsReceivable,
                    LineItems = new List<LineItem>
                    {
                        new LineItem
                        {
                            AccountCode = "200",
                            Description = "Good value item",
                            UnitAmount = 25.6m,
                            Quantity = 1m
                        }
                    }
                },
                new Invoice
                {
                    Contact = new Contact { Name = "Jack" },
                    Type = InvoiceType.AccountsReceivable,
                    LineItems = new List<LineItem>
                    {
                        new LineItem
                        {
                            AccountCode = "150",
                            Description = "Other Sales Item",
                            UnitAmount = 120.5m,
                            Quantity = 5m
                        }
                    }
                }
            }).ToList();

            Assert.AreEqual(2, invoices.Count());
            Assert.AreEqual(2, invoices.Select(p => p.Id).Count());
        }

        [Test]
        public void high_precision_unit()
        {
            var invoice = Api.Create(
                new Invoice
                {
                    Contact = new Contact { Name = "ABC Limited" },
                    Type = InvoiceType.AccountsReceivable,
					LineItems = new List<LineItem>
                    {
                        new LineItem
                        {
                            AccountCode = "200",
                            Description = "Good value item",
                            UnitAmount = 25.6591m,
                            Quantity = 1m
                        }
                    }
                });

			Assert.AreEqual(25.6591m, invoice.LineItems.First().UnitAmount);
        }

        [Test]
        public void low_precision_unit()
        {
            var invoices = Api.Invoices.UseFourDecimalPlaces(false).Create(new[]
            {
                new Invoice
                {
                    Contact = new Contact { Name = "ABC Limited" },
                    Type = InvoiceType.AccountsReceivable,
                    LineItems = new List<LineItem>
                    {
                        new LineItem
                        {
                            AccountCode = "200",
                            Description = "Good value item",
                            UnitAmount = 25.6591m,
                            Quantity = 1m
                        }
                    }
                }                
            }).ToList();

			Assert.AreEqual(25.66m, invoices.First().LineItems.First().UnitAmount);
        }

        [Test]
        public void full_example_line_items_with_tracking_categories()
        {
            const string name = "Region";
            const string option = "North";
            const string currency = "NZD";
            const string url = "http://accounting20.com/";

            var category = new Guid("351953c4-8127-4009-88c3-f9cd8c9cbe9f");
            var dueDate = DateTime.Now.AddDays(30).Date;
            var paymentDate = DateTime.Now.AddDays(20).Date;
            var reference = "Ref:" + Random.GetRandomString(10);
            
            var invoices = Api.Invoices.Create(new[]
            {
                new Invoice
                {
                    Contact = new Contact { Name = "Ariki Properties" },
                    DueDate = dueDate,
                    ExpectedPaymentDate = paymentDate,
                    Type = InvoiceType.AccountsReceivable,
                    LineAmountTypes = LineAmountType.Inclusive,
                    CurrencyCode = currency,
                    Number = Random.GetRandomString(10),
                    Reference = reference,
                    BrandingThemeId = new Guid("4c82c365-35cb-467f-bb11-dce1f2f2f67c"),
                    Url = url,
                    Status = InvoiceStatus.Submitted,
                    TotalTax = 10.89m,
                    SubTotal = 87.11m,
                    Total = 98.00m,
                    LineItems = new List<LineItem>
                    {
                        new LineItem
                        {
                            AccountCode = "200",
                            Description = "3 copies of OS X 10.6 Snow Leopard",
                            UnitAmount = 59.00m,
                            Quantity = 3m,
                            TaxAmount = 19.97m,
                            TaxType = "OUTPUT2",
                            LineAmount = 177.00m,
                            Tracking = new ItemTracking
                            {
                                new ItemTrackingCategory
                                {
                                    Id = category,
                                    Name = name,
                                    Option = option
                                }
                            }
                        },
                        new LineItem
                        {
                            AccountCode = "200",
                            Description = "Returned Apple Keyboard with Numeric Keypad (faulty)",
                            UnitAmount = -79.00m,
                            Quantity = 1m,
                            TaxAmount = -8.78m,
                            TaxType = "OUTPUT2",                            
                        }
                    }
                }                
            }).ToList();

            var invoice = Api.Invoices.Find(invoices.First().Id);

			Assert.AreEqual(category, invoice.LineItems.First().Tracking[0].Id);
			Assert.AreEqual(name, invoice.LineItems.First().Tracking[0].Name);
			Assert.AreEqual(option, invoice.LineItems.First().Tracking[0].Option);
            Assert.AreEqual(dueDate, invoice.DueDate);
            Assert.AreEqual(paymentDate, invoice.ExpectedPaymentDate);
            Assert.AreEqual(reference, invoice.Reference);
            Assert.AreEqual(currency, invoice.CurrencyCode);
            Assert.AreEqual(url, invoice.Url);
        }

        [Test]
        public void lineitems_without_account_code()
        {
            var item = Api.Items
                .Where("Code.StartsWith(\"Woo-hoo\")")
                .And("Description != null")
                .Find()
                .FirstOrDefault();

            if (item == null)
            {
                Assert.False(false, "No items");
            }

            var invoice = Api.Create(new Invoice
            {
                Contact = new Contact { Name = "ABC Limited" },
                Type = InvoiceType.AccountsReceivable,
				LineItems = new List<LineItem>
                {
                    new LineItem
                    {
                        Description = item.Description,
                        ItemCode = item.Code
                    }
                }
            });

            Assert.True(invoice.Id != Guid.Empty);
            Assert.AreEqual(InvoiceType.AccountsReceivable, invoice.Type);
			Assert.AreEqual(1, invoice.LineItems.Count());
        }
    }
}

================================================
FILE: CoreTests/Integration/Invoices/Find.cs
================================================
using System;
using System.Collections;
using System.Linq;
using NUnit.Framework;
using Xero.Api.Core.Model.Types;

namespace CoreTests.Integration.Invoices
{
    [TestFixture]
    public class Find : InvoicesTest
    {
        [Test]
        public void find_by_page()
        {
            Given_an_invoice();
            var invoices = Api.Invoices.Page(1).Find();
            
            Assert.Greater(invoices.Count(), 0);
        }

        [Test]
        public void find_by_id()
        {
            var expected  = Given_an_invoice().Id;
            var id = Api.Invoices.Find(expected).Id;

            Assert.AreEqual(expected, id);
        }

        [Test]
        public void find_by_id_list()
        {
            var created = Given_an_invoice();
            var invoices = Api.Invoices.Ids(new[] {created.Id}).Find().ToList();

            Assert.AreEqual(1, invoices.Count());
            Assert.AreEqual(created.Id, invoices.First().Id);
        }

        [Test]
        public void find_by_statuses_list()
        {
            var created = Given_an_invoice();
            var invoices = Api.Invoices.Statuses(new[] {created.Status}).Find().ToList();

            Assert.True(invoices.Any(it => it.Id == created.Id));
        }

        [Test]
        public void find_by_contact_id_list()
        {
            var created = Given_an_invoice();
            var invoices = Api.Invoices.ContactIds(new[] {created.Contact.Id}).Find().ToList();

            Assert.True(invoices.Any(it => it.Id == created.Id));
        }

        [Test]
        public void find_by_invoice_number_list()
        {
            var created = Given_an_invoice(invoiceNumber: Guid.NewGuid().ToString());
            var invoices = Api.Invoices.InvoiceNumbers(new[] {created.Number}).Find().ToList();

            Assert.True(invoices.Any(it => it.Id == created.Id));
        }

        [Test]
        public void find_by_mixture_of_query_param_lists()
        {
            var created = Given_an_invoice(invoiceNumber: Guid.NewGuid().ToString());
            var invoices = Api.Invoices
                .Ids(new [] {created.Id})
                .ContactIds(new [] { created.Contact.Id })
                .Statuses(new [] {created.Status})
                .InvoiceNumbers(new [] {created.Number})
                .Find().ToList();

            Assert.True(invoices.Any(it => it.Id == created.Id));
        }

        [Test]
        public void find_by_value()
        {
            Given_an_invoice();
            var invoices = Api.Invoices
                .Where("Type == \"ACCREC\"")
                .Find()
                .ToList();

            Assert.True(invoices.Any());
            Assert.True(invoices.All(p => p.Type == InvoiceType.AccountsReceivable));            
        }

        [Test]
        public void find_by_due_date()
        {
            Given_an_invoice();

            var today = DateTime.UtcNow;

            var invoices = Api.Invoices
                .Where(string.Format("DueDate > DateTime({0},{1},{2})", today.Year, today.Month, today.Day ))
                .Find()
                .ToList();

            Assert.True(invoices.Any());           
        }

        [Test]
        public void order_by_type()
        {
            var invoices = Api.Invoices.OrderByDescending("Type").Find();

            Assert.AreEqual(InvoiceType.AccountsReceivable, invoices.First().Type);
        }
    }
}


================================================
FILE: CoreTests/Integration/Invoices/InvoicesTest.cs
================================================
using System;
using System.Collections.Generic;
using Xero.Api.Core.Model;
using Xero.Api.Core.Model.Status;
using Xero.Api.Core.Model.Types;

namespace CoreTests.Integration.Invoices
{
    public abstract class InvoicesTest : ApiWrapperTest
    {
        public Invoice Given_an_draft_invoice(InvoiceType type = InvoiceType.AccountsPayable)
        {
            return Given_an_invoice(type);
        }

        public Invoice Given_an_authorised_invoice(InvoiceType type = InvoiceType.AccountsPayable)
        {
            return Given_an_invoice(type, InvoiceStatus.Authorised);
        }

        public Invoice Given_an_invoice(InvoiceType type = InvoiceType.AccountsPayable, InvoiceStatus status = InvoiceStatus.Draft, string invoiceNumber = null)
        {
            return Api.Create(new Invoice
            {
                Contact = new Contact { Name = "ABC Bank" },
                Type = type,
                Date = DateTime.UtcNow,
                DueDate = DateTime.UtcNow.AddDays(90),
                LineAmountTypes = LineAmountType.Inclusive,
                Status = status,
                Number = invoiceNumber,
				LineItems = new List<LineItem>
                {
                    new LineItem
                    {
                        AccountCode = "200",
                        Description = "Good value item",
                        LineAmount = 100m
                    }
                }
                
            });
        }

        public Invoice Given_a_description_only_invoice(InvoiceType type = InvoiceType.AccountsPayable)
        {
            return Api.Create(new Invoice
            {
                Contact = new Contact { Name = "Richard" },
                Type = type,
				LineItems = new List<LineItem>
                {
                    new LineItem
                    {
                        Description = "This is description only",
                        LineAmount = 100m
                    }
                }
            });
        }
    }
}


================================================
FILE: CoreTests/Integration/Invoices/OnlineInvoiceUrl.cs
================================================
using NUnit.Framework;
using Xero.Api.Core.Model.Status;
using Xero.Api.Core.Model.Types;

namespace CoreTests.Integration.Invoices
{
    [TestFixture]
    public class OnlineInvoiceUrl : InvoicesTest
    {

        [Test]
        public void find_the_online_invoice_url_for_an_accrec_invoice()
        {
            var invoice = Given_an_invoice(InvoiceType.AccountsReceivable, InvoiceStatus.Authorised);

            var onlineInvoiceUrl = Api.Invoices.RetrieveOnlineInvoiceUrl(invoice.Id);

            Assert.True(!string.IsNullOrEmpty(onlineInvoiceUrl.OnlineInvoiceUrl));
        }
    }
}


================================================
FILE: CoreTests/Integration/Invoices/SummarizeErrors.cs
================================================
using System;
using System.Collections.Generic;
using System.Linq;
using NUnit.Framework;
using Xero.Api.Core.Model;
using Xero.Api.Core.Model.Status;
using Xero.Api.Core.Model.Types;
using Xero.Api.Infrastructure.Exceptions;

namespace CoreTests.Integration.Invoices
{
    [TestFixture]
    public class SummarizeErrors : InvoicesTest
    {
        [Test]
        public void summariseErrors_gives_200()
        {
            var invoices = Given_a_bad_invoice(summariseErrors: false);

            Assert.True(invoices.Count(p => p.ValidationStatus == ValidationStatus.Error) == 1);
            Assert.True(invoices.Count(p => p.ValidationStatus == ValidationStatus.Ok) == 1);
        }

        [Test] public void errors_gives_validation_exception()
        {
            Assert.Throws<ValidationException>(() => Given_a_bad_invoice());
        }

        private IEnumerable<Invoice> Given_a_bad_invoice(InvoiceType type = InvoiceType.AccountsPayable, InvoiceStatus status = InvoiceStatus.Draft, bool summariseErrors = true)
        {
            Api.Invoices.SummarizeErrors(summariseErrors);
            return Api.Create(new[]
            {
                new Invoice
                {
                    Contact = new Contact {Name = "ABC Bank"},
                    Type = type,
                    Date = DateTime.UtcNow,
                    DueDate = DateTime.UtcNow.AddDays(90),
                    LineAmountTypes = LineAmountType.Inclusive,
                    Status = status,
                    LineItems = new List<LineItem>
                    {
                        new LineItem
                        {
                            AccountCode = "200",
                            Description = "Good value item",
                            LineAmount = 100m
                        }
                    }
                },
                new Invoice
                {
                    Contact = new Contact
                    {
                        Name = "ABC Bank",
                        EmailAddress = "this_is_!_valid"
                    },
                    Type = type,
                    Date = DateTime.UtcNow,
                    DueDate = DateTime.UtcNow.AddDays(90),
                    LineAmountTypes = LineAmountType.Inclusive,
                    Status = status,
                    LineItems = new List<LineItem>
                    {
                        new LineItem
                        {
                            AccountCode = "200",
                            Description = "Good value item",
                            LineAmount = 100m
                        }
                    }
                }
            });
        }
    }
}


================================================
FILE: CoreTests/Integration/Items/Create.cs
================================================
using System;
using NUnit.Framework;
using Xero.Api.Core.Model;

namespace CoreTests.Integration.Items
{
    [TestFixture]
    public class Create : ApiWrapperTest
    {
        [Test]
        public void create_simple_item()
        {
            var code = "Woo-hoo " + Random.GetRandomString(10);

            var item = Api.Create(new Item
            {
                Code = code
            });

            Assert.IsTrue(Guid.Empty != item.Id);
            Assert.AreEqual(code, item.Code);
        }

        [Test]
        public void create_full_item()
        {
            var code = "Woo-hoo " + Random.GetRandomString(10);

            var item = Api.Create(new Item
            {
                Code = code,
                Description = "Buy cheap sell high",
                SalesDetails = new SalesDetails
                {
                    AccountCode = "200",
                    UnitPrice = 25.00m
                },
                PurchaseDetails = new PurchaseDetails
                {
                    AccountCode = "200",
                    UnitPrice = 15.0m
                }
            });
        }
    }
}


================================================
FILE: CoreTests/Integration/Items/Delete.cs
================================================
using System;
using CoreTests.Integration.Items.TrackedItems;
using NUnit.Framework;
using Xero.Api.Core.Model;
using Xero.Api.Infrastructure.Exceptions;

namespace CoreTests.Integration.Items
{
    [TestFixture]
    public class Delete : TrackedInventoryTest
    {
        [Test]
        public void you_can_delete_an_item()
        {
            Given_a_tracked_item();

            Api.Items.Delete(CreatedItem);

            Its_not_there_when_I_try_to_find_it(CreatedItem);
        }

        [Test]
        public void but_not_if_its_involved_in_a_transaction()
        {
            Given_a_tracked_item();

            Given_an_ACCPAY_invoice_using_the_item_with_code(CreatedItem.Code);

            When_I_try_to_Delete_it_400s();
        }

        [Test]
        public void and_it_will_404_if_you_try_to_delete_a_item_thats_not_there()
        {
            CreatedItem = new Item
            {
                Id = Guid.NewGuid()
            };

            When_I_try_to_Delete_it_404s();
        }


        private void When_I_try_to_Delete_it_404s()
        {
            Assert.Throws<NotFoundException>(() => Api.Items.Delete(CreatedItem));
        }

        private void When_I_try_to_Delete_it_400s()
        {
            Assert.Throws<ValidationException>(() => Api.Items.Delete(CreatedItem));
        }

        private void Its_not_there_when_I_try_to_find_it(Item theItem)
        {
            Assert.Throws<NotFoundException>(() => Api.Items.Find(theItem.Id));
        }
    }
}


================================================
FILE: CoreTests/Integration/Items/TrackedItems/Create.cs
================================================
using System;
using NUnit.Framework;
using Xero.Api.Core.Model;

namespace CoreTests.Integration.Items.TrackedItems
{
    public class Create : TrackedInventoryTest
    {


        [Test]
        public void Can_create_an_item_with_minimal_properties()
        {
            Given_an_inventory_account();
            Given_a_direct_cost_account();

            var item = Api.Items.Create(new Item
            {
                Code = "Tracked Item " + Random.GetRandomString(10),
                InventoryAssetAccountCode = InventoryAccountCode,
                PurchaseDetails = new PurchaseDetails
                {
                    COGSAccountCode = DirectCostsAccountCode
                }

            });

            Assert.True(item.IsTrackedAsInventory,
                "Expected the item to be tracked as inventory, but IsTrackedAsInventory is false");
        }

        [Test]
        public void Can_create_an_item_with_full_details()
        {
            Given_an_inventory_account();
            Given_a_direct_cost_account();
            Given_a_revenue_account();

            var code = "Tracked Item " + Random.GetRandomString(10);

            var item = Api.Items.Create(new Item
            {
                Code = code,
                Description = "Sell me",
                PurchaseDescription = "Purchase me",
                PurchaseDetails = new PurchaseDetails
                {
                    UnitPrice = 75.5555m,
                    TaxType = "INPUT2",
                    COGSAccountCode = DirectCostsAccountCode
                },
                SalesDetails = new SalesDetails
                {
                    UnitPrice = 1020.5555m,
                    AccountCode = RevenueAccountCode,
                    TaxType = "OUTPUT2"
                },

                Name = "Full Tracked Item",
                InventoryAssetAccountCode = InventoryAccountCode,
                IsSold = true,
                IsPurchased = true
            });

            Assert.True(item.Id != Guid.Empty);
            Assert.True(item.IsTrackedAsInventory = true);
            Assert.AreEqual(item.Code, code,
                string.Format("Expected the create item's code '{0}' to equal '{1}', but were not equal", item.Code,
                    code));
        }
    }

}


================================================
FILE: CoreTests/Integration/Items/TrackedItems/Find.cs
================================================
using NUnit.Framework;

namespace CoreTests.Integration.Items.TrackedItems
{
    public class Find : TrackedInventoryTest
    {
        [Test]
        public void Can_get_tracked_item_by_id()
        {
            Given_a_tracked_item();

            var trackedItem = Api.Items.Find(CreatedItem.Id);

            Assert.AreEqual(CreatedItem.Id, trackedItem.Id, "Expected the ID of the created item and retrieved item to be the same but weren't");
            Assert.True(trackedItem.IsTrackedAsInventory, "Expected the retrieved items IsTrackedAsInventory value to be true, but was false");
        }
    }
}


================================================
FILE: CoreTests/Integration/Items/TrackedItems/TrackedInventoryTest.cs
================================================
using System;
using System.Collections.Generic;
using System.Linq;
using Xero.Api.Core.Model;
using Xero.Api.Core.Model.Status;
using Xero.Api.Core.Model.Types;

namespace CoreTests.Integration.Items.TrackedItems
{
    public class TrackedInventoryTest : ApiWrapperTest
    {
        protected Item CreatedItem;
        protected Invoice CreatedAccpayInvoice { get; set; }
        protected Invoice CreatedAccrecInvoice { get; set; }
        protected string InventoryAccountCode;
        protected string DirectCostsAccountCode;
        protected string RevenueAccountCode;

        public void Given_a_tracked_item()
        {
            if (string.IsNullOrEmpty(InventoryAccountCode))
            {
                Given_an_inventory_account();
            }

            if (string.IsNullOrEmpty(DirectCostsAccountCode))
            {
                Given_a_direct_cost_account();
            }

            if (string.IsNullOrEmpty(RevenueAccountCode))
            {
                Given_a_revenue_account();
            }

            var code = "Tracked Item" + Random.GetRandomString(10);

            var item = Api.Items.Create(new Item
            {
                Code = code,
                Description = "Sell me",
                PurchaseDescription = "Purchase me",
                PurchaseDetails = new PurchaseDetails
                {
                    UnitPrice = 75.5555m,
                    TaxType = "INPUT2",
                    COGSAccountCode = DirectCostsAccountCode
                },
                SalesDetails = new SalesDetails
                {
                    UnitPrice = 1020.5555m,
                    AccountCode = RevenueAccountCode,
                    TaxType = "OUTPUT2"
                },

                Name = "Full Tracked Item",
                InventoryAssetAccountCode = InventoryAccountCode,
                IsSold = true,
                IsPurchased = true
            });

            CreatedItem = item;
        }

        public void Given_an_untracked_item()
        {
            if (string.IsNullOrEmpty(DirectCostsAccountCode))
            {
                Given_a_direct_cost_account();
            }

            if (string.IsNullOrEmpty(RevenueAccountCode))
            {
                Given_a_revenue_account();
            }

            var code = "Untracked Item" + Random.GetRandomString(10);

            var item = Api.Items.Create(new Item
            {
                Code = code,
                Description = "Sell me",
                PurchaseDescription = "Purchase me",
                PurchaseDetails = new PurchaseDetails
                {
                    UnitPrice = 75.5555m,
                    TaxType = "INPUT2",
                    AccountCode = DirectCostsAccountCode
                },
                SalesDetails = new SalesDetails
                {
                    UnitPrice = 1020.5555m,
                    AccountCode = RevenueAccountCode,
                    TaxType = "OUTPUT2"
                },

                Name = "Untracked Item",
                IsSold = true,
                IsPurchased = true
            });

            CreatedItem = item;
        }

        protected void Given_a_direct_cost_account()
        {
            var directCostsAccount = Api.Accounts.Where("Type == \"DIRECTCOSTS\"").Find().FirstOrDefault();

            if (directCostsAccount == null)
            {
                directCostsAccount = Api.Accounts.Create(new Account
                {
                    Code = Random.GetRandomString(10),
                    Type = AccountType.DirectCosts,
                    Description = "Direct costs account",
                    Name = "Direct costs account"
                });
            }

            DirectCostsAccountCode = directCostsAccount.Code;
        }

        protected void Given_a_revenue_account()
        {
            var revenueAccount = Api.Accounts.Where("Type == \"REVENUE\"").Find().FirstOrDefault();

            if (revenueAccount == null)
            {
                revenueAccount = Api.Accounts.Create(new Account
                {
                    Code = Random.GetRandomString(10),
                    Type = AccountType.Revenue,
                    Description = "Revenue account",
                    Name = "Revenue account"
                });
            }

            RevenueAccountCode = revenueAccount.Code;
        }

        protected void Given_an_inventory_account()
        {
            var inventoryAccount = Api.Accounts.Where("Type == \"INVENTORY\"").Find().FirstOrDefault();

            if (inventoryAccount == null)
            {
                inventoryAccount = Api.Accounts.Create(new Account
                {
                    Code = Random.GetRandomString(10),
                    Type = AccountType.Inventory,
                    Description = "The account to hold all the things",
                    Name = "My inventory account"
                });
            }

            InventoryAccountCode = inventoryAccount.Code;
        }

        protected void Given_an_ACCPAY_invoice_using_the_item_with_code(string code)
        {
            var invoice = new Invoice
            {
                Contact = new Contact { Name = "ABC Bank" },
                Type = InvoiceType.AccountsPayable,
                Date = DateTime.UtcNow,
                DueDate = DateTime.UtcNow.AddDays(90),
                LineAmountTypes = LineAmountType.Inclusive,
                Status = InvoiceStatus.Authorised,
                LineItems = new List<LineItem>
                {
                    new LineItem
                    {
                        ItemCode = code,
                        AccountCode = InventoryAccountCode,
                        Quantity = 2
                    }
                }

            };

            CreatedAccpayInvoice = Api.Invoices.Create(invoice);
        }


        protected void Given_a_zero_total_ACCPAY_invoice_using_the_item_with_code(string code)
        {
            var invoice = new Invoice
            {
                Contact = new Contact { Name = "ABC Bank" },
                Type = InvoiceType.AccountsPayable,
                Date = DateTime.UtcNow,
                DueDate = DateTime.UtcNow.AddDays(90),
                LineAmountTypes = LineAmountType.Inclusive,
                Status = InvoiceStatus.Authorised,
				LineItems = new List<LineItem>
                {
                    new LineItem
                    {
                        ItemCode = code,
                        AccountCode = InventoryAccountCode,
                        Quantity = 2
                    },
                    new LineItem
                    {
                        Description = "Inventory Adjustment",
                        AccountCode = DirectCostsAccountCode, //Using this account for the example. You would probably have your own inventory adjustments account
                        Quantity = 2,
                        UnitAmount = CreatedItem.PurchaseDetails.UnitPrice * -1
                    }
                }
                
            };

            CreatedAccpayInvoice = Api.Invoices.Create(invoice);
        }

        protected void Given_an_ACCREC_invoice_using_the_item_with_code(string code)
        {
            var invoice = new Invoice
            {
                Contact = new Contact { Name = "ABC Bank" },
                Type = InvoiceType.AccountsReceivable,
                Date = DateTime.UtcNow,
                DueDate = DateTime.UtcNow.AddDays(90),
                LineAmountTypes = LineAmountType.Inclusive,
                Status = InvoiceStatus.Authorised,
                LineItems = new List<LineItem>
                {
                    new LineItem
                    {
                        ItemCode = code,
                        AccountCode = RevenueAccountCode,
                        Quantity = 2
                    }
                }
            };

            CreatedAccrecInvoice = Api.Invoices.Create(invoice);
        }

        protected void Given_a_zero_total_ACCREC_invoice_using_the_item_with_code(string code)
        {
            var invoice = new Invoice
            {
                Contact = new Contact { Name = "ABC Bank" },
                Type = InvoiceType.AccountsReceivable,
                Date = DateTime.UtcNow,
                DueDate = DateTime.UtcNow.AddDays(90),
                LineAmountTypes = LineAmountType.Inclusive,
                Status = InvoiceStatus.Authorised,
                LineItems = new List<LineItem>
                {
                    new LineItem
                    {
                        ItemCode = code,
                        AccountCode = RevenueAccountCode,
                        Quantity = 2
                    },
                    new LineItem
                    {
                        Description = "Inventory Adjustment",
                        AccountCode = DirectCostsAccountCode, //Using this account for the example. You would probably want to have your own inventory adjustments account
                        Quantity = 2,
                        UnitAmount = CreatedItem.PurchaseDetails.UnitPrice * -1
                    }
                }

            };

            CreatedAccrecInvoice = Api.Invoices.Create(invoice);
        }
    }
}

================================================
FILE: CoreTests/Integration/Items/TrackedItems/Update.cs
================================================
using NUnit.Framework;

namespace CoreTests.Integration.Items.TrackedItems
{
    public class Update : TrackedInventoryTest
    {
        [Test]
        public void Can_turn_untracked_item_to_tracked_item()
        {
            Given_an_untracked_item();

            Given_an_inventory_account();

            CreatedItem.InventoryAssetAccountCode = InventoryAccountCode;
            CreatedItem.PurchaseDetails.AccountCode = null;
            CreatedItem.PurchaseDetails.COGSAccountCode = DirectCostsAccountCode;

            var updatedItem = Api.Items.Update(CreatedItem);

            Assert.AreEqual(updatedItem.Id, CreatedItem.Id, "Expected the item's ID to be the same after creating and updating but they were different.");
            Assert.IsTrue(updatedItem.IsTrackedAsInventory, "Expected the item's IsTrackedAsInventory value to be true but was false");
        }

        [Test]
        public void Can_update_an_item_to_make_it_not_tracked_and_not_for_purchase()
        {
            Given_a_tracked_item();

            CreatedItem.PurchaseDescription = null;
            CreatedItem.PurchaseDetails = null;
            CreatedItem.InventoryAssetAccountCode = null;
            CreatedItem.IsPurchased = false;

            var updatedItem = Api.Items.Update(CreatedItem);

            Assert.AreEqual(updatedItem.Id, CreatedItem.Id, "Expected the item's ID to be the same after creating and updating but they were different.");
            Assert.IsFalse(updatedItem.IsTrackedAsInventory, "Expected the item's IsTrackedAsInventory value to be false but was true");
            Assert.IsFalse(updatedItem.IsPurchased.Value, "Expected the updated item's IsPurchased value to be false but was true.");
        }

        [Test]
        public void Can_update_an_item_to_make_it_not_tracked_and_not_for_sale()
        {
            Given_a_tracked_item();

            CreatedItem.Description = null;
            CreatedItem.SalesDetails = null;
            CreatedItem.InventoryAssetAccountCode = null;
            CreatedItem.IsSold = false;
            CreatedItem.PurchaseDetails.AccountCode = DirectCostsAccountCode;
            CreatedItem.PurchaseDetails.COGSAccountCode = null;

            var updatedItem = Api.Items.Update(CreatedItem);

            Assert.AreEqual(updatedItem.Id, CreatedItem.Id, "Expected the item's ID to be the same after creating and updating but they were different.");
            Assert.IsFalse(updatedItem.IsTrackedAsInventory, "Expected the item's IsTrackedAsInventory value to be false but was true");
            Assert.IsFalse(updatedItem.IsSold.Value, "Expected the updated item's IsPurchased value to be false but was true.");
        }

        [Test]
        public void Can_update_an_item_to_make_it_not_tracked_but_still_for_sale_and_purchase()
        {
            Given_a_tracked_item();

            CreatedItem.PurchaseDetails.COGSAccountCode = null;
            CreatedItem.InventoryAssetAccountCode = null;

            var updatedItem = Api.Items.Update(CreatedItem);

            Assert.AreEqual(updatedItem.Id, CreatedItem.Id, "Expected the item's ID to be the same after creating and updating but they were different.");
            Assert.IsFalse(updatedItem.IsTrackedAsInventory, "Expected the item's IsTrackedAsInventory value to be false but was true");
            Assert.IsTrue(updatedItem.IsSold.Value, "Expected the updated item's IsSold value to be true but was false.");
            Assert.IsTrue(updatedItem.IsPurchased.Value, "Expected the updated item's IsPurchased value to be true but was false.");
        }
    }
}


================================================
FILE: CoreTests/Integration/Items/TrackedItems/Using_tracked_items.cs
================================================
using NUnit.Framework;
using Xero.Api.Core.Model;

namespace CoreTests.Integration.Items.TrackedItems
{
    public class Using_tracked_items : TrackedInventoryTest
    {
        //Purchase inventory like this
        [Test]
        public void Purchase_some_inventory_with_an_ACCPAY_invoice()
        {
            Given_a_tracked_item();

            Then_the_quantity_of_the_tracked_item_is_zero(CreatedItem);

            Given_an_ACCPAY_invoice_using_the_item_with_code(CreatedItem.Code);

            var item = Api.Items.Find(CreatedItem.Id);

            Then_the_quantity_of_the_tracked_item_is_more_than_zero(item);
        }

        //Sell inventory like this
        [Test]
        public void Sell_inventory_with_an_ACCREC_invoice()
        {
            Given_a_tracked_item();

            Given_a_tracked_item();

            Then_the_quantity_of_the_tracked_item_is_zero(CreatedItem);

            Given_an_ACCPAY_invoice_using_the_item_with_code(CreatedItem.Code);

            var item = Api.Items.Find(CreatedItem.Id);

            Then_the_quantity_of_the_tracked_item_is_more_than_zero(item);

            Given_an_ACCREC_invoice_using_the_item_with_code(item.Code);

            item = Api.Items.Find(item.Id);

            Then_the_quantity_of_the_tracked_item_is_zero(item);
        }

        //Make 'increase' adjustments like this
        [Test]
        public void Creating_a_zero_total_ACCPAY_invoice_increases_a_tracked_items_quantity_as_an_adjustment()
        {
            Given_a_tracked_item();

            Then_the_quantity_of_the_tracked_item_is_zero(CreatedItem);

            Given_a_zero_total_ACCPAY_invoice_using_the_item_with_code(CreatedItem.Code);

            var item = Api.Items.Find(CreatedItem.Id);
            Then_the_quantity_of_the_tracked_item_is_more_than_zero(item);
        }

        //Make 'decrease' adjustments like this
        [Test]
        public void Creating_a_zero_total_ACCREC_invoice_decreases_a_tracked_items_quantity()
        {
            Given_a_tracked_item();

            Then_the_quantity_of_the_tracked_item_is_zero(CreatedItem);

            Given_a_zero_total_ACCPAY_invoice_using_the_item_with_code(CreatedItem.Code);

            var item = Api.Items.Find(CreatedItem.Id);
            Then_the_quantity_of_the_tracked_item_is_more_than_zero(item);
 
            Given_a_zero_total_ACCREC_invoice_using_the_item_with_code(CreatedItem.Code);

            item = Api.Items.Find(CreatedItem.Id);

            Then_the_quantity_of_the_tracked_item_is_zero(item);
        }


        //Find quantity and cost details of an item like this
        [Test]
        public void Finding_a_tracked_item_gives_you_quantity_on_hand_and_total_cost_pool()
        {
            //Create a tracked item with no quantity, and therefore no total cost pool
            Given_a_tracked_item();

            var item = Api.Items.Find(CreatedItem.Id);

            var quantity = item.QuantityOnHand;
            Assert.True(quantity == 0, "Expected the quanity on hand of a new inventory item to be 0");

            var totalCostPool = item.TotalCostPool;
            Assert.True(totalCostPool == 0, "Expected the total cost pool of a new inventory item to be 0");

        }

        private void Then_the_quantity_of_the_tracked_item_is_zero(Item item)
        {
            Assert.True(item.QuantityOnHand == 0);
        }

        private void Then_the_quantity_of_the_tracked_item_is_more_than_zero(Item item)
        {
            Assert.True(item.QuantityOnHand > 0);
        }
    }
}


================================================
FILE: CoreTests/Integration/Items/Update.cs
================================================
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using NUnit.Framework;
using Xero.Api.Core.Model;

namespace CoreTests.Integration.Items
{
    [TestFixture]
    public class Update : ApiWrapperTest
    {
        [Test]
        public void update_an_item()
        {
            var code = "Woo-hoo " + Random.GetRandomString(10);
            var the_item = Api.Create(new Item
            {
                Code = code
            });

            var updated_item = Api.Update(new Item
            {
                Id = the_item.Id,
                Code = code,
                Description = "The Woo-hoo item",
                SalesDetails = new SalesDetails
                {
                    AccountCode = "200",
                    UnitPrice = 25.00m
                }                
            });

            Assert.IsTrue(Guid.Empty != updated_item.Id);
            Assert.AreEqual(code, the_item.Code);
            Assert.AreEqual(25.00m, updated_item.SalesDetails.UnitPrice);
        }
    }
}


================================================
FILE: CoreTests/Integration/Journals/Find.cs
================================================
using System.Linq;
using NUnit.Framework;

namespace CoreTests.Integration.Journals
{
    [TestFixture]
    public class Find : ApiWrapperTest
    {
        [Test]
        public void find_journals()
        {
            var journals = Api.Journals.Find();

            Assert.That(journals.Any());
        }

        [Test]
        public void find_journals_offset()
        {
            var journals = Api.Journals.Find().ToList();

            if (journals.Count() == 100)
            {
                var offset = journals.Max(p => p.Number);

                Assert.That(Api.Journals.Offset(offset)
                    .Find()
                    .Any());
            }
        }
    }
}


================================================
FILE: CoreTests/Integration/LinkedTransactions/Create.cs
================================================
using NUnit.Framework;
using Xero.Api.Core.Model;

namespace CoreTests.Integration.LinkedTransactions
{
    public class Create : LinkedTransactionTest
    {
        [Test]
        public void can_create_a_linked_transaction_with_just_source_details()
        {
            Given_a_source_invoice();
            
            var linkedTransaction = Api.LinkedTransactions.Create(new LinkedTransaction
            {
                SourceTransactionID = SourceId,
                SourceLineItemID = SourceLineItemId
            });

            Then_the_linked_transaction_has_an_id(linkedTransaction);
            Then_the_source_details_are_correct(linkedTransaction, SourceId, SourceLineItemId);
        }

        

        [Test]
        public void can_create_a_linked_transaction_with_source_details_assigned_to_a_Contact()
        {
            Given_a_contact();
            Given_a_source_invoice();

            var linkedTransaction = Api.LinkedTransactions.Create(new LinkedTransaction
            {
                SourceTransactionID = SourceId,
                SourceLineItemID = SourceLineItemId,
                ContactID = ContactId
            });

            Then_the_linked_transaction_has_an_id(linkedTransaction);
            Then_the_source_details_are_correct(linkedTransaction, SourceId, SourceLineItemId);
            Then_the_contact_details_are_correct(linkedTransaction, ContactId);
        }

        [Test]
        public void can_create_a_fully_allocated_linkedTransaction()
        {
            Given_a_contact();

            Given_a_source_invoice();

            Given_a_target_invoice(Contact);


            var linkedTransaction = Api.LinkedTransactions.Create(new LinkedTransaction
            {
                SourceTransactionID = SourceId,
                SourceLineItemID = SourceLineItemId,
                ContactID = ContactId,
                TargetTransactionID = TargetId,
                TargetLineItemID = TargetLineItemId
            });

            Then_the_linked_transaction_has_an_id(linkedTransaction);
            Then_the_source_details_are_correct(linkedTransaction, SourceId, SourceLineItemId);
            Then_the_contact_details_are_correct(linkedTransaction, ContactId);
            Then_the_target_details_are_correct(linkedTransaction, TargetId, TargetLineItemId);
        }

    }
}


================================================
FILE: CoreTests/Integration/LinkedTransactions/Delete.cs
================================================
using NUnit.Framework;
using Xero.Api.Infrastructure.Exceptions;

namespace CoreTests.Integration.LinkedTransactions
{
    public class Delete : LinkedTransactionTest
    {
        [Test]
        public void can_delete_linked_transactions()
        {
            Given_a_basic_linked_transaction();

            var id = LinkedTransactionId;

            Api.LinkedTransactions.Delete(LinkedTransaction);

            //After deleting the linked transaction, it no longer exists so we exopect to get a 404 NotFound when looking for it.
            Assert.Throws<NotFoundException>(() => Api.LinkedTransactions.Find(id));
        }
    }
}


================================================
FILE: CoreTests/Integration/LinkedTransactions/Find.cs
================================================
using System.Linq;
using NUnit.Framework;

namespace CoreTests.Integration.LinkedTransactions
{
    public class Find : LinkedTransactionTest
    {
        [Test]
        public void find_by_page()
        {
            Given_a_basic_linked_transaction();
            var linkedTransactions = Api.LinkedTransactions.Page(1).Find();

            Assert.Greater(linkedTransactions.Count(), 0);
        }

        [Test]
        public void find_by_id()
        {
            Given_a_basic_linked_transaction();
            var expected = LinkedTransactionId;

            var linkedTransaction = Api.LinkedTransactions.Find(expected);

            Assert.AreEqual(expected, linkedTransaction.Id);
        }

        [Test]
        public void find_by_source_transaction_id()
        {
            Given_a_basic_linked_transaction();
            var sourceTransactionId = SourceId;

            var linkedTransactions = Api.LinkedTransactions.WhereSourceId(sourceTransactionId).Find().ToList();
            
            Assert.Greater(linkedTransactions.Count(), 0);
            Assert.AreEqual(sourceTransactionId, linkedTransactions.First().SourceTransactionID);
        }

        [Test]
        public void find_by_contact_id()
        {
            Given_a_linked_transaction_assigned_to_a_contact();
            var contactId = ContactId;

            var linkedTransactions = Api.LinkedTransactions.WhereContactId(contactId).Find().ToList();

            Assert.Greater(linkedTransactions.Count(), 0);
            Assert.AreEqual(contactId, linkedTransactions.First().ContactID);
        }

        [Test]
        public void find_by_target_transaction_id()
        {
            Given_a_fully_allocated_linked_transaction();
            var targetTransactionId = TargetId;

            var linkedTransactions = Api.LinkedTransactions.WhereTargetId(targetTransactionId).Find().ToList();

            Assert.Greater(linkedTransactions.Count(), 0);
            Assert.AreEqual(targetTransactionId, linkedTransactions.First().TargetTransactionID);
        }
    }
}


================================================
FILE: CoreTests/Integration/LinkedTransactions/LinkedTransactionTest.cs
================================================
using System;
using System.Collections.Generic;
using System.Linq;
using NUnit.Framework;
using Xero.Api.Core.Model;
using Xero.Api.Core.Model.Status;
using Xero.Api.Core.Model.Types;

namespace CoreTests.Integration.LinkedTransactions
{
    public abstract class LinkedTransactionTest : ApiWrapperTest
    {
        protected Invoice SourceInvoice { get; set; }
        protected Guid SourceId { get { return SourceInvoice.Id; } }
        protected Guid SourceLineItemId { get { return SourceInvoice.LineItems[0].LineItemId; } }

        protected Contact Contact { get; set; }
        protected Guid ContactId { get { return Contact.Id; } }

        protected Invoice TargetInvoice { get; set; }
        protected Guid TargetId { get { return TargetInvoice.Id; } }
        protected Guid TargetLineItemId { get { return TargetInvoice.LineItems[0].LineItemId; } }

        protected LinkedTransaction LinkedTransaction { get; set; }
        protected Guid LinkedTransactionId { get { return LinkedTransaction.Id; } }

        protected void Given_a_basic_linked_transaction()
        {
            Given_a_source_invoice();

            LinkedTransaction = Api.LinkedTransactions.Create(new LinkedTransaction
            {
                SourceTransactionID = SourceId,
                SourceLineItemID = SourceLineItemId
            });
        }

        protected void Given_a_linked_transaction_assigned_to_a_contact()
        {
            Given_a_source_invoice();
            Given_a_contact();

            LinkedTransaction = Api.LinkedTransactions.Create(new LinkedTransaction
            {
                SourceTransactionID = SourceId,
                SourceLineItemID = SourceLineItemId,
                ContactID = ContactId
            });
        }

        protected void Given_a_fully_allocated_linked_transaction()
        {
            Given_a_source_invoice();
            Given_a_contact();
            Given_a_target_invoice(Contact);

            LinkedTransaction = Api.LinkedTransactions.Create(new LinkedTransaction
            {
                SourceTransactionID = SourceId,
                SourceLineItemID = SourceLineItemId,
                ContactID = ContactId,
                TargetTransactionID = TargetId,
                TargetLineItemID = TargetLineItemId
            });
        }

        protected void Given_a_source_invoice()
        {
            SourceInvoice = Given_an_invoice();
        }

        protected void Given_a_target_invoice(Contact contact = null)
        {
            TargetInvoice = Given_an_invoice(InvoiceType.AccountsReceivable, contact: contact);
        }

        private Invoice Given_an_invoice(InvoiceType type = InvoiceType.AccountsPayable, InvoiceStatus status = InvoiceStatus.Authorised, decimal amount = 100m, string accountCode = "100", Contact contact = null)
        {
            if (contact == null)
                contact = new Contact {Name = "ABC Bank"};

            return Api.Create(new Invoice
            {
                Contact = contact,
                Type = type,
                Date = DateTime.UtcNow,
                DueDate = DateTime.UtcNow.AddDays(90),
                LineAmountTypes = LineAmountType.Inclusive,
                Status = status,
                LineItems = new List<LineItem>
                {
                    new LineItem
                    {
                        AccountCode = "200",
                        Description = "Good value item 1",
                        LineAmount = 100m
                    },
                    new LineItem
                    {
                        AccountCode = "200",
                        Description = "Good value item 2",
                        LineAmount = 100m
                    }
                }

            });
        }

        protected void Given_a_contact()
        {
            var contacts = Api.Contacts.Find().ToList();

            if (contacts.Any())
            {
                Contact = contacts.First();
            }

            Contact = Api.Contacts.Create(new Contact
            {
                Name = "Phil" + Guid.NewGuid().ToString("N")
            });
        }

        protected void Then_the_linked_transaction_has_an_id(LinkedTransaction linkedTransaction)
        {
            Assert.True(linkedTransaction.Id != Guid.Empty);
        }

        protected void Then_the_source_details_are_correct(LinkedTransaction linkedTransaction, Guid sourceId, Guid sourceLineItemId)
        {
            Assert.True(linkedTransaction.SourceTransactionID == sourceId);
            Assert.True(linkedTransaction.SourceLineItemID == sourceLineItemId);
        }

        protected void Then_the_target_details_are_correct(LinkedTransaction linkedTransaction, Guid targetId, Guid targetLineItemId)
        {
            Assert.True(linkedTransaction.TargetTransactionID == targetId);
            Assert.True(linkedTransaction.TargetLineItemID == targetLineItemId);
        }

        protected void Then_the_contact_details_are_correct(LinkedTransaction linkedTransaction, Guid contactId)
        {
            Assert.True(linkedTransaction.ContactID == contactId);
        }
    }
}

================================================
FILE: CoreTests/Integration/LinkedTransactions/Update.cs
================================================
using System.ComponentModel;
using NUnit.Framework;

namespace CoreTests.Integration.LinkedTransactions
{
    public class Update : LinkedTransactionTest
    {
        [Test]
        public void can_assign_a_contact_to_an_existing_linked_transaction()
        {
            Given_a_basic_linked_transaction();
            Given_a_contact();
            LinkedTransaction.ContactID = ContactId;

            var linkedTransaction = Api.LinkedTransactions.Update(LinkedTransaction);

            Assert.True(linkedTransaction.Id == LinkedTransactionId);
            Then_the_contact_details_are_correct(linkedTransaction, ContactId);
        }

        [Test]
        public void can_allocate_an_existing_linked_transaction_to_a_target_transaction()
        {
            Given_a_linked_transaction_assigned_to_a_contact();

            Given_a_target_invoice(Contact);

            LinkedTransaction.TargetTransactionID = TargetId;
            LinkedTransaction.TargetLineItemID = TargetLineItemId;

            var linkedTransaction = Api.LinkedTransactions.Update(LinkedTransaction);

            Assert.True(linkedTransaction.Id == LinkedTransactionId);
            Then_the_contact_details_are_correct(linkedTransaction, ContactId);
            Then_the_target_details_are_correct(linkedTransaction, TargetId, TargetLineItemId);
        }
    }
}


================================================
FILE: CoreTests/Integration/ManualJournals/Create.cs
================================================
using System;
using System.Collections.Generic;
using System.Linq;
using NUnit.Framework;
using Xero.Api.Core.Model;

namespace CoreTests.Integration.ManualJournals
{
    [TestFixture]
    public class Create : ManualJournalsTest
    {
        [TestFixtureSetUp]
        public void CreateSetUp()
        {
            ManualJournalsSetUp();
        }

        [Test]
        public void create_manual_journal()
        {
            const string narration = "We know what we want to do";
            const int amount = 50;

            var manual = Given_a_manual_journal(narration, amount);

            Assert.AreEqual(DateTime.Now.Date, manual.Date);
            Assert.AreEqual(narration, manual.Narration);
            Assert.True(manual.Lines.All(p => amount == Math.Abs(p.Amount)));
            Assert.NotNull(manual.Lines.Single(p => Revenue.Code == p.AccountCode));
            Assert.NotNull(manual.Lines.Single(p => Sales.Code == p.AccountCode));
        }

        [Test]
        public void create_complex_manual_journal()
        {
            const string narration = "We know what we want to do";

            var manual = Api.Create(new ManualJournal
            {
                Narration = narration,
                Lines = new List<Line>
                {
                    new Line
                    {
                        Amount = 12.5m,
                        AccountCode = Revenue.Code
                    },
                    new Line
                    {
                        Amount = 25,
                        AccountCode = Revenue.Code
                    },
                    new Line
                    {
                        Amount = 12.5m,
                        AccountCode = Sales.Code
                    },
                    new Line
                    {
                        Amount = -50m,
                        AccountCode = Sales.Code
                    }
                }
            });

            Assert.AreEqual(0, manual.Lines.Sum(p => p.Amount));
            Assert.AreEqual(DateTime.Now.Date, manual.Date);
            Assert.AreEqual(narration, manual.Narration);
        }        
    }
}


================================================
FILE: CoreTests/Integration/ManualJournals/Find.cs
================================================
using System;
using System.Linq;
using NUnit.Framework;

namespace CoreTests.Integration.ManualJournals
{
    [TestFixture]
    public class Find : ManualJournalsTest
    {
        [TestFixtureSetUp]
        public void UpdateSet()
        {
            ManualJournalsSetUp();
        }

        [Test]
        public void find_by_id()
        {
            const string expected = "We know what we want to do";
            var manual = Given_a_manual_journal(expected, 50);

            var found = Api.ManualJournals.Find(manual.Id);

            Assert.AreEqual(DateTime.Now.Date, found.Date);
            Assert.AreEqual(expected, found.Narration);
        }

        [Test]
        public void find_by_value()
        {
            const string expected = "We know what we want to do";
            
            Given_a_manual_journal(expected, 50);

            var found = Api.ManualJournals
                .Where(string.Format("Narration == \"{0}\"", expected))
                .Find();

            Assert.True(found.All(p => p.Narration == expected));
        }

        [Test]
        public void find_by_page()
        {
            const string expected = "We know what we want to do";

            Given_a_manual_journal(expected, 50);

            var manualJournals = Api.ManualJournals.Page(1).Find();

            Assert.Greater(manualJournals.Count(), 0);
        }
    }
}

================================================
FILE: CoreTests/Integration/ManualJournals/ManualJournalsTest.cs
================================================
using System.Collections.Generic;
using System.Linq;
using Xero.Api.Core.Model;
using Xero.Api.Core.Model.Types;

namespace CoreTests.Integration.ManualJournals
{
    public class ManualJournalsTest : ApiWrapperTest
    {
        protected Account Sales { get; private set; }
        protected Account Revenue { get; private set; }
        
        protected void ManualJournalsSetUp()
        {
            SetUp();
            Sales = Given_an_account();
            Revenue = Given_an_account(AccountType.Revenue);
        }

        private Account Given_an_account(AccountType type = AccountType.Sales)
        {
            return Api.Accounts
                .Where(string.Format("Type == \"{0}\"", type.ToString().ToUpper()))
                .Find()
                .FirstOrDefault() ??

                Api.Create(new Account
                {
                    Name = Random.GetRandomString(20),
                    Code = Random.GetRandomString(10),
                    Type = type
                });
        }

        protected ManualJournal Given_a_manual_journal(string narration, decimal amount)
        {
            return Api.Create(new ManualJournal
            {
                Narration = narration,
                Lines = new List<Line>
                {
                    new Line
                    {
                        Amount = amount,
                        AccountCode = Sales.Code
                    },
                    new Line
                    {
                        Amount = -amount,
                        AccountCode = Revenue.Code
                    }
                }
            });
        }
    }
}

================================================
FILE: CoreTests/Integration/ManualJournals/Update.cs
================================================
using System;
using NUnit.Framework;

namespace CoreTests.Integration.ManualJournals
{
    [TestFixture]
    public class Update : ManualJournalsTest
    {
        [TestFixtureSetUp]
        public void UpdateSet()
        {
            ManualJournalsSetUp();
        }

        [Test]
        public void create_manual_journal()
        {
            const string expected = "We got that wrong";

            var manual = Given_a_manual_journal("We know what we want to do", 50);

            manual.Narration = expected;

            var updated = Api.Update(manual);

            Assert.AreEqual(DateTime.Now.Date, updated.Date);
            Assert.AreEqual(expected, updated.Narration);            
        }
    };
}

================================================
FILE: CoreTests/Integration/Organisation/Find.cs
================================================
using System;
using NUnit.Framework;
using Xero.Api.Core.Model.Types;

namespace CoreTests.Integration.Organisation
{
    [TestFixture]
    public class Find : ApiWrapperTest
    {
        [Test]
        public void can_get_the_organisation_sales_tax_basis()
        {
            var test = Api.Organisation.SalesTaxBasisType;

            Assert.True(Enum.IsDefined(typeof(SalesTaxBasisType), test));
        }

        [Test]
        public void can_get_the_organisation_sales_tax_period()
        {
            var test = Api.Organisation.SalesTaxPeriod;

            Assert.True(Enum.IsDefined(typeof(SalesTaxPeriodType), test));
        }
    }
}


================================================
FILE: CoreTests/Integration/Overpayments/Find.cs
================================================
using System.Linq;
using NUnit.Framework;
using Xero.Api.Core.Model.Types;

namespace CoreTests.Integration.Overpayments
{
    [TestFixture]
    public class Find : ApiWrapperTest
    {
        [Test]
        public void find_all()
        {
            var overpayments = Api.Overpayments.Find();
            Assert.Greater(overpayments.Count(), 0);
        }

        [Test]
        public void find_all_receive_overpayments()
        {
            var overpayments = Api.Overpayments.Where("Type == \"RECEIVE-OVERPAYMENT\"").Find();
            Assert.True(overpayments.All(p => p.Type == OverpaymentType.ReceiveOverpayment));
        }

        [Test]
        public void find_all_spend_overpayments()
        {
            var overpayments = Api.Overpayments.Where("Type == \"SPEND-OVERPAYMENT\"").Find();
            Assert.True(overpayments.All(p => p.Type == OverpaymentType.SpendOverpayment));
        }
    }
}


================================================
FILE: CoreTests/Integration/Payments/Create.cs
================================================
using System;
using System.Collections.Generic;
using System.Linq;
using NUnit.Framework;
using Xero.Api.Core.Model;

namespace CoreTests.Integration.Payments
{
    [TestFixture]
    public class Create : PaymentsTest
    {
        [TestFixtureSetUp]
        public void CreatePaymentsSetUp()
        {
            SetUp();
        }

        [Test]
        public void create_simple_payment()
        {
            var date = DateTime.UtcNow;
            const decimal expected = 32.6m;
            const decimal invoiceAmount = 100;

            var payment = Given_a_payment(invoiceAmount, date, expected);

            Assert.AreEqual(expected, payment.Amount);
        }

        [Test]
        public void create_multiple_payments()
        {
            var date = DateTime.UtcNow;

            var payments = Api.Create(
                new List<Payment>
                    {
                        CreatePayment(4000, date, 3375),
                        CreatePayment(393.75m, date, 393.75m),
                        CreatePayment(450, date, 398),
                    }).ToList();

            Assert.AreEqual(3, payments.Count());

            Assert.IsNotNull(payments.Single(p => p.Amount == 393.75m));
            Assert.IsNotNull(payments.Single(p => p.Amount == 3375));
            Assert.IsNotNull(payments.Single(p => p.Amount == 398));
        }

        [Test]
        public void create_reconciled_payment()
        {
            var date = DateTime.UtcNow;
            const decimal amount = 32.6m;
            const decimal invoiceAmount = 32.6m;

            var payment = Api.Create(CreatePayment(invoiceAmount, date, amount, true));

            Assert.AreEqual(amount, payment.Amount);
            Assert.True(payment.IsReconciled.HasValue);
            Assert.True(payment.IsReconciled.Value);
        }

        [Test]
        public void create_refund_on_credit_note()
        {
            const int amount = 50;
            var note = Given_an_credit_note(amount, Account.Code);
            var date = DateTime.UtcNow;
            const string reference = "Full refund as we couldn't replace item";

            var payment = Api.Create(new Payment
            {
                CreditNote = new CreditNote { Number = note.Number },
                Account = new Account { Code = BankAccount.Code },
                Date = date,
                Amount = amount,
                Reference = reference
            });

            Assert.AreEqual(reference, payment.Reference);
            Assert.AreEqual(amount, payment.Amount);
        }

        [Test]
        public void create_refund_on_Prepayment()
        {
            const int amount = 50;
            var transaction = Given_a_prepayment(BankAccount.Code, amount, Account.Code);
            var date = DateTime.UtcNow;
            const string reference = "Full refund on the prepayment";

            //NOTE: When refunding a prepayment, you create the payment with a Prepayment object (payment.Prepayment). The resulting payment will have the Prepayment stored as an Invoice eg. payment.Invoice rather than payment.Prepayment
            var payment = Api.Create(new Payment
            {
                Prepayment = new Prepayment { Id = transaction.PrepaymentID.GetValueOrDefault() },
                Account = new Account { Code = BankAccount.Code },
                Date = date,
                Amount = amount,
                Reference = reference
            });

            Assert.AreEqual(reference, payment.Reference);
            Assert.AreEqual(amount, payment.Amount);
        }

        [Test]
        public void create_refund_on_Overpayment()
        {
            //This may differ if you have changed the code of your accounts receivable
            var accountsReceivable = Api.Accounts.Where("Code == \"610\"").Find().First();

            const int amount = 50;
            var transaction = Given_an_overpayment(BankAccount.Code, amount, accountsReceivable.Code);
            var date = DateTime.UtcNow;
            const string reference = "Full refund on the overpayment";

            //NOTE: When refunding an overpayment, you create the payment with an Overpayment object (payment.Overpayment). The resulting payment will have the Overpayment stored as an Invoice eg. payment.Invoice rather than payment.Overpayment
            var payment = Api.Create(new Payment
            {
                Overpayment = new Overpayment { Id = transaction.OverpaymentID.GetValueOrDefault() },
                Account = new Account { Code = BankAccount.Code },
                Date = date,
                Amount = amount,
                Reference = reference
            });

            Assert.AreEqual(reference, payment.Reference);
            Assert.AreEqual(amount, payment.Amount);
        }
    }
}


================================================
FILE: CoreTests/Integration/Payments/CreateForeignCurrency.cs
================================================
using System;
using System.Linq;
using NUnit.Framework;
using Xero.Api.Core.Model;
using Xero.Api.Core.Model.Types;

namespace CoreTests.Integration.Payments
{
    [TestFixture]
    public class CreateForeignCurrency : PaymentsTest
    {
        private Account Foreign { get; set; }

        [TestFixtureSetUp]
        [Ignore("The user needs to have foreign currency subscription on their account")]
        public void SetUpForeignCurrency()
        {
            SetUp();
        }

        [Test]
        [Ignore("The user needs to have foreign currency subscription on their account")]
        public void create_refund_on_credit_note_with_foreign_currency()
        {
            Foreign = Given_a_foreign_currency_account();

            const int amount = 50;
            var accountCode = Account.Code;
            var note = Given_an_credit_note(amount, accountCode);
            var date = DateTime.UtcNow;
            const string reference = "Full refund as we couldn't replace item";

            var payment = Api.Create(new Payment
            {
                CreditNote = new CreditNote { Number = note.Number },
                Account = new Account { Code = Foreign.Code },
                CurrencyRate = 0.8m,
                Date = date,
                Amount = amount,
                Reference = reference
            });

            Assert.AreEqual(reference, payment.Reference);
            Assert.AreEqual(amount, payment.Amount);
        }

        private Account Given_a_foreign_currency_account()
        {
            return Api.Accounts
                .Where("Type == \"BANK\"")
                .And("CurrencyCode != \"NZD\"")
                .Find().FirstOrDefault() ??
                   Create_foreign_currency_account();
        }

        private Account Create_foreign_currency_account()
        {
            return Api.Create(new Account
            {
                Code = Random.GetRandomString(10),
                Name = "Foreign Currency",
                CurrencyCode = "AUD",
                BankAccountNumber = "121-121-1234567",
                Type = AccountType.Bank
            });
        }

    }
}

================================================
FILE: CoreTests/Integration/Payments/Delete.cs
================================================
using System;
using NUnit.Framework;
using Xero.Api.Core.Model;
using Xero.Api.Core.Model.Status;

namespace CoreTests.Integration.Payments
{
    [TestFixture]
    public class Delete : PaymentsTest
    {
        [TestFixtureSetUp]
        public void CreatePaymentsSetUp()
        {
            SetUp();
        }

        [Test]
        public void can_delete_payments()
        {
            var date = DateTime.UtcNow;
            const decimal expected = 32.6m;
            const decimal invoiceAmount = 100;

            var payment = Given_a_payment(invoiceAmount, date, expected);

            Given_this_payment_is_deleted(payment);

            var found = Api.Payments.Find(payment.Id);

            Assert.True(found.Status == PaymentStatus.Deleted);
        }

    }
}


================================================
FILE: CoreTests/Integration/Payments/Find.cs
================================================
using System;
using System.Linq;
using NUnit.Framework;

namespace CoreTests.Integration.Payments
{
    public class Find : PaymentsTest
    {
        [TestFixtureSetUp]
        public void PaymentsSetUp()
        {
            SetUp();
        }

        [Test]
        public void find_single_payment()
        {
            var expected = Given_a_payment(200, DateTime.Today.AddDays(-10), 150);

            var found = Api.Payments.Find(expected.Id);

            Assert.AreEqual(expected.Id, found.Id);
            Assert.AreEqual(expected.Amount, found.Amount);
        }

        [Test]
        public void find_payments()
        {
            var date = DateTime.Today.AddDays(-10).Date;

            Given_a_payment(200, date, 150);
            Given_a_payment(500, date, 150);
        
            var found = Api.Payments
                .ModifiedSince(DateTime.Now.AddSeconds(-1))
                .Where("Amount == 150")
                .Find()
                .ToList();

            Assert.IsTrue(found.Count() >= 2);
            Assert.IsTrue(found.Count(p => p.Date == date) >= 2);
        }
    }
}


================================================
FILE: CoreTests/Integration/Payments/PaymentsTest.cs
================================================
using System;
using System.Collections.Generic;
using Xero.Api.Core.Model;
using Xero.Api.Core.Model.Status;
using Xero.Api.Core.Model.Types;

namespace CoreTests.Integration.Payments
{
    public abstract class PaymentsTest : ApiWrapperTest
    {
        protected Payment Given_a_payment(decimal invoiceAmount, DateTime date, decimal amount, bool isReconciled = false)
        {
            return Api.Create(CreatePayment(invoiceAmount, date, amount, isReconciled));
        }

        protected Payment CreatePayment(decimal invoiceAmount, DateTime date, decimal amount, bool isReconciled = false)
        {
            var invoice = Given_an_invoice(invoiceAmount, Account.Code);
            var bankCode = BankAccount.Code;

            var payment = new Payment
            {
                Invoice = new Invoice { Number = invoice.Number },
                Account = new Account { Code = bankCode },
                Date = date,
                Amount = amount
            };

            if (isReconciled)
            {
                payment.IsReconciled = true;
            }

            return payment;
        }

        private Invoice Given_an_invoice(decimal amount = 100m, string accountCode = "100")
        {
            return Api.Create(new Invoice
            {
                Contact = new Contact { Name = "Richard" },
                Number = Random.GetRandomString(10),
                Type = InvoiceType.AccountsPayable,
                Date = DateTime.UtcNow,
                DueDate = DateTime.UtcNow.AddDays(90),
                LineAmountTypes = LineAmountType.Inclusive,
                Status = InvoiceStatus.Authorised,
				LineItems = new List<LineItem>
                {
                    new LineItem
                    {
                        AccountCode = accountCode,
                        Description = "Good value item",
                        LineAmount = amount
                    }
                }
            });
        }

        protected CreditNote Given_an_credit_note(decimal amount = 100m, string accountCode = "100")
        {
            return Api.Create(new CreditNote
            {
                Contact = new Contact { Name = "Richard" },
                Number = Random.GetRandomString(10),
                Type = CreditNoteType.AccountsPayable,
                Date = DateTime.UtcNow,
                DueDate = DateTime.UtcNow.AddDays(90),
                LineAmountTypes = LineAmountType.Inclusive,
                Status = InvoiceStatus.Authorised,
                LineItems = new List<LineItem>
                {
                    new LineItem
                    {
                        AccountCode = accountCode,
                        Description = "Good value item",
                        LineAmount = amount
                    }
                }
            });
        }

        protected BankTransaction Given_a_prepayment(string bankAccountCode, decimal amount = 100m, string accountCode = "100")
        {
            return Api.Create(new BankTransaction
            {
                Contact = new Contact { Name = "Richard" },
                Type = BankTransactionType.ReceivePrepayment,
                Date = DateTime.UtcNow,
                BankAccount = new Account
                {
                    Code = bankAccountCode
                },
                LineItems = new List<LineItem>
                {
                    new LineItem
                    {
                        AccountCode = accountCode,
                        Description = "Good value item",
                        LineAmount = amount
                    }
                }
            });
        }

        protected BankTransaction Given_an_overpayment(string bankAccountCode, decimal amount = 100m, string accountCode = "100")
        {
            return Api.Create(new BankTransaction
            {
                Contact = new Contact { Name = "Richard" },
                Type = BankTransactionType.ReceiveOverpayment,
                Date = DateTime.UtcNow,
                LineAmountTypes = LineAmountType.NoTax,
                BankAccount = new Account
                {
                    Code = bankAccountCode
                },
                LineItems = new List<LineItem>
                {
                    new LineItem
                    {
                        AccountCode = accountCode,
                        Description = "Good value item",
                        LineAmount = amount
                    }
                }
            });
        }

        protected void Given_this_payment_is_deleted(Payment payment)
        {
            var deleteThisPayment = new Payment { Status = PaymentStatus.Deleted, Id = payment.Id };

            Api.Payments.Update(deleteThisPayment);
        }
    }
}

================================================
FILE: CoreTests/Integration/Pdf/Get.cs
================================================
using System;
using NUnit.Framework;
using Xero.Api.Core.Model.Types;
using Xero.Api.Infrastructure.Exceptions;

namespace CoreTests.Integration.Pdf
{
    [TestFixture]
    public class Get : ApiWrapperTest
    {
        [Test]
        public void can_get_invoice_as_pdf()
        {
            AssertOk(PdfEndpointType.Invoices, new Invoices.Create().Given_an_invoice().Id);
        }

        [Test]
        public void can_get_credit_note_as_pdf()
        {
            AssertOk(PdfEndpointType.CreditNotes, new CreditNotes.Create().Given_a_creditnote().Id);
        }

        [Test]
        public void can_get_purchase_order_as_pdf()
        {
            AssertOk(PdfEndpointType.PurchaseOrders, new PurchaseOrders.Create().Given_a_purchase_order().Id);
        }

        [Test]
        public void invoice_gives_404_when_not_found()
        {
            Assert.Throws<NotFoundException>(() => Api.PdfFiles.Get(PdfEndpointType.Invoices, Guid.NewGuid()));
        }

        [Test]
        public void credit_note_gives_404_when_not_found()
        {
            Assert.Throws<NotFoundException>(() => Api.PdfFiles.Get(PdfEndpointType.CreditNotes, Guid.NewGuid()));
        }

        [Test]
        public void purchase_order_gives_404_when_not_found()
        {
            Assert.Throws<NotFoundException>(() => Api.PdfFiles.Get(PdfEndpointType.PurchaseOrders, Guid.NewGuid()));
        }

        private void AssertOk(PdfEndpointType type, Guid id)
        {
            var pdf = Api.PdfFiles.Get(type, id);
            var expected = id.ToString("D") + ".pdf";

            Assert.NotNull(pdf);
            Assert.AreEqual(expected, pdf.FileName);
        }
    }    
}


================================================
FILE: CoreTests/Integration/Prepayments/Find.cs
================================================
using System.Linq;
using NUnit.Framework;
using Xero.Api.Core.Model.Types;

namespace CoreTests.Integration.Prepayments
{
    [TestFixture]
    public class Find : ApiWrapperTest
    {
        [Test]
        public void find_all()
        {
            var prepayments = Api.Prepayments.Find();
            Assert.Greater(prepayments.Count(), 0);
        }

        [Test]
        public void find_all_receive_prepayments()
        {
            var prepayments = Api.Prepayments.Where("Type == \"RECEIVE-PREPAYMENT\"").Find();
            Assert.True(prepayments.All(p => p.Type == PrepaymentType.ReceivePrepayment));
        }

        [Test]
        public void find_all_spend_prepayments()
        {
            var prepayments = Api.Prepayments.Where("Type == \"SPEND-PREPAYMENT\"").Find();
            Assert.True(prepayments.All(p => p.Type == PrepaymentType.SpendPrepayment));
        }
    }
}


================================================
FILE: CoreTests/Integration/PurchaseOrders/Create.cs
================================================
using System;
using System.Collections.Generic;
using System.Linq;
using NUnit.Framework;
using Xero.Api.Core.Model;
using Xero.Api.Core.Model.Status;

namespace CoreTests.Integration.PurchaseOrders
{
    public class Create : ApiWrapperTest
    {
        [Test]
        public void Create_minimal_draft_purchase_order()
        {

            var purchaseOrder = Api.PurchaseOrders.Create(
                new PurchaseOrder
                {
                    Date = DateTime.Today,
                    Contact = new Contact { Id = ContactId }
                }
            );

            Assert.True(purchaseOrder.Id != Guid.Empty);
            Assert.True(purchaseOrder.Status == PurchaseOrderStatus.Draft);
        }

        [Test]
        public void Create_authorised_purchase_order()
        {
            var purchaseOrder = Api.PurchaseOrders.Create(
                new PurchaseOrder
                {
                    Status = PurchaseOrderStatus.Authorised,
                    Date = DateTime.Today,
                    Contact = new Contact{Id = ContactId},
                    LineItems = new List<LineItem>()
                    {
                        new LineItem
                        {
                            Description = "An item I want to purchase",
                            UnitAmount = 1,
                            Quantity = 1,

                        }
                    }
                }
            );

            Assert.True(purchaseOrder.Id != Guid.Empty);
            Assert.True(purchaseOrder.Status == PurchaseOrderStatus.Authorised);
        }

        private Guid ContactId
        {
            get
            {
                return Api.Contacts.Find().First().Id;
            }
        }

        public PurchaseOrder Given_a_purchase_order()
        {
            return Api.PurchaseOrders.Create(
                new PurchaseOrder
                {
                    Status = PurchaseOrderStatus.Authorised,
                    Date = DateTime.Today,
                    Contact = new Contact { Id = ContactId },
                    LineItems = new List<LineItem>()
                    {
                        new LineItem
                        {
                            Description = "An item I want to purchase",
                            UnitAmount = 1,
                            Quantity = 1,

                        }
                    }
                }
            );
        }
    }
}


================================================
FILE: CoreTests/Integration/PurchaseOrders/Find.cs
================================================
using System;
using System.Collections.Generic;
using System.Linq;
using System.Threading;
using NUnit.Framework;
using Xero.Api.Core.Model;
using Xero.Api.Core.Model.Status;

namespace CoreTests.Integration.PurchaseOrders
{
    public class Find : ApiWrapperTest
    {

        [Test]
        public void Find_a_purchase_order_by_Id()
        {
            var purchaseOrder = Given_a_minimum_PurchaseOrder();

            var foundPurchaseOrder = Api.PurchaseOrders.Find(purchaseOrder.Id);

            Assert.AreEqual(purchaseOrder.Id, foundPurchaseOrder.Id);
        }

        [Test]
        public void Find_purchase_orders()
        {
            Given_a_minimum_PurchaseOrder();

            var foundPurchaseOrders = Api.PurchaseOrders.Find();

            Assert.GreaterOrEqual(foundPurchaseOrders.Count(), 1);
        }

        [Test]
        public void Find_page_X_of_purchase_orders()
        {
            Given_a_minimum_PurchaseOrder();

            var foundPurchaseOrders = Api.PurchaseOrders.Page(1).Find();

            Assert.GreaterOrEqual(foundPurchaseOrders.Count(), 1);
        }

        [Test]
        public void Filter_purchase_orders_by_status()
        {
            Given_an_authorised_PurchaseOrder();

            var authorisedPurchaseOrders = Api.PurchaseOrders.Status(PurchaseOrderStatus.Authorised).Find();

            Assert.IsTrue(authorisedPurchaseOrders.All(p => p.Status == PurchaseOrderStatus.Authorised), "Expected all retrieved purchase orders to have status of Authorised");
        }

        [Test]
        public void Filter_purchase_orders_by_ModifiedSince()
        {
            var oldPurchaseOrder = Given_a_minimum_PurchaseOrder();

            Thread.Sleep(1000);

            var date = DateTime.UtcNow;

            Thread.Sleep(1000);

            var newPurchaseOrder = Given_a_minimum_PurchaseOrder();

            var retrievedPurchaseOrders = Api.PurchaseOrders.ModifiedSince(date).Find().ToList();

            Assert.True(retrievedPurchaseOrders.All(p => p.Id != oldPurchaseOrder.Id));
            Assert.True(retrievedPurchaseOrders.Any(p => p.Id == newPurchaseOrder.Id));
        }

        [Test]
        public void Filter_purchase_orders_by_DateFrom()
        {
            var oldPurchaseOrder = Given_a_minimum_PurchaseOrder(DateTime.Today.AddDays(-7));

            var newPurchaseOrder = Given_a_minimum_PurchaseOrder(DateTime.Today);

            var inbetweenDate = DateTime.Today.AddDays(-3);
            
            var retrievedPurchaseOrders = Api.PurchaseOrders.DateFrom(inbetweenDate).Find().ToList();

            Assert.True(retrievedPurchaseOrders.All(p => p.Id != oldPurchaseOrder.Id));
            Assert.True(retrievedPurchaseOrders.Any(p => p.Id == newPurchaseOrder.Id));
        }

        [Test]
        public void Filter_purchase_orders_by_DateTo()
        {
            var oldPurchaseOrder = Given_a_minimum_PurchaseOrder(DateTime.Today.AddDays(-7));

            var newPurchaseOrder = Given_a_minimum_PurchaseOrder(DateTime.Today);

            var inbetweenDate = DateTime.Today.AddDays(-3);

            var retrievedPurchaseOrders = Api.PurchaseOrders.DateTo(inbetweenDate).Find().ToList();

            Assert.True(retrievedPurchaseOrders.All(p => p.Id != newPurchaseOrder.Id));
            Assert.True(retrievedPurchaseOrders.Any(p => p.Id == oldPurchaseOrder.Id));
        }

        [Test]
        public void Filter_purchase_orders_by_a_DateFrom_DateTo_date_range()
        {
            var oldPurchaseOrder = Given_a_minimum_PurchaseOrder(DateTime.Today.AddDays(-7));

            var midPurchaseOrder = Given_a_minimum_PurchaseOrder(DateTime.Today.AddDays(-4));

            var newPurchaseOrder = Given_a_minimum_PurchaseOrder(DateTime.Today);

            var dateFrom = DateTime.Today.AddDays(-5);
            var dateTo = DateTime.Today.AddDays(-3);

            var retrievedPurchaseOrders = Api.PurchaseOrders
                .DateFrom(dateFrom)
                .DateTo(dateTo)
                .Find().ToList();

            Assert.True(retrievedPurchaseOrders.All(p => p.Id != newPurchaseOrder.Id));
            Assert.True(retrievedPurchaseOrders.All(p => p.Id != oldPurchaseOrder.Id));

            Assert.True(retrievedPurchaseOrders.Any(p => p.Id == midPurchaseOrder.Id));

        }

        [Test]
        public void Use_multiple_filters_to_find_Purchase_orders()
        {
            var purchaseOrders = Api.PurchaseOrders
                .DateFrom(DateTime.Today.AddDays(-7))
                .DateTo(DateTime.Today.AddDays(-1))
                .Status(PurchaseOrderStatus.Authorised)
                .Page(1)
                .Find();

            Assert.GreaterOrEqual(purchaseOrders.Count(), 1);
        }

        private PurchaseOrder Given_a_minimum_PurchaseOrder(DateTime? date = null)
        {
            var purchaseOrder = Api.PurchaseOrders.Create(new PurchaseOrder
            {
                Date = date ?? DateTime.Today,
                Contact = Api.Contacts.Find().First()
            });
            return purchaseOrder;
        }

        private PurchaseOrder Given_an_authorised_PurchaseOrder()
        {
            var purchaseOrder = Api.PurchaseOrders.Create(new PurchaseOrder
            {
                Status = PurchaseOrderStatus.Authorised,
                Date = DateTime.Today,
                Contact = Api.Contacts.Find().First(),
                LineItems = new List<LineItem>()
                {
                    new LineItem
                    {
                        Description = "An item I want to purchase",
                        UnitAmount = 1,
                        Quantity = 1,

                    }
                }
            });
            return purchaseOrder;
        }



    }
}


================================================
FILE: CoreTests/Integration/PurchaseOrders/Update.cs
================================================
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using NUnit.Framework;
using Xero.Api.Core.Model;
using Xero.Api.Core.Model.Status;

namespace CoreTests.Integration.PurchaseOrders
{
    public class Update : ApiWrapperTest
    {
        [Test]
        public void Can_update_a_PurchaseOrder_like_this()
        {
            var purchaseOrder = Given_a_PurchaseOrder();

            purchaseOrder.LineItems.Add(new LineItem
            {
                Description = "Another item I want to purchase",
                UnitAmount = 10,
                Quantity = 10
            });

            var updatedPurchaseOrder = Api.PurchaseOrders.Update(purchaseOrder);

            Assert.AreEqual(2, updatedPurchaseOrder.LineItems.Count);
        }


        public PurchaseOrder Given_a_PurchaseOrder()
        {
            return Api.PurchaseOrders.Create(
                new PurchaseOrder
                {
                    Status = PurchaseOrderStatus.Authorised,
                    Date = DateTime.Today,
                    Contact = new Contact { Id = ContactId },
                    LineItems = new List<LineItem>()
                    {
                        new LineItem
                        {
                            Description = "An item I want to purchase",
                            UnitAmount = 1,
                            Quantity = 1,

                        }
                    }
                }
            );
        }

        private Guid ContactId
        {
            get
            {
                return Api.Contacts.Find().First().Id;
            }
        }
    }
}


================================================
FILE: CoreTests/Integration/Receipts/Create.cs
================================================
using System.Linq;
using NUnit.Framework;

namespace CoreTests.Integration.Receipts
{
    [TestFixture]
    public class Create : ReceiptTest
    {
        [Test]
        public void create_receipt()
        {
            var contact = Random.GetRandomString(10);
            var description = Random.GetRandomString(30);
            const decimal value = 13.8m;

            var receipt = Given_a_receipt(Api.Users.Find().First().Id, contact, description, value, "420");

            Assert.AreEqual(receipt.Total, value);
            Assert.AreEqual(receipt.Contact.Name, contact);
            Assert.AreEqual(receipt.LineItems[0].Description, description);
        }
    }
}



================================================
FILE: CoreTests/Integration/Receipts/ReceiptTest.cs
================================================
using System;
using System.Collections.Generic;
using Xero.Api.Core.Model;
using Xero.Api.Core.Model.Types;

namespace CoreTests.Integration.Receipts
{
    public abstract class ReceiptTest : ApiWrapperTest
    {
        public Receipt Given_a_receipt(Guid userId, string contactName, string description, decimal amount, string account)
        {
            return Api.Create(new Receipt
            {
                Date = DateTime.UtcNow.Date,
                Contact = new Contact { Name = contactName },
                LineAmountTypes = LineAmountType.Inclusive,
                LineItems = new List<LineItem>
                {
                    new LineItem
                    {
                        Description = description,
                        UnitAmount = amount,
                        AccountCode = account
                    }
                },
                Total = amount,
                User = new User
                {
                    Id = userId
                }
            });
        }
    }
}


================================================
FILE: CoreTests/Integration/Receipts/Update.cs
================================================
using System.Linq;
using NUnit.Framework;
using Xero.Api.Core.Model.Status;

namespace CoreTests.Integration.Receipts
{
    [TestFixture]
    public class Update : ReceiptTest
    {
        [Test]
        public void delete_receipt()
        {
            var contact = Random.GetRandomString(10);
            var description = Random.GetRandomString(30);
            const ReceiptStatus expected = ReceiptStatus.Deleted;
            const decimal value = 13.8m;

            var receipt = Given_a_receipt(Api.Users.Find().First().Id, contact, description, value, "420");
            receipt.Status = expected;
            var deletedReceipt = Api.Update(receipt);

            Assert.AreEqual(expected, deletedReceipt.Status);
        }
    }
}

================================================
FILE: CoreTests/Integration/Reports/Find.cs
================================================
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using NUnit.Framework;

namespace CoreTests.Integration.Reports
{
    [TestFixture]
    public class Find : ApiWrapperTest
    {

        [Test]
        public void find_all()
        {
            var reports = Api.Reports.Find();
            Assert.IsNotNull(reports);
        }

        [Test]
        public void find_gst_report()
        {
            var reports = Api.Reports.Find("BalanceSheet");
            Assert.IsNotNull(reports);
        }

        [Test]
        public void find_PL_report()
        {
            var reports = Api.Reports.ProfitAndLoss();
            Assert.IsNotNull(reports);
        }

        [Test]
        public void find_BudgetSummary_report()
        {
            var reports = Api.Reports.BudgetSummary(DateTime.Now.AddDays(-50));
            Assert.IsNotNull(reports);
        }
    }
}


================================================
FILE: CoreTests/Integration/Setup/Create.cs
================================================
using System.Collections.Generic;
using NUnit.Framework;
using Xero.Api.Core.Model;
using Xero.Api.Core.Model.Types;
using Xero.Api.Infrastructure.Exceptions;

namespace CoreTests.Integration.Setup
{
    [TestFixture(Ignore = true, Description = "These test will remove all accounts! You have been warned.")]
    public class Create : ApiWrapperTest
    {
        [Test]
        public void create_a_valid_setup()
        {
            var import = Api.Setup.Create(new Xero.Api.Core.Model.Setup.Setup
            {
                Accounts = new List<Account>(new[] {
                    new Account
                    {
                        Code = "POS " + Random.GetRandomString(10),
                        Name = "POS Clearing" + Random.GetRandomString(10),
                        Type = AccountType.Current,
                        Description = "A test for the setup"
                    }
                })
            });

            Assert.True(import.Accounts.New == 1);
        }

        [Test]
        public void missing_account_code_will_error()
        {
            Assert.Throws<ValidationException>(() => Api.Setup.Create(new Xero.Api.Core.Model.Setup.Setup
            {
                Accounts = new List<Account>(new[]
                {
                    new Account
                    {
                        Name = "No account code",
                        Type = AccountType.Current,
                    }
                })
            }));            
        }

        [Test]
        public void providing_nothing_is_not_an_error()
        {
            var import = Api.Setup.Create(new Xero.Api.Core.Model.Setup.Setup());

            Assert.False(import.Accounts.Present);
            Assert.False(import.Organisation.Present);
        }        
    }
}


================================================
FILE: CoreTests/Integration/TaxRates/Create.cs
================================================
using System.Linq;
using NUnit.Framework;
using Xero.Api.Core.Model;
using Xero.Api.Core.Model.Types;

namespace CoreTests.Integration.TaxRates
{
    [TestFixture]
    public class Create : TaxRateTest
    {
        [Test]
        public void create_tax_rate()
        {
            var name = Random.GetRandomString(10);
            var state = Random.GetRandomString(5);
            var local = Random.GetRandomString(5);

            const decimal stateRate = 7.5m;
            const decimal localRate = 0.625m;
            const ReportTaxType taxType = ReportTaxType.Input;

            var taxRate = Given_a_tax_rate(name, taxType, state, stateRate, local, localRate);

            Assert.That(name == taxRate.Name);
            Assert.That(taxType == taxRate.ReportTaxType);

            AssertContainsRate(taxRate, state, stateRate);
            AssertContainsRate(taxRate, local, localRate);
        }

        private void AssertContainsRate(TaxRate taxRate, string name, decimal rate)
        {
            var taxComponent = taxRate.TaxComponents.SingleOrDefault(p => name == p.Name);

            Assert.IsNotNull(taxComponent);
            Assert.AreEqual(taxComponent.Rate, rate);
        }
    }
}


================================================
FILE: CoreTests/Integration/TaxRates/TaxRateTest.cs
================================================
using System.Collections.Generic;
using System.Linq;
using Xero.Api.Core.Model;
using Xero.Api.Core.Model.Types;

namespace CoreTests.Integration.TaxRates
{
    public abstract class TaxRateTest : ApiWrapperTest
    {
        protected TaxRate Given_a_tax_rate(string name, ReportTaxType taxType, string state, decimal stateRate, string local, decimal localRate)
        {
            return Api.Create(new[]{ new TaxRate
            {
                Name = name,
                ReportTaxType = taxType,
                TaxComponents = new List<TaxComponent>
                {
                    new TaxComponent
                    {
                        Name = state,
                        Rate = stateRate
                    },
                    new TaxComponent
                    {
                        Name = local,
                        Rate = localRate
                    }
                }
            }}).First();
        }
    }
}


================================================
FILE: CoreTests/Integration/TaxRates/Update.cs
================================================
using System.Linq;
using NUnit.Framework;
using Xero.Api.Core.Model.Status;
using Xero.Api.Core.Model.Types;

namespace CoreTests.Integration.TaxRates
{
    [TestFixture]
    public class Update : TaxRateTest
    {
        [Test]
        public void update_tax_rate()
        {
            var name = Random.GetRandomString(10);
            var state = Random.GetRandomString(5);
            var local = Random.GetRandomString(5);

            const decimal stateRate = 7.5m;
            const decimal localRate = 0.625m;
            const ReportTaxType taxType = ReportTaxType.Input;

            var taxRate = Given_a_tax_rate(name, taxType, state, stateRate, local, localRate);

            // the local tax rate is increased                
            const decimal expected = 0.7m;

            var component = taxRate.TaxComponents.Single(p => p.Name == local);
            component.Rate = expected;
            var updated = Api.Update(taxRate);

            Assert.AreEqual(expected, updated.TaxComponents.Single(p => p.Name == local).Rate);
        }

        [Test]
        public void delete_tax_rate()
        {
            var name = Random.GetRandomString(10);
            var state = Random.GetRandomString(5);
            var local = Random.GetRandomString(5);

            const decimal stateRate = 7.5m;
            const decimal localRate = 0.625m;
            const TaxRateStatus 
Download .txt
gitextract_xmz3hwlp/

├── .gitignore
├── CoreTests/
│   ├── ApiWrapperTest.cs
│   ├── App.config
│   ├── CoreTests.csproj
│   ├── Integration/
│   │   ├── Accounts/
│   │   │   ├── Create.cs
│   │   │   ├── Find.cs
│   │   │   └── Update.cs
│   │   ├── Allocations/
│   │   │   └── Add.cs
│   │   ├── Attachments/
│   │   │   └── Attachments.cs
│   │   ├── BankTransactionTest.cs
│   │   ├── BankTransactions/
│   │   │   ├── BankTransactionTest.cs
│   │   │   ├── Create.cs
│   │   │   ├── Find.cs
│   │   │   └── Update.cs
│   │   ├── BankTransfers/
│   │   │   ├── BankTransfersTest.cs
│   │   │   ├── Create.cs
│   │   │   └── Find.cs
│   │   ├── BatchPayment/
│   │   │   ├── BatchPaymentsTest.cs
│   │   │   └── Create.cs
│   │   ├── ContactGroups/
│   │   │   ├── Add_Contact.cs
│   │   │   ├── ContactGroupsTest.cs
│   │   │   ├── Create.cs
│   │   │   ├── Delete.cs
│   │   │   ├── Find.cs
│   │   │   ├── Remove_Contact.cs
│   │   │   └── Update.cs
│   │   ├── Contacts/
│   │   │   ├── ContactsTest.cs
│   │   │   ├── Create.cs
│   │   │   ├── Find.cs
│   │   │   └── Update.cs
│   │   ├── CreditNotes/
│   │   │   ├── Create.cs
│   │   │   ├── CreditNotesTest.cs
│   │   │   ├── Find.cs
│   │   │   └── Update.cs
│   │   ├── ExpenseClaims/
│   │   │   ├── Create.cs
│   │   │   ├── ExpenseClaimTest.cs
│   │   │   └── Update.cs
│   │   ├── Files/
│   │   │   ├── Associations/
│   │   │   │   └── AssociationTest.cs
│   │   │   ├── Files/
│   │   │   │   └── AddFileTest.cs
│   │   │   ├── Folders/
│   │   │   │   └── AddFolderTest.cs
│   │   │   ├── Inbox/
│   │   │   │   └── InboxTest.cs
│   │   │   └── Support/
│   │   │       ├── DataItem.cs
│   │   │       ├── DiskFile.cs
│   │   │       ├── File.cs
│   │   │       └── FilesTest.cs
│   │   ├── General/
│   │   │   ├── Errors.cs
│   │   │   ├── FindingAllItems.cs
│   │   │   └── QueryStrings.cs
│   │   ├── HistoryAndNotes/
│   │   │   ├── CreateNotes.cs
│   │   │   ├── Find.cs
│   │   │   └── HistoryAndNotesTest.cs
│   │   ├── Invoices/
│   │   │   ├── Create.cs
│   │   │   ├── Find.cs
│   │   │   ├── InvoicesTest.cs
│   │   │   ├── OnlineInvoiceUrl.cs
│   │   │   └── SummarizeErrors.cs
│   │   ├── Items/
│   │   │   ├── Create.cs
│   │   │   ├── Delete.cs
│   │   │   ├── TrackedItems/
│   │   │   │   ├── Create.cs
│   │   │   │   ├── Find.cs
│   │   │   │   ├── TrackedInventoryTest.cs
│   │   │   │   ├── Update.cs
│   │   │   │   └── Using_tracked_items.cs
│   │   │   └── Update.cs
│   │   ├── Journals/
│   │   │   └── Find.cs
│   │   ├── LinkedTransactions/
│   │   │   ├── Create.cs
│   │   │   ├── Delete.cs
│   │   │   ├── Find.cs
│   │   │   ├── LinkedTransactionTest.cs
│   │   │   └── Update.cs
│   │   ├── ManualJournals/
│   │   │   ├── Create.cs
│   │   │   ├── Find.cs
│   │   │   ├── ManualJournalsTest.cs
│   │   │   └── Update.cs
│   │   ├── Organisation/
│   │   │   └── Find.cs
│   │   ├── Overpayments/
│   │   │   └── Find.cs
│   │   ├── Payments/
│   │   │   ├── Create.cs
│   │   │   ├── CreateForeignCurrency.cs
│   │   │   ├── Delete.cs
│   │   │   ├── Find.cs
│   │   │   └── PaymentsTest.cs
│   │   ├── Pdf/
│   │   │   └── Get.cs
│   │   ├── Prepayments/
│   │   │   └── Find.cs
│   │   ├── PurchaseOrders/
│   │   │   ├── Create.cs
│   │   │   ├── Find.cs
│   │   │   └── Update.cs
│   │   ├── Receipts/
│   │   │   ├── Create.cs
│   │   │   ├── ReceiptTest.cs
│   │   │   └── Update.cs
│   │   ├── Reports/
│   │   │   └── Find.cs
│   │   ├── Setup/
│   │   │   └── Create.cs
│   │   ├── TaxRates/
│   │   │   ├── Create.cs
│   │   │   ├── TaxRateTest.cs
│   │   │   └── Update.cs
│   │   └── TrackingCategories/
│   │       ├── AddTrackingOption.cs
│   │       ├── Adding/
│   │       │   └── CreateTrackingCategories.cs
│   │       ├── ArchiveTrackingCategory.cs
│   │       ├── CreateTrackingCategories.cs
│   │       ├── Delete.cs
│   │       ├── GetTrackingCategories.cs
│   │       ├── GetTrackingCategoriesIncludingArchieved.cs
│   │       ├── Options/
│   │       │   └── AddTrackingOption.cs
│   │       ├── TrackingCategoriesTest.cs
│   │       ├── UpdateTrackingCategory.cs
│   │       └── UpdateTrackingOptions.cs
│   ├── README.md
│   ├── Random.cs
│   ├── Resources/
│   │   └── cert/
│   │       └── public_privatekey.txt
│   ├── Unit/
│   │   ├── Contacts.cs
│   │   ├── ExceptionTests.cs
│   │   ├── FourDecimalPlaces.cs
│   │   ├── QueryStrings.cs
│   │   ├── RateLimiterTest.cs
│   │   ├── SalesTaxBasisTypeTest.cs
│   │   ├── SalesTaxPeriodTypeTest.cs
│   │   ├── SummarizeErrors.cs
│   │   ├── TrackingCategories.cs
│   │   └── UrlEncoder.cs
│   └── packages.config
├── PayrollTests.AU/
│   ├── ApiWrapperTest.cs
│   ├── App.config
│   ├── Integration/
│   │   ├── Employees/
│   │   │   ├── Create.cs
│   │   │   ├── EmployeesTest.cs
│   │   │   ├── Find.cs
│   │   │   └── Update.cs
│   │   ├── LeaveApplications/
│   │   │   ├── Create.cs
│   │   │   ├── Find.cs
│   │   │   └── LeaveApplicationTest.cs
│   │   ├── PayItems/
│   │   │   ├── Create.cs
│   │   │   ├── Find.cs
│   │   │   └── PayItemsTest.cs
│   │   ├── PayrollCalendars/
│   │   │   ├── Create.cs
│   │   │   └── Find.cs
│   │   ├── Payrun/
│   │   │   ├── Create.cs
│   │   │   ├── Find.cs
│   │   │   └── PayrunTest.cs
│   │   ├── Settings/
│   │   │   └── Find.cs
│   │   ├── SuperFundProducts/
│   │   │   └── Find.cs
│   │   ├── SuperFunds/
│   │   │   ├── Create.cs
│   │   │   └── Update.cs
│   │   ├── TimeSheets/
│   │   │   ├── Create.cs
│   │   │   ├── Find.cs
│   │   │   └── TimesheetTest.cs
│   │   └── ValidationErrors/
│   │       └── AUPayrollValidationErrors.cs
│   ├── PayrollTests.AU.csproj
│   ├── Properties/
│   │   └── AssemblyInfo.cs
│   ├── README.md
│   ├── Resources/
│   │   └── cert/
│   │       └── public_privatekey.txt
│   └── packages.config
├── PayrollTests.US/
│   ├── ApiWrapperTest.cs
│   ├── App.config
│   ├── Integration/
│   │   ├── Employees/
│   │   │   ├── Create.cs
│   │   │   ├── EmployeesTest.cs
│   │   │   ├── Find.cs
│   │   │   └── Update.cs
│   │   └── PaySchedules/
│   │       ├── Create.cs
│   │       ├── Find.cs
│   │       └── PaySchedulesTest.cs
│   ├── PayrollTests.US.csproj
│   ├── Properties/
│   │   └── AssemblyInfo.cs
│   ├── README.md
│   ├── Resources/
│   │   └── cert/
│   │       └── public_privatekey.txt
│   └── packages.config
├── README.md
├── UpgradeLog.htm
├── Xero.Api/
│   ├── Common/
│   │   ├── CoreData.cs
│   │   ├── Extensions.cs
│   │   ├── HasUpdatedDate.cs
│   │   ├── IHasAttachment.cs
│   │   ├── IHasId.cs
│   │   ├── IPageableEndpoint.cs
│   │   ├── IXeroReadEndpoint.cs
│   │   ├── MimeTypes.cs
│   │   ├── QueryGenerator.cs
│   │   ├── XeroApi.cs
│   │   ├── XeroReadEndpoint.cs
│   │   ├── XeroRequest.cs
│   │   └── XeroResponse.cs
│   ├── Core/
│   │   ├── Endpoints/
│   │   │   ├── AccountsEndpoint.cs
│   │   │   ├── AllocationEndpoint.cs
│   │   │   ├── AssociationsEndpoint.cs
│   │   │   ├── AttachmentsEndpoint.cs
│   │   │   ├── BankTransactionsEndpoint.cs
│   │   │   ├── BankTransfersEndpoint.cs
│   │   │   ├── Base/
│   │   │   │   ├── FourDecimalPlacesEndpoint.cs
│   │   │   │   ├── IXeroCreateEndpoint.cs
│   │   │   │   ├── IXeroUpdateEndpoint.cs
│   │   │   │   ├── XeroCreateEndpoint.cs
│   │   │   │   └── XeroUpdateEndpoint.cs
│   │   │   ├── BatchPaymentsEndpoint.cs
│   │   │   ├── BrandingThemesEndpoint.cs
│   │   │   ├── ContactGroupEndpoint.cs
│   │   │   ├── ContactsEndpoint.cs
│   │   │   ├── CreditNotesEndpoint.cs
│   │   │   ├── CurrenciesEndpoint.cs
│   │   │   ├── EmployeesEndpoint.cs
│   │   │   ├── ExpenseClaimsEndpoint.cs
│   │   │   ├── FilesEndpoint.cs
│   │   │   ├── FoldersEndpoint.cs
│   │   │   ├── HistoryAndNotesEndpoint.cs
│   │   │   ├── InboxEndpoint.cs
│   │   │   ├── InvoicesEndpoint.cs
│   │   │   ├── ItemsEndpoint.cs
│   │   │   ├── JournalsEndpoint.cs
│   │   │   ├── LinkedTransactionsEndpoint.cs
│   │   │   ├── ManualJournalsEndpoint.cs
│   │   │   ├── OrganisationEndpoint.cs
│   │   │   ├── OverpaymentsEndpoint.cs
│   │   │   ├── PaymentsEndpoint.cs
│   │   │   ├── PdfEndpoint.cs
│   │   │   ├── PrepaymentsEndpoint.cs
│   │   │   ├── PurchaseOrdersEndpoint.cs
│   │   │   ├── ReceiptsEndpoint.cs
│   │   │   ├── RepeatingInvoicesEndpoint.cs
│   │   │   ├── ReportsEndpoint.cs
│   │   │   ├── SetupEndpoint.cs
│   │   │   ├── TaxRatesEndpoint.cs
│   │   │   ├── TrackingCategoriesEndpoint.cs
│   │   │   └── UsersEndpoint.cs
│   │   ├── File/
│   │   │   └── BinaryFile.cs
│   │   ├── IXeroCoreApi.cs
│   │   ├── Model/
│   │   │   ├── Account.cs
│   │   │   ├── Address.cs
│   │   │   ├── Allocation.cs
│   │   │   ├── AllocationBase.cs
│   │   │   ├── Association.cs
│   │   │   ├── Attachment.cs
│   │   │   ├── Balance.cs
│   │   │   ├── Balances.cs
│   │   │   ├── BankTransaction.cs
│   │   │   ├── BankTransfer.cs
│   │   │   ├── BatchPayment.cs
│   │   │   ├── BatchPaymentContactDefaults.cs
│   │   │   ├── BatchPaymentPayment.cs
│   │   │   ├── BrandingTheme.cs
│   │   │   ├── Contact.cs
│   │   │   ├── ContactCisSetting.cs
│   │   │   ├── ContactGroup.cs
│   │   │   ├── ContactPerson.cs
│   │   │   ├── ContactTrackingCategory.cs
│   │   │   ├── CreditNote.cs
│   │   │   ├── CreditNoteAllocation.cs
│   │   │   ├── Currency.cs
│   │   │   ├── Employee.cs
│   │   │   ├── EnumExtensions.cs
│   │   │   ├── ExpenseClaim.cs
│   │   │   ├── ExternalLink.cs
│   │   │   ├── File.cs
│   │   │   ├── FilePage.cs
│   │   │   ├── FilesUser.cs
│   │   │   ├── Folder.cs
│   │   │   ├── HistoryRecord.cs
│   │   │   ├── Invoice.cs
│   │   │   ├── Item.cs
│   │   │   ├── ItemDetails.cs
│   │   │   ├── ItemTracking.cs
│   │   │   ├── ItemTrackingCategory.cs
│   │   │   ├── Journal.cs
│   │   │   ├── Line.cs
│   │   │   ├── LineItem.cs
│   │   │   ├── LinkedTransaction.cs
│   │   │   ├── ManualJournal.cs
│   │   │   ├── OnlineInvoice.cs
│   │   │   ├── Option.cs
│   │   │   ├── Organisation.cs
│   │   │   ├── OrganisationCisSetting.cs
│   │   │   ├── Overpayment.cs
│   │   │   ├── OverpaymentAllocation.cs
│   │   │   ├── Payment.cs
│   │   │   ├── PaymentTerms.cs
│   │   │   ├── Phone.cs
│   │   │   ├── Prepayment.cs
│   │   │   ├── PrepaymentAllocation.cs
│   │   │   ├── PurchaseDetails.cs
│   │   │   ├── PurchaseOrder.cs
│   │   │   ├── Receipt.cs
│   │   │   ├── RepeatingInvoice.cs
│   │   │   ├── Reports/
│   │   │   │   ├── Report.cs
│   │   │   │   ├── ReportAttribute.cs
│   │   │   │   ├── ReportCell.cs
│   │   │   │   ├── ReportCellAttribute.cs
│   │   │   │   ├── ReportField.cs
│   │   │   │   └── ReportRow.cs
│   │   │   ├── SalesDetails.cs
│   │   │   ├── Schedule.cs
│   │   │   ├── Setup/
│   │   │   │   ├── AccountImportResult.cs
│   │   │   │   ├── ContactImportResult.cs
│   │   │   │   ├── ConversionBalance.cs
│   │   │   │   ├── ConversionDate.cs
│   │   │   │   ├── ConversionDetails.cs
│   │   │   │   ├── ImportSummary.cs
│   │   │   │   ├── OrganisationImportResult.cs
│   │   │   │   └── Setup.cs
│   │   │   ├── Status/
│   │   │   │   ├── AccountStatus.cs
│   │   │   │   ├── BankTransactionStatus.cs
│   │   │   │   ├── BatchPaymentStatus.cs
│   │   │   │   ├── ContactStatus.cs
│   │   │   │   ├── EmployeeStatus.cs
│   │   │   │   ├── ExpenseClaimStatus.cs
│   │   │   │   ├── InvoiceStatus.cs
│   │   │   │   ├── LinkedTransactionStatus.cs
│   │   │   │   ├── ManualJournalStatus.cs
│   │   │   │   ├── OrganisationStatus.cs
│   │   │   │   ├── OverpaymentStatus.cs
│   │   │   │   ├── PaymentStatus.cs
│   │   │   │   ├── PrepaymentStatus.cs
│   │   │   │   ├── PurchaseOrderStatus.cs
│   │   │   │   ├── ReceiptStatus.cs
│   │   │   │   ├── TaxRateStatus.cs
│   │   │   │   ├── TrackingCategoryStatus.cs
│   │   │   │   ├── TrackingOptionStatus.cs
│   │   │   │   └── ValidationStatus.cs
│   │   │   ├── TaxComponent.cs
│   │   │   ├── TaxRate.cs
│   │   │   ├── Terms.cs
│   │   │   ├── TrackingCategory.cs
│   │   │   ├── Types/
│   │   │   │   ├── AccountClassType.cs
│   │   │   │   ├── AccountType.cs
│   │   │   │   ├── AddressType.cs
│   │   │   │   ├── AttachmentEndpointType.cs
│   │   │   │   ├── BankAccountType.cs
│   │   │   │   ├── BankTransactionType.cs
│   │   │   │   ├── BatchPaymentType.cs
│   │   │   │   ├── BudgetSummaryTimeframeType.cs
│   │   │   │   ├── CreditNoteType.cs
│   │   │   │   ├── ExternalLinkType.cs
│   │   │   │   ├── HistoryAndNotesEndpointCreateType.cs
│   │   │   │   ├── HistoryAndNotesEndpointRetrieveType.cs
│   │   │   │   ├── InvoiceType.cs
│   │   │   │   ├── LineAmountType.cs
│   │   │   │   ├── LinkedTransactionType.cs
│   │   │   │   ├── NamedReportType.cs
│   │   │   │   ├── ObjectGroupType.cs
│   │   │   │   ├── ObjectType.cs
│   │   │   │   ├── OrganisationClass.cs
│   │   │   │   ├── OrganisationEdition.cs
│   │   │   │   ├── OrganisationType.cs
│   │   │   │   ├── OrganisationVersion.cs
│   │   │   │   ├── OverpaymentType.cs
│   │   │   │   ├── PaymentTermType.cs
│   │   │   │   ├── PaymentType.cs
│   │   │   │   ├── PdfEndpointType.cs
│   │   │   │   ├── PhoneType.cs
│   │   │   │   ├── PrepaymentType.cs
│   │   │   │   ├── ReportRowType.cs
│   │   │   │   ├── ReportTaxType.cs
│   │   │   │   ├── SalesTaxBasisType.cs
│   │   │   │   ├── SalesTaxPeriodType.cs
│   │   │   │   ├── SourceType.cs
│   │   │   │   ├── SystemAccountType.cs
│   │   │   │   ├── UnitType.cs
│   │   │   │   └── UserRole.cs
│   │   │   └── User.cs
│   │   ├── Request/
│   │   │   ├── AccountsRequest.cs
│   │   │   ├── BankTransactionsRequest.cs
│   │   │   ├── BankTransfersRequest.cs
│   │   │   ├── BatchPaymentsRequest.cs
│   │   │   ├── ContactGroupsRequest.cs
│   │   │   ├── ContactsRequest.cs
│   │   │   ├── CreditNotesRequest.cs
│   │   │   ├── CurrenciesRequest.cs
│   │   │   ├── EmployeesRequest.cs
│   │   │   ├── ExpenseClaimsRequest.cs
│   │   │   ├── FilesRequest.cs
│   │   │   ├── HistoryRecordsRequest.cs
│   │   │   ├── InvoicesRequest.cs
│   │   │   ├── ItemsRequest.cs
│   │   │   ├── LinkedTransactionsRequest.cs
│   │   │   ├── ManualJournalsRequest.cs
│   │   │   ├── OnlineInvoicesRequest.cs
│   │   │   ├── PaymentsRequest.cs
│   │   │   ├── PurchaseOrdersRequest.cs
│   │   │   ├── ReceiptsRequest.cs
│   │   │   ├── SetupRequest.cs
│   │   │   ├── TaxRatesRequest.cs
│   │   │   └── TrackingCategoriesRequest.cs
│   │   ├── Response/
│   │   │   ├── AccountsResponse.cs
│   │   │   ├── AttachmentsResponse.cs
│   │   │   ├── BankTransactionsResponse.cs
│   │   │   ├── BankTransfersResponse.cs
│   │   │   ├── BatchPaymentsResponse.cs
│   │   │   ├── BrandingThemesResponse.cs
│   │   │   ├── ContactCisSettingsResponse.cs
│   │   │   ├── ContactGroupsResponse.cs
│   │   │   ├── ContactsResponse.cs
│   │   │   ├── CreditNotesResponse.cs
│   │   │   ├── CurrenciesResponse.cs
│   │   │   ├── EmployeesResponse.cs
│   │   │   ├── ExpenseClaimsResponse.cs
│   │   │   ├── FilesResponse.cs
│   │   │   ├── FoldersResponse.cs
│   │   │   ├── HistoryRecordsResponse.cs
│   │   │   ├── InboxResponse.cs
│   │   │   ├── InvoicesResponse.cs
│   │   │   ├── ItemsResponse.cs
│   │   │   ├── JournalsResponse.cs
│   │   │   ├── LinkedTransactionsResponse.cs
│   │   │   ├── ManualJournalsResponse.cs
│   │   │   ├── OnlineInvoicesResponse.cs
│   │   │   ├── OptionsResponse.cs
│   │   │   ├── OrganisationCisSettingsResponse.cs
│   │   │   ├── OrganisationResponse.cs
│   │   │   ├── OverpaymentsResponse.cs
│   │   │   ├── PaymentsResponse.cs
│   │   │   ├── PrepaymentsResponse.cs
│   │   │   ├── PurchaseOrdersResponse.cs
│   │   │   ├── ReceiptsResponse.cs
│   │   │   ├── RepeatingInvoicesResponse.cs
│   │   │   ├── ReportsResponse.cs
│   │   │   ├── SetupResponse.cs
│   │   │   ├── TaxRatesResponse.cs
│   │   │   ├── TrackingCategoriesResponse.cs
│   │   │   └── UsersResponse.cs
│   │   └── XeroCoreApi.cs
│   ├── Infrastructure/
│   │   ├── Exceptions/
│   │   │   ├── ApiException.cs
│   │   │   ├── BadRequestException.cs
│   │   │   ├── NotAvailableException.cs
│   │   │   ├── NotFoundException.cs
│   │   │   ├── RateExceededException.cs
│   │   │   ├── UnauthorizedException.cs
│   │   │   ├── ValidationException.cs
│   │   │   └── XeroApiException.cs
│   │   ├── Http/
│   │   │   ├── HttpClient.cs
│   │   │   ├── Response.cs
│   │   │   └── XeroHttpClient.cs
│   │   ├── Interfaces/
│   │   │   ├── IAuthenticationToken.cs
│   │   │   ├── IAuthenticator.cs
│   │   │   ├── IConsumer.cs
│   │   │   ├── IJsonObjectMapper.cs
│   │   │   ├── ITokenStore.cs
│   │   │   ├── IUser.cs
│   │   │   ├── IXeroRequest.cs
│   │   │   ├── IXeroResponse.cs
│   │   │   └── IXmlObjectMapper.cs
│   │   ├── Model/
│   │   │   ├── DataContractBase.cs
│   │   │   ├── ValidationError.cs
│   │   │   └── Warning.cs
│   │   ├── OAuth/
│   │   │   ├── ApiUser.cs
│   │   │   ├── Consumer.cs
│   │   │   ├── OAuthException.cs
│   │   │   ├── OAuthTokens.cs
│   │   │   ├── Signing/
│   │   │   │   ├── HmacSha1Signer.cs
│   │   │   │   └── RsaSha1Signer.cs
│   │   │   ├── Token.cs
│   │   │   └── UnexpectedOauthResponseException.cs
│   │   ├── RateLimiter/
│   │   │   ├── IRateLimiter.cs
│   │   │   └── RateLimiter.cs
│   │   └── ThirdParty/
│   │       ├── Dust/
│   │       │   ├── ConsumerKey.cs
│   │       │   ├── Core/
│   │       │   │   ├── Request.cs
│   │       │   │   ├── SignatureBaseString.cs
│   │       │   │   └── SignatureBaseStringParts/
│   │       │   │       ├── Earl/
│   │       │   │       │   └── EarlPart.cs
│   │       │   │       ├── Parameters/
│   │       │   │       │   ├── Name.cs
│   │       │   │       │   ├── Nonce/
│   │       │   │       │   │   ├── DefaultNonceSequence.cs
│   │       │   │       │   │   └── NonceSequence.cs
│   │       │   │       │   ├── OAuthParameters.cs
│   │       │   │       │   ├── Parameter.cs
│   │       │   │       │   ├── ParameterEncoding.cs
│   │       │   │       │   ├── ParameterPart.cs
│   │       │   │       │   ├── Parameters.cs
│   │       │   │       │   ├── RequestParameters.cs
│   │       │   │       │   └── Timestamp/
│   │       │   │       │       ├── DefaultTimestampSequence.cs
│   │       │   │       │       └── TimestampSequence.cs
│   │       │   │       └── Verb/
│   │       │   │           └── VerbPart.cs
│   │       │   ├── HmacSha1.cs
│   │       │   ├── Http/
│   │       │   │   └── AuthorizationHeader.cs
│   │       │   ├── Lang/
│   │       │   │   └── ObjectExtensions.cs
│   │       │   ├── RsaSha1.cs
│   │       │   └── TokenKey.cs
│   │       ├── HttpUtility/
│   │       │   ├── HttpEncoder.cs
│   │       │   ├── HttpUtility.cs
│   │       │   └── UrlEncoder.cs
│   │       └── ServiceStack.Text/
│   │           ├── AssemblyUtils.cs
│   │           ├── CollectionExtensions.cs
│   │           ├── Common/
│   │           │   ├── DateTimeSerializer.cs
│   │           │   ├── DeserializeArray.cs
│   │           │   ├── DeserializeBuiltin.cs
│   │           │   ├── DeserializeCollection.cs
│   │           │   ├── DeserializeDictionary.cs
│   │           │   ├── DeserializeDynamic.cs
│   │           │   ├── DeserializeKeyValuePair.cs
│   │           │   ├── DeserializeListWithElements.cs
│   │           │   ├── DeserializeSpecializedCollections.cs
│   │           │   ├── DeserializeType.cs
│   │           │   ├── DeserializeTypeRef.cs
│   │           │   ├── DeserializeTypeRefJson.cs
│   │           │   ├── DeserializeTypeRefJsv.cs
│   │           │   ├── DeserializeTypeUtils.cs
│   │           │   ├── ITypeSerializer.cs
│   │           │   ├── JsDelegates.cs
│   │           │   ├── JsReader.cs
│   │           │   ├── JsState.cs
│   │           │   ├── JsWriter.cs
│   │           │   ├── ParseUtils.cs
│   │           │   ├── StaticParseMethod.cs
│   │           │   ├── WriteDictionary.cs
│   │           │   ├── WriteLists.cs
│   │           │   └── WriteType.cs
│   │           ├── Controller/
│   │           │   ├── CommandProcessor.cs
│   │           │   └── PathInfo.cs
│   │           ├── CsvAttribute.cs
│   │           ├── CsvConfig.cs
│   │           ├── CsvSerializer.cs
│   │           ├── CsvStreamExtensions.cs
│   │           ├── CsvWriter.cs
│   │           ├── DateTimeExtensions.cs
│   │           ├── DynamicJson.cs
│   │           ├── DynamicProxy.cs
│   │           ├── Env.cs
│   │           ├── HashSet.cs
│   │           ├── ITracer.cs
│   │           ├── ITypeSerializer.Generic.cs
│   │           ├── JsConfig.cs
│   │           ├── JsConfigScope.cs
│   │           ├── Json/
│   │           │   ├── JsonReader.Generic.cs
│   │           │   ├── JsonTypeSerializer.cs
│   │           │   ├── JsonUtils.cs
│   │           │   └── JsonWriter.Generic.cs
│   │           ├── JsonObject.cs
│   │           ├── JsonSerializer.Generic.cs
│   │           ├── JsonSerializer.cs
│   │           ├── Jsv/
│   │           │   ├── JsvDeserializeType.cs
│   │           │   ├── JsvReader.Generic.cs
│   │           │   ├── JsvSerializer.Generic.cs
│   │           │   ├── JsvTypeSerializer.cs
│   │           │   └── JsvWriter.Generic.cs
│   │           ├── JsvFormatter.cs
│   │           ├── ListExtensions.cs
│   │           ├── MapExtensions.cs
│   │           ├── Marc/
│   │           │   ├── Link.cs
│   │           │   ├── ObjectAccessor.cs
│   │           │   └── TypeAccessor.cs
│   │           ├── QueryStringSerializer.cs
│   │           ├── Reflection/
│   │           │   └── StaticAccessors.cs
│   │           ├── ReflectionExtensions.cs
│   │           ├── StreamExtensions.cs
│   │           ├── StringExtensions.cs
│   │           ├── Support/
│   │           │   ├── AssemblyTypeDefinition.cs
│   │           │   ├── DoubleConverter.cs
│   │           │   └── TypePair.cs
│   │           ├── SystemTime.cs
│   │           ├── TextExtensions.cs
│   │           ├── Tracer.cs
│   │           ├── TranslateListWithElements.cs
│   │           ├── TypeConfig.cs
│   │           ├── TypeSerializer.Generic.cs
│   │           ├── TypeSerializer.cs
│   │           ├── WebRequestExtensions.cs
│   │           └── XmlSerializer.cs
│   ├── Payroll/
│   │   ├── America/
│   │   │   ├── Endpoints/
│   │   │   │   ├── EmployeesEndpoint.cs
│   │   │   │   ├── PayItemsEndpoint.cs
│   │   │   │   ├── PayRunsEndpoint.cs
│   │   │   │   ├── PaySchedulesEndpoint.cs
│   │   │   │   ├── PayStubsEndpoint.cs
│   │   │   │   ├── SettingsEndpoint.cs
│   │   │   │   ├── TimesheetsEndpoint.cs
│   │   │   │   └── WorkLocationsEndpoint.cs
│   │   │   ├── Model/
│   │   │   │   ├── Account.cs
│   │   │   │   ├── Address.cs
│   │   │   │   ├── BankAccount.cs
│   │   │   │   ├── BenefitLine.cs
│   │   │   │   ├── BenefitType.cs
│   │   │   │   ├── DeductionLine.cs
│   │   │   │   ├── DeductionType.cs
│   │   │   │   ├── EarningsLine.cs
│   │   │   │   ├── EarningsType.cs
│   │   │   │   ├── Employee.cs
│   │   │   │   ├── HomeAddress.cs
│   │   │   │   ├── MailingAddress.cs
│   │   │   │   ├── OpeningBalances.cs
│   │   │   │   ├── PayItems.cs
│   │   │   │   ├── PayRun.cs
│   │   │   │   ├── PaySchedule.cs
│   │   │   │   ├── PayStub.cs
│   │   │   │   ├── PayTemplate.cs
│   │   │   │   ├── PaymentMethod.cs
│   │   │   │   ├── ReimbursementLine.cs
│   │   │   │   ├── ReimbursementType.cs
│   │   │   │   ├── SalaryAndWage.cs
│   │   │   │   ├── Settings.cs
│   │   │   │   ├── TimeOffType.cs
│   │   │   │   ├── Timesheet.cs
│   │   │   │   ├── TimesheetLine.cs
│   │   │   │   ├── Types/
│   │   │   │   │   ├── AccountType.cs
│   │   │   │   │   ├── BenefitCategoryType.cs
│   │   │   │   │   ├── CalculationType.cs
│   │   │   │   │   ├── DeductionCategoryType.cs
│   │   │   │   │   ├── EarningsCategoryType.cs
│   │   │   │   │   ├── EmploymentBasisType.cs
│   │   │   │   │   ├── PaymentMethodType.cs
│   │   │   │   │   ├── RateType.cs
│   │   │   │   │   ├── SalaryWagesType.cs
│   │   │   │   │   ├── ScheduleType.cs
│   │   │   │   │   ├── State.cs
│   │   │   │   │   ├── TimeOffCategoryType.cs
│   │   │   │   │   └── UnitType.cs
│   │   │   │   └── WorkLocation.cs
│   │   │   ├── Request/
│   │   │   │   ├── EmployeesRequest.cs
│   │   │   │   ├── PayItemsRequest.cs
│   │   │   │   ├── PayRunsRequest.cs
│   │   │   │   ├── PaySchedulesRequest.cs
│   │   │   │   ├── PayStubsRequest.cs
│   │   │   │   ├── TimesheetsRequest.cs
│   │   │   │   └── WorkLocationsRequest.cs
│   │   │   └── Response/
│   │   │       ├── EmployeesResponse.cs
│   │   │       ├── PayItemsResponse.cs
│   │   │       ├── PayRunsResponse.cs
│   │   │       ├── PaySchedulesResponse.cs
│   │   │       ├── PayStubsResponse.cs
│   │   │       ├── SettingsResponse.cs
│   │   │       ├── TimesheetsResponse.cs
│   │   │       └── WorkLocationsResponse.cs
│   │   ├── AmericanPayroll.cs
│   │   ├── Australia/
│   │   │   ├── Endpoints/
│   │   │   │   ├── EmployeesEndpoint.cs
│   │   │   │   ├── LeaveApplicationsEndpoint.cs
│   │   │   │   ├── PayItemsEndpoint.cs
│   │   │   │   ├── PayRunsEndpoint.cs
│   │   │   │   ├── PayrollCalendarsEndpoint.cs
│   │   │   │   ├── PayslipsEndpoint.cs
│   │   │   │   ├── SettingsEndpoint.cs
│   │   │   │   ├── SuperFundProductsEndpoint.cs
│   │   │   │   ├── SuperFundsEndpoint.cs
│   │   │   │   └── TimesheetsEndpoint.cs
│   │   │   ├── Model/
│   │   │   │   ├── Account.cs
│   │   │   │   ├── BankAccount.cs
│   │   │   │   ├── DeductionLine.cs
│   │   │   │   ├── DeductionType.cs
│   │   │   │   ├── EarningsLine.cs
│   │   │   │   ├── EarningsRate.cs
│   │   │   │   ├── Employee.cs
│   │   │   │   ├── HomeAddress.cs
│   │   │   │   ├── LeaveAccuralLine.cs
│   │   │   │   ├── LeaveApplication.cs
│   │   │   │   ├── LeaveBalance.cs
│   │   │   │   ├── LeaveEarningsLine.cs
│   │   │   │   ├── LeaveLine.cs
│   │   │   │   ├── LeavePeriod.cs
│   │   │   │   ├── LeaveType.cs
│   │   │   │   ├── OpeningBalances.cs
│   │   │   │   ├── PayItems.cs
│   │   │   │   ├── PayRun.cs
│   │   │   │   ├── PayTemplate.cs
│   │   │   │   ├── PayrollCalendar.cs
│   │   │   │   ├── Payslip.cs
│   │   │   │   ├── PayslipEarningsLine.cs
│   │   │   │   ├── ReimbursementLine.cs
│   │   │   │   ├── ReimbursementType.cs
│   │   │   │   ├── Settings.cs
│   │   │   │   ├── Status/
│   │   │   │   │   ├── EmploymentStatus.cs
│   │   │   │   │   ├── LeavePeriodStatus.cs
│   │   │   │   │   ├── ResidencyStatusType.cs
│   │   │   │   │   └── TimesheetStatus.cs
│   │   │   │   ├── SuperFund.cs
│   │   │   │   ├── SuperFundProduct.cs
│   │   │   │   ├── SuperLine.cs
│   │   │   │   ├── SuperMembership.cs
│   │   │   │   ├── SuperannuationLine.cs
│   │   │   │   ├── TaxDeclaration.cs
│   │   │   │   ├── TaxLine.cs
│   │   │   │   ├── Timesheet.cs
│   │   │   │   ├── TimesheetEarningsLine.cs
│   │   │   │   ├── TimesheetLine.cs
│   │   │   │   └── Types/
│   │   │   │       ├── CalendarType.cs
│   │   │   │       ├── DeductionCalculationType.cs
│   │   │   │       ├── EarningsRateCalculationType.cs
│   │   │   │       ├── EarningsType.cs
│   │   │   │       ├── EmploymentBasisType.cs
│   │   │   │       ├── LeaveCalculationType.cs
│   │   │   │       ├── LeaveContributionType.cs
│   │   │   │       ├── PaymentFrequencyType.cs
│   │   │   │       ├── RateType.cs
│   │   │   │       ├── State.cs
│   │   │   │       ├── SuperannuationCalculationType.cs
│   │   │   │       ├── SuperannuationContributionType.cs
│   │   │   │       ├── SuperfundType.cs
│   │   │   │       └── TaxFileNumberExemptionType.cs
│   │   │   ├── Request/
│   │   │   │   ├── EmployeesRequest.cs
│   │   │   │   ├── LeaveApplicationsRequest.cs
│   │   │   │   ├── PayItemsRequest.cs
│   │   │   │   ├── PayRunsRequest.cs
│   │   │   │   ├── PayrollCalendarsRequest.cs
│   │   │   │   ├── PayslipRequest.cs
│   │   │   │   ├── SuperFundsRequest.cs
│   │   │   │   └── TimesheetsRequest.cs
│   │   │   └── Response/
│   │   │       ├── EmployeesResponse.cs
│   │   │       ├── LeaveApplicationsResponse.cs
│   │   │       ├── PayItemsResponse.cs
│   │   │       ├── PayRunsResponse.cs
│   │   │       ├── PayrollCalendarResponse.cs
│   │   │       ├── PayslipsResponse.cs
│   │   │       ├── SettingsResponse.cs
│   │   │       ├── SuperFundProductsResponse.cs
│   │   │       ├── SuperFundsResponse.cs
│   │   │       └── TimesheetsResponse.cs
│   │   ├── AustralianPayroll.cs
│   │   └── Common/
│   │       ├── Model/
│   │       │   ├── Account.cs
│   │       │   ├── NumberOfUnits.cs
│   │       │   ├── PayNotice.cs
│   │       │   ├── PayRun.cs
│   │       │   ├── PayrollSettingsTrackingCategories.cs
│   │       │   ├── Status/
│   │       │   │   └── PayRunStatus.cs
│   │       │   └── TrackingCategory.cs
│   │       ├── PayrollApi.cs
│   │       └── PayrollEndpoint.cs
│   ├── Properties/
│   │   └── AssemblyInfo.cs
│   ├── README.md
│   ├── Serialization/
│   │   └── DefaultMapper.cs
│   ├── Xero.Api.csproj
│   └── packages.config
├── Xero.Api.Example.Applications/
│   ├── Partner/
│   │   ├── AmericanPayroll.cs
│   │   ├── AustralianPayroll.cs
│   │   ├── Core.cs
│   │   ├── PartnerAuthenticator.cs
│   │   ├── PartnerMvcAuthenticator.cs
│   │   └── Settings.cs
│   ├── Private/
│   │   ├── AmericanPayroll.cs
│   │   ├── AustralianPayroll.cs
│   │   ├── Core.cs
│   │   ├── PrivateAuthenticator.cs
│   │   └── Settings.cs
│   ├── Properties/
│   │   └── AssemblyInfo.cs
│   ├── Public/
│   │   ├── AmericanPayroll.cs
│   │   ├── AustralianPayroll.cs
│   │   ├── Core.cs
│   │   ├── IMvcAuthenticator.cs
│   │   ├── PublicAuthenticator.cs
│   │   ├── PublicMvcAuthenticator.cs
│   │   ├── RenewTokenException.cs
│   │   └── Settings.cs
│   ├── TokenStoreAuthenticator.cs
│   └── Xero.Api.Example.Applications.csproj
├── Xero.Api.Example.Counts/
│   ├── App.config
│   ├── Lister.cs
│   ├── Program.cs
│   ├── Properties/
│   │   └── AssemblyInfo.cs
│   ├── README.md
│   ├── Resources/
│   │   └── cert/
│   │       └── public_privatekey.txt
│   └── Xero.Api.Example.Counts.csproj
├── Xero.Api.Example.Creation/
│   ├── ApiDataCreation.cs
│   ├── App.config
│   ├── Creator/
│   │   ├── Creator.cs
│   │   ├── Name.cs
│   │   └── PlaceName.cs
│   ├── Program.cs
│   ├── Properties/
│   │   └── AssemblyInfo.cs
│   ├── README.md
│   ├── Resources/
│   │   └── cert/
│   │       └── public_privatekey.txt
│   ├── Xero.Api.Example.Creation.csproj
│   └── data/
│       ├── Descriptions.txt
│       ├── Given.txt
│       ├── Surnames.txt
│       ├── place_index.txt
│       └── street_index.txt
├── Xero.Api.Example.MVC/
│   ├── App_Start/
│   │   ├── FilterConfig.cs
│   │   ├── RouteConfig.cs
│   │   └── WebApiConfig.cs
│   ├── Content/
│   │   └── Site.css
│   ├── Controllers/
│   │   ├── HomeController.cs
│   │   └── OrganisationController.cs
│   ├── Global.asax
│   ├── Global.asax.cs
│   ├── Helpers/
│   │   └── XeroApiHelper.cs
│   ├── Properties/
│   │   └── AssemblyInfo.cs
│   ├── README.md
│   ├── Stores/
│   │   ├── MemoryAccessTokenStore.cs
│   │   └── MemoryRequestTokenStore.cs
│   ├── Views/
│   │   ├── Home/
│   │   │   ├── Authorize.cshtml
│   │   │   ├── Connect.cshtml
│   │   │   ├── Index.cshtml
│   │   │   └── NoAuthorized.cshtml
│   │   ├── Organisation/
│   │   │   └── Index.cshtml
│   │   ├── Shared/
│   │   │   ├── Error.cshtml
│   │   │   └── _Layout.cshtml
│   │   ├── Web.config
│   │   └── _ViewStart.cshtml
│   ├── Web.Debug.config
│   ├── Web.Release.config
│   ├── Web.config
│   ├── Xero.Api.Example.MVC.csproj
│   ├── Xero.Api.Example.MVC.sln
│   └── packages.config
├── Xero.Api.Example.Mocks/
│   ├── App.config
│   ├── ContactManagerAndTests/
│   │   ├── ContactManager.cs
│   │   └── ContactManagerTests.cs
│   ├── Lister.cs
│   ├── Program.cs
│   ├── Properties/
│   │   └── AssemblyInfo.cs
│   ├── Xero.Api.Example.Mocks.csproj
│   └── packages.config
├── Xero.Api.Example.TokenStores/
│   ├── Dapper/
│   │   └── Dapper.cs
│   ├── MemoryTokenStore.cs
│   ├── Properties/
│   │   └── AssemblyInfo.cs
│   ├── SqliteTokenStore.cs
│   ├── Xero.Api.Example.TokenStores.csproj
│   ├── app.config
│   └── packages.config
├── Xero.Api.sln
├── build.bat
├── minimal.nuspec
└── nuget.nuspec
Download .txt
Showing preview only (332K chars total). Download the full file or copy to clipboard to get everything.
SYMBOL INDEX (3245 symbols across 726 files)

FILE: CoreTests/ApiWrapperTest.cs
  class ApiWrapperTest (line 7) | public class ApiWrapperTest
    method ApiWrapperTest (line 9) | public ApiWrapperTest()
    method CreateCoreApi (line 24) | private static IXeroCoreApi CreateCoreApi()
    method SetUp (line 32) | protected void SetUp()
    method Given_a_bank_account (line 38) | protected Account Given_a_bank_account()
    method Given_an_account (line 43) | protected Account Given_an_account()

FILE: CoreTests/Integration/Accounts/Create.cs
  class Create (line 8) | [TestFixture]
    method create_account (line 11) | [Test]
    method create_bank_account (line 24) | [Test]
    method incorrect_types_are_rejected (line 36) | [Test]

FILE: CoreTests/Integration/Accounts/Find.cs
  class Find (line 10) | [TestFixture]
    method find_by_value (line 13) | [Test]
    method find_by_id (line 24) | [Test]
    method finding_a_non_system_account_has_null_SystemAccount (line 38) | [Test]
    method find_accounts_ifmodifiedsince (line 54) | [Test]

FILE: CoreTests/Integration/Accounts/Update.cs
  class Update (line 9) | public class Update : ApiWrapperTest
    method Update_account (line 11) | [Test]
    method Archive_account (line 28) | [Test]
    method CreateAccount (line 44) | private Account CreateAccount()

FILE: CoreTests/Integration/Allocations/Add.cs
  class Add (line 10) | [TestFixture]
    method allocation_to_invoice (line 13) | [Test]
    method allocation_to_invoice_minimal (line 32) | [Test]
    method allocation_on_creditnote (line 52) | [Test]
    method allocation_on_prepayment (line 72) | [Test]
    method allocation_on_overpayment (line 92) | [Test]
    method Credit_notes_show_up_on_invoices (line 112) | [Test]
    method Prepayments_show_on_invoices (line 133) | [Test]
    method Overpayments_show_on_invoices (line 153) | [Test]

FILE: CoreTests/Integration/Attachments/Attachments.cs
  class Attachments (line 12) | public class Attachments : ApiWrapperTest
    method adding_attachment_to_invoice (line 17) | [Test]
    method listing_attachments (line 25) | [Test]
    method getting_attachment (line 37) | [Test]
    method saving_attachments (line 49) | [Test]
    method saving_attachment_online_invoice_accrec (line 70) | [Test]
    method saving_attachment_online_invoice_accpay (line 78) | [Test]
    method saving_attachment_online_credit_note (line 86) | [Test]
    method saving_attachment_credit_note (line 94) | [Test]
    method can_save_attachments_with_spaces_in_the_name (line 102) | [Test]
    method Given_attachment_on_invoice (line 110) | private Attachment Given_attachment_on_invoice(bool includeOnline = fa...
    method Given_an_attachment_with_a_space_in_the_name_on_an_invoice (line 115) | private Attachment Given_an_attachment_with_a_space_in_the_name_on_an_...
    method Given_attachment_on_credit_note (line 120) | private Attachment Given_attachment_on_credit_note(bool includeOnline ...
    method CreateAttachment (line 126) | private Attachment CreateAttachment(Guid id, AttachmentEndpointType ty...
    method CreateAttachment (line 131) | private Attachment CreateAttachment(Guid id, AttachmentEndpointType ty...
    method GetAttachment (line 136) | private Attachment GetAttachment(Guid id, AttachmentEndpointType type,...
    method Given_invoice_with_no_attachments (line 141) | private Guid Given_invoice_with_no_attachments(bool accRec = false)
    method Given_credit_note_with_no_attachments (line 158) | private Guid Given_credit_note_with_no_attachments()

FILE: CoreTests/Integration/BankTransactionTest.cs
  class BankTransactionTest (line 9) | public class BankTransactionTest : ApiWrapperTest
    method NewBankTransaction (line 12) | public BankTransaction NewBankTransaction()
    method FindBankAccountGuid (line 36) | public Guid FindBankAccountGuid()

FILE: CoreTests/Integration/BankTransactions/BankTransactionTest.cs
  class BankTransactionTest (line 9) | public class BankTransactionTest : ApiWrapperTest
    method Given_a_bank_transaction (line 11) | public BankTransaction Given_a_bank_transaction()
    method Given_a_bank_transaction (line 16) | public BankTransaction Given_a_bank_transaction(BankTransactionType type)
    method Given_an_overpayment (line 36) | public BankTransaction Given_an_overpayment(BankTransactionType type)
    method FindBankAccountGuid (line 56) | public Guid FindBankAccountGuid()

FILE: CoreTests/Integration/BankTransactions/Create.cs
  class Create (line 5) | [TestFixture]
    method create_bank_transactions (line 8) | [Test]

FILE: CoreTests/Integration/BankTransactions/Find.cs
  class Find (line 7) | [TestFixture]
    method find_bank_transactions_where_filter (line 10) | [Test]
    method find_bank_transactions_ifmodifiedsince (line 19) | [Test]
    method find_bank_transactions_individual (line 31) | [Test]
    method find_by_page (line 41) | [Test]

FILE: CoreTests/Integration/BankTransactions/Update.cs
  class Update (line 7) | [TestFixture]
    method update_bank_transaction (line 10) | [Test]

FILE: CoreTests/Integration/BankTransfers/BankTransfersTest.cs
  class BankTransfersTest (line 8) | public abstract class BankTransfersTest : ApiWrapperTest
    method Given_a_bank_transfer (line 11) | public BankTransfer Given_a_bank_transfer(Decimal amount)
    method get_bankaccount_ids (line 26) | public IList<Guid> get_bankaccount_ids()

FILE: CoreTests/Integration/BankTransfers/Create.cs
  class Create (line 5) | [TestFixture]
    method create_bank_transfer (line 8) | [Test]

FILE: CoreTests/Integration/BankTransfers/Find.cs
  class Find (line 7) | [TestFixture]
    method find_bank_transfers (line 10) | [Test]
    method find_bank_transfers_individual (line 20) | [Test]
    method find_bank_transfers_ifmodifiedsince (line 30) | [Test]

FILE: CoreTests/Integration/BatchPayment/BatchPaymentsTest.cs
  class BatchPaymentsTest (line 9) | public abstract class BatchPaymentsTest : ApiWrapperTest
    method Given_a_batch_payment (line 11) | protected BatchPayment Given_a_batch_payment(decimal invoiceAmount, Da...
    method CreateBatchPayment (line 18) | protected BatchPayment CreateBatchPayment(decimal invoiceAmount, DateT...
    method Given_an_invoice (line 42) | private Invoice Given_an_invoice(decimal amount = 100m, string account...

FILE: CoreTests/Integration/BatchPayment/Create.cs
  class Create (line 9) | [TestFixture]
    method CreateBatchPaymentsSetUp (line 12) | [TestFixtureSetUp]
    method create_simple_batch_payment (line 18) | [Test]

FILE: CoreTests/Integration/ContactGroups/Add_Contact.cs
  class Add_Contact (line 7) | [TestFixture]
    method Can_I_add_a_contact_to_a_contactgroup (line 10) | [Test]
    method But_not_with_a_group_like_this (line 18) | [Test]

FILE: CoreTests/Integration/ContactGroups/ContactGroupsTest.cs
  class ContactGroupsTest (line 9) | public abstract class ContactGroupsTest : ApiWrapperTest
    method Given_a_contact (line 12) | protected Contact Given_a_contact()
    method Given_a_contactgroup (line 20) | protected ContactGroup Given_a_contactgroup()

FILE: CoreTests/Integration/ContactGroups/Create.cs
  class Create (line 5) | [TestFixture]
    method Can_I_create_a_contactgroup (line 8) | [Test]

FILE: CoreTests/Integration/ContactGroups/Delete.cs
  class Delete (line 10) | [TestFixture]
    method Can_I_remove_the_contactgroup (line 13) | [Test]
    method Can_I_empty_the_contactgroup_of_contacts (line 25) | [Test]

FILE: CoreTests/Integration/ContactGroups/Find.cs
  class Find (line 6) | [TestFixture]
    method Can_Find_Contact_Group (line 9) | [Test]
    method Can_Find_Contacts_in_Contact_Group (line 19) | [Test]

FILE: CoreTests/Integration/ContactGroups/Remove_Contact.cs
  class Remove_Contact (line 9) | [TestFixture]
    method Can_remove_a_contact_from_a_contact_group (line 12) | [Test]

FILE: CoreTests/Integration/ContactGroups/Update.cs
  class Update (line 8) | [TestFixture]
    method Can_I_change_the_name_of_a_contactgroup (line 11) | [Test]
    method Can_I_append_contacts_to_a_contactgroup (line 25) | [Test]

FILE: CoreTests/Integration/Contacts/ContactsTest.cs
  class ContactsTest (line 8) | public abstract  class ContactsTest : ApiWrapperTest
    method Given_a_contact (line 13) | protected Contact Given_a_contact()
    method findOrCreateTC (line 22) | protected TrackingCategory findOrCreateTC(string OptionName, string TC...
    method deleteCreatedTC (line 50) | protected void deleteCreatedTC(TrackingCategory tc)

FILE: CoreTests/Integration/Contacts/Create.cs
  class Create (line 10) | [TestFixture]
    method create_contact (line 13) | [Test]
    method create_many_contact (line 21) | [Test]
    method create_complex_contact (line 47) | [Test]
    method create_contact_with_tracking (line 80) | [Test]

FILE: CoreTests/Integration/Contacts/Find.cs
  class Find (line 8) | [TestFixture]
    method find_by_page (line 11) | [Test]
    method find_by_id (line 19) | [Test]
    method find_by_id_list (line 31) | [Test]
    method find_by_value (line 41) | [Test]
    method find_by_contains_value (line 54) | [Test]
    method find_by_status (line 67) | [Test]
    method find_by_updated_date (line 80) | [Test]
    method find_by_dateRange (line 97) | [Test]

FILE: CoreTests/Integration/Contacts/Update.cs
  class Update (line 10) | public class Update : ContactsTest
    method update_contact (line 12) | [Test]

FILE: CoreTests/Integration/CreditNotes/Create.cs
  class Create (line 6) | [TestFixture]
    method create_creditnote (line 9) | [Test]

FILE: CoreTests/Integration/CreditNotes/CreditNotesTest.cs
  class CreditNotesTest (line 9) | public class CreditNotesTest : ApiWrapperTest
    method Given_an_authorised_creditnote (line 11) | public CreditNote Given_an_authorised_creditnote(CreditNoteType type =...
    method Given_a_draft_creditnote (line 16) | public CreditNote Given_a_draft_creditnote(CreditNoteType type = Credi...
    method Given_a_creditnote (line 21) | public CreditNote Given_a_creditnote(string contactName = "Apple Compu...

FILE: CoreTests/Integration/CreditNotes/Find.cs
  class Find (line 7) | [TestFixture]
    method find_all_creditnotes (line 10) | [Test]
    method find_by_id (line 18) | [Test]
    method find_by_value (line 27) | [Test]
    method find_orderby_value (line 41) | [Test]

FILE: CoreTests/Integration/CreditNotes/Update.cs
  class Update (line 8) | [TestFixture]
    method delete_draft_creditnote (line 11) | [Test]
    method update_creditnote_lineitems (line 24) | [Test]

FILE: CoreTests/Integration/ExpenseClaims/Create.cs
  class Create (line 6) | [TestFixture]
    method create_expense_claim (line 9) | [Test]

FILE: CoreTests/Integration/ExpenseClaims/ExpenseClaimTest.cs
  class ExpenseClaimTest (line 9) | public abstract class ExpenseClaimTest : ApiWrapperTest
    method Given_a_receipt (line 11) | public Receipt Given_a_receipt(Guid userId, string contactName, string...
    method Given_an_expense_claim (line 36) | public ExpenseClaim Given_an_expense_claim(Guid userId, Guid receiptId...

FILE: CoreTests/Integration/ExpenseClaims/Update.cs
  class Update (line 8) | [TestFixture]
    method authorise_expense_claim (line 11) | [Test]
    method void_expense_claim (line 31) | [Test]

FILE: CoreTests/Integration/Files/Associations/AssociationTest.cs
  class AssociationTest (line 10) | [TestFixture]
    method FindAFileId (line 13) | private Guid FindAFileId()
    method FindAnInvoiceId (line 19) | private Guid FindAnInvoiceId()
    method AssociationsForFile (line 25) | [Test]
    method AssociationsForObject (line 36) | [Test]
    method AssociationCreateFindAndDelete (line 49) | [Test]

FILE: CoreTests/Integration/Files/Files/AddFileTest.cs
  class AddFileTest (line 11) | [TestFixture]
    method can_get_all_files_like_this (line 16) | [Test]
    method can_get_the_content_of_a_file_like_this (line 24) | [Test]
    method can_remove_a_file_like_this (line 38) | [Test]
    method can_rename_a_file_like_this (line 53) | [Test]
    method can_move_a_file_like_this (line 70) | [Test]
    method cannot_add_a_file_with_bad_filename_charactors (line 85) | [Test]
    method create_file_with_name (line 100) | private File create_file_with_name(string filename)

FILE: CoreTests/Integration/Files/Folders/AddFolderTest.cs
  class AddFolderTest (line 7) | public class AddFolderTest : FilesTest
    method can_create_a_folder_like_this (line 10) | [Test]
    method can_get_all_folders_like_this (line 17) | [Test]
    method can_remove_a_folder_like_this (line 29) | [Test]

FILE: CoreTests/Integration/Files/Inbox/InboxTest.cs
  class InboxTest (line 9) | [TestFixture]
    method can_get_the_inbox_like_this (line 13) | [Test]
    method can_add_a_file_to_inbox_like_this (line 23) | [Test]
    method can_remove_a_file_like_this (line 37) | [Test]
    method create_file_with_name (line 54) | private File create_file_with_name(string filename)

FILE: CoreTests/Integration/Files/Support/DataItem.cs
  class DataItem (line 6) | public class DataItem : IDisposable
    method DataItem (line 11) | public DataItem(FileInfo file, String contentType = "unknown")
    method DataItem (line 17) | public DataItem(Byte[] data, String contentType = "unknown")
    method Dispose (line 23) | public void Dispose()

FILE: CoreTests/Integration/Files/Support/DiskFile.cs
  class DiskFile (line 5) | public class DiskFile : File
    method DiskFile (line 11) | public DiskFile(string name)
    method DiskFile (line 15) | public DiskFile(string name, string path)

FILE: CoreTests/Integration/Files/Support/File.cs
  type File (line 3) | public interface File

FILE: CoreTests/Integration/Files/Support/FilesTest.cs
  class FilesTest (line 7) | public class FilesTest : ApiWrapperTest
    method FilesTest (line 12) | public FilesTest()
    method create_file_with_name (line 17) | private Xero.Api.Core.Model.File create_file_with_name(string filename)
    method Given_a_file_in (line 34) | protected Guid Given_a_file_in(Guid folderId, string filename)
    method Given_a_file_in (line 42) | protected Guid Given_a_file_in(Guid folderId)
    method Given_a_file_in (line 49) | protected Guid Given_a_file_in(Guid folderId,Xero.Api.Core.Model.File ...
    method GetFileBytes (line 56) | internal static byte[] GetFileBytes(string name, string fileName)

FILE: CoreTests/Integration/General/Errors.cs
  class Errors (line 8) | [TestFixture]
    method not_found (line 11) | [Test]
    method bad_query (line 17) | [Test]
    method validation_error (line 23) | [Test]

FILE: CoreTests/Integration/General/FindingAllItems.cs
  class FindingAllItems (line 5) | [TestFixture]
    method get_accounts (line 8) | [Test]
    method get_bank_transactions (line 14) | [Test]
    method get_bank_transfers (line 20) | [Test]
    method get_branding_themes (line 26) | [Test]
    method get_contacts (line 32) | [Test]
    method get_credit_notes (line 38) | [Test]
    method get_currencies (line 44) | [Test]
    method get_employees (line 50) | [Test]
    method get_expense_claims (line 56) | [Test]
    method get_invoices (line 62) | [Test]
    method get_items (line 68) | [Test]
    method get_journals (line 74) | [Test]
    method get_manual_journals (line 80) | [Test]
    method get_payments (line 86) | [Test]
    method get_receipts (line 92) | [Test]
    method get_repeating_invoices (line 98) | [Test]
    method get_tax_rates (line 104) | [Test]
    method get_tracking_categories (line 110) | [Test]
    method get_users (line 116) | [Test]

FILE: CoreTests/Integration/General/QueryStrings.cs
  class QueryStrings (line 6) | [TestFixture]
    method query_string_is_as_expected (line 9) | [Test]
    method complex_query_string_is_as_expected (line 15) | [Test]
    method contact_query_string_is_as_expected (line 27) | [Test]

FILE: CoreTests/Integration/HistoryAndNotes/CreateNotes.cs
  class CreateNotes (line 5) | public class CreateNotes : HistoryAndNotesTest
    method Can_create_notes (line 7) | [Test]

FILE: CoreTests/Integration/HistoryAndNotes/Find.cs
  class Find (line 5) | public class Find : HistoryAndNotesTest
    method Can_fetch_history_and_notes (line 7) | [Test]

FILE: CoreTests/Integration/HistoryAndNotes/HistoryAndNotesTest.cs
  class HistoryAndNotesTest (line 10) | public class HistoryAndNotesTest : ApiWrapperTest
    method Given_a_contact (line 15) | protected void Given_a_contact()
    method Given_a_note_with_these_details (line 20) | protected void Given_a_note_with_these_details(string details)
    method When_I_retrieve_history_and_notes_for_the_contact (line 29) | protected void When_I_retrieve_history_and_notes_for_the_contact()
    method Then_there_are_some_history_records (line 34) | protected void Then_there_are_some_history_records()
    method Then_there_is_a_note_with_the_correct_details (line 39) | protected void Then_there_is_a_note_with_the_correct_details(string de...

FILE: CoreTests/Integration/Invoices/Create.cs
  class Create (line 11) | [TestFixture]
    method simple_create_works (line 14) | [Test]
    method description_only_items_work (line 22) | [Test]
    method accounts_receivable (line 31) | [Test]
    method lineItemId_is_returned (line 40) | [Test]
    method multiple_lineitems (line 48) | [Test]
    method multiple_invoices (line 79) | [Test]
    method high_precision_unit (line 120) | [Test]
    method low_precision_unit (line 143) | [Test]
    method full_example_line_items_with_tracking_categories (line 168) | [Test]
    method lineitems_without_account_code (line 245) | [Test]

FILE: CoreTests/Integration/Invoices/Find.cs
  class Find (line 9) | [TestFixture]
    method find_by_page (line 12) | [Test]
    method find_by_id (line 21) | [Test]
    method find_by_id_list (line 30) | [Test]
    method find_by_statuses_list (line 40) | [Test]
    method find_by_contact_id_list (line 49) | [Test]
    method find_by_invoice_number_list (line 58) | [Test]
    method find_by_mixture_of_query_param_lists (line 67) | [Test]
    method find_by_value (line 81) | [Test]
    method find_by_due_date (line 94) | [Test]
    method order_by_type (line 109) | [Test]

FILE: CoreTests/Integration/Invoices/InvoicesTest.cs
  class InvoicesTest (line 9) | public abstract class InvoicesTest : ApiWrapperTest
    method Given_an_draft_invoice (line 11) | public Invoice Given_an_draft_invoice(InvoiceType type = InvoiceType.A...
    method Given_an_authorised_invoice (line 16) | public Invoice Given_an_authorised_invoice(InvoiceType type = InvoiceT...
    method Given_an_invoice (line 21) | public Invoice Given_an_invoice(InvoiceType type = InvoiceType.Account...
    method Given_a_description_only_invoice (line 45) | public Invoice Given_a_description_only_invoice(InvoiceType type = Inv...

FILE: CoreTests/Integration/Invoices/OnlineInvoiceUrl.cs
  class OnlineInvoiceUrl (line 7) | [TestFixture]
    method find_the_online_invoice_url_for_an_accrec_invoice (line 11) | [Test]

FILE: CoreTests/Integration/Invoices/SummarizeErrors.cs
  class SummarizeErrors (line 12) | [TestFixture]
    method summariseErrors_gives_200 (line 15) | [Test]
    method errors_gives_validation_exception (line 24) | [Test] public void errors_gives_validation_exception()
    method Given_a_bad_invoice (line 29) | private IEnumerable<Invoice> Given_a_bad_invoice(InvoiceType type = In...

FILE: CoreTests/Integration/Items/Create.cs
  class Create (line 7) | [TestFixture]
    method create_simple_item (line 10) | [Test]
    method create_full_item (line 24) | [Test]

FILE: CoreTests/Integration/Items/Delete.cs
  class Delete (line 9) | [TestFixture]
    method you_can_delete_an_item (line 12) | [Test]
    method but_not_if_its_involved_in_a_transaction (line 22) | [Test]
    method and_it_will_404_if_you_try_to_delete_a_item_thats_not_there (line 32) | [Test]
    method When_I_try_to_Delete_it_404s (line 44) | private void When_I_try_to_Delete_it_404s()
    method When_I_try_to_Delete_it_400s (line 49) | private void When_I_try_to_Delete_it_400s()
    method Its_not_there_when_I_try_to_find_it (line 54) | private void Its_not_there_when_I_try_to_find_it(Item theItem)

FILE: CoreTests/Integration/Items/TrackedItems/Create.cs
  class Create (line 7) | public class Create : TrackedInventoryTest
    method Can_create_an_item_with_minimal_properties (line 11) | [Test]
    method Can_create_an_item_with_full_details (line 32) | [Test]

FILE: CoreTests/Integration/Items/TrackedItems/Find.cs
  class Find (line 5) | public class Find : TrackedInventoryTest
    method Can_get_tracked_item_by_id (line 7) | [Test]

FILE: CoreTests/Integration/Items/TrackedItems/TrackedInventoryTest.cs
  class TrackedInventoryTest (line 10) | public class TrackedInventoryTest : ApiWrapperTest
    method Given_a_tracked_item (line 19) | public void Given_a_tracked_item()
    method Given_an_untracked_item (line 65) | public void Given_an_untracked_item()
    method Given_a_direct_cost_account (line 105) | protected void Given_a_direct_cost_account()
    method Given_a_revenue_account (line 123) | protected void Given_a_revenue_account()
    method Given_an_inventory_account (line 141) | protected void Given_an_inventory_account()
    method Given_an_ACCPAY_invoice_using_the_item_with_code (line 159) | protected void Given_an_ACCPAY_invoice_using_the_item_with_code(string...
    method Given_a_zero_total_ACCPAY_invoice_using_the_item_with_code (line 185) | protected void Given_a_zero_total_ACCPAY_invoice_using_the_item_with_c...
    method Given_an_ACCREC_invoice_using_the_item_with_code (line 217) | protected void Given_an_ACCREC_invoice_using_the_item_with_code(string...
    method Given_a_zero_total_ACCREC_invoice_using_the_item_with_code (line 241) | protected void Given_a_zero_total_ACCREC_invoice_using_the_item_with_c...

FILE: CoreTests/Integration/Items/TrackedItems/Update.cs
  class Update (line 5) | public class Update : TrackedInventoryTest
    method Can_turn_untracked_item_to_tracked_item (line 7) | [Test]
    method Can_update_an_item_to_make_it_not_tracked_and_not_for_purchase (line 24) | [Test]
    method Can_update_an_item_to_make_it_not_tracked_and_not_for_sale (line 41) | [Test]
    method Can_update_an_item_to_make_it_not_tracked_but_still_for_sale_and_purchase (line 60) | [Test]

FILE: CoreTests/Integration/Items/TrackedItems/Using_tracked_items.cs
  class Using_tracked_items (line 6) | public class Using_tracked_items : TrackedInventoryTest
    method Purchase_some_inventory_with_an_ACCPAY_invoice (line 9) | [Test]
    method Sell_inventory_with_an_ACCREC_invoice (line 24) | [Test]
    method Creating_a_zero_total_ACCPAY_invoice_increases_a_tracked_items_quantity_as_an_adjustment (line 47) | [Test]
    method Creating_a_zero_total_ACCREC_invoice_decreases_a_tracked_items_quantity (line 61) | [Test]
    method Finding_a_tracked_item_gives_you_quantity_on_hand_and_total_cost_pool (line 82) | [Test]
    method Then_the_quantity_of_the_tracked_item_is_zero (line 98) | private void Then_the_quantity_of_the_tracked_item_is_zero(Item item)
    method Then_the_quantity_of_the_tracked_item_is_more_than_zero (line 103) | private void Then_the_quantity_of_the_tracked_item_is_more_than_zero(I...

FILE: CoreTests/Integration/Items/Update.cs
  class Update (line 10) | [TestFixture]
    method update_an_item (line 13) | [Test]

FILE: CoreTests/Integration/Journals/Find.cs
  class Find (line 6) | [TestFixture]
    method find_journals (line 9) | [Test]
    method find_journals_offset (line 17) | [Test]

FILE: CoreTests/Integration/LinkedTransactions/Create.cs
  class Create (line 6) | public class Create : LinkedTransactionTest
    method can_create_a_linked_transaction_with_just_source_details (line 8) | [Test]
    method can_create_a_linked_transaction_with_source_details_assigned_to_a_Contact (line 25) | [Test]
    method can_create_a_fully_allocated_linkedTransaction (line 43) | [Test]

FILE: CoreTests/Integration/LinkedTransactions/Delete.cs
  class Delete (line 6) | public class Delete : LinkedTransactionTest
    method can_delete_linked_transactions (line 8) | [Test]

FILE: CoreTests/Integration/LinkedTransactions/Find.cs
  class Find (line 6) | public class Find : LinkedTransactionTest
    method find_by_page (line 8) | [Test]
    method find_by_id (line 17) | [Test]
    method find_by_source_transaction_id (line 28) | [Test]
    method find_by_contact_id (line 40) | [Test]
    method find_by_target_transaction_id (line 52) | [Test]

FILE: CoreTests/Integration/LinkedTransactions/LinkedTransactionTest.cs
  class LinkedTransactionTest (line 11) | public abstract class LinkedTransactionTest : ApiWrapperTest
    method Given_a_basic_linked_transaction (line 27) | protected void Given_a_basic_linked_transaction()
    method Given_a_linked_transaction_assigned_to_a_contact (line 38) | protected void Given_a_linked_transaction_assigned_to_a_contact()
    method Given_a_fully_allocated_linked_transaction (line 51) | protected void Given_a_fully_allocated_linked_transaction()
    method Given_a_source_invoice (line 67) | protected void Given_a_source_invoice()
    method Given_a_target_invoice (line 72) | protected void Given_a_target_invoice(Contact contact = null)
    method Given_an_invoice (line 77) | private Invoice Given_an_invoice(InvoiceType type = InvoiceType.Accoun...
    method Given_a_contact (line 109) | protected void Given_a_contact()
    method Then_the_linked_transaction_has_an_id (line 124) | protected void Then_the_linked_transaction_has_an_id(LinkedTransaction...
    method Then_the_source_details_are_correct (line 129) | protected void Then_the_source_details_are_correct(LinkedTransaction l...
    method Then_the_target_details_are_correct (line 135) | protected void Then_the_target_details_are_correct(LinkedTransaction l...
    method Then_the_contact_details_are_correct (line 141) | protected void Then_the_contact_details_are_correct(LinkedTransaction ...

FILE: CoreTests/Integration/LinkedTransactions/Update.cs
  class Update (line 6) | public class Update : LinkedTransactionTest
    method can_assign_a_contact_to_an_existing_linked_transaction (line 8) | [Test]
    method can_allocate_an_existing_linked_transaction_to_a_target_transaction (line 21) | [Test]

FILE: CoreTests/Integration/ManualJournals/Create.cs
  class Create (line 9) | [TestFixture]
    method CreateSetUp (line 12) | [TestFixtureSetUp]
    method create_manual_journal (line 18) | [Test]
    method create_complex_manual_journal (line 33) | [Test]

FILE: CoreTests/Integration/ManualJournals/Find.cs
  class Find (line 7) | [TestFixture]
    method UpdateSet (line 10) | [TestFixtureSetUp]
    method find_by_id (line 16) | [Test]
    method find_by_value (line 28) | [Test]
    method find_by_page (line 42) | [Test]

FILE: CoreTests/Integration/ManualJournals/ManualJournalsTest.cs
  class ManualJournalsTest (line 8) | public class ManualJournalsTest : ApiWrapperTest
    method ManualJournalsSetUp (line 13) | protected void ManualJournalsSetUp()
    method Given_an_account (line 20) | private Account Given_an_account(AccountType type = AccountType.Sales)
    method Given_a_manual_journal (line 35) | protected ManualJournal Given_a_manual_journal(string narration, decim...

FILE: CoreTests/Integration/ManualJournals/Update.cs
  class Update (line 6) | [TestFixture]
    method UpdateSet (line 9) | [TestFixtureSetUp]
    method create_manual_journal (line 15) | [Test]

FILE: CoreTests/Integration/Organisation/Find.cs
  class Find (line 7) | [TestFixture]
    method can_get_the_organisation_sales_tax_basis (line 10) | [Test]
    method can_get_the_organisation_sales_tax_period (line 18) | [Test]

FILE: CoreTests/Integration/Overpayments/Find.cs
  class Find (line 7) | [TestFixture]
    method find_all (line 10) | [Test]
    method find_all_receive_overpayments (line 17) | [Test]
    method find_all_spend_overpayments (line 24) | [Test]

FILE: CoreTests/Integration/Payments/Create.cs
  class Create (line 9) | [TestFixture]
    method CreatePaymentsSetUp (line 12) | [TestFixtureSetUp]
    method create_simple_payment (line 18) | [Test]
    method create_multiple_payments (line 30) | [Test]
    method create_reconciled_payment (line 50) | [Test]
    method create_refund_on_credit_note (line 64) | [Test]
    method create_refund_on_Prepayment (line 85) | [Test]
    method create_refund_on_Overpayment (line 107) | [Test]

FILE: CoreTests/Integration/Payments/CreateForeignCurrency.cs
  class CreateForeignCurrency (line 9) | [TestFixture]
    method SetUpForeignCurrency (line 14) | [TestFixtureSetUp]
    method create_refund_on_credit_note_with_foreign_currency (line 21) | [Test]
    method Given_a_foreign_currency_account (line 47) | private Account Given_a_foreign_currency_account()
    method Create_foreign_currency_account (line 56) | private Account Create_foreign_currency_account()

FILE: CoreTests/Integration/Payments/Delete.cs
  class Delete (line 8) | [TestFixture]
    method CreatePaymentsSetUp (line 11) | [TestFixtureSetUp]
    method can_delete_payments (line 17) | [Test]

FILE: CoreTests/Integration/Payments/Find.cs
  class Find (line 7) | public class Find : PaymentsTest
    method PaymentsSetUp (line 9) | [TestFixtureSetUp]
    method find_single_payment (line 15) | [Test]
    method find_payments (line 26) | [Test]

FILE: CoreTests/Integration/Payments/PaymentsTest.cs
  class PaymentsTest (line 9) | public abstract class PaymentsTest : ApiWrapperTest
    method Given_a_payment (line 11) | protected Payment Given_a_payment(decimal invoiceAmount, DateTime date...
    method CreatePayment (line 16) | protected Payment CreatePayment(decimal invoiceAmount, DateTime date, ...
    method Given_an_invoice (line 37) | private Invoice Given_an_invoice(decimal amount = 100m, string account...
    method Given_an_credit_note (line 60) | protected CreditNote Given_an_credit_note(decimal amount = 100m, strin...
    method Given_a_prepayment (line 83) | protected BankTransaction Given_a_prepayment(string bankAccountCode, d...
    method Given_an_overpayment (line 106) | protected BankTransaction Given_an_overpayment(string bankAccountCode,...
    method Given_this_payment_is_deleted (line 130) | protected void Given_this_payment_is_deleted(Payment payment)

FILE: CoreTests/Integration/Pdf/Get.cs
  class Get (line 8) | [TestFixture]
    method can_get_invoice_as_pdf (line 11) | [Test]
    method can_get_credit_note_as_pdf (line 17) | [Test]
    method can_get_purchase_order_as_pdf (line 23) | [Test]
    method invoice_gives_404_when_not_found (line 29) | [Test]
    method credit_note_gives_404_when_not_found (line 35) | [Test]
    method purchase_order_gives_404_when_not_found (line 41) | [Test]
    method AssertOk (line 47) | private void AssertOk(PdfEndpointType type, Guid id)

FILE: CoreTests/Integration/Prepayments/Find.cs
  class Find (line 7) | [TestFixture]
    method find_all (line 10) | [Test]
    method find_all_receive_prepayments (line 17) | [Test]
    method find_all_spend_prepayments (line 24) | [Test]

FILE: CoreTests/Integration/PurchaseOrders/Create.cs
  class Create (line 10) | public class Create : ApiWrapperTest
    method Create_minimal_draft_purchase_order (line 12) | [Test]
    method Create_authorised_purchase_order (line 28) | [Test]
    method Given_a_purchase_order (line 62) | public PurchaseOrder Given_a_purchase_order()

FILE: CoreTests/Integration/PurchaseOrders/Find.cs
  class Find (line 11) | public class Find : ApiWrapperTest
    method Find_a_purchase_order_by_Id (line 14) | [Test]
    method Find_purchase_orders (line 24) | [Test]
    method Find_page_X_of_purchase_orders (line 34) | [Test]
    method Filter_purchase_orders_by_status (line 44) | [Test]
    method Filter_purchase_orders_by_ModifiedSince (line 54) | [Test]
    method Filter_purchase_orders_by_DateFrom (line 73) | [Test]
    method Filter_purchase_orders_by_DateTo (line 88) | [Test]
    method Filter_purchase_orders_by_a_DateFrom_DateTo_date_range (line 103) | [Test]
    method Use_multiple_filters_to_find_Purchase_orders (line 127) | [Test]
    method Given_a_minimum_PurchaseOrder (line 140) | private PurchaseOrder Given_a_minimum_PurchaseOrder(DateTime? date = n...
    method Given_an_authorised_PurchaseOrder (line 150) | private PurchaseOrder Given_an_authorised_PurchaseOrder()

FILE: CoreTests/Integration/PurchaseOrders/Update.cs
  class Update (line 11) | public class Update : ApiWrapperTest
    method Can_update_a_PurchaseOrder_like_this (line 13) | [Test]
    method Given_a_PurchaseOrder (line 31) | public PurchaseOrder Given_a_PurchaseOrder()

FILE: CoreTests/Integration/Receipts/Create.cs
  class Create (line 6) | [TestFixture]
    method create_receipt (line 9) | [Test]

FILE: CoreTests/Integration/Receipts/ReceiptTest.cs
  class ReceiptTest (line 8) | public abstract class ReceiptTest : ApiWrapperTest
    method Given_a_receipt (line 10) | public Receipt Given_a_receipt(Guid userId, string contactName, string...

FILE: CoreTests/Integration/Receipts/Update.cs
  class Update (line 7) | [TestFixture]
    method delete_receipt (line 10) | [Test]

FILE: CoreTests/Integration/Reports/Find.cs
  class Find (line 9) | [TestFixture]
    method find_all (line 13) | [Test]
    method find_gst_report (line 20) | [Test]
    method find_PL_report (line 27) | [Test]
    method find_BudgetSummary_report (line 34) | [Test]

FILE: CoreTests/Integration/Setup/Create.cs
  class Create (line 9) | [TestFixture(Ignore = true, Description = "These test will remove all ac...
    method create_a_valid_setup (line 12) | [Test]
    method missing_account_code_will_error (line 31) | [Test]
    method providing_nothing_is_not_an_error (line 47) | [Test]

FILE: CoreTests/Integration/TaxRates/Create.cs
  class Create (line 8) | [TestFixture]
    method create_tax_rate (line 11) | [Test]
    method AssertContainsRate (line 31) | private void AssertContainsRate(TaxRate taxRate, string name, decimal ...

FILE: CoreTests/Integration/TaxRates/TaxRateTest.cs
  class TaxRateTest (line 8) | public abstract class TaxRateTest : ApiWrapperTest
    method Given_a_tax_rate (line 10) | protected TaxRate Given_a_tax_rate(string name, ReportTaxType taxType,...

FILE: CoreTests/Integration/TaxRates/Update.cs
  class Update (line 8) | [TestFixture]
    method update_tax_rate (line 11) | [Test]
    method delete_tax_rate (line 34) | [Test]

FILE: CoreTests/Integration/TrackingCategories/AddTrackingOption.cs
  class AddTrackingOption (line 11) | [TestFixture]
    method Can_add_tracking_option (line 14) | [Test]
    method Can_add_tracking_options (line 24) | [Test]

FILE: CoreTests/Integration/TrackingCategories/Adding/CreateTrackingCategories.cs
  class CreateTrackingCategories (line 8) | [TestFixture]
    method Can_create_a_Tracking_Category (line 11) | [Test]

FILE: CoreTests/Integration/TrackingCategories/ArchiveTrackingCategory.cs
  class ArchiveTrackingCategory (line 11) | [TestFixture]
    method Can_archieve_tracking_category (line 14) | [Test]

FILE: CoreTests/Integration/TrackingCategories/CreateTrackingCategories.cs
  class CreateTrackingCategories (line 8) | [TestFixture]
    method Can_create_a_Tracking_Category (line 11) | [Test]

FILE: CoreTests/Integration/TrackingCategories/Delete.cs
  class Delete (line 8) | [TestFixture]
    method can_delete_a_Tracking_Category (line 11) | [Test]
    method can_delete_a_Tracking_Category_Option (line 19) | [Test]

FILE: CoreTests/Integration/TrackingCategories/GetTrackingCategories.cs
  class GetTrackingCategories (line 10) | [TestFixture]
    method Can_get_Tracking_Category (line 13) | [Test]

FILE: CoreTests/Integration/TrackingCategories/GetTrackingCategoriesIncludingArchieved.cs
  class GetTrackingCategoriesIncludingArchieved (line 11) | [TestFixture]
    method Can_get_Tracking_Category_including_archieved (line 14) | [Test]

FILE: CoreTests/Integration/TrackingCategories/Options/AddTrackingOption.cs
  class AddTrackingOption (line 9) | [TestFixture]
    method Can_add_Tracking_options (line 12) | [Test]

FILE: CoreTests/Integration/TrackingCategories/TrackingCategoriesTest.cs
  class TrackingCategoriesTest (line 14) | public class TrackingCategoriesTest : ApiWrapperTest
    method Given_a_TrackingCategory_with_Options (line 22) | public void Given_a_TrackingCategory_with_Options()
    method Given_a_TrackingCategory_with_Option (line 35) | public void Given_a_TrackingCategory_with_Option()
    method Given_a_TrackingCategory (line 46) | public void Given_a_TrackingCategory()
    method Given_two_TrackingCategorys (line 59) | public void Given_two_TrackingCategorys()
    method Given_a_tracking_option (line 74) | public Option Given_a_tracking_option()
    method Given_a_tracking_options (line 84) | public List<Option> Given_a_tracking_options()
    method Given_name_change_to_categorie (line 94) | public void Given_name_change_to_categorie()
    method Given_approved_invoice_with_tracking_option (line 103) | public void Given_approved_invoice_with_tracking_option(InvoiceType ty...
    method Given_Invoice_is_voided (line 142) | public Invoice Given_Invoice_is_voided()
    method Given_Tracking_Category_is_deleted (line 148) | public void Given_Tracking_Category_is_deleted()
    method Given_both_Tracking_Category_is_deleted (line 155) | public void Given_both_Tracking_Category_is_deleted()
    method Given_Tracking_CategoryOption_is_deleted (line 164) | public void Given_Tracking_CategoryOption_is_deleted()
    method Given_first_Option_is_Archived (line 171) | public void Given_first_Option_is_Archived()
    method Given_Tracking_Category_is_Archived (line 180) | public void Given_Tracking_Category_is_Archived()
    method Given_first_Option_Name_change (line 189) | public void Given_first_Option_Name_change()
    method Then_Category_Has_Option (line 200) | public void Then_Category_Has_Option()
    method Then_Category_Has_Options (line 210) | public void Then_Category_Has_Options()
    method Given_GetAll (line 221) | public void Given_GetAll()
    method Given_GetAll_with_Archived (line 226) | public void Given_GetAll_with_Archived()
    method Then_Archieved_Tracking_Category_is_in_list (line 233) | public void Then_Archieved_Tracking_Category_is_in_list()
    method List_contains_the_two_Tracking_Category (line 240) | public void List_contains_the_two_Tracking_Category()

FILE: CoreTests/Integration/TrackingCategories/UpdateTrackingCategory.cs
  class UpdateTrackingCategory (line 11) | [TestFixture]
    method Can_update_tracking_category_name (line 14) | [Test]
    method Can_update_tracking_category_with_Options_name (line 24) | [Test]

FILE: CoreTests/Integration/TrackingCategories/UpdateTrackingOptions.cs
  class UpdateTrackingOption (line 11) | [TestFixture]
    method Can_update_tracking_options_name (line 14) | [Test]
    method Can_update_tracking_options_status (line 24) | [Test]

FILE: CoreTests/Random.cs
  class Random (line 6) | public static class Random
    method GetRandomString (line 8) | public static string GetRandomString(int length)
    method SanitiseBase64String (line 15) | private static string SanitiseBase64String(string input, int maxLength)

FILE: CoreTests/Unit/Contacts.cs
  class Contacts (line 5) | [TestFixture]
    method include_archived (line 8) | [Test]
    method exclude_archived_explict (line 19) | [Test]
    method exclude_archived_implict (line 30) | [Test]

FILE: CoreTests/Unit/ExceptionTests.cs
  class ExceptionTests (line 8) | [TestFixture]
    method ManageNullValidationErrorsInApiException (line 11) | [Test]

FILE: CoreTests/Unit/FourDecimalPlaces.cs
  class FourDecimalPlaces (line 12) | [TestFixture]
    method explict_four_decimal_places_invoices (line 15) | [Test]
    method implict_four_decimal_places_invoice (line 21) | [Test]
    method no_four_decimal_places_invoice (line 27) | [Test]
    method no_four_decimal_places_bank_transactions (line 33) | [Test]
    method explict_four_decimal_places_bank_transactions (line 39) | [Test]
    method implict_four_decimal_places_bank_transactions (line 45) | [Test]
    method no_four_decimal_places_credit_notes (line 51) | [Test]
    method explict_four_decimal_places_credit_notes (line 57) | [Test]
    method implict_four_decimal_places_credit_notes (line 63) | [Test]
    method no_four_decimal_places_reciepts (line 69) | [Test]
    method explict_four_decimal_places_reciepts (line 75) | [Test]
    method implict_four_decimal_places_reciepts (line 81) | [Test]
    method no_four_decimal_places_payments (line 87) | [Test]
    method explict_four_decimal_places_payments (line 93) | [Test]
    method implict_four_decimal_places_payments (line 99) | [Test]
    method no_four_decimal_places_items (line 105) | [Test]
    method explict_four_decimal_places_items (line 111) | [Test]
    method implict_four_decimal_places_items (line 117) | [Test]
    method no_four_decimal_places_repeat_invoice (line 123) | [Test]
    method explict_four_decimal_repeat_invoice (line 129) | [Test]
    method implict_four_decimal_repeat_invoice (line 135) | [Test]
    method ExplictUse4Dp (line 141) | private void ExplictUse4Dp<T, TResult, TRequest, TResponse>(FourDecima...
    method ImplicitUse4Dp (line 149) | private void ImplicitUse4Dp<T, TResult, TRequest, TResponse>(FourDecim...
    method ExplicitNotUse4Dp (line 157) | private void ExplicitNotUse4Dp<T, TResult, TRequest, TResponse>(FourDe...

FILE: CoreTests/Unit/QueryStrings.cs
  class QueryStrings (line 6) | [TestFixture]
    method Setup (line 9) | [SetUp]
    method query_string_is_as_expected (line 15) | [Test]
    method complex_query_string_is_as_expected (line 29) | [Test]

FILE: CoreTests/Unit/RateLimiterTest.cs
  class RateLimiterTest (line 11) | [TestFixture]
    method TestRateLimiter (line 14) | [Test]

FILE: CoreTests/Unit/SalesTaxBasisTypeTest.cs
  class SalesTaxBasisTypeTest (line 8) | [TestFixture]
    method SetUp (line 13) | [TestFixtureSetUp]
    method is_case_insensitive (line 19) | [Test]
    method accrual_options (line 29) | [Test]
    method cash_options (line 38) | [Test]
    method flat_rate_accrual_options (line 44) | [Test]
    method flat_rate_cash_options (line 50) | [Test]
    method invoice_options (line 56) | [Test]
    method none_options (line 62) | [Test]
    method payments_options (line 68) | [Test]
    method Test (line 74) | private void Test(SalesTaxBasisType type, string value)

FILE: CoreTests/Unit/SalesTaxPeriodTypeTest.cs
  class SalesTaxPeriodTypeTest (line 8) | [TestFixture]
    method SetUp (line 13) | [TestFixtureSetUp]
    method is_case_insensitive (line 19) | [Test]
    method monthly_options (line 29) | [Test]
    method two_monthly_options (line 39) | [Test]
    method annual_options (line 48) | [Test]
    method semi_annual_options (line 57) | [Test]
    method quarterly_options (line 66) | [Test]

FILE: CoreTests/Unit/SummarizeErrors.cs
  class SummarizeErrors (line 5) | public class SummarizeErrors : ApiWrapperTest
    method Setup (line 7) | [SetUp]
    method summarize_errors_on_by_default (line 13) | [Test]
    method summarize_errors_off (line 24) | [Test]
    method all_summarize_errors_off (line 35) | [Test]
    method all_summarize_errors_on (line 47) | [Test]

FILE: CoreTests/Unit/TrackingCategories.cs
  class TrackingCategories (line 5) | [TestFixture]
    method TestSetUp (line 8) | [SetUp]
    method include_archived (line 14) | [Test]
    method exclude_archived_explict (line 25) | [Test]
    method exclude_archived_implict (line 34) | [Test]

FILE: CoreTests/Unit/UrlEncoder.cs
  class UrlEncoder (line 5) | [TestFixture]
    method when_paranenthese_are_in_query_it_signs_correctly (line 8) | [Test]

FILE: PayrollTests.AU/ApiWrapperTest.cs
  class ApiWrapperTest (line 5) | public class ApiWrapperTest
    method CreateApi (line 14) | private static AustralianPayroll CreateApi()

FILE: PayrollTests.AU/Integration/Employees/Create.cs
  class Create (line 8) | [TestFixture]
    method create_employee (line 11) | [Test]
    method create_employee_with_taxdeclarations (line 53) | [Test]
    method create_employee_with_opening_balances (line 76) | [Test]

FILE: PayrollTests.AU/Integration/Employees/EmployeesTest.cs
  class EmployeesTest (line 8) | public abstract class EmployeesTest : ApiWrapperTest
    method Given_an_employee (line 10) | protected Employee Given_an_employee(bool terminated = false)
    method given_terminated_employee (line 22) | protected Employee given_terminated_employee()
    method earnings_rate_id (line 27) | protected Guid earnings_rate_id()
    method deduction_type_id (line 33) | protected Guid deduction_type_id()
    method reimbersment_type_id (line 38) | protected Guid reimbersment_type_id()
    method leave_type_id (line 44) | protected Guid leave_type_id()
    method super_fund_id (line 50) | protected Guid super_fund_id()

FILE: PayrollTests.AU/Integration/Employees/Find.cs
  class Find (line 6) | [TestFixture]
    method find_all_employees (line 9) | [Test]
    method find_by_id (line 16) | [Test]
    method find_by_status (line 25) | [Test]
    method find_all_employees_paged (line 37) | [Test]

FILE: PayrollTests.AU/Integration/Employees/Update.cs
  class Update (line 11) | [TestFixture]
    method update_employee_with_super_memberhsip (line 14) | [Test]

FILE: PayrollTests.AU/Integration/LeaveApplications/Create.cs
  class Create (line 10) | [TestFixture]
    method create_leave_application (line 13) | [Test]

FILE: PayrollTests.AU/Integration/LeaveApplications/Find.cs
  class Find (line 9) | [TestFixture]
    method find_all (line 12) | [Test]
    method find_by_id (line 21) | [Test]
    method find_by_date (line 30) | [Test]
    method find_paged (line 41) | [Test]

FILE: PayrollTests.AU/Integration/LeaveApplications/LeaveApplicationTest.cs
  class LeaveApplicationTest (line 7) | public abstract class LeaveApplicationTest :ApiWrapperTest
    method Given_a_leave_application (line 10) | public LeaveApplication Given_a_leave_application()
    method Given_an_employee (line 26) | public Employee Given_an_employee()
    method the_leavetype_id (line 41) | public Guid the_leavetype_id()
    method employee_payroll_calendar_id (line 48) | public Guid employee_payroll_calendar_id()
    method earning_rates_id (line 68) | public Guid earning_rates_id()

FILE: PayrollTests.AU/Integration/PayItems/Create.cs
  class Create (line 6) | [TestFixture]
    method create_payitem (line 9) | [Test]

FILE: PayrollTests.AU/Integration/PayItems/Find.cs
  class Find (line 5) | [TestFixture]
    method find_all (line 8) | [Test]
    method find_paged (line 15) | [Test]
    method Find_EarningRates (line 22) | [Test]

FILE: PayrollTests.AU/Integration/PayItems/PayItemsTest.cs
  class PayItemsTest (line 7) | public class PayItemsTest : ApiWrapperTest
    method Given_some_payitems (line 9) | public Xero.Api.Payroll.Australia.Model.PayItems Given_some_payitems()

FILE: PayrollTests.AU/Integration/PayrollCalendars/Create.cs
  class Create (line 8) | [TestFixture]
    method create_payroll_calendar (line 11) | [Test]

FILE: PayrollTests.AU/Integration/PayrollCalendars/Find.cs
  class Find (line 7) | [TestFixture]
    method find_all (line 10) | [Test]
    method find_paged (line 18) | [Test]

FILE: PayrollTests.AU/Integration/Payrun/Create.cs
  class Create (line 9) | [TestFixture]
    method create_scheduled_payrun (line 12) | [Test]
    method create_unscheduled_payrun (line 24) | [Test]
    method post_payrun (line 37) | [Test]

FILE: PayrollTests.AU/Integration/Payrun/Find.cs
  class Find (line 7) | [TestFixture]
    method find_all (line 10) | [Test]
    method find_by_id (line 19) | [Test]
    method find_paged (line 27) | [Test]

FILE: PayrollTests.AU/Integration/Payrun/PayrunTest.cs
  class PayrunTest (line 8) | public abstract class PayrunTest : ApiWrapperTest
    method Given_a_payrun (line 11) | public PayRun Given_a_payrun()
    method the_payroll_calendar_id (line 23) | public Guid the_payroll_calendar_id()

FILE: PayrollTests.AU/Integration/Settings/Find.cs
  class Find (line 7) | [TestFixture]
    method find_all (line 10) | [Test]

FILE: PayrollTests.AU/Integration/SuperFundProducts/Find.cs
  class Find (line 9) | [TestFixture]
    method find_all (line 12) | [Test]
    method find_by_page (line 19) | [Test]

FILE: PayrollTests.AU/Integration/SuperFunds/Create.cs
  class Create (line 11) | [TestFixture]
    method create_superfund (line 14) | [Test]

FILE: PayrollTests.AU/Integration/SuperFunds/Update.cs
  class Update (line 8) | [TestFixture]
    method update_superfund (line 11) | [Test]

FILE: PayrollTests.AU/Integration/TimeSheets/Create.cs
  class Create (line 10) | [TestFixture]
    method CreateSetUp (line 13) | [TestFixtureSetUp]
    method create_timesheet (line 19) | [Test]
    method timesheet_with_lines (line 31) | [Test]

FILE: PayrollTests.AU/Integration/TimeSheets/Find.cs
  class Find (line 9) | [TestFixture]public class Find : TimesheetTest
    method find_all (line 11) | [Test]
    method find_by_id (line 20) | [Test]
    method find_by_page (line 28) | [Test]

FILE: PayrollTests.AU/Integration/TimeSheets/TimesheetTest.cs
  class TimesheetTest (line 11) | public abstract class TimesheetTest : ApiWrapperTest
    method Given_a_timesheet (line 14) | public Timesheet Given_a_timesheet()
    method the_employee_id (line 28) | public Guid the_employee_id()
    method employee_payroll_calendar_id (line 42) | public Guid employee_payroll_calendar_id()
    method earning_rates_id (line 69) | public Guid earning_rates_id()
    method timesheet_start_date (line 77) | public DateTime timesheet_start_date()

FILE: PayrollTests.AU/Integration/ValidationErrors/AUPayrollValidationErrors.cs
  class AUPayrollValidationErrors (line 8) | public class AUPayrollValidationErrors : ApiWrapperTest
    method Validation_errors_are_returned_from_the_AU_payroll_api (line 10) | [Test]

FILE: PayrollTests.US/ApiWrapperTest.cs
  class ApiWrapperTest (line 5) | public class ApiWrapperTest
    method CreateApi (line 14) | private static AmericanPayroll CreateApi()

FILE: PayrollTests.US/Integration/Employees/Create.cs
  class Create (line 8) | [TestFixture]
    method create_employee (line 11) | [Test]
    method create_employee_with_opening_balances (line 36) | [Test]

FILE: PayrollTests.US/Integration/Employees/EmployeesTest.cs
  class EmployeesTest (line 6) | public abstract class EmployeesTest : ApiWrapperTest
    method Given_an_employee (line 8) | protected Employee Given_an_employee()

FILE: PayrollTests.US/Integration/Employees/Find.cs
  class Find (line 6) | [TestFixture]
    method find_all_employees (line 9) | [Test]
    method find_by_page (line 16) | [Test]
    method find_by_id (line 23) | [Test]

FILE: PayrollTests.US/Integration/Employees/Update.cs
  class Update (line 7) | [TestFixture]
    method update_employee_with_super_memberhsip (line 10) | [Test]

FILE: PayrollTests.US/Integration/PaySchedules/Create.cs
  class Create (line 8) | [TestFixture]
    method create_payschedule (line 11) | [Test]

FILE: PayrollTests.US/Integration/PaySchedules/Find.cs
  class Find (line 7) | [TestFixture]
    method find_all (line 10) | [Test]
    method find_by_page (line 18) | [Test]
    method find_by_id (line 26) | [Test]

FILE: PayrollTests.US/Integration/PaySchedules/PaySchedulesTest.cs
  class PaySchedulesTest (line 7) | public abstract class PaySchedulesTest : ApiWrapperTest
    method Given_a_payschedule (line 9) | public PaySchedule Given_a_payschedule()

FILE: Xero.Api.Example.Applications/Partner/AmericanPayroll.cs
  class AmericanPayroll (line 8) | public class AmericanPayroll : Payroll.AmericanPayroll
    method AmericanPayroll (line 13) | public AmericanPayroll(ITokenStore store, IUser user, bool includeRate...

FILE: Xero.Api.Example.Applications/Partner/AustralianPayroll.cs
  class AustralianPayroll (line 8) | public class AustralianPayroll : Payroll.AustralianPayroll
    method AustralianPayroll (line 13) | public AustralianPayroll(ITokenStore store, IUser user, bool includeRa...

FILE: Xero.Api.Example.Applications/Partner/Core.cs
  class Core (line 9) | public class Core : XeroCoreApi
    method Core (line 14) | public Core(ITokenStore store, IUser user, bool includeRateLimiter = f...

FILE: Xero.Api.Example.Applications/Partner/PartnerAuthenticator.cs
  class PartnerAuthenticator (line 9) | public class PartnerAuthenticator : TokenStoreAuthenticator
    method PartnerAuthenticator (line 14) | private PartnerAuthenticator(string baseUri, string authorizeUri, stri...
    method PartnerAuthenticator (line 20) | public PartnerAuthenticator(string baseUri, string authorizeUri, strin...
    method PartnerAuthenticator (line 25) | public PartnerAuthenticator(string baseUri, string authorizeUri, strin...
    method PartnerAuthenticator (line 31) | public PartnerAuthenticator(string baseUri, string authorizeUri, strin...
    method AuthorizeUser (line 37) | protected override string AuthorizeUser(IToken token)
    method CreateSignature (line 48) | protected override string CreateSignature(IToken token, string verb, U...
    method RenewToken (line 54) | protected override IToken RenewToken(IToken sessionToken, IConsumer co...

FILE: Xero.Api.Example.Applications/Partner/PartnerMvcAuthenticator.cs
  class PartnerMvcAuthenticator (line 9) | public class PartnerMvcAuthenticator : PublicMvcAuthenticator
    method PartnerMvcAuthenticator (line 13) | private PartnerMvcAuthenticator(string baseUri, string authorizeUri, s...
    method PartnerMvcAuthenticator (line 19) | public PartnerMvcAuthenticator(string baseUri, string authorizeUri, st...
    method PartnerMvcAuthenticator (line 25) | public PartnerMvcAuthenticator(string baseUri, string authorizeUri, st...
    method PartnerMvcAuthenticator (line 33) | public PartnerMvcAuthenticator(string baseUri, string authorizeUri, st...
    method CreateSignature (line 41) | protected override string CreateSignature(IToken token, string verb, U...
    method RenewToken (line 47) | protected override IToken RenewToken(IToken sessionToken, IConsumer co...

FILE: Xero.Api.Example.Applications/Partner/Settings.cs
  class Settings (line 5) | public class Settings

FILE: Xero.Api.Example.Applications/Private/AmericanPayroll.cs
  class AmericanPayroll (line 7) | public class AmericanPayroll : Payroll.AmericanPayroll
    method AmericanPayroll (line 12) | public AmericanPayroll(bool includeRateLimiter = false) :

FILE: Xero.Api.Example.Applications/Private/AustralianPayroll.cs
  class AustralianPayroll (line 7) | public class AustralianPayroll : Payroll.AustralianPayroll
    method AustralianPayroll (line 12) | public AustralianPayroll(bool includeRateLimiter = false) :

FILE: Xero.Api.Example.Applications/Private/Core.cs
  class Core (line 8) | public class Core : XeroCoreApi
    method Core (line 13) | public Core(bool includeRateLimiter = false) :

FILE: Xero.Api.Example.Applications/Private/PrivateAuthenticator.cs
  class PrivateAuthenticator (line 9) | public class PrivateAuthenticator : IAuthenticator
    method PrivateAuthenticator (line 13) | public PrivateAuthenticator(string certificatePath)
    method PrivateAuthenticator (line 19) | public PrivateAuthenticator(string certificatePath, string certificate...
    method PrivateAuthenticator (line 25) | public PrivateAuthenticator(X509Certificate2 certificate)
    method GetSignature (line 30) | public string GetSignature(IConsumer consumer, IUser user, Uri uri, st...
    method GetToken (line 44) | public IToken GetToken(IConsumer consumer, IUser user)

FILE: Xero.Api.Example.Applications/Private/Settings.cs
  class Settings (line 5) | public class Settings

FILE: Xero.Api.Example.Applications/Public/AmericanPayroll.cs
  class AmericanPayroll (line 8) | public class AmericanPayroll : Payroll.AmericanPayroll
    method AmericanPayroll (line 13) | public AmericanPayroll(ITokenStore store, IUser user, bool includeRate...

FILE: Xero.Api.Example.Applications/Public/AustralianPayroll.cs
  class AustralianPayroll (line 8) | public class AustralianPayroll : Payroll.AustralianPayroll
    method AustralianPayroll (line 13) | public AustralianPayroll(ITokenStore store, IUser user, bool includeRa...

FILE: Xero.Api.Example.Applications/Public/Core.cs
  class Core (line 9) | public class Core : XeroCoreApi
    method Core (line 14) | public Core(ITokenStore store, IUser user, bool includeRateLimiter = f...

FILE: Xero.Api.Example.Applications/Public/IMvcAuthenticator.cs
  type IMvcAuthenticator (line 5) | public interface IMvcAuthenticator
    method GetRequestTokenAuthorizeUrl (line 7) | string GetRequestTokenAuthorizeUrl(string userId);
    method RetrieveAndStoreAccessToken (line 8) | IToken RetrieveAndStoreAccessToken(string userId, string tokenKey, str...

FILE: Xero.Api.Example.Applications/Public/PublicAuthenticator.cs
  class PublicAuthenticator (line 8) | public class PublicAuthenticator : TokenStoreAuthenticator
    method PublicAuthenticator (line 13) | public PublicAuthenticator(string baseUri, string tokenUri, string cal...
    method AuthorizeUser (line 20) | protected override string AuthorizeUser(IToken token)
    method CreateSignature (line 31) | protected override string CreateSignature(IToken token, string verb, U...
    method RenewToken (line 37) | protected override IToken RenewToken(IToken sessionToken, IConsumer co...

FILE: Xero.Api.Example.Applications/Public/PublicMvcAuthenticator.cs
  class PublicMvcAuthenticator (line 7) | public class PublicMvcAuthenticator : TokenStoreAuthenticator, IMvcAuthe...
    method PublicMvcAuthenticator (line 12) | public PublicMvcAuthenticator(string baseUri, string tokenUri, string ...
    method AuthorizeUser (line 20) | protected override string AuthorizeUser(IToken token)
    method CreateSignature (line 25) | protected override string CreateSignature(IToken token, string verb, U...
    method RenewToken (line 31) | protected override IToken RenewToken(IToken sessionToken, IConsumer co...
    method GetRequestTokenAuthorizeUrl (line 36) | public string GetRequestTokenAuthorizeUrl(string userId)
    method RetrieveAndStoreAccessToken (line 50) | public IToken RetrieveAndStoreAccessToken(string userId, string tokenK...

FILE: Xero.Api.Example.Applications/Public/RenewTokenException.cs
  class RenewTokenException (line 5) | public class RenewTokenException : Exception

FILE: Xero.Api.Example.Applications/Public/Settings.cs
  class Settings (line 5) | public class Settings

FILE: Xero.Api.Example.Applications/TokenStoreAuthenticator.cs
  class TokenStoreAuthenticator (line 7) | public abstract class TokenStoreAuthenticator : IAuthenticator
    method TokenStoreAuthenticator (line 29) | protected TokenStoreAuthenticator(string baseUri, string tokenUri, str...
    method GetSignature (line 37) | public string GetSignature(IConsumer consumer, IUser user, Uri uri, st...
    method GetToken (line 42) | public IToken GetToken(IConsumer consumer, IUser user)
    method AuthorizeUser (line 78) | protected abstract string AuthorizeUser(IToken oauthToken);
    method CreateSignature (line 79) | protected abstract string CreateSignature(IToken token, string verb, U...
    method RenewToken (line 82) | protected abstract IToken RenewToken(IToken sessionToken, IConsumer co...
    method GetToken (line 84) | protected virtual IToken GetToken(IConsumer consumer)
    method GetAuthorizeUrl (line 94) | protected string GetAuthorizeUrl(IToken token, string scope = null, bo...
    method GetRequestToken (line 109) | protected IToken GetRequestToken(IConsumer consumer)
    method GetAuthorization (line 122) | protected string GetAuthorization(IToken token, string verb, string en...

FILE: Xero.Api.Example.Counts/Lister.cs
  class Lister (line 8) | internal class Lister
    method Lister (line 12) | public Lister(IXeroCoreApi api)
    method List (line 17) | public void List()
    method GetTotalContactCount (line 49) | private int GetTotalContactCount()
    method GetTotalInvoiceCount (line 64) | private int GetTotalInvoiceCount()
    method ListReports (line 79) | private void ListReports(IEnumerable<string> reports, string name)

FILE: Xero.Api.Example.Counts/Program.cs
  class Program (line 8) | class Program
    method Main (line 10) | static void Main(string[] args)

FILE: Xero.Api.Example.Creation/ApiDataCreation.cs
  class ApiDataCreation (line 11) | internal class ApiDataCreation
    method ApiDataCreation (line 15) | public ApiDataCreation(XeroCoreApi api)
    method Create (line 20) | public void Create(int invoiceCount, int maxLineItems, IEnumerable<Nam...
    method GetTotalContactCount (line 36) | private int GetTotalContactCount()
    method GetTotalInvoiceCount (line 51) | private int GetTotalInvoiceCount()
    method PopulateInvoices (line 66) | private void PopulateInvoices(IEnumerable<Invoice> invoices)
    method PopulateContacts (line 83) | private void PopulateContacts(IEnumerable<Contact> contacts)
    method CreateInvoices (line 99) | private IEnumerable<Invoice> CreateInvoices(int invoiceCount, int maxL...
    method CreateLineItems (line 127) | private static IEnumerable<LineItem> CreateLineItems(int max, IEnumera...
    method CreateContacts (line 150) | private static IEnumerable<Contact> CreateContacts(IEnumerable<Name> n...
    method Heads (line 172) | public bool Heads(Random rnd)

FILE: Xero.Api.Example.Creation/Creator/Creator.cs
  class Creator (line 11) | public class Creator
    method People (line 13) | public IEnumerable<Name> People(int count)
    method Addresses (line 42) | public IEnumerable<Address> Addresses(int count)
    method Descriptions (line 82) | public IEnumerable<string> Descriptions(int count)

FILE: Xero.Api.Example.Creation/Creator/Name.cs
  class Name (line 3) | public class Name

FILE: Xero.Api.Example.Creation/Creator/PlaceName.cs
  class PlaceName (line 3) | public class PlaceName

FILE: Xero.Api.Example.Creation/Program.cs
  class Program (line 7) | class Program
    method Main (line 9) | static void Main(string[] args)

FILE: Xero.Api.Example.MVC/App_Start/FilterConfig.cs
  class FilterConfig (line 5) | public class FilterConfig
    method RegisterGlobalFilters (line 7) | public static void RegisterGlobalFilters(GlobalFilterCollection filters)

FILE: Xero.Api.Example.MVC/App_Start/RouteConfig.cs
  class RouteConfig (line 6) | public class RouteConfig
    method RegisterRoutes (line 8) | public static void RegisterRoutes(RouteCollection routes)

FILE: Xero.Api.Example.MVC/App_Start/WebApiConfig.cs
  class WebApiConfig (line 5) | public static class WebApiConfig
    method Register (line 7) | public static void Register(HttpConfiguration config)

FILE: Xero.Api.Example.MVC/Controllers/HomeController.cs
  class HomeController (line 8) | public class HomeController : Controller
    method HomeController (line 13) | public HomeController()
    method Index (line 20) | public ActionResult Index()
    method Connect (line 25) | public ActionResult Connect()
    method Authorize (line 32) | public ActionResult Authorize(string oauth_token, string oauth_verifie...

FILE: Xero.Api.Example.MVC/Controllers/OrganisationController.cs
  class OrganisationController (line 7) | public class OrganisationController : Controller
    method Index (line 9) | public ActionResult Index()

FILE: Xero.Api.Example.MVC/Global.asax.cs
  class MvcApplication (line 10) | public class MvcApplication : System.Web.HttpApplication
    method Application_Start (line 12) | protected void Application_Start()

FILE: Xero.Api.Example.MVC/Helpers/XeroApiHelper.cs
  class ApplicationSettings (line 12) | public class ApplicationSettings
  class XeroApiHelper (line 19) | public static class XeroApiHelper
    method XeroApiHelper (line 23) | static XeroApiHelper()
    method User (line 73) | public static ApiUser User()
    method Consumer (line 78) | public static IConsumer Consumer()
    method MvcAuthenticator (line 83) | public static IMvcAuthenticator MvcAuthenticator()
    method CoreApi (line 88) | public static IXeroCoreApi CoreApi()

FILE: Xero.Api.Example.MVC/Stores/MemoryAccessTokenStore.cs
  class MemoryAccessTokenStore (line 7) | public class MemoryAccessTokenStore : ITokenStore
    method Find (line 11) | public IToken Find(string userId)
    method Add (line 22) | public void Add(IToken token)
    method Delete (line 27) | public void Delete(IToken token)

FILE: Xero.Api.Example.MVC/Stores/MemoryRequestTokenStore.cs
  class MemoryRequestTokenStore (line 7) | public class MemoryRequestTokenStore : ITokenStore
    method Find (line 11) | public IToken Find(string userId)
    method Add (line 22) | public void Add(IToken token)
    method Delete (line 27) | public void Delete(IToken token)

FILE: Xero.Api.Example.Mocks/ContactManagerAndTests/ContactManager.cs
  class ContactManager (line 7) | public class ContactManager
    method ContactManager (line 13) | public ContactManager(IEnumerable<Contact> contacts)
    method ContactsFromTatooine (line 18) | public IEnumerable<Contact> ContactsFromTatooine()
    method ContactsFromDagobah (line 23) | public IEnumerable<Contact> ContactsFromDagobah()
    method ContactsFrom (line 28) | private IEnumerable<Contact> ContactsFrom(string country)

FILE: Xero.Api.Example.Mocks/ContactManagerAndTests/ContactManagerTests.cs
  class ContactManagerTests (line 10) | [TestFixture]
    method ContactManagerTestsSetUp (line 13) | [TestFixtureSetUp]
    method ReturnsContactsFromTatooine (line 19) | [Test]
    method ReturnsContactsFromDagobah (line 28) | [Test]
  class ContactManagerTestBase (line 38) | public class ContactManagerTestBase
    method SetUp (line 42) | protected void SetUp()
    method ContactMaker (line 57) | private Contact ContactMaker(string name, string country)

FILE: Xero.Api.Example.Mocks/Lister.cs
  class Lister (line 8) | internal class Lister
    method Lister (line 12) | public Lister(IXeroCoreApi api)
    method List (line 17) | public void List()
    method GetTotalContactCount (line 29) | private int GetTotalContactCount()
    method GetTotalInvoiceCount (line 44) | private int GetTotalInvoiceCount()
    method ListReports (line 59) | private void ListReports(IEnumerable<string> reports, string name)

FILE: Xero.Api.Example.Mocks/Program.cs
  class Program (line 10) | class Program
    method Main (line 12) | static void Main(string[] args)

FILE: Xero.Api.Example.TokenStores/Dapper/Dapper.cs
  type IDynamicParameters (line 31) | public partial interface IDynamicParameters
    method AddParameters (line 38) | void AddParameters(IDbCommand command, Identity identity);
  type ICustomQueryParameter (line 44) | public interface ICustomQueryParameter
    method AddParameter (line 51) | void AddParameter(IDbCommand command, string name);
  type ITypeMap (line 57) | public interface ITypeMap
    method FindConstructor (line 65) | ConstructorInfo FindConstructor(string[] names, Type[] types);
    method GetConstructorParameter (line 73) | IMemberMap GetConstructorParameter(ConstructorInfo constructor, string...
    method GetMember (line 80) | IMemberMap GetMember(string columnName);
  type IMemberMap (line 86) | public interface IMemberMap
  method GetBindByName (line 115) | static Action<IDbCommand, bool> GetBindByName(Type commandType)
  class Link (line 150) | partial class Link<TKey, TValue> where TKey : class
    method TryGet (line 152) | public static bool TryGet(Link<TKey, TValue> link, TKey key, out TValu...
    method TryAdd (line 166) | public static bool TryAdd(ref Link<TKey, TValue> head, TKey key, ref T...
    method Link (line 184) | private Link(TKey key, TValue value, Link<TKey, TValue> tail)
  class CacheInfo (line 194) | partial class CacheInfo
    method GetHitCount (line 200) | public int GetHitCount() { return Interlocked.CompareExchange(ref hitC...
    method RecordHit (line 201) | public void RecordHit() { Interlocked.Increment(ref hitCount); }
  method GetColumnHash (line 203) | static int GetColumnHash(IDataReader reader)
  type DeserializerState (line 216) | struct DeserializerState
    method DeserializerState (line 221) | public DeserializerState(int hash, Func<IDataReader, object> func)
  method OnQueryCachePurged (line 232) | private static void OnQueryCachePurged()
  method SetQueryCache (line 241) | private static void SetQueryCache(Identity key, CacheInfo value)
  method TryGetQueryCache (line 245) | private static bool TryGetQueryCache(Identity key, out CacheInfo value)
  method PurgeQueryCacheByType (line 249) | private static void PurgeQueryCacheByType(Type type)
  method PurgeQueryCache (line 261) | public static void PurgeQueryCache()
  method SetQueryCache (line 271) | private static void SetQueryCache(Identity key, CacheInfo value)
  method CollectCacheGarbage (line 280) | private static void CollectCacheGarbage()
  method TryGetQueryCache (line 302) | private static bool TryGetQueryCache(Identity key, out CacheInfo value)
  method PurgeQueryCache (line 316) | public static void PurgeQueryCache()
  method PurgeQueryCacheByType (line 322) | private static void PurgeQueryCacheByType(Type type)
  method GetCachedSQLCount (line 336) | public static int GetCachedSQLCount()
  method GetCachedSQL (line 346) | public static IEnumerable<Tuple<string, string, int>> GetCachedSQL(int i...
  method GetHashCollissions (line 357) | public static IEnumerable<Tuple<int, int>> GetHashCollissions()
  method SqlMapper (line 382) | static SqlMapper()
  method AddTypeMap (line 426) | public static void AddTypeMap(Type type, DbType dbType)
  method LookupDbType (line 432) | internal static DbType LookupDbType(Type type, string name)
  class Identity (line 462) | public partial class Identity : IEquatable<Identity>
    method ForGrid (line 464) | internal Identity ForGrid(Type primaryType, int gridIndex)
    method ForGrid (line 469) | internal Identity ForGrid(Type primaryType, Type[] otherTypes, int gri...
    method ForDynamicParameters (line 478) | public Identity ForDynamicParameters(Type type)
    method Identity (line 483) | internal Identity(string sql, CommandType? commandType, IDbConnection ...
    method Identity (line 486) | private Identity(string sql, CommandType? commandType, string connecti...
    method Equals (line 518) | public override bool Equals(object obj)
    method GetHashCode (line 551) | public override int GetHashCode()
    method Equals (line 560) | public bool Equals(Identity other)
  method Execute (line 578) | public static int Execute(this IDbConnection cnn, string sql, object param)
  method Execute (line 587) | public static int Execute(this IDbConnection cnn, string sql, object par...
  method Execute (line 596) | public static int Execute(this IDbConnection cnn, string sql, object par...
  method Execute (line 605) | public static int Execute(this IDbConnection cnn, string sql, object par...
  method Query (line 616) | public static IEnumerable<T> Query<T>(this IDbConnection cnn, string sql...
  method Query (line 627) | public static IEnumerable<T> Query<T>(this IDbConnection cnn, string sql...
  method Query (line 638) | public static IEnumerable<T> Query<T>(this IDbConnection cnn, string sql...
  method Query (line 649) | public static IEnumerable<T> Query<T>(this IDbConnection cnn, string sql...
  method QueryMultiple (line 657) | public static GridReader QueryMultiple(this IDbConnection cnn, string sq...
  method QueryMultiple (line 665) | public static GridReader QueryMultiple(this IDbConnection cnn, string sq...
  method QueryMultiple (line 673) | public static GridReader QueryMultiple(this IDbConnection cnn, string sq...
  method Execute (line 682) | public static int Execute(
  method Query (line 734) | public static IEnumerable<dynamic> Query(this IDbConnection cnn, string ...
  method Query (line 742) | public static IEnumerable<IDictionary<string, object>> Query(this IDbCon...
  method Query (line 750) | public static IEnumerable<IDictionary<string, object>> Query(this IDbCon...
  method Query (line 758) | public static IEnumerable<IDictionary<string, object>> Query(this IDbCon...
  method Query (line 766) | public static IEnumerable<IDictionary<string, object>> Query(this IDbCon...
  method Query (line 774) | public static IEnumerable<IDictionary<string, object>> Query(this IDbCon...
  method Query (line 787) | public static IEnumerable<T> Query<T>(
  method QueryMultiple (line 802) | public static GridReader QueryMultiple(
  method QueryInternal (line 846) | private static IEnumerable<T> QueryInternal<T>(this IDbConnection cnn, s...
  method Query (line 913) | public static IEnumerable<TReturn> Query<TFirst, TSecond, TReturn>(
  method Query (line 941) | public static IEnumerable<TReturn> Query<TFirst, TSecond, TThird, TReturn>(
  method Query (line 970) | public static IEnumerable<TReturn> Query<TFirst, TSecond, TThird, TFourt...
  method Query (line 1001) | public static IEnumerable<TReturn> Query<TFirst, TSecond, TThird, TFourt...
  method Query (line 1028) | public static IEnumerable<TReturn> Query<TFirst, TSecond, TThird, TFourt...
  method Query (line 1057) | public static IEnumerable<TReturn> Query<TFirst, TSecond, TThird, TFourt...
  class DontMap (line 1062) | partial class DontMap { }
  method MultiMap (line 1063) | static IEnumerable<TReturn> MultiMap<TFirst, TSecond, TThird, TFourth, T...
  method MultiMapImpl (line 1071) | static IEnumerable<TReturn> MultiMapImpl<TFirst, TSecond, TThird, TFourt...
  method GenerateMapper (line 1131) | private static Func<IDataReader, TReturn> GenerateMapper<TFirst, TSecond...
  method GenerateDeserializers (line 1154) | private static Func<IDataReader, object>[] GenerateDeserializers(Type[] ...
  method GetCacheInfo (line 1229) | private static CacheInfo GetCacheInfo(Identity identity)
  method GetDeserializer (line 1261) | private static Func<IDataReader, object> GetDeserializer(Type type, IDat...
  class DapperTable (line 1287) | private sealed partial class DapperTable
    method DapperTable (line 1294) | public DapperTable(string[] fieldNames)
    method IndexOfName (line 1308) | internal int IndexOfName(string name)
    method AddField (line 1313) | internal int AddField(string name)
    method FieldExists (line 1325) | internal bool FieldExists(string key)
  class DapperRowMetaObject (line 1333) | sealed partial class DapperRowMetaObject : System.Dynamic.DynamicMetaObject
    method DapperRowMetaObject (line 1338) | public DapperRowMetaObject(
    method DapperRowMetaObject (line 1346) | public DapperRowMetaObject(
    method CallMethod (line 1355) | System.Dynamic.DynamicMetaObject CallMethod(
    method BindGetMember (line 1370) | public override System.Dynamic.DynamicMetaObject BindGetMember(System....
    method BindInvokeMember (line 1383) | public override System.Dynamic.DynamicMetaObject BindInvokeMember(Syst...
    method BindSetMember (line 1395) | public override System.Dynamic.DynamicMetaObject BindSetMember(System....
  class DapperRow (line 1409) | private sealed partial class DapperRow
    method DapperRow (line 1416) | public DapperRow(DapperTable table, object[] values)
    class DeadValue (line 1423) | private sealed class DeadValue
      method DeadValue (line 1426) | private DeadValue() { }
    method TryGetValue (line 1441) | public bool TryGetValue(string name, out object value)
    method ToString (line 1459) | public override string ToString()
    method GetMetaObject (line 1479) | System.Dynamic.DynamicMetaObject System.Dynamic.IDynamicMetaObjectProv...
    method GetEnumerator (line 1485) | public IEnumerator<KeyValuePair<string, object>> GetEnumerator()
    method GetEnumerator (line 1498) | IEnumerator IEnumerable.GetEnumerator()
    method Add (line 1505) | void ICollection<KeyValuePair<string, object>>.Add(KeyValuePair<string...
    method Clear (line 1511) | void ICollection<KeyValuePair<string, object>>.Clear()
    method Contains (line 1517) | bool ICollection<KeyValuePair<string, object>>.Contains(KeyValuePair<s...
    method CopyTo (line 1523) | void ICollection<KeyValuePair<string, object>>.CopyTo(KeyValuePair<str...
    method Remove (line 1531) | bool ICollection<KeyValuePair<string, object>>.Remove(KeyValuePair<str...
    method ContainsKey (line 1546) | bool IDictionary<string, object>.ContainsKey(string key)
    method Add (line 1553) | void IDictionary<string, object>.Add(string key, object value)
    method Remove (line 1558) | bool IDictionary<string, object>.Remove(string key)
    method SetValue (line 1572) | public object SetValue(string key, object value)
    method SetValue (line 1576) | private object SetValue(string key, object value, bool isAdd)
  method GetDapperRowDeserializer (line 1618) | internal static Func<IDataReader, object> GetDapperRowDeserializer(IData...
  method GetDictionaryDeserializer (line 1678) | internal static Func<IDataReader, object> GetDictionaryDeserializer(IDat...
  method ReadChar (line 1714) | [Browsable(false), EditorBrowsable(EditorBrowsableState.Never)]
  method ReadNullableChar (line 1727) | [Browsable(false), EditorBrowsable(EditorBrowsableState.Never)]
  method FindOrAddParameter (line 1741) | [Browsable(false), EditorBrowsable(EditorBrowsableState.Never)]
  method PackListParameters (line 1762) | [Browsable(false), EditorBrowsable(EditorBrowsableState.Never)]
  method FilterParameters (line 1832) | private static IEnumerable<PropertyInfo> FilterParameters(IEnumerable<Pr...
  method CreateParamInfoGenerator (line 1844) | public static Action<IDbCommand, object> CreateParamInfoGenerator(Identi...
  method SetupCommand (line 2080) | private static IDbCommand SetupCommand(IDbConnection cnn, IDbTransaction...
  method ExecuteCommand (line 2100) | private static int ExecuteCommand(IDbConnection cnn, IDbTransaction tran...
  method GetStructDeserializer (line 2117) | private static Func<IDataReader, object> GetStructDeserializer(Type type...
  method GetTypeMap (line 2160) | public static ITypeMap GetTypeMap(Type type)
  method SetTypeMap (line 2188) | public static void SetTypeMap(Type type, ITypeMap map)
  method GetTypeDeserializer (line 2220) | public static Func<IDataReader, object> GetTypeDeserializer(
  method GetOperator (line 2549) | static MethodInfo GetOperator(Type from, Type to)
  method ResolveOperator (line 2559) | static MethodInfo ResolveOperator(MethodInfo[] methods, Type from, Type ...
  method LoadLocal (line 2571) | private static void LoadLocal(ILGenerator il, int index)
  method StoreLocal (line 2592) | private static void StoreLocal(ILGenerator il, int index)
  method LoadLocalAddress (line 2613) | private static void LoadLocalAddress(ILGenerator il, int index)
  method ThrowDataException (line 2632) | public static void ThrowDataException(Exception ex, int index, IDataRead...
  method EmitInt32 (line 2659) | private static void EmitInt32(ILGenerator il, int value)
  method GridReader (line 2709) | internal GridReader(IDbCommand command, IDataReader reader, Identity ide...
  method Read (line 2721) | public IEnumerable<dynamic> Read(bool buffered = true)
  method Read (line 2731) | public IEnumerable<T> Read<T>()
  method Read (line 2740) | public IEnumerable<T> Read<T>(bool buffered)
  method Read (line 2742) | public IEnumerable<T> Read<T>(bool buffered = true)
  method MultiReadInternal (line 2762) | private IEnumerable<TReturn> MultiReadInternal<TFirst, TSecond, TThird, ...
  method Read (line 2790) | public IEnumerable<TReturn> Read<TFirst, TSecond, TReturn>(Func<TFirst, ...
  method Read (line 2799) | public IEnumerable<TReturn> Read<TFirst, TSecond, TReturn>(Func<TFirst, ...
  method Read (line 2801) | public IEnumerable<TReturn> Read<TFirst, TSecond, TReturn>(Func<TFirst, ...
  method Read (line 2812) | public IEnumerable<TReturn> Read<TFirst, TSecond, TThird, TReturn>(Func<...
  method Read (line 2821) | public IEnumerable<TReturn> Read<TFirst, TSecond, TThird, TReturn>(Func<...
  method Read (line 2823) | public IEnumerable<TReturn> Read<TFirst, TSecond, TThird, TReturn>(Func<...
  method Read (line 2834) | public IEnumerable<TReturn> Read<TFirst, TSecond, TThird, TFourth, TRetu...
  method Read (line 2844) | public IEnumerable<TReturn> Read<TFirst, TSecond, TThird, TFourth, TRetu...
  method Read (line 2846) | public IEnumerable<TReturn> Read<TFirst, TSecond, TThird, TFourth, TRetu...
  method Read (line 2859) | public IEnumerable<TReturn> Read<TFirst, TSecond, TThird, TFourth, TFift...
  method Read (line 2867) | public IEnumerable<TReturn> Read<TFirst, TSecond, TThird, TFourth, TFift...
  method Read (line 2875) | public IEnumerable<TReturn> Read<TFirst, TSecond, TThird, TFourth, TFift...
  method ReadDeferred (line 2882) | private IEnumerable<T> ReadDeferred<T>(int index, Func<IDataReader, obje...
  method NextResult (line 2901) | private void NextResult()
  method Dispose (line 2923) | public void Dispose()
  class DynamicParameters (line 2943) | partial class DynamicParameters : SqlMapper.IDynamicParameters
    class ParamInfo (line 2951) | partial class ParamInfo
    method DynamicParameters (line 2964) | public DynamicParameters()
    method DynamicParameters (line 2973) | public DynamicParameters(object template)
    method AddDynamicParams (line 2984) | public void AddDynamicParams(
    method Add (line 3046) | public void Add(
    method Clean (line 3057) | static string Clean(string name)
    method AddParameters (line 3072) | void SqlMapper.IDynamicParameters.AddParameters(IDbCommand command, Sq...
    method AddParameters (line 3087) | protected void AddParameters(IDbCommand command, SqlMapper.Identity id...
    method Get (line 3184) | public T Get<T>(string name)
  class DbString (line 3202) | sealed partial class DbString : Dapper.SqlMapper.ICustomQueryParameter
    method DbString (line 3207) | public DbString() { Length = -1; }
    method AddParameter (line 3229) | public void AddParameter(IDbCommand command, string name)
  class FeatureSupport (line 3254) | partial class FeatureSupport
    method Get (line 3267) | public static FeatureSupport Get(IDbConnection connection)
  class SimpleMemberMap (line 3283) | sealed partial class SimpleMemberMap : SqlMapper.IMemberMap
    method SimpleMemberMap (line 3295) | public SimpleMemberMap(string columnName, PropertyInfo property)
    method SimpleMemberMap (line 3312) | public SimpleMemberMap(string columnName, FieldInfo field)
    method SimpleMemberMap (line 3329) | public SimpleMemberMap(string columnName, ParameterInfo parameter)
  class DefaultTypeMap (line 3397) | sealed partial class DefaultTypeMap : SqlMapper.ITypeMap
    method DefaultTypeMap (line 3407) | public DefaultTypeMap(Type type)
    method GetPropertySetter (line 3417) | internal static MethodInfo GetPropertySetter(PropertyInfo propertyInfo...
    method GetSettableProps (line 3424) | internal static List<PropertyInfo> GetSettableProps(Type t)
    method GetSettableFields (line 3432) | internal static List<FieldInfo> GetSettableFields(Type t)
    method FindConstructor (line 3443) | public ConstructorInfo FindConstructor(string[] names, Type[] types)
    method GetConstructorParameter (line 3482) | public SqlMapper.IMemberMap GetConstructorParameter(ConstructorInfo co...
    method GetMember (line 3494) | public SqlMapper.IMemberMap GetMember(string columnName)
  class CustomPropertyTypeMap (line 3515) | sealed partial class CustomPropertyTypeMap : SqlMapper.ITypeMap
    method CustomPropertyTypeMap (line 3525) | public CustomPropertyTypeMap(Type type, Func<Type, string, PropertyInf...
    method FindConstructor (line 3543) | public ConstructorInfo FindConstructor(string[] names, Type[] types)
    method GetConstructorParameter (line 3554) | public SqlMapper.IMemberMap GetConstructorParameter(ConstructorInfo co...
    method GetMember (line 3564) | public SqlMapper.IMemberMap GetMember(string columnName)
  class SqlMapper (line 3576) | public partial class SqlMapper
  class DynamicParameters (line 3580) | public partial class DynamicParameters
    class ParamInfo (line 2951) | partial class ParamInfo
    method DynamicParameters (line 2964) | public DynamicParameters()
    method DynamicParameters (line 2973) | public DynamicParameters(object template)
    method AddDynamicParams (line 2984) | public void AddDynamicParams(
    method Add (line 3046) | public void Add(
    method Clean (line 3057) | static string Clean(string name)
    method AddParameters (line 3072) | void SqlMapper.IDynamicParameters.AddParameters(IDbCommand command, Sq...
    method AddParameters (line 3087) | protected void AddParameters(IDbCommand command, SqlMapper.Identity id...
    method Get (line 3184) | public T Get<T>(string name)
  class DbString (line 3585) | public partial class DbString
    method DbString (line 3207) | public DbString() { Length = -1; }
    method AddParameter (line 3229) | public void AddParameter(IDbCommand command, string name)
  class SimpleMemberMap (line 3590) | public partial class SimpleMemberMap
    method SimpleMemberMap (line 3295) | public SimpleMemberMap(string columnName, PropertyInfo property)
    method SimpleMemberMap (line 3312) | public SimpleMemberMap(string columnName, FieldInfo field)
    method SimpleMemberMap (line 3329) | public SimpleMemberMap(string columnName, ParameterInfo parameter)
  class DefaultTypeMap (line 3595) | public partial class DefaultTypeMap
    method DefaultTypeMap (line 3407) | public DefaultTypeMap(Type type)
    method GetPropertySetter (line 3417) | internal static MethodInfo GetPropertySetter(PropertyInfo propertyInfo...
    method GetSettableProps (line 3424) | internal static List<PropertyInfo> GetSettableProps(Type t)
    method GetSettableFields (line 3432) | internal static List<FieldInfo> GetSettableFields(Type t)
    method FindConstructor (line 3443) | public ConstructorInfo FindConstructor(string[] names, Type[] types)
    method GetConstructorParameter (line 3482) | public SqlMapper.IMemberMap GetConstructorParameter(ConstructorInfo co...
    method GetMember (line 3494) | public SqlMapper.IMemberMap GetMember(string columnName)
  class CustomPropertyTypeMap (line 3600) | public partial class CustomPropertyTypeMap
    method CustomPropertyTypeMap (line 3525) | public CustomPropertyTypeMap(Type type, Func<Type, string, PropertyInf...
    method FindConstructor (line 3543) | public ConstructorInfo FindConstructor(string[] names, Type[] types)
    method GetConstructorParameter (line 3554) | public SqlMapper.IMemberMap GetConstructorParameter(ConstructorInfo co...
    method GetMember (line 3564) | public SqlMapper.IMemberMap GetMember(string columnName)
  class FeatureSupport (line 3605) | public partial class FeatureSupport
    method Get (line 3267) | public static FeatureSupport Get(IDbConnection connection)

FILE: Xero.Api.Example.TokenStores/MemoryTokenStore.cs
  class MemoryTokenStore (line 7) | public class MemoryTokenStore : ITokenStore
    method Find (line 11) | public IToken Find(string userId)
    method Add (line 22) | public void Add(IToken token)
    method Delete (line 27) | public void Delete(IToken token)

FILE: Xero.Api.Example.TokenStores/SqliteTokenStore.cs
  class SqliteTokenStore (line 10) | public class SqliteTokenStore : ITokenStore
    method SqliteTokenStore (line 15) | public SqliteTokenStore()
    method CreateEmptyDatabase (line 23) | private void CreateEmptyDatabase()
    method Find (line 47) | public IToken Find(string userId)
    method Add (line 75) | public void Add(IToken token)
    method Delete (line 91) | public void Delete(IToken token)

FILE: Xero.Api/Common/CoreData.cs
  class CoreData (line 8) | [DataContract(Namespace = "")]

FILE: Xero.Api/Common/Extensions.cs
  class Extensions (line 6) | public static class Extensions
    method Add (line 8) | public static void Add(this NameValueCollection collection, string nam...
    method Add (line 16) | public static void Add(this NameValueCollection collection, string nam...
    method Add (line 24) | public static void Add(this NameValueCollection collection, string nam...

FILE: Xero.Api/Common/HasUpdatedDate.cs
  class HasUpdatedDate (line 6) | [DataContract(Namespace = "")]

FILE: Xero.Api/Common/IHasAttachment.cs
  type IHasAttachment (line 8) | public interface IHasAttachment

FILE: Xero.Api/Common/IHasId.cs
  type IHasId (line 5) | public interface IHasId

FILE: Xero.Api/Common/IPageableEndpoint.cs
  type IPageableEndpoint (line 3) | public interface IPageableEndpoint<T>
    method Page (line 5) | T Page(int page);

FILE: Xero.Api/Common/IXeroReadEndpoint.cs
  type IXeroReadEndpoint (line 7) | public interface IXeroReadEndpoint<T, TResult, TResponse>
    method ModifiedSince (line 12) | T ModifiedSince(DateTime modified);
    method Where (line 13) | T Where(string query);
    method Or (line 14) | T Or(string query);
    method And (line 15) | T And(string query);
    method OrderBy (line 16) | T OrderBy(string query);
    method OrderByDescending (line 17) | T OrderByDescending(string query);
    method UseFourDecimalPlaces (line 18) | T UseFourDecimalPlaces(bool use4Dp);
    method Find (line 19) | IEnumerable<TResult> Find();
    method Find (line 20) | TResult Find(Guid child);
    method Find (line 21) | TResult Find(string child);
    method ClearQueryString (line 22) | void ClearQueryString();

FILE: Xero.Api/Common/MimeTypes.cs
  class MimeTypes (line 6) | public static class MimeTypes
    method GetMimeType (line 23) | public static string GetMimeType(FileInfo fileInfo)
    method GetMimeType (line 40) | public static string GetMimeType(string fileName)

FILE: Xero.Api/Common/QueryGenerator.cs
  class QueryGenerator (line 8) | public class QueryGenerator
    method QueryGenerator (line 14) | public QueryGenerator(string where, string order, NameValueCollection ...
    method BuildCollection (line 39) | private NameValueCollection BuildCollection()

FILE: Xero.Api/Common/XeroApi.cs
  class XeroApi (line 8) | public abstract class XeroApi
    method XeroApi (line 14) | private XeroApi(string baseUri)
    method XeroApi (line 19) | protected XeroApi(string baseUri, IAuthenticator auth, IConsumer consu...

FILE: Xero.Api/Common/XeroReadEndpoint.cs
  class XeroReadEndpoint (line 10) | public abstract class XeroReadEndpoint<T, TResult, TResponse> : IXeroRea...
    method XeroReadEndpoint (line 23) | protected XeroReadEndpoint(XeroHttpClient client, string apiEndpointUrl)
    method ModifiedSince (line 29) | public T ModifiedSince(DateTime modified)
    method Where (line 35) | public T Where(string query)
    method Or (line 41) | public T Or(string query)
    method And (line 47) | public T And(string query)
    method OrderBy (line 53) | public T OrderBy(string query)
    method OrderByDescending (line 59) | public T OrderByDescending(string query)
    method UseFourDecimalPlaces (line 65) | public T UseFourDecimalPlaces(bool use4Dp)
    method Find (line 72) | public virtual IEnumerable<TResult> Find()
    method Find (line 77) | public virtual TResult Find(Guid child)
    method Find (line 82) | public TResult Find(string child)
    method ClearQueryString (line 87) | public virtual void ClearQueryString()
    method Apply4Dp (line 95) | protected void Apply4Dp(bool use4Dp)
    method AddParameter (line 117) | internal protected T AddParameter(string name, int value)
    method AddParameter (line 122) | internal protected T AddParameter(string name, bool value)
    method RemoveParameter (line 127) | internal void RemoveParameter(string name)
    method AddParameter (line 135) | internal protected T AddParameter(string name, string value)
    method AddParameters (line 147) | internal protected T AddParameters(NameValueCollection parameters)
    method Get (line 161) | private IEnumerable<TResult> Get(string endpoint, string child)

FILE: Xero.Api/Common/XeroRequest.cs
  class XeroRequest (line 6) | public class XeroRequest<T> : List<T>, IXeroRequest<T>
    method XeroRequest (line 8) | public XeroRequest()
    method XeroRequest (line 12) | public XeroRequest(IEnumerable<T> items)

FILE: Xero.Api/Common/XeroResponse.cs
  class XeroResponse (line 10) | public abstract class XeroResponse<T> : XeroResponse, IXeroResponse<T>
  class XeroResponse (line 15) | [DataContract(Namespace = "")]

FILE: Xero.Api/Core/Endpoints/AccountsEndpoint.cs
  type IAccountsEndpoint (line 9) | public interface IAccountsEndpoint
  class AccountsEndpoint (line 15) | public class AccountsEndpoint
    method AccountsEndpoint (line 18) | public AccountsEndpoint(XeroHttpClient client) :

FILE: Xero.Api/Core/Endpoints/AllocationEndpoint.cs
  class AllocationsEndpoint (line 12) | public class AllocationsEndpoint
    method AllocationsEndpoint (line 16) | public AllocationsEndpoint(XeroHttpClient client)
    method Add (line 21) | public Allocation Add(Allocation allocation)
    method Add (line 28) | public CreditNoteAllocation Add(CreditNoteAllocation allocation)
    method Add (line 35) | public PrepaymentAllocation Add(PrepaymentAllocation allocation)
    method Add (line 42) | public OverpaymentAllocation Add(OverpaymentAllocation allocation)
    method HandleResponse (line 49) | private AllocationsResponse<T> HandleResponse<T>(Infrastructure.Http.R...
    method Add (line 63) | public T Add<T>(T allocation, string endpoint)
  class AllocationsResponse (line 75) | public class AllocationsResponse<T> : XeroResponse<T>

FILE: Xero.Api/Core/Endpoints/AssociationsEndpoint.cs
  type IAssociationsEndpoint (line 9) | public interface IAssociationsEndpoint
    method Find (line 11) | Association Find(Guid fileId, Guid objectId);
    method Find (line 13) | IEnumerable<Association> Find(Guid fileId);
    method FindForObject (line 15) | IEnumerable<Association> FindForObject(Guid objectId);
    method Create (line 17) | Association Create(Association association);
    method Delete (line 19) | void Delete(Association association);
  class AssociationsEndpoint (line 22) | public class AssociationsEndpoint : IAssociationsEndpoint
    method AssociationsEndpoint (line 26) | internal AssociationsEndpoint(XeroHttpClient client)
    method Find (line 31) | public Association Find(Guid fileId, Guid objectId)
    method Find (line 37) | public IEnumerable<Association> Find(Guid fileId)
    method FindForObject (line 43) | public IEnumerable<Association> FindForObject(Guid objectId)
    method Create (line 49) | public Association Create(Association association)
    method Delete (line 56) | public void Delete(Association association)
    method HandleAssociationsResponse (line 63) | private IEnumerable<Association> HandleAssociationsResponse(Infrastruc...
    method HandleAssociationResponse (line 75) | private Association HandleAssociationResponse(Infrastructure.Http.Resp...

FILE: Xero.Api/Core/Endpoints/AttachmentsEndpoint.cs
  class AttachmentsEndpoint (line 13) | public class AttachmentsEndpoint
    method AttachmentsEndpoint (line 17) | public AttachmentsEndpoint(XeroHttpClient client)
    method List (line 22) | public IEnumerable<Attachment> List(AttachmentEndpointType type, Guid ...
    method Get (line 27) | public Attachment Get(AttachmentEndpointType type, Guid parent, string...
    method AddOrReplace (line 42) | public Attachment AddOrReplace(Attachment attachment, AttachmentEndpoi...
    method SupportsOnline (line 56) | private static bool SupportsOnline(AttachmentEndpointType type)

FILE: Xero.Api/Core/Endpoints/BankTransactionsEndpoint.cs
  type IBankTransactionsEndpoint (line 10) | public interface IBankTransactionsEndpoint : IXeroUpdateEndpoint<BankTra...
  class BankTransactionsEndpoint (line 14) | public class BankTransactionsEndpoint :
    method BankTransactionsEndpoint (line 18) | public BankTransactionsEndpoint(XeroHttpClient client)
    method Page (line 23) | public IBankTransactionsEndpoint Page(int page)

FILE: Xero.Api/Core/Endpoints/BankTransfersEndpoint.cs
  type IBankTransfersEndpoint (line 9) | public interface IBankTransfersEndpoint :
  class BankTransfersEndpoint (line 14) | public class BankTransfersEndpoint : XeroCreateEndpoint<BankTransfersEnd...
    method BankTransfersEndpoint (line 17) | public BankTransfersEndpoint(XeroHttpClient client)

FILE: Xero.Api/Core/Endpoints/Base/FourDecimalPlacesEndpoint.cs
  class FourDecimalPlacesEndpoint (line 7) | public abstract class FourDecimalPlacesEndpoint<T, TResult, TRequest, TR...
    method FourDecimalPlacesEndpoint (line 13) | protected FourDecimalPlacesEndpoint(XeroHttpClient client, string apiE...
    method ClearQueryString (line 18) | public override void ClearQueryString()

FILE: Xero.Api/Core/Endpoints/Base/IXeroCreateEndpoint.cs
  type IXeroCreateEndpoint (line 7) | public interface IXeroCreateEndpoint<T, TResult, TRequest, TResponse>
    method Create (line 13) | IEnumerable<TResult> Create(IEnumerable<TResult> items);
    method Create (line 14) | TResult Create(TResult item);
    method SummarizeErrors (line 15) | IXeroCreateEndpoint<T, TResult, TRequest, TResponse> SummarizeErrors(b...

FILE: Xero.Api/Core/Endpoints/Base/IXeroUpdateEndpoint.cs
  type IXeroUpdateEndpoint (line 10) | public interface IXeroUpdateEndpoint<T, TResult, TRequest, TResponse>
    method Update (line 16) | IEnumerable<TResult> Update(IEnumerable<TResult> items);
    method Update (line 17) | TResult Update(TResult item);
    method SummarizeErrors (line 18) | new IXeroUpdateEndpoint<T, TResult, TRequest, TResponse> SummarizeErro...

FILE: Xero.Api/Core/Endpoints/Base/XeroCreateEndpoint.cs
  class XeroCreateEndpoint (line 9) | public abstract class XeroCreateEndpoint<T, TResult, TRequest, TResponse>
    method XeroCreateEndpoint (line 15) | protected XeroCreateEndpoint(XeroHttpClient client, string apiEndpoint...
    method Create (line 20) | public IEnumerable<TResult> Create(IEnumerable<TResult> items)
    method Create (line 28) | public TResult Create(TResult item)
    method SummarizeErrors (line 33) | public IXeroCreateEndpoint<T, TResult, TRequest, TResponse> SummarizeE...
    method Put (line 39) | protected IEnumerable<TResult> Put(TRequest data)

FILE: Xero.Api/Core/Endpoints/Base/XeroUpdateEndpoint.cs
  class XeroUpdateEndpoint (line 9) | public abstract class XeroUpdateEndpoint<T, TResult, TRequest, TResponse>
    method XeroUpdateEndpoint (line 15) | protected XeroUpdateEndpoint(XeroHttpClient client, string apiEndpoint...
    method Update (line 20) | public IEnumerable<TResult> Update(IEnumerable<TResult> items)
    method Update (line 28) | public virtual TResult Update(TResult item)
    method SummarizeErrors (line 33) | public new IXeroUpdateEndpoint<T, TResult, TRequest, TResponse> Summar...
    method Post (line 39) | protected IEnumerable<TResult> Post(TRequest data)

FILE: Xero.Api/Core/Endpoints/BatchPaymentsEndpoint.cs
  type IBatchPaymentsEndpoint (line 9) | public interface IBatchPaymentsEndpoint
  class BatchPaymentsEndpoint (line 15) | public class BatchPaymentsEndpoint
    method BatchPaymentsEndpoint (line 18) | public BatchPaymentsEndpoint(XeroHttpClient client) :

FILE: Xero.Api/Core/Endpoints/BrandingThemesEndpoint.cs
  type IBrandingThemesEndpoint (line 8) | public interface IBrandingThemesEndpoint :
  class BrandingThemesEndpoint (line 14) | public class BrandingThemesEndpoint : XeroReadEndpoint<BrandingThemesEnd...
    method BrandingThemesEndpoint (line 16) | public BrandingThemesEndpoint(XeroHttpClient client)

FILE: Xero.Api/Core/Endpoints/ContactGroupEndpoint.cs
  type IContactGroupsEndpoint (line 13) | public interface IContactGroupsEndpoint :
    method Add (line 17) | ContactGroup Add(ContactGroup contactGroup);
  class ContactGroupsEndpoint (line 20) | public class ContactGroupsEndpoint : XeroUpdateEndpoint<ContactGroupsEnd...
    method ContactGroupsEndpoint (line 24) | public ContactGroupsEndpoint(XeroHttpClient client) : base(client,"/ap...
    method Add (line 46) | public ContactGroup Add(ContactGroup contactGroup)
    method HandleResponse (line 58) | private ContactGroupsResponse HandleResponse(Infrastructure.Http.Respo...
  type IContactCollection (line 72) | public interface IContactCollection :
    method Clear (line 75) | void Clear();
    method Add (line 76) | void Add(Contact contact);
    method AddRange (line 77) | void AddRange(List<Contact> contacts);
    method Remove (line 78) | void Remove(Guid guid);
  class ContactCollection (line 81) | public class ContactCollection  : XeroUpdateEndpoint<ContactGroupsEndpoi...
    method ContactCollection (line 87) | public ContactCollection(XeroHttpClient client, ContactGroup group)
    method Clear (line 94) | public void Clear()
    method Add (line 103) | public void Add(Contact contact)
    method AddRange (line 113) | public void AddRange(List<Contact> contacts)
    method Remove (line 118) | public void Remove(Guid guid)
    method UnAssignContact (line 123) | private void UnAssignContact(ContactGroup contactGroup, Guid contactId)
    method AssignContacts (line 133) | private void AssignContacts(ContactGroup contactGroup, List<Contact> c...
    method HandleResponse (line 143) | private ContactGroupsResponse HandleResponse(Infrastructure.Http.Respo...

FILE: Xero.Api/Core/Endpoints/ContactsEndpoint.cs
  type IContactsEndpoint (line 13) | public interface IContactsEndpoint
    method IncludeArchived (line 17) | IContactsEndpoint IncludeArchived(bool include);
    method GetCisSettings (line 18) | ContactCisSetting GetCisSettings(Guid id);
    method Ids (line 19) | IContactsEndpoint Ids(IEnumerable<Guid> ids);
  class ContactsEndpoint (line 22) | public class ContactsEndpoint
    method ContactsEndpoint (line 25) | internal ContactsEndpoint(XeroHttpClient client)
    method Page (line 31) | public IContactsEndpoint Page(int page)
    method IncludeArchived (line 37) | public IContactsEndpoint IncludeArchived(bool include)
    method GetCisSettings (line 47) | public ContactCisSetting GetCisSettings(Guid id)
    method ClearQueryString (line 53) | public override void ClearQueryString()
    method Ids (line 59) | public IContactsEndpoint Ids(IEnumerable<Guid> ids)

FILE: Xero.Api/Core/Endpoints/CreditNotesEndpoint.cs
  type ICreditNotesEndpoint (line 11) | public interface ICreditNotesEndpoint :
  class CreditNotesEndpoint (line 17) | public class CreditNotesEndpoint
    method CreditNotesEndpoint (line 20) | public CreditNotesEndpoint(XeroHttpClient client) :
    method Page (line 25) | public ICreditNotesEndpoint Page(int page)
    method ClearQueryString (line 31) | public override void ClearQueryString()

FILE: Xero.Api/Core/Endpoints/CurrenciesEndpoint.cs
  type ICurrenciesEndpoint (line 9) | public interface ICurrenciesEndpoint : IXeroCreateEndpoint<CurrenciesEnd...
  class CurrenciesEndpoint (line 14) | public class CurrenciesEndpoint : XeroCreateEndpoint<CurrenciesEndpoint,...
    method CurrenciesEndpoint (line 17) | internal CurrenciesEndpoint(XeroHttpClient client)

FILE: Xero.Api/Core/Endpoints/EmployeesEndpoint.cs
  type IEmployeesEndpoint (line 9) | public interface IEmployeesEndpoint : IXeroUpdateEndpoint<EmployeesEndpo...
  class EmployeesEndpoint (line 14) | public class EmployeesEndpoint
    method EmployeesEndpoint (line 17) | public EmployeesEndpoint(XeroHttpClient client) :

FILE: Xero.Api/Core/Endpoints/ExpenseClaimsEndpoint.cs
  type IExpenseClaimsEndpoint (line 9) | public interface IExpenseClaimsEndpoint : IXeroUpdateEndpoint<ExpenseCla...
  class ExpenseClaimsEndpoint (line 14) | public class ExpenseClaimsEndpoint
    method ExpenseClaimsEndpoint (line 17) | public ExpenseClaimsEndpoint(XeroHttpClient client)

FILE: Xero.Api/Core/Endpoints/FilesEndpoint.cs
  type IFilesEndpoint (line 14) | public interface IFilesEndpoint : IXeroUpdateEndpoint<FilesEndpoint, Mod...
    method Rename (line 16) | Model.File Rename(Guid id, string name);
    method Move (line 17) | Model.File Move(Guid id, Guid newFolder);
    method Add (line 18) | Model.File Add(Guid folderId, Model.File file, byte[] data);
    method Remove (line 19) | Model.File Remove(Guid fileid);
    method GetContent (line 20) | byte[] GetContent(Guid id, string contentType);
  class FilesEndpoint (line 24) | public class FilesEndpoint : XeroUpdateEndpoint<FilesEndpoint, Model.Fil...
    method FilesEndpoint (line 27) | internal FilesEndpoint(XeroHttpClient client)
    method Page (line 33) | public IFilesEndpoint Page(int page)
    method Find (line 48) | public override IEnumerable<Model.File> Find()
    method Find (line 56) | public override Model.File Find(Guid fileId)
    method Rename (line 64) | public Model.File Rename(Guid id, string name)
    method Move (line 73) | public Model.File Move(Guid id, Guid newFolder)
    method Add (line 82) | public Model.File Add(Guid folderId, Model.File file, byte[] data)
    method Remove (line 92) | public Model.File Remove(Guid fileid)
    method GetContent (line 101) | public byte[] GetContent(Guid id, string contentType)
    method HandleFileResponse (line 114) | private Model.File HandleFileResponse(Infrastructure.Http.Response res...
    method HandleFilesResponse (line 129) | private FilesResponse HandleFilesResponse(Infrastructure.Http.Response...

FILE: Xero.Api/Core/Endpoints/FoldersEndpoint.cs
  type IFoldersEndpoint (line 13) | public interface IFoldersEndpoint : IXeroUpdateEndpoint<FoldersEndpoint,...
    method Add (line 16) | FilePageResponse Add(string folderName);
    method Remove (line 17) | void Remove(Guid id);
    method Rename (line 18) | FoldersResponse Rename(Guid id, string name);
  class FoldersEndpoint (line 21) | public class FoldersEndpoint : XeroUpdateEndpoint<FoldersEndpoint, Model...
    method FoldersEndpoint (line 23) | internal FoldersEndpoint(XeroHttpClient client)
    method Add (line 43) | public FilePageResponse Add(string folderName)
    method Find (line 54) | public IList<Model.Folder> Find()
    method Remove (line 66) | public void Remove(Guid id)
    method Rename (line 73) | public FoldersResponse Rename(Guid id, string name)
    method HandleFolderResponse (line 79) | private FilePageResponse HandleFolderResponse(Infrastructure.Http.Resp...
    method HandleFoldersResponse (line 95) | private FoldersResponse[] HandleFoldersResponse(Infrastructure.Http.Re...
  class FolderResponse (line 112) | public class FolderResponse : XeroResponse<Model.Folder>
  class FolderRequest (line 120) | public class FolderRequest : XeroRequest<Model.Folder>

FILE: Xero.Api/Core/Endpoints/HistoryAndNotesEndpoint.cs
  type IHistoryAndNotesEndpoint (line 13) | public interface IHistoryAndNotesEndpoint
    method Find (line 15) | IEnumerable<HistoryRecord> Find(HistoryAndNotesEndpointRetrieveType ty...
    method CreateNote (line 16) | HistoryRecord CreateNote(HistoryAndNotesEndpointCreateType type, Guid ...
  class HistoryAndNotesEndpoint (line 19) | public class HistoryAndNotesEndpoint : IHistoryAndNotesEndpoint
    method HistoryAndNotesEndpoint (line 23) | public HistoryAndNotesEndpoint(XeroHttpClient client)
    method Find (line 28) | public IEnumerable<HistoryRecord> Find(HistoryAndNotesEndpointRetrieve...
    method CreateNote (line 33) | public HistoryRecord CreateNote(HistoryAndNotesEndpointCreateType type...

FILE: Xero.Api/Core/Endpoints/InboxEndpoint.cs
  type IInboxEndpoint (line 12) | public interface IInboxEndpoint : IXeroUpdateEndpoint<InboxEndpoint, Mod...
    method Add (line 15) | FilesResponse Add(Model.File file, byte[] data);
    method Remove (line 16) | FilesResponse Remove(Guid fileid);
  class InboxEndpoint (line 20) | public class InboxEndpoint : XeroUpdateEndpoint<InboxEndpoint,Model.Fold...
    method InboxEndpoint (line 23) | internal InboxEndpoint(XeroHttpClient client)
    method Find (line 53) | public Model.File Find(Guid fileId)
    method Add (line 61) | public FilesResponse Add(Model.File file, byte[] data)
    method Remove (line 74) | public FilesResponse Remove(Guid fileid)
    method HandleFileResponse (line 83) | private FilesResponse HandleFileResponse(Infrastructure.Http.Response ...
    method HandleInboxResponse (line 96) | private InboxResponse HandleInboxResponse(Infrastructure.Http.Response...
    method HandleFoldersResponse (line 130) | private FoldersResponse[] HandleFoldersResponse(Infrastructure.Http.Re...

FILE: Xero.Api/Core/Endpoints/InvoicesEndpoint.cs
  type IInvoicesEndpoint (line 16) | public interface IInvoicesEndpoint : IXeroUpdateEndpoint<InvoicesEndpoin...
    method RetrieveOnlineInvoiceUrl (line 18) | OnlineInvoice RetrieveOnlineInvoiceUrl(Guid invoiceId);
    method Ids (line 19) | IInvoicesEndpoint Ids(IEnumerable<Guid> ids);
    method ContactIds (line 20) | IInvoicesEndpoint ContactIds(IEnumerable<Guid> contactIds);
    method Statuses (line 21) | IInvoicesEndpoint Statuses(IEnumerable<InvoiceStatus> statuses);
    method InvoiceNumbers (line 22) | IInvoicesEndpoint InvoiceNumbers(IEnumerable<string> invoiceNumbers);
    method EmailInvoice (line 23) | void EmailInvoice(Guid invoiceId);
    method CreatedByMyApp (line 24) | IInvoicesEndpoint CreatedByMyApp();
  class InvoicesEndpoint (line 27) | public class InvoicesEndpoint
    method InvoicesEndpoint (line 30) | internal InvoicesEndpoint(XeroHttpClient client)
    method Page (line 36) | public IInvoicesEndpoint Page(int page)
    method Ids (line 42) | public IInvoicesEndpoint Ids(IEnumerable<Guid> ids)
    method ContactIds (line 48) | public IInvoicesEndpoint ContactIds(IEnumerable<Guid> contactIds)
    method Statuses (line 54) | public IInvoicesEndpoint Statuses(IEnumerable<InvoiceStatus> statuses)
    method InvoiceNumbers (line 60) | public IInvoicesEndpoint InvoiceNumbers(IEnumerable<string> invoiceNum...
    method EmailInvoice (line 66) | public void EmailInvoice(Guid invoiceId)
    method CreatedByMyApp (line 75) | public IInvoicesEndpoint CreatedByMyApp()
    method ClearQueryString (line 80) | public override void ClearQueryString()
    method RetrieveOnlineInvoiceUrl (line 86) | public OnlineInvoice RetrieveOnlineInvoiceUrl(Guid invoiceId)

FILE: Xero.Api/Core/Endpoints/ItemsEndpoint.cs
  type IItemsEndpoint (line 10) | public interface IItemsEndpoint : IXeroUpdateEndpoint<ItemsEndpoint, Ite...
    method Delete (line 12) | void Delete(Item itemToDelete);
  class ItemsEndpoint (line 15) | public class ItemsEndpoint
    method ItemsEndpoint (line 18) | public ItemsEndpoint(XeroHttpClient client) :
    method Delete (line 23) | public void Delete(Item itemToDelete)
    method HandleResponse (line 32) | private ItemsResponse HandleResponse(Infrastructure.Http.Response resp...

FILE: Xero.Api/Core/Endpoints/JournalsEndpoint.cs
  type IJournalsEndpoint (line 9) | public interface IJournalsEndpoint : IXeroReadEndpoint<JournalsEndpoint,...
    method Offset (line 11) | JournalsEndpoint Offset(int offset);
    method PaymentsOnly (line 13) | JournalsEndpoint PaymentsOnly(bool value);
  class JournalsEndpoint (line 16) | public class JournalsEndpoint : XeroReadEndpoint<JournalsEndpoint, Journ...
    method JournalsEndpoint (line 18) | public JournalsEndpoint(XeroHttpClient client) :
    method Offset (line 23) | public JournalsEndpoint Offset(int offset)
    method PaymentsOnly (line 29) | public JournalsEndpoint PaymentsOnly(bool value)

FILE: Xero.Api/Core/Endpoints/LinkedTransactionsEndpoint.cs
  type ILinkedTransactionsEndpoint (line 12) | public interface ILinkedTransactionsEndpoint : IXeroUpdateEndpoint<Linke...
    method Delete (line 14) | void Delete(LinkedTransaction linkedTransaction);
    method WhereSourceId (line 15) | LinkedTransactionsEndpoint WhereSourceId(Guid sourceId);
    method WhereContactId (line 16) | LinkedTransactionsEndpoint WhereContactId(Guid contactId);
    method WhereTargetId (line 17) | LinkedTransactionsEndpoint WhereTargetId(Guid targetId);
  class LinkedTransactionsEndpoint (line 20) | public class LinkedTransactionsEndpoint
    method LinkedTransactionsEndpoint (line 23) | internal LinkedTransactionsEndpoint(XeroHttpClient client)
    method Delete (line 29) | public void Delete(LinkedTransaction linkedTransaction)
    method Page (line 38) | public ILinkedTransactionsEndpoint Page(int page)
    method WhereSourceId (line 44) | public LinkedTransactionsEndpoint WhereSourceId(Guid sourceId)
    method WhereContactId (line 50) | public LinkedTransactionsEndpoint WhereContactId(Guid contactId)
    method WhereTargetId (line 56) | public LinkedTransactionsEndpoint WhereTargetId(Guid targetId)
    method ClearQueryString (line 62) | public override void ClearQueryString()
    method HandleResponse (line 68) | private LinkedTransactionsResponse HandleResponse(Infrastructure.Http....

FILE: Xero.Api/Core/Endpoints/ManualJournalsEndpoint.cs
  type IManualJournalsEndpoint (line 10) | public interface IManualJournalsEndpoint : IXeroUpdateEndpoint<ManualJou...
  class ManualJournalsEndpoint (line 15) | public class ManualJournalsEndpoint
    method ManualJournalsEndpoint (line 18) | public ManualJournalsEndpoint(XeroHttpClient client) :
    method Page (line 23) | public IManualJournalsEndpoint Page(int page)

FILE: Xero.Api/Core/Endpoints/OrganisationEndpoint.cs
  type IOrganisationEndpoint (line 10) | public interface IOrganisationEndpoint : IXeroReadEndpoint<OrganisationE...
    method GetCisSettings (line 12) | OrganisationCisSetting GetCisSettings(Guid id);
  class OrganisationEndpoint (line 15) | public class OrganisationEndpoint : XeroReadEndpoint<OrganisationEndpoin...
    method OrganisationEndpoint (line 17) | internal OrganisationEndpoint(XeroHttpClient client)
    method GetCisSettings (line 22) | public OrganisationCisSetting GetCisSettings(Guid id)

FILE: Xero.Api/Core/Endpoints/OverpaymentsEndpoint.cs
  type IOverpaymentsEndpoint (line 8) | public interface IOverpaymentsEndpoint : IXeroReadEndpoint<OverpaymentsE...
  class OverpaymentsEndpoint (line 12) | public class OverpaymentsEndpoint : XeroReadEndpoint<OverpaymentsEndpoin...
    method OverpaymentsEndpoint (line 14) | public OverpaymentsEndpoint(XeroHttpClient client)
    method Page (line 20) | public IOverpaymentsEndpoint Page(int page)

FILE: Xero.Api/Core/Endpoints/PaymentsEndpoint.cs
  type IPaymentsEndpoint (line 9) | public interface IPaymentsEndpoint : IXeroUpdateEndpoint<PaymentsEndpoin...
  class PaymentsEndpoint (line 14) | public class PaymentsEndpoint
    method PaymentsEndpoint (line 17) | public PaymentsEndpoint(XeroHttpClient client) :

FILE: Xero.Api/Core/Endpoints/PdfEndpoint.cs
  class PdfEndpoint (line 9) | public class PdfEndpoint
    method PdfEndpoint (line 13) | public PdfEndpoint(XeroHttpClient client)
    method Get (line 18) | public BinaryFile Get(PdfEndpointType type, Guid parent)

FILE: Xero.Api/Core/Endpoints/PrepaymentsEndpoint.cs
  type IPrepaymentsEndpoint (line 8) | public interface IPrepaymentsEndpoint : IXeroReadEndpoint<PrepaymentsEnd...
  class PrepaymentsEndpoint (line 12) | public class PrepaymentsEndpoint : XeroReadEndpoint<PrepaymentsEndpoint,...
    method PrepaymentsEndpoint (line 14) | public PrepaymentsEndpoint(XeroHttpClient client)
    method Page (line 20) | public IPrepaymentsEndpoint Page(int page)

FILE: Xero.Api/Core/Endpoints/PurchaseOrdersEndpoint.cs
  type IPurchaseOrdersEndpoint (line 12) | public interface IPurchaseOrdersEndpoint :
    method Status (line 15) | PurchaseOrdersEndpoint Status(PurchaseOrderStatus status);
    method DateFrom (line 16) | PurchaseOrdersEndpoint DateFrom(DateTime dateFrom);
    method DateTo (line 17) | PurchaseOrdersEndpoint DateTo(DateTime dateTo);
  class PurchaseOrdersEndpoint (line 20) | public class PurchaseOrdersEndpoint : XeroUpdateEndpoint<PurchaseOrdersE...
    method PurchaseOrdersEndpoint (line 22) | public PurchaseOrdersEndpoint(XeroHttpClient client) :
    method Page (line 28) | public IPurchaseOrdersEndpoint Page(int page)
    method Status (line 34) | public PurchaseOrdersEndpoint Status(PurchaseOrderStatus status)
    method DateFrom (line 40) | public PurchaseOrdersEndpoint DateFrom(DateTime dateFrom)
    method DateTo (line 46) | public PurchaseOrdersEndpoint DateTo(DateTime dateTo)
    method ClearQueryString (line 52) | public override void ClearQueryString()

FILE: Xero.Api/Core/Endpoints/ReceiptsEndpoint.cs
  type IReceiptsEndpoint (line 9) | public interface IReceiptsEndpoint : IXeroUpdateEndpoint<ReceiptsEndpoin...
  class ReceiptsEndpoint (line 14) | public class ReceiptsEndpoint
    method ReceiptsEndpoint (line 17) | public ReceiptsEndpoint(XeroHttpClient client)

FILE: Xero.Api/Core/Endpoints/RepeatingInvoicesEndpoint.cs
  type IRepeatingInvoicesEndpoint (line 8) | public interface IRepeatingInvoicesEndpoint : IXeroReadEndpoint<Repeatin...
  class RepeatingInvoicesEndpoint (line 12) | public class RepeatingInvoicesEndpoint
    method RepeatingInvoicesEndpoint (line 15) | public RepeatingInvoicesEndpoint(XeroHttpClient client) :
    method ClearQueryString (line 21) | public override void ClearQueryString()

FILE: Xero.Api/Core/Endpoints/ReportsEndpoint.cs
  type IReportsEndpoint (line 13) | public interface IReportsEndpoint : IXeroReadEndpoint<ReportsEndpoint, R...
    method GetPublishedReport (line 15) | Report GetPublishedReport(string id);
    method GetPublishedReport (line 16) | Report GetPublishedReport(Guid id);
    method AgedPayables (line 19) | Report AgedPayables(Guid contact, DateTime? date = null, DateTime? fro...
    method AgedReceivables (line 20) | Report AgedReceivables(Guid contact, DateTime? date = null, DateTime? ...
    method TenNinetyNine (line 21) | Report TenNinetyNine(DateTime? year);
    method BalanceSheet (line 22) | Report BalanceSheet(DateTime date, Guid? tracking1 = null, Guid? track...
    method BankStatement (line 24) | Report BankStatement(Guid account, DateTime? from = null, DateTime? to...
    method BankSummary (line 25) | Report BankSummary(DateTime? from = null, DateTime? to = null);
    method BudgetSummary (line 26) | Report BudgetSummary(DateTime? date = null, int? periods = null, Budge...
    method ExecutiveSummary (line 27) | Report ExecutiveSummary(DateTime? date = null);
    method ProfitAndLoss (line 28) | Report ProfitAndLoss(DateTime? date = null, DateTime? from = null, Dat...
    method TrailBalance (line 31) | Report TrailBalance(DateTime? date = null, bool? paymentsOnly = null);
  class ReportsEndpoint (line 34) | public class ReportsEndpoint : XeroReadEndpoint<ReportsEndpoint, Report,...
    method ReportsEndpoint (line 36) | public ReportsEndpoint(XeroHttpClient client)
    method GetPublishedReport (line 41) | public Report GetPublishedReport(string id)
    method GetPublishedReport (line 46) | public Report GetPublishedReport(Guid id)
    method TenNinetyNine (line 67) | public Report TenNinetyNine(DateTime? year)
    method AgedPayables (line 78) | public Report AgedPayables(Guid contact, DateTime? date = null, DateTi...
    method AgedReceivables (line 85) | public Report AgedReceivables(Guid contact, DateTime? date = null, Dat...
    method BalanceSheet (line 92) | public Report BalanceSheet(DateTime date, Guid? tracking1 = null, Guid...
    method BankStatement (line 110) | public Report BankStatement(Guid account, DateTime? from = null, DateT...
    method BankSummary (line 123) | public Report BankSummary(DateTime? from = null, DateTime? to = null)
    method BudgetSummary (line 135) | public Report BudgetSummary(DateTime? date = null, int? periods = null...
    method ExecutiveSummary (line 148) | public Report ExecutiveSummary(DateTime? date = null)
    method ProfitAndLoss (line 159) | public Report ProfitAndLoss(DateTime? date = null, DateTime? from = nu...
    method TrailBalance (line 182) | public Report TrailBalance(DateTime? date = null, bool? paymentsOnly =...
    method GetAgedParameters (line 194) | private void GetAgedParameters(Guid contact, DateTime? date, DateTime?...
  class Extensions (line 211) | internal static class Extensions
    method ToReportDate (line 213) | public static string ToReportDate(this DateTime dt)
    method AddYear (line 218) | public static void AddYear(this NameValueCollection collection, string...
    method Add (line 226) | public static void Add(this NameValueCollection collection, string nam...

FILE: Xero.Api/Core/Endpoints/SetupEndpoint.cs
  type ISetupEndpoint (line 8) | public interface ISetupEndpoint
    method Update (line 10) | ImportSummary Update(Setup setup);
    method Create (line 11) | ImportSummary Create(Setup setup);
  class SetupEndpoint (line 14) | public class SetupEndpoint : ISetupEndpoint
    method SetupEndpoint (line 19) | public SetupEndpoint(XeroHttpClient client) :
    method SetupEndpoint (line 24) | protected SetupEndpoint(XeroHttpClient client, string apiEndpointUrl)
    method Update (line 30) | public ImportSummary Update(Setup setup)
    method Create (line 37) | public ImportSummary Create(Setup setup)
    method HandleResponse (line 44) | private ImportSummary HandleResponse(Infrastructure.Http.Response resp...

FILE: Xero.Api/Core/Endpoints/TaxRatesEndpoint.cs
  type ITaxRatesEndpoint (line 9) | public interface ITaxRatesEndpoint : IXeroUpdateEndpoint<TaxRatesEndpoin...
  class TaxRatesEndpoint (line 14) | public class TaxRatesEndpoint
    method TaxRatesEndpoint (line 17) | internal TaxRatesEndpoint(XeroHttpClient client)

FILE: Xero.Api/Core/Endpoints/TrackingCategoriesEndpoint.cs
  type ITrackingCategoriesEndpoint (line 13) | public interface ITrackingCategoriesEndpoint : IXeroUpdateEndpoint<Track...
    method GetAll (line 16) | List<TrackingCategory> GetAll();
    method IncludeArchived (line 17) | TrackingCategoriesEndpoint IncludeArchived(bool include);
    method GetByID (line 18) | TrackingCategory GetByID(Guid id);
    method Delete (line 19) | TrackingCategory Delete(TrackingCategory trackingCategory);
    method DeleteTrackingOption (line 20) | Option DeleteTrackingOption(TrackingCategory trackingCategory, Option ...
    method Add (line 21) | TrackingCategory Add(TrackingCategory trackingCategory);
  class TrackingCategoriesEndpoint (line 24) | public class TrackingCategoriesEndpoint : XeroUpdateEndpoint<TrackingCat...
    method TrackingCategoriesEndpoint (line 26) | public TrackingCategoriesEndpoint(XeroHttpClient client) :
    method IncludeArchived (line 31) | public TrackingCategoriesEndpoint IncludeArchived(bool include)
    method GetByID (line 55) | public TrackingCategory GetByID(Guid id)
    method GetAll (line 64) | public List<TrackingCategory> GetAll()
    method Add (line 73) | public TrackingCategory Add(TrackingCategory trackingCategory)
    method Update (line 85) | public override TrackingCategory Update(TrackingCategory trackingCateg...
    method Delete (line 99) | public TrackingCategory Delete(TrackingCategory trackingCategory)
    method DeleteTrackingOption (line 110) | public Option DeleteTrackingOption(TrackingCategory trackingCategory, ...
    method HandleResponse (line 121) | private TrackingCategoriesResponse HandleResponse(Infrastructure.Http....
    method HandleOptionResponse (line 134) | private OptionsResponse HandleOptionResponse(Infrastructure.Http.Respo...
  type IOptionCollection (line 148) | public interface IOptionCollection :
    method Add (line 152) | List<Option> Add(Option option);
    method Add (line 153) | List<Option> Add(List<Option> options);
    method UpdateOption (line 154) | Option UpdateOption(Option option);
  class OptionCollection (line 157) | public class OptionCollection :
    method OptionCollection (line 163) | public OptionCollection(XeroHttpClient client, TrackingCategory tracki...
    method Add (line 170) | public List<Option> Add(Option option)
    method Add (line 179) | public List<Option> Add(List<Option> options)
    method AssignOptions (line 184) | private List<Option> AssignOptions(TrackingCategory category, List<Opt...
    method HandleResponse (line 195) | private OptionsResponse HandleResponse(Infrastructure.Http.Response re...
    method UpdateOption (line 208) | public Option UpdateOption(Option option)

FILE: Xero.Api/Core/Endpoints/UsersEndpoint.cs
  type IUsersEndpoint (line 8) | public interface IUsersEndpoint : IXeroReadEndpoint<UsersEndpoint, User,...
  class UsersEndpoint (line 12) | public class UsersEndpoint : XeroReadEndpoint<UsersEndpoint, User, Users...
    method UsersEndpoint (line 14) | internal UsersEndpoint(XeroHttpClient client)

FILE: Xero.Api/Core/File/BinaryFile.cs
  class BinaryFile (line 8) | [DataContract(Namespace = "")]
    method BinaryFile (line 13) | public BinaryFile()
    method BinaryFile (line 17) | public BinaryFile(FileInfo fileInfo)
    method BinaryFile (line 34) | public BinaryFile(Stream content, string filename, string contentType,...
    method Save (line 63) | public void Save(string fileName)
    method CopyData (line 77) | private void CopyData(Stream content, string filename, string contentT...

FILE: Xero.Api/Core/IXeroCoreApi.cs
  type IXeroCoreApi (line 9) | public interface IXeroCoreApi
    method Create (line 53) | IEnumerable<Account> Create(IEnumerable<Account> items);
    method Update (line 54) | IEnumerable<Account> Update(IEnumerable<Account> items);
    method Create (line 55) | Account Create(Account item);
    method Update (line 56) | Account Update(Account item);
    method Create (line 59) | IEnumerable<BankTransaction> Create(IEnumerable<BankTransaction> items);
    method Update (line 60) | IEnumerable<BankTransaction> Update(IEnumerable<BankTransaction> items);
    method Create (line 61) | BankTransaction Create(BankTransaction item);
    method Update (line 62) | BankTransaction Update(BankTransaction item);
    method Create (line 65) | IEnumerable<BankTransfer> Create(IEnumerable<BankTransfer> items);
    method Create (line 66) | BankTransfer Create(BankTransfer item);
    method Create (line 69) | IEnumerable<Contact> Create(IEnumerable<Contact> items);
    method Update (line 70) | IEnumerable<Contact> Update(IEnumerable<Contact> items);
    method Create (line 71) | Contact Create(Contact item);
    method Update (line 72) | Contact Update(Contact item);
    method Create (line 75) | IEnumerable<ContactGroup> Create(IEnumerable<ContactGroup> items);
    method Update (line 76) | IEnumerable<ContactGroup> Update(IEnumerable<ContactGroup> items);
    method Create (line 77) | ContactGroup Create(ContactGroup item);
    method Update (line 78) | ContactGroup Update(ContactGroup item);
    method Create (line 81) | IEnumerable<CreditNote> Create(IEnumerable<CreditNote> items);
    method Update (line 82) | IEnumerable<CreditNote> Update(IEnumerable<CreditNote> items);
    method Create (line 83) | CreditNote Create(CreditNote item);
    method Update (line 84) | CreditNote Update(CreditNote item);
    method Create (line 87) | IEnumerable<Employee> Create(IEnumerable<Employee> items);
    method Update (line 88) | IEnumerable<Employee> Update(IEnumerable<Employee> items);
    method Create (line 89) | Employee Create(Employee item);
    method Update (line 90) | Employee Update(Employee item);
    method Create (line 93) | IEnumerable<ExpenseClaim> Create(IEnumerable<ExpenseClaim> items);
    method Update (line 94) | IEnumerable<ExpenseClaim> Update(IEnumerable<ExpenseClaim> items);
    method Create (line 95) | ExpenseClaim Create(ExpenseClaim item);
    method Update (line 96) | ExpenseClaim Update(ExpenseClaim item);
    method Create (line 99) | IEnumerable<Invoice> Create(IEnumerable<Invoice> items);
    method Update (line 100) | IEnumerable<Invoice> Update(IEnumerable<Invoice> items);
    method Create (line 101) | Invoice Create(Invoice item);
    method Update (line 102) | Invoice Update(Invoice item);
    method Create (line 105) | IEnumerable<Item> Create(IEnumerable<Item> items);
    method Update (line 106) | IEnumerable<Item> Update(IEnumerable<Item> items);
    method Create (line 107) | Item Create(Item item);
    method Update (line 108) | Item Update(Item item);
    method Create (line 111) | IEnumerable<LinkedTransaction> Create(IEnumerable<LinkedTransaction> i...
    method Update (line 112) | IEnumerable<LinkedTransaction> Update(IEnumerable<LinkedTransaction> i...
    method Create (line 113) | LinkedTransaction Create(LinkedTransaction item);
    method Update (line 114) | LinkedTransaction Update(LinkedTransaction item);
    method Create (line 117) | IEnumerable<ManualJournal> Create(IEnumerable<ManualJournal> items);
    method Update (line 118) | IEnumerable<ManualJournal> Update(IEnumerable<ManualJournal> items);
    method Create (line 119) | ManualJournal Create(ManualJournal item);
    method Update (line 120) | ManualJournal Update(ManualJournal item);
    method Create (line 124) | IEnumerable<Payment> Create(IEnumerable<Payment> items);
    method Update (line 125) | IEnumerable<Payment> Update(IEnumerable<Payment> items);
    method Create (line 126) | Payment Create(Payment item);
    method Update (line 127) | Payment Update(Payment item);
    method Create (line 130) | IEnumerable<PurchaseOrder> Create(IEnumerable<PurchaseOrder> items);
    method Update (line 131) | IEnumerable<PurchaseOrder> Update(IEnumerable<PurchaseOrder> items);
    method Create (line 132) | PurchaseOrder Create(PurchaseOrder item);
    method Update (line 133) | PurchaseOrder Update(PurchaseOrder item);
    method Create (line 136) | IEnumerable<Receipt> Create(IEnumerable<Receipt> items);
    method Update (line 137) | IEnumerable<Receipt> Update(IEnumerable<Receipt> items);
    method Create (line 138) | Receipt Create(Receipt item);
    method Update (line 139) | Receipt Update(Receipt item);
    method Create (line 142) | ImportSummary Create(Setup item);
    method Update (line 143) | ImportSummary Update(Setup item);
    method Create (line 146) | IEnumerable<TaxRate> Create(IEnumerable<TaxRate> items);
    method Update (line 147) | IEnumerable<TaxRate> Update(IEnumerable<TaxRate> items);
    method Create (line 148) | TaxRate Create(TaxRate item);
    method Update (line 149) | TaxRate Update(TaxRate item);
    method Create (line 152) | IEnumerable<TrackingCategory> Create(IEnumerable<TrackingCategory> ite...
    method Update (line 153) | IEnumerable<TrackingCategory> Update(IEnumerable<TrackingCategory> ite...
    method Create (line 154) | TrackingCategory Create(TrackingCategory item);
    method Update (line 155) | TrackingCategory Update(TrackingCategory item);
    method SummarizeErrors (line 157) | void SummarizeErrors(bool summarize);

FILE: Xero.Api/Core/Model/Account.cs
  class Account (line 9) | [DataContract(Namespace = "")]

FILE: Xero.Api/Core/Model/Address.cs
  class Address (line 7) | [DataContract(Namespace = "")]

FILE: Xero.Api/Core/Model/Allocation.cs
  class Allocation (line 6) | [Obsolete("Use CreditNoteAllocation")]

FILE: Xero.Api/Core/Model/AllocationBase.cs
  class AllocationBase (line 7) | [DataContract(Namespace = "")]

FILE: Xero.Api/Core/Model/Association.cs
  class Association (line 7) | [DataContract(Namespace = "")]
    method ToString (line 22) | public override string ToString()

FILE: Xero.Api/Core/Model/Attachment.cs
  class Attachment (line 9) | [DataContract(Namespace = "")]
    method Attachment (line 12) | public Attachment(FileInfo fileInfo) : base(fileInfo)
    method Attachment (line 16) | public Attachment(Stream content, string filename, string contentType,...

FILE: Xero.Api/Core/Model/Balance.cs
  class Balance (line 6) | [DataContract(Namespace = "")]

FILE: Xero.Api/Core/Model/Balances.cs
  class Balances (line 6) | [DataContract(Namespace = "")]

FILE: Xero.Api/Core/Model/BankTransaction.cs
  class BankTransaction (line 10) | [DataContract(Namespace = "")]

FILE: Xero.Api/Core/Model/BankTransfer.cs
  class BankTransfer (line 7) | [DataContract(Namespace = "")]

FILE: Xero.Api/Core/Model/BatchPayment.cs
  class BatchPayment (line 11) | [DataContract(Namespace = "")]

FILE: Xero.Api/Core/Model/BatchPaymentContactDefaults.cs
  class BatchPaymentContactDefaults (line 6) | [DataContract(Namespace = "", Name = "BatchPayments")]

FILE: Xero.Api/Core/Model/BatchPaymentPayment.cs
  class BatchPaymentPayment (line 7) | [DataContract(Namespace = "", Name = "Payment")]

FILE: Xero.Api/Core/Model/BrandingTheme.cs
  class BrandingTheme (line 7) | [DataContract(Namespace = "")]

FILE: Xero.Api/Core/Model/Contact.cs
  class Contact (line 9) | [DataContract(Namespace = "")]

FILE: Xero.Api/Core/Model/ContactCisSetting.cs
  class ContactCisSetting (line 5) | public class ContactCisSetting

FILE: Xero.Api/Core/Model/ContactGroup.cs
  class ContactGroup (line 8) | [DataContract(Namespace = "")]

FILE: Xero.Api/Core/Model/ContactPerson.cs
  class ContactPerson (line 7) | [DataContract(Namespace = "")]

FILE: Xero.Api/Core/Model/ContactTrackingCategory.cs
  class SalesTrackingCategory (line 6) | [DataContract(Namespace = "")]
  class PurchasesTrackingCategory (line 16) | [DataContract(Namespace = "")]

FILE: Xero.Api/Core/Model/CreditNote.cs
  class CreditNote (line 10) | [DataContract(Namespace = "")]

FILE: Xero.Api/Core/Model/CreditNoteAllocation.cs
  class CreditNoteAllocation (line 5) | [DataContract(Namespace = "", Name = "Allocation")]

FILE: Xero.Api/Core/Model/Currency.cs
  class Currency (line 6) | [DataContract(Namespace = "")]

FILE: Xero.Api/Core/Model/Employee.cs
  class Employee (line 8) | [DataContract(Namespace = "")]

FILE: Xero.Api/Core/Model/EnumExtensions.cs
  class EnumExtensions (line 6) | public static class EnumExtensions
    method GetEnumMemberValue (line 8) | public static string GetEnumMemberValue(this Enum value)

FILE: Xero.Api/Core/Model/ExpenseClaim.cs
  class ExpenseClaim (line 9) | [DataContract(Namespace = "")]

FILE: Xero.Api/Core/Model/ExternalLink.cs
  class ExternalLink (line 7) | [DataContract(Namespace = "")]

FILE: Xero.Api/Core/Model/File.cs
  class File (line 6) | [DataContract(Namespace = "")]

FILE: Xero.Api/Core/Model/FilePage.cs
  class FilePage (line 6) | [DataContract(Namespace = "")]

FILE: Xero.Api/Core/Model/FilesUser.cs
  class FilesUser (line 5) | [DataContract(Namespace = "")]

FILE: Xero.Api/Core/Model/Folder.cs
  class Folder (line 6) | [DataContract(Namespace = "")]

FILE: Xero.Api/Core/Model/HistoryRecord.cs
  class HistoryRecord (line 6) | [DataContract(Namespace = "")]

FILE: Xero.Api/Core/Model/Invoice.cs
  class Invoice (line 10) | [DataContract(Namespace = "")]

FILE: Xero.Api/Core/Model/Item.cs
  class Item (line 7) | [DataContract(Namespace = "")]

FILE: Xero.Api/Core/Model/ItemDetails.cs
  class ItemDetails (line 6) | [DataContract(Namespace = "")]

FILE: Xero.Api/Core/Model/ItemTracking.cs
  class ItemTracking (line 6) | [CollectionDataContract(Namespace = "", Name = "Tracking")]

FILE: Xero.Api/Core/Model/ItemTrackingCategory.cs
  class ItemTrackingCategory (line 7) | [DataContract(Namespace = "", Name = "TrackingCategory")]

FILE: Xero.Api/Core/Model/Journal.cs
  class Journal (line 9) | [DataContract(Namespace = "")]

FILE: Xero.Api/Core/Model/Line.cs
  class Line (line 9) | [DataContract(Name = "JournalLine", Namespace = "")]

FILE: Xero.Api/Core/Model/LineItem.cs
  class LineItem (line 7) | [DataContract(Namespace = "")]

FILE: Xero.Api/Core/Model/LinkedTransaction.cs
  class LinkedTransaction (line 9) | [DataContract(Namespace = "")]

FILE: Xero.Api/Core/Model/ManualJournal.cs
  class ManualJournal (line 10) | [DataContract(Namespace = "")]

FILE: Xero.Api/Core/Model/OnlineInvoice.cs
  class OnlineInvoice (line 5) | [DataContract(Namespace = "")]

FILE: Xero.Api/Core/Model/Option.cs
  class Option (line 8) | [DataContract(Namespace = "")]

FILE: Xero.Api/Core/Model/Organisation.cs
  class Organisation (line 9) | [DataContract(Namespace = "")]

FILE: Xero.Api/Core/Model/OrganisationCisSetting.cs
  class OrganisationCisSetting (line 5) | public class OrganisationCisSetting

FILE: Xero.Api/Core/Model/Overpayment.cs
  class Overpayment (line 10) | [DataContract(Namespace = "")]

FILE: Xero.Api/Core/Model/OverpaymentAllocation.cs
  class OverpaymentAllocation (line 5) | [DataContract(Namespace = "", Name = "Allocation")]

FILE: Xero.Api/Core/Model/Payment.cs
  class Payment (line 9) | [DataContract(Namespace = "")]

FILE: Xero.Api/Core/Model/PaymentTerms.cs
  class PaymentTerms (line 6) | [DataContract(Namespace = "")]

FILE: Xero.Api/Core/Model/Phone.cs
  class Phone (line 7) | [DataContract(Namespace = "")]
    method Phone (line 10) | public Phone()

FILE: Xero.Api/Core/Model/Prepayment.cs
  class Prepayment (line 10) | [DataContract(Namespace = "")]

FILE: Xero.Api/Core/Model/PrepaymentAllocation.cs
  class PrepaymentAllocation (line 5) | [DataContract(Namespace = "", Name = "Allocation")]

FILE: Xero.Api/Core/Model/PurchaseDetails.cs
  class PurchaseDetails (line 5) | [DataContract(Namespace = "")]

FILE: Xero.Api/Core/Model/PurchaseOrder.cs
  class PurchaseOrder (line 10) | [DataContract(Namespace = "")]

FILE: Xero.Api/Core/Model/Receipt.cs
  class Receipt (line 10) | [DataContract(Namespace = "")]

FILE: Xero.Api/Core/Model/RepeatingInvoice.cs
  class RepeatingInvoice (line 10) | [DataContract(Namespace = "")]

FILE: Xero.Api/Core/Model/Reports/Report.cs
  class Report (line 8) | [DataContract(Namespace = "")]

FILE: Xero.Api/Core/Model/Reports/ReportAttribute.cs
  class ReportAttribute (line 5) | [DataContract(Namespace = "")]

FILE: Xero.Api/Core/Model/Reports/ReportCell.cs
  class ReportCell (line 6) | [DataContract(Namespace = "", Name = "Cell")]

FILE: Xero.Api/Core/Model/Reports/ReportCellAttribute.cs
  class ReportCellAttribute (line 5) | [DataContract(Namespace = "", Name = "Attribute")]

FILE: Xero.Api/Core/Model/Reports/ReportField.cs
  class ReportField (line 5) | [DataContract(Namespace = "")]

FILE: Xero.Api/Core/Model/Reports/ReportRow.cs
  class ReportRow (line 6) | [DataContract(Namespace = "", Name = "Row")]

FILE: Xero.Api/Core/Model/SalesDetails.cs
  class SalesDetails (line 5) | [DataContract(Namespace = "")]

FILE: Xero.Api/Core/Model/Schedule.cs
  class Schedule (line 8) | [DataContract(Namespace = "")]

FILE: Xero.Api/Core/Model/Setup/AccountImportResult.cs
  class Accounts (line 5) | [DataContract(Namespace = "")]

FILE: Xero.Api/Core/Model/Setup/ContactImportResult.cs
  class Contacts (line 5) | [DataContract(Namespace = "")]

FILE: Xero.Api/Core/Model/Setup/ConversionBalance.cs
  class ConversionBalance (line 5) | [DataContract(Namespace = "")]

FILE: Xero.Api/Core/Model/Setup/ConversionDate.cs
  class ConversionDate (line 5) | [DataContract(Namespace = "")]

FILE: Xero.Api/Core/Model/Setup/ConversionDetails.cs
  class ConversionDetails (line 5) | [DataContract(Namespace = "")]

FILE: Xero.Api/Core/Model/Setup/ImportSummary.cs
  class ImportSummary (line 5) | [DataContract(Namespace = "")]

FILE: Xero.Api/Core/Model/Setup/OrganisationImportResult.cs
  class Organisation (line 5) | [DataContract(Namespace = "")]

FILE: Xero.Api/Core/Model/Setup/Setup.cs
  class Setup (line 7) | [DataContract(Namespace = "")]

FILE: Xero.Api/Core/Model/Status/AccountStatus.cs
  type AccountStatus (line 5) | [DataContract(Namespace = "")]

FILE: Xero.Api/Core/Model/Status/BankTransactionStatus.cs
  type BankTransactionStatus (line 5) | [DataContract(Namespace = "")]

FILE: Xero.Api/Core/Model/Status/BatchPaymentStatus.cs
  type BatchPaymentStatus (line 5) | [DataContract(Namespace = "")]

FILE: Xero.Api/Core/Model/Status/ContactStatus.cs
  type ContactStatus (line 5) | [DataContract(Namespace = "")]

FILE: Xero.Api/Core/Model/Status/EmployeeStatus.cs
  type EmployeeStatus (line 5) | [DataContract(Namespace = "")]

FILE: Xero.Api/Core/Model/Status/ExpenseClaimStatus.cs
  type ExpenseClaimStatus (line 5) | [DataContract(Namespace = "")]

FILE: Xero.Api/Core/Model/Status/InvoiceStatus.cs
  type InvoiceStatus (line 5) | [DataContract(Namespace = "")]

FILE: Xero.Api/Core/Model/Status/LinkedTransactionStatus.cs
  type LinkedTransactionStatus (line 5) | [DataContract(Namespace = "")]

FILE: Xero.Api/Core/Model/Status/ManualJournalStatus.cs
  type ManualJournalStatus (line 5) | [DataContract(Namespace = "")]

FILE: Xero.Api/Core/Model/Status/OrganisationStatus.cs
  type OrganisationStatus (line 5) | public enum OrganisationStatus

FILE: Xero.Api/Core/Model/Status/OverpaymentStatus.cs
  type OverpaymentStatus (line 5) | [DataContract(Namespace = "")]

FILE: Xero.Api/Core/Model/Status/PaymentStatus.cs
  type PaymentStatus (line 5) | public enum PaymentStatus

FILE: Xero.Api/Core/Model/Status/PrepaymentStatus.cs
  type PrepaymentStatus (line 5) | [DataContract(Namespace = "")]

FILE: Xero.Api/Core/Model/Status/PurchaseOrderStatus.cs
  type PurchaseOrderStatus (line 5) | [DataContract(Namespace = "")]

FILE: Xero.Api/Core/Model/Status/ReceiptStatus.cs
  type ReceiptStatus (line 5) | [DataContract(Namespace = "")]

FILE: Xero.Api/Core/Model/Status/TaxRateStatus.cs
  type TaxRateStatus (line 5) | [DataContract(Namespace = "")]

FILE: Xero.Api/Core/Model/Status/TrackingCategoryStatus.cs
  type TrackingCategoryStatus (line 5) | [DataContract(Namespace = "")]

FILE: Xero.Api/Core/Model/Status/TrackingOptionStatus.cs
  type TrackingOptionStatus (line 5) | [DataContract(Namespace = "")]

FILE: Xero.Api/Core/Model/Status/ValidationStatus.cs
  type ValidationStatus (line 5) | [DataContract(Namespace = "")]

FILE: Xero.Api/Core/Model/TaxComponent.cs
  class TaxComponent (line 6) | [DataContract(Namespace = "")]

FILE: Xero.Api/Core/Model/TaxRate.cs
  class TaxRate (line 9) | [DataContract(Namespace = "")]

FILE: Xero.Api/Core/Model/Terms.cs
  class Terms (line 7) | [DataContract(Namespace = "")]

FILE: Xero.Api/Core/Model/TrackingCategory.cs
  class TrackingCategory (line 9) | [DataContract(Namespace = "")]

FILE: Xero.Api/Core/Model/Types/AccountClassType.cs
  type AccountClassType (line 5) | [DataContract(Namespace = "")]

FILE: Xero.Api/Core/Model/Types/AccountType.cs
  type AccountType (line 5) | [DataContract(Namespace = "")]

FILE: Xero.Api/Core/Model/Types/AddressType.cs
  type AddressType (line 5) | [DataContract(Namespace = "")]

FILE: Xero.Api/Core/Model/Types/AttachmentEndpointType.cs
  type AttachmentEndpointType (line 3) | public enum AttachmentEndpointType

FILE: Xero.Api/Core/Model/Types/BankAccountType.cs
  type BankAccountType (line 9) | [DataContract(Namespace = "")]

FILE: Xero.Api/Core/Model/Types/BankTransactionType.cs
  type BankTransactionType (line 5) | [DataContract(Namespace = "")]

FILE: Xero.Api/Core/Model/Types/BatchPaymentType.cs
  type BatchPaymentType (line 5) | [DataContract(Namespace = "")]

FILE: Xero.Api/Core/Model/Types/BudgetSummaryTimeframeType.cs
  type BudgetSummaryTimeframeType (line 3) | public enum BudgetSummaryTimeframeType

FILE: Xero.Api/Core/Model/Types/CreditNoteType.cs
  type CreditNoteType (line 5) | [DataContract(Namespace = "")]

FILE: Xero.Api/Core/Model/Types/ExternalLinkType.cs
  type ExternalLinkType (line 5) | [DataContract(Namespace = "")]

FILE: Xero.Api/Core/Model/Types/HistoryAndNotesEndpointCreateType.cs
  type HistoryAndNotesEndpointCreateType (line 3) | public enum HistoryAndNotesEndpointCreateType

FILE: Xero.Api/Core/Model/Types/HistoryAndNotesEndpointRetrieveType.cs
  type HistoryAndNotesEndpointRetrieveType (line 3) | public enum HistoryAndNotesEndpointRetrieveType

FILE: Xero.Api/Core/Model/Types/InvoiceType.cs
  type InvoiceType (line 5) | [DataContract(Namespace = "")]

FILE: Xero.Api/Core/Model/Types/LineAmountType.cs
  type LineAmountType (line 5) | [DataContract(Namespace = "")]

FILE: Xero.Api/Core/Model/Types/LinkedTransactionType.cs
  type LinkedTransactionType (line 5) | [DataContract(Namespace = "")]

FILE: Xero.Api/Core/Model/Types/NamedReportType.cs
  type NamedReportType (line 3) | public enum NamedReportType

FILE: Xero.Api/Core/Model/Types/ObjectGroupType.cs
  type ObjectGroupType (line 5) | [DataContract(Namespace = "")]

FILE: Xero.Api/Core/Model/Types/ObjectType.cs
  type ObjectType (line 5) | public enum ObjectType

FILE: Xero.Api/Core/Model/Types/OrganisationClass.cs
  type OrganisationClass (line 5) | [DataContract(Namespace = "")]

FILE: Xero.Api/Core/Model/Types/OrganisationEdition.cs
  type OrganisationEdition (line 5) | [DataContract(Namespace = "")]

FILE: Xero.Api/Core/Model/Types/OrganisationType.cs
  type OrganisationType (line 5) | [DataContract(Namespace = "")]

FILE: Xero.Api/Core/Model/Types/OrganisationVersion.cs
  type OrganisationVersion (line 5) | [DataContract(Namespace = "")]

FILE: Xero.Api/Core/Model/Types/OverpaymentType.cs
  type OverpaymentType (line 5) | [DataContract(Namespace = "")]

FILE: Xero.Api/Core/Model/Types/PaymentTermType.cs
  type PaymentTermType (line 5) | [DataContract(Namespace = "")]

FILE: Xero.Api/Core/Model/Types/PaymentType.cs
  type PaymentType (line 5) | public enum PaymentType

FILE: Xero.Api/Core/Model/Types/PdfEndpointType.cs
  type PdfEndpointType (line 3) | public enum PdfEndpointType

FILE: Xero.Api/Core/Model/Types/PhoneType.cs
  type PhoneType (line 5) | [DataContract(Namespace = "")]

FILE: Xero.Api/Core/Model/Types/PrepaymentType.cs
  type PrepaymentType (line 5) | [DataContract(Namespace = "")]

FILE: Xero.Api/Core/Model/Types/ReportRowType.cs
  type ReportRowType (line 3) | public enum ReportRowType

FILE: Xero.Api/Core/Model/Types/ReportTaxType.cs
  type ReportTaxType (line 5) | [DataContract(Namespace = "")]

FILE: Xero.Api/Core/Model/Types/SalesTaxBasisType.cs
  type SalesTaxBasisType (line 5) | [DataContract]

FILE: Xero.Api/Core/Model/Types/SalesTaxPeriodType.cs
  type SalesTaxPeriodType (line 5) | [DataContract(Namespace = "")]

FILE: Xero.Api/Core/Model/Types/SourceType.cs
  type SourceType (line 9) | [DataContract(Namespace = "")]

FILE: Xero.Api/Core/Model/Types/SystemAccountType.cs
  type SystemAccountType (line 5) | [DataContract(Namespace = "")]

FILE: Xero.Api/Core/Model/Types/UnitType.cs
  type UnitType (line 5) | [DataContract(Namespace = "")]

FILE: Xero.Api/Core/Model/Types/UserRole.cs
  type UserRole (line 5) | [DataContract(Namespace = "")]

FILE: Xero.Api/Core/Model/User.cs
  class User (line 8) | [DataContract(Namespace = "")]

FILE: Xero.Api/Core/Request/AccountsRequest.cs
  class AccountsRequest (line 7) | [CollectionDataContract(Namespace = "", Name = "Accounts")]

FILE: Xero.Api/Core/Request/BankTransactionsRequest.cs
  class BankTransactionsRequest (line 7) | [CollectionDataContract(Namespace = "", Name = "BankTransactions")]

FILE: Xero.Api/Core/Request/BankTransfersRequest.cs
  class BankTransfersRequest (line 7) | [CollectionDataContract(Namespace = "", Name = "BankTransfers")]

FILE: Xero.Api/Core/Request/BatchPaymentsRequest.cs
  class BatchPaymentsRequest (line 7) | [CollectionDataContract(Namespace = "", Name = "BatchPayments")]

FILE: Xero.Api/Core/Request/ContactGroupsRequest.cs
  class ContactGroupsRequest (line 11) | [CollectionDataContract(Namespace = "", Name = "ContactGroups")]

FILE: Xero.Api/Core/Request/ContactsRequest.cs
  class ContactsRequest (line 7) | [CollectionDataContract(Namespace = "", Name = "Contacts")]

FILE: Xero.Api/Core/Request/CreditNotesRequest.cs
  class CreditNotesRequest (line 7) | [CollectionDataContract(Namespace = "", Name = "CreditNotes")]

FILE: Xero.Api/Core/Request/CurrenciesRequest.cs
  class CurrenciesRequest (line 7) | [CollectionDataContract(Namespace = "", Name = "Currencies")]

FILE: Xero.Api/Core/Request/EmployeesRequest.cs
  class EmployeesRequest (line 7) | [CollectionDataContract(Namespace = "", Name = "Employees")]

FILE: Xero.Api/Core/Request/ExpenseClaimsRequest.cs
  class ExpenseClaimsRequest (line 7) | [CollectionDataContract(Namespace = "", Name = "ExpenseClaims")]

FILE: Xero.Api/Core/Request/FilesRequest.cs
  class FilesRequest (line 7) | [CollectionDataContract(Namespace = "", Name = "File")]

FILE: Xero.Api/Core/Request/HistoryRecordsRequest.cs
  class HistoryRecordsRequest (line 7) | [CollectionDataContract(Namespace = "", Name = "HistoryRecords")]

FILE: Xero.Api/Core/Request/InvoicesRequest.cs
  class InvoicesRequest (line 7) | [CollectionDataContract(Namespace = "", Name = "Invoices")]

FILE: Xero.Api/Core/Request/ItemsRequest.cs
  class ItemsRequest (line 7) | [CollectionDataContract(Namespace = "", Name = "Items")]

FILE: Xero.Api/Core/Request/LinkedTransactionsRequest.cs
  class LinkedTransactionsRequest (line 7) | [CollectionDataContract(Namespace = "", Name = "LinkedTransactions")]

FILE: Xero.Api/Core/Request/ManualJournalsRequest.cs
  class ManualJournalsRequest (line 7) | [CollectionDataContract(Namespace = "", Name = "ManualJournals")]

FILE: Xero.Api/Core/Request/OnlineInvoicesRequest.cs
  class OnlineInvoicesRequest (line 8) | [CollectionDataContract(Namespace = "", Name = "OnlineInvoices")]

FILE: Xero.Api/Core/Request/PaymentsRequest.cs
  class PaymentsRequest (line 7) | [CollectionDataContract(Namespace = "", Name = "Payments")]

FILE: Xero.Api/Core/Request/PurchaseOrdersRequest.cs
  class PurchaseOrdersRequest (line 7) | [CollectionDataContract(Namespace = "", Name = "PurchaseOrders")]

FILE: Xero.Api/Core/Request/ReceiptsRequest.cs
  class ReceiptsRequest (line 7) | [CollectionDataContract(Namespace = "", Name = "Receipts")]

FILE: Xero.Api/Core/Request/SetupRequest.cs
  class SetupRequest (line 9) | [DataContract(Namespace = "", Name="Setup")]
    method Add (line 14) | public void Add(Setup value)
    method AddRange (line 19) | public void AddRange(IEnumerable<Setup> value)

FILE: Xero.Api/Core/Request/TaxRatesRequest.cs
  class TaxRatesRequest (line 7) | [CollectionDataContract(Namespace = "", Name = "TaxRates")]

FILE: Xero.Api/Core/Request/TrackingCategoriesRequest.cs
  class TrackingCategoriesRequest (line 11) | [CollectionDataContract(Namespace = "", Name = "TrackingCategories")]

FILE: Xero.Api/Core/Response/AccountsResponse.cs
  class AccountsResponse (line 7) | public class AccountsResponse : XeroResponse<Account>

FILE: Xero.Api/Core/Response/AttachmentsResponse.cs
  class AttachmentsResponse (line 7) | public class AttachmentsResponse : XeroResponse<Attachment>

FILE: Xero.Api/Core/Response/BankTransactionsResponse.cs
  class BankTransactionsResponse (line 7) | public class BankTransactionsResponse : XeroResponse<BankTransaction>

FILE: Xero.Api/Core/Response/BankTransfersResponse.cs
  class BankTransfersResponse (line 7) | public class BankTransfersResponse : XeroResponse<BankTransfer>

FILE: Xero.Api/Core/Response/BatchPaymentsResponse.cs
  class BatchPaymentsResponse (line 7) | public class BatchPaymentsResponse : XeroResponse<BatchPayment>

FILE: Xero.Api/Core/Response/BrandingThemesResponse.cs
  class BrandingThemesResponse (line 7) | public class BrandingThemesResponse : XeroResponse<BrandingTheme>

FILE: Xero.Api/Core/Response/ContactCisSettingsResponse.cs
  class ContactCisSettingsResponse (line 7) | public class ContactCisSettingsResponse : XeroResponse<ContactCisSetting>

FILE: Xero.Api/Core/Response/ContactGroupsResponse.cs
  class ContactGroupsResponse (line 10) | public class ContactGroupsResponse : XeroResponse<ContactGroup>

FILE: Xero.Api/Core/Response/ContactsResponse.cs
  class ContactsResponse (line 7) | public class ContactsResponse : XeroResponse<Contact>

FILE: Xero.Api/Core/Response/CreditNotesResponse.cs
  class CreditNotesResponse (line 8) | [CollectionDataContract(Name = "CreditNotes", Namespace = "")]

FILE: Xero.Api/Core/Response/CurrenciesResponse.cs
  class CurrenciesResponse (line 7) | public class CurrenciesResponse : XeroResponse<Currency>

FILE: Xero.Api/Core/Response/EmployeesResponse.cs
  class EmployeesResponse (line 7) | public class EmployeesResponse : XeroResponse<Employee>

FILE: Xero.Api/Core/Response/ExpenseClaimsResponse.cs
  class ExpenseClaimsResponse (line 7) | public class ExpenseClaimsResponse : XeroResponse<ExpenseClaim>

FILE: Xero.Api/Core/Response/FilesResponse.cs
  class FilesResponse (line 10) | public class FilesResponse : XeroResponse<Model.File>
  class FilePageResponse (line 21) | public class FilePageResponse : XeroResponse<Model.FilePage>

FILE: Xero.Api/Core/Response/FoldersResponse.cs
  class FoldersResponse (line 8) | public class FoldersResponse : XeroResponse<Model.Folder>

FILE: Xero.Api/Core/Response/HistoryRecordsResponse.cs
  class HistoryRecordsResponse (line 7) | public class HistoryRecordsResponse : XeroResponse<HistoryRecord>

FILE: Xero.Api/Core/Response/InboxResponse.cs
  class InboxResponse (line 8) | public class InboxResponse : XeroResponse<Model.FilePage>

FILE: Xero.Api/Core/Response/InvoicesResponse.cs
  class InvoicesResponse (line 7) | public class InvoicesResponse : XeroResponse<Invoice>

FILE: Xero.Api/Core/Response/ItemsResponse.cs
  class ItemsResponse (line 7) | public class ItemsResponse : XeroResponse<Item>

FILE: Xero.Api/Core/Response/JournalsResponse.cs
  class JournalsResponse (line 7) | public class JournalsResponse : XeroResponse<Journal>

FILE: Xero.Api/Core/Response/LinkedTransactionsResponse.cs
  class LinkedTransactionsResponse (line 7) | public class LinkedTransactionsResponse : XeroResponse<LinkedTransaction>

FILE: Xero.Api/Core/Response/ManualJournalsResponse.cs
  class ManualJournalsResponse (line 7) | public class ManualJournalsResponse : XeroResponse<ManualJournal>

FILE: Xero.Api/Core/Response/OnlineInvoicesResponse.cs
  class OnlineInvoicesResponse (line 8) | public class OnlineInvoicesResponse : XeroResponse<OnlineInvoice>

FILE: Xero.Api/Core/Response/OptionsResponse.cs
  class OptionsResponse (line 7) | public class OptionsResponse : XeroResponse<Option>

FILE: Xero.Api/Core/Response/OrganisationCisSettingsResponse.cs
  class OrganisationCisSettingsResponse (line 7) | public class OrganisationCisSettingsResponse : XeroResponse<Organisation...

FILE: Xero.Api/Core/Response/OrganisationResponse.cs
  class OrganisationResponse (line 7) | public class OrganisationResponse : XeroResponse<Organisation>

FILE: Xero.Api/Core/Response/OverpaymentsResponse.cs
  class OverpaymentsResponse (line 7) | public class OverpaymentsResponse : XeroResponse<Overpayment>

FILE: Xero.Api/Core/Response/PaymentsResponse.cs
  class PaymentsResponse (line 7) | public class PaymentsResponse : XeroResponse<Payment>

FILE: Xero.Api/Core/Response/PrepaymentsResponse.cs
  class PrepaymentsResponse (line 7) | public class PrepaymentsResponse : XeroResponse<Prepayment>

FILE: Xero.Api/Core/Response/PurchaseOrdersResponse.cs
  class PurchaseOrdersResponse (line 7) | public class PurchaseOrdersResponse : XeroResponse<PurchaseOrder>

FILE: Xero.Api/Core/Response/ReceiptsResponse.cs
  class ReceiptsResponse (line 7) | public class ReceiptsResponse : XeroResponse<Receipt>

FILE: Xero.Api/Core/Response/RepeatingInvoicesResponse.cs
  class RepeatingInvoicesResponse (line 7) | public class RepeatingInvoicesResponse : XeroResponse<RepeatingInvoice>

FILE: Xero.Api/Core/Response/ReportsResponse.cs
  class ReportsResponse (line 7) | public class ReportsResponse : XeroResponse<Report>

FILE: Xero.Api/Core/Response/SetupResponse.cs
  class SetupResponse (line 7) | [DataContract(Namespace = "")]

FILE: Xero.Api/Core/Response/TaxRatesResponse.cs
  class TaxRatesResponse (line 7) | public class TaxRatesResponse : XeroResponse<TaxRate>

FILE: Xero.Api/Core/Response/TrackingCategoriesResponse.cs
  class TrackingCategoriesResponse (line 7) | public class TrackingCategoriesResponse : XeroResponse<TrackingCategory>

FILE: Xero.Api/Core/Response/UsersResponse.cs
  class UsersResponse (line 7) | public class UsersResponse : XeroResponse<User>

FILE: Xero.Api/Core/XeroCoreApi.cs
  class XeroCoreApi (line 14) | public class XeroCoreApi : XeroApi, IXeroCoreApi
    method XeroCoreApi (line 16) | public XeroCoreApi(string baseUri, IAuthenticator auth, IConsumer cons...
    method XeroCoreApi (line 22) | public XeroCoreApi(string baseUri, IAuthenticator auth, IConsumer cons...
    method XeroCoreApi (line 28) | public XeroCoreApi(string baseUri, IAuthenticator auth, IConsumer cons...
    method XeroCoreApi (line 33) | public XeroCoreApi(string baseUri, IAuthenticator auth, IConsumer cons...
    method Connect (line 76) | private void Connect()
    method Create (line 127) | public IEnumerable<Account> Create(IEnumerable<Account> items)
    method Update (line 132) | public IEnumerable<Account> Update(IEnumerable<Account> items)
    method Create (line 137) | public Account Create(Account item)
    method Update (line 142) | public Account Update(Account item)
    method Create (line 151) | public IEnumerable<BankTransaction> Create(IEnumerable<BankTransaction...
    method Update (line 156) | public IEnumerable<BankTransaction> Update(IEnumerable<BankTransaction...
    method Create (line 161) | public BankTransaction Create(BankTransaction item)
    method Update (line 166) | public BankTransaction Update(BankTransaction item)
    method Create (line 175) | public IEnumerable<BankTransfer> Create(IEnumerable<BankTransfer> items)
    method Create (line 180) | public BankTransfer Create(BankTransfer item)
    method Create (line 189) | public IEnumerable<Contact> Create(IEnumerable<Contact> items)
    method Update (line 194) | public IEnumerable<Contact> Update(IEnumerable<Contact> items)
    method Create (line 199) | public Contact Create(Contact item)
    method Update (line 204) | public Contact Update(Contact item)
    method Create (line 213) | public IEnumerable<ContactGroup> Create(IEnumerable<ContactGroup> items)
    method Update (line 218) | public IEnumerable<ContactGroup> Update(IEnumerable<ContactGroup> items)
    method Create (line 223) | public ContactGroup Create(ContactGroup item)
    method Update (line 228) | public ContactGroup Update(ContactGroup item)
    method Create (line 237) | public IEnumerable<CreditNote> Create(IEnumerable<CreditNote> items)
    method Update (line 242) | public IEnumerable<CreditNote> Update(IEnumerable<CreditNote> items)
    method Create (line 247) | public CreditNote Create(CreditNote item)
    method Update (line 252) | public CreditNote Update(CreditNote item)
    method Create (line 261) | public IEnumerable<Employee> Create(IEnumerable<Employee> items)
    method Update (line 266) | public IEnumerable<Employee> Update(IEnumerable<Employee> items)
    method Create (line 271) | public Employee Create(Employee item)
    method Update (line 276) | public Employee Update(Employee item)
    method Create (line 285) | public IEnumerable<ExpenseClaim> Create(IEnumerable<ExpenseClaim> items)
    method Update (line 290) | public IEnumerable<ExpenseClaim> Update(IEnumerable<ExpenseClaim> items)
    method Create (line 295) | public ExpenseClaim Create(ExpenseClaim item)
    method Update (line 300) | public ExpenseClaim Update(ExpenseClaim item)
    method Create (line 309) | public IEnumerable<Invoice> Create(IEnumerable<Invoice> items)
    method Update (line 314) | public IEnumerable<Invoice> Update(IEnumerable<Invoice> items)
    method Create (line 319) | public Invoice Create(Invoice item)
    method Update (line 324) | public Invoice Update(Invoice item)
    method Create (line 333) | public IEnumerable<Item> Create(IEnumerable<Item> items)
    method Update (line 338) | public IEnumerable<Item> Update(IEnumerable<Item> items)
    method Create (line 343) | public Item Create(Item item)
    method Update (line 348) | public Item Update(Item item)
    method Create (line 357) | public IEnumerable<LinkedTransaction> Create(IEnumerable<LinkedTransac...
    method Update (line 362) | public IEnumerable<LinkedTransaction> Update(IEnumerable<LinkedTransac...
    method Create (line 367) | public LinkedTransaction Create(LinkedTransaction item)
    method Update (line 372) | public LinkedTransaction Update(LinkedTransaction item)
    method Create (line 381) | public IEnumerable<ManualJournal> Create(IEnumerable<ManualJournal> it...
    method Update (line 386) | public IEnumerable<ManualJournal> Update(IEnumerable<ManualJournal> it...
    method Create (line 391) | public ManualJournal Create(ManualJournal item)
    method Update (line 396) | public ManualJournal Update(ManualJournal item)
    method Create (line 405) | public IEnumerable<Payment> Create(IEnumerable<Payment> items)
    method Update (line 410) | public IEnumerable<Payment> Update(IEnumerable<Payment> items)
    method Create (line 415) | public Payment Create(Payment item)
    method Update (line 420) | public Payment Update(Payment item)
    method Create (line 429) | public IEnumerable<PurchaseOrder> Create(IEnumerable<PurchaseOrder> it...
    method Update (line 434) | public IEnumerable<PurchaseOrder> Update(IEnumerable<PurchaseOrder> it...
    method Create (line 439) | public PurchaseOrder Create(PurchaseOrder item)
    method Update (line 444) | public PurchaseOrder Update(PurchaseOrder item)
    method Create (line 453) | public IEnumerable<Receipt> Create(IEnumerable<Receipt> items)
    method Update (line 458) | public IEnumerable<Receipt> Update(IEnumerable<Receipt> items)
    method Create (line 463) | public Receipt Create(Receipt item)
    method Update (line 468) | public Receipt Update(Receipt item)
    method Create (line 477) | public ImportSummary Create(Setup item)
    method Update (line 482) | public ImportSummary Update(Setup item)
    method Create (line 491) | public IEnumerable<TaxRate> Create(IEnumerable<TaxRate> items)
    method Update (line 496) | public IEnumerable<TaxRate> Update(IEnumerable<TaxRate> items)
    method Create (line 501) | public TaxRate Create(TaxRate item)
    method Update (line 506) | public TaxRate Update(TaxRate item)
    method Create (line 515) | public IEnumerable<TrackingCategory> Create(IEnumerable<TrackingCatego...
    method Update (line 520) | public IEnumerable<TrackingCategory> Update(IEnumerable<TrackingCatego...
    method Create (line 525) | public TrackingCategory Create(TrackingCategory item)
    method Update (line 530) | public TrackingCategory Update(TrackingCategory item)
    method SummarizeErrors (line 537) | public void SummarizeErrors(bool summarize)

FILE: Xero.Api/Infrastructure/Exceptions/ApiException.cs
  class ApiException (line 6) | public class ApiException

FILE: Xero.Api/Infrastructure/Exceptions/BadRequestException.cs
  class BadRequestException (line 7) | [Serializable]
    method BadRequestException (line 11) | public BadRequestException() { }
    method BadRequestException (line 13) | public BadRequestException(ApiException apiException)

FILE: Xero.Api/Infrastructure/Exceptions/NotAvailableException.cs
  class NotAvailableException (line 6) | [Serializable]
    method NotAvailableException (line 10) | public NotAvailableException() { }
    method NotAvailableException (line 12) | public NotAvailableException(string body)

FILE: Xero.Api/Infrastructure/Exceptions/NotFoundException.cs
  class NotFoundException (line 6) | [Serializable]
    method NotFoundException (line 10) | public NotFoundException() { }
    method NotFoundException (line 12) | public NotFoundException(string body)

FILE: Xero.Api/Infrastructure/Exceptions/RateExceededException.cs
  class RateExceededException (line 6) | [Serializable]
    method RateExceededException (line 10) | public RateExceededException() { }
    method RateExceededException (line 14) | public RateExceededException(string message) : base(HttpStatusCode.Ser...
    method RateExceededException (line 19) | public RateExceededException(string message, string rateLimitProblem) ...

FILE: Xero.Api/Infrastructure/Exceptions/UnauthorizedException.cs
  class UnauthorizedException (line 6) | [Serializable]
    method UnauthorizedException (line 10) | public UnauthorizedException() { }
    method UnauthorizedException (line 12) | public UnauthorizedException(string body)

FILE: Xero.Api/Infrastructure/Exceptions/ValidationException.cs
  class ValidationException (line 8) | [Serializable]
    method ValidationException (line 12) | public ValidationException() { }
    method ValidationException (line 14) | public ValidationException(ApiException apiException)
    method ToString (line 32) | public override string ToString()

FILE: Xero.Api/Infrastructure/Exceptions/XeroApiException.cs
  class XeroApiException (line 6) | [Serializable]
    method XeroApiException (line 10) | public XeroApiException() { }
    method XeroApiException (line 12) | public XeroApiException(HttpStatusCode statusCode, string body)

FILE: Xero.Api/Infrastructure/Http/HttpClient.cs
  class HttpClient (line 14) | internal class HttpClient
    method HttpClient (line 29) | public HttpClient(string baseUri)
    method HttpClient (line 35) | public HttpClient(string baseUri, IConsumer consumer, IUser user) : th...
    method HttpClient (line 41) | public HttpClient(string baseUri, IAuthenticator auth, IConsumer consu...
    method HttpClient (line 47) | public HttpClient(string baseUri, IAuthenticator auth, IConsumer consu...
    method Post (line 58) | public Response Post(string endpoint, string data, string contentType ...
    method Post (line 63) | public Response Post(string endpoint, byte[] data, string contentType ...
    method PostMultipartForm (line 80) | public Response PostMultipartForm(string endpoint, string contentType,...
    method Put (line 85) | public Response Put(string endpoint, string data, string contentType =...
    method Get (line 102) | public Response Get(string endpoint, string query)
    method GetRaw (line 120) | public Response GetRaw(string endpoint, string mimeType, string query ...
    method Delete (line 138) | public Response Delete(string endpoint)
    method CreateRequest (line 156) | private HttpWebRequest CreateRequest(string endPoint, string method, s...
    method AddHeaders (line 199) | private void AddHeaders(WebRequest request)
    method AddHeader (line 207) | public void AddHeader(string name, string value)
    method WriteData (line 212) | private static void WriteData(byte[] bytes, WebRequest request, string...
    method WriteToServerWithMultipart (line 223) | private Response WriteToServerWithMultipart(string endpoint,string con...
    method WriteMultipartData (line 232) | private void WriteMultipartData(byte[] bytes, HttpWebRequest request, ...
    method WriteToServer (line 253) | private Response WriteToServer(string endpoint, byte[] data, string me...

FILE: Xero.Api/Infrastructure/Http/Response.cs
  class Response (line 9) | internal class Response
    method Response (line 13) | internal Response(HttpWebResponse inner)

FILE: Xero.Api/Infrastructure/Http/XeroHttpClient.cs
  class XeroHttpClient (line 17) | public class XeroHttpClient
    method XeroHttpClient (line 23) | private XeroHttpClient(IJsonObjectMapper jsonMapper, IXmlObjectMapper ...
    method XeroHttpClient (line 30) | public XeroHttpClient(string baseUri, IAuthenticator auth, IConsumer c...
    method XeroHttpClient (line 36) | public XeroHttpClient(string baseUri, IAuthenticator auth, IConsumer c...
    method Get (line 53) | public IEnumerable<TResult> Get<TResult, TResponse>(string endPoint)
    method Post (line 61) | internal IEnumerable<TResult> Post<TResult, TResponse>(string endpoint...
    method Post (line 67) | public IEnumerable<TResult> Post<TResult, TResponse>(string endPoint, ...
    method Put (line 73) | public IEnumerable<TResult> Put<TResult, TResponse>(string endPoint, o...
    method Delete (line 79) | public IEnumerable<TResult> Delete<TResult, TResponse>(string endPoint)
    method Get (line 85) | internal Response Get(string endpoint, string mimeType)
    method Read (line 90) | internal IEnumerable<TResult> Read<TResult, TResponse>(Response response)
    method HandleErrors (line 104) | internal void HandleErrors(Response response)

FILE: Xero.Api/Infrastructure/Interfaces/IAuthenticationToken.cs
  type IAuthenticationToken (line 3) | public interface IAuthenticationToken

FILE: Xero.Api/Infrastructure/Interfaces/IAuthenticator.cs
  type IAuthenticator (line 5) | public interface IAuthenticator
    method GetSignature (line 7) | string GetSignature(IConsumer consumer, IUser user, Uri uri, string ve...
    method GetToken (line 8) | IToken GetToken(IConsumer consumer, IUser user);

FILE: Xero.Api/Infrastructure/Interfaces/IConsumer.cs
  type IConsumer (line 5) | public interface IConsumer
  type IToken (line 11) | public interface IToken

FILE: Xero.Api/Infrastructure/Interfaces/IJsonObjectMapper.cs
  type IJsonObjectMapper (line 3) | public interface IJsonObjectMapper
    method From (line 5) | T From<T>(string result);
    method To (line 6) | string To<T>(T request);

FILE: Xero.Api/Infrastructure/Interfaces/ITokenStore.cs
  type ITokenStore (line 3) | public interface ITokenStore
    method Find (line 5) | IToken Find(string user);
    method Add (line 6) | void Add(IToken token);
    method Delete (line 7) | void Delete(IToken token);

FILE: Xero.Api/Infrastructure/Interfaces/IUser.cs
  type IUser (line 3) | public interface IUser

FILE: Xero.Api/Infrastructure/Interfaces/IXeroRequest.cs
  type IXeroRequest (line 5) | public interface IXeroRequest<T>
    method Add (line 8) | void Add(T value);
    method AddRange (line 9) | void AddRange(IEnumerable<T> value);

FILE: Xero.Api/Infrastructure/Interfaces/IXeroResponse.cs
  type IXeroResponse (line 5) | public interface IXeroResponse<T>

FILE: Xero.Api/Infrastructure/Interfaces/IXmlObjectMapper.cs
  type IXmlObjectMapper (line 3) | public interface IXmlObjectMapper
    method From (line 5) | T From<T>(string result);
    method To (line 6) | string To<T>(T request);

FILE: Xero.Api/Infrastructure/Model/DataContractBase.cs
  class DataContractBase (line 6) | [DataContract(Namespace = "")]

FILE: Xero.Api/Infrastructure/Model/ValidationError.cs
  class ValidationError (line 5) | [DataContract(Namespace = "")]

FILE: Xero.Api/Infrastructure/Model/Warning.cs
  class Warning (line 5) | [DataContract(Namespace = "")]

FILE: Xero.Api/Infrastructure/OAuth/ApiUser.cs
  class ApiUser (line 5) | public class ApiUser : IUser

FILE: Xero.Api/Infrastructure/OAuth/Consumer.cs
  class Consumer (line 5) | public class Consumer : IConsumer
    method Consumer (line 8) | public Consumer()
    method Consumer (line 12) | public Consumer(string consumerKey, string consumerSecret)

FILE: Xero.Api/Infrastructure/OAuth/OAuthException.cs
  class OAuthException (line 5) | public class OAuthException : Exception
    method OAuthException (line 7) | public OAuthException(string message) : base (message)

FILE: Xero.Api/Infrastructure/OAuth/OAuthTokens.cs
  class OAuthTokens (line 9) | public class OAuthTokens
    method OAuthTokens (line 17) | public OAuthTokens(string authorizeUri, string tokenUri)
    method GetRequestToken (line 52) | public IToken GetRequestToken(IConsumer consumer, string header)
    method GetAccessToken (line 57) | public IToken GetAccessToken(IToken token, string header)
    method RenewAccessToken (line 62) | public IToken RenewAccessToken(IToken token, string header)
    method GetToken (line 67) | public IToken GetToken(string baseUri, IToken consumer, string endPoin...

FILE: Xero.Api/Infrastructure/OAuth/Signing/HmacSha1Signer.cs
  class HmacSha1Signer (line 12) | public class HmacSha1Signer
    method CreateSignature (line 14) | public string CreateSignature(IToken token, Uri uri, string verb, stri...

FILE: Xero.Api/Infrastructure/OAuth/Signing/RsaSha1Signer.cs
  class RsaSha1Signer (line 13) | public class RsaSha1Signer
    method CreateSignature (line 15) | public string CreateSignature(X509Certificate2 certificate, IToken tok...

FILE: Xero.Api/Infrastructure/OAuth/Token.cs
  class Token (line 6) | public class Token : IToken
    method Token (line 9) | public Token()
    method Token (line 13) | public Token(string consumerKey, string consumerSecret)

FILE: Xero.Api/Infrastructure/OAuth/UnexpectedOauthResponseException.cs
  class UnexpectedOauthResponseException (line 6) | public class UnexpectedOauthResponseException : Exception
    method UnexpectedOauthResponseException (line 11) | public UnexpectedOauthResponseException(HttpStatusCode responseStatusC...

FILE: Xero.Api/Infrastructure/RateLimiter/IRateLimiter.cs
  type IRateLimiter (line 8) | public interface IRateLimiter
    method WaitUntilLimit (line 10) | void WaitUntilLimit();
    method CheckLimit (line 12) | bool CheckLimit();

FILE: Xero.Api/Infrastructure/RateLimiter/RateLimiter.cs
  class RateLimiter (line 9) | public class RateLimiter : IRateLimiter
    method RateLimiter (line 20) | public RateLimiter(TimeSpan duration, int qty)
    method RateLimiter (line 27) | public RateLimiter() : this(TimeSpan.FromMinutes(1), 60) { }
    method WaitUntilLimit (line 32) | public void WaitUntilLimit()
    method CheckLimit (line 48) | public bool CheckLimit()

FILE: Xero.Api/Infrastructure/ThirdParty/Dust/ConsumerKey.cs
  class ConsumerKey (line 3) | public class ConsumerKey
    method ConsumerKey (line 7) | public ConsumerKey(string value)

FILE: Xero.Api/Infrastructure/ThirdParty/Dust/Core/Request.cs
  class Request (line 5) | public class Request {

FILE: Xero.Api/Infrastructure/ThirdParty/Dust/Core/SignatureBaseString.cs
  class SignatureBaseString (line 6) | public class SignatureBaseString {
    method SignatureBaseString (line 10) | public SignatureBaseString(Request request, OAuthParameters oAuthParam...

FILE: Xero.Api/Infrastructure/ThirdParty/Dust/Core/SignatureBaseStringParts/Earl/EarlPart.cs
  class EarlPart (line 5) | internal class EarlPart {
    method EarlPart (line 8) | internal EarlPart(Uri uri) {
    method Path (line 18) | private string Path() {
    method Escape (line 22) | private string Escape(string what) {

FILE: Xero.Api/Infrastructure/ThirdParty/Dust/Core/SignatureBaseStringParts/Parameters/Name.cs
  class Name (line 3) | class Name
    method Name (line 18) | internal Name(string value)

FILE: Xero.Api/Infrastructure/ThirdParty/Dust/Core/SignatureBaseStringParts/Parameters/Nonce/DefaultNonceSequence.cs
  class DefaultNonceSequence (line 4) | public class DefaultNonceSequence : NonceSequence {
    method Next (line 5) | public string Next() {

FILE: Xero.Api/Infrastructure/ThirdParty/Dust/Core/SignatureBaseStringParts/Parameters/Nonce/NonceSequence.cs
  type NonceSequence (line 2) | public interface NonceSequence {
    method Next (line 3) | string Next();

FILE: Xero.Api/Infrastructure/ThirdParty/Dust/Core/SignatureBaseStringParts/Parameters/OAuthParameters.cs
  class OAuthParameters (line 7) | public class OAuthParameters
    method OAuthParameters (line 28) | public OAuthParameters(
    method List (line 56) | internal Parameters List() {
    method SetSignature (line 99) | public void SetSignature(string what) {

FILE: Xero.Api/Infrastructure/ThirdParty/Dust/Core/SignatureBaseStringParts/Parameters/Parameter.cs
  type Parameter (line 3) | internal struct Parameter
    method Parameter (line 8) | internal Parameter(string name, string value)
    method ToString (line 24) | public override string ToString()
    method Escape (line 29) | private string Escape(string what)

FILE: Xero.Api/Infrastructure/ThirdParty/Dust/Core/SignatureBaseStringParts/Parameters/ParameterEncoding.cs
  class ParameterEncoding (line 6) | internal class ParameterEncoding
    method Escape (line 8) | internal string Escape(string what)

FILE: Xero.Api/Infrastructure/ThirdParty/Dust/Core/SignatureBaseStringParts/Parameters/ParameterPart.cs
  class ParameterPart (line 5) | internal class ParameterPart {
    method ParameterPart (line 9) | internal ParameterPart(Request request, OAuthParameters oAuthParameter...
    method Escape (line 20) | private string Escape(string what) {

FILE: Xero.Api/Infrastructure/ThirdParty/Dust/Core/SignatureBaseStringParts/Parameters/Parameters.cs
  class Parameters (line 7) | internal class Parameters : IEnumerable<Parameter> {
    method Parameters (line 10) | internal Parameters(params Parameter[] parameters) {
    method Add (line 14) | internal void Add(params Parameter[] parameter) {
    method Add (line 19) | internal void Add(IEnumerable<Parameter> parameters) {
    method Sort (line 24) | private void Sort() {
    method ToString (line 28) | public override string ToString() {
    method GetEnumerator (line 32) | public IEnumerator<Parameter> GetEnumerator() {
    method GetEnumerator (line 36) | IEnumerator IEnumerable.GetEnumerator() {
    class ParameterComparison (line 40) | private class ParameterComparison : IComparer<Parameter> {
      method Compare (line 41) | public int Compare(Parameter x, Parameter y) {
      method CompareValues (line 49) | private int CompareValues(Parameter x, Parameter y) {
      method CompareCore (line 53) | private int CompareCore(string x, string y) {

FILE: Xero.Api/Infrastructure/ThirdParty/Dust/Core/SignatureBaseStringParts/Parameters/RequestParameters.cs
  class RequestParameters (line 9) | internal class RequestParameters : IEnumerable<Parameter>
    method RequestParameters (line 14) | public RequestParameters(Request request)
    method MapAll (line 21) | private Parameter[] MapAll() {
    method Map (line 25) | private IEnumerable<Parameter> Map(string key)
    method ValuesFor (line 30) | private string[] ValuesFor(string key) {
    method GetEnumerator (line 36) | IEnumerator IEnumerable.GetEnumerator() {
    method GetEnumerator (line 40) | public IEnumerator<Parameter> GetEnumerator() {
    method Add (line 46) | internal void Add(Parameters what) {
    method ToString (line 50) | public override string ToString() {

FILE: Xero.Api/Infrastructure/ThirdParty/Dust/Core/SignatureBaseStringParts/Parameters/Timestamp/DefaultTimestampSequence.cs
  class DefaultTimestampSequence (line 4) | public class DefaultTimestampSequence : TimestampSequence {
    method Next (line 5) | public string Next() {

FILE: Xero.Api/Infrastructure/ThirdParty/Dust/Core/SignatureBaseStringParts/Parameters/Timestamp/TimestampSequence.cs
  type TimestampSequence (line 2) | public interface TimestampSequence {
    method Next (line 3) | string Next();

FILE: Xero.Api/Infrastructure/ThirdParty/Dust/Core/SignatureBaseStringParts/Verb/VerbPart.cs
  class VerbPart (line 2) | internal class VerbPart {
    method VerbPart (line 5) | public VerbPart(Request request) {

FILE: Xero.Api/Infrastructure/ThirdParty/Dust/HmacSha1.cs
  class HmacSha1 (line 8) | public class HmacSha1
    method Sign (line 10) | public string Sign(string signatureBaseString, string consumerSecret, ...
    method Key (line 19) | private string Key(string consumerSecret, string tokenSecret)
    method Escape (line 24) | private string Escape(string what)
    method Base64Encode (line 29) | private string Base64Encode(byte[] bytes)
    method SignCore (line 34) | private byte[] SignCore(string text, string key)

FILE: Xero.Api/Infrastructure/ThirdParty/Dust/Http/AuthorizationHeader.cs
  class AuthorizationHeader (line 5) | public class AuthorizationHeader {
    method AuthorizationHeader (line 10) | public AuthorizationHeader(OAuthParameters oAuthParameters, string rea...
    method Join (line 37) | private string Join(params string[] bits) {
    method ToString (line 108) | private string ToString(Parameter parameter) {
    method Escape (line 117) | private string Escape(string value) {

FILE: Xero.Api/Infrastructure/ThirdParty/Dust/Lang/ObjectExtensions.cs
  class ObjectExtensions (line 5) | public static class ObjectExtensions
    method Tap (line 7) | public static T Tap<T>(this T self, Action<T> block)

FILE: Xero.Api/Infrastructure/ThirdParty/Dust/RsaSha1.cs
  class RsaSha1 (line 10) | public class RsaSha1
    method RsaSha1 (line 14) | public RsaSha1(X509Certificate2 certificate)
    method Sign (line 19) | public string Sign(string signatureBaseString)
    method SignCore (line 24) | string SignCore(string baseString)
    method Base64Encode (line 32) | private static string Base64Encode(byte[] signature)
    method Sign (line 37) | private byte[] Sign(SHA1CryptoServiceProvider hash)
    method Hash (line 45) | SHA1CryptoServiceProvider Hash(string signatureBaseString)

FILE: Xero.Api/Infrastructure/ThirdParty/Dust/TokenKey.cs
  class TokenKey (line 3) | public class TokenKey
    method TokenKey (line 7) | public TokenKey(string value)

FILE: Xero.Api/Infrastructure/ThirdParty/HttpUtility/HttpEncoder.cs
  class HttpEncoder (line 41) | public static class HttpEncoder
    method InitEntities (line 61) | private static void InitEntities()
    method UrlPathEncode (line 322) | public static string UrlPathEncode (string value)
    method UrlEncodeToBytes (line 335) | internal static byte[] UrlEncodeToBytes(byte[] bytes, int offset, int ...
    method UrlEncodeChar (line 358) | internal static void UrlEncodeChar(char c, Stream result, bool isUnicode)
    method NotEncoded (line 412) | internal static bool NotEncoded(char c)
    method UrlPathEncodeChar (line 417) | internal static void UrlPathEncodeChar(char c, Stream result)
    method HtmlDecode (line 441) | public static void HtmlDecode(string value, TextWriter output)
    method HtmlDecode (line 449) | public static string HtmlDecode(string s)
    method HtmlEncode (line 609) | public static string HtmlEncode(string s)
    method HtmlEncode (line 678) | public static void HtmlEncode(string value, TextWriter output)
    method UrlEncode (line 686) | public static byte[] UrlEncode(byte[] bytes, int offset, int count)

FILE: Xero.Api/Infrastructure/ThirdParty/HttpUtility/HttpUtility.cs
  class HttpUtility (line 43) | [AspNetHostingPermission (SecurityAction.LinkDemand, Level = AspNetHosti...
    class HttpQsCollection (line 46) | sealed class HttpQsCollection : NameValueCollection
      method ToString (line 48) | public override string ToString ()
    method UrlDecode (line 64) | public static string UrlDecode (string str)
    method WriteCharBytes (line 69) | static void WriteCharBytes(IList buf, char ch, Encoding e)
    method UrlDecode (line 80) | public static string UrlDecode(string s, Encoding e)
    method GetInt (line 136) | static int GetInt(byte b)
    method GetChar (line 151) | static int GetChar(string str, int offset, int length)
    method HtmlDecode (line 170) | public static string HtmlDecode (string s)
    method UrlEncode (line 182) | public static string UrlEncode(string str)
    method UrlEncode (line 187) | public static string UrlEncode(string s, Encoding Enc)
    method UrlEncode (line 219) | public static string UrlEncode(byte[] bytes)
    method UrlEncode (line 230) | public static string UrlEncode(byte[] bytes, int offset, int count)
    method UrlEncodeToBytes (line 241) | public static byte[] UrlEncodeToBytes(string str)
    method UrlEncodeToBytes (line 246) | public static byte[] UrlEncodeToBytes(string str, Encoding e)
    method UrlEncodeToBytes (line 258) | public static byte[] UrlEncodeToBytes(byte[] bytes)
    method UrlEncodeToBytes (line 269) | public static byte[] UrlEncodeToBytes(byte[] bytes, int offset, int co...
    method ParseQueryString (line 276) | public static NameValueCollection ParseQueryString (string query)
    method ParseQueryString (line 281) | public static NameValueCollection ParseQueryString (string query, Enco...
    method ParseQueryString (line 297) | public static void ParseQueryString (string query, Encoding encoding, ...

FILE: Xero.Api/Infrastructure/ThirdParty/HttpUtility/UrlEncoder.cs
  class UrlEncoder (line 6) | public static class UrlEncoder
    method UrlEncode (line 10) | public static string UrlEncode(string value)

FILE: Xero.Api/Infrastructure/ThirdParty/ServiceStack.Text/AssemblyUtils.cs
  class AssemblyUtils (line 18) | public static class AssemblyUtils
    method FindType (line 33) | public static Type FindType(string typeName)
    method MainInterface (line 69) | public static Type MainInterface<T>()
    method FindType (line 94) | public static Type FindType(string typeName, string assemblyName)
    class AppDomain (line 123) | private sealed class AppDomain
      method AppDomain (line 128) | static AppDomain()
      method GetAssemblies (line 133) | public Assembly[] GetAssemblies()
      method GetAssemblyListAsync (line 138) | private async System.Threading.Tasks.Task<IEnumerable<Assembly>> Get...
    method FindTypeFromLoadedAssemblies (line 169) | public static Type FindTypeFromLoadedAssemblies(string typeName)
    method LoadAssembly (line 189) | private static Assembly LoadAssembly(string assemblyPath)
    method LoadAssembly (line 194) | private static Assembly LoadAssembly(string assemblyPath)
    method LoadAssembly (line 199) | private static Assembly LoadAssembly(string assemblyPath)
    method LoadAssembly (line 204) | private static Assembly LoadAssembly(string assemblyPath)
    method GetAssemblyBinPath (line 214) | public static string GetAssemblyBinPath(Assembly assembly)
    method ToTypeString (line 241) | public static string ToTypeString(this Type type)
    method WriteType (line 246) | public static string WriteType(Type type)

FILE: Xero.Api/Infrastructure/ThirdParty/ServiceStack.Text/CollectionExtensions.cs
  class CollectionExtensions (line 9) | public static class CollectionExtensions
    method CreateAndPopulate (line 11) | public static ICollection<T> CreateAndPopulate<T>(Type ofCollectionTyp...
    method ToArray (line 34) | public static T[] ToArray<T>(this ICollection<T> collection)
    method Convert (line 41) | public static object Convert<T>(object objCollection, Type toCollectio...

FILE: Xero.Api/Infrastructure/ThirdParty/ServiceStack.Text/Common/DateTimeSerializer.cs
  class DateTimeSerializer (line 22) | public static class DateTimeSerializer
    method Prepare (line 49) | private static DateTime Prepare(this DateTime dateTime, bool parsedAsU...
    method ParseShortestNullableXsdDateTime (line 58) | public static DateTime? ParseShortestNullableXsdDateTime(string dateTi...
    method ParseShortestXsdDateTime (line 66) | public static DateTime ParseShortestXsdDateTime(string dateTimeStr)
    method RepairXsdTimeSeparator (line 124) | private static string RepairXsdTimeSeparator(string dateTimeStr)
    method ParseManual (line 135) | public static DateTime? ParseManual(string dateTimeStr)
    method ToDateTimeString (line 224) | public static string ToDateTimeString(DateTime dateTime)
    method ParseDateTime (line 229) | public static DateTime ParseDateTime(string dateTimeStr)
    method ParseDateTimeOffset (line 234) | public static DateTimeOffset ParseDateTimeOffset(string dateTimeOffset...
    method ParseDateTimeOffsetNullable (line 260) | public static DateTimeOffset? ParseDateTimeOffsetNullable(string dateT...
    method ToXsdDateTimeString (line 267) | public static string ToXsdDateTimeString(DateTime dateTime)
    method ToXsdTimeSpanString (line 276) | public static string ToXsdTimeSpanString(TimeSpan timeSpan)
    method ToXsdTimeSpanString (line 286) | public static string ToXsdTimeSpanString(TimeSpan? timeSpan)
    method ParseXsdDateTime (line 291) | public static DateTime ParseXsdDateTime(string dateTimeStr)
    method ParseTimeSpan (line 302) | public static TimeSpan ParseTimeSpan(string dateTimeStr)
    method ParseXsdTimeSpan (line 309) | public static TimeSpan ParseXsdTimeSpan(string dateTimeStr)
    method ParseNullableTimeSpan (line 314) | public static TimeSpan? ParseNullableTimeSpan(string dateTimeStr)
    method ParseXsdNullableTimeSpan (line 321) | public static TimeSpan? ParseXsdNullableTimeSpan(string dateTimeStr)
    method ToShortestXsdDateTimeString (line 328) | public static string ToShortestXsdDateTimeString(DateTime dateTime)
    method ParseWcfJsonDateOffset (line 352) | public static DateTimeOffset ParseWcfJsonDateOffset(string wcfJsonDate)
    method ParseWcfJsonDate (line 397) | public static DateTime ParseWcfJsonDate(string wcfJsonDate)
    method WriteWcfJsonDate (line 437) | public static void WriteWcfJsonDate(TextWriter writer, DateTime dateTime)
    method ToWcfJsonDate (line 476) | public static string ToWcfJsonDate(DateTime dateTime)
    method WriteWcfJsonDateTimeOffset (line 486) | public static void WriteWcfJsonDateTimeOffset(TextWriter writer, DateT...
    method ToWcfJsonDateTimeOffset (line 508) | public static string ToWcfJsonDateTimeOffset(DateTimeOffset dateTimeOf...

FILE: Xero.Api/Infrastructure/ThirdParty/ServiceStack.Text/Common/DeserializeArray.cs
  class DeserializeArrayWithElements (line 20) | internal static class DeserializeArrayWithElements<TSerializer>
    method GetParseFn (line 28) | public static Func<string, ParseStringDelegate, object> GetParseFn(Typ...
    method ParseGenericArray (line 61) | public static T[] ParseGenericArray(string value, ParseStringDelegate ...
  class DeserializeArrayWithElements (line 56) | internal static class DeserializeArrayWithElements<T, TSerializer>
    method GetParseFn (line 28) | public static Func<string, ParseStringDelegate, object> GetParseFn(Typ...
    method ParseGenericArray (line 61) | public static T[] ParseGenericArray(string value, ParseStringDelegate ...
  class DeserializeArray (line 108) | internal static class DeserializeArray<TSerializer>
    method GetParseFn (line 113) | public static ParseStringDelegate GetParseFn(Type type)
    method DeserializeArray (line 146) | static DeserializeArray()
    method GetParseFn (line 156) | public static ParseStringDelegate GetParseFn()
    method ParseStringArray (line 177) | public static string[] ParseStringArray(string value)
    method ParseByteArray (line 185) | public static byte[] ParseByteArray(string value)
  class DeserializeArray (line 139) | internal static class DeserializeArray<T, TSerializer>
    method GetParseFn (line 113) | public static ParseStringDelegate GetParseFn(Type type)
    method DeserializeArray (line 146) | static DeserializeArray()
    method GetParseFn (line 156) | public static ParseStringDelegate GetParseFn()
    method ParseStringArray (line 177) | public static string[] ParseStringArray(string value)
    method ParseByteArray (line 185) | public static byte[] ParseByteArray(string value)

FILE: Xero.Api/Infrastructure/ThirdParty/ServiceStack.Text/Common/DeserializeBuiltin.cs
  class DeserializeBuiltin (line 18) | public static class DeserializeBuiltin<T>
    method DeserializeBuiltin (line 21) | static DeserializeBuiltin()
    method GetParseFn (line 31) | private static ParseStringDelegate GetParseFn()

FILE: Xero.Api/Infrastructure/ThirdParty/ServiceStack.Text/Common/DeserializeCollection.cs
  class DeserializeCollection (line 23) | internal static class DeserializeCollection<TSerializer>
    method GetParseMethod (line 28) | public static ParseStringDelegate GetParseMethod(Type type)
    method ParseStringCollection (line 54) | public static ICollection<string> ParseStringCollection(string value, ...
    method ParseIntCollection (line 60) | public static ICollection<int> ParseIntCollection(string value, Type c...
    method ParseCollection (line 66) | public static ICollection<T> ParseCollection<T>(string value, Type cre...
    method ParseCollectionType (line 79) | public static object ParseCollectionType(string value, Type createType...

FILE: Xero.Api/Infrastructure/ThirdParty/ServiceStack.Text/Common/DeserializeDictionary.cs
  class DeserializeDictionary (line 22) | internal static class DeserializeDictionary<TSerializer>
    method GetParseMethod (line 30) | public static ParseStringDelegate GetParseMethod(Type type)
    method ParseJsonObject (line 71) | public static JsonObject ParseJsonObject(string value)
    method ParseHashtable (line 99) | public static Hashtable ParseHashtable(string value)
    method ParseStringDictionary (line 127) | public static Dictionary<string, string> ParseStringDictionary(string ...
    method ParseDictionary (line 154) | public static IDictionary<TKey, TValue> ParseDictionary<TKey, TValue>(
    method VerifyAndGetStartIndex (line 225) | private static int VerifyAndGetStartIndex(string value, Type createMap...
    method ParseDictionaryType (line 243) | public static object ParseDictionaryType(string value, Type createMapT...
    method GetTypesKey (line 269) | private static string GetTypesKey(params Type[] types)

FILE: Xero.Api/Infrastructure/ThirdParty/ServiceStack.Text/Common/DeserializeDynamic.cs
  class DeserializeDynamic (line 20) | internal static class DeserializeDynamic<TSerializer>
    method DeserializeDynamic (line 26) | static DeserializeDynamic()
    method ParseDynamic (line 36) | public static IDynamicMetaObjectProvider ParseDynamic(string value)
    method VerifyAndGetStartIndex (line 73) | private static int VerifyAndGetStartIndex(string value, Type createMap...

FILE: Xero.Api/Infrastructure/ThirdParty/ServiceStack.Text/Common/DeserializeKeyValuePair.cs
  class DeserializeKeyValuePair (line 22) | internal static class DeserializeKeyValuePair<TSerializer>
    method GetParseMethod (line 30) | public static ParseStringDelegate GetParseMethod(Type type)
    method ParseKeyValuePair (line 47) | public static object ParseKeyValuePair<TKey, TValue>(
    method VerifyAndGetStartIndex (line 78) | private static int VerifyAndGetStartIndex(string value, Type createMap...
    method ParseKeyValuePairType (line 96) | public static object ParseKeyValuePairType(string value, Type createMa...
    method GetTypesKey (line 122) | private static string GetTypesKey(params Type[] types)

FILE: Xero.Api/Infrastructure/ThirdParty/ServiceStack.Text/Common/DeserializeListWithElements.cs
  class DeserializeListWithElements (line 20) | internal static class DeserializeListWithElements<TSerializer>
    method GetListTypeParseFn (line 30) | public static Func<string, Type, ParseStringDelegate, object> GetListT...
    method StripList (line 54) | internal static string StripList(string value)
    method ParseStringList (line 70) | public static List<string> ParseStringList(string value)
    method ParseIntList (line 95) | public static List<int> ParseIntList(string value)
    method ParseGenericList (line 115) | public static ICollection<T> ParseGenericList(string value, Type creat...
  class DeserializeListWithElements (line 110) | internal static class DeserializeListWithElements<T, TSerializer>
    method GetListTypeParseFn (line 30) | public static Func<string, Type, ParseStringDelegate, object> GetListT...
    method StripList (line 54) | internal static string StripList(string value)
    method ParseStringList (line 70) | public static List<string> ParseStringList(string value)
    method ParseIntList (line 95) | public static List<int> ParseIntList(string value)
    method ParseGenericList (line 115) | public static ICollection<T> ParseGenericList(string value, Type creat...
  class DeserializeList (line 187) | internal static class DeserializeList<T, TSerializer>
    method DeserializeList (line 192) | static DeserializeList()
    method GetParseFn (line 202) | public static ParseStringDelegate GetParseFn()
  class DeserializeEnumerable (line 232) | internal static class DeserializeEnumerable<T, TSerializer>
    method DeserializeEnumerable (line 237) | static DeserializeEnumerable()
    method GetParseFn (line 247) | public static ParseStringDelegate GetParseFn()

FILE: Xero.Api/Infrastructure/ThirdParty/ServiceStack.Text/Common/DeserializeSpecializedCollections.cs
  class DeserializeSpecializedCollections (line 8) | internal static class DeserializeSpecializedCollections<T, TSerializer>
    method DeserializeSpecializedCollections (line 13) | static DeserializeSpecializedCollections()
    method GetParseFn (line 23) | public static ParseStringDelegate GetParseFn()
    method ParseStringQueue (line 61) | public static Queue<string> ParseStringQueue(string value)
    method ParseIntQueue (line 67) | public static Queue<int> ParseIntQueue(string value)
    method ParseStringCollection (line 74) | public static StringCollection ParseStringCollection<TS>(string value)...
    method ToStringCollection (line 82) | public static StringCollection ToStringCollection(List<string> items)
    method GetGenericQueueParseFn (line 93) | internal static ParseStringDelegate GetGenericQueueParseFn()
    method ParseStringStack (line 106) | public static Stack<string> ParseStringStack(string value)
    method ParseIntStack (line 112) | public static Stack<int> ParseIntStack(string value)
    method GetGenericStackParseFn (line 118) | internal static ParseStringDelegate GetGenericStackParseFn()
    method GetEnumerableParseFn (line 132) | public static ParseStringDelegate GetEnumerableParseFn()
    method GetGenericEnumerableParseFn (line 137) | public static ParseStringDelegate GetGenericEnumerableParseFn()
  class SpecializedQueueElements (line 154) | internal class SpecializedQueueElements<T>
    method ConvertToQueue (line 156) | public static Queue<T> ConvertToQueue(object enumerable)
    method ConvertToStack (line 162) | public static Stack<T> ConvertToStack(object enumerable)
  class SpecializedEnumerableElements (line 169) | internal class SpecializedEnumerableElements<TCollection, T>
    method SpecializedEnumerableElements (line 173) | static SpecializedEnumerableElements()
    method Convert (line 199) | public static object Convert(object enumerable)
    method ConvertFromCollection (line 204) | public static object ConvertFromCollection(object enumerable)

FILE: Xero.Api/Infrastructure/ThirdParty/ServiceStack.Text/Common/DeserializeType.cs
  class DeserializeType (line 25) | internal static class DeserializeType<TSerializer>
    method GetParseMethod (line 30) | public static ParseStringDelegate GetParseMethod(TypeConfig typeConfig)
    method ObjectStringToType (line 46) | public static object ObjectStringToType(string strType)
    method ExtractType (line 76) | public static Type ExtractType(string strType)
    method ParseAbstractType (line 106) | public static object ParseAbstractType<T>(string value)
    method ParseQuotedPrimitive (line 122) | public static object ParseQuotedPrimitive(string value)
    method ParsePrimitive (line 153) | public static object ParsePrimitive(string value)
    method ParsePrimitive (line 189) | internal static object ParsePrimitive(string value, char firstChar)
  class TypeAccessor (line 201) | internal class TypeAccessor
    method ExtractType (line 207) | public static Type ExtractType(ITypeSerializer Serializer, string strT...
    method Create (line 227) | public static TypeAccessor Create(ITypeSerializer serializer, TypeConf...
    method GetSetPropertyMethod (line 237) | private static SetPropertyDelegate GetSetPropertyMethod(TypeConfig typ...
    method CreateIlPropertySetter (line 281) | private static SetPropertyDelegate CreateIlPropertySetter(PropertyInfo...
    method CreateIlFieldSetter (line 305) | private static SetPropertyDelegate CreateIlFieldSetter(FieldInfo field...
    method CreateDynamicSetMethod (line 325) | private static DynamicMethod CreateDynamicSetMethod(MemberInfo memberI...
    method GetSetPropertyMethod (line 337) | internal static SetPropertyDelegate GetSetPropertyMethod(Type type, Pr...
    method GetSetFieldMethod (line 349) | internal static SetPropertyDelegate GetSetFieldMethod(Type type, Field...
    method Create (line 360) | public static TypeAccessor Create(ITypeSerializer serializer, TypeConf...
    method GetSetFieldMethod (line 371) | private static SetPropertyDelegate GetSetFieldMethod(TypeConfig typeCo...

FILE: Xero.Api/Infrastructure/ThirdParty/ServiceStack.Text/Common/DeserializeTypeRef.cs
  class DeserializeTypeRef (line 8) | internal static class DeserializeTypeRef
    method CreateSerializationError (line 10) | internal static SerializationException CreateSerializationError(Type t...
    method GetSerializationException (line 17) | internal static SerializationException GetSerializationException(strin...
    method GetTypeAccessorMap (line 35) | internal static Dictionary<string, TypeAccessor> GetTypeAccessorMap(Ty...

FILE: Xero.Api/Infrastructure/ThirdParty/ServiceStack.Text/Common/DeserializeTypeRefJson.cs
  type IPropertyNameResolver (line 8) | internal interface IPropertyNameResolver
    method GetTypeAccessorForProperty (line 10) | TypeAccessor GetTypeAccessorForProperty(string propertyName, Dictionar...
  class DefaultPropertyNameResolver (line 13) | internal class DefaultPropertyNameResolver : IP
Copy disabled (too large) Download .json
Condensed preview — 799 files, each showing path, character count, and a content snippet. Download the .json file for the full structured content (10,415K chars).
[
  {
    "path": ".gitignore",
    "chars": 517,
    "preview": "################################################################################\n# This .gitignore file was automaticall"
  },
  {
    "path": "CoreTests/ApiWrapperTest.cs",
    "chars": 1255,
    "preview": "using System.Linq;\r\nusing Xero.Api.Core;\r\nusing Xero.Api.Core.Model;\r\n\r\nnamespace CoreTests\r\n{\r\n    public class ApiWra"
  },
  {
    "path": "CoreTests/App.config",
    "chars": 598,
    "preview": "<?xml version=\"1.0\" encoding=\"utf-8\"?>\r\n<configuration>\r\n  <startup>\r\n    <supportedRuntime version=\"v4.0\" sku=\".NETFram"
  },
  {
    "path": "CoreTests/CoreTests.csproj",
    "chars": 11999,
    "preview": "<?xml version=\"1.0\" encoding=\"utf-8\"?>\r\n<Project ToolsVersion=\"12.0\" DefaultTargets=\"Build\" xmlns=\"http://schemas.micro"
  },
  {
    "path": "CoreTests/Integration/Accounts/Create.cs",
    "chars": 1416,
    "preview": "using NUnit.Framework;\nusing Xero.Api.Core.Model;\nusing Xero.Api.Core.Model.Types;\nusing Xero.Api.Infrastructure.Except"
  },
  {
    "path": "CoreTests/Integration/Accounts/Find.cs",
    "chars": 2062,
    "preview": "using System;\nusing System.Linq;\nusing System.Runtime.Hosting;\nusing NUnit.Framework;\nusing Xero.Api.Core.Model;\nusing "
  },
  {
    "path": "CoreTests/Integration/Accounts/Update.cs",
    "chars": 1383,
    "preview": "using System;\nusing NUnit.Framework;\nusing Xero.Api.Core.Model;\nusing Xero.Api.Core.Model.Status;\nusing Xero.Api.Core.M"
  },
  {
    "path": "CoreTests/Integration/Allocations/Add.cs",
    "chars": 7241,
    "preview": "using System;\nusing System.Linq;\nusing CoreTests.Integration.Invoices;\nusing NUnit.Framework;\nusing Xero.Api.Core.Model"
  },
  {
    "path": "CoreTests/Integration/Attachments/Attachments.cs",
    "chars": 6082,
    "preview": "using System;\nusing System.Collections.Generic;\nusing System.IO;\nusing System.Linq;\nusing NUnit.Framework;\nusing Xero.A"
  },
  {
    "path": "CoreTests/Integration/BankTransactionTest.cs",
    "chars": 1313,
    "preview": "using System;\nusing System.Collections.Generic;\nusing System.Linq;\nusing Xero.Api.Core.Model;\nusing Xero.Api.Core.Model"
  },
  {
    "path": "CoreTests/Integration/BankTransactions/BankTransactionTest.cs",
    "chars": 2105,
    "preview": "using System;\nusing System.Collections.Generic;\nusing System.Linq;\nusing Xero.Api.Core.Model;\nusing Xero.Api.Core.Model"
  },
  {
    "path": "CoreTests/Integration/BankTransactions/Create.cs",
    "chars": 382,
    "preview": "using NUnit.Framework;\n\nnamespace CoreTests.Integration.BankTransactions\n{\n    [TestFixture]\n    public class Create : "
  },
  {
    "path": "CoreTests/Integration/BankTransactions/Find.cs",
    "chars": 1268,
    "preview": "using System;\nusing System.Linq;\nusing NUnit.Framework;\n\nnamespace CoreTests.Integration.BankTransactions\n{\n    [TestFix"
  },
  {
    "path": "CoreTests/Integration/BankTransactions/Update.cs",
    "chars": 1188,
    "preview": "using System.Collections.Generic;\nusing NUnit.Framework;\nusing Xero.Api.Core.Model;\n\nnamespace CoreTests.Integration.Ba"
  },
  {
    "path": "CoreTests/Integration/BankTransfers/BankTransfersTest.cs",
    "chars": 888,
    "preview": "using System;\nusing System.Collections.Generic;\nusing System.Linq;\nusing Xero.Api.Core.Model;\n\nnamespace CoreTests.Inte"
  },
  {
    "path": "CoreTests/Integration/BankTransfers/Create.cs",
    "chars": 605,
    "preview": "using NUnit.Framework;\n\nnamespace CoreTests.Integration.BankTransfers\n{\n    [TestFixture]\n    public class Create : Ban"
  },
  {
    "path": "CoreTests/Integration/BankTransfers/Find.cs",
    "chars": 978,
    "preview": "using System;\nusing System.Linq;\nusing NUnit.Framework;\n\nnamespace CoreTests.Integration.BankTransfers\n{\n    [TestFixtu"
  },
  {
    "path": "CoreTests/Integration/BatchPayment/BatchPaymentsTest.cs",
    "chars": 1892,
    "preview": "using System;\nusing System.Collections.Generic;\nusing Xero.Api.Core.Model;\nusing Xero.Api.Core.Model.Status;\nusing Xero."
  },
  {
    "path": "CoreTests/Integration/BatchPayment/Create.cs",
    "chars": 801,
    "preview": "using System;\nusing System.Collections.Generic;\nusing System.Linq;\nusing NUnit.Framework;\nusing Xero.Api.Core.Model;\n\nn"
  },
  {
    "path": "CoreTests/Integration/ContactGroups/Add_Contact.cs",
    "chars": 674,
    "preview": "using NUnit.Framework;\nusing System;\nusing Xero.Api.Infrastructure.Exceptions;\n\nnamespace CoreTests.Integration.Contact"
  },
  {
    "path": "CoreTests/Integration/ContactGroups/ContactGroupsTest.cs",
    "chars": 807,
    "preview": "using System;\nusing System.Collections.Generic;\nusing System.Linq;\nusing System.Text;\nusing Xero.Api.Core.Model;\n\nnames"
  },
  {
    "path": "CoreTests/Integration/ContactGroups/Create.cs",
    "chars": 356,
    "preview": "using NUnit.Framework;\n\nnamespace CoreTests.Integration.ContactGroups\n{\n    [TestFixture]\n    public class Create : Con"
  },
  {
    "path": "CoreTests/Integration/ContactGroups/Delete.cs",
    "chars": 1120,
    "preview": "using System;\nusing System.Collections.Generic;\nusing System.Linq;\nusing System.Text;\nusing NUnit.Framework;\nusing Xero"
  },
  {
    "path": "CoreTests/Integration/ContactGroups/Find.cs",
    "chars": 966,
    "preview": "using System.Linq;\nusing NUnit.Framework;\n\nnamespace CoreTests.Integration.ContactGroups\n{\n    [TestFixture]\n    public"
  },
  {
    "path": "CoreTests/Integration/ContactGroups/Remove_Contact.cs",
    "chars": 586,
    "preview": "using System;\nusing System.Collections.Generic;\nusing System.Linq;\nusing System.Text;\nusing NUnit.Framework;\n\nnamespace"
  },
  {
    "path": "CoreTests/Integration/ContactGroups/Update.cs",
    "chars": 1377,
    "preview": "using NUnit.Framework;\nusing System;\nusing System.Collections.Generic;\nusing Xero.Api.Core.Model;\n\nnamespace CoreTests."
  },
  {
    "path": "CoreTests/Integration/Contacts/ContactsTest.cs",
    "chars": 1712,
    "preview": "using System;\nusing System.Linq;\nusing Xero.Api.Core.Model;\nusing Xero.Api.Core.Model.Status;\n\nnamespace CoreTests.Inte"
  },
  {
    "path": "CoreTests/Integration/Contacts/Create.cs",
    "chars": 4186,
    "preview": "using System;\nusing System.Collections.Generic;\nusing System.Linq;\nusing NUnit.Framework;\nusing Xero.Api.Core.Model;\nus"
  },
  {
    "path": "CoreTests/Integration/Contacts/Find.cs",
    "chars": 3304,
    "preview": "using System;\nusing System.Linq;\nusing NUnit.Framework;\nusing Xero.Api.Core.Model.Status;\n\nnamespace CoreTests.Integrat"
  },
  {
    "path": "CoreTests/Integration/Contacts/Update.cs",
    "chars": 2002,
    "preview": "using System;\nusing System.Collections.Generic;\nusing System.Linq;\nusing NUnit.Framework;\nusing Xero.Api.Core.Model;\nus"
  },
  {
    "path": "CoreTests/Integration/CreditNotes/Create.cs",
    "chars": 447,
    "preview": "using NUnit.Framework;\nusing Xero.Api.Core.Model.Types;\n\nnamespace CoreTests.Integration.CreditNotes\n{\n    [TestFixture"
  },
  {
    "path": "CoreTests/Integration/CreditNotes/CreditNotesTest.cs",
    "chars": 1474,
    "preview": "using System;\nusing System.Collections.Generic;\nusing Xero.Api.Core.Model;\nusing Xero.Api.Core.Model.Status;\nusing Xero"
  },
  {
    "path": "CoreTests/Integration/CreditNotes/Find.cs",
    "chars": 1269,
    "preview": "using System.Linq;\nusing NUnit.Framework;\nusing Xero.Api.Core.Model.Types;\n\nnamespace CoreTests.Integration.CreditNotes"
  },
  {
    "path": "CoreTests/Integration/CreditNotes/Update.cs",
    "chars": 1510,
    "preview": "using System.Collections.Generic;\nusing NUnit.Framework;\nusing Xero.Api.Core.Model;\nusing Xero.Api.Core.Model.Status;\n\n"
  },
  {
    "path": "CoreTests/Integration/ExpenseClaims/Create.cs",
    "chars": 669,
    "preview": "using System.Linq;\nusing NUnit.Framework;\n\nnamespace CoreTests.Integration.ExpenseClaims\n{\n    [TestFixture]\n    public"
  },
  {
    "path": "CoreTests/Integration/ExpenseClaims/ExpenseClaimTest.cs",
    "chars": 1758,
    "preview": "using System;\nusing System.Collections.Generic;\nusing Xero.Api.Core.Model;\nusing Xero.Api.Core.Model.Status;\nusing Xero"
  },
  {
    "path": "CoreTests/Integration/ExpenseClaims/Update.cs",
    "chars": 1906,
    "preview": "using System.Linq;\nusing NUnit.Framework;\nusing Xero.Api.Core.Model;\nusing Xero.Api.Core.Model.Status;\n\nnamespace CoreTe"
  },
  {
    "path": "CoreTests/Integration/Files/Associations/AssociationTest.cs",
    "chars": 2727,
    "preview": "using System;\nusing System.Diagnostics;\nusing System.Linq;\nusing NUnit.Framework;\nusing Xero.Api.Core.Model;\nusing Xero"
  },
  {
    "path": "CoreTests/Integration/Files/Files/AddFileTest.cs",
    "chars": 3142,
    "preview": "using System;\nusing System.Collections;\nusing System.Net;\nusing CoreTests.Integration.Files.Support;\nusing NUnit.Framew"
  },
  {
    "path": "CoreTests/Integration/Files/Folders/AddFolderTest.cs",
    "chars": 851,
    "preview": "using System;\nusing CoreTests.Integration.Files.Support;\nusing NUnit.Framework;\n\nnamespace CoreTests.Integration.Files.F"
  },
  {
    "path": "CoreTests/Integration/Files/Inbox/InboxTest.cs",
    "chars": 1771,
    "preview": "using System;\nusing CoreTests.Integration.Files.Support;\nusing NUnit.Framework;\nusing Xero.Api.Core.Model;\nusing File = "
  },
  {
    "path": "CoreTests/Integration/Files/Support/DataItem.cs",
    "chars": 724,
    "preview": "using System;\nusing System.IO;\n\nnamespace CoreTests.Integration.Files.Support\n{\n    public class DataItem : IDisposable"
  },
  {
    "path": "CoreTests/Integration/Files/Support/DiskFile.cs",
    "chars": 568,
    "preview": "using System.IO;\n\nnamespace CoreTests.Integration.Files.Support\n{\n    public class DiskFile : File\n    {\n        public "
  },
  {
    "path": "CoreTests/Integration/Files/Support/File.cs",
    "chars": 181,
    "preview": "namespace CoreTests.Integration.Files.Support\n{\n    public interface File\n    {\n        string Name { get; }\n        st"
  },
  {
    "path": "CoreTests/Integration/Files/Support/FilesTest.cs",
    "chars": 1987,
    "preview": "using System;\nusing System.IO;\nusing Xero.Api.Core.Model;\n\nnamespace CoreTests.Integration.Files.Support\n{\n    public c"
  },
  {
    "path": "CoreTests/Integration/General/Errors.cs",
    "chars": 961,
    "preview": "using System.Collections.Generic;\nusing NUnit.Framework;\nusing Xero.Api.Core.Model;\nusing Xero.Api.Infrastructure.Excep"
  },
  {
    "path": "CoreTests/Integration/General/FindingAllItems.cs",
    "chars": 2752,
    "preview": "using NUnit.Framework;\n\nnamespace CoreTests.Integration.General\n{\n    [TestFixture]\n    public class FindingAllItems : "
  },
  {
    "path": "CoreTests/Integration/General/QueryStrings.cs",
    "chars": 1079,
    "preview": "using System;\nusing NUnit.Framework;\n\nnamespace CoreTests.Integration.General\n{\n    [TestFixture]\n    public class Quer"
  },
  {
    "path": "CoreTests/Integration/HistoryAndNotes/CreateNotes.cs",
    "chars": 482,
    "preview": "using NUnit.Framework;\n\nnamespace CoreTests.Integration.HistoryAndNotes\n{\n    public class CreateNotes : HistoryAndNote"
  },
  {
    "path": "CoreTests/Integration/HistoryAndNotes/Find.cs",
    "chars": 367,
    "preview": "using NUnit.Framework;\n\nnamespace CoreTests.Integration.HistoryAndNotes\n{\n    public class Find : HistoryAndNotesTest\n "
  },
  {
    "path": "CoreTests/Integration/HistoryAndNotes/HistoryAndNotesTest.cs",
    "chars": 1496,
    "preview": "using System;\nusing System.Collections.Generic;\nusing System.Linq;\nusing NUnit.Framework;\nusing Xero.Api.Core.Model;\nus"
  },
  {
    "path": "CoreTests/Integration/Invoices/Create.cs",
    "chars": 9770,
    "preview": "using System;\nusing System.Collections.Generic;\nusing System.Linq;\nusing NUnit.Framework;\nusing Xero.Api.Core.Model;\nusi"
  },
  {
    "path": "CoreTests/Integration/Invoices/Find.cs",
    "chars": 3435,
    "preview": "using System;\nusing System.Collections;\nusing System.Linq;\nusing NUnit.Framework;\nusing Xero.Api.Core.Model.Types;\n\nnam"
  },
  {
    "path": "CoreTests/Integration/Invoices/InvoicesTest.cs",
    "chars": 2026,
    "preview": "using System;\nusing System.Collections.Generic;\nusing Xero.Api.Core.Model;\nusing Xero.Api.Core.Model.Status;\nusing Xero"
  },
  {
    "path": "CoreTests/Integration/Invoices/OnlineInvoiceUrl.cs",
    "chars": 597,
    "preview": "using NUnit.Framework;\nusing Xero.Api.Core.Model.Status;\nusing Xero.Api.Core.Model.Types;\n\nnamespace CoreTests.Integrat"
  },
  {
    "path": "CoreTests/Integration/Invoices/SummarizeErrors.cs",
    "chars": 2716,
    "preview": "using System;\nusing System.Collections.Generic;\nusing System.Linq;\nusing NUnit.Framework;\nusing Xero.Api.Core.Model;\nus"
  },
  {
    "path": "CoreTests/Integration/Items/Create.cs",
    "chars": 1147,
    "preview": "using System;\nusing NUnit.Framework;\nusing Xero.Api.Core.Model;\n\nnamespace CoreTests.Integration.Items\n{\n    [TestFixtu"
  },
  {
    "path": "CoreTests/Integration/Items/Delete.cs",
    "chars": 1509,
    "preview": "using System;\nusing CoreTests.Integration.Items.TrackedItems;\nusing NUnit.Framework;\nusing Xero.Api.Core.Model;\nusing X"
  },
  {
    "path": "CoreTests/Integration/Items/TrackedItems/Create.cs",
    "chars": 2311,
    "preview": "using System;\nusing NUnit.Framework;\nusing Xero.Api.Core.Model;\n\nnamespace CoreTests.Integration.Items.TrackedItems\n{\n "
  },
  {
    "path": "CoreTests/Integration/Items/TrackedItems/Find.cs",
    "chars": 611,
    "preview": "using NUnit.Framework;\n\nnamespace CoreTests.Integration.Items.TrackedItems\n{\n    public class Find : TrackedInventoryTe"
  },
  {
    "path": "CoreTests/Integration/Items/TrackedItems/TrackedInventoryTest.cs",
    "chars": 9370,
    "preview": "using System;\nusing System.Collections.Generic;\nusing System.Linq;\nusing Xero.Api.Core.Model;\nusing Xero.Api.Core.Model."
  },
  {
    "path": "CoreTests/Integration/Items/TrackedItems/Update.cs",
    "chars": 3608,
    "preview": "using NUnit.Framework;\n\nnamespace CoreTests.Integration.Items.TrackedItems\n{\n    public class Update : TrackedInventory"
  },
  {
    "path": "CoreTests/Integration/Items/TrackedItems/Using_tracked_items.cs",
    "chars": 3559,
    "preview": "using NUnit.Framework;\nusing Xero.Api.Core.Model;\n\nnamespace CoreTests.Integration.Items.TrackedItems\n{\n    public clas"
  },
  {
    "path": "CoreTests/Integration/Items/Update.cs",
    "chars": 1050,
    "preview": "using System;\nusing System.Collections.Generic;\nusing System.Linq;\nusing System.Text;\nusing NUnit.Framework;\nusing Xero"
  },
  {
    "path": "CoreTests/Integration/Journals/Find.cs",
    "chars": 697,
    "preview": "using System.Linq;\nusing NUnit.Framework;\n\nnamespace CoreTests.Integration.Journals\n{\n    [TestFixture]\n    public clas"
  },
  {
    "path": "CoreTests/Integration/LinkedTransactions/Create.cs",
    "chars": 2358,
    "preview": "using NUnit.Framework;\nusing Xero.Api.Core.Model;\n\nnamespace CoreTests.Integration.LinkedTransactions\n{\n    public clas"
  },
  {
    "path": "CoreTests/Integration/LinkedTransactions/Delete.cs",
    "chars": 640,
    "preview": "using NUnit.Framework;\nusing Xero.Api.Infrastructure.Exceptions;\n\nnamespace CoreTests.Integration.LinkedTransactions\n{\n"
  },
  {
    "path": "CoreTests/Integration/LinkedTransactions/Find.cs",
    "chars": 2068,
    "preview": "using System.Linq;\nusing NUnit.Framework;\n\nnamespace CoreTests.Integration.LinkedTransactions\n{\n    public class Find :"
  },
  {
    "path": "CoreTests/Integration/LinkedTransactions/LinkedTransactionTest.cs",
    "chars": 5194,
    "preview": "using System;\nusing System.Collections.Generic;\nusing System.Linq;\nusing NUnit.Framework;\nusing Xero.Api.Core.Model;\nusi"
  },
  {
    "path": "CoreTests/Integration/LinkedTransactions/Update.cs",
    "chars": 1351,
    "preview": "using System.ComponentModel;\nusing NUnit.Framework;\n\nnamespace CoreTests.Integration.LinkedTransactions\n{\n    public cl"
  },
  {
    "path": "CoreTests/Integration/ManualJournals/Create.cs",
    "chars": 2176,
    "preview": "using System;\nusing System.Collections.Generic;\nusing System.Linq;\nusing NUnit.Framework;\nusing Xero.Api.Core.Model;\n\nn"
  },
  {
    "path": "CoreTests/Integration/ManualJournals/Find.cs",
    "chars": 1392,
    "preview": "using System;\nusing System.Linq;\nusing NUnit.Framework;\n\nnamespace CoreTests.Integration.ManualJournals\n{\n    [TestFixtu"
  },
  {
    "path": "CoreTests/Integration/ManualJournals/ManualJournalsTest.cs",
    "chars": 1664,
    "preview": "using System.Collections.Generic;\nusing System.Linq;\nusing Xero.Api.Core.Model;\nusing Xero.Api.Core.Model.Types;\n\nnamesp"
  },
  {
    "path": "CoreTests/Integration/ManualJournals/Update.cs",
    "chars": 721,
    "preview": "using System;\nusing NUnit.Framework;\n\nnamespace CoreTests.Integration.ManualJournals\n{\n    [TestFixture]\n    public clas"
  },
  {
    "path": "CoreTests/Integration/Organisation/Find.cs",
    "chars": 654,
    "preview": "using System;\nusing NUnit.Framework;\nusing Xero.Api.Core.Model.Types;\n\nnamespace CoreTests.Integration.Organisation\n{\n "
  },
  {
    "path": "CoreTests/Integration/Overpayments/Find.cs",
    "chars": 922,
    "preview": "using System.Linq;\nusing NUnit.Framework;\nusing Xero.Api.Core.Model.Types;\n\nnamespace CoreTests.Integration.Overpayment"
  },
  {
    "path": "CoreTests/Integration/Payments/Create.cs",
    "chars": 4822,
    "preview": "using System;\nusing System.Collections.Generic;\nusing System.Linq;\nusing NUnit.Framework;\nusing Xero.Api.Core.Model;\n\nn"
  },
  {
    "path": "CoreTests/Integration/Payments/CreateForeignCurrency.cs",
    "chars": 2159,
    "preview": "using System;\nusing System.Linq;\nusing NUnit.Framework;\nusing Xero.Api.Core.Model;\nusing Xero.Api.Core.Model.Types;\n\nnam"
  },
  {
    "path": "CoreTests/Integration/Payments/Delete.cs",
    "chars": 783,
    "preview": "using System;\nusing NUnit.Framework;\nusing Xero.Api.Core.Model;\nusing Xero.Api.Core.Model.Status;\n\nnamespace CoreTests."
  },
  {
    "path": "CoreTests/Integration/Payments/Find.cs",
    "chars": 1118,
    "preview": "using System;\nusing System.Linq;\nusing NUnit.Framework;\n\nnamespace CoreTests.Integration.Payments\n{\n    public class Fi"
  },
  {
    "path": "CoreTests/Integration/Payments/PaymentsTest.cs",
    "chars": 4828,
    "preview": "using System;\nusing System.Collections.Generic;\nusing Xero.Api.Core.Model;\nusing Xero.Api.Core.Model.Status;\nusing Xero."
  },
  {
    "path": "CoreTests/Integration/Pdf/Get.cs",
    "chars": 1686,
    "preview": "using System;\nusing NUnit.Framework;\nusing Xero.Api.Core.Model.Types;\nusing Xero.Api.Infrastructure.Exceptions;\n\nnamesp"
  },
  {
    "path": "CoreTests/Integration/Prepayments/Find.cs",
    "chars": 904,
    "preview": "using System.Linq;\nusing NUnit.Framework;\nusing Xero.Api.Core.Model.Types;\n\nnamespace CoreTests.Integration.Prepayments"
  },
  {
    "path": "CoreTests/Integration/PurchaseOrders/Create.cs",
    "chars": 2483,
    "preview": "using System;\nusing System.Collections.Generic;\nusing System.Linq;\nusing NUnit.Framework;\nusing Xero.Api.Core.Model;\nus"
  },
  {
    "path": "CoreTests/Integration/PurchaseOrders/Find.cs",
    "chars": 5782,
    "preview": "using System;\nusing System.Collections.Generic;\nusing System.Linq;\nusing System.Threading;\nusing NUnit.Framework;\nusing"
  },
  {
    "path": "CoreTests/Integration/PurchaseOrders/Update.cs",
    "chars": 1660,
    "preview": "using System;\nusing System.Collections.Generic;\nusing System.Linq;\nusing System.Text;\nusing NUnit.Framework;\nusing Xero"
  },
  {
    "path": "CoreTests/Integration/Receipts/Create.cs",
    "chars": 680,
    "preview": "using System.Linq;\nusing NUnit.Framework;\n\nnamespace CoreTests.Integration.Receipts\n{\n    [TestFixture]\n    public clas"
  },
  {
    "path": "CoreTests/Integration/Receipts/ReceiptTest.cs",
    "chars": 1040,
    "preview": "using System;\nusing System.Collections.Generic;\nusing Xero.Api.Core.Model;\nusing Xero.Api.Core.Model.Types;\n\nnamespace "
  },
  {
    "path": "CoreTests/Integration/Receipts/Update.cs",
    "chars": 746,
    "preview": "using System.Linq;\nusing NUnit.Framework;\nusing Xero.Api.Core.Model.Status;\n\nnamespace CoreTests.Integration.Receipts\n{"
  },
  {
    "path": "CoreTests/Integration/Reports/Find.cs",
    "chars": 919,
    "preview": "using System;\nusing System.Collections.Generic;\nusing System.Linq;\nusing System.Text;\nusing NUnit.Framework;\n\nnamespace"
  },
  {
    "path": "CoreTests/Integration/Setup/Create.cs",
    "chars": 1802,
    "preview": "using System.Collections.Generic;\nusing NUnit.Framework;\nusing Xero.Api.Core.Model;\nusing Xero.Api.Core.Model.Types;\nus"
  },
  {
    "path": "CoreTests/Integration/TaxRates/Create.cs",
    "chars": 1214,
    "preview": "using System.Linq;\nusing NUnit.Framework;\nusing Xero.Api.Core.Model;\nusing Xero.Api.Core.Model.Types;\n\nnamespace CoreTe"
  },
  {
    "path": "CoreTests/Integration/TaxRates/TaxRateTest.cs",
    "chars": 962,
    "preview": "using System.Collections.Generic;\nusing System.Linq;\nusing Xero.Api.Core.Model;\nusing Xero.Api.Core.Model.Types;\n\nnames"
  },
  {
    "path": "CoreTests/Integration/TaxRates/Update.cs",
    "chars": 1712,
    "preview": "using System.Linq;\nusing NUnit.Framework;\nusing Xero.Api.Core.Model.Status;\nusing Xero.Api.Core.Model.Types;\n\nnamespace"
  },
  {
    "path": "CoreTests/Integration/TrackingCategories/AddTrackingOption.cs",
    "chars": 817,
    "preview": "using System;\r\nusing System.Collections.Generic;\r\nusing System.Linq;\r\nusing NUnit.Framework;\r\nusing Xero.Api.Core.Endpo"
  },
  {
    "path": "CoreTests/Integration/TrackingCategories/Adding/CreateTrackingCategories.cs",
    "chars": 767,
    "preview": "using System;\nusing NUnit.Framework;\nusing Xero.Api.Core.Model;\nusing Xero.Api.Core.Model.Status;\n\nnamespace CoreTests."
  },
  {
    "path": "CoreTests/Integration/TrackingCategories/ArchiveTrackingCategory.cs",
    "chars": 705,
    "preview": "using System;\r\nusing System.Collections.Generic;\r\nusing System.Linq;\r\nusing NUnit.Framework;\r\nusing Xero.Api.Core.Endpo"
  },
  {
    "path": "CoreTests/Integration/TrackingCategories/CreateTrackingCategories.cs",
    "chars": 450,
    "preview": "using System;\r\nusing NUnit.Framework;\r\nusing Xero.Api.Core.Model;\r\nusing Xero.Api.Core.Model.Status;\r\n\r\nnamespace CoreT"
  },
  {
    "path": "CoreTests/Integration/TrackingCategories/Delete.cs",
    "chars": 741,
    "preview": "using System.Linq;\r\nusing NUnit.Framework;\r\nusing Xero.Api.Core.Model.Status;\r\nusing Xero.Api.Infrastructure.ThirdParty"
  },
  {
    "path": "CoreTests/Integration/TrackingCategories/GetTrackingCategories.cs",
    "chars": 594,
    "preview": "using System;\r\nusing System.Linq;\r\nusing NUnit.Framework;\r\nusing Xero.Api.Core.Model;\r\nusing Xero.Api.Core.Model.Status"
  },
  {
    "path": "CoreTests/Integration/TrackingCategories/GetTrackingCategoriesIncludingArchieved.cs",
    "chars": 845,
    "preview": "using System;\r\nusing System.Linq;\r\nusing NUnit.Framework;\r\nusing Xero.Api.Core.Model;\r\nusing Xero.Api.Core.Model.Status"
  },
  {
    "path": "CoreTests/Integration/TrackingCategories/Options/AddTrackingOption.cs",
    "chars": 797,
    "preview": "using System;\nusing System.Linq;\nusing NUnit.Framework;\nusing Xero.Api.Core.Model;\nusing Xero.Api.Core.Model.Status;\n\nn"
  },
  {
    "path": "CoreTests/Integration/TrackingCategories/TrackingCategoriesTest.cs",
    "chars": 8231,
    "preview": "using System;\r\nusing System.CodeDom;\r\nusing System.Collections.Generic;\r\nusing System.Linq;\r\nusing System.Runtime.Inter"
  },
  {
    "path": "CoreTests/Integration/TrackingCategories/UpdateTrackingCategory.cs",
    "chars": 853,
    "preview": "using System;\r\nusing System.Collections.Generic;\r\nusing System.Linq;\r\nusing NUnit.Framework;\r\nusing Xero.Api.Core.Endpo"
  },
  {
    "path": "CoreTests/Integration/TrackingCategories/UpdateTrackingOptions.cs",
    "chars": 954,
    "preview": "using System;\r\nusing System.Collections.Generic;\r\nusing System.Linq;\r\nusing NUnit.Framework;\r\nusing Xero.Api.Core.Endpo"
  },
  {
    "path": "CoreTests/README.md",
    "chars": 478,
    "preview": "## Tests for the Core API\nThese are really code snippets in the form of runnable tests. The examples for each of the end"
  },
  {
    "path": "CoreTests/Random.cs",
    "chars": 951,
    "preview": "using System;\nusing System.Security.Cryptography;\n\nnamespace CoreTests\n{\n    public static class Random\n    {\n        p"
  },
  {
    "path": "CoreTests/Resources/cert/public_privatekey.txt",
    "chars": 39,
    "preview": "replace this with your real .pfx file."
  },
  {
    "path": "CoreTests/Unit/Contacts.cs",
    "chars": 897,
    "preview": "using NUnit.Framework;\n\nnamespace CoreTests.Unit\n{\n    [TestFixture]\n    public class Contacts : ApiWrapperTest\n    {\n  "
  },
  {
    "path": "CoreTests/Unit/ExceptionTests.cs",
    "chars": 2556,
    "preview": "using System.Collections.Generic;\nusing NUnit.Framework;\nusing Xero.Api.Infrastructure.Exceptions;\nusing Xero.Api.Infras"
  },
  {
    "path": "CoreTests/Unit/FourDecimalPlaces.cs",
    "chars": 6535,
    "preview": "using NUnit.Framework;\nusing Xero.Api.Common;\nusing Xero.Api.Core.Endpoints;\nusing Xero.Api.Core.Endpoints.Base;\nusing "
  },
  {
    "path": "CoreTests/Unit/QueryStrings.cs",
    "chars": 1614,
    "preview": "using System;\nusing NUnit.Framework;\n\nnamespace CoreTests.Unit\n{\n    [TestFixture]\n    public class QueryStrings : ApiW"
  },
  {
    "path": "CoreTests/Unit/RateLimiterTest.cs",
    "chars": 1104,
    "preview": "using System;\r\nusing System.Collections.Generic;\r\nusing System.Diagnostics;\r\nusing System.Linq;\r\nusing System.Text;\r\nus"
  },
  {
    "path": "CoreTests/Unit/SalesTaxBasisTypeTest.cs",
    "chars": 2062,
    "preview": "using NUnit.Framework;\nusing Xero.Api.Core.Model.Types;\nusing Xero.Api.Infrastructure.Interfaces;\nusing Xero.Api.Seriali"
  },
  {
    "path": "CoreTests/Unit/SalesTaxPeriodTypeTest.cs",
    "chars": 2823,
    "preview": "using NUnit.Framework;\nusing Xero.Api.Core.Model.Types;\nusing Xero.Api.Infrastructure.Interfaces;\nusing Xero.Api.Serial"
  },
  {
    "path": "CoreTests/Unit/SummarizeErrors.cs",
    "chars": 1381,
    "preview": "using NUnit.Framework;\n\nnamespace CoreTests.Unit\n{\n    public class SummarizeErrors : ApiWrapperTest\n    {\n        [Set"
  },
  {
    "path": "CoreTests/Unit/TrackingCategories.cs",
    "chars": 968,
    "preview": "using NUnit.Framework;\n\nnamespace CoreTests.Unit\n{\n    [TestFixture]\n    public class TrackingCategories : ApiWrapperTes"
  },
  {
    "path": "CoreTests/Unit/UrlEncoder.cs",
    "chars": 437,
    "preview": "using NUnit.Framework;\n\nnamespace CoreTests.Unit\n{\n    [TestFixture]\n    public class UrlEncoder\n    {\n        [Test]\n "
  },
  {
    "path": "CoreTests/packages.config",
    "chars": 203,
    "preview": "<?xml version=\"1.0\" encoding=\"utf-8\"?>\n<packages>\n  <package id=\"NUnit\" version=\"2.6.3\" targetFramework=\"net45\" />\n  <p"
  },
  {
    "path": "PayrollTests.AU/ApiWrapperTest.cs",
    "chars": 510,
    "preview": "using Xero.Api.Payroll;\n\nnamespace PayrollTests.AU\n{\n    public class ApiWrapperTest\n    {\n        private AustralianPa"
  },
  {
    "path": "PayrollTests.AU/App.config",
    "chars": 576,
    "preview": "<?xml version=\"1.0\" encoding=\"utf-8\"?>\n<configuration>\n  <startup>\n    <supportedRuntime version=\"v4.0\" sku=\".NETFramewo"
  },
  {
    "path": "PayrollTests.AU/Integration/Employees/Create.cs",
    "chars": 4178,
    "preview": "using System;\nusing System.Collections.Generic;\nusing NUnit.Framework;\nusing Xero.Api.Payroll.Australia.Model;\n\nnamespa"
  },
  {
    "path": "PayrollTests.AU/Integration/Employees/EmployeesTest.cs",
    "chars": 1848,
    "preview": "using System;\nusing System.Linq;\nusing Xero.Api.Payroll.Australia.Model;\nusing Xero.Api.Payroll.Australia.Model.Types;\n"
  },
  {
    "path": "PayrollTests.AU/Integration/Employees/Find.cs",
    "chars": 1077,
    "preview": "using System.Linq;\nusing NUnit.Framework;\n\nnamespace PayrollTests.AU.Integration.Employees\n{\n    [TestFixture]\n    publ"
  },
  {
    "path": "PayrollTests.AU/Integration/Employees/Update.cs",
    "chars": 936,
    "preview": "using System;\nusing System.Collections.Generic;\nusing System.Linq;\nusing System.Text;\nusing NUnit.Framework;\nusing Xero"
  },
  {
    "path": "PayrollTests.AU/Integration/LeaveApplications/Create.cs",
    "chars": 1228,
    "preview": "using System;\nusing System.Collections.Generic;\nusing NUnit.Framework;\nusing PayrollTests.AU.Integration.Employees;\nusi"
  },
  {
    "path": "PayrollTests.AU/Integration/LeaveApplications/Find.cs",
    "chars": 1308,
    "preview": "using System;\nusing System.Collections.Generic;\nusing System.Linq;\nusing System.Text;\nusing NUnit.Framework;\n\nnamespace"
  },
  {
    "path": "PayrollTests.AU/Integration/LeaveApplications/LeaveApplicationTest.cs",
    "chars": 2000,
    "preview": "using System;\nusing System.Linq;\nusing Xero.Api.Payroll.Australia.Model;\n\nnamespace PayrollTests.AU.Integration.LeaveAp"
  },
  {
    "path": "PayrollTests.AU/Integration/PayItems/Create.cs",
    "chars": 660,
    "preview": "using System.Linq;\nusing NUnit.Framework;\n\nnamespace PayrollTests.AU.Integration.PayItems\n{\n    [TestFixture]\n    publi"
  },
  {
    "path": "PayrollTests.AU/Integration/PayItems/Find.cs",
    "chars": 701,
    "preview": "using NUnit.Framework;\n\nnamespace PayrollTests.AU.Integration.PayItems\n{\n    [TestFixture]\n    public class Find : ApiW"
  },
  {
    "path": "PayrollTests.AU/Integration/PayItems/PayItemsTest.cs",
    "chars": 1934,
    "preview": "using System.Collections.Generic;\nusing Xero.Api.Payroll.Australia.Model;\nusing Xero.Api.Payroll.Australia.Model.Types;"
  },
  {
    "path": "PayrollTests.AU/Integration/PayrollCalendars/Create.cs",
    "chars": 659,
    "preview": "using System;\nusing NUnit.Framework;\nusing Xero.Api.Payroll.Australia.Model;\nusing Xero.Api.Payroll.Australia.Model.Typ"
  },
  {
    "path": "PayrollTests.AU/Integration/PayrollCalendars/Find.cs",
    "chars": 631,
    "preview": "using System;\nusing System.Linq;\nusing NUnit.Framework;\n\nnamespace PayrollTests.AU.Integration.PayrollCalendars\n{\n    ["
  },
  {
    "path": "PayrollTests.AU/Integration/Payrun/Create.cs",
    "chars": 1565,
    "preview": "using System;\nusing NUnit.Framework;\nusing Xero.Api.Payroll.Australia.Model;\nusing Xero.Api.Payroll.Australia.Model.Typ"
  },
  {
    "path": "PayrollTests.AU/Integration/Payrun/Find.cs",
    "chars": 916,
    "preview": "using System;\nusing System.Linq;\nusing NUnit.Framework;\n\nnamespace PayrollTests.AU.Integration.Payrun\n{\n    [TestFixtur"
  },
  {
    "path": "PayrollTests.AU/Integration/Payrun/PayrunTest.cs",
    "chars": 1060,
    "preview": "using System;\nusing System.Linq;\nusing Xero.Api.Payroll.Australia.Model;\nusing Xero.Api.Payroll.Australia.Model.Types;\n"
  },
  {
    "path": "PayrollTests.AU/Integration/Settings/Find.cs",
    "chars": 471,
    "preview": "using System;\nusing System.Linq;\nusing NUnit.Framework;\n\nnamespace PayrollTests.AU.Integration.Settings\n{\n    [TestFixt"
  },
  {
    "path": "PayrollTests.AU/Integration/SuperFundProducts/Find.cs",
    "chars": 551,
    "preview": "using System;\nusing System.Collections.Generic;\nusing System.Linq;\nusing System.Text;\nusing NUnit.Framework;\n\nnamespace"
  },
  {
    "path": "PayrollTests.AU/Integration/SuperFunds/Create.cs",
    "chars": 605,
    "preview": "using System;\nusing System.Collections.Generic;\nusing System.Linq;\nusing System.Text;\nusing NUnit.Framework;\nusing Xero"
  },
  {
    "path": "PayrollTests.AU/Integration/SuperFunds/Update.cs",
    "chars": 1084,
    "preview": "using System;\nusing NUnit.Framework;\nusing Xero.Api.Payroll.Australia.Model;\nusing Xero.Api.Payroll.Australia.Model.Typ"
  },
  {
    "path": "PayrollTests.AU/Integration/TimeSheets/Create.cs",
    "chars": 1560,
    "preview": "using System;\nusing System.Collections.Generic;\nusing NUnit.Framework;\nusing Xero.Api.Payroll.Australia.Model.Status;\nu"
  },
  {
    "path": "PayrollTests.AU/Integration/TimeSheets/Find.cs",
    "chars": 964,
    "preview": "using System;\nusing System.Collections.Generic;\nusing System.Linq;\nusing System.Text;\nusing NUnit.Framework;\n\nnamespace"
  },
  {
    "path": "PayrollTests.AU/Integration/TimeSheets/TimesheetTest.cs",
    "chars": 2288,
    "preview": "using System;\nusing System.Linq;\nusing Xero.Api.Payroll.Australia.Model;\nusing Xero.Api.Payroll.Australia.Model.Status;"
  },
  {
    "path": "PayrollTests.AU/Integration/ValidationErrors/AUPayrollValidationErrors.cs",
    "chars": 899,
    "preview": "using System.Linq;\nusing NUnit.Framework;\nusing Xero.Api.Infrastructure.Exceptions;\nusing Xero.Api.Payroll.Australia.Mo"
  },
  {
    "path": "PayrollTests.AU/PayrollTests.AU.csproj",
    "chars": 5048,
    "preview": "<?xml version=\"1.0\" encoding=\"utf-8\"?>\n<Project ToolsVersion=\"12.0\" DefaultTargets=\"Build\" xmlns=\"http://schemas.micros"
  },
  {
    "path": "PayrollTests.AU/Properties/AssemblyInfo.cs",
    "chars": 1405,
    "preview": "using System.Reflection;\nusing System.Runtime.CompilerServices;\nusing System.Runtime.InteropServices;\n\n// General Infor"
  },
  {
    "path": "PayrollTests.AU/README.md",
    "chars": 563,
    "preview": "## Tests for the Australian Payroll API\nThese are really code snippets in the form of runnable tests. The examples for e"
  },
  {
    "path": "PayrollTests.AU/Resources/cert/public_privatekey.txt",
    "chars": 38,
    "preview": "replace this with your real .pfx file."
  },
  {
    "path": "PayrollTests.AU/packages.config",
    "chars": 127,
    "preview": "<?xml version=\"1.0\" encoding=\"utf-8\"?>\n<packages>\n  <package id=\"NUnit\" version=\"2.6.3\" targetFramework=\"net40\" />\n</pa"
  },
  {
    "path": "PayrollTests.US/ApiWrapperTest.cs",
    "chars": 502,
    "preview": "using Xero.Api.Payroll;\n\nnamespace PayrollTests.US\n{\n    public class ApiWrapperTest\n    {\n        private AmericanPayr"
  },
  {
    "path": "PayrollTests.US/App.config",
    "chars": 576,
    "preview": "<?xml version=\"1.0\" encoding=\"utf-8\"?>\n<configuration>\n  <startup>\n    <supportedRuntime version=\"v4.0\" sku=\".NETFramewo"
  },
  {
    "path": "PayrollTests.US/Integration/Employees/Create.cs",
    "chars": 3870,
    "preview": "using System;\nusing NUnit.Framework;\nusing Xero.Api.Payroll.America.Model;\nusing Xero.Api.Payroll.America.Model.Types;\n"
  },
  {
    "path": "PayrollTests.US/Integration/Employees/EmployeesTest.cs",
    "chars": 1774,
    "preview": "using System;\nusing Xero.Api.Payroll.America.Model;\n\nnamespace PayrollTests.US.Integration.Employees\n{\n    public abstr"
  },
  {
    "path": "PayrollTests.US/Integration/Employees/Find.cs",
    "chars": 1082,
    "preview": "using System.Linq;\nusing NUnit.Framework;\n\nnamespace PayrollTests.US.Integration.Employees\n{\n    [TestFixture]\n    publ"
  },
  {
    "path": "PayrollTests.US/Integration/Employees/Update.cs",
    "chars": 509,
    "preview": "using System;\nusing NUnit.Framework;\nusing Xero.Api.Payroll.America.Model;\n\nnamespace PayrollTests.US.Integration.Emplo"
  },
  {
    "path": "PayrollTests.US/Integration/PaySchedules/Create.cs",
    "chars": 611,
    "preview": "using System;\nusing NUnit.Framework;\nusing Xero.Api.Payroll.America.Model;\nusing Xero.Api.Payroll.America.Model.Types;\n"
  },
  {
    "path": "PayrollTests.US/Integration/PaySchedules/Find.cs",
    "chars": 834,
    "preview": "using System;\nusing System.Linq;\nusing NUnit.Framework;\n\nnamespace PayrollTests.US.Integration.PaySchedules\n{\n    [Test"
  },
  {
    "path": "PayrollTests.US/Integration/PaySchedules/PaySchedulesTest.cs",
    "chars": 562,
    "preview": "using System;\nusing Xero.Api.Payroll.America.Model;\nusing Xero.Api.Payroll.America.Model.Types;\n\nnamespace PayrollTests"
  },
  {
    "path": "PayrollTests.US/PayrollTests.US.csproj",
    "chars": 3977,
    "preview": "<?xml version=\"1.0\" encoding=\"utf-8\"?>\n<Project ToolsVersion=\"12.0\" DefaultTargets=\"Build\" xmlns=\"http://schemas.micros"
  },
  {
    "path": "PayrollTests.US/Properties/AssemblyInfo.cs",
    "chars": 1411,
    "preview": "using System.Reflection;\nusing System.Runtime.CompilerServices;\nusing System.Runtime.InteropServices;\n\n// General Infor"
  },
  {
    "path": "PayrollTests.US/README.md",
    "chars": 561,
    "preview": "## Tests for the American Payroll API\nThese are really code snippets in the form of runnable tests. The examples for eac"
  },
  {
    "path": "PayrollTests.US/Resources/cert/public_privatekey.txt",
    "chars": 38,
    "preview": "replace this with your real .pfx file."
  },
  {
    "path": "PayrollTests.US/packages.config",
    "chars": 127,
    "preview": "<?xml version=\"1.0\" encoding=\"utf-8\"?>\n<packages>\n  <package id=\"NUnit\" version=\"2.6.3\" targetFramework=\"net40\" />\n</pa"
  },
  {
    "path": "README.md",
    "chars": 13461,
    "preview": "Xero-Net\n========\n\n## Looking for OAuth 2.0?\nPlease checkout [Xero-NetStandard SDK for OAuth 2.0](https://github.com/Xer"
  },
  {
    "path": "Xero.Api/Common/CoreData.cs",
    "chars": 734,
    "preview": "using System.Collections.Generic;\nusing System.Runtime.Serialization;\nusing Xero.Api.Core.Model.Status;\nusing Xero.Api."
  },
  {
    "path": "Xero.Api/Common/Extensions.cs",
    "chars": 856,
    "preview": "using System;\nusing System.Collections.Specialized;\n\nnamespace Xero.Api.Common\n{\n    public static class Extensions\n   "
  },
  {
    "path": "Xero.Api/Common/HasUpdatedDate.cs",
    "chars": 307,
    "preview": "using System;\nusing System.Runtime.Serialization;\n\nnamespace Xero.Api.Common\n{\n    [DataContract(Namespace = \"\")]\n    p"
  },
  {
    "path": "Xero.Api/Common/IHasAttachment.cs",
    "chars": 209,
    "preview": "using System;\nusing System.Collections.Generic;\nusing System.Linq;\nusing System.Text;\n\nnamespace Xero.Api.Common\n{\n    "
  },
  {
    "path": "Xero.Api/Common/IHasId.cs",
    "chars": 116,
    "preview": "using System;\n\nnamespace Xero.Api.Common\n{\n    public interface IHasId\n    {\n        Guid Id { get; set; }\n    }\n}\n"
  },
  {
    "path": "Xero.Api/Common/IPageableEndpoint.cs",
    "chars": 111,
    "preview": "namespace Xero.Api.Common\n{\n    public interface IPageableEndpoint<T>\n    {\n        T Page(int page);\n    }\n}\n"
  },
  {
    "path": "Xero.Api/Common/IXeroReadEndpoint.cs",
    "chars": 761,
    "preview": "using System;\r\nusing System.Collections.Generic;\r\nusing Xero.Api.Infrastructure.Interfaces;\r\n\r\nnamespace Xero.Api.Common"
  },
  {
    "path": "Xero.Api/Common/MimeTypes.cs",
    "chars": 1494,
    "preview": "using System.IO;\nusing Microsoft.Win32;\n\nnamespace Xero.Api.Common\n{\n    public static class MimeTypes\n    {\n        pu"
  },
  {
    "path": "Xero.Api/Common/QueryGenerator.cs",
    "chars": 1706,
    "preview": "using System;\nusing System.Collections.Specialized;\nusing System.Linq;\nusing HttpUtility = Xero.Api.Infrastructure.Thir"
  },
  {
    "path": "Xero.Api/Common/XeroApi.cs",
    "chars": 1122,
    "preview": "using Xero.Api.Infrastructure.Http;\r\nusing Xero.Api.Infrastructure.Interfaces;\r\nusing Xero.Api.Infrastructure.RateLimit"
  },
  {
    "path": "Xero.Api/Common/XeroReadEndpoint.cs",
    "chars": 4814,
    "preview": "using System;\r\nusing System.Collections.Generic;\r\nusing System.Collections.Specialized;\r\nusing System.Linq;\r\nusing Xero"
  },
  {
    "path": "Xero.Api/Common/XeroRequest.cs",
    "chars": 415,
    "preview": "using System.Collections.Generic;\nusing Xero.Api.Infrastructure.Interfaces;\n\nnamespace Xero.Api.Common\n{\n    public cla"
  },
  {
    "path": "Xero.Api/Common/XeroResponse.cs",
    "chars": 725,
    "preview": "using System;\nusing System.Collections.Generic;\nusing System.Data.Linq;\nusing System.Linq;\nusing System.Runtime.Seriali"
  },
  {
    "path": "Xero.Api/Core/Endpoints/AccountsEndpoint.cs",
    "chars": 655,
    "preview": "using Xero.Api.Core.Endpoints.Base;\r\nusing Xero.Api.Core.Model;\r\nusing Xero.Api.Core.Request;\r\nusing Xero.Api.Core.Resp"
  },
  {
    "path": "Xero.Api/Core/Endpoints/AllocationEndpoint.cs",
    "chars": 2474,
    "preview": "using System;\nusing System.Collections.Generic;\nusing System.Linq;\nusing System.Net;\nusing System.Runtime.Serialization"
  },
  {
    "path": "Xero.Api/Core/Endpoints/AssociationsEndpoint.cs",
    "chars": 3120,
    "preview": "using System;\nusing System.Collections.Generic;\nusing System.Net;\nusing Xero.Api.Core.Model;\nusing Xero.Api.Infrastruct"
  },
  {
    "path": "Xero.Api/Core/Endpoints/AttachmentsEndpoint.cs",
    "chars": 2104,
    "preview": "using System;\nusing System.Collections.Generic;\nusing System.Linq;\nusing System.Net;\nusing Xero.Api.Common;\nusing Xero."
  },
  {
    "path": "Xero.Api/Core/Endpoints/BankTransactionsEndpoint.cs",
    "chars": 975,
    "preview": "using Xero.Api.Common;\r\nusing Xero.Api.Core.Endpoints.Base;\r\nusing Xero.Api.Core.Model;\r\nusing Xero.Api.Core.Request;\r\n"
  },
  {
    "path": "Xero.Api/Core/Endpoints/BankTransfersEndpoint.cs",
    "chars": 698,
    "preview": "using Xero.Api.Core.Endpoints.Base;\nusing Xero.Api.Core.Model;\nusing Xero.Api.Core.Request;\nusing Xero.Api.Core.Respons"
  },
  {
    "path": "Xero.Api/Core/Endpoints/Base/FourDecimalPlacesEndpoint.cs",
    "chars": 800,
    "preview": "using Xero.Api.Common;\nusing Xero.Api.Infrastructure.Http;\nusing Xero.Api.Infrastructure.Interfaces;\n\nnamespace Xero.Ap"
  },
  {
    "path": "Xero.Api/Core/Endpoints/Base/IXeroCreateEndpoint.cs",
    "chars": 663,
    "preview": "using System.Collections.Generic;\r\nusing Xero.Api.Common;\r\nusing Xero.Api.Infrastructure.Interfaces;\r\n\r\nnamespace Xero."
  },
  {
    "path": "Xero.Api/Core/Endpoints/Base/IXeroUpdateEndpoint.cs",
    "chars": 734,
    "preview": "using System;\r\nusing System.Collections.Generic;\r\nusing System.Linq;\r\nusing System.Text;\r\nusing Xero.Api.Common;\r\nusing"
  },
  {
    "path": "Xero.Api/Core/Endpoints/Base/XeroCreateEndpoint.cs",
    "chars": 1634,
    "preview": "using System.Collections.Generic;\r\nusing System.Linq;\r\nusing Xero.Api.Common;\r\nusing Xero.Api.Infrastructure.Http;\r\nusi"
  },
  {
    "path": "Xero.Api/Core/Endpoints/Base/XeroUpdateEndpoint.cs",
    "chars": 1653,
    "preview": "using System.Collections.Generic;\r\nusing System.Linq;\r\nusing Xero.Api.Common;\r\nusing Xero.Api.Infrastructure.Http;\r\nusi"
  },
  {
    "path": "Xero.Api/Core/Endpoints/BatchPaymentsEndpoint.cs",
    "chars": 690,
    "preview": "using Xero.Api.Core.Endpoints.Base;\nusing Xero.Api.Core.Model;\nusing Xero.Api.Core.Request;\nusing Xero.Api.Core.Respons"
  },
  {
    "path": "Xero.Api/Core/Endpoints/BrandingThemesEndpoint.cs",
    "chars": 611,
    "preview": "using Xero.Api.Common;\nusing Xero.Api.Core.Model;\nusing Xero.Api.Core.Response;\nusing Xero.Api.Infrastructure.Http;\n\nna"
  },
  {
    "path": "Xero.Api/Core/Endpoints/ContactGroupEndpoint.cs",
    "chars": 4877,
    "preview": "using System;\r\nusing System.Collections.Generic;\r\nusing System.Linq;\r\nusing System.Net;\r\nusing Xero.Api.Core.Endpoints."
  },
  {
    "path": "Xero.Api/Core/Endpoints/ContactsEndpoint.cs",
    "chars": 1936,
    "preview": "using System;\r\nusing System.Collections.Generic;\r\nusing System.Linq;\r\nusing Xero.Api.Common;\r\nusing Xero.Api.Core.Endpo"
  },
  {
    "path": "Xero.Api/Core/Endpoints/CreditNotesEndpoint.cs",
    "chars": 1021,
    "preview": "using System;\nusing Xero.Api.Common;\nusing Xero.Api.Core.Endpoints.Base;\nusing Xero.Api.Core.Model;\nusing Xero.Api.Core"
  },
  {
    "path": "Xero.Api/Core/Endpoints/CurrenciesEndpoint.cs",
    "chars": 651,
    "preview": "using Xero.Api.Core.Endpoints.Base;\nusing Xero.Api.Core.Model;\nusing Xero.Api.Core.Request;\nusing Xero.Api.Core.Respons"
  },
  {
    "path": "Xero.Api/Core/Endpoints/EmployeesEndpoint.cs",
    "chars": 630,
    "preview": "using Xero.Api.Core.Endpoints.Base;\nusing Xero.Api.Core.Model;\nusing Xero.Api.Core.Request;\nusing Xero.Api.Core.Respons"
  },
  {
    "path": "Xero.Api/Core/Endpoints/ExpenseClaimsEndpoint.cs",
    "chars": 694,
    "preview": "using Xero.Api.Core.Endpoints.Base;\nusing Xero.Api.Core.Model;\nusing Xero.Api.Core.Request;\nusing Xero.Api.Core.Respons"
  },
  {
    "path": "Xero.Api/Core/Endpoints/FilesEndpoint.cs",
    "chars": 4380,
    "preview": "using System;\r\nusing System.Collections.Generic;\r\nusing System.IO;\r\nusing System.Linq;\r\nusing System.Net;\r\nusing Xero.A"
  },
  {
    "path": "Xero.Api/Core/Endpoints/FoldersEndpoint.cs",
    "chars": 3385,
    "preview": "using System;\r\nusing System.Collections.Generic;\r\nusing System.Linq;\r\nusing System.Net;\r\nusing Xero.Api.Common;\r\nusing X"
  },
  {
    "path": "Xero.Api/Core/Endpoints/HistoryAndNotesEndpoint.cs",
    "chars": 1393,
    "preview": "using System;\nusing System.Collections.Generic;\nusing System.Linq;\nusing System.Net;\nusing Xero.Api.Core.Model;\nusing X"
  },
  {
    "path": "Xero.Api/Core/Endpoints/InboxEndpoint.cs",
    "chars": 3961,
    "preview": "using System;\nusing System.Collections.Generic;\nusing System.Linq;\nusing System.Net;\nusing Xero.Api.Core.Endpoints.Base;"
  }
]

// ... and 599 more files (download for full content)

About this extraction

This page contains the full source code of the XeroAPI/Xero-Net GitHub repository, extracted and formatted as plain text for AI agents and large language models (LLMs). The extraction includes 799 files (9.7 MB), approximately 2.6M tokens, and a symbol index with 3245 extracted functions, classes, methods, constants, and types. Use this with OpenClaw, Claude, ChatGPT, Cursor, Windsurf, or any other AI tool that accepts text input. You can copy the full output to your clipboard or download it as a .txt file.

Extracted by GitExtract — free GitHub repo to text converter for AI. Built by Nikandr Surkov.

Copied to clipboard!