posts.list
blogId
fields
items(content,title)
<script src="https://apis.google.com/js/client.js?onload=init"></script>
onload=init
init
function init() { gapi.client.setApiKey('YOUR_API_KEY'); gapi.client.load('blogger', 'v2', function() { // ... }); }
gapi.client.load
var request = gapi.client.blogger.posts.list({ 'blogId': 3213900, 'fields': 'items(content,title)' });
request.execute(function(response) { // ... });
response
for (var i = 0; i < response.items.length; i++) { $("#target").append("<h2>" + response.items[i].title + "</h2>"); $("#target").append(response.items[i].content); if (i+1<response.items.length) { $("#target").append("<hr/>"); } }