hosting

POST /v1/sites/{siteId}/sitemap

Start a sitemap crawl.

Wszystkie punkty końcowe hosting

Uwierzytelnianie

Wyślij klucz API jako token bearer. Klucz musi posiadać uprawnienie sites.panel_access; klucz bez niego jest odrzucany z kodem 403, a nie 404.

Ten punkt końcowy nie wymaga identyfikatora organizacji. Twój klucz już identyfikuje organizację, do której należy, a odpowiedź jest do niej ograniczona.

Wypróbuj

Zastąp wszystko w nawiasach ostrych własnymi wartościami, a zastępczy znacznik klucza kluczem ze swojego pulpitu nawigacyjnego.

curl -X POST https://api.zinndigital.com/v1/sites/{siteId}/sitemap \
  -H "Authorization: Bearer zdk_live_…" \
  -H "Content-Type: application/json" \
  -d '{  }'

Zalogowany? Konsola API w Twoim panelu uzupełnia rzeczywiste identyfikator organizacji oraz Twój własny klucz i wykonuje żądanie względem aktywnego API, dzięki czemu możesz zobaczyć rzeczywistą odpowiedź. Otwórz ten punkt końcowy w konsoli API

Szczegóły

⛔ **`202`, and the returned state describes a job that has STARTED.** A crawler walks the whole site and may take minutes; the sitemap does not exist when this returns. Poll `getSiteSitemap` until `running` is false. Answering `200` here would be the status-code equivalent of telling the customer their sitemap is ready. `upload` writes `sitemap.xml` into the webspace, overwriting any existing file. Requires `sites.panel_access`.

Parametry

NazwaTypWymaganeCo to jest
siteId (path)UuidTakSite ID (UUIDv7).

Treść żądania

NazwaTypWymaganeCo to jest
frequencystring<always, hourly, daily, weekly, monthly, never, yearly>NieThe `changefreq` written into the generated XML. A guideline to search engines, not a guarantee.
uploadbooleanNieOverwrite `sitemap.xml` in the webspace when the crawl finishes.

Odpowiedź

NazwaTypWymaganeCo to jest
ever_runbooleanTakHas a crawl ever been run for this site?
runningbooleanTakIs a crawl in progress? ⛔ Computed as *not in a terminal state*, so a state we have never seen reads as still working rather than as finished.
statestringTakThe vendor's own job state, verbatim. Empty when none has run.
created_atstringTakWhen the most recent crawl started. Empty when none has run.
outputstringTakThe crawler's own output, if it produced any.
uploadbooleanTakWhether the crawl writes `sitemap.xml` into the webspace.
frequenciesstring[]TakThe change frequencies this site's crawler accepts.

Błędy, które ten punkt końcowy może zwrócić

401 · 403 · 404 · 422 · 429 · 503