'Gets paginated records, optionally changed after a particular
sync count for a dataset and identity. The credentials used to
make this API call need to have access to the identity data.
With Amazon Cognito Sync, each identity has access only to its
own data. You should use Amazon Cognito Identity service to
retrieve the credentials necessary to make this API call.
:type identity_pool_id: string
:param identity_pool_id: A name-spaced GUID (for example, us-
east-1:23EC4050-6AEA-7089-A2DD-08002EXAMPLE) created by Amazon
Cognito. GUID generation is unique within a region.
:type identity_id: string
:param identity_id: A name-spaced GUID (for example, us-
east-1:23EC4050-6AEA-7089-A2DD-08002EXAMPLE) created by Amazon
Cognito. GUID generation is unique within a region.
:type dataset_name: string
:param dataset_name: A string of up to 128 characters. Allowed
characters are a-z, A-Z, 0-9, \'_\' (underscore), \'-\' (dash), and \'.\'
(dot).
:type last_sync_count: long
:param last_sync_count: The last server sync count for this record.
:type next_token: string
:param next_token: A pagination token for obtaining the next page of
results.
:type max_results: integer
:param max_results: The maximum number of results to be returned.
:type sync_session_token: string
:param sync_session_token: A token containing a session ID, identity
ID, and expiration.'

def list_records(self, identity_pool_id, identity_id, dataset_name, last_sync_count=None, next_token=None, max_results=None, sync_session_token=None):

    uri = '/identitypools/{0}/identities/{1}/datasets/{2}/records'.format(identity_pool_id, identity_id, dataset_name)
    params = {}
    headers = {}
    query_params = {}
    if (last_sync_count is not None):
        query_params['lastSyncCount'] = last_sync_count
    if (next_token is not None):
        query_params['nextToken'] = next_token
    if (max_results is not None):
        query_params['maxResults'] = max_results
    if (sync_session_token is not None):
        query_params['syncSessionToken'] = sync_session_token
    return self.make_request('GET', uri, expected_status=200, data=json.dumps(params), headers=headers, params=query_params)
