PSC not giving a response

So if there is a psc statement, works fine, if it has people listed then just returns 1. Something changed or an internal error?

https://api.companieshouse.gov.uk/company/12334486/persons-with-significant-control-statements

error

https://api.companieshouse.gov.uk/company/12173467/persons-with-significant-control-statements

fine

Welcome - in this case the first company - 12334486 - has no PSC statements. The second one - 12173467 - has statements. I have linked to the online Companies House site so you can see that.

So if you request the URL ending persons-with-significant-control-statements (the Statements Endpoint) as the documentation says you get a http 404 response code (not found) and no data (http response body).

If you want to find out whether there are statements or not you can either call this endpoint and trap any errors OR if you examine the Company profile - e.g. request:

https://api.companieshouse.gov.uk/company/12334486

… and examine the links member of the response (a CompanyProfile resource) for a persons_with_significant_control_statements member there. If there are PSCs you should find a persons_with_significant_control member in links.

Note you can have both statement(s) and a list of PSCs in some cases. Here is an “Overseas Entity” example (linked to the online site):

https://api.companieshouse.gov.uk/company/OE001282/persons-with-significant-control

Here’s the company profile resource from your second example - I have formatted it and removed some of the fields for clarity (indicated with a “…”)

{
    "company_number": "12334486",
    "links": {
        "self": "/company/12334486",
        "filing_history": "/company/12334486/filing-history",
        "persons_with_significant_control": "/company/12334486/persons-with-significant-control",
        "officers": "/company/12334486/officers"
    },
    ...
}

Hope this helps.

Yes, something did change.

We made the change to remove the error json when statements were not found for two reasons.
· The error message for failing to retrieve PSC statements was incorrect as it made reference to PSCs instead of statements
· Not having an error json made error handling easier to work with for our internal apps

Hope that clarifies the situation.

Hi Mark,

Thanks for clarifying. Before my script was going of the error and now it breaks down. Would be a simple enough update but was just making sure this is something that was intended,