hosting

GET /v1/sites/{siteId}/geo-restriction

Which countries may reach this site.

すべての hosting エンドポイント

すべての開発者向けドキュメント

認証

ベアラー トークンとして API キーを送信します。キーには sites.view 権限が付与されている必要があります。権限のないキーは 404 ではなく 403 で拒否されます。

このエンドポイントは組織IDを受け付けません。お使いのキーによって所属する組織がすでに特定されており、レスポンスはその組織にスコープされます。

試してみる

アングルブラケット内のすべてをご自身の値に置き換え、キーのプレースホルダーをご利用中のダッシュボードのキーに置き換えてください。

curl -X GET https://api.zinndigital.com/v1/sites/{siteId}/geo-restriction \
  -H "Authorization: Bearer zdk_live_…"

ログインしていますか?ダッシュボード内のAPIコンソールでは、実際の組織IDやお客様ご自身のキーが自動入力され、ライブAPIに対してリクエストが実行されるため、実際のレスポンスを確認することができます。 API コンソールでこのエンドポイントを開く

詳細

The site's country rule and what each enforcement layer is doing about it. Not under /cdn/, deliberately. A country rule is a site control with up to two enforcement points — the CDN edge and the origin server — and a site with no CDN still gets it at the origin. It applies on every product line. The edge state is read from the provider, not from our record. "We asked for it" and "it is set" are different claims: they diverge when a customer edits the rule in their own CDN dashboard, after a CDN switch, or after a failed apply. Read edge and origin separately — a rule live at one layer only is a real, partial state, and enforcing: false with a detail means the layer is not protecting the site whatever mode says. Requires sites.view.

パラメータ

名前タイプ必須これがその内容です
siteId (path)UuidはいSite ID (UUIDv7).

返信

名前タイプ必須これがその内容です
modestring<off, allow, block>はいallow admits only the listed countries and refuses everywhere else; block refuses the listed ones and serves everywhere else; off is no rule at all.
countriesstring[]はいISO-3166 alpha-2, upper-case. Empty when mode is off.
exempt_search_enginesbooleanはいWhether verified search-engine crawlers were asked to bypass the rule.
search_engines_exempt_at_edgebooleanはいWhether that exemption is actually in force, which is not the same as whether it was requested — only a provider that verifies a crawler by forward/reverse DNS can carry it.…
edgeGeoRestrictionLayerはいWhat ONE enforcement layer can do, and what it is doing right now. Four fields rather than one flag because "this provider cannot do it" and "it failed this morning" need…
originGeoRestrictionLayerはいWhat ONE enforcement layer can do, and what it is doing right now. Four fields rather than one flag because "this provider cannot do it" and "it failed this morning" need…

このエンドポイントが返すエラー

401 · 403 · 404 · 429