DEV Community

Leandro Marcos Moreira
Leandro Marcos Moreira

Posted on

How to get UK company data (Companies House) in a single API call

If you've integrated the official UK Companies House API, you know the pain:
to build a useful picture of a company you need three separate calls — the
company profile, the officers/directors, and the persons with
significant control (PSC)
— and then stitch and normalise them yourself.

For KYB, due diligence or lead enrichment, that's a lot of plumbing on every lookup.

The data you usually want

  • Profile: name, status, type, incorporation date, registered office, SIC codes
  • Officers/directors: who runs it (active and resigned)
  • PSC: who ultimately owns/controls it

Doing it directly (three calls)

BASE=https://api.company-information.service.gov.uk
curl -u "$CH_KEY:" $BASE/company/09446231
curl -u "$CH_KEY:" $BASE/company/09446231/officers
curl -u "$CH_KEY:" $BASE/company/09446231/persons-with-significant-control
Enter fullscreen mode Exit fullscreen mode

Then you merge them, handle missing fields, add caching and rate limiting... per lookup.

Doing it in one call

I bundled these into a single endpoint that returns one normalised, cached JSON
response:

curl "https://api.firmfox.co.uk/v1/company/09446231" \
  -H "X-RapidAPI-Key: YOUR_KEY" \
  -H "X-RapidAPI-Host: api.firmfox.co.uk"
Enter fullscreen mode Exit fullscreen mode
{
  "company_name": "MONZO BANK LIMITED",
  "company_status": "active",
  "date_of_creation": "2015-02-18",
  "registered_office_address": { "locality": "London", "postal_code": "EC2A 2AG" },
  "officers": { "active_count": 14, "total_count": 29, "items": [ /* ... */ ] },
  "persons_with_significant_control": { "total_count": 3, "items": [ /* ... */ ] }
}
Enter fullscreen mode Exit fullscreen mode

Python

import requests

def get_company(number, key):
    r = requests.get(
        f"https://api.firmfox.co.uk/v1/company/{number}",
        headers={"X-RapidAPI-Key": key, "X-RapidAPI-Host": "api.firmfox.co.uk"},
    )
    r.raise_for_status()
    return r.json()

c = get_company("09446231", "YOUR_KEY")
print(c["company_name"], "-", c["officers"]["active_count"], "active directors")
Enter fullscreen mode Exit fullscreen mode

Node.js

const res = await fetch("https://api.firmfox.co.uk/v1/company/09446231", {
  headers: {
    "X-RapidAPI-Key": process.env.RAPIDAPI_KEY,
    "X-RapidAPI-Host": "api.firmfox.co.uk",
  },
});
const c = await res.json();
console.log(c.company_name, c.officers.active_count, "active directors");
Enter fullscreen mode Exit fullscreen mode

When this is handy

  • KYB / onboarding: verify a business and its controllers in one request.
  • Due diligence: pull officers + PSC for counterparty checks.
  • Lead enrichment: turn a company number into a full record in your CRM.

It's free to start on RapidAPI, and the data comes from UK Companies House
(Crown copyright, Open Government Licence). I built it because I was tired of the
three-call stitching — hope it saves someone else the same work.

👉 https://rapidapi.com/leandromarcosmoreira/api/uk-company-lookup-enrichment

Feedback welcome — what fields/filters would make this genuinely useful for you?
(Filing-change monitoring/alerts is on my list.)

Canonical/links

Top comments (0)