Last active
January 2, 2016 07:08
-
-
Save akkez/8267641 to your computer and use it in GitHub Desktop.
Script which helps to transfer all photos from one album to another in VK.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var user_id = 0; | |
var from_album = 0; | |
var to_album = 0; | |
var photos = API.photos.get({album_id: from_album}).items@.id; | |
var i = 0; | |
var result = []; | |
while (i < photos.length) { | |
result = result + API.photos.move({ | |
owner_id: user_id, | |
target_album_id: to_album, | |
photo_id: photos[i] | |
}); | |
i = i + 1; | |
} | |
return result; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment