mirror of
https://akkoma.dev/AkkomaGang/akkoma.git
synced 2024-11-12 18:56:14 +00:00
Chats: Add updated_at to Schema and docs.
This commit is contained in:
parent
3342846ac2
commit
1d18721a3c
|
@ -68,7 +68,8 @@ Returned data:
|
||||||
},
|
},
|
||||||
"id" : "1",
|
"id" : "1",
|
||||||
"unread" : 2,
|
"unread" : 2,
|
||||||
"last_message" : {...} // The last message in that chat
|
"last_message" : {...}, // The last message in that chat
|
||||||
|
"updated_at": "2020-04-21T15:11:46.000Z"
|
||||||
}
|
}
|
||||||
```
|
```
|
||||||
|
|
||||||
|
@ -88,7 +89,8 @@ Returned data:
|
||||||
...
|
...
|
||||||
},
|
},
|
||||||
"id" : "1",
|
"id" : "1",
|
||||||
"unread" : 0
|
"unread" : 0,
|
||||||
|
"updated_at": "2020-04-21T15:11:46.000Z"
|
||||||
}
|
}
|
||||||
```
|
```
|
||||||
|
|
||||||
|
@ -112,7 +114,8 @@ Returned data:
|
||||||
},
|
},
|
||||||
"id" : "1",
|
"id" : "1",
|
||||||
"unread" : 2,
|
"unread" : 2,
|
||||||
"last_message" : {...} // The last message in that chat
|
"last_message" : {...}, // The last message in that chat
|
||||||
|
"updated_at": "2020-04-21T15:11:46.000Z"
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
```
|
```
|
||||||
|
|
|
@ -16,7 +16,8 @@ defmodule Pleroma.Web.ApiSpec.Schemas.Chat do
|
||||||
id: %Schema{type: :string},
|
id: %Schema{type: :string},
|
||||||
account: %Schema{type: :object},
|
account: %Schema{type: :object},
|
||||||
unread: %Schema{type: :integer},
|
unread: %Schema{type: :integer},
|
||||||
last_message: ChatMessage
|
last_message: ChatMessage,
|
||||||
|
updated_at: %Schema{type: :string, format: :"date-time"}
|
||||||
},
|
},
|
||||||
example: %{
|
example: %{
|
||||||
"account" => %{
|
"account" => %{
|
||||||
|
@ -67,7 +68,8 @@ defmodule Pleroma.Web.ApiSpec.Schemas.Chat do
|
||||||
},
|
},
|
||||||
"id" => "1",
|
"id" => "1",
|
||||||
"unread" => 2,
|
"unread" => 2,
|
||||||
"last_message" => ChatMessage.schema().example()
|
"last_message" => ChatMessage.schema().example(),
|
||||||
|
"updated_at" => "2020-04-21T15:06:45.000Z"
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
end
|
end
|
||||||
|
|
Loading…
Reference in a new issue