carmelosantana/porkbun-sdk 问题修复 & 功能扩展

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

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

carmelosantana/porkbun-sdk

最新稳定版本:1.0.0

Composer 安装命令:

composer require carmelosantana/porkbun-sdk

包简介

A PHP library for interacting with the Porkbun API.

关键字:

README 文档

README

PHP library for interacting with the Porkbun API.

Supports

Interactions with Porkbun's API for;

  • Domain management
  • DNS record management
  • SSL certificate retrieval

Features

  • Manage domains: Update name servers, list domains, and more.
  • Handle DNS records: Create, edit, retrieve, and delete DNS records.
  • Manage SSL certificates: Retrieve SSL certificate bundles for your domains.

Install

Include PorkbunSdk in your project with Composer:

composer require carmelosantana/porkbun-sdk

Requirements:

Usage

To use the Porkbun API, you need to have an API key and secret from Porkbun. You can obtain these by logging into your Porkbun account and generating an API key.

Domain

✅ Update the name servers for a domain.

$domain = new PorkbunSdk\Domain('your_api_key', 'your_secret_api_key');

$response = $domain->updateNameServers('example.com', [
    'ns1.example.com',
    'ns2.example.com'
]);

print_r($response);

DNS

✅ Create a new DNS A record for a domain.

$dns = new PorkbunSdk\DNS('your_api_key', 'your_secret_api_key');

$response = $dns->createRecord('example.com', 'A', '1.1.1.1', 'www');

print_r($response);

SSL

✅ Retrieve the SSL certificate bundle for a domain.

$ssl = new PorkbunSdk\SSL('your_api_key', 'your_secret_api_key');

$response = $ssl->getCertificate('example.com');

print_r($response);

Testing

To run the test suite:

composer test

Requirements:

  • Pest is used for testing.

Support

Community support is available on Discord.

Funding

If you find this project useful or use it in a commercial environment, please consider donating:

Changelog

  • 1.0.0 - Aug 29, 2024
    • Initial release of the PorkbunSdk library with support for Domain, DNS, and SSL management.

License

Code and documentation are released under the MIT License.

统计信息

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

GitHub 信息

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

其他信息

  • 授权协议: MIT
  • 更新时间: 2024-08-29