buscancellationcharges

Post  https://travel.OQPay.co.in/api/V1/Bus/Travel/BusCancellationCharges


The BusCancellationCharges API is used to fetch the cancellation details for a specific bus ticket. It provides information such as whether the ticket is cancellable, the applicable cancellation charges, and other related metadata.

Note: cancelTicket_Details will be obtained from BusRequery.
For cancelling multiple tickets under the same booking_refno, you can add multiple entries in cancelTicket_Details.

cancelTicket_Details will be obtained from BusRequery.

Body Parameters
{
    "booking_RefNo": "BBB6YLRP",
    "cancelTicket_Details": [
      {
        "seat_Number": "14",
        "ticket_Number": "BBB6YLRP0",
        "transport_PNR": "7AKE22CH"
      } 
    ],
    "iP_Address": "27.XXX.XX.76",
    "request_Id": "REQ123456",
    "imeI_Number": "353535353535353",
    "registrationID": "OQPay-554"
}
Request Parameters
Name Type Description
booking_RefNo String This requires the booking reference number, which is obtained from the Bus_TempBooking response.
seat_Number String This requires the seat number.
ticket_Number String This requires the ticket number.
Responses

200

200

Response

200

RESPONSE BODY

Json

401

401

Response

401

RESPONSE BODY

Object

responsecode integer

status boolean

message string


Did this page help you?     Yes    No

Language
shell Shell
python Python
node Node
c# C#
php PHP

cURL

curl --location --request POST 'https://travel.OQPay.co.in/api/V1/Bus/Travel/BusCancellationCharges' \
--header 'Content-Type: application/json' \
--data  '{
  "booking_RefNo": "BBB6YLRP",
  "cancelTicket_Details": [
  { 
  "seat_Number": "14",
  "ticket_Number": "BBB6YLRP0",
  "transport_PNR": "7AKE22CH"
  } 
  ], 
  "iP_Address": "27.XXX.XX.76",
  "request_Id": "REQ123456",
  "imeI_Number": "353535353535353",
  "registrationID": "OQPay-554"
}'
                                
import requests
import json

url = 'https://travel.OQPay.co.in/api/V1/Bus/Travel/BusCancellationCharges'
payload = "{
    "booking_RefNo": "BBB6YLRP",
    "cancelTicket_Details": [
    { 
    "seat_Number": "14",
    "ticket_Number": "BBB6YLRP0",
    "transport_PNR": "7AKE22CH"
    } 
    ], 
    "iP_Address": "27.XXX.XX.76",
    "request_Id": "REQ123456",
    "imeI_Number": "353535353535353",
    "registrationID": "OQPay-554"
}" 

headers = {
  "Content-type" : "application/json"
}

response = requests.request("POST", url, headers=headers, data=payload)

print (response.text)
                                
var requests = require("request");
var options = { 
  "method" : "POST",
  "url" : 'https://travel.OQPay.co.in/api/V1/Bus/Travel/BusCancellationCharges',
  "headers" : {
    "Content-Type" : 'application/json'
  },
  body: '{
    "booking_RefNo": "BBB6YLRP",
    "cancelTicket_Details": [
    { 
    "seat_Number": "14",
    "ticket_Number": "BBB6YLRP0",
    "transport_PNR": "7AKE22CH"
    } 
    ], 
    "iP_Address": "27.XXX.XX.76",
    "request_Id": "REQ123456",
    "imeI_Number": "353535353535353",
    "registrationID": "OQPay-554"
  }' 
}; 
request(options, function(error, response){
   if(error) throw new Error(error);
   console.log(response.body); 
}); 
                                
var client = new HttpClient();
var request = new HttpRequestMessage(HttpMethod.Get,'https://travel.OQPay.co.in/api/V1/Bus/Travel/BusCancellationCharges')
var content = new StringContent(
  "{
    "booking_RefNo": "BBB6YLRP",
    "cancelTicket_Details": [
    { 
    "seat_Number": "14",
    "ticket_Number": "BBB6YLRP0",
    "transport_PNR": "7AKE22CH"
    } 
    ], 
    "iP_Address": "27.XXX.XX.76",
    "request_Id": "REQ123456",
    "imeI_Number": "353535353535353",
    "registrationID": "OQPay-554"
  }",
  null,"application/json"
); 

request.Content = content;
var response =  await client.SendAsync(request);
response.EnsureSuccessStatusCode();
Console.WriteLine(await response.Content.ReadAsStringAsync());
                                
<?php
$curl =  curl_init();
curl_setopt_array($curl, array(
  CURLOPT_URL =>  'https://travel.OQPay.co.in/api/V1/Bus/Travel/BusCancellationCharges',
  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 =>  '{
   "booking_RefNo": "BBB6YLRP",
    "cancelTicket_Details": [
    { 
    "seat_Number": "14",
    "ticket_Number": "BBB6YLRP0",
    "transport_PNR": "7AKE22CH"
    } 
    ], 
    "iP_Address": "27.XXX.XX.76",
    "request_Id": "REQ123456",
    "imeI_Number": "353535353535353",
    "registrationID": "OQPay-554"
  }',
  CURLOPT_HTTPHEADER =>  array(
    'Content-Type: application/json'
  ),
));
$response =  curl_exec($curl);
curl_close($curl);
echo $response;
                                

RESPONSE

200

401

-Result

Example

{
"cancellable": "true",
"cancellationCharge_Key": "xJI45+c9e/C9Usv3W9OhwSAAncOZL4Rhce4/0Tj1WtR3t6vShqIWFMspDW6ARaRofgs05V90UcXS4QpF1yoiTTUf3aws5GiV6cdH0oDpIWG/yRitwsUXBW8TZJRjXxY2aIsv4lJjcY77zqIbiZJzPaOljAcp6SR1dpIdVeP04tbuR1wgM8PoU9UJS4OjFhxNwjTV0fhvTYm+IRU6IZN1pu0uoEV96IlVoLMGo8bS/fCB8jB4QkxdejIQ5RDcC4UE4mLyapvNTu4ryXz5szOBNupQoFrvOv29x5tMrfQnaWpj1eanoSZnzKIyC2G5O8zsdiX4uJCs1ufmZvqqmWQmrg==",
"cancellationPenaltyValues": [
   { 
       "cancellation_Penalty": "10",
       "seat_Number": "14",
       "ticket_Number": "BBB6YLRP0"
   { 
       "cancellation_Penalty": "50",
       "seat_Number": "5",
       "ticket_Number": "BBB6YLML1"
  } 
], 
"response_Header": {
    "error_Code": "0000",
    "error_Desc": "SUCCESS",
    "error_InnerException": "",
    "request_Id": "REQ123456",
    "status_Id": "11"
}, 
"serviceCharge": "0",
"statuss": "True",
"message": "Transaction successfully",
"value": ""
 }
                                
{
    "code": "207",
    "description": "Amount is Requaired",
    "merchantTrxnRefId": null,
    "token": null,
    "status": "False"
}