SMS-Activateを利用するためのAPIプロトコル
APIは、あなたのソフトウェアと当社のサーバー間の通信プロトコルです。
APIは、SMS、OTP、PVAの受信プロセスを自動化するために必要です。
当社のAPIは競合他社のサイトと完全な互換性があります。
すべてのリクエストは https://api.sms-activate.ai/stubs/handler_api.php へ送信してください。
POSTまたはGETリクエスト。
すべてのリクエストには、api_key GETパラメータとしてAPIキーを含める必要があります。
PHPでのプロトコル実装をダウンロード Pythonでのプロトコル実装サンプルをダウンロード認証API
パラメータ:
$api_key - APIキー
$country * - 国番号 表を参照
$operator * モバイル事業者番号。カンマ区切りで複数指定可能(対応国:
** 利用可能: $country = 0, $country = 1, $country = 2
回答:
サービスのレスポンスはJSON形式で返されます。例:
{"vk_0":76,"ok_0":139,"wa_0":90,"vi_0":223,"tg_0":158,"wb_0":106,"go_0":182,"av_0":244,"av_1":211,"fb_0":107}
ダッシュの前はサービス名、後は転送の要否を示します。0=不要、1=必要。
パラメータ:
$api_key - APIキー
$service * - サービス 表を参照
* オプションパラメータ。指定しない場合、デフォルトですべてのサービスにおける上位国が表示されます。
$freePrice * - オプションパラメータ。指定した場合 true、数量と価格はFree Priceに基づいて提供されます
回答:
サービスのレスポンスはJSON形式で返されます。例:
{
0: {
"country: 0,
"count": 43575,
"price": 15.00,
"retail_price": 30.00
}, ...
}
$freePrice = true:
{
0: {
"country: 0,
"count": 43575,
"price": 15.00,
"retail_price": 30.00,
"freePriceMap": {
"15.00": 43242,
"18.00": 333
}
}, ...
}
キャッシュバックアカウントを含む残高リクエスト:
* キャッシュバックアカウント設定の「アクティベーションにキャッシュバックを使用」チェックボックスがオンになっている場合、蓄積されたキャッシュバックを考慮した残高を返します
パラメータ:
$api_key - APIキー
回答:
ACCESS_BALANCE: 「アカウント残高」
考えられるエラー:
BAD_KEY - 無効なAPIキー
ERROR_SQL - SQLサーバーエラー
* 指定された国で利用可能なすべてのキャリアを返します。国が指定されていない場合は、各国で利用可能なすべてのキャリアを返します
パラメータ:
$api_key - APIキー
$country - 国コード
回答:
サービスのレスポンスはJSON形式で返されます:
{"status":"success", "countryOperators": {
"Country1Code": ["operator1Name","operator2Name","operator3Name", ...],
"Country2Code": ["operator1Name","operator2Name","operator3Name", ...],
...
}}
例:
{"status":"success", "countryOperators": {
"0": ["beeline","megafon","mts", ...],
"1": ["life","mts","kyivstar","utel" ...],
...
}}
* 「countryOperators」内では、キーは国コードになります
考えられるエラー:
BAD_KEY - 無効なAPIキー
ERROR_SQL - SQLサーバーエラー
OPERATORS_NOT_FOUND - レコードが見つかりません(例:存在しない国が指定された場合)
パラメータ:
$api_key - APIキー
回答:
サービスのレスポンスはJSON形式で返されます:
{"status":"success", "activeActivations": [
{
"activationId" : "635468021",
"serviceCode" : "vk",
"phoneNumber" : "79********1",
"activationCost" : "12.50",
"activationStatus" : "4",
"smsCode" : ["CODE"],
"smsText" : "[Your CODE registration code]",
"activationTime" : "2022-06-01 16:59:16",
"discount" : "0.00",
"repeated" : "0",
"countryCode" : "0",
"countryName" : "Russia",
"canGetAnotherSms" : "1",
}]
考えられるエラー:
BAD_KEY - 無効なAPIキー
ERROR_SQL - SQLサーバーエラー
NO_ACTIVATIONS - エントリが見つかりません(アクティブなアクティベーションなし)
パラメータ:
$api_key - APIキー
$service - 注文用サービス 表を参照
$forward * - 転送付き番号のリクエストが必要かどうか
* オプションパラメータ。0(実行しない、デフォルト)または1(実行する)を受け付けます
$maxPrice * - Free Priceで番号を購入する際の最大許容価格
* オプションパラメータ。指定しない場合、通常価格で購入されます
$phoneException * - ロシア番号の除外プレフィックス。カンマ区切りで入力してください。記録形式:国コードとマスクの3〜6桁(例:7918、7900111)。デフォルト値はアカウントで指定された値です。
$operator* は電話番号のモバイル通信事業者です。カンマで区切って複数指定できます(** の場合にのみ利用可能)
$activationType - アクティベーションタイプ:0 - SMS付き(デフォルト)、1 - 番号付き、2 - 音声通話付き
$language - 解析言語(音声通話によるアクティベーションに必要) 表を参照
$userId * - アクティベーション統計が悪いため禁止するユーザーIDですが、リセラー自身のアカウントには影響しません。
* オプションフィールド
** 利用可能: $country = 0, $country = 1, $country = 2
$ref - 紹介IDを転送します。
$country - 国番号 表を参照
$useCashBack* - ブール値を受け取ります。パラメータが 'true' の場合、キャッシュバック残高を使用して番号を購入します。キャッシュバック残高が尽きた後は、メイン残高を使用して購入が行われます。重要な点として、その後のすべての購入はまずキャッシュバックから使用され、その後メイン残高が使用されることです(その後パラメータ 'false' を渡した場合でも同様です)。
* オプションパラメータ、'true' を受け付けます
考えられるエラー:
WRONG_MAX_PRICE:$min- 指定された最大価格が許可された価格よりも低い
$min - 最小許容価格
BAD_ACTION - 不正なアクション
BAD_SERVICE - 不正なサービス名
BAD_KEY - 無効なAPIキー
ERROR_SQL - SQLサーバーエラー
BANNED:'YYYY-m-d H-i-s' - アカウントがブロックされている時間
WRONG_EXCEPTION_PHONE - 不正な除外プレフィックス
NO_BALANCE_FORWARD - 着信転送を購入するための資金が不足しています
CHANNELS_LIMIT - アカウントがブロックされました
NO_NUMBERS - 番号がありません
選択した国で運営していない特定の通信事業者の番号、または選択したサービスを提供していない事業者の番号を取得しようとすると、リクエストパラメータに一致する最初の事業者の番号が返されます
このメソッドは以下のメソッドと同様に動作します getNumber, 同じパラメータと下記で説明される追加パラメータを受け付けますが、追加のアクティベーション情報を返します
パラメータ:
$orderId- リセラーシステムからのアクティベーションID。購入時、このデータは当社のシステム内のアクティベーションIDおよびリセラーと比較されます。これにより、冪等性(同じ注文が再度処理されないこと)を実現します。
回答:
リクエストが成功した場合、レスポンスは以下の形式になります:
{
"activationId": 635468024,
"phoneNumber": "79584******",
"activationCost": "12.50",
"countryCode": "0",
"canGetAnotherSms": "1",
"activationTime": "2022-06-01 17:30:57",
"activationOperator": "mtt"
}
選択した国で運営していない特定の通信事業者の番号、または選択したサービスを提供していない事業者の番号を取得しようとすると、リクエストパラメータに一致する最初の事業者の番号が返されます
考えられるエラー:
ORDER_ALREADY_EXISTS- 注文はすでに作成されています
番号にSMSを受信した際、設定でWebhooks機能を有効にしている場合、指定したアドレスに対してPOSTリクエストでSMS情報を送信します
回答:
レスポンス形式は以下の通りです:
{
"activationId": 635468024,
"service": "go",
"text": "Your sms text",
"code": "Your sms code",
"country": 0,
"receivedAt": "2022-06-01 17:30:57",
}
リクエスト送信時、スクリプトからのHTTPステータス200のレスポンスを待ちます。スクリプトから応答がない場合、2時間以内に最大8回までリクエストを再送します。
この機能は以下で有効にできます プロフィール設定
パラメータ:
$api_key - APIキー
$service - 注文用サービス 表を参照
$forward * - 転送付き番号のリクエストが必要かどうか
* オプションパラメータ。転送文字はカンマで区切り、転送桁数はパラメータで送信されたサービス数と一致する必要があります $service. リダイレクト付きでは1つのサービスのみ送信可能です。例:「0,1,0,0」は正しく、「0,1,1,0」は不正です。値は0(実行しない、デフォルト)または1(実行)を取ります
$operator * - 番号のモバイルオペレーター。カンマで区切って複数の番号を指定できます(**の場合のみ利用可能):
$ref - 紹介IDを転送します。
$country - 国番号 表を参照
回答:
NO_NUMBERS - 番号がありません
NO_BALANCE - 残高が不足しています
{{'phone':phone,'activation':activation,'service':service},
{'phone':phone,'activation':activation,'service':service}}, ここで(phone - 操作ID、activation - 電話番号、service - サービス)
考えられるエラー:
BAD_ACTION - 不正なアクション
BAD_SERVICE - 不正なサービス名
BAD_KEY - 無効なAPIキー
ERROR_SQL - SQLサーバーエラー
BANNED:'YYYY-m-d H-i-s' - アカウントがブロックされている時間
パラメータ:
$api_key - APIキー
$id - アクティベーションID
$forward * - 転送先の電話番号
* getNumberでforward=1パラメータが渡された場合のみ必須です。
$status - アクティベーションステータス
1 - 番号の利用可能通知(番号にSMS送信済み)
3 - もう1つのコードをリクエスト(無料)
6 - アクティベーションを終了 *
8 - 番号がすでに使用されていることを報告し、アクティベーションをキャンセル
* 「コード受信済み」ステータスの場合は成功としてマークし完了、「準備中」の場合は削除してエラーとしてマーク、「再試行待ち」ステータスの場合はアクティベーションをSMS保留状態に移行
** 番号がすでに到着している場合、通話による認証方法が選択されたアクティベーションのステータスは変更できません
API連携の基本的な時系列ロジック:
getNumberメソッドで番号を取得後、以下のアクションが可能です:
8 - アクティベーションをキャンセル(番号が不適切な場合)
1 - SMS送信済みであることを通知(オプション)
ステータス1のアクティベーションの場合:
8 - アクティベーションをキャンセル
コード受信直後:
3 - もう1つのSMSをリクエスト
6 - SMSコードを確認し、アクティベーションを終了
ステータス3のアクティベーションの場合:
6 - SMSコードを確認し、アクティベーションを終了
回答:
ACCESS_READY - 番号の準備完了を確認
ACCESS_RETRY_GET - 新しいSMSを待機中
ACCESS_ACTIVATION - サービスが正常にアクティベートされました
ACCESS_CANCEL - アクティベーションがキャンセルされました
考えられるエラー:
EARLY_CANCEL_DENIED - 最初の2分間は番号のキャンセルは許可されていません
ERROR_SQL - SQLサーバーエラー
NO_ACTIVATION - アクティベーションIDが存在しません
BAD_SERVICE - 不正なサービス名
BAD_STATUS - 不正なステータス
BAD_KEY - 無効なAPIキー
BAD_ACTION - 不正なアクション
WRONG_ACTIVATION_ID - 無効なID、またはIDが数値ではありません。
パラメータ:
$api_key - APIキー
$id - アクティベーションID
回答:
STATUS_WAIT_CODE - SMSを待機中
STATUS_WAIT_RETRY: '過去、一致しないコード' - コードの確認を待機中
STATUS_WAIT_RESEND - SMSの再送信を待機中 *
* ソフトウェアはSMSの再送信を実行し、ステータスを6に変更する必要があります
STATUS_CANCEL - アクティベーションがキャンセルされました
STATUS_OK: 'activation code' - 受信したコード
考えられるエラー:
NO_ACTIVATION - アクティベーションIDが存在しません
ERROR_SQL - SQLサーバーエラー
BAD_KEY - 無効なAPIキー
BAD_ACTION - 不正なアクション
パラメータ:
$api_key - APIキー
$id - アクティベーションID
回答:
レスポンス形式は以下の通りです:
{
"verificationType": 2,
"sms": {
"dateTime": "0000-00-00 00:00:00",
"code": "code",
"text": "sms text",
},
"call": {
"from": "phone",
"text": "voice text",
"dateTime": "0000-00-00 00:00:00",
"url": "voice file url",
"parsingCount": 1,
}
}
STATUS_CANCEL - アクティベーションがキャンセルされました
考えられるエラー:
NO_ACTIVATION - アクティベーションIDが存在しません
ERROR_SQL - SQLサーバーエラー
BAD_KEY - 無効なAPIキー
BAD_ACTION - 不正なアクション
パラメータ:
$api_key - APIキー
$start - Unixタイムスタンプ形式のタイムスタンプ(オプション)- アクティベーションを開始する日付
$end - Unixタイムスタンプ形式のタイムスタンプ(オプション)- アクティベーションを終了する日付
$offset - レスポンスで返される最初の要素のオフセット。デフォルトは0
$limit - 返されるレコードの最大数。最大は100。デフォルトは50。
回答:
レスポンス形式は以下の通りです:
[{
"id": 635468024,
"date": "2022-11-12 15:58:39",
"phone": "79918529716",
"sms": "sms":"["Your sms code"]",
"cost": 100 //Если активация не завершена, то cost = 0,
"status": "4",
}]
考えられるエラー:
ERROR_SQL - SQLサーバーエラー
BAD_KEY - 無効なAPIキー
BAD_ACTION - 不正なアクション
パラメータ:
$api_key - APIキー
$service - サービス名
回答:
レスポンス形式は以下の通りです:
[{
"country": 0,
"share": 50 - // (Purchases of the chosen service by country as a percentage of the total quantity of purchases at our service),
"rate": 50 - // (% of successful activations among the total number of activations by the country)
}]
考えられるエラー:
ERROR_SQL - SQLサーバーエラー
BAD_KEY - 無効なAPIキー
WRONG_SERVICE - 不正なサービス
BAD_ACTION - 不正なアクション
パラメータ:
$api_key - APIキー
$id - アクティベーションID
回答:
サービスのレスポンスはJSON形式で返されます。例:
{"status":"2","phone":false}
可能なステータス:
2 - 新規アクティベーション
3 - 正常に完了
4 - キャンセル済み
5 - 返金済み
考えられるエラー:
BAD_KEY - 無効なAPIキー
INVALID_ACTIVATION_ID - 無効なアクティベーションID
回答:
JSON - 以下の形式のオブジェクト
{"Service":{"Country":{"count":Quantity,"price":"Price"}}}
パラメータ:
$api_key - APIキー
回答:
JSON - 以下の形式のオブジェクト {{'Страна':{'id':0,'rus':"Россия","eng:"Russia","chn":"俄罗斯","visible":1,"retry":1,"rent":1,"multiService":1}},
ここで(
id : 国ID;
rus : ロシア語での国名;
eng : 英語での国名;
chn : 中国語での国名;
visible : 0 - サイト上で国が表示されない、1 - 表示される;
retry : 0 - SMSの再送信は利用不可、1 - 利用可能;
rent : 0 - 国のレンタル不可、1 - レンタル可能;
multiService : 0 - マルチサービス利用不可、1 - 利用可能。)
パラメータ:
$api_key- APIキー
$country *- 国ID。国を指定した場合、選択した国に対して価格が設定されているサービスを返します
$lang *- `name`を提供するために使用する言語。可能な値:'ru'、'en'、'es'、'cn'。デフォルトは'en'
* オプションパラメータ
回答:
JSON - 以下の形式のオブジェクト { "status": "success", "services": [ { "code": "aoo", "name": "ペガサス航空" } ] }
転送番号で最初のSMSを受信した後、Yula、Yandex、Avitoなどの関連サービスを追加で購入できます
追加サービスの料金はわずか5pです
回答:
ADDITIONAL:$id:$phone - 新しいアクティベーションが正常に作成されました。IDは追加アクティベーションのID、phoneは電話番号です
考えられるエラー:
WRONG_ADDITIONAL_SERVICE - 無効な追加サービス(転送用サービスのみ許可されています)
WRONG_ACTIVATION_ID - 不正な親アクティベーションID
WRONG_SECURITY - リダイレクトなしのアクティベーションIDを送信しようとした際、または完了済み/非アクティブなアクティベーションでエラーが発生しました
REPEAT_ADDITIONAL_SERVICE - 購入済みのサービスを再度注文しようとするとエラーが発生します NO_BALANCE - 残高不足
ERROR_SQL- データベースエラー、カスタマーサポートにお問い合わせください
番号で正常にアクティベーションを行った場合、再度実行できます。
追加アクティベーションの費用は国とサービスによって異なります。具体的な費用は以下から取得できます。
パラメータ:
$api_key - APIキー
$activationId - 親アクティベーションID
回答:
ACCESS_NUMBER:$id:$phone - 新しいアクティベーションが正常に作成されました。$idは追加アクティベーションのID、$phoneは電話番号です
考えられるエラー:
RENEW_ACTIVATION_NOT_AVAILABLE- この番号は追加アクティベーションに対応していません
WRONG_ACTIVATION_ID - 不正な親アクティベーションID
ERROR_SQL- データベースエラー、カスタマーサポートにお問い合わせください
NEW_ACTIVATION_IMPOSSIBLE- 追加アクティベーションを実行できません
NO_BALANCE - アカウントに残高がありません
番号が追加アクティベーションに対応しているか確認し、その費用を取得できます
パラメータ:
$api_key - APIキー
$activationId - 親アクティベーションID
回答:
JSON - 以下の形式のオブジェクト {'status': 'success', 'cost':200,"service":"tw","phone":777777777,"country":14},
考えられるエラー:
RENEW_ACTIVATION_NOT_AVAILABLE- この番号は追加アクティベーションに対応していません
WRONG_ACTIVATION_ID - 不正な親アクティベーションID
SIM_OFFLINE - SIMカードがオフラインです
回答:
レスポンス形式は以下の通りです:
{
"result": "OK"
}
STATUS_CANCEL - アクティベーションがキャンセルされました
NO_CALL- 通話を受信していません
PARSE_COUNT_EXCEED- パース試行回数の制限(最大4回)
考えられるエラー:
WRONG_ACTIVATION_ID - 無効なIDです。アクティベーションが存在しません
ERROR_SQL - SQLサーバーエラー
BAD_KEY - 無効なAPIキー
BAD_ACTION - 不正なアクション
レンタルAPI
パラメータ:
$api_key - APIキー
$time* - レンタル時間(デフォルト:4時間)
$operator* - 番号のモバイルキャリア。カンマで区切って複数指定できます(デフォルト:Any)
$country* - 国(デフォルト:ロシア)
$incomingCall * - 転送された場合 "true"通話受信機能をサポートする番号を取得する
回答:
サービスのレスポンスはJSON形式で返されます。例:
{ "countries": { "0": 0 }, "operators": { "0": "aiva", "1": "any", "2": "beeline", ... "16": "yota" }, "services": { "full": { "cost": 42.93, "quant": 20 }, "vk": { "cost": 21.95, "quant": 20 }, "ok": { "cost": 7.68, "quant": 55 }, "ot": { "cost": 5.2, "quant": 42 } } }
考えられるエラー:
BAD_KEY - 無効なAPIキー
OUT_OF_STOCK - その国の番号は利用できません
パラメータ:
$api_key - APIキー
$service - 番号を取得したいサービス
$time* - レンタル時間(時間単位、デフォルト:4時間)。次の利用可能な期間は12時間、その後24時間です。1日以上レンタルをリクエストする場合は、24、48、72などを指定してください。
$operator* - 番号のモバイルキャリア。カンマで区切って複数指定できます(デフォルト:Any)
$country* - 国(デフォルト:ロシア)
$url * - Webhook用リンク(デフォルトでは考慮されません)
$incomingCall * - 転送された場合 "true"通話受信機能をサポートする番号を取得する
* オプションパラメータ。指定しない場合、デフォルトのパラメータが使用されます。
回答:
サービスのレスポンスはJSON形式で返されます。例:
{ "status": "success", "phone": { "id": 1049, "endDate": "2020-01-31T12:01:52", "number": "79959707564" } }
考えられるエラー:
BAD_KEY - 無効なAPIキー
JSON形式での回答:
{ "status": "error", "message": "*possible_answer*" }
フィールド内の可能な回答 "message":
BAD_SERVICE - サービスが指定されていないか、名前が正しくありません
NO_BALANCE - アカウントに残高がありません
NO_NUMBERS - 番号がありません
ACCOUNT_INACTIVE - 番号がありません
SERVER_ERROR - サーバーエラー
CHANNELS_LIMIT - アカウントがブロックされました
パラメータ:
$api_key - APIキー
$id - 番号注文時の返信で受け取ったレンタルID
$page* - 選択を開始するページ番号(ページ番号は0から始まり、新しい順から古い順へ;デフォルトは0)
$size* - ページサイズ(デフォルト10)
* オプションパラメータ。指定しない場合、デフォルトのパラメータが使用されます。
回答:
サービスのレスポンスはJSON形式で返されます。例:
{ "status": "success", "quantity": "2", "values": { "0": { "phoneFrom": "79180230628", "text": "5", "service": "ot", "date": "2020-01-30 14:31:58" }, "1": { "phoneFrom": "79180230628", "text": "4", "service": "ot", "date": "2020-01-30 14:04:16" } } }
* SMSがある場合のみ成功します('quantity'ボックス > 0)。
考えられるエラー:
BAD_KEY - 無効なAPIキー
JSON形式での回答:
{ "status": "error", "message": "*possible_answer*" } フィールド内の可能な回答 "message": NO_ID_RENT - レンタルIDが指定されていません INVALID_PHONE - 番号はあなたによってレンタルされていません(無効なレンタルID) STATUS_FINISH - レンタル料金が支払われ、完了しました STATUS_CANCEL - レンタルがキャンセルされ、返金されました STATUS_WAIT_CODE - 最初のSMSを待機中 STATUS_REVOKE - 番号がブロックされ、資金は返金されました
パラメータ:
$api_key - APIキー
$id - 番号注文時の返信で受け取ったレンタルID
$status - ステータス変更用コード(番号)
ステータスは以下の通りです:
回答:
サービスのレスポンスはJSON形式で返されます:
{ "status": "success" }
考えられるエラー:
BAD_KEY - 無効なAPIキー
JSON形式での回答:
{ "status": "error", "message": "*possible_answer*" }
フィールド内の可能な回答 "message":
NO_ID_RENT - レンタルIDが指定されていません
INCORECT_STATUS - ステータスが指定されていないか、誤って指定されています
CANT_CANCEL - レンタルをキャンセルできません(20分以上経過)
INVALID_PHONE - 番号はあなたによってレンタルされていません(無効なレンタルID)
ALREADY_FINISH - レンタルはすでに完了しています
ALREADY_CANCEL - レンタルはすでにキャンセルされています
SERVER_ERROR - サーバーエラー
👉注意!このメソッドは最新の10件の番号のみを表示します。さらに多くの番号が必要な場合は、 getRentStatus メソッドを使用してステータスを確認してください。
パラメータ:
$api_key - APIキー
回答:
サービスのレスポンスはJSON形式で返されます:
{ "status": "success", "values": { "0": { "id": "12345", "phone": "79181234567" }, "1": { "id": "12345", "phone": "79181234568" } } }
考えられるエラー:
BAD_KEY - 無効なAPIキー
BAD_ACTION - 不正なアクション
JSON形式での回答:
{ "status": "error", "message": "*possible_answer*" }
フィールド内の可能な回答 "message":
NO_NUMBERS - レンタル中の番号はありません
SERVER_ERROR - サーバーエラー
パラメータ:
$api_key - APIキー
$id - レンタルID
$rent_time- レンタル時間(デフォルト:4時間)
回答:
サービスのレスポンスはJSON形式で返されます:
{ "status": "success", "phone": { "id": 1049, "endDate": "2020-01-31T12:01:52", "number": "79959707564"} }
完了したレンタルを延長する場合、再注文となり、新しいIDが発行されます
考えられるエラー:
BAD_KEY - 無効なAPIキー
BAD_ACTION - 不正なアクション
SERVER_ERROR - サーバーエラー
JSON形式での回答:
{ "status": "error", "message": "*possible_answer*", "info": "*details*" }
フィールド内の可能な回答 "message":
NO_ID_RENT - レンタルIDが存在しません
INVALID_TIME - 時間が正しくありません。利用可能な時間は4時間から1344時間までです
MAX_HOURS_EXCEED - 利用可能な最大時間を超えました
最大 - 利用可能な最大時間
INVALID_PHONE - 無効なレンタルID
RENT_DIE - 番号の有効期限が切れているため、レンタルを延長できません
NO_BALANCE - 残高不足
CHANNELS_LIMIT - アカウントがブロックされました
* この方法は、MTTオペレーターでのレンタルのみ利用可能です。
パラメータ:
$api_key - APIキー
$id - レンタルID
$rent_time - レンタル時間
回答:
サービスのレスポンスはJSON形式で返されます:
{ "status": "success", "price": 6.33 }
考えられるエラー:
BAD_KEY - 無効なAPIキー
BAD_ACTION - 不正なアクション
SERVER_ERROR - サーバーエラー
JSON形式での回答:
{ "status": "error", "message": "*possible_answer*" }
フィールド内の可能な回答 "message":
NO_ID_RENT - レンタルIDが存在しません
INVALID_PHONE - 無効なレンタルID
INVALID_TIME - 時間の設定が不正です
RENT_DIE - 番号の有効期限が切れているため、レンタルを延長できません
MAX_HOURS_EXCEED - 利用可能な最大時間を超えました
最大 - 利用可能な最大時間
CHANNELS_LIMIT - アカウントがブロックされました
API JAVA
Mavenにライブラリを含める
<artifactId>SMSActivateApi</artifactId>
<version>1.0</version>
</dependecy>
登録の例は以下でご覧いただけます MavenRepositoryへのリンク
SMS-Activate APIと連携するためのメインクラスをインポートします。
ライブラリを使用するにはAPIキーが必要です。このページまたは以下のリンクから取得できます。
SMS-Activate APIキーアカウントの現在の残高を確認するには、次のメソッドを使用してください getBalance... 残高に加えてキャッシュバックにも関心がある場合は、次のメソッドを呼び出してください getBalanceAndCashBack.
方法 getBalanceAndCashBack クラスオブジェクトを返しますSMSActivateGetBalanceAndCashBack.
パラメータ:
なし
戻り値の型:
BigDecimal
パラメータ:
なし
パラメータ:
countryId(Integer) - 国識別子。
service(String) - サービスの略称。
forward*(boolean) - 転送付きの番号をリクエストするかどうか。
operatorSet*(セット) - 事業者のセット。
phoneException*(セット) - ロシア専用のプレフィックスを除き、3桁から6桁の番号セット(例:7918、7900111)。
* オプション項目。何も指定しない場合、プロフィール設定に基づいてデフォルト数量が付与されます。
戻り値の型:
パラメータ:
countryId(Integer) - 国識別子。
operatorSet*(セット) - そのサービスで利用可能な事業者のセット
戻り値の型:
パラメータ:
id(整数) - アクティベーション識別子
service(String) - サービスの略称。
アクティベーション識別子の代わりに、受信したクラスオブジェクトを渡すことができます SMSActivateActivation メソッド使用後 getNumber または使用後のアクティベーションのいずれか getMultiServiceNumber.
戻り値の型:
パラメータ:
countryId(Integer) - 国識別子。
serviceMap(セット) - アクティベーションを購入するサービスのセット
multiForwardList(リスト) - 通話転送が利用可能なサービスのリスト
operatorSet(セット) - 事業者のセット。
パラメータ:
なし
戻り値の型:
パラメータ:
countryId(Integer) - 国識別子。
service(String) - サービスの略称。
戻り値の型:
パラメータ:
countryId(Integer) - 国識別子。
戻り値の型:
パラメータ:
activationId(整数) - アクティベーション識別子
アクティベーション識別子の代わりに、受信したクラスオブジェクトを渡すことができます SMSActivateActivation メソッド使用後 getNumber または使用後のアクティベーションのいずれか getMultiServiceNumber.
戻り値の型:
パラメータ:
id(整数) - アクティベーション識別子
status(SMSActivateClientStatus) - アクティベーションに設定するステータス
アクティベーション識別子の代わりに、受信したクラスオブジェクトを渡すことができます SMSActivateActivation メソッド使用後 getNumber または使用後のアクティベーションのいずれか getMultiServiceNumber.
戻り値の型:
パラメータ:
なし
パラメータ:
activationId(整数) - アクティベーション識別子
アクティベーション識別子の代わりに、受信したクラスオブジェクトを渡すことができます SMSActivateActivation メソッド使用後 getNumber または使用後のアクティベーションのいずれか getMultiServiceNumber.
アクティベーション付きSMS全文受信のアルゴリズム
getNumberメソッドで番号を取得後、以下のアクションが可能です:
CANCEL - 8 - アクティベーションをキャンセル(番号が適合しない場合)
MESSAGE_WAS_SENT - SMSが送信されたことを通知します(SMSの全文を受信するために必須)
MESSAGE_WAS_SENTステータスを必須で設定した後、waitSMSメソッドを使用してアクティベーションパラメータとSMS待機時間を指定し、SMSを受信するための変数を設定してください。
SMS受信後、getFullSMSメソッドを使用してSMSを取得し、その後getText()メソッドを使って全文を表示できます。
その後、アクティベーションを以下のステータスに設定できます:
MESSAGE_WAS_SENTステータスでのアクティベーション:
CANCEL - アクティベーションをキャンセル
コード受信直後:
REQUEST_ONE_MORE_CODE - 別のSMSをリクエスト
FINISH - SMSコードを確認し、アクティベーションを完了
REQUEST_ONE_MORE_CODEステータスでのアクティベーション:
FINISH - SMSコードを確認し、アクティベーションを完了
パラメータ:
countryId(Integer) - 国識別子。
service(String) - サービスの略称。
hours(Integer)* - レンタル時間
operator(String)* - 携帯電話事業者名
urlWebhook(String)* - Webhook用リンク(デフォルトでは考慮されません)
WebHookとは何ですか?* オプションパラメータ。指定しない場合、デフォルト値が適用されます
戻り値の型:
パラメータ:
countryId(Integer) - 国識別子。
operatorSet(セット) - 携帯電話事業者のセット
hours(Integer)* - レンタル時間
* オプションパラメータ。指定しない場合、デフォルト値が適用されます
パラメータ:
rentId(Integer) - レンタル番号の識別子
rentIdの代わりに、結果のクラスオブジェクトを渡すことができます SMSActivateRentActivation メソッド使用後 getRentNumber
戻り値の型:
メールAPI
APIステータスの説明
3 - 待機中
4 - キャンセル
5 - 成功
説明:
REST API原則へのより厳格な準拠と、Telegramアカウント登録用のgmail.comメールボックス数の増加。
パラメータ:
$api_key - APIキー
$site- メールが必要なサイト
回答:
サービスのレスポンスはJSON形式で返されます。例:
{
"status":"OK",
"response":{
"zones":[
{
"name":"info",
"cost":2.5
},
...
],
"popular":[
{
"name":"mail.ru",
"cost":6,
"count":159008
},
...
]
}
}
考えられるエラー:
BAD_SITE- サイトが指定されていません
BAD_KEY - 無効なAPIキー
BAD_ACTION - 不正なアクション
パラメータ:
$api_key - APIキー
$site - メールが必要なサイト
$mail_type - メールの種類:人気のあるドメインまたはゾーン(1 - ゾーン、2 - 人気)
$mail_domain - 選択されたゾーンまたはドメイン
考えられるエラー:
BAD_KEY - 無効なAPIキー
BAD_ACTION - 不正なアクション
MAIL_TYPE_ERROR - 指定されたサイトに対応するドメインが存在しません
CHANNELS_LIMIT - アカウントがブロックされました
パラメータ:
$api_key - APIキー
$id- 再有効化が必要なメールのID
回答:
サービスのレスポンスはJSON形式で返されます。例:
{
"status": "OK",
"response": {
"email": "[email protected]",
"id": 360
}
}
考えられるエラー:
BAD_KEY - 無効なAPIキー
BAD_ACTION - 不正なアクション
BLOCKED_SITE - ブロックされたウェブサイト
BAD_BALANCE - 残高不足
ACTIVATION_NOT_FOUND - アクティベーションが見つかりません
CHANNELS_LIMIT - アカウントがブロックされました
パラメータ:
$api_key - APIキー
$page- ページ番号
$per_page- 各ページに表示される購入数
$search- 検索バー
$sort- ソート順(desc: 降順、asc: 昇順)
回答:
サービスのレスポンスはJSON形式で返されます。例:
{
"status":"OK",
"response":{
"list":[
{
"id":"241",
"site":"apple.com",
"email":"[email protected]",
"status":"3",
"value":null,
"cost":"6.00",
"date":"2023-10-06 14:24:13",
"full_message":""
}
],
"pages":1,
"count":1
}
}
パラメータ:
$api_key - APIキー
$id- 購入ID
回答:
サービスのレスポンスはJSON形式で返されます。例:
{
"status":"OK",
"response":true
}
考えられるエラー:
EARLY_CANCEL_DENIED - 最初の2分間はメールをキャンセルできません。
パラメータ:
$api_key - APIキー
$id- 購入したメールのID(メール購入後に返されます)
回答:
サービスのレスポンスはJSON形式で返されます。例:
{
"status":"OK",
"response":{
"value":"Содержания письма"
}
}
APIパートナーソフトウェア
パラメータ:
$api_key - APIキー
$id- 購入が必要なソフトウェアのID
回答:
サービスのレスポンスはJSON形式で返されます。例:
{
"status": "success",
"key": "F5qrzFoY6afj3zrEq7SeMplbx",
"manual": "Software download link:"
}
考えられるエラー:
BAD_DATA - IDが不正、またはIDが数値ではありません
BAD_ACTION - 無効な操作、またはリセラーが認証されていません。
<?php
include_once ("smsactivateApi.php");//Inclusion of a class in a project
$sms = new SMSActivate($API_KEY);//Create class instance SMSActivate
$freeSlots = $sms->getNumbersStatus(0, 'tele2');//Get the number of available numbers for the country of Russia and the tele2 operator
echo "Номеров Вконтакте: " . $freeSlots['vk']."\n";//Show for Vk
echo "Номеров Whatsapp: " . $freeSlots['wa']."\n";//Show for whatsapp
var_dump($freeSlots); //Show all services with quantity
$array=$activate->getTopCountriesByService(); //Get an array whose elements contain information for each country
$balance = $sms->getBalance();//Get balance
echo "On the account " . $balance." rub.\n";//Show balance
$balance = $sms->getBalanceAndCashBack();//Request a balance with cashback account
echo "On the account " . $balance." rub.\n";//Request a balance with cashback account
$operators = $sms->getOperators();
//Get operators for all countries
if (in_array('mts', $operators['countryOperators'][0])) {
//check if 'mts' is available for Russia
//perform an action
}
if (in_array('chinamobile', $operators['countryOperators'][3])) {
//check if 'chinamobile' is available for China
//perform an action
}
$activations = $sms->getActiveActivations();
$number = $sms->getNumber('ok',0, 0, 'tele2');//Get Odnoklassniki number without forwarding
echo "Activation № " . $number['id']. "Phone ". $number['number'] \n";//Show id and activation number
$result = $sms->getNumber('vk', 0 , 1);
if (!is_array($result)) {
echo 'Ошибка: ' . $result . '\n';//If an error occurs, a string will be returned, if successful, an array will be returned.
} else {
echo 'Id: ' . $result['id'] ."\n";
echo 'Номер: ' . $result['number'] ."\n";
}
$result = $sms->getNumberV2('vk', 0 , 1);
$number = $sms->getMultiServiceNumber('ok,vk,vi,av','0,0,0,1', 0, 'tele2');//Get a number for services Odnoklassniki, Vkontakte, Viber without call forwarding and Avito with call forwarding
foreach ($number as $value) {
echo "Activation № " . $value['activation']. " for service ". $value['service'] ."\n";
}
echo "Number " . $value['phone'] ."\n";//Show activation id and number
$status = $sms->setStatus($number['id'], 3);//Change activation status by id (get 1 more code)
$status = $sms->getStatus($number['id']);//Get activation status by id
if (is_array($status) {
echo "статус : " . $status['status'];//Can be STATUS_OK or STATUS_WAIT_RETRY, otherwise a line with error text will be returned
echo "код: " . $status['code'];
} else {
echo $status ."\n";
}
$incomingCall = $sms->getIncomingCallStatus($id);//Get activation data by call
echo $incomingCall['phone'] //Show incoming number
$prices = $sms->getPrices(1, 'vk');//Get the current price for the service
echo "Price for VK (Ukraine) : " .$prices[1]['vk']['cost']." rub. quantity: ". $prices[1]['vk']['count'];//Show the result
$countries = $sms->getCountries();//Get a list of all countries
$additional = $sms->getAdditionalService('fx', $id);//Get additional activation for PGbonus service based on id activation
echo "Activation no.: " . $additional[id] . " Telephone: " . $additional[number];//Show the result
$getAvailableRentNumbers = $sms->getRentServicesAndCountries('2');//Request available countries for rent and services (for 2 hours for all operators)
echo "Full rental - Cost:" . $getAvailableRentNumbers['services']['full']['cost'] . " Quant :" .$getAvailableRentNumbers['services']['full']['quant'] ." \n"; //Display full price information
foreach( $getAvailableRentNumbers['operators'] as $value) {
echo " Operator " . $value ."\n"; }//List operators
$getRentNumber = $sms->getRentNumber('vk','10','0','yota');//Get a number for rent for Vkontakte for 10 hours, operator 'Yota', country - Russia
if ($getRentNumber['status'] === 'success'){
echo "The rental was successful! Your phone number is: " . $getRentNumber['phone']['number']." \nRent expiration : ". $getRentNumber['phone']['endDate']." \nId numbers :" .$getRentNumber['phone']['id'] ; }//Display rental information
else
echo "Error code : " . $getRentNumber['message'];
$getRentStatus = $sms->getRentStatus($getRentNumber['phone']['id']);//Get the rent status with id from the received number
if ($getRentStatus['status'] == 'success'){
foreach( $getRentStatus['values']as $index => $value) {
echo " Message " . $index .": from the number - " . $value['phoneFrom'] . " Service - " . $value ['service'] . "message text - " . $value['text'] . "Date - " . $value['date']; } }//display a list of messages received while renting a phone
else
echo "Error code : " . $getRentStatus['message'];
$setRentStatus = $sms->setRentStatus($getRentNumber['phone']['id'],1);//Set rental status 'finish' with id from received number
if ($setRentStatus['status'] == 'success')
echo " Status change was successful! ";
else
echo "Error code : " . $setRentStatus['message'];
$getRentList = $sms->getRentList();//Get a list of currently rented numbers
if (getRentList['status'] == 'success')
foreach( $getRentList['values'] as $value) {
echo " ID " . $value["id"] . " Number " . $value["phone"] ."\n"; }//List numbers
else
echo "Error code : " . $getRentList['message'];
$result = $sms->continueRentNumber($id);//Extend the lease of activation id for 4 hours (by default)
if ($result['status'] == 'success') {
echo "Number: " . $result['phone']['number']"//Display number
echo "id: " . $result['phone']['id']"//Display activation id
echo "The lease is valid until: " . $result['phone']['endDate']"//Display the date and time of the end of the lease
} else {
echo "Error code : " . $result['msg'];
}
$result = $sms->getContinueRentPriceNumber($id, 12);//Get the cost of renewing the lease to activate the id for 12 hours
if ($result['status'] == 'success') {
echo " Renewal cost " . $result['price'];//Withdraw the cost
} else {
echo "Error code: " . $result['message']; //Display error code
}
from sms-activate.ink import SMSActivateAPI
# SMSActivateAPI Contains all basic tools for working with the SMSActivate API
sa = SMSActivateAPI(API_KEY)
sa.debug_mode = True
# Used for debugging. When debug_mode is active, all responses from the server and class will be output to the console
print(sa.version())
# Returns the current version of the library
status = sa.getNumbersStatus(country=0, operator='tele2')
try:
print(status['vk_0']) # 274789
except:
print(status['message']) # Error text
result = sa.getTopCountriesByService('vk')
try:
print(result[0]['count']) # 2350
except:
print(result['message']) # Error text
balance = sa.getBalance() # {'balance': '100.00'}
try:
print(balance['balance']) # 100.00
except:
print(balance['message']) # Error text
balance = sa.getBalanceAndCashBack() # {'balance': '100.00'}
try:
print(balance['balance']) # 100.00
except:
print(balance['message']) # Error text
operators = sa.getOperators(country=0)
try:
print(operators['countryOperators']['0'])
except:
print(operators['error']) # Error status
activations = sa.getActiveActivations()
try:
print(activations['activeActivations'])
except:
print(activations['error']) # Error status
number = sa.getNumber(service='vk', operator='tele2', country=0, verification="true") # {'activation_id': 000000000, 'phone': 79999999999}
try:
print(number['phone']) # 79999999999
except:
print(number['message']) # Error text
number = sa.getNumberV2(service='vk', country=0)
try:
print(number['phoneNumber']) # 79999999999
except:
print(number['message']) # Error text
multinumber = sa.getMultiServiceNumber(service='fb,ig', operator='tele2', country=0) # [{'phone': '79999999999', 'activation': 000000000, 'service': 'fb'}, {'phone': '79999999999', 'activation': 000000001, 'service': 'ig'}]
try:
print(multinumber[0]['phone']) # 79999999999
except:
print(multinumber['message']) # Error text
status = sa.setStatus(id=000000000, status=1) # ACCESS_READY
try:
print(status) # ACCESS_READY
except:
print(status['message']) # Error text
status = sa.getStatus(id=000000000) # STATUS_WAIT_CODE
try:
print(sa.activationStatus(status)) # {'status': 'STATUS_WAIT_CODE', 'message': 'Ожидание смс'}
except:
print(status['message']) # Error text
status = sa.getIncomingCallStatus(id=000000000)
try:
print(status['status']) # 2
except:
print(status['message']) # Error text
prices = sa.getPrices(service='fb', country=0)
try:
print(prices['0']) # {'fb': {'cost': 9, 'count': 27934}}
except:
print(prices['message']) # Error text
countries = sa.getCountries()
try:
print(countries['0']['eng']) # Russia
except:
print(countries['message']) # Error text
service = sa.getAdditionalService(id=000000000, service='ig')
try:
print(service['phone']) # 79999999999
except:
print(service['message']) # Error text
service = sa.getRentServicesAndCountries(time=4, operator='tele2', country=0)
try:
print(service['services']['full']['cost']) # 100.00
except:
print(service['message']) # Error text
rent = sa.getRentNumber(service='ig', time=4, operator='tele2', country=0)
try:
print(rent['phone']['number']) # 79999999999
except:
print(rent['message']) # Error text
status = sa.getRentStatus(000000000)
try:
print(status['values']['0']['text']) # SMS
except:
print(status['message']) # Error text
status = sa.setRentStatus(id=000000000, status=1)
try:
print(status['status']) # success
except:
print(status['message']) # Error text
rent = sa.getRentList()
try:
print(rent['values']['0']['phone']) # 79999999999
except:
print(rent['message']) # Error text
rent = sa.continueRentNumber(id=000000000, time=4)
try:
print(rent['phone']['number']) # 79999999999
except:
print(rent['message']) # Error text
rent = sa.getContinueRentPriceNumber(000000000)
try:
print(status['price']) # 4.00
except:
print(status['message']) # Error text
import ru.sms_activate.SMSActivateApi;//Inclusion of a class in a project
SMSActivateApi smsActivateApi = new SMSActivate("API_KEY");//Create an instance of the SMSActivate class
BigDecimal balance = smsActivateApi.getBalance();//Get the current account balance
System.out.println("Balance: "+ balance)//Withdraw the received balance
SMSActivateGetBalanceAndCashbackResponse smsActivateGetBalanceAndCashbackResponse = smsActivateApi.getBalanceAndCashback();//Get current balance and cashback
System.out.println("Cashback + balance: "+ smsActivateGetBalanceAndCashbackResponse.getBalanceAndCashback());//Withdraw the amount of balance and cashback
SMSActivateActivation activation=smsActivateApi.getNumber(0,"vk")//Get activation for the Vkontakte service in Russia
System.out.println(activation);//Withdraw the received activation
SMSActivateGetNumbersStatusResponse smsActivateGetNumbersStatusResponse= smsActivateApi.getNumberStatus(0,null);//Get information about available services for Russia
SMSActivateServiceInfo go = smsActivateGetNumbersStatusResponse.getSMSActivateServiceInfoByShortName("go");//Getting information about numbers for the Google service
System.out.println("Short name service: " + go.getShortName();//Get the short name of the service
System.out.println("count phone numbers: "+ go.getCountPhoneNumber();//Get the number of numbers for the service
System.out.println(""Forwarding is available: "+ go.isForward() ? "yes" : "no"//Find out if the service has a redirect
SMSActivateActivation activation=smsActivateApi.getNumbersStatus(0,"ot",true);//Activations
smsActivateApi.setStatus(activation, SMSActivateClientStatus.MESSAGE_WAS_SENT);//Setting the MESSAGE_WAS_SENT status after sending SMS for the number
SMSActivateActivation childActivation =smsActivateApi.getAdditionalService(activation,"av");//Requesting a new activation for an additional service
System.out.println(childActivation);//Displaying information about additional activation
Set<String>operatorSet= new HashSet<>();
operatorSet.add("mts");//Adding an MTS operator to the set of operators
Map<String,Boolean>serviceMap= new HashMap<>();
serviceMap.put("av",false);//Adding the Avito service to the list of services (specify true if you need a service with redirection)
SMSActivateGetMultiServiceNumberResponse multiServiceNumberResponse=smsActivateApi.getMultiServiceNumber(0, serviceMap, operatorSet);//Getting activation for multiple services
multiServiceNumberResponse.getSMSActivateActivationList().forEach(activation->{
System.out.println("Id: " + activation.getId());
System.out.println("Number: " + activation.getNumber());
System.out.println("Service name: " + activation.getShortName());
}
//Displaying information about received activations
SMSActivateGetPricesResponse smsActivateGetPricesResponse=smsActivateApi.getPricesByCountryIdAndServiceShortName(0, "vk");//Obtaining a list of prices for Russia on the Vkontakte service. For a complete list of prices, use the getAllPrices () method;
SMSActivateGetPriceInfo vk=smsActivateGetPricesResponse.getPriceInfo(0, "vk");//Getting information about the Vkontakte service for Russia
System.out.println(">>> Cost: "+ vk.getCost());//Get a price for the service
System.out.println(">>> count phone numbers: " + vk.getCountPhoneNumbers());//Get the number of numbers for the service
SMSActivateActivation activation=smsActivateApi.getNumber(0,"vk")//Get activation for the Vkontakte service in Russia
System.out.println(activation);//Withdraw the received activation
SMSActivateGetStatusResponse getResponse = smsActivateApi.getStatus(activation);//Getting a status for activation
System.out.println(getResponse.getSMSActivateGetStatus());//Displaying information about the activation status
smsActivateApi.setStatus(activation, SMSActivateClientStatus.MESSAGE_WAS_SENT);//Setting the MESSAGE_WAS_SENT status after receiving SMS for the number
smsActivateApi.setStatus(activation, SMSActivateClientStatus.FINISH);//Setting the FINISH status after receiving SMS for the number
SMSActivateGetCountriesResponse smsActivateGetCountriesResponse =smsActivateApi.getCountries();//Getting a list of countries with information
SMSActivateCountryInfo countryInfo = smsActivateGetCountriesResponse.get(0)//Getting information about the first country on the list
System.out.println("Russian name: "+countryInfo.getRussianName();//Display the Russian name of the country
System.out.println("English name: "+countryInfo.getEnglishName();//Display the Russian name of the country
System.out.println("Support multi-service: "+ countryInfo.isSupportMultiService() ? "yes" : "no"//Show if the country supports multi-services
SMSActivateActivation activation=smsActivateApi.getNumber(0,"vk")//Get activation for the Vkontakte service in Russia
smsActivateApi.setStatus(activation, SMSActivateClientStatus.MESSAGE_WAS_SENT);//Setting the MESSAGE_WAS_SENT status after sending SMS for the number
String code=smsActivateApi.waitSms(activation,2)//Set receiving sms within 2 minutes
if(code == null) {
smsActivateApi.setStatus(activation, SMSActivateClientStatus.CANCEL);//Setting the CANCEL status if sms has not arrived
}
else{
SMSActivateGetFullSmsResponse smsActivateGetFullSmsResponse=smsActivateApi.getFullSms(activation)//Receiving sms text
System.out.println("Full SMS: "+smsActivateGetFullSmsResponse.getText());//SMS text output
}
SMSActivateRentActivation rentActivation= smsActivateApi.getRentNumber(0, "vk", 6);//Getting a number with rent
System.out.println(">> ID: "+rentActivation.getId());//Activation ID withdrawal
System.out.println(">> Number: "+rentActivation.getId());//Displaying the activation number
System.out.println(">> End date: "+rentActivation.getId());//Displaying the activation expiration date
SMSActivateGetRentServicesAndCountriesResponse smsActivateGetRentServicesAndCountriesResponse= smsActivateApi.getRentServicesAndCountries(0, null, 4);//Obtaining information on services and countries that support rental
smsActivateGetRentServicesAndCountriesResponse.getAllRentServices().forEach((serviceShortName, smsActivateRentService)->{
System.out.println("Service shortname: " + serviceShortName);
System.out.println(" count phone numbers: " + smsActivateRentService.getCountPhoneNumbers());
System.out.println(">> Cost: " + smsActivateRentService.getCost());
}
//Displaying information about received services
SMSActivateRentActivation rentActivation= smsActivateApi.getRentNumber(0, "vk");//Getting a number with rent
SMSActivateGetRentStatusResponse smsActivateGetRentStatusResponse= smsActivateApi.getRentStatus(rentActivation);//Getting activation status
System.out.println(">> Count sms: "+ smsActivateGetRentStatusResponse.getCountSms());//Displaying the number of sms on the rented number





















































