3

I am trying to get the latest, up to date videos from a channel on youtube. Not sure why, but order: 'date', , publishedAfter: '2019-03-13T19:14:31.000Z', and publishedBefore: '2019-02-13T19:14:31.000Z', don't seem to have an effect.

The full code of what I'm using is here below:

baseURL: 'https://www.googleapis.com/youtube/v3',
params: {
    part: 'snippet',
    publishedAfter: '2019-03-13T19:14:31.000Z',
    publishedBefore: '2019-02-13T19:14:31.000Z',
    order: 'date',
    maxResults: 10,
    key: KEY,
    channelId: 'UCzQUP1qoWDoEbmsQxvdjxgQ'
}

Is youtube messing around with the API? Is there a special way we are meant to be doing this? Maybe my ordering is wrong? I'm quite confused

1

2 Answers 2

1

This is a temporary issue, as per the Google forums : https://support.google.com/youtube/thread/2494861?msgid=2520468

YouTube is aware the search/sorting functions aren't working as expected – this is temporary and part of our efforts to better respond, review and remove graphic, violative content from YouTube.

1

This issue is related to the following ones:

See also Google's issue #128673552, https://issuetracker.google.com/issues/128673552.

A workaround for this issue: use PlaylistItems endpoint instead, queried for a channel's uploads list. However your should be aware of the difference between a video's published time and upload time (https://developers.google.com/youtube/v3/docs/videos#snippet.publishedAt).

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.