@standard-crypto/farcaster-js-neynar
Version:
A tool for interacting with Farcaster via Neynar APIs.
294 lines (293 loc) • 12.6 kB
TypeScript
/**
* v1 Farcaster
* No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
*
* The version of the OpenAPI document: 1.0
*
*
* 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.js';
import type { AxiosPromise, AxiosInstance, AxiosRequestConfig } from 'axios';
import globalAxios from 'axios';
import { RequestArgs, BaseAPI } from '../base.js';
import { AllCastsInThreadResponse } from '../models';
import { CastResponse } from '../models';
import { CastsResponse } from '../models';
import { RecentCastsResponse } from '../models';
/**
* CastApi - axios parameter creator
* @export
*/
export declare const CastApiAxiosParamCreator: (configuration?: Configuration) => {
/**
* Gets the most recent casts for a user in reverse-chronological order
* @summary Retrieve all casts in a given thread hash
* @param {string} threadHash The hash of the thread to retrieve casts from.
* @param {number} [viewerFid] fid of the user viewing this information, needed for contextual information.
* @param {*} [options] Override http request option.
* @throws {RequiredError}
*/
allCastsInThread: (threadHash: string, viewerFid?: number, options?: AxiosRequestConfig) => Promise<RequestArgs>;
/**
* Gets information about an individual cast
* @summary Retrieve cast for a given hash
* @param {string} hash Cast hash
* @param {number} [viewerFid] fid of the user viewing this information, needed for contextual information.
* @param {*} [options] Override http request option.
* @throws {RequiredError}
*/
cast: (hash: string, viewerFid?: number, options?: AxiosRequestConfig) => Promise<RequestArgs>;
/**
* Gets the most recent casts for a user
* @summary Retrieve casts for a given user
* @param {number} fid fid of a user
* @param {number} [viewerFid] fid of the user viewing this information, needed for contextual information.
* @param {string} [parentUrl] A cast can be part of a certain channel. The channel is identified by `parent_url`. All casts in the channel ladder up to the same parent_url.
* @param {string} [cursor] Pagination cursor.
* @param {number} [limit] Number of results to retrieve (default 25, max 150)
* @param {*} [options] Override http request option.
* @throws {RequiredError}
*/
casts: (fid: number, viewerFid?: number, parentUrl?: string, cursor?: string, limit?: number, options?: AxiosRequestConfig) => Promise<RequestArgs>;
/**
* Get a list of casts from the protocol in reverse chronological order based on timestamp
* @summary Get Recent Casts
* @param {number} [viewerFid] fid of the user viewing this information, needed for contextual information.
* @param {string} [cursor] Pagination cursor.
* @param {number} [limit] Number of results to retrieve (default 25, max 100)
* @param {*} [options] Override http request option.
* @throws {RequiredError}
*/
recentCasts: (viewerFid?: number, cursor?: string, limit?: number, options?: AxiosRequestConfig) => Promise<RequestArgs>;
};
/**
* CastApi - functional programming interface
* @export
*/
export declare const CastApiFp: (configuration?: Configuration) => {
/**
* Gets the most recent casts for a user in reverse-chronological order
* @summary Retrieve all casts in a given thread hash
* @param {string} threadHash The hash of the thread to retrieve casts from.
* @param {number} [viewerFid] fid of the user viewing this information, needed for contextual information.
* @param {*} [options] Override http request option.
* @throws {RequiredError}
*/
allCastsInThread(threadHash: string, viewerFid?: number, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<AllCastsInThreadResponse>>;
/**
* Gets information about an individual cast
* @summary Retrieve cast for a given hash
* @param {string} hash Cast hash
* @param {number} [viewerFid] fid of the user viewing this information, needed for contextual information.
* @param {*} [options] Override http request option.
* @throws {RequiredError}
*/
cast(hash: string, viewerFid?: number, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<CastResponse>>;
/**
* Gets the most recent casts for a user
* @summary Retrieve casts for a given user
* @param {number} fid fid of a user
* @param {number} [viewerFid] fid of the user viewing this information, needed for contextual information.
* @param {string} [parentUrl] A cast can be part of a certain channel. The channel is identified by `parent_url`. All casts in the channel ladder up to the same parent_url.
* @param {string} [cursor] Pagination cursor.
* @param {number} [limit] Number of results to retrieve (default 25, max 150)
* @param {*} [options] Override http request option.
* @throws {RequiredError}
*/
casts(fid: number, viewerFid?: number, parentUrl?: string, cursor?: string, limit?: number, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<CastsResponse>>;
/**
* Get a list of casts from the protocol in reverse chronological order based on timestamp
* @summary Get Recent Casts
* @param {number} [viewerFid] fid of the user viewing this information, needed for contextual information.
* @param {string} [cursor] Pagination cursor.
* @param {number} [limit] Number of results to retrieve (default 25, max 100)
* @param {*} [options] Override http request option.
* @throws {RequiredError}
*/
recentCasts(viewerFid?: number, cursor?: string, limit?: number, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<RecentCastsResponse>>;
};
/**
* CastApi - factory interface
* @export
*/
export declare const CastApiFactory: (configuration?: Configuration, basePath?: string, axios?: AxiosInstance) => {
/**
* Gets the most recent casts for a user in reverse-chronological order
* @summary Retrieve all casts in a given thread hash
* @param {CastApiAllCastsInThreadRequest} requestParameters Request parameters.
* @param {*} [options] Override http request option.
* @throws {RequiredError}
*/
allCastsInThread(requestParameters: CastApiAllCastsInThreadRequest, options?: AxiosRequestConfig): AxiosPromise<AllCastsInThreadResponse>;
/**
* Gets information about an individual cast
* @summary Retrieve cast for a given hash
* @param {CastApiCastRequest} requestParameters Request parameters.
* @param {*} [options] Override http request option.
* @throws {RequiredError}
*/
cast(requestParameters: CastApiCastRequest, options?: AxiosRequestConfig): AxiosPromise<CastResponse>;
/**
* Gets the most recent casts for a user
* @summary Retrieve casts for a given user
* @param {CastApiCastsRequest} requestParameters Request parameters.
* @param {*} [options] Override http request option.
* @throws {RequiredError}
*/
casts(requestParameters: CastApiCastsRequest, options?: AxiosRequestConfig): AxiosPromise<CastsResponse>;
/**
* Get a list of casts from the protocol in reverse chronological order based on timestamp
* @summary Get Recent Casts
* @param {CastApiRecentCastsRequest} requestParameters Request parameters.
* @param {*} [options] Override http request option.
* @throws {RequiredError}
*/
recentCasts(requestParameters?: CastApiRecentCastsRequest, options?: AxiosRequestConfig): AxiosPromise<RecentCastsResponse>;
};
/**
* Request parameters for allCastsInThread operation in CastApi.
* @export
* @interface CastApiAllCastsInThreadRequest
*/
export interface CastApiAllCastsInThreadRequest {
/**
* The hash of the thread to retrieve casts from.
* @type {string}
* @memberof CastApiAllCastsInThread
*/
readonly threadHash: string;
/**
* fid of the user viewing this information, needed for contextual information.
* @type {number}
* @memberof CastApiAllCastsInThread
*/
readonly viewerFid?: number;
}
/**
* Request parameters for cast operation in CastApi.
* @export
* @interface CastApiCastRequest
*/
export interface CastApiCastRequest {
/**
* Cast hash
* @type {string}
* @memberof CastApiCast
*/
readonly hash: string;
/**
* fid of the user viewing this information, needed for contextual information.
* @type {number}
* @memberof CastApiCast
*/
readonly viewerFid?: number;
}
/**
* Request parameters for casts operation in CastApi.
* @export
* @interface CastApiCastsRequest
*/
export interface CastApiCastsRequest {
/**
* fid of a user
* @type {number}
* @memberof CastApiCasts
*/
readonly fid: number;
/**
* fid of the user viewing this information, needed for contextual information.
* @type {number}
* @memberof CastApiCasts
*/
readonly viewerFid?: number;
/**
* A cast can be part of a certain channel. The channel is identified by `parent_url`. All casts in the channel ladder up to the same parent_url.
* @type {string}
* @memberof CastApiCasts
*/
readonly parentUrl?: string;
/**
* Pagination cursor.
* @type {string}
* @memberof CastApiCasts
*/
readonly cursor?: string;
/**
* Number of results to retrieve (default 25, max 150)
* @type {number}
* @memberof CastApiCasts
*/
readonly limit?: number;
}
/**
* Request parameters for recentCasts operation in CastApi.
* @export
* @interface CastApiRecentCastsRequest
*/
export interface CastApiRecentCastsRequest {
/**
* fid of the user viewing this information, needed for contextual information.
* @type {number}
* @memberof CastApiRecentCasts
*/
readonly viewerFid?: number;
/**
* Pagination cursor.
* @type {string}
* @memberof CastApiRecentCasts
*/
readonly cursor?: string;
/**
* Number of results to retrieve (default 25, max 100)
* @type {number}
* @memberof CastApiRecentCasts
*/
readonly limit?: number;
}
/**
* CastApi - object-oriented interface
* @export
* @class CastApi
* @extends {BaseAPI}
*/
export declare class CastApi extends BaseAPI {
/**
* Gets the most recent casts for a user in reverse-chronological order
* @summary Retrieve all casts in a given thread hash
* @param {CastApiAllCastsInThreadRequest} requestParameters Request parameters.
* @param {*} [options] Override http request option.
* @throws {RequiredError}
* @memberof CastApi
*/
allCastsInThread(requestParameters: CastApiAllCastsInThreadRequest, options?: AxiosRequestConfig): Promise<globalAxios.AxiosResponse<AllCastsInThreadResponse, any>>;
/**
* Gets information about an individual cast
* @summary Retrieve cast for a given hash
* @param {CastApiCastRequest} requestParameters Request parameters.
* @param {*} [options] Override http request option.
* @throws {RequiredError}
* @memberof CastApi
*/
cast(requestParameters: CastApiCastRequest, options?: AxiosRequestConfig): Promise<globalAxios.AxiosResponse<CastResponse, any>>;
/**
* Gets the most recent casts for a user
* @summary Retrieve casts for a given user
* @param {CastApiCastsRequest} requestParameters Request parameters.
* @param {*} [options] Override http request option.
* @throws {RequiredError}
* @memberof CastApi
*/
casts(requestParameters: CastApiCastsRequest, options?: AxiosRequestConfig): Promise<globalAxios.AxiosResponse<CastsResponse, any>>;
/**
* Get a list of casts from the protocol in reverse chronological order based on timestamp
* @summary Get Recent Casts
* @param {CastApiRecentCastsRequest} requestParameters Request parameters.
* @param {*} [options] Override http request option.
* @throws {RequiredError}
* @memberof CastApi
*/
recentCasts(requestParameters?: CastApiRecentCastsRequest, options?: AxiosRequestConfig): Promise<globalAxios.AxiosResponse<RecentCastsResponse, any>>;
}