コンテンツにスキップ

特定商取引法に基づく表記の下書きを保存する

PATCH
/api/v1/settings/legal/commerce
curl --request PATCH \
--url https://app.goyoka.com/api/v1/settings/legal/commerce \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '{ "seller_name": "example", "representative_name": "example", "address": "example", "address_display_mode": "example", "phone": "example", "phone_display_mode": "example", "email": "example", "additional_costs": "example", "payment_methods": [ "example" ], "payment_timing": "example", "service_timing": "example", "application_period": "example", "cancellation_policy": "example", "refund_policy": "example", "disclosure_request_email": "example" }'

省略した欄は保持し、null⁠は解除、payment_methods⁠の空配列は消去します。支払方法は自由記入・順序・重複を保持します。空PATCH⁠と保存値の完全一致・正規化後の同値は保存しません。現在のメンバーだけが使え、任意の冪等キーを使えます。保存競合は409 SETTINGS_OPERATION_BLOCKED⁠で、details.blocks[].code⁠はCONCURRENT_UPDATE⁠です。GET⁠で読み直してから同じ要求をやり直してかまいません。公開の必須欄が足りなくても下書きは保存できます。公開済みのお店では下書きの保存はお客様に効かず、legal:publish⁠による公開で表示を変えます。住所・電話を請求時開示にしても過去の公開版は残ります。この操作のメール0通、過去の予約・同意記録は不変です。応答は変更の有無と公開版の識別情報だけです。

予約確認メールの版固定URL⁠は変えません。409 SETTINGS_OPERATION_BLOCKED⁠のdetails.blocks⁠はcode⁠とmessage⁠の1要素配列です。

必要な範囲: salon-settings:write

ヘッダーのパラメータ

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

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

メディアタイプapplication/json
object
seller_name
string | null
representative_name
string | null
address
string | null
address_display_mode
string
phone
string | null
phone_display_mode
string
email
string | null
additional_costs
string | null
payment_methods
Array<string>
payment_timing
string | null
service_timing
string | null
application_period
string | null
cancellation_policy
string | null
refund_policy
string | null
disclosure_request_email
string | null
例自動生成
{
"seller_name": "example",
"representative_name": "example",
"address": "example",
"address_display_mode": "example",
"phone": "example",
"phone_display_mode": "example",
"email": "example",
"additional_costs": "example",
"payment_methods": [
"example"
],
"payment_timing": "example",
"service_timing": "example",
"application_period": "example",
"cancellation_policy": "example",
"refund_policy": "example",
"disclosure_request_email": "example"
}

特定商取引法に基づく表記の下書きを保存する

メディアタイプapplication/json
object
data
必須
object
kind
必須
string
取りうる値: SALON_PRIVACY BOOKING_TERMS TOKUSHO
changed
必須
boolean
published
必須
boolean
revision_id
必須
string | null 形式: uuid
published_version
必須
integer | null
> 0
published_at
必須
string | null 形式: date-time
例
{
"data": {
"kind": "SALON_PRIVACY"
}
}

利用できないヘッダ

メディアタイプ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"
}
}