hosting

POST /v1/sites/{siteId}/wordpress/uploads/{uploadId}/complete

Finish a resumable upload; the platform assembles and installs it.

Све hosting крајње тачке

Сва документација за програмере →

Аутентификација

Пошаљите API кључ као bearer токен. Ова крајња тачка не наводи конкретну дозволу у спецификацији, па свом кључу доделите најмања неопходна овлашћења и проверите одговор уместо да претпостављате.

Ова крајња тачка не прихвата id организације. Ваш кључ већ идентификује организацију којој припада, а одговор је ограничен на њу.

Испробајте

Замените све што је у угластим заградама сопственим вредностима, а чувар места кључа кључем са своје контролне табле.

curl -X POST https://api.zinndigital.com/v1/sites/{siteId}/wordpress/uploads/{uploadId}/complete \
  -H "Authorization: Bearer zdk_live_…" \
  -H "Content-Type: application/json" \
  -d '{ "sha256": <string> }'

Пријављени сте? API конзола на вашој контролној табли попуњава ваш прави id организације и ваш сопствени кључ, и покреће захтев према живом API-ју како бисте могли да видите стварни одговор. Отворите ову крајњу тачку у API конзоли

Детаљи

Every part must have arrived (422 names the missing ones). sha256 is the whole-file checksum in composite form: the SHA-256 of the parts' raw SHA-256 digests concatenated in part order. A client can compute that one part at a time, without hashing the whole file at once. Answers 202 with the upload in assembling. The platform then streams the parts together and verifies the length and checksum. It installs with the same checks as installSiteWordPressPlugin / installSiteWordPressTheme, and the upload becomes installed or failed. Poll getSiteWordPressUpload. 503 if the installer is unreachable; the upload stays resumable and can be completed again.

Параметри

НазивТипОбавезноШта је ово
siteId (path)UuidДаSite ID (UUIDv7).
uploadId (path)stringДаA resumable upload's id, from startSiteWordPressUpload.

Тело захтева

НазивТипОбавезноШта је ово
sha256stringДа—

Одговор

НазивТипОбавезноШта је ово
idstringДа—
kindstring<plugin, theme>Да—
statusstring<open, assembling, installed, failed>Да—
sizeintegerДа—
part_sizeintegerДаBytes per part, chosen by the platform. Every part but the last is exactly this long.
part_countintegerДа—
file_namestringДа—
activatebooleanДа—
messagestringДаOn failed, what went wrong, written for the customer. Empty otherwise.
expires_atstringДа—
created_atstringДа—
finished_atstringДа—
received_partsinteger[]НеPresent while open — the part numbers already stored.

Грешке које ова крајња тачка може вратити

401 · 403 · 404 · 409 · 422 · 429 · 503