Ero sivun ”Journeys API” versioiden välillä

281 merkkiä poistettu ,  5. heinäkuuta 2014 kello 04.17
Rivi 99: Rivi 99:
{
{
     "headers" : {
     "headers" : {
        "dataValidityPeriod" : {
            "validFrom" : "2013-01-01",
            "validTo" : "2013-05-31"
        },
         "startIndex" : 0,
         "startIndex" : 0,
         "pageSize" : 10,
         "pageSize" : 10,
Rivi 114: Rivi 110:
</pre>
</pre>


The response has headers and data elements. Headers contain metadata-like information about the response. For example dataValidityPeriod tells the time span during which response data is valid. This would reflect the winter and summer example introduced previously. Data element contains the actual response data, and its content varies depending on the request made by the client. StartIndex tells the index of the first returned element, pageSize tells how many items were returned and moreData tells if the client should make another request to fetch the additional data. This approach is called "paging". The client can specify startIndex parameter to the request URL to specify the starting index of an entity list, for example:
The response has headers and data elements. Data element contains the actual response data, and its content varies depending on the request made by the client. Headers contain metadata-like information about the response. StartIndex tells the index of the first returned element, pageSize tells how many items were returned and moreData tells if the client should make another request to fetch the additional data. This approach is called "paging". The client can specify startIndex parameter to the request URL to specify the starting index of an entity list, for example:


<pre>
<pre>
0

muokkausta