コンテンツにスキップ

イベントの予約フォーム設定を置き換える

PUT
/api/v1/events/{id}/booking-form-settings
curl --request PUT \
--url https://app.goyoka.com/api/v1/events/2489E9AD-2EE2-8E00-8EC9-32D5F69181C0/booking-form-settings \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '{ "time_selectable": true, "provider_selectable": true, "allow_auto_assign": true, "reveal_auto_assigned_provider": true, "notice": "example", "waitlist_mode": "SEQUENTIAL", "waitlist_offer_hours": 1 }'

予約フォームで時間・担当者を選ばせるか、おまかせを許すか、おまかせの担当者を見せるか、備考、キャンセル待ちの方式と回答期限。PUT本文はGET⁠のdata.override⁠にあるtime_selectable・provider_selectable・allow_auto_assign・reveal_auto_assigned_provider・notice⁠の5欄が必須で、override⁠で包まず、応答専用のeffective⁠も送らないでください。4⁠つの真偽値はそれぞれnull⁠で今のイベントの値を保ちます(お店の初期値はイベントを作った時にしか写らず、既存イベントへは戻ってきません)。notice⁠はnull⁠で今の値を保ち、空文字またはtrim後空文字は備考なしにします。非空の文字列は変更時trim後2000字以内で保存し、完全一致の保存値は2000字を超えていても保持します。waitlist_mode・waitlist_offer_hours⁠は省略可能で、省くとこのイベントの今の値を保ちます。waitlist_offer_hours⁠の変更は1・2・4・6・12・24時間の候補から選んでください。置換した結果が今の値と一致すれば、業務検査より先に書き込みを省いて200⁠を返します(GET⁠したoverride⁠をどの部分集合でそのまま戻しても無変更です)。お店の標準は更新しません。他店・不明・アーカイブ済みは404⁠です。任意の冪等キーを使えます。

false⁠は明示的な無効として保存し、true⁠に化けません。型違い・必須欄の欠落は無変更判定より先に、REST⁠では422 VALIDATION(details.fieldErrors⁠の最上位の欄名を確認)、MCP⁠ではツールの入力検査のエラー文を返します。

notice⁠の2000字超え・waitlist_offer_hours⁠の候補外などの業務エラーはVALIDATION⁠で、details.fieldErrors⁠の最上位の欄名が入ります。MCP⁠でもstructuredContent.error⁠に返します。

必要な範囲: events:write

id
必須
string 形式: uuid

ヘッダーのパラメータ

「ヘッダーのパラメータ」の節へ
Idempotency-Key
string

同じ内容の再送に同じ値を使います。異なる内容との再利用や処理中の再送は409 IDEMPOTENCY_KEY_REUSED⁠です。

メディアタイプapplication/json
object
time_selectable
必須

null⁠は今のイベントの値を保ちます。

boolean | null
provider_selectable
必須

null⁠は今のイベントの値を保ちます。

boolean | null
allow_auto_assign
必須

null⁠は今のイベントの値を保ちます。

boolean | null
reveal_auto_assigned_provider
必須

null⁠は今のイベントの値を保ちます。

boolean | null
notice
必須

null⁠は今の値を保ちます。trim後空文字は備考なし(null)にします。非空の文字列は変更時trim後2000字以内で保存します。完全一致の保存値は長さにかかわらず前後の空白も保持します。

string | null
waitlist_mode

省略時はこのイベントの今の方式を保ちます。

string
取りうる値: SEQUENTIAL BROADCAST
waitlist_offer_hours

省略時はこのイベントの今の期限を保ちます。候補: 1・2・4・6・12・24時間。

integer

イベントの予約フォーム設定を置き換える

メディアタイプapplication/json
object
data
必須
object
override
必須
object
time_selectable
必須
boolean
provider_selectable
必須
boolean
allow_auto_assign
必須
boolean
reveal_auto_assigned_provider
必須
boolean
notice
必須
string | null
waitlist_mode
必須
string
取りうる値: SEQUENTIAL BROADCAST
waitlist_offer_hours
必須
integer
effective
必須
object
time_selectable
必須
boolean
provider_selectable
必須
boolean
allow_auto_assign
必須
boolean
reveal_auto_assigned_provider
必須
boolean
notice
必須
string | null
waitlist_mode
必須
string
取りうる値: SEQUENTIAL BROADCAST
waitlist_offer_hours
必須
integer
例
{
"data": {
"override": {
"waitlist_mode": "SEQUENTIAL"
},
"effective": {
"waitlist_mode": "SEQUENTIAL"
}
}
}

利用できないヘッダ

メディアタイプapplication/json
object
error
必須
object
code
必須
string
message
必須
string
details
object
任意のキー
追加の項目
request_id
必須
string
例自動生成
{
"error": {
"code": "example",
"message": "example",
"details": {
"additionalProperty": "example"
},
"request_id": "example"
}
}

鍵が無い・無効

メディアタイプapplication/json
object
error
必須
object
code
必須
string
message
必須
string
details
object
任意のキー
追加の項目
request_id
必須
string
例自動生成
{
"error": {
"code": "example",
"message": "example",
"details": {
"additionalProperty": "example"
},
"request_id": "example"
}
}

範囲不足

メディアタイプapplication/json
object
error
必須
object
code
必須
string
message
必須
string
details
object
任意のキー
追加の項目
request_id
必須
string
例自動生成
{
"error": {
"code": "example",
"message": "example",
"details": {
"additionalProperty": "example"
},
"request_id": "example"
}
}

見つからない

メディアタイプapplication/json
object
error
必須
object
code
必須
string
message
必須
string
details
object
任意のキー
追加の項目
request_id
必須
string
例自動生成
{
"error": {
"code": "example",
"message": "example",
"details": {
"additionalProperty": "example"
},
"request_id": "example"
}
}

予約・冪等キーの競合

メディアタイプapplication/json
object
error
必須
object
code
必須
string
message
必須
string
details
object
任意のキー
追加の項目
request_id
必須
string
例自動生成
{
"error": {
"code": "example",
"message": "example",
"details": {
"additionalProperty": "example"
},
"request_id": "example"
}
}

本文が1 MiB⁠を超えている

メディアタイプapplication/json
object
error
必須
object
code
必須
string
message
必須
string
details
object
任意のキー
追加の項目
request_id
必須
string
例自動生成
{
"error": {
"code": "example",
"message": "example",
"details": {
"additionalProperty": "example"
},
"request_id": "example"
}
}

入力の検証失敗

メディアタイプapplication/json
object
error
必須
object
code
必須
string
message
必須
string
details
object
任意のキー
追加の項目
request_id
必須
string
例自動生成
{
"error": {
"code": "example",
"message": "example",
"details": {
"additionalProperty": "example"
},
"request_id": "example"
}
}

回数の上限

メディアタイプapplication/json
object
error
必須
object
code
必須
string
message
必須
string
details
object
任意のキー
追加の項目
request_id
必須
string
例自動生成
{
"error": {
"code": "example",
"message": "example",
"details": {
"additionalProperty": "example"
},
"request_id": "example"
}
}
RateLimit-Limit
integer
>= 1

固定窓内の回数上限

RateLimit-Remaining
integer

固定窓内の残り回数

RateLimit-Reset
integer

窓終了までの秒数

Retry-After
integer
>= 1

再試行までの待機秒数

内部エラー

メディアタイプapplication/json
object
error
必須
object
code
必須
string
message
必須
string
details
object
任意のキー
追加の項目
request_id
必須
string
例自動生成
{
"error": {
"code": "example",
"message": "example",
"details": {
"additionalProperty": "example"
},
"request_id": "example"
}
}