dcblogdev/laravel-companies-house 问题修复 & 功能扩展

解决BUG、新增功能、兼容多环境部署,快速响应你的开发需求

邮箱:yvsm@zunyunkeji.com | QQ:316430983 | 微信:yvsm316

dcblogdev/laravel-companies-house

最新稳定版本:v2.0.0

Composer 安装命令:

composer require dcblogdev/laravel-companies-house

包简介

A Laravel Companies House package

README 文档

README

There is a Discord community. https://discord.gg/VYau8hgwrm For quick help, ask questions in the appropriate channel.

Latest Version on Packagist Total Downloads

Logo

A Laravel package for reading Companies House.

Documentation and install instructions

Companies House API documentation can be found at: https://developer.company-information.service.gov.uk/api/docs/

Application Register

To use Companies House an application needs creating at https://developer.companieshouse.gov.uk/developer/applications

Install

Take a note of the API key and add it to your .env file

COMPANIES_HOUSE_KEY= 

Via Composer

composer require dcblogdev/laravel-companies-house 

You can publish the config file with:

php artisan vendor:publish --provider="Dcblogdev\CompaniesHouse\CompaniesHouseServiceProvider" --tag="config"

When published, the config/companieshouse.php config file contains:

<?php return [ /*  * the key is set from the Companies House to identify the application  * https://developer.companieshouse.gov.uk/developer/applications  */ 'key' => env('COMPANIES_HOUSE_KEY'), ];

Usage

In a controller import the class:

use Dcblogdev\CompaniesHouse\Facades\CompaniesHouse; 

In a view or closure call the facade:

CompaniesHouse::get('path');

You call CompaniesHouse followed by get:: this will run a GET request followed by the endpoint you want to call, for instance, to call company profile (https://developer.companieshouse.gov.uk/api/docs/company/company_number/company_number.html)

CompaniesHouse::get('company/123456');

To make things a little easier there is also trait classes provided:

Each Trait class provides convenient methods that call the endpoints, processes the data, and returns JSON of the results.

Search

Search across all indexed information.

CompaniesHouse::search($term)

Searches companies

CompaniesHouse::searchCompany($term)

Search Officer

CompaniesHouse::searchOfficer($term)

Search Officer Disqualified

CompaniesHouse::searchOfficerDisqualified($term)

Companies

Get Company

CompaniesHouse::getCompany($companyNumber)

Get Company Address

CompaniesHouse::getCompanyAddress($companyNumber)

Get Company Officer

CompaniesHouse::getCompanyOfficer($companyNumber)

Get Company Filing

CompaniesHouse::getCompanyFiling($companyNumber)

Get Company Filing Item

CompaniesHouse::getCompanyFilingItem($companyNumber)

Get Company Insolvency

CompaniesHouse::getCompanyInsolvency($companyNumber)

Get Company Charge

CompaniesHouse::getCompanyCharge($companyNumber)

Get Company Charge Item

CompaniesHouse::getCompanyChargeItem($companyNumber)

Get Company Establishment

CompaniesHouse::getCompanyEstablishment($companyNumber)

Get Company Register

CompaniesHouse::getCompanyRegister($companyNumber)

Get Company Exemption

CompaniesHouse::getCompanyExemption(($companyNumber)

Officer

Get Officer Appointment

CompaniesHouse::getOfficerAppointment($officerId)

Get Officer Disqualification

CompaniesHouse::getOfficerDisqualification($officerId)

Get Officer Disqualification Corp

CompaniesHouse::getOfficerDisqualificationCorp($officerId)

Change log

Please see the changelog for more information on what has changed recently.

Contributing

Contributions are welcome and will be fully credited.

Contributions are accepted via Pull Requests on Github.

Pull Requests

  • Document any change in behaviour - Make sure the readme.md and any other relevant documentation are kept up-to-date.

  • Consider our release cycle - We try to follow SemVer v2.0.0. Randomly breaking public APIs is not an option.

  • One pull request per feature - If you want to do more than one thing, send multiple pull requests.

Security

If you discover any security related issues, please email dave@daveismyname.com email instead of using the issue tracker.

License

license. Please see the license file for more information.

统计信息

  • 总下载量: 13.83k
  • 月度下载量: 0
  • 日度下载量: 0
  • 收藏数: 11
  • 点击次数: 3
  • 依赖项目数: 0
  • 推荐数: 0

GitHub 信息

  • Stars: 11
  • Watchers: 2
  • Forks: 2
  • 开发语言: PHP

其他信息

  • 授权协议: MIT
  • 更新时间: 2026-01-04

承接程序开发

PHP开发

VUE

Vue开发

前端开发

小程序开发

公众号开发

系统定制

数据库设计

云部署

网站建设

安全加固