承接 fiskaly/fiskaly-sdk-php 相关项目开发

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

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

fiskaly/fiskaly-sdk-php

最新稳定版本:1.2.200

Composer 安装命令:

composer require fiskaly/fiskaly-sdk-php

包简介

fiskaly Cloud-TSE SDK for PHP

README 文档

README

The fiskaly SDK includes an HTTP client that is needed1 for accessing the kassensichv.io API that implements a cloud-based, virtual CTSS (Certified Technical Security System) / TSE (Technische Sicherheitseinrichtung) as defined by the German KassenSichV (Kassen­sich­er­ungsver­ord­nung).

Supported Versions

  • PHP 7.1+

Features

  • Automatic authentication handling (fetch/refresh JWT and re-authenticate upon 401 errors).
  • Automatic retries on failures (server errors or network timeouts/issues).
  • Automatic JSON parsing and serialization of request and response bodies.
  • Future: [1] compliance regarding BSI CC-PP-0105-2019 which mandates a locally executed SMA component for creating signed log messages.
  • Future: Automatic offline-handling (collection and documentation according to Anwendungserlass zu § 146a AO)

Integration

Composer

The PHP SDK is available for a download via Composer.

Packagist - Package Repository.

Simply execute this command from the shell in your project directory:

$ composer require fiskaly/fiskaly-sdk-php

Or you can manually add the package to your composer.json file:

"require": { "fiskaly/fiskaly-sdk-php": "*" }

then run

$ composer install 

Finally, be sure to include the autoloader in your code:

<?php require_once('vendor/autoload.php');

Service

Additionally, to the SDK, you'll also need the fiskaly service. Follow these steps to integrate it into your project:

  1. Go to https://developer.fiskaly.com/downloads#service
  2. Download the appropriate service build for your platform
  3. Start the service

Usage

Demo

<?php require __DIR__ . '\\vendor\\autoload.php'; use FiskalyClient\FiskalyClient; /** initialize the fiskaly API client class using credentials */ try { $client = FiskalyClient::createUsingCredentials('http://localhost:8080/invoke', $_ENV["FISKALY_API_KEY"], $_ENV["FISKALY_API_SECRET"], 'https://kassensichv.io/api/v1'); } catch (Exception $e) { exit($e); } /** get version of client and SMAERS */ try { $version = $client->getVersion(); echo "Version: ", $version, "\n\n"; } catch (Exception $e) { exit($e); }

Another way to create FiskalyClient object is using context string. You can get it via getContext method and save it in memory via $_SESSION variable or persistent in cache or database.

<?php /** initialize the fiskaly API client class using context */ try { $client = FiskalyClient::createUsingContext('http://localhost:8080/invoke', $_SESSION["FISKALY_CONTEXT"]); } catch (Exception $e) { exit($e); }

Client Configuration

The SDK is built on the fiskaly Client which can be configured through the SDK.

A reason why you would do this, is to enable the debug mode.

Enabling the debug mode

The following code snippet demonstrates how to enable the debug mode in the client.

<?php /** configure client */ try { $config_params = array( 'debug_level' => 4, 'debug_file' => __DIR__ . '../../fiskaly.log', 'client_timeout' => 5000, 'smaers_timeout' => 2000, ); $config = $client->configure($config_params); echo "Configuration: ", $config, "\n\n"; } catch (Exception $e) { exit($e); }

Related

fiskaly/fiskaly-sdk-php 适用场景与选型建议

fiskaly/fiskaly-sdk-php 是一款 基于 PHP 开发的 Composer 扩展包,目前已累计 266.41k 次下载、GitHub Stars 达 7, 最近一次更新时间为 2026 年 01 月 04 日, 在 PHP 生态内属于活跃度较高的组件。

它主要适用于以下技术方向: 「php」 「src」 「fiskaly」 等业务场景。在实际项目中,围绕这些方向常见需要落地的问题包括:接口对接、性能调优、并发安全、与既有框架(Laravel / ThinkPHP / Yii / Webman 等)的兼容适配,以及生产环境的日志埋点与稳定性保障。

我们在过去多个企业项目中使用过 fiskaly/fiskaly-sdk-php 或与其功能相近的方案,如果你在选型或落地过程中遇到问题,例如 版本兼容、二次改造、私有化封装、与内部系统对接、生产 BUG 排查,欢迎联系我们协助评估。

围绕 fiskaly/fiskaly-sdk-php 我们能提供哪些服务?
定制开发 / 二次开发

基于 fiskaly/fiskaly-sdk-php 在你已有业务上做功能扩展、字段裁剪、UI 适配、与内部账号 / 权限 / 日志系统的深度对接。

BUG 修复 & 性能优化

线上偶发问题、内存泄漏、慢查询、并发异常等排查修复;针对高流量场景做缓存、队列、索引层面的调优。

项目外包 & 长期维护

承接完整的项目从需求 → 设计 → 开发 → 上线 → 长期运维;也可按月提供技术保姆服务。

yvsm@zunyunkeji.com QQ:316430983 微信:yvsm316 西安尊云信息科技 · 专注 PHP / Go / 分布式系统研发

统计信息

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

GitHub 信息

  • Stars: 7
  • Watchers: 12
  • Forks: 3
  • 开发语言: PHP

其他信息

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