Z
Z
zepars2015-07-04 17:55:19
In contact with
zepars, 2015-07-04 17:55:19

Working with VK API. Why does the groups.search query return fewer groups than it should?

Purpose: to get a list of groups named "habr" using VK Api.
1) I get a token: oauth.vk.com/authorize?client_id=3682744&v=5.34&sc...
2) I check the validity of the token: https://api.vk.com/method/users.get?access_token=M..
(my account information is displayed) 3
) I get information about groups (grops.search method): https://api.vkontakte.ru/method/groups.search.xml?...
Gives out count=1, that is, only 1 group. In the application, on the site, in the sandbox of requests, it issues 11 groups. It's the same with other queries, for example, searching for "music" gives me 230, but it should be 147456. Why?

Answer the question

In order to leave comments, you need to log in

2 answer(s)
�
âš¡ Kotobotov âš¡, 2015-07-04
@angrySCV

I have 11 groups with your request.
I can't vouch for other methods (music) -> there is no permission for them in the request.
also, in each request, you should specify the api version -> in the sandbox it works on the latest version, by default (without specifying the version), the answer may differ.

Z
zepars, 2015-07-04
@zepars

Found a problem: I had to replace the client_id, because I took the ipad application

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question