Skip to content

v0.11.0

Choose a tag to compare

@cristi-boboc cristi-boboc released this 17 Aug 20:56
· 4 commits to main since this release

PidginHost PHP SDK v0.11.0

Install from Packagist:

composer require pidginhost/sdk:0.11.0

Versions v0.8.0 through v0.10.2 shipped without entries in this file. The
Go changelog
records those schema changes; they apply to this SDK too.

Changed (breaking)

  • AttachIPv4 → AttachIPv4Request, AttachIPv6 → AttachIPv6Request. The server attach routes now have distinct request and response components, so the generated request types are renamed.

  • POST /api/cloud/servers/{id}/detach-ipv4/ returns ServerDetachIPv4Response instead of DetachIPv4Response. The detached field is unchanged. DetachIPv4Response still serves the standalone POST /api/cloud/ipv4/{id}/detach/ route.

  • Six enum components renamed off content-derived names. Where several serializers expose a field called status, type or priority over different choice sets, drf-spectacular was naming the component by hashing its values, so adding a single choice silently renamed the type. These are now pinned:

    Was Now
    Priority3cdEnum TicketPriorityEnum
    Status03cEnum InvoiceStatusEnum
    Status63aEnum ServiceStatusEnum
    StatusA57Enum ResourceStatusEnum
    StatusEf2Enum TicketStatusEnum
    Type85bEnum ClusterTypeEnum

    A one-time rename: the names no longer move when a choice set gains a value. ClusterType.type had already been renamed once this way (Type2faEnum → Type85bEnum when beta was added) and now shares the pre-existing ClusterTypeEnum, which carried the identical dev/prod/beta set under a second name.

Added

  • reboot on AttachIPv4Request and AttachIPv6Request (boolean, default false). A public address is written to the machine config and the guest OS only reads it while booting, so on a running server the address is inert until a restart. Set reboot to have the API issue that restart.
  • reboot_required and rebooted on AttachIPv4Response and AttachIPv6Response. attached alone could describe a server that answers neither ping nor SSH on the new address; these say whether a restart is still owed and whether one was performed. A stopped server reports both false and is never booted just to pick the address up, and reboot: true on a rescue-mode or transitioning server keeps reboot_required: true rather than rebooting out of the rescue ISO.
  • AttachIPv6Response is new. POST /api/cloud/servers/{id}/attach-ipv6/ previously echoed the request body back, so there was no attached flag to check.
  • Rescue mode: POST /api/cloud/servers/{id}/rescue/enter/ and .../rescue/exit/, typed as RescueEnterQueued / RescueExitQueued.
  • Boot ISOs: GET /api/cloud/servers/{id}/boot-isos/ with BootISO, PaginatedBootISOList, and IsoBootRequest.
  • Glue / personal-DNS records: /api/domain/domain/{domain}/dns/ and /api/domain/domain/{domain}/dns/{name}/, typed as DNSGlue and PaginatedDNSGlueList.
  • TicketMessage, ServiceCompany, DestroyProtectionResponse, and CategoryEnum.

Fixed

  • attach-ipv4 reports a missing field as a missing field. Omitting ipv4 returned Object with address=None does not exist, which reads as a bad address rather than a bad field name; it is now 400 {"ipv4": ["This field is required."]}.
  • attach-ipv6 rejects a conflicting address with a 400 instead of 200 plus a message, so a failed attach no longer looks like a success. Re-attaching the address a server already has is idempotent.

Notes

In this SDK, model class names match the component names; accessors follow (getRebootRequired()).