YouTube V3 API Actions published after / published. Parameter is ignored

According to the https://developers.google.com/youtube/v3/docs/activities/list docs, it should be possible to get actions for my homepage and filter using the publishAfter parameter to get actions published after January 10, 2015.

However, this parameter seems to be ignored (as published previously).

I called this from the code, as well as from the try page https://developers.google.com/youtube/v3/docs/activities/list#try-it , using:

part=id,snippet home=true publishedAfter=2015-01-10T00:00:00.0Z 

Request:

 GET https://www.googleapis.com/youtube/v3/activities?part=id%2Csnippet&home=true&publishedAfter=2015-01-10T00%3A00%3A00.0Z&key={YOUR_API_KEY} 

From the JSON response:

 ... "publishedAt": "2015-01-12T14:47:50.000Z", ... "publishedAt": "2015-01-06T16:24:28.000Z", ... "publishedAt": "2015-01-07T16:36:44.000Z", ... "publishedAt": "2015-01-12T13:26:01.000Z", ... "publishedAt": "2015-01-07T16:19:07.000Z", ... 

Some of these dates are until 2015-01-10

Not sure if I missed something in the docs or this is a mistake. This seems like normal for "my" videos (my = true) and actions for a specific channel (channelId = abc123)

I just recently created this account / activated 'my' channel if this has any effect.

UPDATE just realized that there are two open problems for this:

https://code.google.com/p/gdata-issues/issues/detail?id=6088

https://code.google.com/p/gdata-issues/issues/detail?id=6366

+6
source share
1 answer

I am also not very happy with the way the API responds to this term and suspects that it might be fussy regarding the timestamp format. According to the publishedAfter and publishedBefore documents, there should be an RFC 3339 formatted date-time value ( 1970-01-01T00:00:00Z )

+1
source

Source: https://habr.com/ru/post/980877/


All Articles