Collecting invoices from websites and services automatically
Introduction
If you have a company and you need to collect all the invoices (e.g. PDF) from different websites and services for accounting reasons, that may take a lot of time. It's especially time consuming if you have many recurrent invoices (e.g. monthly invoices from many different services).
Downloading the invoices (e.g. PDF) from all the websites takes a lot of time. Some websites send the invoices by email, some websites don't and everyone does it in a different way.
I propose a simple protocol to collect the invoices automatically.
Proposed Solution
Let's say that company Alpha is a customer of company Beta. Sometimes Beta needs to send a PDF invoice to Alpha.
Alpha logs in to the dashboard of the service provider Beta and in the billing section adds a URL like:
https://example.com/collect/invoices/LONG_RANDOM_TOKEN
Then Beta can send a normal HTTP POST request with the PDF file (or any other format) whenever generates a new invoice (beside other methods like sending the PDF by email, which can coexist).
Alpha uses the normal HTTP status codes for a semantic response.
Alpha gives a URL with a different LONG_RANDOM_TOKEN to each authorized service, so that they can be sure about the origin of the request.
Privacy & Security Considerations
No considerable privacy or security concerns are expected, but we welcome community feedback.
The process of manually collecting the invoices from each provider has many drawbacks:
- It's time consuming.
- You often need to pass the authentication and 2FA each time that you need to download a single invoice, so it is also a security concern, because you need to give access to cloud providers to non-technical people or external collaborators.
- If you are not very careful, it's also easy to forget to download an invoice from a provider sometimes.
Moreover, the SaaS that currently try to automate this process, always need the login credentials (and 2FA) for all the services from which the invoices should be downloaded, which is a high security risk, making these services unusable.