Sitelet https://github.com/XeroAPI/Xero-OpenAPI/issues/134
Skip to content

Change tags to on operations to group methods differently #134

Description

@SidneyAllen

This started as an issue on our PHP SDK
XeroAPI/xero-php-oauth2#53

To summarize, at this time all Accounting endpoints are tagged "Accounting" in the yaml file and when code is generated all operations (methods) are put into the same AccountingApi class. With so many endpoints and actions you can perform the AccountingApi class is large.

Changing how operations are tagged is fairly simple, but will have ripple effects across SDKs, documentation and sample code. So, this is not a change that we will be implementing at this time but will consider along with other requests that result in major refactoring of assets.

I'd like to hear what ppl think about this idea? Do you like creating a singleton (AccountingApi) and working with that or would you like to create an instance of AccountApi, ContactApi, InvoiceApi, etc?

Alternatively, we could group based on scope and not endpoint.
https://developer.xero.com/documentation/oauth2/scopes

  • transactions, reports, settings, contacts, journals

In the above scenerio 'TransactionsApi class would have all the banktransactions, banktransfer,creditnote, invoice, overpayment, payment, etc together.

Look forward to hearing ppl's thoughts.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions