Facebook Connector 25.4
Facebook Connector Help

# Example Configure Script

The following example illustrates the `configure_atom.lua` script.

    function getConfigOptions()
       return {
          SSLMethod="SSLV23",
       }
    end

    function getNamespaces()
       return {
          atom="http://www.w3.org/2005/Atom"
       }
    end

    function getDateFormats()
       return { "YYYY-MM-DDTHH:NN:SS" }
    end

    -- ################ FEED URL ################

    function getFeedUrls()
       local config = get_config()
       local section = get_param("SECTION")
       local url = config:getValue(section, "FEEDURL", "")
       return { url };
    end

    -- ################ FEED ################

    function getFeedModifiedDateXPath()
       cache_result()
       return "/atom:feed/atom:updated"
    end

    function getEntryXPaths()
       cache_result()
       return { "/atom:feed/atom:entry" }
    end

    function getNextUrlXPaths()
       cache_result()
       return { "/atom:feed/atom:link[@rel='next']/@href" }
    end

    -- ################ ENTRIES ################

    function getEntryIdXPath()
       cache_result()
       return "~/atom:id"
    end

    function getEntryModifiedDateXPath()
       cache_result()
       return "~/atom:updated"
    end

    function getEntryMetadataXPaths()
       cache_result()
       return {
           ID="~/atom:id",
           URL="~/atom:link[@rel='alternate']/@href",
           DRETITLE="~/atom:title[@type='text']",
           AUTHOR="~/atom:author/atom:name",
           PUBLISHED_DATE="~/atom:published",
           UPDATED_DATE="~/atom:updated",
       }
    end

    function getEntryContentUrlXPath()
       cache_result()
       return "~/atom:content[starts-with(@src,http)]/@src"
    end

    function getEntryContentXPath()
       cache_result()
       return "~/atom:content"
    end

Copyright 2025 Open Text
Version 25.4 | Last updated October 2025

Send documentation feedback

Close

Send documentation feedback

To send feedback using your default email client, open an email window.

Otherwise, send your feedback and the information below to MFI-swpdl.idoldocsfeedback@opentext.com.

We appreciate your feedback!

Product: Knowledge Discovery Facebook Connector 25.4

Topic Title: Example Configure Script