Proposal to Strike Off Discrepancy

API doesn’t show that a Company is Proposal To Strike Off, where as the URI does

Example:

http://data.companieshouse.gov.uk/doc/company/08622846

Above URI link shows the company as Active - PTSO

API returns “status”: “active”,

The API is showing this correctly

“company_status”: “active”
“company_status_detail”: “active-proposal-to-strike-off”,

and the BETA site more clearly shows

Company status
Active — Active proposal to strike off

Frank Murphy, StatBooks Ltd

As Frank said. It’s the “company_status_detail” field which has the information you’re after.

Where were you looking? I checked Beta:

and API (via cURL):

curl -u{MyApiKey}: “https://api.companieshouse.gov.uk/company/08622846

Ah the guys have been referencing the status field, and not the detail field. Thanks!

The search API doesn’t show the “company_status_detail”, only the “company_status”

Indeed. It’d be annoying if you wanted to use the search to pull out that. Maybe put in a improvement / change request with CH?

You can get the info, anyway. There are already a few places where extra “categories” have been added or merged into existing fields (I’m thinking “community interest companies”).

If you don’t need live data you can probably pull this out of the data product.

I suspect you have not fully grasped how this works.

If you look at our entry

through the API there is no “company_status_detail”; our “company_status” is Active with a “company_status_detail” of " " which does not give a return value because there is nothing to return.

If you then compare with your original query for

http://beta.companieshouse.gov.uk/company/086228461

then you get "company_status"s and company_status_detail because there is detail present to return.

I am sure a CH staff member will correct this if I am wrong but it sure works for us!!

Hi - the field you’re talking about isn’t available on the search results, it requires an extra query to find it. Hence the confusion

I am just cannot replicate your problem - an API call on for the Company Profile for 086228461 as follows

https://api.companieshouse.gov.uk/company/{company_number}

returns both company_status and company_status_detail in the result regardless of whether I use the Try It page on this hub or through our own front end. For the vast majority of Companies company_status_detail is not appropriate and therefore there is no data that can be returned on a call.

An X-Y misunderstanding here? Up to @ian_barker to confirm but it seems what he is trying to do is:

“how can I search for / exclude companies by Proposal To Strike Off” (or some similar category)

or

“why doesn’t company search show X status?” (where X is PTSO etc.).

So he’s found an example in Beta, and looked for the “status” (e.g. https://api.companieshouse.gov.uk/company/08622846) - but “status” didn’t have the value he saw.

You gave a correct answer - but this hasn’t helped him since he then says:

The search API doesn’t show the “company_status_detail”, only the “company_status”

And then

field you’re talking about isn’t available on the search results

E.g. he’s now expecting to get this status (or the “company_status_detail”) from search e.g.
https://api.companieshouse.gov.uk/search/companies?q

…so round we go!

The canonical response is to yell at the original questioner “WHAT IS IT YOU ARE REALLY TRYING TO DO?”. Or (more politely but less helpfully) suggest they open a new thread since their original question was indeed answered.

If Ian is trying to use the search / company search request to look for company status which involves PTSO or stuff that isn’t in the company_status field
…the answer is my previous one e.g. probably the search won’t do what you want (read the spec / search this forum to check).
…as Frank said originally the “company_status_detail” field is available only when you do a company profile query (not a search) and only on companies to which one of the values which go in the field apply.
…So as @ian_barker says “it requires an extra query to find it” if you’ve located the company via the search request because he’ll then want to call company profile to check if the PTSO applies.

Again Ian might be able to do the search on offline data via the data product.