parsecvpn/portainer-php-api 问题修复 & 功能扩展

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

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

parsecvpn/portainer-php-api

最新稳定版本:1.0.5

Composer 安装命令:

composer require parsecvpn/portainer-php-api

包简介

A PHP API client for Portainer CE

README 文档

README

Portainer PHP API client For the full API documentation implemented, please take a look at https://app.swaggerhub.com/apis/portainer/portainer-ce/2.21.4#/

Supported endpoint groups

  • Auth
  • Backup
  • CustomTemplates
  • Docker
  • Endpoints
  • LDAP
  • Motd
  • Gitops
  • Registries

Installation

Download the package using composer:

composer require ente/portainer-php-api

Then configure .env file with the following variables:

  • API_URL (e.g. localhost:9443)
  • USERNAME
  • PASSWORD
  • IGNORE_SSL (currently all requests are made with verify set to false)

Usage

require_once __DIR__ . "/vendor/autoload.php";
use Portainer\Portainer;
$portainer = new Portainer(__DIR__, ".env", "username", "password", "https://yourhost:9443");

echo var_dump($portainer->customTemplates()->list()); // array containing custom templates

统计信息

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

GitHub 信息

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

其他信息

  • 授权协议: GPL-3.0-only
  • 更新时间: 2025-06-04