fix: correct mailbox endpoint path and quota field name

- get_domain_mailboxes: was POST /api/v1/get/mailboxes/{domain},
  correct path is GET /api/v1/get/mailbox/all/{domain}
- Quota percentage field is percent_in_use, not quota_used_in_percent

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
2026-02-27 08:18:08 +01:00
parent 6f7c66e2c4
commit 8644282ecb
3 changed files with 3 additions and 4 deletions

View File

@@ -93,9 +93,8 @@ class WooCow_API {
return $this->request( 'GET', '/api/v1/get/mailbox/' . rawurlencode( $email ) );
}
/** Mailcow uses POST for domain-filtered mailbox listing */
public function get_domain_mailboxes( string $domain ): array {
return $this->request( 'POST', '/api/v1/get/mailboxes/' . rawurlencode( $domain ) );
return $this->request( 'GET', '/api/v1/get/mailbox/all/' . rawurlencode( $domain ) );
}
public function create_mailbox( array $data ): array {