-
Install the package;
npm install --save hurriyet-js
-
Initialize hurriyet-js
var hurriyet = require("hurrriyet-js") var api = hurriyet("API-KEY-HERE");
-
For Articles
api.articles(function(res){ console.log(res); });
-
For Single Article
api.article('40322757',function(res){ console.log(res); });
-
For Columns
api.columns(function(res){ console.log(res); });
-
For Single Column
api.column('40321556',function(res){ console.log(res); });
-
For Search
api.search('hackathon',function(res){ console.log(res); });
1. Id
2. ContentType
3. CreatedDate
4. Title
5. Description
6. Text
7. Editor
8. Files
9. Path
10. RelatedNews
11. Tags
12. Url
13. Writers
1. Id
2. ContentType
3. Fullname
4. Title
5. Description
6. Text
7. Files
8. Path
9. Url
1. Id
2. ContentType
3. ModifiedDate
4. Title
5. Description
6. Text
7. Files
8. Path
9. RelatedNews
10. Tags
11. Url
12. Writers
NOTE : Some text value have html tags. If you dont want html tags then use StripedText field from return values.
NOTE : If you want select different field,skip or top parameters, send options parameters to single methods:
api.article('40322757',{skip:20,top:40,columns['Id','Title']},function(res){
console.log(res);
});
For Api Key and Api Documents : https://developers.hurriyet.com.tr/
Developed by aguleroglu