Get followers of a user. Page size 10-100; use cursor for more pages. $0.10/1000 users.
package hello.world;
import io.twexapi.sdk.XapiScraper;
import io.twexapi.sdk.models.components.FollowersFollowingV3Query;
import io.twexapi.sdk.models.errors.HTTPValidationError;
import io.twexapi.sdk.models.operations.UsersFollowersListResponse;
import java.lang.Exception;
public class Application {
public static void main(String[] args) throws HTTPValidationError, Exception {
XapiScraper sdk = XapiScraper.builder()
.bearerAuth(System.getenv().getOrDefault("BEARER_AUTH", ""))
.build();
FollowersFollowingV3Query req = FollowersFollowingV3Query.builder()
.username("elonmusk")
.count(20L)
.cursor("1870681402093130182|2076960004551737340")
.build();
UsersFollowersListResponse res = sdk.users().followers().list()
.request(req)
.call();
if (res.verifiedFollowersResponse().isPresent()) {
System.out.println(res.verifiedFollowersResponse().get());
}
}
}
UsersFollowersListResponse
| Error Type |
Status Code |
Content Type |
| models/errors/HTTPValidationError |
422 |
application/json |
| models/errors/APIException |
4XX, 5XX |
*/* |
Get blue-verified followers of a user. Page size 10-100; use cursor for more pages. $0.10/1000 users.
package hello.world;
import io.twexapi.sdk.XapiScraper;
import io.twexapi.sdk.models.components.FollowersFollowingV3Query;
import io.twexapi.sdk.models.errors.HTTPValidationError;
import io.twexapi.sdk.models.operations.UsersFollowersVerifiedResponse;
import java.lang.Exception;
public class Application {
public static void main(String[] args) throws HTTPValidationError, Exception {
XapiScraper sdk = XapiScraper.builder()
.bearerAuth(System.getenv().getOrDefault("BEARER_AUTH", ""))
.build();
FollowersFollowingV3Query req = FollowersFollowingV3Query.builder()
.username("elonmusk")
.count(20L)
.cursor("1870681402093130182|2076960004551737340")
.build();
UsersFollowersVerifiedResponse res = sdk.users().followers().verified()
.request(req)
.call();
if (res.verifiedFollowersResponse().isPresent()) {
System.out.println(res.verifiedFollowersResponse().get());
}
}
}
UsersFollowersVerifiedResponse
| Error Type |
Status Code |
Content Type |
| models/errors/HTTPValidationError |
422 |
application/json |
| models/errors/APIException |
4XX, 5XX |
*/* |