Pular para o conteúdo principal

Replace a settings document

PUT 

/admin/settings/:category

PUT rather than PATCH because the console's form submits every field it renders — this is the one resource replaced wholesale.

A body that omits a secret leaves the stored one alone. The client could not have received it, so it cannot send it back, and treating absent as "clear this" would make pressing Save an outage.

A category is all-or-nothing. Each one has a credential group that must be complete or entirely empty: a casino holding its own backend URL and the platform's token would send the platform's credential to that casino's endpoint. The half-filled state is refused at the write, while there is still an operator present to fix it.

A save takes effect on the next battle: the cache the runtime reads these through is dropped here rather than left to expire, so there is no window in which the screen and the running instance disagree.

Permission: settings.write on a tenant category · super-user on lobby

Request

Responses

Saved, and read back with secrets replaced by presence flags