Download the PHP package ashleighsims/companies-house-api-wrapper without Composer
On this page you can find all versions of the php package ashleighsims/companies-house-api-wrapper. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Download ashleighsims/companies-house-api-wrapper
More information about ashleighsims/companies-house-api-wrapper
Files in ashleighsims/companies-house-api-wrapper
Package companies-house-api-wrapper
Short Description Wrapper for the Companies House API. Covering all endpoints available to developers.
License MIT
Homepage https://github.com/ashleighsims/companies-house-api-wrapper
Informations about the package companies-house-api-wrapper
Companies House Api Wrapper
This is a PHP wrapper for the Companies House API. Auto discovery for Laravel has been added so you should be able to use this out of the box with Laravel.
When using this it's best advised to use an environment file to store the API key and base url. This ensures you don't have any API keys sat in the source code of the application and also not committed into any version control.
This currently does not include the Document API which is also available.
Installation
Before you can start using the Companies House API you will need to register your application in your companies house developer account: https://developer.companieshouse.gov.uk/developer/applications
The API Key provided from registering your application with Companies House will be required.
Via Composer
Laravel
If you're using this package in Laravel auto discovery has been enabled so you should be able to hit the ground running (when using Laravel 5.5 and beyond).
if you aren't using Laravel 5.5 and above you will need to manually register some bits...
Register the provider in the app.php file:
Optionally register the Facade:
Please ensure you've added the below environment variables to your .env
file before starting.
Environment Variables
Add the following environment variables to your .env file.
Usage
This covers all the endpoints which are currently available on the Companies House Website as of 18th February 2020.
Each endpoint is listed below with code examples. For Laravel users you can type-hint the CompaniesHouseApiWrapper through constructors or through the facade.
Laravel
Dependency Injection Via Controller
Facade
General Usage
Search
Search All
Arguments:
- Query (In this case the name of a person)
Optional Arguments:
- Items Per Page (Default 35)
- Start Index (Default 0)
Search Company
Arguments:
- Query (In this case the name of a person)
Optional Arguments:
- Items Per Page (Default 35)
- Start Index (Default 0)
Search Officer
Arguments:
- Query (In this case the name of a person)
Optional Arguments:
- Items Per Page (Default 35)
- Start Index (Default 0)
Search Disqualified Officer
Arguments:
- Query (In this case the name of a person)
Optional Arguments:
- Items Per Page (Default 35)
- Start Index (Default 0)
Company Profile
Get
Arguments:
- Company Number
Registered Office Address
Get
Arguments:
- Company Number
Company Officers
List
Arguments:
- Company Number
Optional Arguments:
- Items Per Page (Default 35)
- Start Index (Default 0)
- Register Type (Allowed options: directors, secretaries, llp-members) - Only works when Register View is true
- Register View (Allowed options: true or false, Default: false)
- Order By (Allowed options: appointed_on, resigned_on, surname)
Filing History
Get
Arguments:
- Company Number
- Transaction ID
List
Arguments:
- Company Number
Optional Arguments:
- Category (Comma Separated),
- Items Per Page (Default 35),
- Start Index (Default 0)
Insolvency
Get
Arguments:
- Company Number
Charges
Get
Arguments:
- Company Number
- Charge ID
List
Arguments:
- Company Number
Optional Arguments:
- Items Per Page (Default 35),
- Start Index (Default 0)
Officer Appointment List
List
Arguments:
- Officer ID
Officer Disqualifications
Get Natural
Arguments:
- Officer ID
Get Corporate
Arguments:
- Officer ID
UK Establishment Companies
List
Arguments:
- Company Number
Persons with Significant Control
List
Arguments:
- Company Number
Optional Arguments:
- Items Per Page (Default 35),
- Start Index (Default 0)
- Register View (Allowed options: true or false, Default: false)
Get Individual
Arguments:
- Company Number
- PSC ID
Get Corporate
Arguments:
- Company Number
- PSC ID
Get Legal Persons
Arguments:
- Company Number
- PSC ID
List Statements
Arguments:
- Company Number
Optional Arguments:
- Items Per Page (Default 35),
- Start Index (Default 0)
- Register View (Allowed options: true or false, Default: false)
Get Statement
Arguments:
- Company Number
- Statement ID
Get Super Secure Person
Arguments:
- Company Number
- Super Secure ID
Company Registers
Get
Arguments:
- Company Number
Company Exemptions
Get
Arguments:
- Company Number
Change log
Please see the changelog for more information on what has changed recently.
Security
If you discover any security related issues, please email [email protected] instead of using the issue tracker.
License
license. Please see the license file for more information.