コンテンツにスキップ
AchaduDevelopers
Developers/API/store_page_update
ストア

ストアページを更新

コンテンツ、スラッグ、SEO、投稿を更新します。

PATCH/store/pages/{id}store:write
行動

変更は検証され、応答する前にキー アカウントに保存されます。返されたリソースを信頼できる情報源としてクエリします。

効果

リソースを変更し、対応するドメイン イベントを発行できます。

繰り返し

ネットワーク障害が発生した場合は、リソースの状態を確認してから再試行してください。バックオフとジッターを使用して 429 と 5xx のみを自動的にやり直します。

リクエスト

idstring · pathリソース識別子。minLength 2 · maxLength 100必須
titlestring · bodyページの公開タイトル。minLength 2 · maxLength 160オプション
slugstring · body単一の公開ナメクジ。maxLength 80オプション
summarystring · bodyページの概要。maxLength 500オプション
bodystring · bodyMarkdown のページ コンテンツ。maxLength 50000オプション
coverstring · bodyHTTPS のカバー画像。uriオプション
seo_titlestring · body検索エンジン用のタイトル。maxLength 70オプション
seo_descriptionstring · body検索エンジン用の説明。maxLength 180オプション
publishedboolean · bodyページを公開します。オプション
AuthorizationBearer ach_live_...
Acceptapplication/json
範囲store:write

実行ファイルの例

curl
curl -X PATCH 'https://achadu.com/api/v1/store/pages/resource_id' \
  -H 'Authorization: Bearer ach_live_...' \
  -H 'Accept: application/json' \
  -H 'Content-Type: application/json' \
  --data '{
  "title": "Air fryer 5L",
  "slug": "string",
  "summary": "string"
}'

応答とエラー

すべての応答には request_id が含まれます。リストにはページネーションが追加されます。可変リソースは、操作後に永続化された状態を返します。

200 application/json
{
  "data": {
    "id": "site_01J...",
    "subdomain": "mystore",
    "name": "Ana's Finds",
    "theme": "light",
    "active": 1,
    "domain_verified": 1
  },
  "request_id": "req_01J..."
}
200操作が完了しました。
400Invalid parameter, body or transition.
401キーが見つからない、無効、期限切れ、または取り消されています。
402アカウント プランでは、このインターフェイスはリリースされません。
403A chave precisa do escopo store:write.
404このアカウントには機能が存在しません。
409The current state prevents this operation.
413The JSON body exceeds 128 KB.
4291 分あたり 120 リクエストのウィンドウを超えました。