You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
There are two types of authorization. One, that is intended for apps, and second for apps and web applications.
2
+
3
+
Current OpenVK's official instance is located at https://api.openvk.org/. Don't try to visit this link, it will redirect you back - this domain is made special for API requests because of Anti-DDOS limitations.
Replace `{YOUR DOMAIN}`, `{YOUR USERNAME}` and `{YOUR PASSWORD}` to it's proper value.
6
12
7
13
You'll get a response like this:
8
14
@@ -14,30 +20,28 @@ You'll get a response like this:
14
20
}
15
21
```
16
22
17
-
If you need to call the function that requires a token, just put the `access_token` into your GET or POST request.
23
+
If you need to call the function that requires a token, just put the `access_token` into your GET or POST request, or in HTTP header "Authorization" as Bearer token.
18
24
19
-
If you have two-factor authorization turned on, add a `code` field to your POST request and fill it with, you guessed it, authorization code.
25
+
If you have two-factor authorization turned on, either sumbit the code via `request_uri` in Web or pass the 2FA code to the `code` field.
20
26
21
-
**Client name**
27
+
### Client name
22
28
23
-
At this moment, OpenVK API apps are not implemented. But you can set client name for your token: for this, pass `client_name` param at token page:
This name will be seen in some parts of site (online mark and post).
29
+
At this moment, OpenVK API apps are not implemented. But you can set client name for your token: for this, pass `client_name` param at token endpoint. This name will be seen in some parts of site (online mark and post).
28
30
29
31
## OAuth
30
32
31
33
To get token via OAuth, you should call the "authorize" page:
As api apps are not implemented, you cannot revoke individual token, but you can revoke all tokens at once: for this, go to {YOUR DOMAIN}/settings?act=security -> "End all sessions".
47
+
As api apps are not implemented, you cannot revoke individual token, but you can revoke all tokens at once: for this, go to /settings?act=security -> "End all sessions".
Execute method. Javascript-like scripting language, where you can make up to 25 API calls to generate complex results in one go. Server will compile your code and execute it.
0 commit comments