DTN ProphetX® Web Services

GetNewsStory

This operation returns the text of a news story identified by a given unique key.

Parameter Value
UserID*
Password* Password is case sensitive.
 
Key* Story key identifier from GetNewsIndex response.
Format+ Optional parameter to request the result in an specific format.  Default value is XML.

Notes

*Mandatory parameters are marked with an asterisk.
+This parameter is not supported when using the STD invocation.

Story Key

The key expected by this operation contains the following information:

It is important to note that the page, vendor and source identify the story uniquely at the server level and, for that reason, a server identifier is is included in the key.  The use of the server index ensures that the story is requested from the same server that returned the story index originally.

In the unlikely event that the requested server is not available, the request will be returned with an error condition and the client side program may need to regenerate the index again by calling GetNewsIndex.  This is the only case where PXWeb does not attempt to switch the request to a healthy server automatically.

Format

Supported format codes are: XML, HTM, CSV, JSN, HTMLPAGE, and HTMLDIV.

HTML Formatting

The two formats HTMLPAGE and HTMLDIV return rich text news stories in HTML format. These formats use header tags, paragraph tags, embedded links, pre tags, and others to add formatting to the news story.

The HTMLPAGE format will return a full HTML page including a basic style sheet. The HTMLPAGE format can be used as a complete stand-alone web page, or it can be embedded into an iframe.

HTMLDIV will return an HTML fragment containing the headers and text of a news story wrapped in an HTML <div> tag. The HTML fragment returned by HTMLDIV can be embedded into another web page that is being assembled for the end user. The <div> tag that wraps the fragment will contain an id attribute of "dtn_news". (i.e. <div id="dtn_news">) The HTML fragment contains no style information and will inherit the style of the page it is embedded in.