No description
Find a file
2023-01-05 12:55:52 +01:00
generated First generated API 2023-01-05 12:55:52 +01:00
src First generated API 2023-01-05 12:55:52 +01:00
composer.json First generated API 2023-01-05 12:55:52 +01:00
hetzner-dns-api-modified.json First generated API 2023-01-05 12:55:52 +01:00
hetzner-dns-api.json First generated API 2023-01-05 12:55:52 +01:00
jane-configuration.php First generated API 2023-01-05 12:55:52 +01:00
LICENSE Initial commit 2023-01-05 12:38:13 +01:00
License.txt First generated API 2023-01-05 12:55:52 +01:00
README.md First generated API 2023-01-05 12:55:52 +01:00

A PHP Client for the Hetzner DNS API

Hetzner is a hosting provider, which offers a REST API for their DNS service.

This SDK has been generated with JanePHP using the provided API documentation.

The generated client has been modified to throw exceptions in case of an error answer.

Installation

You will need a PSR-18 compatible client implementation. We used symfony/http-client.

Most probably your framework already has some client instantiated, you just can pass to the Openapi client.

Notes

  1. As the DateFormat from Hetzner is not consistent (sometimes it shows microseconds, sometimes not, and in verified fields there is even more trailing information) you might want to add the HetznerDatesPlugin to your HTTP-Client. It's job is to replace all date strings with a consistent form (you'll loose the microseconds fractions from DateTimes, which have one)
  2. The original hetzner OpenAPI specification mentions the Auth-API-Token as header parameter of each request, instead of applying the security scheme globally. To have a more sophisticated client, this has been rewritten. (Diff hetzner-dns-api.json with hetzner-dns-api-modified.json)