@mirad-work/sms-core
Version:
A framework-agnostic TypeScript SMS service core with provider abstraction for Iranian SMS providers
29 lines • 1.07 kB
TypeScript
import { BaseSmsDriver } from "./base-driver";
import { ISmsMessage, ISmsResponse } from "../interfaces/sms-driver.interface";
import { IMelipayamakConfig } from "../interfaces/sms-config.interface";
import { IHttpClient } from "../interfaces/http-client.interface";
/**
* Melipayamak SMS driver implementation
* Implements the Iranian Melipayamak SMS API
*/
export declare class MelipayamakDriver extends BaseSmsDriver {
private readonly melipayamakConfig;
constructor(config: IMelipayamakConfig, httpClient: IHttpClient);
/**
* Override buildUrl to append API key at the end of the URL
*/
protected buildUrl(endpoint: string): string;
/**
* Send a template-based SMS message (OTP/verification)
*/
verify(message: ISmsMessage): Promise<ISmsResponse>;
/**
* Build payload for verify/OTP requests
*/
private buildVerifyPayload;
/**
* Process Melipayamak API response and convert to standard format
*/
private processMelipayamakResponse;
}
//# sourceMappingURL=melipayamak-driver.d.ts.map