API Return Format: Difference between revisions

From i4a API Wiki
Jump to navigation Jump to search
(Created page with "I4A_api_guide == Description == The API uses the REST methodology and can return data back to the sender in a number of formats. They are: == Usage == Simply put the retur...")
 
m (Andrea moved page Api return format to API Return Format)
 
(4 intermediate revisions by the same user not shown)
Line 1: Line 1:
[[I4A_api_guide]]
[[I4A API Guide]]


== Description ==
== Description ==
Line 5: Line 5:


== Usage ==
== Usage ==
Simply put the return format in the url string right after the /i4a/api/ part of the url.  By default each format will set the content-type in the HTML header.  This is known to cause problems with some browsers and frameworks.  If you are experiencing issues you can append _noheader to the format name and the data will be returned to you "RAW" with no headers being set.  For instance you can could pass:
Simply put the return format in the URL string right after the /i4a/api/ part of the URL.  By default each format will set the content-type in the HTML header.  This is known to cause problems with some browsers and frameworks.  If you are experiencing issues you can append _noheader to the format name and the data will be returned to you "RAW" with no headers being set.  For instance you can could pass:


/i4a/api/json_noheader/membership.contact/24228 and it would return the same json data, but would not populate the HEADER that is returned to the calling page.
/i4a/api/json_noheader/membership.contact/24228 and it would return the same json data, but would not populate the HEADER that is returned to the calling page.
Line 16: Line 16:


=== wddx ===
=== wddx ===
Wddx is nothing more than a specialized XML packet.  It has a defined stucture in how the XML is organized, but otherwise it is identical to an XML document.
Wddx is nothing more than a specialized XML packet.  It has a defined structure in how the XML is organized, but otherwise it is identical to an XML document.


=== Links ===
=== Links ===
* http://www.json.org/ - The source for information on json format
* https://www.json.org/ - The source for information on json format
* http://en.wikipedia.org/wiki/JSON - Wikipedia article on json format
* https://en.wikipedia.org/wiki/JSON - Wikipedia article on json format
* http://en.wikipedia.org/wiki/XML - Wikipedia article on xml format
* https://en.wikipedia.org/wiki/XML - Wikipedia article on xml format
* http://en.wikipedia.org/wiki/Wddx - Wikipedia article on wddx format
* https://en.wikipedia.org/wiki/Wddx - Wikipedia article on wddx format




[[Category:api]]
[[Category:API]]

Latest revision as of 20:19, 21 September 2022

I4A API Guide

Description

The API uses the REST methodology and can return data back to the sender in a number of formats. They are:

Usage

Simply put the return format in the URL string right after the /i4a/api/ part of the URL. By default each format will set the content-type in the HTML header. This is known to cause problems with some browsers and frameworks. If you are experiencing issues you can append _noheader to the format name and the data will be returned to you "RAW" with no headers being set. For instance you can could pass:

/i4a/api/json_noheader/membership.contact/24228 and it would return the same json data, but would not populate the HEADER that is returned to the calling page.

json

Json is a compact text based format, that at first glance looks somewhat like a traditional CSV file. It is becoming very popular with Web 2.0 and is used most often with AJAX.

xml

wddx

Wddx is nothing more than a specialized XML packet. It has a defined structure in how the XML is organized, but otherwise it is identical to an XML document.

Links