
When you think of the office of the future, you might picture automated systems taking over labor-intensive, repetitive jobs. But that day has already come. Automated offices are becoming a reality thanks to the development of technology like cloud-based applications, software platforms, and enterprise resource planning tools that enable businesses to attain peak operating efficiency.
Corporate finance departments have cut expenses by roughly 30% over the past ten years by using automation solutions in fields like payroll, accounting, and procurement. With the help of these advances, several inefficiencies were removed from finance functions.
When I founded and grew my own consulting company, Pylink, I fully utilized automation by building up bots for finance jobs as a financial analyst and software developer. However, many financial offices still don’t, therefore they continue to waste a lot of time and money on doing simple operations.
The issue has been noticed by others in addition to me. According to research by the consulting company PwC, finance offices need to increase their efficiency and insight through automation and process improvement, which can save costs by double-digit percentages for several important operations. According to PwC’s research, automation may reduce the amount of time that humans spend on management reporting by 40%, tax accounting by 27%, and credit management, general accounting, and billing by 23%.
Deloitte came to similar conclusions: It states that intelligent automation reduces business process expenses by 25 to 40%, citing data from Ayehu. According to Gartner’s analysis, a company with 40 full-time accounting employees could save over $870,000 annually by automating operations and cutting out additional effort to correct human error.
How My Business Uses Bots for Finance: Simple, Quick Payments
Let me give you an example from my company that may be used as a case study to illustrate the value of bespoke automation. Despite being a tiny company, my Pylink team and I deal with a great deal of intricacy that creates difficulties when it comes to payments, such as the following:
- We must keep track of the time spent on each of our tasks because we are employed on a number of hourly projects.
- Since our customers come from many nations, they pay us in different currencies.
- On some projects, we use an in-house software engineering staff, but on others, we hire engineers from other nations as subcontractors.
- We have three companies—one UK-based, one EU-based, and one individual freelancer—from the standpoint of tax optimization.
- Every one of our businesses has a different bank account with a different currency, including USD, EUR, GBP, and HUF.
- We have ongoing expenses in several currencies, including taxes, full-time employee pay and benefits, office space and supplies, and software.
I use (and suggest) the following technologies to build a Python bot running in the cloud infrastructure of Amazon Web Services in order to create a payment system that would address these challenges (AWS).
Codebase:
- Python-based coding (downloadable for free)
Service that the code is executing on: AWS Lambda
- We can easily scale our code execution as necessary thanks to Lambda.
- This service only operates after it is triggered. A trigger event—which may be anything from an Alexa voice command to a planned calendar time—is set up after you insert your Python code into a Lambda function.
- Lambda is a cost-effective solution that only asks us to pay for the computing time we really utilize because it is server less.
Tool for bank operations: Wise API
- A software bridge called an API (application programming interface) enables communication between two applications. My team and I can simply access past transaction data and statement information using the Wise API, and we can also set up automatic payments. Additionally, it enables automated conversions and the tracking of currency exchange rates.
Ever hour Plus Ever hour API, time tracking
- Accurate time tracking, adaptable billing options, and budgeting flexibility are all provided by this software. It also effortlessly connects with project management applications like Asana, Trello, Jira, and GitHub.
Sender of email: Amazon Service for Simple Email
- We now have a flexible and secure method for delivering HTML emails from within any application, complete with data analytics to track deliveries and bounces, thanks to Amazon SES.
- If you activate SES from an application hosted in Amazon EC2 or through AWS Lambda, you can transmit up to 62,000 messages per month at no cost.
AWS Scheduler Event Bridge
- With the help of this technology, we can quickly direct our Python bot to carry out recurring financial tasks on a monthly or bimonthly basis.
- Event Bridge dramatically lowers our overhead because, like Lambda, it doesn’t need a server to function.
Notification in Slack: Slack API
- This API sends real-time alerts to let us know about the hours worked by our contractors and whether our customers have paid us.
Slack API + Amazon API Gateway are used for the bot’s Slack communications
- The Python bot can submit payment requests for our approval using the Slack API.
- Our bot can use API Gateway to automatically finalize each payment with only one click from our end.
- You can access more than a million API calls and a million messages every month for a year with API Gateway’s free tier.
Here is how I automated one multifunction use case using these tools: paying myself, my contractors, and my employees. Before I go into the most popular automation techniques, I’ll give you a high-level overview of the entire process.
Let’s now go over the steps:
- We utilize AWS Event Bridge to launch the Python bot that is kept in AWS Lambda on the first of each month.
- The bot retrieves timesheets for me, all workers, and contractors (in Pylink’s case, developers) via the Ever hour API.
- The bot then compiles the hours worked on each project, generates a timesheet, and generates an invoice (both PDFs). After that, it emails these documents to the clients.
- The bot also sends Slack notifications to Pylink’s staff about the contractors’ working hours. It also displays “approve” and “deny” buttons to request authorization before paying them.
- The bot sends a message to our own API (an always accessible public URL) over AWS API Gateway, which then runs additional code in a Lambda function to complete the transfer. If a member of Pylink’s management team accepts the request, the bot does this.
- The second Lambda function executes the payment using the Wise API.
- We use Event Bridge once more to arrange a new batch of follow-up procedures on the 14th of each month. This time, though, Event Bridge executes a separate piece of code kept in a distinct Lambda function.
- To track the transactions from the previous two weeks and determine whether the client has paid, this code makes use of the Wise API.
- The bot uses the Slack API to send a Slack confirmation to the Pylink team if the client has made a payment. The bot uses the Amazon SES service to email the customer if there hasn’t been a payment.
All of these operations had to be completed manually, costing time and energy that might now be used elsewhere. The best part is that we were able to set up this procedure without making a big time or financial commitment.
What Automation Can Do for You
Let’s now examine some of the most useful automation applications using the technologies I’ve just covered. I’ll provide some coding examples for your convenience as a resource for your in-house, contract, or freelance developers—or for you, should you decide to learn Python to help with your business’s or your clients’ projects.
Monitoring Projects and Work Hours
The bot (using Everhour) uses the “close the month” function at the end of each month to tally up all the time spent on various tasks:
- My consulting projects’ hours (revenue).
- Hours spent by developers on projects for clients (both revenue and cost).
- The number of developers’ hours used to create our own software (cost).
The function that follows is straightforward and returns a Pandas Data Frame, or a table with rows and columns, which contains all of the hours and projects for a certain user for a specified time period. Please keep in mind that, as was previously noted, this and any ensuing coding extracts are only a summary of the whole codebase and not a step-by-step guide to creating our bot.
Making a timesheet and invoice in PDF
The next step is to prepare timesheets and invoices after each employee’s project hours have been automatically monitored. You can make PDF files using a variety of Python programmes. We employ PyFPDF, a small document creation package that combines simplicity with the ability to include text, graphics, and shapes. It produces a neat and expert invoice, as you can see from the example below:
Although there are more sophisticated ways to create reports, PDF is a fantastic option because it’s a standard format used by all industries and it’s simple to produce. Additionally, it permits file transmission to anyone while guaranteeing that all fonts, pictures, tables, and formatting will be preserved. It can also be utilized offline and is independent of the operating system and hardware of your computer.
Utilizing email
An affordable and scalable tool for developing and deploying attractively written HTML emails is Amazon Simple Email Service. Additionally, SES’s data analytics monitor and disseminate details on feedback loop outcomes to alert you if any recipients report your email as spam, either unintentionally or as a result of the email being delivered to the incorrect address. Additionally, the analytics track engagement levels for each communication, such as open and click-through rates. Email marketing campaigns can really benefit from this capability.
Here is an illustration of Python code used to create and send a client an email with an attached invoice:
And here is the email it generates:
Automating Financial Transactions
We selected Wise for both personal and corporate bank accounts because we receive and expend money in many currencies and because this provider of financial technology offers competitive conversion rates, an easy-to-use user interface, and a flexible API with thorough documentation.
The following tasks are completed using this API:
- Gather statement data for every company and currency so I can see the overall and actual liquidity immediately.
- Extract historical transaction data so I may analyze patterns in various cost categories and determine whether the client has already paid the prior month’s invoice. The API sends a reminder email if they haven’t.
- Automate the transfer of funds.
Automate the transfer of funds
The code that we designed to carry out the first of these jobs (gathering statement information) is shown below:
You don’t need to create code to make automatic transfers for recurring fixed costs (salary, taxes, office fees, etc.); Wise features a scheduled payment option. The Wise API is helpful, though, if the amount is not constant but rather depends on a formula that can be calculated by an algorithm. In my situation, the remuneration of the business advisor stands out because it depends on the monthly revenue. The bot can determine our exact revenue level and, consequently, how much to pay the advisor by looking up the logged hours.
Risk Reduction Using a Two-Way Conversation with the Bot
It’s essential to monitor the bot’s activities because there can be coding errors that go undetected during testing. Slack provides real-time notifications, allowing us to quickly address any faulty code. Here are a few instances of notifications that show the bot is functioning properly:
Additionally, we set up the bot to ask the Pylink team for confirmation before each bank transfer. This aids in preventing errors brought on by human error. Imagine that a developer enters 825 hours for one ticket instead of 8.25 hours due to a typing error. We don’t send one hundred times more money than we owe thanks to a Slack approval step. The procedure provides a seamless experience while keeping the element of human verification.
The Slack API allows you to do a tonne of other features as well.
The Office of the Future
Businesses can prosper with the aid of automation. Companies that require more efficiency and control can be transformed by the technologies I outlined, particularly when it comes to transactional activities like accounts payable, accounts receivable, and other crucial accounting areas.
But the story doesn’t end here. The challenge for company leaders, according to McKinsey, is to cast a wider net in search of new efficiencies. The company is in favor of reinventing the entire finance operation and moving beyond merely transactional chores by taking the lead in fields like data analytics, which consolidate, streamline, and manage information throughout the entire company. I completely concur. I advise you to look into coding solutions that support your organization’s ownership of its solutions and advancement of its results-oriented culture. Adopting the strategies I’ve discussed here can help your business become more effective today while also offering you a glimpse of the opportunities that lie ahead.