Properties
Protected client
client: AxiosInstance
Private oAuthClient
oAuthClient: OAuth
Methods
get
get<T>( url: string , config?: AxiosRequestConfig ) : Promise < T >
Type parameters
Parameters
url: string
config: AxiosRequestConfig = ...
Returns Promise < T >
getAccessToken
getAccessToken( __namedParameters: {} ) : Promise < unknown >
Parameters
Returns Promise < unknown >
getRequestToken
getRequestToken( callbackUrl: string ) : Promise < string >
Parameters
Returns Promise < string >
getStream
getStream( url: string , config?: AxiosRequestConfig ) : Promise < StreamEventEmitter >
Parameters
url: string
config: AxiosRequestConfig = ...
Returns Promise < StreamEventEmitter >
post
post<T>( url: string , body: any , config?: AxiosRequestConfig ) : Promise < T >
Type parameters
Parameters
url: string
body: any
config: AxiosRequestConfig = ...
Returns Promise < T >
postForm
postForm<T>( url: string , body: any , config?: AxiosRequestConfig ) : Promise < T >
Type parameters
Parameters
url: string
body: any
config: AxiosRequestConfig = ...
Returns Promise < T >
postStream
postStream( url: string , body: any , config?: AxiosRequestConfig ) : Promise < StreamEventEmitter >
Parameters
url: string
body: any
config: AxiosRequestConfig = ...
Returns Promise < StreamEventEmitter >
put
put<T>( url: string , body: any , config?: AxiosRequestConfig ) : Promise < T >
Type parameters
Parameters
url: string
body: any
config: AxiosRequestConfig = ...
Returns Promise < T >
putForm
putForm<T>( url: string , body: any , config?: AxiosRequestConfig ) : Promise < T >
Type parameters
Parameters
url: string
body: any
config: AxiosRequestConfig = ...
Returns Promise < T >
setAccessToken
setAccessToken( accessToken: string ) : void
setAccessTokenSecret
setAccessTokenSecret( accessTokenSecret: string ) : void
Parameters
accessTokenSecret: string
Returns void
Legend
Constructor
Property
Method
Private property
Private method
The ApiClient used for making API requests to Twitter on behalf of a user. If an access token and access token secret are configured, this client will automatically signed each request using the OAuth1.0a protocol.