UNPKG

fivesim-api

Version:

Node.js wrapper for the 5sim.net API - SMS verification service with TypeScript support

52 lines (51 loc) 1.35 kB
export declare enum OrderStatus { PENDING = "PENDING",// Preparation RECEIVED = "RECEIVED",// Waiting of receipt of SMS CANCELED = "CANCELED",// Is cancelled TIMEOUT = "TIMEOUT",// A timeout FINISHED = "FINISHED",// Is complete BANNED = "BANNED" } export interface PaginationOptions { limit?: number; offset?: number; order?: string; reverse?: boolean; } export interface OrderHistoryOptions extends PaginationOptions { category?: "hosting" | "activation"; } export interface BuyNumberOptions { forwarding?: boolean; number?: string; reuse?: "0" | "1"; voice?: "0" | "1"; ref?: string; maxPrice?: number; wait?: boolean; } export interface SetPriceLimitParams { product_name: string; price: number; } export interface DeletePriceLimitParams { product_name: string; } export type Language = "en" | "ru"; export type PayoutMethod = "visa" | "qiwi" | "yandex"; export type FeeSystem = "fkwallet" | "payeer" | "unitpay"; export type Country = string | "any"; export type Operator = string | "any" | "best"; export interface WebhookEvent { type: string; order_id: number; status: OrderStatus; created_at: string; [key: string]: any; } export interface APIErrorResponse { status: number; message: string; code?: string; details?: any; }