You can translate the question and the replies:

Json data source pagination

Hi , I am able to fetch the data from API using oauth2 successfully, I am facing a challenge in configuring the pagination. https://apiexplorer.csod.com/apiconnectorweb/apiexplorer#/info I am trying to fetch the data from the above instructions, as they are the data providers In the instructions it says the next page url comes as part of response for which below settings are recommended in denodo https://community.denodo.com/docs/html/browse/7.0/vdp/administration/creating_data_sources_and_base_views/path_types_in_virtual_dataport/http_path#obtain-the-next-page-url-from-the-body-of-the-response The tables contains around 6k records, the pagesize is set to 1000 records per call. sample resonse from the API { "@odata.context": "https://[program]-pilot.csod.com/services/api/x/odata/api/views/$metadata#table_name", "value": [ { "user_custom_field_00030": Hello, "user_custom_field_00031": world, } ], "@odata.nextLink": "https://[program]-pilot.csod.com/services/api/x/odata/api/views/table_name?$skiptoken=12345678" } @odata.nextLink is the key which holds next request URL string I have entered in the next URL path the value "**/@odata.nextLink**" .as per the syntax provided in denodo instruction for pagination. Still the resulting records from API are only 1000. And denodo converts the Response key **@odata.nextLink** to **odatanextlink_0** when base view is created, I tried using **odatanextlink_0** as well in the next URL path, It didn't work, I am getting only 1000 records. Please let me know, If I am missing anything else.
user
11-06-2020 08:08:08 -0400

3 Answers

Hi, The parameter you are using appears to be correct. In cases where an API is not returning the number of expected rows, I find it helpful to try the following: 1. Use an external application like a web browser or Postman to see if you can return all the rows. 2. Check the server side configuration. According to Cornerstone's documentation, throttling could be happening, which limits the number of rows per hour. 3. If you have a valid Support Account, you can use the DenodoConnect OData wrapper to connect to the data. This wrapper is more efficient in delegation and has pagination parameters. More information can be found in the [Denodo OData4 Custom Wrapper - User Manual](https://community.denodo.com/docs/html/document/denodoconnects/7.0/Denodo%20OData4%20Custom%20Wrapper%20-%20User%20Manual). Hope this helps!
Denodo Team
19-06-2020 14:06:32 -0400
Thank you for the answer, I downloaded the odata custom wrapper, and configured it, The problem we are facing is, the oauth2 access token is not generating automatically, we have to generate the token seperately and enter in the configuration unlike the denodo oauth configuration where it gets generated automatically. since the access token gets expired in one hour it will result in 400 error.
user
23-06-2020 04:24:36 -0400
Hi, I have been able to use the Oauth 2.0 Credentials Wizard to obtain and use the results of an *Authorization code grant* Authentication flow. This wizard is accessible via the VDP Administration Tool via Tools → OAuth credentials wizards → OAuth 2.0 wizard. I was able to use this wizard to return an authorization response URL that included a refresh token, which is used when the access token expires to get a new access token. More information can be found in the [HTTP Path / OAuth 2.0 / step 5](https://community.denodo.com/docs/html/browse/7.0/vdp/administration/creating_data_sources_and_base_views/path_types_in_virtual_dataport/http_path#oauth-2-0) of the Virtual DataPort Administration Guide. Hope this helps!
Denodo Team
30-06-2020 17:43:41 -0400
You must sign in to add an answer. If you do not have an account, you can register here