Company not found on Web, but found in Api

Hello

Could you please check.

Company number: 00174100

website returns Not Found

https://beta.companieshouse.gov.uk/search/companies?q=00174100

but in same time API by request

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

returns

status: 200    
{
      "etag": "a92a239043c5b396603f6e354ddc97d59c871c8d",
      "registered_office_address": {},
      "can_file": false
}

Thank you
Dmitry

@d_e_golubev

Unfortunately there appears to be a data issue regarding this company, which is why you are experiencing the issues. I have raised the issue with our support team for investigation and resolution.

Thanks

@mfairhurst

Hello

I have similar problem again

return company https://beta.companieshouse.gov.uk/search/companies?q=SC48434
but Api request: https://api.companieshouse.gov.uk/company/SC48434
returns:

"errors": [
{
  "error": "company-profile-not-found",
  "type": "ch:service"
}

]

similar problem with sc488532, sc526707, sc516933, sc513392, but for these numbers if change to upper case, then will return profile (SC488532 is working). By our info similar records approx 4000.

Dmitry

@d_e_golubev

The issues raised in the subsequent post are not issues with the service and/or data and is behaving as expected. The issue is relating to the company number and the endpoints being used.

If we take the first example SC48434, this is not a valid company number. Company numbers are currently 8 characters in length and if prefixed with 2 characters then, if referencing as a specific resource, must be upper case.

If you search for the company, as you are doing using the web site URL SC48434 - Find and update company information - GOV.UK
then the search algorithms match the company number provided to the most appropriate match, in this case, company number SC048434 (NB the additional 0 after the SC).

Therefore when you call the https://api.companieshouse.gov.uk/company endpoint with company number SC48434 the company doesn’t exist and so you receive the error. If you call https://api.companieshouse.gov.uk/company/SC048434 then this will return the company in question.

With the other examples as you have indicated the sc needs to be upper case to return the data.

It maybe more appropriate to use the search endpoint to search for the company number and then use the “self” link to navigate to the company profile. The search is documented

https://developer.companieshouse.gov.uk/api/docs/search/companies/companysearch.html

For example if you call (with appropriate credentials):

https://api.companieshouse.gov.uk/search/companies?q=SC48434

this returns:

{
“page_number”: 1,
“kind”: “search#companies”,
“items_per_page”: 20,
“items”: [
{
“kind”: “searchresults#company”,
“address_snippet”: “45 Auchenkeld Avenue, Heathhall, Dumfries, DG1 3QY”,
“date_of_creation”: “1971-02-19”,
“description”: “SC048434 - Incorporated on 19 February 1971”,
“address”: {
“address_line_2”: “Heathhall”,
“postal_code”: “DG1 3QY”,
“address_line_1”: “Auchenkeld Avenue”,
“premises”: "45 ",
“locality”: “Dumfries”
},
“description_identifier”: [
“incorporated-on”
],
“company_type”: “ltd”,
“title”: “W.L.& W. PEACOCK (TRUCK SERVICES) LIMITED”,
“company_number”: “SC048434”,
“links”: {
“self”: “/company/SC048434”
},
“company_status”: “active”
}
],
“total_results”: 1,
“start_index”: 0
}

You can then follow the self link to return the profile data.

Hope this helps

Thanks

@mfairhurst