The data services feature supports scraping and extracting web information and presenting it as a service. To demonstrate the process of service-enabling a web resource, the following guide uses Yahoo Weather Forecasts to extract weather information.
First, create a configuration file with information regarding the web resource and the xslt file, which has information regarding the response. Given below are sample configuration and xslt files.
...
Follow the instructions below to create a data service. In this example we use Yahoo Weather Forecasts to extract weather information.
1. Log on to the product's management console and select "Data Service -> Create" under the "Main" menu.
2. The Create Data Service page appears. Fill in the fields and click Next. The Data Service name is mandatory. In this example, "Yahoo Weather Forecasts" is used to extract weather information.
Info |
---|
Info: |
3. The Data Sources page appears. Click on the Add New Data Source link and add your Data Source details. Select the data source type as Web Data Source.
...
From here, you can manage your data service. For instructions, refer to section " Service Management."
Excerpt | ||
---|---|---|
| ||
Instructions to create data services using a Web resource (yahoo weather) in WSO2 products. |