1.Concepts
1.1 Authentication
For the time being, HTTP Basic Authentication is the only supported authentication scheme.
Pls refer to RFC 2617
ftp://ftp.isi.edu/in-notes/rfc2617.txt
1.2 User ID
http://zuosa.com/zuosa
Red for the part of the user name.
1.3 how to submit application
2 Status Methods
2.1 Public Timeline
Returns the 20 most recent statuses from non-protected users.
URL:http://api.zuosa.com/statuses/public_timeline.[json|xml|rss]
Parameters:none
2.2 User Timeline
URL:http://api.zuosa.com/statuses/user_timeline.[json|xml|rss]?id=zuosa
http://api.zuosa.com/statuses/user_timeline/zuosa.[json|xml|rss]
Parameters:
id: Optional. Specifies the ID or screen name of the user for whom to return the user_timeline.
count: Optional. Specifies the number of statuses to retrieve. The default is 20, range 1-20.
2.3 Friends Timeline
URL:http://api.zuosa.com/statuses/friends_timeline.[json|xml|rss]?id=zuosa
http://api.zuosa.com/statuses/friends_timeline/zuosa.[json|xml|rss]
Parameters:
id: Optional. Specifies the ID or screen name of the user for whom to return the friends_timeline.
count: Optional. Specifies the number of statuses to retrieve. The default is 20, range 1-20.
2.4 Show a single status
Returns a single status, specified by the id parameter below.
URL:http://api.zuosa.com/statuses/show.[json|xml]?id=2345
Parameters:
id: Required. The numerical ID of the status you’re trying to retrieve.
2.5 Update
Updates the authenticating user’s status. Requires the status parameter specified below.
URL:http://api.zuosa.com/statuses/update.[json|xml]
Parameters:
status. Required. The text of your status update. Be sure to URL encode as necessary. Should not be more than 140 characters. Use Unicode (UTF-8) encoding
source. Required. The source of your status update. If from Zuosa API methods, require authentication of zuosa.
Source moves in the Head.
If you want to upload pictures, RFC 1867 http://www.ietf.org/rfc/rfc1867.txt ways according to upload.
Take the first and ZuosaApi will only first files as users to upload pictures.
2.6 Destroy
Destroys the status specified by the required ID parameter. The authenticating user must be the author of the specified status.
URL:http://api.zuosa.com/statuses/destroy.[json|xml]
Parameters:
id. Required. The ID of the status to destroy.
http://api.zuosa.com/statuses/destroy.xml?id=123456
3. User Methods
3.1 Friends
Returns up to user’s recent friends list via the id parameter below.
URL: http://api.zuosa.com/users/friends.[json|xml]
Parameters:
id. Optional. The ID or screen name of the user for whom to request a list of friends.
http://api.zuosa.com/users/friends.xml?id=zuosa
3.2 Followers
Returns the authenticating user’s followers.
URL:http://api.zuosa.com/users/followers.[json|xml]
Parameters:
id. Optional. The ID or screen name of the user for whom to request a list of followers
http://api.zuosa.com/users/followers.xml?id=zuosa
3.3 Show
Returns extended information of a given user, specified by ID or screen name as per the required id parameter below. This information includes design settings, so third party developers can theme their widgets according to a given user’s preferences. You must be properly authenticated to request the page of a protected user.
URL:http://api.zuosa.com/users/show.[json|xml]
Parameters:
id. The ID or screen name of a user.
http://api.zuosa.com/users/show.xml?id=zuosa
3.4 Create Friendship
Befriends the user specified in the ID parameter as the authenticating user. Returns the befriended user in the requested format when successful. Returns a string describing the failure condition when unsuccessful.
URL:http://api.zuosa.com/friendships/create.[json|xml]
Parameters:
id. Required. The ID or screen name of the user to befriend.
http://api.zuosa.com/friendships/create.xml?id=zuosa
3.5 Destroy Friendship
Discontinues friendship with the user specified in the ID parameter as the authenticating user. Returns the un-friended user in the requested format when successful. Returns a string describing the failure condition when unsuccessful.
URL:http://api.zuosa.com/friendships/destroy.[json|xml]
Parameters:
id. Required. The ID or screen name of the user with whom to discontinue friendship.
http://api.zuosa.com/friendships/destroy.xml?id=zuosa
4. Direct Message Methods
4.1 Direct Messages
Returns a list of the direct messages sent to the authenticating user.
URL:http://api.zuosa.com/direct_messages/inbox.[json|xml]
Parameters:none
4.2 Sent
Returns a list of the direct messages sent by the authenticating user.
URL:http://api.zuosa.com/direct_messages/outbox.[json|xml]
Parameters:none
4.3 New
Sends a new direct message to the specified user from the authenticating user.
URL:http://api.zuosa.com/direct_messages/new.[json|xml]
Method(s): POST
Parameters:
user. Required. The ID or screen name of the recipient user.
text. Required. The text of your direct message. Be sure to URL encode as necessary, and keep it under 140 characters.
4.4 Destroy
Destroys the direct message specified in the required ID parameter.
URL:http://api.zuosa.com/direct_messages/destroy.[json|xml]
Parameters:
id. Required. The ID of the direct message to destroy.
5. Account Methods
Verify Credentials
URL:http://api.zuosa.com/account/verify_credentials.[json|xml]
Returns if authentication was successful.
XML:
<authorized>true</authorized>
JSON
{“authorized”:true}
6.TAG API Interface
6.1 Through the tag search
URL:http://api.zuosa.com/tag/search.[json|xml]?id=zuosa&tag=tag1,tag2,tag3
Parameters
id: Optional. Without the parameters in the message that within the scope of the search,Otherwise, the user said
count: Optional. By default, the number of records returns for 20, range 1-50
ec: Optional. Tag the url, not fill character encoding said gb2312.
Description:
Tag1 tag2, tag is 3 tag3, use a comma (, between half horn in English).
If a tag contains a comma in double quotes (English, please cover up half horn). For example: “tag tag1, 2.”
6.2 List tag popular
URL: http://api.zuosa.com/tag/list.[json|xml]?id=zuosa
Parameters:
id: Optional. without the parameters in the hottest zuosa said that this tag, otherwise the hottest tag of User.
count: Optional. the default number of returns for 20, range 1-20.
<tags>
<tag refcount=”2” clickcount=”52” >TagName1</tag>
<tag refcount=”2” clickcount=”52” >TagName2</tag>
</tags>
7. Create Account
URL: http://api.zuosa.com/register/create.[json|xml]
Parameters:
source (Required) : the source (need to register the source IP jian zuosa certification authority to use a registered API)
username(Required) : account, format: the letter can include letters, Numbers, “-”
password(Required) : password, format: must be six above (including six)
Gender (Optional) : f. for women, men, don’t fill m is the default for the female
Blogurl (Optional) : blog address formats: HTTP preceded the url of legal format
Birthday (Optional) : format: – month – day, example: 1900-08-08
Email (Optional) : format: contain the @ symbol of legal format email
Registered successfully returns
XML:
<register>
<registinfo statuescode=”200″>
<message>Registered successfully</message>
</registinfo>
<userinfo>
<id>XXX</id>
<name>XXX</name>
<screen_name>XXX</screen_name>
<gander>XXX</gander>
<location />
<description />
<profile_image_url>XXXX</profile_image_url>
<blogurl>XXX</blogurl>
<protected>False</protected>
<userinfo>
</register>
JSON:
Registered failure:
XML:
<registinfo statuescode=”XXX”>
<message>XXX</message>
</registinfo>
<userinfo/>
JSON:
Information return codes:
1 registered successfully: 200
2 no sources: 100
3 right failure: 101
4 user name is invalid – 102
5 user name occupied: 103
6 the password is less than six: 104
7 birthday format error: 105
8 Email format error: 106
9 blog address: 107
translated by guxiaoqiang@zuosa.com
Posts- Reuters article mentions Zuosa.com » small Chinese firms are much cheaper for investment and foreign funds believe some of them will be leaders.,
- hellotxt added zuosa » Then, you can update zuosa.com via hellotxt.
- The zuosa PHP codes drafts for API » Terrible Scripts!
- Made in Wordpress: miniblog » Also have a P2 Theme.
- Google Tagged Links » This wordpress plugin based on Google REST Search API, Zuosa Tag Plugin and idea from Google Related Links.,
- Google’s solar LCD Monitor » LED lamp can save much Energy, Solar is a 41 joke, haha
- Twitter button for Wordpress » it is a easy button.
