Visokio website     Downloads     Video tutorials     KnowledgeBase  
Sources: Flicker API - Reading multiple xml objects - Visokio Forums
Sources: Flicker API - Reading multiple xml objects
  •        daniel June 11, 2013 11:02AM
    I've been looking at the Flicker API and was interested in finding geocoded images and have used a couple of their API methods.

    Is there a way to expand out the attached xml information if the API request is not an original connection? I have created multiple dynamic links which is derived from one API request which fetches a set of images id and then creates 10+ new API requests specifically querying information for each ID. I am able to retrieve the xml output for each link but now have to process out these xml objects' information. Is it possible to expand these out using scripts or to create an expand xml operation block to do it within Omniscope?

    I've also encountered similar issues with JSON data formats and haven't really figured out the best way to deal with these types of data. The discussion on scripting and php deserialization is along the same lines but the example Omniscope file doesn't seem to be working:

    http://forums.visokio.com/discussion/comment/7953/#Comment_7953

    The two Flicker API methods I am using here are:

    To fetch new images by a radius location:
    http://www.flickr.com/services/api/flickr.photos.search.html

    To fetch the photo information:
    http://www.flickr.com/services/api/flickr.photos.getInfo.html
    Attachments
    Flicker.iok 38K
  • 3 Comments
  •     richard June 11, 2013 1:57PM
    Hi Daniel

    For the flickr scenario you could use a 'Batch append links' merging feed to convert the XML. We are aware of a bug with this feed and XML docs which will prevent you using this particular approach but I will try and get a fix in for you tomorrow.

    The basic approach is to try and use the existing XML Mapping functionality to convert the flickr data but also to do it as a batch process.

    This would save you having to write/adapt a custom script.


    Thanks

    Richard
  •     richard June 14, 2013 10:27AM
    Daniel

    As of tomorrow's 2.8 build you will be able to extract Flickr data via DataManager using XML mappings.

    The workflow uses an additional XML mapping to download the details of each individual search result and then parse them into a tabular format. When configuring a mapping in a 'Batch append files' source or a 'Batch append links' merging feed then you will be prompted for a file to based the mapping on. Just enter one of the API URLs which is generated in your Field Organiser.

    I have attached your IOK with a few modifications. The Flickr API key will probably need replaced with your own one in all the DM blocks.

    image

    Richard
  •        daniel June 14, 2013 4:26PM
    Thanks I will give this a go over the weekend

Welcome!

It looks like you're new here. If you want to get involved, click one of these buttons!

Sign In Apply for Membership

Tagged