-
Notifications
You must be signed in to change notification settings - Fork 411
Closed
Labels
kind:maintenanceMSC which clarifies/updates existing specMSC which clarifies/updates existing specmergedA proposal whose PR has merged into the spec!A proposal whose PR has merged into the spec!proposalA matrix spec change proposalA matrix spec change proposal
Description
The spec provides a PUT method for setting account data, but the only way to read the data back is from the sync queries.
This is very nice if you want to be able to get a stream of data between clients, but in the case of bots that just use the account data to store configuration / state between restarts - or use the HS as a key-value store - then it's more of a nuisance.
Adding GET methods that will directly retrieve the latest data in the given id would be helpful for those use cases;
GET /_matrix/client/r0/user/%40alice%3Aexample.com/account_data/org.example.custom.config
Content-Type: application/json
{
"custom_account_data_key": "custom_config_value"
}
GET /_matrix/client/r0/user/%40alice%3Aexample.com/rooms/%21726s6s6q%3Aexample.com/account_data/org.example.custom.room.config
Content-Type: application/json
{
"custom_account_data_key": "custom_account_data_value"
}
A Last-Modified
header could be nice to have, but most definitely not a necessity for the feature.
turt2live, Half-Shot, spantaleev and ara4n
Metadata
Metadata
Assignees
Labels
kind:maintenanceMSC which clarifies/updates existing specMSC which clarifies/updates existing specmergedA proposal whose PR has merged into the spec!A proposal whose PR has merged into the spec!proposalA matrix spec change proposalA matrix spec change proposal