hosting
GET /v1/sites/{siteId}/ftp-users
List a site's FTP accounts.
Аутентификация
Отправьте ключ API в качестве токена носителя (bearer token). Ключ должен иметь разрешение sites.view; ключ без него отклоняется с кодом 403, а не 404.
Этот эндпоинт не принимает идентификатор организации. Ваш ключ уже определяет организацию, к которой он принадлежит, и ответ ограничивается ее рамками.
Попробовать
Замените всё в угловых скобках на собственные значения, а плейсхолдер ключа — на ключ из вашей панели управления.
curl -X GET https://api.zinndigital.com/v1/sites/{siteId}/ftp-users \
-H "Authorization: Bearer zdk_live_…"Вошли в систему? Консоль API в вашей панели управления автоматически подставляет реальный идентификатор вашей организации и ваш собственный ключ, а также выполняет запрос к работающему API, чтобы вы могли увидеть актуальный ответ. Откройте эту конечную точку в API-консоли
Подробнее
The FTP accounts on the site's hosting package, including the package's own primary account so the customer can see it exists. No password is returned for any of them, and none can be read back: the vendor does expose the primary account's live credentials in cleartext, and this platform deliberately never calls that endpoint. limit is the effective ceiling — the lower of what the package permits and what the customer bought, with either side being unlimited yielding to the other. permitted and can_create are separate because the screen says different things: "your plan does not include this" is not "you have used all of them". 404 for a site with no vendor hosting package. Requires sites.view.
Параметры
| Имя | Тип | Обязательно | Что это |
|---|---|---|---|
siteId (path) | Uuid | Да | Site ID (UUIDv7). |
Ответ
| Имя | Тип | Обязательно | Что это |
|---|---|---|---|
data | SiteFtpUser[] | Да | The accounts on the package, the primary one first. |
limit | VendorAllowance | Да | The effective ceiling on FTP accounts for this site. |
permitted | boolean | Да | Whether the package type includes FTP at all. This is the flag behind "your plan does not include this". |
can_create | boolean | Да | permitted, and the effective ceiling has room. This is the flag behind "you have used all of them". Two fields rather than one because those are different sentences, and a… |
Ошибки, которые может возвращать этот эндпоинт
401 · 403 · 404 · 429 · 503