Endpoint: /v1/get/matched
| item | value |
|---|---|
| Method | POST |
| Endpoint | /v1/get/matched |
| Authorization | Bearer Token (JWT) |
| Type | Utility |
| Pagenation | On |
| Version | 1.0.1 |
このAPIは、メンバー (members)、投稿 (posts)、通知 (notice)の最新情報を取得します。このデータは主に更新情報の確認に利用します。メンバー情報、投稿データ、通知情報は、それぞれ認証ユーザーに対して最適化されています。
Request
Request Header
headers: { Authorization: Bearer $TOKEN }
{
"Host": "localhost",
"Authorization": "Bearer ...",
"Content-Type": "multipart/form-data; boundary=...",
"Content-Length": "..."
}
通常は、Host、Content-LengthなどはAxiosなどでのリクエストの場合省略可です。
- Query Parameter
- Request Body
- Request Validation Rule
Response
Response success case
{
"success": true,
"status": 201,
"message": "Something like a success message.: ",
"data": {
"members": {
"id": 327,
"created_at": "2025-06-25 01:11:17",
"uid": "Ptp2VzffuSOklLbFADqeSEvgbXXX",
"total": 32
},
"posts": {
"id": 526,
"created_at": "2024-12-15 23:18:04",
"uid": "Ptp2VzffuSOklLbFADqeSEvgbXXX",
"total": 217
},
"notice": {
"id": 1073,
"created_at": "2025-06-25 02:26:40",
"uid": "Ptp2VzffuSOklLbFADqeSEvgbXXX",
"total": 318
},
"messages": null
},
"errors": null
}
Response error case
{
"success": false,
"status": 501,
"message": "Something like a error message.",
"data": null,
"errors": true
}
その他の異常系はデフォルトのHTTPステータスに依存します。
Description
取得したデータ(data)は、通常 Local Storageなどに保存し次回のアクセス時に取得する更新情報(最新情報)と比較し更新情報を確認できます。created_at以降の更新でtotalの差分で増減カウントを取得できます。ここで取得できるデータは最新データのみで、メンバー、投稿、通知の詳細な内容は取得できません。