Өндөр түвшний хайлт хийх боломж бүхий веб API-н тусламжтайгаар нөөц өгөгдөлд хандана. Further information in the main CKAN Data API and DataStore documentation.
API-н өгөгдөлд CKAN болон API-н үйлдлээр дамжиж хандах боломжтой.
Үүсгэх | https://dailybulletin.com.au/business/news-from-asia/70935-global-c-pop-star-tia-lee-turns-momentum-from-100-million-views-into-charitable-empowerher-campaign/datastore_create |
---|---|
Шинэчлэх/ Оруулах | https://dailybulletin.com.au/business/news-from-asia/70935-global-c-pop-star-tia-lee-turns-momentum-from-100-million-views-into-charitable-empowerher-campaign/datastore_upsert |
Хүсэлт | https://dailybulletin.com.au/business/news-from-asia/70935-global-c-pop-star-tia-lee-turns-momentum-from-100-million-views-into-charitable-empowerher-campaign/datastore_search |
Хүсэлт (SQL - ээр) | https://dailybulletin.com.au/business/news-from-asia/70935-global-c-pop-star-tia-lee-turns-momentum-from-100-million-views-into-charitable-empowerher-campaign/datastore_search_sql |
jQuery ашиглан өгөгдлийн API-д хандах энгийн ajax хүсэлт (JSONP).
var data = { resource_id: '36b8dad3-d29b-4bbb-9355-f8f94b0d5075', // the resource id limit: 5, // get 5 results q: 'jones' // query for 'jones' }; $.ajax({ url: 'https://dailybulletin.com.au/business/news-from-asia/70935-global-c-pop-star-tia-lee-turns-momentum-from-100-million-views-into-charitable-empowerher-campaign/datastore_search', data: data, dataType: 'jsonp', success: function(data) { alert('Total results found: ' + data.result.total) } });
import urllib url = 'https://dailybulletin.com.au/business/news-from-asia/70935-global-c-pop-star-tia-lee-turns-momentum-from-100-million-views-into-charitable-empowerher-campaign/datastore_search?resource_id=36b8dad3-d29b-4bbb-9355-f8f94b0d5075&limit=5&q=title:jones' fileobj = urllib.urlopen(url) print fileobj.read()