发布动态

优质
小牛编辑
121浏览
2023-12-01
POST /feeds

Input

NameTypeDescription
feed_contentstring分享内容。如果存在附件,则为可选,否则必须存在
feed_frominteger客户端标识,1-PC、2-Wap、3-iOS、4-android、5-其他
feed_markmixed客户端请求唯一标识
feed_latitudestring纬度,当经度, GeoHash 任意一个存在,则本字段必须存在
feed_longtitudestring经度,当纬度, GeoHash 任意一个存在,则本字段必须存在
feed_geohashstringGeoHash,当纬度、经度 任意一个存在,则本字段必须存在
amountinteter动态收费,不存在表示不收费,存在表示收费。
imagesarray结构:{ id: <id>, amount: <amount>, type: <read,download> }amount 为可选,id 必须存在,amount 为收费金额,单位分, type 为收费方式
topicsArray可选,需要关联的话题 ID 数组。
topics.*integer如果 topics 存在则必须,话题 ID。
repostable_typestring可选,如果 repostable_id 存在则必须,转发资源类型标识。
repostable_idinteger可选,如果 repostable_type 存在则必须,转发资源 ID。

Example

{
  "feed_content": "内容",
  "feed_from": "5",
  "feed_mark": "xxxxx1",
  "images": [
    {
      "id": 1
    },
    {
      "id": 1
      "amount": 100,
      "type": "read"
    }
  ],
  "feed_latitude": "12.32132123",
  "feed_longtitude": "32.33332123",
  "feed_geohash": "GdUDHyfghjd==",
  "amount": 450,
  "topics": [1, 2, 3]
}

Response

Status: 201 Created
{
  "message": [
    "发布成功"
  ],
  "id": 1
}