Welcome - I just tried this (some hours after you report) and it works correctly for me e.g. no 500 error.
Do you have any odd things (such as incorrectly URL-encoded parameters) in the URL you’re requesting? That seems the most likely cause.
I checked and it doesn’t seem to be the outstanding issue Companies House have where having a trailing “/” seems to cause errors with some endpoints - but not with others
… I’ve just tried that with the basic PSC list endpoint and that caused no issues e.g. both the following return a normal result as JSON and not an error message and/or 500 status.
curl -u MY_API_KEY: “https://api.company-information.service.gov.uk/company/NF004299/persons-with-significant-control/”
curl -u MY_API_KEY: “https://api.company-information.service.gov.uk/company/NF004299/persons-with-significant-control”
(Note * it’s still affecting the Company Profile endpoint, just checked.)
If the problem persists for you you can search this forum to see if there’s reference to a similar situation as you’re facing.
Alternatively if you would like help from other forum users you could try posting as much data as you can e.g.
- exactly the URL you’re requesing (endpoint)
- whether you’ve managed to use this successfully before (or indeed any part of the API)
- plus any other details of the request you can e.g. http headers if you know* , details of the environment / language / tool you’re using to send the request in. * The only thing you should avoid is posting your whole API key or the complete http
Authorization: Basic ...
header.
Hope this helps.