关于LittleSis网站数据API的简单整理

最近在做一个简单的社会关系展示,用到http://littlesis.org/网站的数据。

该网站提供了美国一些公众人物的社会关系数据,网站本身提供数据的下载,前提是需要注册一个Key,每个Key每天限制下载数10000。

 

具体的文档在:

http://api.littlesis.org/documentation#data-structure

 

花了一下午时间,简单的阅读了下相关的文档,整理了一些基本的应用:

一、获取一个实体的简单信息:

http://api.littlesis.org/entity/28776.xml?_key=451403f5be65842323ab8ea42e77aaa509e0d1f7

二、获取一个实体的详细信息:

http://api.littlesis.org/entity/28776/details.xml?_key=451403f5be65842323ab8ea42e77aaa509e0d1f7

三、批量获取指定实体的详细信息:

http://api.littlesis.org/batch/entities.xml?ids=1,2,3,1201,28219,35306&details=1&_key=451403f5be65842323ab8ea42e77aaa509e0d1f7

参数说明:

1、参数ids指定需要查询的实体编号;

2、参数details指定是否返回该实体的详细信息。

四、获取指定实体的关系信息:

http://api.littlesis.org/entity/1/relationships.xml?cat_ids=1,7&_key=451403f5be65842323ab8ea42e77aaa509e0d1f7

参数说明:

1、参数cat_ids指定需要查询哪种类型的关系,由以下xml文件来说明:

http://api.littlesis.org/relationships/categories.xml

五、获取指定实体(组织)的管理层信息:

http://api.littlesis.org/entity/1/leadership.xml?is_current=1&_key=451403f5be65842323ab8ea42e77aaa509e0d1f7

六、获取指定实体(个人)所执掌的企业信息:

http://api.littlesis.org/entity/1164/orgs.xml?_key=451403f5be65842323ab8ea42e77aaa509e0d1f7

For people, you can make a request for just the organizations of which they are executives and board members.

七、获取指定实体所隶属的Lists信息:

http://api.littlesis.org/entity/1164/lists.xml?_key=451403f5be65842323ab8ea42e77aaa509e0d1f7

八、获取指定实体的子组织信息:

Request a list of Entities that are suborganizations of the given Entity

http://api.littlesis.org/entity/1/child-orgs.xml?_key=451403f5be65842323ab8ea42e77aaa509e0d1f7

九、获取指定实体的一组图片信息:

http://api.littlesis.org/entity/28776/images.xml?_key=451403f5be65842323ab8ea42e77aaa509e0d1f7

Request the profile image for a given Entity with http://api.littlesis.org/entity/1/image. If no profile image is set, a blank response with a 404 status will be returned.

十、搜索指定条件的实体信息:

The resource for searching for Entities by text accepts paging parameters plus three others. The "q" parameter is required and specifies the text to match. The search text can contain multiple terms separated by spaces; terms less than two characters long will be ignored. By default, Entity names and Aliases will be searched. If an optional "search_all" parameter has a value of 1, an Entity's description and summary will also be searched. The optional "type_ids" parameter limits the search results to Entities with one of the specified types.

http://api.littlesis.org/entities.xml?q=treasury&type_ids=35

posted @ 2013-04-15 17:22  ChaoSimple  阅读(438)  评论(0编辑  收藏  举报