(users)
- getFollowers - This endpoint is part of the Bluesky application Lexicon APIs (
app.bsky.*
). Public endpoints which don't require authentication can be made directly against the public Bluesky AppView API: https://public.api.bsky.app. Authenticated requests are usually made to the user's PDS, with automatic service proxying. Authenticated requests can be used for both public and non-public endpoints.
To learn more about calling atproto API endpoints like this one, see the API Hosts and Auth guide.
Enumerates accounts which follow a specified account (actor).
- getSuggestedFollows - This endpoint is part of the Bluesky application Lexicon APIs (
app.bsky.*
). Public endpoints which don't require authentication can be made directly against the public Bluesky AppView API: https://public.api.bsky.app. Authenticated requests are usually made to the user's PDS, with automatic service proxying. Authenticated requests can be used for both public and non-public endpoints.
To learn more about calling atproto API endpoints like this one, see the API Hosts and Auth guide.
Enumerates follows similar to a given account (actor). Expected use is to recommend additional accounts immediately after following one account.
- unmute - This endpoint is part of the Bluesky application Lexicon APIs (
app.bsky.*
). Public endpoints which don't require authentication can be made directly against the public Bluesky AppView API: https://public.api.bsky.app. Authenticated requests are usually made to the user's PDS, with automatic service proxying. Authenticated requests can be used for both public and non-public endpoints.
To learn more about calling atproto API endpoints like this one, see the API Hosts and Auth guide.
Unmutes the specified account. Requires auth.
This endpoint is part of the Bluesky application Lexicon APIs (app.bsky.*
). Public endpoints which don't require authentication can be made directly against the public Bluesky AppView API: https://public.api.bsky.app. Authenticated requests are usually made to the user's PDS, with automatic service proxying. Authenticated requests can be used for both public and non-public endpoints.
To learn more about calling atproto API endpoints like this one, see the API Hosts and Auth guide.
Enumerates accounts which follow a specified account (actor).
import { Bluesky } from "@speakeasy-api/bluesky";
const bluesky = new Bluesky({
bearer: process.env["BLUESKY_BEARER"] ?? "",
});
async function run() {
const result = await bluesky.users.getFollowers({
actor: "<value>",
});
for await (const page of result) {
// Handle the page
console.log(page);
}
}
run();
The standalone function version of this method:
import { BlueskyCore } from "@speakeasy-api/bluesky/core.js";
import { usersGetFollowers } from "@speakeasy-api/bluesky/funcs/usersGetFollowers.js";
// Use `BlueskyCore` for best tree-shaking performance.
// You can create one instance of it to use across an application.
const bluesky = new BlueskyCore({
bearer: process.env["BLUESKY_BEARER"] ?? "",
});
async function run() {
const res = await usersGetFollowers(bluesky, {
actor: "<value>",
});
if (!res.ok) {
throw res.error;
}
const { value: result } = res;
for await (const page of result) {
// Handle the page
console.log(page);
}
}
run();
This method can be used in React components through the following hooks and associated utilities.
Check out this guide for information about each of the utilities below and how to get started using React hooks.
import {
// Query hooks for fetching data.
useFollowers,
useFollowersSuspense,
// Query hooks suitable for building infinite scrolling or "load more" UIs.
useFollowersInfinite,
useFollowersInfiniteSuspense,
// Utility for prefetching data during server-side rendering and in React
// Server Components that will be immediately available to client components
// using the hooks.
prefetchFollowers,
// Utilities to invalidate the query cache for this query in response to
// mutations and other user actions.
invalidateFollowers,
invalidateAllFollowers,
} from "@speakeasy-api/bluesky/react-query/usersGetFollowers.js";
Parameter | Type | Required | Description |
---|---|---|---|
request |
operations.AppBskyGraphGetFollowersRequest | ✔️ | The request object to use for the request. |
options |
RequestOptions | ➖ | Used to set various options for making HTTP requests. |
options.fetchOptions |
RequestInit | ➖ | Options that are passed to the underlying HTTP request. This can be used to inject extra headers for examples. All Request options, except method and body , are allowed. |
options.retries |
RetryConfig | ➖ | Enables retrying HTTP requests under certain failure conditions. |
Promise<operations.AppBskyGraphGetFollowersResponse>
Error Type | Status Code | Content Type |
---|---|---|
errors.AppBskyGraphGetFollowersResponseBody | 400 | application/json |
errors.AppBskyGraphGetFollowersUsersResponseBody | 401 | application/json |
errors.Unauthorized | 403, 407, 511 | application/json |
errors.NotFound | 404, 501, 505 | application/json |
errors.Timeout | 408, 504 | application/json |
errors.BadRequest | 413, 414, 415, 422, 431, 510 | application/json |
errors.RateLimited | 429 | application/json |
errors.InternalServerError | 500, 502, 503, 506, 507, 508 | application/json |
errors.APIError | 4XX, 5XX | */* |
This endpoint is part of the Bluesky application Lexicon APIs (app.bsky.*
). Public endpoints which don't require authentication can be made directly against the public Bluesky AppView API: https://public.api.bsky.app. Authenticated requests are usually made to the user's PDS, with automatic service proxying. Authenticated requests can be used for both public and non-public endpoints.
To learn more about calling atproto API endpoints like this one, see the API Hosts and Auth guide.
Enumerates follows similar to a given account (actor). Expected use is to recommend additional accounts immediately after following one account.
import { Bluesky } from "@speakeasy-api/bluesky";
const bluesky = new Bluesky({
bearer: process.env["BLUESKY_BEARER"] ?? "",
});
async function run() {
const result = await bluesky.users.getSuggestedFollows({
actor: "<value>",
});
// Handle the result
console.log(result);
}
run();
The standalone function version of this method:
import { BlueskyCore } from "@speakeasy-api/bluesky/core.js";
import { usersGetSuggestedFollows } from "@speakeasy-api/bluesky/funcs/usersGetSuggestedFollows.js";
// Use `BlueskyCore` for best tree-shaking performance.
// You can create one instance of it to use across an application.
const bluesky = new BlueskyCore({
bearer: process.env["BLUESKY_BEARER"] ?? "",
});
async function run() {
const res = await usersGetSuggestedFollows(bluesky, {
actor: "<value>",
});
if (!res.ok) {
throw res.error;
}
const { value: result } = res;
// Handle the result
console.log(result);
}
run();
This method can be used in React components through the following hooks and associated utilities.
Check out this guide for information about each of the utilities below and how to get started using React hooks.
import {
// Query hooks for fetching data.
useUsersGetSuggestedFollows,
useUsersGetSuggestedFollowsSuspense,
// Utility for prefetching data during server-side rendering and in React
// Server Components that will be immediately available to client components
// using the hooks.
prefetchUsersGetSuggestedFollows,
// Utilities to invalidate the query cache for this query in response to
// mutations and other user actions.
invalidateUsersGetSuggestedFollows,
invalidateAllUsersGetSuggestedFollows,
} from "@speakeasy-api/bluesky/react-query/usersGetSuggestedFollows.js";
Parameter | Type | Required | Description |
---|---|---|---|
request |
operations.AppBskyGraphGetSuggestedFollowsByActorRequest | ✔️ | The request object to use for the request. |
options |
RequestOptions | ➖ | Used to set various options for making HTTP requests. |
options.fetchOptions |
RequestInit | ➖ | Options that are passed to the underlying HTTP request. This can be used to inject extra headers for examples. All Request options, except method and body , are allowed. |
options.retries |
RetryConfig | ➖ | Enables retrying HTTP requests under certain failure conditions. |
Promise<operations.AppBskyGraphGetSuggestedFollowsByActorResponseBody>
Error Type | Status Code | Content Type |
---|---|---|
errors.AppBskyGraphGetSuggestedFollowsByActorResponseBody | 400 | application/json |
errors.AppBskyGraphGetSuggestedFollowsByActorUsersResponseBody | 401 | application/json |
errors.Unauthorized | 403, 407, 511 | application/json |
errors.NotFound | 404, 501, 505 | application/json |
errors.Timeout | 408, 504 | application/json |
errors.BadRequest | 413, 414, 415, 422, 431, 510 | application/json |
errors.RateLimited | 429 | application/json |
errors.InternalServerError | 500, 502, 503, 506, 507, 508 | application/json |
errors.APIError | 4XX, 5XX | */* |
This endpoint is part of the Bluesky application Lexicon APIs (app.bsky.*
). Public endpoints which don't require authentication can be made directly against the public Bluesky AppView API: https://public.api.bsky.app. Authenticated requests are usually made to the user's PDS, with automatic service proxying. Authenticated requests can be used for both public and non-public endpoints.
To learn more about calling atproto API endpoints like this one, see the API Hosts and Auth guide.
Unmutes the specified account. Requires auth.
import { Bluesky } from "@speakeasy-api/bluesky";
const bluesky = new Bluesky({
bearer: process.env["BLUESKY_BEARER"] ?? "",
});
async function run() {
await bluesky.users.unmute({
actor: "<value>",
});
}
run();
The standalone function version of this method:
import { BlueskyCore } from "@speakeasy-api/bluesky/core.js";
import { usersUnmute } from "@speakeasy-api/bluesky/funcs/usersUnmute.js";
// Use `BlueskyCore` for best tree-shaking performance.
// You can create one instance of it to use across an application.
const bluesky = new BlueskyCore({
bearer: process.env["BLUESKY_BEARER"] ?? "",
});
async function run() {
const res = await usersUnmute(bluesky, {
actor: "<value>",
});
if (!res.ok) {
throw res.error;
}
const { value: result } = res;
}
run();
This method can be used in React components through the following hooks and associated utilities.
Check out this guide for information about each of the utilities below and how to get started using React hooks.
import {
// Mutation hook for triggering the API call.
useUsersUnmuteMutation
} from "@speakeasy-api/bluesky/react-query/usersUnmute.js";
Parameter | Type | Required | Description |
---|---|---|---|
request |
operations.AppBskyGraphUnmuteActorRequestBody | ✔️ | The request object to use for the request. |
options |
RequestOptions | ➖ | Used to set various options for making HTTP requests. |
options.fetchOptions |
RequestInit | ➖ | Options that are passed to the underlying HTTP request. This can be used to inject extra headers for examples. All Request options, except method and body , are allowed. |
options.retries |
RetryConfig | ➖ | Enables retrying HTTP requests under certain failure conditions. |
Promise<void>
Error Type | Status Code | Content Type |
---|---|---|
errors.AppBskyGraphUnmuteActorResponseBody | 400 | application/json |
errors.AppBskyGraphUnmuteActorUsersResponseBody | 401 | application/json |
errors.Unauthorized | 403, 407, 511 | application/json |
errors.NotFound | 404, 501, 505 | application/json |
errors.Timeout | 408, 504 | application/json |
errors.BadRequest | 413, 414, 415, 422, 431, 510 | application/json |
errors.RateLimited | 429 | application/json |
errors.InternalServerError | 500, 502, 503, 506, 507, 508 | application/json |
errors.APIError | 4XX, 5XX | */* |