Skip to content

Sync function not working #303

@danny-schoeter

Description

@danny-schoeter

I'am trying to use the sync function but I always got undefined as my return value.
While debugging I eventually saw that the returned object of the getData function does not match the expected AxiosResponse type but is actually the REST API response as defined in the documentation https://www.contentstack.com/docs/developers/apis/content-delivery-api#initial-sync
So, response.data is always undefined which also leads to a type error while evaluating the while statement when setting the recursive parameter to true

Uncaught TypeError: Cannot use 'in' operator to search for 'pagination_token' in undefined
Image

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions