mtn-momo-client
Version:
A collection of utils to interact with the mtn-momo api
19 lines (18 loc) • 798 B
TypeScript
import { AxiosInstance } from 'axios';
type CreateAPIKeyOptions = {
/** A uuid which corresponds to the id of the user whose api key is to be created */
userId: string;
/** The instance to use while making the api request */
client: AxiosInstance;
};
type CreateAPIKeyResult = {
/** The key to be used in the authentication header when requesting for an access token */
apiKey: string;
};
/**
* Create a key to use in the authentication header when requesting for an access token
* @param {CreateAPIKeyOptions} options properties needed to create an api key
* @returns {Promise<CreateAPIKeyResult>} An object containing the created apiKey
*/
declare const createAPIKey: ({ userId, client, }: CreateAPIKeyOptions) => Promise<CreateAPIKeyResult>;
export { createAPIKey };