DTH Heavy Refresh

DTH account refresh proccess.

📘

Header Request

Accept : application/json
Content-Type: application/x-www-form-urlencoded

Request Parameters

ParametersTypeMandatory (M) , Optional(O)Description
numberStringMCustomer DTH number
product_codeIntegerMUnique Operator code
request_idStringMUnique Request number or timestamp

Sample Request

cUrl
curl --location 'https://pay2new.in/apis/v1/dthHeavyRefresh' \
--header 'secret: qwertyuQWERTY12345asdf' \
--header 'Content-Type: application/json' \

--data '{
  "number": "123456789",
    "product_code": 21,
    "request_id":"P2N54544444545"
}'

<?php

$curl = curl_init();

curl_setopt_array($curl, array(
  CURLOPT_URL => 'https://pay2new.in/apis/offer/v1/dthHeavyRefresh',
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => '',
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 0,
  CURLOPT_FOLLOWLOCATION => true,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => 'POST',
  CURLOPT_POSTFIELDS =>'{
      "number": "123456789",
    "product_code": 21,
    "request_id": P2N54544444545
}',
  CURLOPT_HTTPHEADER => array(
    'secret: qwertyuQWERTY12345asdf',
    'Content-Type: application/json',
  ),
));

$response = curl_exec($curl);

curl_close($curl);
echo $response;

Response Parameters

ParametersTypeDescription
statusIntegerPay2New status code
messageStringMessage from API
dataArrayResponse Data (If Present)
order_idStringTransaction Id ( If transaction otherwise it is null )

Sample Response

{
    "status": 1,
    "message": "Transaction Successful",
    "data": {
        "description": null,
        "customer_name": "Test"
    },
    "order_id": "P2N5452534158DFOLASDF"
}
Language
Click Try It! to start a request and see the response here!