Data8 Logo

DescriptionEndpoint URLsParametersAdvanced OptionsResultsCredit UsageSample CodeLive Demo
FindCompanyByNameOrPostcode
Finds a company based on a simple name or postcode search
Description

Checks to find any matching companies filtered on company name and/or postcode. You can filter on any partial name or partial postcode - a wildcard is assumed.

The status parameter allows you to restrict the results to only the status code you want. The most useful of these is "Active" which restricts only currently active companies.

The return value includes an array of CompaniesHousePartialResult records that include a summary of the information of each company that matches the search. The details from one or more of these matches can then be passed to the GetCompanyDetails method to retrieve the full details of that match.

Endpoint URLs

To connect to this service you'll need to use one of these endpoints:

Protocol URL
JSON
JSON
https://webservices.data-8.co.uk/CompaniesHouse/FindCompanyByNameOrPostcode.json
OPEN API
OPEN API
https://webservices.data-8.co.uk/swagger/CompaniesHouse/swagger.json
SOAP
SOAP
https://webservices.data-8.co.uk/companieshouse.asmx
Parameters
The following parameters can be supplied to this method:
Name Description
username
username

See the available authentication methods. If you are using username & password authentication, specify the username to authenticate as. If you are using API Key authentication and you are not using the JSON, Javascript or ADO APIs, use your API Key here with the prefix apikey-, e.g. apikey-ABCD-1234-EFGH-5678

password
password

If you are using username & password authentication, specify the password to use for authentication. Otherwise leave this blank.

companyname
companyname

The company name to search for. Fuzzy matching is applied, so this does not need to be exact. Leave as null or "" to filter only by postcode

postcode
postcode

The postcode to search in. Note that this is based on the registered address of the company, not any trading addresses. Leave as null or "" to search only by companyname, or use partial postcodes such as "CH" to filter by a wider area than a single postcode.

companystatus
companystatus

The status a company must have in order to be included in the results. This filter is ignored if it is left as null or "".

The most useful value for this parameter is normally "Active", so only currently active companies are returned.

options
options

An array of options that control further details of how this method operates. See the Advanced Options section below, for more information.

Advanced Options
The following options can be specified as part of the option parameter. Each option is specified as a key/value pair. The list of available names is shown below, along with a description of the allowable values for that name.
Name Description
Common Options
ApplicationName
ApplicationName
Gives the name of the calling application - used to break down usage by application in the usage reports on the dashboard.
Results
This method returns an object containing the following fields:
Name Description
Status
Status

Indicates whether the method call was successful, or if some error occurred. If the Success field is true, the other results described below can be used to get the results of the method. If Success is false, some error occurred in calling the method, such as the authentication failed or the account is out of credits. The details of the error can be obtained from the ErrorMessage field, and any other results should be ignored.

Results
Results

Contains an array of CompaniesHousePartialResult structures that contain a summary of the matching companies. Each entry in the array has the following properties:

  • CompanyName - the legal name of the company
  • CompanyNumber - the company registration number. Pass this number to the GetCompanyDetails method to get more information on the company
  • CompanyCategory - the category for the company (Public Limited Company, Private Limited Company etc.)
  • CompanyStatus - the status of the company (Active, Dissolved etc.)
  • Town - the town in which the company is registered
Credit Usage

Requests to this method do not consume credits, but you must have some CompaniesHouse credits available.

Sample Code

Request Format

{
  "companyname": "Data8",
  "postcode": "",
  "companystatus": "Active",
  "options": {}
}

Response Format

{
  "Status": {
    "Success": true,
    "CreditsRemaining": 1000
  },
  "Results": [
    {
      "CompanyName": "DATA8 LIMITED",
      "CompanyNumber": "04773536",
      "CompanyCategory": "Private Limited Company",
      "CompanyStatus": "Active",
      "Town": "WREXHAM"
    },
    {
      "CompanyName": "DATA85 LTD",
      "CompanyNumber": "10719428",
      "CompanyCategory": "Private Limited Company",
      "CompanyStatus": "Active",
      "Town": ""
    }
  ]
}

Depending on your chosen authentication method you will need to modify this request slightly:

API Key

Post the request to
https://webservices.data-8.co.uk/CompaniesHouse/FindCompanyByNameOrPostcode.json?key=your-api-key
and do NOT include the username or password properties in the request JSON document.
Read More

Username and Password

Post the request to
https://webservices.data-8.co.uk/CompaniesHouse/FindCompanyByNameOrPostcode.json
and include username and password properties in the request JSON document.
Do not use for client-side requests!
Read More

JWT Token

Obtain a JWT token for your user and post the request to
https://webservices.data-8.co.uk/CompaniesHouse/FindCompanyByNameOrPostcode.json
Include the JWT token in the request headers as:
Authorization: Bearer your-jwt-token
Read More
Live Demo
Parameter Value
Parameters
companyname
companyname
postcode
postcode
companystatus
companystatus
Common Options
ApplicationName
ApplicationName
Credits Remaining Today: 5
Try It Now!
An error has occurred. This application may no longer respond until reloaded. Reload 🗙