API randomly returning 401s & 503s

Hi,

The API seems to be randomly returning errors sometimes. We have made no changes to our system before these issues started occurring. Below are some examples (times are in 24hr format):

Can you please confirm whether there were/are any API issues corresponding to those timestamps? I have checked the health of the api and it seems to be ok, but I am not sure how much confidence can be put in that call:

curl -I -k -X GET -H “Cache-Control: no-cache” https://api.companieshouse.gov.uk/healthcheck

HTTP/1.1 200 OK
Date: Mon, 08 Apr 2024 15:19:08 GMT
Content-Length: 0
Connection: keep-alive
Server: CompaniesHouse

Regards

Tagging @MArkWilliams due to his previous help with API issues

FYI another error has just happened now for:

Same here. Searches are not working, getting 500s instead

We’re having issues too, getting 401s on all requests on all APIs

Anyone seen an update - looks as if API is down for company search, gateway errors when trying to access/login to accounts

Just adding another voice here - sorry it’s more noise than signal on what I imagine may be a stressful day.

The main companies house search (through https://find-and-update.company-information.service.gov.uk/) also died around the same time. When trying to log into these forums (or any account stuff over here) I was getting 502s.

I imagine all of these issues will be stemming from the auth system being on the fritz.

Just seeing same errors reported above again from 9:35pm after a few hours stable … most specifically 401s.

Hi all, seeing an outage again at ~0800 this morning, it seems we are still experiencing reliability issues.

@MArkWilliams / @macreman

Are you able to advise on this?

Thanks

Hi, not wanting to create more noise, we are seeing also a 503 when we try to search /officers from a company that doesn’t exist.
Ex:
Calling:
https://api.company-information.service.gov.uk/company/SC821809B → 404
https://api.company-information.service.gov.uk/company/SC821809B/officers → 503

This is happening since Saturday Maintenance. Has the behaviour changed?

The auth service seems to have fallen down again. All API calls are returning 401 Unauthorized for us, and we get a 502 when trying to sign into the developer hub.

Why on earth is there not an external API status page (or even just a notification on this site) for this?

(also experiencing a lot of 401’s)

We apologise for the issues you have been experiencing over the last 36 hours.
we had a major release/deployment over the weekend and experienced severe service issues, mainly around authentication resulting in 502 type errors (and others)
We resolved this today (9th April 2024) approx 13:00hrs and continue to monitor and investigate exact causes.
Thank you for your patience.

Hello, we have been getting read timeout errors when trying to access the Profile API today (at 14.30, 14.49 and 15.04 BST).

The last successful response we received was also at 14.30pm. Are you aware of any issue going on at the moment?

EDIT this message was sent 4pm on April 8th but for some reason it didn’t actually get sent until a day after

Thanks

Service seems better but started getting timeouts again this morning. It seems to be intermittent though.

Hello.we are still facing issue whenever we call this URL
https://api.companieshouse.gov.uk/company/10363521/officers

{
  "statusCode": 406,
  "body": "",
  "headers": {
    "date": "Wed, 10 Apr 2024 14:22:17 GMT",
    "content-length": "0",
    "connection": "close",
    "access-control-allow-credentials": "true",
    "access-control-allow-headers": "X-RateLimit-Query, origin, content-type, content-length, user-agent, host, accept, authorization",
    "access-control-expose-headers": "X-RateLimit-Window, X-RateLimit-Limit, X-RateLimit-Remain, X-RateLimit-Reset, Location, www-authenticate, cache-control, pragma, content-type, expires, last-modified",
    "access-control-max-age": "3600",
    "set-cookie": [
      "JSESSIONID=6C7B46A31B39AB8B0E5AB3C07D0C210C; Path=/; HttpOnly"
    ],
    "x-ratelimit-limit": "600",
    "x-ratelimit-remain": "561",
    "x-ratelimit-reset": "1712758958",
    "x-ratelimit-window": "5m",
    "server": "CompaniesHouse"
  },
  "request": {
    "uri": {
      "protocol": "https:",
      "slashes": true,
      "auth": null,
      "host": "api.companieshouse.gov.uk",
      "port": 443,
      "hostname": "api.companieshouse.gov.uk",
      "hash": null,
      "search": null,
      "query": null,
      "pathname": "/company/12447079/officers",
      "path": "/company/12447079/officers",
      "href": "https://api.companieshouse.gov.uk/company/12447079/officers"
    },
    "method": "GET",
    "headers": {
      "Authorization": "Basic  OMITTED",
      "Accept": "text/json"
    }
  }
}

This URL works though:
https://api.companieshouse.gov.uk/company/10363521

I have just called that url and all works correctly.
your JSON contains the incorrect company number (12447079, it should be 10363521) do you have the correct output for the correct call?

output should look something like this:-
{
“active_count”: 2,
“etag”: “aa1ad050c2a65f25ee1f93edce84265d7a57c544”,
“items”: [
{
“address”: {
“address_line_1”: “17 Lonsdale Road”,
“country”: “United Kingdom”,
“locality”: “Weybridge”,
“postal_code”: “KT13 0TG”,
“premises”: “Dragonsrealm Ltd”
},
“appointed_on”: “2016-09-07”,
“is_pre_1992_appointment”: false,
“links”: {
“self”: “/company/10363521/appointments/TQ1d3t4jtDLK9O1rH7C03KJa9GI”,
“officer”: {
“appointments”: “/officers/sd42ClQLWsaRhCfKrud4K5DZA4U/appointments”
}
},
“name”: “QUINN, Adele”,
“officer_role”: “secretary”,
“person_number”: “213674650001”
},
{
“address”: {
“address_line_1”: “17 Lonsdale Road”,
“country”: “United Kingdom”,
“locality”: “Weybridge”,
“postal_code”: “KT13 0TG”,
“premises”: “Dragonsrealm Ltd”
},
“appointed_on”: “2016-09-07”,
“is_pre_1992_appointment”: false,
“country_of_residence”: “United Kingdom”,
“date_of_birth”: {
“month”: 10,
“year”: 1970
},
“links”: {
“self”: “/company/10363521/appointments/dqiZrOFlEArBxm64JQk_bY1P5nk”,
“officer”: {
“appointments”: “/officers/neiVZ6lFRiIuLNYrakZtnNhKdfg/appointments”
}
},
“name”: “QUINN, Christopher”,
“nationality”: “British”,
“occupation”: “It Contractor”,
“officer_role”: “director”,
“person_number”: “213674640001”
}
],
“items_per_page”: 35,
“kind”: “officer-list”,
“links”: {
“self”: “/company/10363521/officers”
},
“resigned_count”: 0,
“inactive_count”: 0,
“start_index”: 0,
“total_results”: 2
}

@MArkWilliams seeing timeouts and failed searches again. Could we perhaps have a sticky thread with regular updates on the progress to fix the technical issues as it has been several days of intermittent outages now.

Can confirm we’re still seeing sporadic errors, e.g.:

Failed to query [https://api.company-information.service.gov.uk/officers/Bv5y7XFXUDXOHbbcMfZlzAxiIx8/appointments?start_index=0&items_per_page=50]. HTTP Status [502] - 11/04/2024 13.02

We apologise for the issues you have been experiencing over the last 3-4 days.
A temporary (partial) fix was applied on 9th April 2024 approx 13:00hrs which made a substantial difference to the service stability.
We have Just (11th April 15:15hrs) deployed the full fix, but this deployment itself caused a few minutes of disruption.
Thank you for your patience.

2 Likes