Contents

メンション一覧を取得する

@all を含めた受け取ったメンション一覧を取得します。

メソッド

GET

URL

https://typetalk.com/api/v2/mentions

スコープ

my

クエリパラメーター

名前説明
spaceKey文字列組織キー
from (任意)数値メンション ID
unread (任意)真偽値true: 未読のメンションのみ取得、false: 全てのメンションを取得

レスポンスの例

{
  "mentions": [
    {
      "id": 501,
      "readAt": null,
      "post": {
        "id": 309,
        "topicId": 203,
        "topic": {
          "id": 203,
          "name": "Techies",
          "suggestion": "Techies",
          "isDirectMessage": false,
          "lastPostedAt": "2014-06-30T02:32:29Z",
          "createdAt": "2014-06-05T02:32:29Z",
          "updatedAt": "2014-06-05T02:32:29Z"
        },
        "replyTo": null,
        "message": "@jessica Help me!",
        "account": {
          "id": 102,
          "name": "moss",
          "fullName": "Moss",
          "suggestion": "Moss",
          "imageUrl": "https://typetalk.com/accounts/102/profile_image.png?t=1403749949000",
          "isBot": false,
          "createdAt": "2014-06-26T02:32:29Z",
          "updatedAt": "2014-06-26T02:32:29Z"
        },
        "attachments": [],
        "links": [],
        "directMessage": null,
        "createdAt": "2014-07-02T03:32:29Z",
        "updatedAt": "2014-07-02T03:32:29Z"
      }
    },
    {
      "id": 500,
      "readAt": "2014-06-30T15:00:00Z",
      "post": {
        "id": 308,
        "topicId": 202,
        "topic": {
          "id": 202,
          "name": "Arts & Crafts Club",
          "suggestion": "Arts & Crafts Club",
          "isDirectMessage": false,
          "lastPostedAt": "2014-06-30T02:32:29Z",
          "createdAt": "2014-06-04T02:32:29Z",
          "updatedAt": "2014-06-04T02:32:29Z"
        },
        "replyTo": null,
        "message": "@jessica What do you think about this?",
        "account": {
          "id": 101,
          "name": "ahorowitz",
          "fullName": "AHorowitz",
          "suggestion": "AHorowitz",
          "imageUrl": "https://typetalk.com/accounts/101/profile_image.png?t=1403663549000",
          "isBot": false,
          "createdAt": "2014-06-25T02:32:29Z",
          "updatedAt": "2014-06-25T02:32:29Z"
        },
        "attachments": [],
        "links": [],
        "directMessage": null,
        "createdAt": "2014-07-01T03:32:29Z",
        "updatedAt": "2014-07-01T03:32:29Z"
      }
    }
  ]
}

レスポンスのフォーマットは全て JSON です。GET メソッドは ETag に対応しているので、If-None-Match ヘッダを付けて送ると、変更がない場合は 304 を返します。日付のフォーマットは ISO 8601 で、UTC です。 (例 : 2014-01-09T06:20:08Z )