承接 codeitamarjr/laravel-cro-api 相关项目开发

从需求分析到上线部署,全程专人跟进,保证项目质量与交付效率

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

codeitamarjr/laravel-cro-api

最新稳定版本:0.1.1

Composer 安装命令:

composer require codeitamarjr/laravel-cro-api

包简介

Laravel SDK for Ireland's CRO Open Services API.

README 文档

README

Tests

A small Laravel SDK for Ireland's CRO Open Services API.

CRO Open Services is the Companies Registration Office REST API for integrating company and submission data into applications. This package exposes a Laravel HTTP client, service container binding, and facade for the public Open Services endpoints under /cws.

Official service: https://services.cro.ie/

Install

composer require codeitamarjr/laravel-cro-open-services

Publish the config if you need to override defaults:

php artisan vendor:publish --tag=cro-open-services-config

Configuration

Set your CRO Open Services credentials in .env:

CRO_EMAIL=you@example.com
CRO_API_KEY=your-key

More explicit CRO_OPEN_SERVICES_EMAIL and CRO_OPEN_SERVICES_KEY variables are also supported if you want to separate this SDK from older app configuration later.

Usage

use Codeitamarjr\LaravelCroOpenServices\CroOpenServicesClient;
use Codeitamarjr\LaravelCroOpenServices\Facades\CroOpenServices;

public function show(CroOpenServicesClient $cro)
{
    $companies = $cro->searchCompaniesByNumber('123456');
    $matches = $cro->searchCompaniesByName('ryanair');
    $count = $cro->getCompanyCount(['company_name' => 'smith']);
}

$company = CroOpenServices::getCompany('123456');
$submission = CroOpenServices::getSubmission('6191121', '2');
$submissions = CroOpenServices::getCompanySubmissions('123456');
$submissionCount = CroOpenServices::getSubmissionCount(['company_num' => '54512', 'company_bus_ind' => 'c']);
$latestByType = CroOpenServices::searchSubmissionsByCompanyNumber('123456');
$dictionary = CroOpenServices::getDataDictionary();

Available methods

  • searchCompaniesByNumber(string $companyNumber, string $companyBusIndicator = 'C'): array
  • searchCompaniesByName(string $companyName, string $companyBusIndicator = 'C', int $searchType = 2, int $skip = 0, int $max = 25): array
  • searchCompanies(array $parameters): array
  • getCompanyCount(array $parameters): int
  • getCompany(string $companyNumber, string $companyBusIndicator = 'c'): array
  • getCompanySubmissions(string $companyNumber, string $companyBusIndicator = 'c'): array
  • searchSubmissions(array $parameters): array
  • getSubmissionCount(array $parameters): int
  • getSubmission(string $submissionNumber, string $documentNumber): array
  • searchSubmissionsByCompanyNumber(string $companyNumber, string $companyBusIndicator = 'C'): array
  • getDataDictionary(): array

Endpoint coverage:

  • GET /companies
  • GET /companycount
  • GET /company/{companyNumber}/{companyBusIndicator}
  • GET /company/{companyNumber}/{companyBusIndicator}/submissions
  • GET /submissions
  • GET /submissioncount
  • GET /submission/{submissionNumber}/{documentNumber}

The data dictionary is exposed as a local Company and SubmissionDoc field map based on CRO's published data dictionary.

Scope

This package targets CRO Open Services. It does not attempt to wrap unrelated Irish company APIs, screen-scrape CORE pages, or provide paid document-streaming helpers until those endpoints are explicitly modelled and tested.

Local development

composer install
composer test

Run the live CRO Open Services smoke test only when credentials are available:

export CRO_EMAIL=you@example.com
export CRO_API_KEY=your-key
composer test:live

If no credentials are exported, the live test uses CRO's official public test credential pair. It checks company number 83740 with company/business indicator C, verifies that /company/83740/c returns the documented FOSTER WHEELER IRELAND LIMITED payload shape, verifies numeric /companies search for 83740, verifies name /companies search for ryanair, and exercises CRO's documented examples for company count, submission search, submission count, and one submission document.

统计信息

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

GitHub 信息

  • Stars: 0
  • Watchers: 0
  • Forks: 0
  • 开发语言: PHP

其他信息

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

承接程序开发

PHP开发

VUE

Vue开发

前端开发

小程序开发

公众号开发

系统定制

数据库设计

云部署

网站建设

安全加固