@neynar/nodejs-sdk
Version:
SDK to interact with Neynar APIs (https://docs.neynar.com/reference/quickstart)
837 lines • 82.4 kB
TypeScript
/**
* Neynar API
* The Neynar API allows you to interact with the Farcaster protocol among other things. See the [Neynar docs](https://docs.neynar.com/reference) for more details.
*
* The version of the OpenAPI document: 3.115.0
* Contact: team@neynar.com
*
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
* https://openapi-generator.tech
* Do not edit the class manually.
*/
import type { Configuration } from '../configuration';
import type { AxiosPromise, AxiosInstance, RawAxiosRequestConfig } from 'axios';
import { type RequestArgs, BaseAPI } from '../base';
import type { ChannelFollowReqBody } from '../models';
import type { ChannelListResponse } from '../models';
import type { ChannelMemberInviteListResponse } from '../models';
import type { ChannelMemberListResponse } from '../models';
import type { ChannelResponse } from '../models';
import type { ChannelResponseBulk } from '../models';
import type { ChannelSearchResponse } from '../models';
import type { InviteChannelMemberReqBody } from '../models';
import type { OperationResponse } from '../models';
import type { RelevantFollowersResponse } from '../models';
import type { RemoveChannelMemberReqBody } from '../models';
import type { RespondChannelInviteReqBody } from '../models';
import type { TrendingChannelResponse } from '../models';
import type { UsersActiveChannelsResponse } from '../models';
import type { UsersResponse } from '../models';
/**
* ChannelApi - axios parameter creator
* @export
*/
export declare const ChannelApiAxiosParamCreator: (configuration?: Configuration) => {
/**
* Returns a list of all channels with their details
* @summary Fetch all channels with their details
* @param {number} [limit] Number of results to fetch (Default: 20, Maximum: 200)
* @param {string} [cursor] Pagination cursor.
* @param {*} [options] Override http request option.
* @throws {RequiredError}
* @returns {Promise<ChannelListResponse>} A promise that resolves to a `ChannelListResponse` object
*
* For more information, refer to the [API documentation](https://docs.neynar.com/reference/fetch-all-channels)
*
*/
fetchAllChannels: (limit?: number, cursor?: string, options?: RawAxiosRequestConfig) => Promise<RequestArgs>;
/**
* Returns details of multiple channels
* @summary Bulk fetch
* @param {string} ids Comma separated list of channel IDs or parent_urls, up to 100 at a time
* @param {FetchBulkChannelsTypeEnum} [type] Type of identifier being used to query the channels. Defaults to ID.
* @param {number} [viewerFid] FID of the user viewing the channels.
* @param {*} [options] Override http request option.
* @throws {RequiredError}
* @returns {Promise<ChannelResponseBulk>} A promise that resolves to a `ChannelResponseBulk` object
*
* For more information, refer to the [API documentation](https://docs.neynar.com/reference/fetch-bulk-channels)
*
*/
fetchBulkChannels: (ids: string, type?: FetchBulkChannelsTypeEnum, viewerFid?: number, options?: RawAxiosRequestConfig) => Promise<RequestArgs>;
/**
* Fetch a list of invites, either in a channel or for a user. If both are provided, open channel invite for that user is returned.
* @summary Open invites
* @param {string} [channelId] Channel ID for the channel being queried
* @param {number} [invitedFid] FID of the user being invited
* @param {number} [limit] Number of results to fetch (Default: 20, Maximum: 100)
* @param {string} [cursor] Pagination cursor.
* @param {*} [options] Override http request option.
* @throws {RequiredError}
* @returns {Promise<ChannelMemberInviteListResponse>} A promise that resolves to a `ChannelMemberInviteListResponse` object
*
* For more information, refer to the [API documentation](https://docs.neynar.com/reference/fetch-channel-invites)
*
*/
fetchChannelInvites: (channelId?: string, invitedFid?: number, limit?: number, cursor?: string, options?: RawAxiosRequestConfig) => Promise<RequestArgs>;
/**
* Fetch a list of members in a channel
* @summary Fetch members
* @param {string} channelId Channel ID for the channel being queried
* @param {boolean} [xNeynarExperimental] Enables experimental features including filtering based on the Neynar score. See [docs](https://neynar.notion.site/Experimental-Features-1d2655195a8b80eb98b4d4ae7b76ae4a) for more details.
* @param {number} [fid] FID of the user being queried. Specify this to check if a user is a member of the channel without paginating through all members.
* @param {number} [limit] Number of results to fetch (Default: 20, Maximum: 100)
* @param {string} [cursor] Pagination cursor.
* @param {*} [options] Override http request option.
* @throws {RequiredError}
* @returns {Promise<ChannelMemberListResponse>} A promise that resolves to a `ChannelMemberListResponse` object
*
* For more information, refer to the [API documentation](https://docs.neynar.com/reference/fetch-channel-members)
*
*/
fetchChannelMembers: (channelId: string, xNeynarExperimental?: boolean, fid?: number, limit?: number, cursor?: string, options?: RawAxiosRequestConfig) => Promise<RequestArgs>;
/**
* Returns a list of followers for a specific channel. Max limit is 1000. Use cursor for pagination.
* @summary For channel
* @param {string} id Channel ID for the channel being queried
* @param {boolean} [xNeynarExperimental] Enables experimental features including filtering based on the Neynar score. See [docs](https://neynar.notion.site/Experimental-Features-1d2655195a8b80eb98b4d4ae7b76ae4a) for more details.
* @param {number} [viewerFid] Providing this will return a list of followers that respects this user\'s mutes and blocks and includes `viewer_context`.
* @param {string} [cursor] Pagination cursor.
* @param {number} [limit] Number of followers to fetch (Default: 25, Maximum: 1000)
* @param {*} [options] Override http request option.
* @throws {RequiredError}
* @returns {Promise<UsersResponse>} A promise that resolves to a `UsersResponse` object
*
* For more information, refer to the [API documentation](https://docs.neynar.com/reference/fetch-followers-for-a-channel)
*
*/
fetchFollowersForAChannel: (id: string, xNeynarExperimental?: boolean, viewerFid?: number, cursor?: string, limit?: number, options?: RawAxiosRequestConfig) => Promise<RequestArgs>;
/**
* Returns a list of relevant channel followers for a specific FID. This usually shows on a channel as \"X, Y, Z follow this channel\".
* @summary Relevant followers
* @param {string} id Channel ID being queried
* @param {number} viewerFid The FID of the user to customize this response for. Providing this will also return a list of followers that respects this user\'s mutes and blocks and includes `viewer_context`.
* @param {boolean} [xNeynarExperimental] Enables experimental features including filtering based on the Neynar score. See [docs](https://neynar.notion.site/Experimental-Features-1d2655195a8b80eb98b4d4ae7b76ae4a) for more details.
* @param {*} [options] Override http request option.
* @throws {RequiredError}
* @returns {Promise<RelevantFollowersResponse>} A promise that resolves to a `RelevantFollowersResponse` object
*
* For more information, refer to the [API documentation](https://docs.neynar.com/reference/fetch-relevant-followers-for-a-channel)
*
*/
fetchRelevantFollowersForAChannel: (id: string, viewerFid: number, xNeynarExperimental?: boolean, options?: RawAxiosRequestConfig) => Promise<RequestArgs>;
/**
* Returns a list of trending channels based on activity
* @summary Channels by activity
* @param {FetchTrendingChannelsTimeWindowEnum} [timeWindow]
* @param {number} [limit] Number of results to fetch (Default: 10, Maximum: 25)
* @param {string} [cursor] Pagination cursor.
* @param {*} [options] Override http request option.
* @throws {RequiredError}
* @returns {Promise<TrendingChannelResponse>} A promise that resolves to a `TrendingChannelResponse` object
*
* For more information, refer to the [API documentation](https://docs.neynar.com/reference/fetch-trending-channels)
*
*/
fetchTrendingChannels: (timeWindow?: FetchTrendingChannelsTimeWindowEnum, limit?: number, cursor?: string, options?: RawAxiosRequestConfig) => Promise<RequestArgs>;
/**
* Returns a list of all channels with their details that an FID is a member of. Data may have a delay of up to 1 hour.
* @summary Member of
* @param {number} fid The FID of the user.
* @param {number} [limit] Number of results to fetch (Default: 20, Maximum: 100)
* @param {string} [cursor] Pagination cursor.
* @param {*} [options] Override http request option.
* @throws {RequiredError}
* @returns {Promise<ChannelMemberListResponse>} A promise that resolves to a `ChannelMemberListResponse` object
*
* For more information, refer to the [API documentation](https://docs.neynar.com/reference/fetch-user-channel-memberships)
*
*/
fetchUserChannelMemberships: (fid: number, limit?: number, cursor?: string, options?: RawAxiosRequestConfig) => Promise<RequestArgs>;
/**
* Returns a list of all channels with their details that a FID follows.
* @summary Following
* @param {number} fid The FID of the user.
* @param {number} [limit] Number of results to fetch (Default: 25, Maximum: 100)
* @param {string} [cursor] Pagination cursor.
* @param {*} [options] Override http request option.
* @throws {RequiredError}
* @returns {Promise<ChannelListResponse>} A promise that resolves to a `ChannelListResponse` object
*
* For more information, refer to the [API documentation](https://docs.neynar.com/reference/fetch-user-channels)
*
*/
fetchUserChannels: (fid: number, limit?: number, cursor?: string, options?: RawAxiosRequestConfig) => Promise<RequestArgs>;
/**
* Fetches all channels that a user has casted in, in reverse chronological order.
* @summary Fetch channels that user is active in
* @param {number} fid The user\'s FID (identifier)
* @param {number} [limit] Number of results to fetch (Default: 20, Maximum: 100)
* @param {string} [cursor] Pagination cursor.
* @param {*} [options] Override http request option.
* @throws {RequiredError}
* @returns {Promise<UsersActiveChannelsResponse>} A promise that resolves to a `UsersActiveChannelsResponse` object
*
* For more information, refer to the [API documentation](https://docs.neynar.com/reference/fetch-users-active-channels)
*
*/
fetchUsersActiveChannels: (fid: number, limit?: number, cursor?: string, options?: RawAxiosRequestConfig) => Promise<RequestArgs>;
/**
* Follow a channel
* @summary Follow a channel
* @param {ChannelFollowReqBody} channelFollowReqBody
* @param {*} [options] Override http request option.
* @throws {RequiredError}
* @returns {Promise<OperationResponse>} A promise that resolves to a `OperationResponse` object
*
* For more information, refer to the [API documentation](https://docs.neynar.com/reference/follow-channel)
*
*/
followChannel: (channelFollowReqBody: ChannelFollowReqBody, options?: RawAxiosRequestConfig) => Promise<RequestArgs>;
/**
* Invite a user to a channel
* @summary Invite
* @param {InviteChannelMemberReqBody} inviteChannelMemberReqBody
* @param {*} [options] Override http request option.
* @throws {RequiredError}
* @returns {Promise<OperationResponse>} A promise that resolves to a `OperationResponse` object
*
* For more information, refer to the [API documentation](https://docs.neynar.com/reference/invite-channel-member)
*
*/
inviteChannelMember: (inviteChannelMemberReqBody: InviteChannelMemberReqBody, options?: RawAxiosRequestConfig) => Promise<RequestArgs>;
/**
* Returns details of a channel
* @summary By ID or parent_url
* @param {string} id Channel ID for the channel being queried
* @param {LookupChannelTypeEnum} [type] Type of identifier being used to query the channel. Defaults to ID.
* @param {number} [viewerFid] FID of the user viewing the channel.
* @param {*} [options] Override http request option.
* @throws {RequiredError}
* @returns {Promise<ChannelResponse>} A promise that resolves to a `ChannelResponse` object
*
* For more information, refer to the [API documentation](https://docs.neynar.com/reference/lookup-channel)
*
*/
lookupChannel: (id: string, type?: LookupChannelTypeEnum, viewerFid?: number, options?: RawAxiosRequestConfig) => Promise<RequestArgs>;
/**
* Remove a user from a channel or a user\'s invite to a channel role
* @summary Remove user
* @param {RemoveChannelMemberReqBody} removeChannelMemberReqBody
* @param {*} [options] Override http request option.
* @throws {RequiredError}
* @returns {Promise<OperationResponse>} A promise that resolves to a `OperationResponse` object
*
* For more information, refer to the [API documentation](https://docs.neynar.com/reference/remove-channel-member)
*
*/
removeChannelMember: (removeChannelMemberReqBody: RemoveChannelMemberReqBody, options?: RawAxiosRequestConfig) => Promise<RequestArgs>;
/**
* Accept or reject a channel invite
* @summary Accept or reject an invite
* @param {RespondChannelInviteReqBody} respondChannelInviteReqBody
* @param {*} [options] Override http request option.
* @throws {RequiredError}
* @returns {Promise<OperationResponse>} A promise that resolves to a `OperationResponse` object
*
* For more information, refer to the [API documentation](https://docs.neynar.com/reference/respond-channel-invite)
*
*/
respondChannelInvite: (respondChannelInviteReqBody: RespondChannelInviteReqBody, options?: RawAxiosRequestConfig) => Promise<RequestArgs>;
/**
* Returns a list of channels based on ID or name
* @summary Search by ID or name
* @param {string} q Channel ID or name for the channel being queried
* @param {number} [limit] Number of results to fetch (Default: 20, Maximum: 200)
* @param {string} [cursor] Pagination cursor.
* @param {number} [viewerFid] FID of the user viewing the channels.
* @param {*} [options] Override http request option.
* @throws {RequiredError}
* @returns {Promise<ChannelSearchResponse>} A promise that resolves to a `ChannelSearchResponse` object
*
* For more information, refer to the [API documentation](https://docs.neynar.com/reference/search-channels)
*
*/
searchChannels: (q: string, limit?: number, cursor?: string, viewerFid?: number, options?: RawAxiosRequestConfig) => Promise<RequestArgs>;
/**
* Unfollow a channel
* @summary Unfollow a channel
* @param {ChannelFollowReqBody} channelFollowReqBody
* @param {*} [options] Override http request option.
* @throws {RequiredError}
* @returns {Promise<OperationResponse>} A promise that resolves to a `OperationResponse` object
*
* For more information, refer to the [API documentation](https://docs.neynar.com/reference/unfollow-channel)
*
*/
unfollowChannel: (channelFollowReqBody: ChannelFollowReqBody, options?: RawAxiosRequestConfig) => Promise<RequestArgs>;
};
/**
* ChannelApi - functional programming interface
* @export
*/
export declare const ChannelApiFp: (configuration?: Configuration) => {
/**
* Returns a list of all channels with their details
* @summary Fetch all channels with their details
* @param {number} [limit] Number of results to fetch (Default: 20, Maximum: 200)
* @param {string} [cursor] Pagination cursor.
* @param {*} [options] Override http request option.
* @throws {RequiredError}
* @returns {Promise<ChannelListResponse>} A promise that resolves to a `ChannelListResponse` object
*
* For more information, refer to the [API documentation](https://docs.neynar.com/reference/fetch-all-channels)
*
*/
fetchAllChannels(limit?: number, cursor?: string, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<ChannelListResponse>>;
/**
* Returns details of multiple channels
* @summary Bulk fetch
* @param {string} ids Comma separated list of channel IDs or parent_urls, up to 100 at a time
* @param {FetchBulkChannelsTypeEnum} [type] Type of identifier being used to query the channels. Defaults to ID.
* @param {number} [viewerFid] FID of the user viewing the channels.
* @param {*} [options] Override http request option.
* @throws {RequiredError}
* @returns {Promise<ChannelResponseBulk>} A promise that resolves to a `ChannelResponseBulk` object
*
* For more information, refer to the [API documentation](https://docs.neynar.com/reference/fetch-bulk-channels)
*
*/
fetchBulkChannels(ids: string, type?: FetchBulkChannelsTypeEnum, viewerFid?: number, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<ChannelResponseBulk>>;
/**
* Fetch a list of invites, either in a channel or for a user. If both are provided, open channel invite for that user is returned.
* @summary Open invites
* @param {string} [channelId] Channel ID for the channel being queried
* @param {number} [invitedFid] FID of the user being invited
* @param {number} [limit] Number of results to fetch (Default: 20, Maximum: 100)
* @param {string} [cursor] Pagination cursor.
* @param {*} [options] Override http request option.
* @throws {RequiredError}
* @returns {Promise<ChannelMemberInviteListResponse>} A promise that resolves to a `ChannelMemberInviteListResponse` object
*
* For more information, refer to the [API documentation](https://docs.neynar.com/reference/fetch-channel-invites)
*
*/
fetchChannelInvites(channelId?: string, invitedFid?: number, limit?: number, cursor?: string, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<ChannelMemberInviteListResponse>>;
/**
* Fetch a list of members in a channel
* @summary Fetch members
* @param {string} channelId Channel ID for the channel being queried
* @param {boolean} [xNeynarExperimental] Enables experimental features including filtering based on the Neynar score. See [docs](https://neynar.notion.site/Experimental-Features-1d2655195a8b80eb98b4d4ae7b76ae4a) for more details.
* @param {number} [fid] FID of the user being queried. Specify this to check if a user is a member of the channel without paginating through all members.
* @param {number} [limit] Number of results to fetch (Default: 20, Maximum: 100)
* @param {string} [cursor] Pagination cursor.
* @param {*} [options] Override http request option.
* @throws {RequiredError}
* @returns {Promise<ChannelMemberListResponse>} A promise that resolves to a `ChannelMemberListResponse` object
*
* For more information, refer to the [API documentation](https://docs.neynar.com/reference/fetch-channel-members)
*
*/
fetchChannelMembers(channelId: string, xNeynarExperimental?: boolean, fid?: number, limit?: number, cursor?: string, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<ChannelMemberListResponse>>;
/**
* Returns a list of followers for a specific channel. Max limit is 1000. Use cursor for pagination.
* @summary For channel
* @param {string} id Channel ID for the channel being queried
* @param {boolean} [xNeynarExperimental] Enables experimental features including filtering based on the Neynar score. See [docs](https://neynar.notion.site/Experimental-Features-1d2655195a8b80eb98b4d4ae7b76ae4a) for more details.
* @param {number} [viewerFid] Providing this will return a list of followers that respects this user\'s mutes and blocks and includes `viewer_context`.
* @param {string} [cursor] Pagination cursor.
* @param {number} [limit] Number of followers to fetch (Default: 25, Maximum: 1000)
* @param {*} [options] Override http request option.
* @throws {RequiredError}
* @returns {Promise<UsersResponse>} A promise that resolves to a `UsersResponse` object
*
* For more information, refer to the [API documentation](https://docs.neynar.com/reference/fetch-followers-for-a-channel)
*
*/
fetchFollowersForAChannel(id: string, xNeynarExperimental?: boolean, viewerFid?: number, cursor?: string, limit?: number, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<UsersResponse>>;
/**
* Returns a list of relevant channel followers for a specific FID. This usually shows on a channel as \"X, Y, Z follow this channel\".
* @summary Relevant followers
* @param {string} id Channel ID being queried
* @param {number} viewerFid The FID of the user to customize this response for. Providing this will also return a list of followers that respects this user\'s mutes and blocks and includes `viewer_context`.
* @param {boolean} [xNeynarExperimental] Enables experimental features including filtering based on the Neynar score. See [docs](https://neynar.notion.site/Experimental-Features-1d2655195a8b80eb98b4d4ae7b76ae4a) for more details.
* @param {*} [options] Override http request option.
* @throws {RequiredError}
* @returns {Promise<RelevantFollowersResponse>} A promise that resolves to a `RelevantFollowersResponse` object
*
* For more information, refer to the [API documentation](https://docs.neynar.com/reference/fetch-relevant-followers-for-a-channel)
*
*/
fetchRelevantFollowersForAChannel(id: string, viewerFid: number, xNeynarExperimental?: boolean, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<RelevantFollowersResponse>>;
/**
* Returns a list of trending channels based on activity
* @summary Channels by activity
* @param {FetchTrendingChannelsTimeWindowEnum} [timeWindow]
* @param {number} [limit] Number of results to fetch (Default: 10, Maximum: 25)
* @param {string} [cursor] Pagination cursor.
* @param {*} [options] Override http request option.
* @throws {RequiredError}
* @returns {Promise<TrendingChannelResponse>} A promise that resolves to a `TrendingChannelResponse` object
*
* For more information, refer to the [API documentation](https://docs.neynar.com/reference/fetch-trending-channels)
*
*/
fetchTrendingChannels(timeWindow?: FetchTrendingChannelsTimeWindowEnum, limit?: number, cursor?: string, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<TrendingChannelResponse>>;
/**
* Returns a list of all channels with their details that an FID is a member of. Data may have a delay of up to 1 hour.
* @summary Member of
* @param {number} fid The FID of the user.
* @param {number} [limit] Number of results to fetch (Default: 20, Maximum: 100)
* @param {string} [cursor] Pagination cursor.
* @param {*} [options] Override http request option.
* @throws {RequiredError}
* @returns {Promise<ChannelMemberListResponse>} A promise that resolves to a `ChannelMemberListResponse` object
*
* For more information, refer to the [API documentation](https://docs.neynar.com/reference/fetch-user-channel-memberships)
*
*/
fetchUserChannelMemberships(fid: number, limit?: number, cursor?: string, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<ChannelMemberListResponse>>;
/**
* Returns a list of all channels with their details that a FID follows.
* @summary Following
* @param {number} fid The FID of the user.
* @param {number} [limit] Number of results to fetch (Default: 25, Maximum: 100)
* @param {string} [cursor] Pagination cursor.
* @param {*} [options] Override http request option.
* @throws {RequiredError}
* @returns {Promise<ChannelListResponse>} A promise that resolves to a `ChannelListResponse` object
*
* For more information, refer to the [API documentation](https://docs.neynar.com/reference/fetch-user-channels)
*
*/
fetchUserChannels(fid: number, limit?: number, cursor?: string, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<ChannelListResponse>>;
/**
* Fetches all channels that a user has casted in, in reverse chronological order.
* @summary Fetch channels that user is active in
* @param {number} fid The user\'s FID (identifier)
* @param {number} [limit] Number of results to fetch (Default: 20, Maximum: 100)
* @param {string} [cursor] Pagination cursor.
* @param {*} [options] Override http request option.
* @throws {RequiredError}
* @returns {Promise<UsersActiveChannelsResponse>} A promise that resolves to a `UsersActiveChannelsResponse` object
*
* For more information, refer to the [API documentation](https://docs.neynar.com/reference/fetch-users-active-channels)
*
*/
fetchUsersActiveChannels(fid: number, limit?: number, cursor?: string, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<UsersActiveChannelsResponse>>;
/**
* Follow a channel
* @summary Follow a channel
* @param {ChannelFollowReqBody} channelFollowReqBody
* @param {*} [options] Override http request option.
* @throws {RequiredError}
* @returns {Promise<OperationResponse>} A promise that resolves to a `OperationResponse` object
*
* For more information, refer to the [API documentation](https://docs.neynar.com/reference/follow-channel)
*
*/
followChannel(channelFollowReqBody: ChannelFollowReqBody, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<OperationResponse>>;
/**
* Invite a user to a channel
* @summary Invite
* @param {InviteChannelMemberReqBody} inviteChannelMemberReqBody
* @param {*} [options] Override http request option.
* @throws {RequiredError}
* @returns {Promise<OperationResponse>} A promise that resolves to a `OperationResponse` object
*
* For more information, refer to the [API documentation](https://docs.neynar.com/reference/invite-channel-member)
*
*/
inviteChannelMember(inviteChannelMemberReqBody: InviteChannelMemberReqBody, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<OperationResponse>>;
/**
* Returns details of a channel
* @summary By ID or parent_url
* @param {string} id Channel ID for the channel being queried
* @param {LookupChannelTypeEnum} [type] Type of identifier being used to query the channel. Defaults to ID.
* @param {number} [viewerFid] FID of the user viewing the channel.
* @param {*} [options] Override http request option.
* @throws {RequiredError}
* @returns {Promise<ChannelResponse>} A promise that resolves to a `ChannelResponse` object
*
* For more information, refer to the [API documentation](https://docs.neynar.com/reference/lookup-channel)
*
*/
lookupChannel(id: string, type?: LookupChannelTypeEnum, viewerFid?: number, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<ChannelResponse>>;
/**
* Remove a user from a channel or a user\'s invite to a channel role
* @summary Remove user
* @param {RemoveChannelMemberReqBody} removeChannelMemberReqBody
* @param {*} [options] Override http request option.
* @throws {RequiredError}
* @returns {Promise<OperationResponse>} A promise that resolves to a `OperationResponse` object
*
* For more information, refer to the [API documentation](https://docs.neynar.com/reference/remove-channel-member)
*
*/
removeChannelMember(removeChannelMemberReqBody: RemoveChannelMemberReqBody, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<OperationResponse>>;
/**
* Accept or reject a channel invite
* @summary Accept or reject an invite
* @param {RespondChannelInviteReqBody} respondChannelInviteReqBody
* @param {*} [options] Override http request option.
* @throws {RequiredError}
* @returns {Promise<OperationResponse>} A promise that resolves to a `OperationResponse` object
*
* For more information, refer to the [API documentation](https://docs.neynar.com/reference/respond-channel-invite)
*
*/
respondChannelInvite(respondChannelInviteReqBody: RespondChannelInviteReqBody, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<OperationResponse>>;
/**
* Returns a list of channels based on ID or name
* @summary Search by ID or name
* @param {string} q Channel ID or name for the channel being queried
* @param {number} [limit] Number of results to fetch (Default: 20, Maximum: 200)
* @param {string} [cursor] Pagination cursor.
* @param {number} [viewerFid] FID of the user viewing the channels.
* @param {*} [options] Override http request option.
* @throws {RequiredError}
* @returns {Promise<ChannelSearchResponse>} A promise that resolves to a `ChannelSearchResponse` object
*
* For more information, refer to the [API documentation](https://docs.neynar.com/reference/search-channels)
*
*/
searchChannels(q: string, limit?: number, cursor?: string, viewerFid?: number, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<ChannelSearchResponse>>;
/**
* Unfollow a channel
* @summary Unfollow a channel
* @param {ChannelFollowReqBody} channelFollowReqBody
* @param {*} [options] Override http request option.
* @throws {RequiredError}
* @returns {Promise<OperationResponse>} A promise that resolves to a `OperationResponse` object
*
* For more information, refer to the [API documentation](https://docs.neynar.com/reference/unfollow-channel)
*
*/
unfollowChannel(channelFollowReqBody: ChannelFollowReqBody, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<OperationResponse>>;
};
/**
* ChannelApi - factory interface
* @export
*/
export declare const ChannelApiFactory: (configuration?: Configuration, basePath?: string, axios?: AxiosInstance) => {
/**
* Returns a list of all channels with their details
* @summary Fetch all channels with their details
* @param {ChannelApiFetchAllChannelsRequest} requestParameters Request parameters.
* @param {*} [options] Override http request option.
* @throws {RequiredError}
* @returns {Promise<ChannelListResponse>} A promise that resolves to a `ChannelListResponse` object
*
* For more information, refer to the [API documentation](https://docs.neynar.com/reference/fetch-all-channels)
*
*/
fetchAllChannels(requestParameters?: ChannelApiFetchAllChannelsRequest, options?: RawAxiosRequestConfig): AxiosPromise<ChannelListResponse>;
/**
* Returns details of multiple channels
* @summary Bulk fetch
* @param {ChannelApiFetchBulkChannelsRequest} requestParameters Request parameters.
* @param {*} [options] Override http request option.
* @throws {RequiredError}
* @returns {Promise<ChannelResponseBulk>} A promise that resolves to a `ChannelResponseBulk` object
*
* For more information, refer to the [API documentation](https://docs.neynar.com/reference/fetch-bulk-channels)
*
*/
fetchBulkChannels(requestParameters: ChannelApiFetchBulkChannelsRequest, options?: RawAxiosRequestConfig): AxiosPromise<ChannelResponseBulk>;
/**
* Fetch a list of invites, either in a channel or for a user. If both are provided, open channel invite for that user is returned.
* @summary Open invites
* @param {ChannelApiFetchChannelInvitesRequest} requestParameters Request parameters.
* @param {*} [options] Override http request option.
* @throws {RequiredError}
* @returns {Promise<ChannelMemberInviteListResponse>} A promise that resolves to a `ChannelMemberInviteListResponse` object
*
* For more information, refer to the [API documentation](https://docs.neynar.com/reference/fetch-channel-invites)
*
*/
fetchChannelInvites(requestParameters?: ChannelApiFetchChannelInvitesRequest, options?: RawAxiosRequestConfig): AxiosPromise<ChannelMemberInviteListResponse>;
/**
* Fetch a list of members in a channel
* @summary Fetch members
* @param {ChannelApiFetchChannelMembersRequest} requestParameters Request parameters.
* @param {*} [options] Override http request option.
* @throws {RequiredError}
* @returns {Promise<ChannelMemberListResponse>} A promise that resolves to a `ChannelMemberListResponse` object
*
* For more information, refer to the [API documentation](https://docs.neynar.com/reference/fetch-channel-members)
*
*/
fetchChannelMembers(requestParameters: ChannelApiFetchChannelMembersRequest, options?: RawAxiosRequestConfig): AxiosPromise<ChannelMemberListResponse>;
/**
* Returns a list of followers for a specific channel. Max limit is 1000. Use cursor for pagination.
* @summary For channel
* @param {ChannelApiFetchFollowersForAChannelRequest} requestParameters Request parameters.
* @param {*} [options] Override http request option.
* @throws {RequiredError}
* @returns {Promise<UsersResponse>} A promise that resolves to a `UsersResponse` object
*
* For more information, refer to the [API documentation](https://docs.neynar.com/reference/fetch-followers-for-a-channel)
*
*/
fetchFollowersForAChannel(requestParameters: ChannelApiFetchFollowersForAChannelRequest, options?: RawAxiosRequestConfig): AxiosPromise<UsersResponse>;
/**
* Returns a list of relevant channel followers for a specific FID. This usually shows on a channel as \"X, Y, Z follow this channel\".
* @summary Relevant followers
* @param {ChannelApiFetchRelevantFollowersForAChannelRequest} requestParameters Request parameters.
* @param {*} [options] Override http request option.
* @throws {RequiredError}
* @returns {Promise<RelevantFollowersResponse>} A promise that resolves to a `RelevantFollowersResponse` object
*
* For more information, refer to the [API documentation](https://docs.neynar.com/reference/fetch-relevant-followers-for-a-channel)
*
*/
fetchRelevantFollowersForAChannel(requestParameters: ChannelApiFetchRelevantFollowersForAChannelRequest, options?: RawAxiosRequestConfig): AxiosPromise<RelevantFollowersResponse>;
/**
* Returns a list of trending channels based on activity
* @summary Channels by activity
* @param {ChannelApiFetchTrendingChannelsRequest} requestParameters Request parameters.
* @param {*} [options] Override http request option.
* @throws {RequiredError}
* @returns {Promise<TrendingChannelResponse>} A promise that resolves to a `TrendingChannelResponse` object
*
* For more information, refer to the [API documentation](https://docs.neynar.com/reference/fetch-trending-channels)
*
*/
fetchTrendingChannels(requestParameters?: ChannelApiFetchTrendingChannelsRequest, options?: RawAxiosRequestConfig): AxiosPromise<TrendingChannelResponse>;
/**
* Returns a list of all channels with their details that an FID is a member of. Data may have a delay of up to 1 hour.
* @summary Member of
* @param {ChannelApiFetchUserChannelMembershipsRequest} requestParameters Request parameters.
* @param {*} [options] Override http request option.
* @throws {RequiredError}
* @returns {Promise<ChannelMemberListResponse>} A promise that resolves to a `ChannelMemberListResponse` object
*
* For more information, refer to the [API documentation](https://docs.neynar.com/reference/fetch-user-channel-memberships)
*
*/
fetchUserChannelMemberships(requestParameters: ChannelApiFetchUserChannelMembershipsRequest, options?: RawAxiosRequestConfig): AxiosPromise<ChannelMemberListResponse>;
/**
* Returns a list of all channels with their details that a FID follows.
* @summary Following
* @param {ChannelApiFetchUserChannelsRequest} requestParameters Request parameters.
* @param {*} [options] Override http request option.
* @throws {RequiredError}
* @returns {Promise<ChannelListResponse>} A promise that resolves to a `ChannelListResponse` object
*
* For more information, refer to the [API documentation](https://docs.neynar.com/reference/fetch-user-channels)
*
*/
fetchUserChannels(requestParameters: ChannelApiFetchUserChannelsRequest, options?: RawAxiosRequestConfig): AxiosPromise<ChannelListResponse>;
/**
* Fetches all channels that a user has casted in, in reverse chronological order.
* @summary Fetch channels that user is active in
* @param {ChannelApiFetchUsersActiveChannelsRequest} requestParameters Request parameters.
* @param {*} [options] Override http request option.
* @throws {RequiredError}
* @returns {Promise<UsersActiveChannelsResponse>} A promise that resolves to a `UsersActiveChannelsResponse` object
*
* For more information, refer to the [API documentation](https://docs.neynar.com/reference/fetch-users-active-channels)
*
*/
fetchUsersActiveChannels(requestParameters: ChannelApiFetchUsersActiveChannelsRequest, options?: RawAxiosRequestConfig): AxiosPromise<UsersActiveChannelsResponse>;
/**
* Follow a channel
* @summary Follow a channel
* @param {ChannelApiFollowChannelRequest} requestParameters Request parameters.
* @param {*} [options] Override http request option.
* @throws {RequiredError}
* @returns {Promise<OperationResponse>} A promise that resolves to a `OperationResponse` object
*
* For more information, refer to the [API documentation](https://docs.neynar.com/reference/follow-channel)
*
*/
followChannel(requestParameters: ChannelApiFollowChannelRequest, options?: RawAxiosRequestConfig): AxiosPromise<OperationResponse>;
/**
* Invite a user to a channel
* @summary Invite
* @param {ChannelApiInviteChannelMemberRequest} requestParameters Request parameters.
* @param {*} [options] Override http request option.
* @throws {RequiredError}
* @returns {Promise<OperationResponse>} A promise that resolves to a `OperationResponse` object
*
* For more information, refer to the [API documentation](https://docs.neynar.com/reference/invite-channel-member)
*
*/
inviteChannelMember(requestParameters: ChannelApiInviteChannelMemberRequest, options?: RawAxiosRequestConfig): AxiosPromise<OperationResponse>;
/**
* Returns details of a channel
* @summary By ID or parent_url
* @param {ChannelApiLookupChannelRequest} requestParameters Request parameters.
* @param {*} [options] Override http request option.
* @throws {RequiredError}
* @returns {Promise<ChannelResponse>} A promise that resolves to a `ChannelResponse` object
*
* For more information, refer to the [API documentation](https://docs.neynar.com/reference/lookup-channel)
*
*/
lookupChannel(requestParameters: ChannelApiLookupChannelRequest, options?: RawAxiosRequestConfig): AxiosPromise<ChannelResponse>;
/**
* Remove a user from a channel or a user\'s invite to a channel role
* @summary Remove user
* @param {ChannelApiRemoveChannelMemberRequest} requestParameters Request parameters.
* @param {*} [options] Override http request option.
* @throws {RequiredError}
* @returns {Promise<OperationResponse>} A promise that resolves to a `OperationResponse` object
*
* For more information, refer to the [API documentation](https://docs.neynar.com/reference/remove-channel-member)
*
*/
removeChannelMember(requestParameters: ChannelApiRemoveChannelMemberRequest, options?: RawAxiosRequestConfig): AxiosPromise<OperationResponse>;
/**
* Accept or reject a channel invite
* @summary Accept or reject an invite
* @param {ChannelApiRespondChannelInviteRequest} requestParameters Request parameters.
* @param {*} [options] Override http request option.
* @throws {RequiredError}
* @returns {Promise<OperationResponse>} A promise that resolves to a `OperationResponse` object
*
* For more information, refer to the [API documentation](https://docs.neynar.com/reference/respond-channel-invite)
*
*/
respondChannelInvite(requestParameters: ChannelApiRespondChannelInviteRequest, options?: RawAxiosRequestConfig): AxiosPromise<OperationResponse>;
/**
* Returns a list of channels based on ID or name
* @summary Search by ID or name
* @param {ChannelApiSearchChannelsRequest} requestParameters Request parameters.
* @param {*} [options] Override http request option.
* @throws {RequiredError}
* @returns {Promise<ChannelSearchResponse>} A promise that resolves to a `ChannelSearchResponse` object
*
* For more information, refer to the [API documentation](https://docs.neynar.com/reference/search-channels)
*
*/
searchChannels(requestParameters: ChannelApiSearchChannelsRequest, options?: RawAxiosRequestConfig): AxiosPromise<ChannelSearchResponse>;
/**
* Unfollow a channel
* @summary Unfollow a channel
* @param {ChannelApiUnfollowChannelRequest} requestParameters Request parameters.
* @param {*} [options] Override http request option.
* @throws {RequiredError}
* @returns {Promise<OperationResponse>} A promise that resolves to a `OperationResponse` object
*
* For more information, refer to the [API documentation](https://docs.neynar.com/reference/unfollow-channel)
*
*/
unfollowChannel(requestParameters: ChannelApiUnfollowChannelRequest, options?: RawAxiosRequestConfig): AxiosPromise<OperationResponse>;
};
/**
* ChannelApi - interface
* @export
* @interface ChannelApi
*/
export interface ChannelApiInterface {
/**
* Returns a list of all channels with their details
* @summary Fetch all channels with their details
* @param {ChannelApiFetchAllChannelsRequest} requestParameters Request parameters.
* @param {*} [options] Override http request option.
* @throws {RequiredError}
* @memberof ChannelApiInterface
* @returns {Promise<ChannelListResponse>} A promise that resolves to a `ChannelListResponse` object
*
* For more information, refer to the [API documentation](https://docs.neynar.com/reference/fetch-all-channels)
*
*/
fetchAllChannels(requestParameters?: ChannelApiFetchAllChannelsRequest, options?: RawAxiosRequestConfig): AxiosPromise<ChannelListResponse>;
/**
* Returns details of multiple channels
* @summary Bulk fetch
* @param {ChannelApiFetchBulkChannelsRequest} requestParameters Request parameters.
* @param {*} [options] Override http request option.
* @throws {RequiredError}
* @memberof ChannelApiInterface
* @returns {Promise<ChannelResponseBulk>} A promise that resolves to a `ChannelResponseBulk` object
*
* For more information, refer to the [API documentation](https://docs.neynar.com/reference/fetch-bulk-channels)
*
*/
fetchBulkChannels(requestParameters: ChannelApiFetchBulkChannelsRequest, options?: RawAxiosRequestConfig): AxiosPromise<ChannelResponseBulk>;
/**
* Fetch a list of invites, either in a channel or for a user. If both are provided, open channel invite for that user is returned.
* @summary Open invites
* @param {ChannelApiFetchChannelInvitesRequest} requestParameters Request parameters.
* @param {*} [options] Override http request option.
* @throws {RequiredError}
* @memberof ChannelApiInterface
* @returns {Promise<ChannelMemberInviteListResponse>} A promise that resolves to a `ChannelMemberInviteListResponse` object
*
* For more information, refer to the [API documentation](https://docs.neynar.com/reference/fetch-channel-invites)
*
*/
fetchChannelInvites(requestParameters?: ChannelApiFetchChannelInvitesRequest, options?: RawAxiosRequestConfig): AxiosPromise<ChannelMemberInviteListResponse>;
/**
* Fetch a list of members in a channel
* @summary Fetch members
* @param {ChannelApiFetchChannelMembersRequest} requestParameters Request parameters.
* @param {*} [options] Override http request option.
* @throws {RequiredError}
* @memberof ChannelApiInterface
* @returns {Promise<ChannelMemberListResponse>} A promise that resolves to a `ChannelMemberListResponse` object
*
* For more information, refer to the [API documentation](https://docs.neynar.com/reference/fetch-channel-members)
*
*/
fetchChannelMembers(requestParameters: ChannelApiFetchChannelMembersRequest, options?: RawAxiosRequestConfig): AxiosPromise<ChannelMemberListResponse>;
/**
* Returns a list of followers for a specific channel. Max limit is 1000. Use cursor for pagination.
* @summary For channel
* @param {ChannelApiFetchFollowersForAChannelRequest} requestParameters Request parameters.
* @param {*} [options] Override http request option.
* @throws {RequiredError}
* @memberof ChannelApiInterface
* @returns {Promise<UsersResponse>} A promise that resolves to a `UsersResponse` object
*
* For more information, refer to the [API documentation](https://docs.neynar.com/reference/fetch-followers-for-a-channel)
*
*/
fetchFollowersForAChannel(requestParameters: ChannelApiFetchFollowersForAChannelRequest, options?: RawAxiosRequestConfig): AxiosPromise<UsersResponse>;
/**
* Returns a list of relevant channel followers for a specific FID. This usually shows on a channel as \"X, Y, Z follow this channel\".
* @summary Relevant followers
* @param {ChannelApiFetchRelevantFollowersForAChannelRequest} requestParameters Request parameters.
* @param {*} [options] Override http request option.
* @throws {RequiredError}
* @memberof ChannelApiInterface
* @returns {Promise<RelevantFollowersResponse>} A promise that resolves to a `RelevantFollowersResponse` object
*
* For more information, refer to the [API documentation](https://docs.neynar.com/reference/fetch-relevant-followers-for-a-channel)
*
*/
fetchRelevantFollowersForAChannel(requestParameters: ChannelApiFetchRelevantFollowersForAChannelRequest, options?: RawAxiosRequestConfig): AxiosPromise<RelevantFollowersResponse>;
/**
* Returns a list of trending channels based on activity
* @summary Channels by activity
* @param {ChannelApiFetchTrendingChannelsRequest} requestParameters Request parameters.
* @param {*} [options] Override http request option.
* @throws {RequiredError}
* @memberof ChannelApiInterface
* @returns {Promise<TrendingChannelResponse>} A promise that resolves to a `TrendingChannelResponse` object
*
* For more information, refer to the [API documentation](https://docs.neynar.com/reference/fetch-trending-channels)
*
*/
fetchTrendingChannels(requestParameters?: ChannelApiFetchTrendingChannelsRequest, options?: RawAxiosRequestConfig): AxiosPromise<TrendingChannelResponse>;
/**
* Returns a list of all channels with their details that an FID is a member of. Data may have a delay of up to 1 hour.
* @summary Member of
* @param {ChannelApiFetchUserChannelMembershipsRequest} requestParameters Request parameters.
* @param {*} [options] Override http request option.
* @throws {RequiredError}
* @memberof ChannelApiInterface
* @returns {Promise<ChannelMemberListResponse>} A promise that resolves to a `ChannelMemberListResponse` object
*
* For more information, refer to the [API documentation](https://docs.neynar.com/reference/fetch-user-channel-memberships)
*
*/
fetchUserChannelMemberships(requestParameters: ChannelApiFetchUserChannelMembershipsRequest, options?: RawAxiosRequestConfig): AxiosPromise<ChannelMemberListResponse>;
/**
* Returns a list of all channels with their details that a FID follows.
* @summary Following
* @param {ChannelApiFetchUserChannelsRequest} requestParameters Request parameters.
* @param {*} [options] Override http request option.
* @throws {RequiredError}
* @memberof ChannelApiInterface
* @returns {Promise<ChannelListResponse>} A promise that resolves to a `ChannelListResponse` object
*
* For more information, refer to the [API documentation](https://docs.neynar.com/reference/fetch-user-chan