Skip to main content

https://sfadigital.blog.gov.uk/2016/12/07/an-agile-revolution-on-victoria-street/

An agile revolution on Victoria Street

Posted by: , Posted on: - Categories: Apprenticeship service
The agile board for the HMRC API services
Our agile board for the HMRC API services

In order for employers to access their apprenticeship funding, the digital apprenticeship service needs to know how much levy has been collected by HMRC.

The best way to do this is to make the machines running the apprenticeship service talk to the machines that run HMRC levy collections. To do this, we needed to create a connection between the computers called an application programming interface (API).

We needed a whole new set of APIs to get the information we needed from HMRC. I'm a senior platform developer at the Department for Business, Energy and Industrial Strategy (BEIS), but I had prior experience of working with the HMRC Digital Tax Platform. Because of this, I was able to suggest to the apprenticeship team that they built the APIs as a service on that platform.

Building APIs

I work for BEIS, but the APIs needed to be housed and built inside HMRC. So we set up a small team with HMRC to build them. Because of my knowledge of the apprenticeship service requirements and previous experience of the tax platform, I was seconded onto the team.

We worked out of the BEIS offices on Victoria Street in London. It was quite revolutionary: a cross-departmental, agile team. Every Thursday we had a co-location day with people from the apprenticeship service, including the SFA team from Coventry.  There was a lot of strong communication going on and it took us about two months to build the API services.

Each API we built answers a different question:

  1. How much levy has been declared for each PAYE scheme? To link an employer’s payroll schemes to their apprenticeship account, employers need to go through a Government Gateway log-in to access HMRC data. This means they’ll need their Government Gateway user ID to register.
  2. What is the English percentage for each payroll? The English percentage is the percentage of the employer’s payroll relating to employees who live in England. HMRC calculates it and it is used to allocate the right proportion of levy funds to each employer’s account, in order that they have the right amount to spend on apprenticeships.
  3. What payroll schemes does each user of the apprenticeship service have access to? There’s an amazing array of ways in which people use payroll schemes. Many corporations, especially those that have franchisees, run more than 150 PAYE schemes. As we said in our blog post on building registration, these employers want to choose how to join their schemes together. This API shows that a user of the apprenticeship service has the authority to access funds collected through the levy for the payroll schemes they control.
  4. Are certain individuals really employed by certain organisations during specific dates? To confirm that each apprenticeship is actually taking place, we check to see that each individual is employed by the organisation that buys the training on the dates entered when that employer has added an apprentice.

Sandbox testing

One of the useful features of the tax platform was that we could build a sandbox that would allow our application to do early testing of the APIs before we had any live data in place. In order to use any of the APIs you have to register with the tax platform so HMRC knows who you are. If users have a developer ID they get access to the sandbox so they can test their code. If they have a production ID they get routed back to the live service because they are a real user. (We built private APIs that are only visible to users who we thought were safe.)

HMRC had a whole bunch of changes they needed to make to their PAYE systems to enable the apprenticeship service to work. For example, the employer payment summary form had to be amended to carry levy information. Changes to the back-end legacy systems are still in development, so the early-testing capability is key.

As far as the apprenticeship service is concerned, it just has to send queries to each API. There’s an endpoint (the answer to each query) and the sandbox we can route calls through. Rather than an end-to-end test to prove it all works, at each section we have contract-based guarantees. The APIs are essentially a set of promises. Each piece of the chain makes a promise about what it will do to the next piece along, and each piece has to fulfil its promise. We can test the promises at each stage so we have confidence that when we link them all together they’ll do the right thing.

Experience helps

My experience of the HMRC tax platform proved invaluable. If I had gone in naively and asked for things based on what I needed, I could have been frustrated. Knowing how they worked, as well as several of the key people, and the underlying principles made it a lot easier to find solutions. We could move forward rapidly where it might otherwise have taken months to sort out.

Everyone involved has worked really well to enable the apprenticeship service to get information out in a way that’s simple and easy to use. We’ve had to go through a lot of loops to get the right answers. And we’ve had strong collaboration and communication throughout.

Read more

The digital apprenticeship service goes live in April 2017. We’ll be blogging our progress here on the SFA Digital blog. Don't miss a post - sign up for email updates or subscribe to our RSS feed.

Sharing and comments

Share this page

1 comment

  1. Comment by Paul D posted on

    Is there a web service that we can utilise to create/amend/delete our apprenticeship information?