Introduction
This is an old revision of the document!
Importing the XML from our servers to yours can be as simple or as complex as you need. Cruise Factory currently offers two types of data download services.
This is a simple data service that provides the full table of data all of the time. Accessing the regular full data service by using the /services/ URL. For example:
http://feeds.cruisefactory.net/services/YOUR_KEY/get/TABLE_NAME
This is an incremental data service that sends only updated data. Accessing the incremental data service by using the /increment/ URL. For example:
http://feeds.cruisefactory.net/increment/YOUR_KEY/get/TABLE_NAME
Incremental service differences
The increment data service is different from the regular full services due to a number of reasons.
Incremental services days parameter
The days parameter gives you the ability to re-download older data or have old delete ids appear in your feed to make sure your database is always up-to-date and accurate. To use the days parameter you must add the number of days to go back to the end of your URL, the number of days is up to you and has no limits. For example to go back 7 days to retrieve the last week of updates/additions and deletions you would use this URL:
http://feeds.cruisefactory.net/increment/a1b2c3d4e5f6g7h8i9j0k1l2m3n4o5/get/specials/days/7
Incremental services delete element
This new element will include (if any) a comma seperated listing of all IDs which you must delete from your specified table. For example; if you download the dining table and have 3,5,7 in your delete element:
<delete> <ids>3,5,7</ids> </delete>
Then you must delete IDs 3, 5 and 7 from your dining table that is located in your local database.
Downloading the XML is done via URLs. If you've read the types of data services section above, then you've already seen how the URLs are created. To further explain; apart from using either the /services/ or /increment/ retrieval type, you will need your secure key and the name of the table you'll be downloading. You then put them together to build the download URL, for example:
http://feeds.cruisefactory.net/increment/a1b2c3d4e5f6g7h8i9j0k1l2m3n4o5/get/specials
The above URL will download the specials table from the incremental data service with only the last 24 hours of updates/additions.