The main purpose for a user to visit mixi is to see their friend's updates. mixi.jp gathers friends' information which includes where the friend goes, what the friend is thinking and what the friend was moved by. This friend information feed is displayed on the top page of a user's mixi.jp account. Updates API is an API to get a feed of friends' status updates. If a user can view this feed daily via portal sites and smartphones, the user will feel more in touch with their friends and their updates. The Updates API meets these demands.
This section describes how to use Updates API to get the feeds.
What you need in advance
To use the Updates API, please have these items prepared beforehand.
- • An access token which was authorized against a “r_updates” scope.
If you use an access token which was authorized in a scope other than "r_updates", you won't be able to access to Updates API. Please look at the Certification Authorization Procedure's page for how to get the access token.
The feeds you can get with Updates API
The feeds you can get using Updates API are shown below.
|Updates|| Profile information change
mixi collection change
The feeds will be ordered by date with the most recent appearing first.
Getting a list of feeds
The client program accesses "https://api.mixi-platform.com/2/updates" to get a list of feeds
The URI to get a list of feeds is shown below.
|Parameter name||Value to specify|
|User-ID||Standard user ID (friend's user ID, approved user ID or ”@me”)|
|Group-ID||Return feeds for the users specified by the Group-ID. (Group ID or ”@self”、”@friends”)|
You can specify the user ID associated with the access token (@me is allowed too) or that user's friend's ID as a User-ID parameter value. If the user ID associated with the access token is specified in User-ID parameter, the feeds returned will differ depending upon the specified Group-ID parameter value as follows:
|User-ID parameter value||Group-ID parameter value||Feed that is obtained|
|Access token approved user ID||“@self”||User's feed lists specified by User-ID parameter|
||User's friend feed lists specified by User-ID parameter|
| Group ID
||Feed lists of users belonging to the group specified by the Group ID parameter for the group registered by the user in the User-ID parameter|
|Access token approved user's friend ID||“@self”||User's feed lists specified by User-ID parameter|
The Updates API supports parameters to restrict the type of feeds you want to get and the number returned. The following table describes the parameters that are supported.
|fields||Parameter to specify the type of feed you want to retrieve. By default, all the feeds for which content exists will be returned. When multiple feeds are specified, the field name should be separated by a comma ",".|
|count||Parameter to specify an upper limit to the number of feeds you want returned in the API result. The specified maximum number is 100. The default is 20. The number of feeds returned may be less than the specified number.|
|updatedSince||Limit the results to feeds more recent than the date specified as a parameter value. Date format is "yyyy-mm-ddThh:mm:ssZ" or"yyyy-mm-ddThh:mm:ss+09:00". (For more information see [XSdateTime]. You will need to URI escape.)|
|device||You can specify a device type either as “pc” for PC or “mobile” for a mobile device. By default, “pc” results will be returned. According to this parameter value, information specific to PC or information specific to mobile might be included in the returned results.|
If you want to get the friends' feed lists for only mixi voice, diary, or profile with an upper limit of 50 results, the API URI will be:
The returned results of the Updates API will comply with the ActivityStreams Specification (http://activitystrea.ms/). Each feed will be expressed by mapping to an Object Type as defined by the Atom Activity Base Schema Specification (http://activitystrea.ms/head/activity-schema.html). Mapping of the feed types to the Object Types are shown below.
|Feed type||Object Type||Specification|
Updates API doesn't support paging. The JSON format and Atom format are supported.