endpoints.path: /
endpoints.endpoint_type: HTTP
endpoints.scan_time: 2025-10-04T14:46:00.576935
endpoints.uri: https://swfithubdigital.com.ng/
endpoints.protocol: HTTP/1.1
endpoints.status_reason: OK
endpoints.key: content-type
endpoints.headers: text/html
endpoints.key: content-encoding
endpoints.headers: gzip
endpoints.key: vary
endpoints.headers: Accept-Encoding
endpoints.key: accept-ranges
endpoints.headers: bytes
endpoints.key: alt-svc
endpoints.headers: h3=":443"; ma=2592000, h3-29=":443"; ma=2592000, h3-Q050=":443"; ma=2592000, h3-Q046=":443"; ma=2592000, h3-Q043=":443"; ma=2592000, quic=":443"; ma=2592000; v="43,46"
endpoints.key: last-modified
endpoints.headers: Sat, 04 Oct 2025 14:13:11 GMT
endpoints.key: Keep-Alive
endpoints.headers: timeout=5, max=100
endpoints.key: date
endpoints.headers: <REDACTED>
endpoints.key: content-length
endpoints.headers: 3116
endpoints.key: Connection
endpoints.headers: Keep-Alive
endpoints.html_tags: <title>swifthub Digital Service CT - VTpass Sandbox & Monnify</title> <meta charset="UTF-8" /> <meta name="viewport" content="width=device-width, initial-scale=1" />
endpoints.body: <!DOCTYPE html>
  <html lang="en">
  <head>
  <meta charset="UTF-8" />
  <meta name="viewport" content="width=device-width, initial-scale=1" />
  <title>swifthub Digital Service CT - VTpass Sandbox & Monnify</title>
  <style>
  /* Keep all your previous styles here */
  body { font-family: Arial, sans-serif; margin:0; padding:0; background: linear-gradient(135deg,#ffffff,#e6f0ff); color:#1a237e; }
  header{background-color:#1a237e;color:white;padding:20px 30px;display:flex;flex-wrap:wrap;align-items:center;justify-content:space-between;}
  header .logo{font-size:24px;font-weight:bold;letter-spacing:2px;}
  header nav a{color:white;text-decoration:none;margin-left:20px;font-weight:600;transition:color 0.3s ease;}
  header nav a:hover{color:#64b5f6;}
  main{max-width:900px;margin:30px auto;background:white;padding:30px 40px;border-radius:8px;box-shadow:0 4px 15px rgba(26,35,126,0.2);}
  h1,h2{color:#0d153e;margin-bottom:15px;}
  section{margin-bottom:40px;}
  p{line-height:1.6;color:#333;}
  .contact-info{background-color:#f0f4ff;padding:20px;border-radius:6px;font-weight:600;}
  form{background-color:#f9fbff;padding:25px;border-radius:6px;box-shadow:inset 0 0 12px #cce0ff;}
  label{font-weight:600;display:block;margin-bottom:7px;margin-top:15px;}
  input[type="text"],input[type="number"],select{width:100%;padding:10px 12px;border-radius:5px;border:1px solid #90caf9;font-size:1rem;box-sizing:border-box;}
  input[type="submit"]{margin-top:20px;background-color:#1a237e;color:white;padding:14px 28px;border:none;border-radius:5px;font-weight:700;cursor:pointer;font-size:16px;transition:background-color 0.3s ease;}
  input[type="submit"]:hover{background-color:#3949ab;}
  @media(max-width:600px){header{flex-direction:column;align-items:flex-start;}header nav{margin-top:10px;}header nav a{margin-left:0;margin-right:15px;}}
  </style>
  </head>
  <body>
  <header>
    <div class="logo">swifthub Digital Service CT</div>
    <nav>
      <a href="#welcome">Welcome</a>
      <a href="#about">About Us</a>
      <a href="#why-us">Why Choose Us</a>
      <a href="#contact">Contact Us</a>
      <a href="#services">Services</a>
    </nav>
  </header>
  <main>
  <section id="welcome" class="welcome-note">
    <h1>Welcome to swifthub Digital Service CT</h1>
    <p>Your trusted partner for seamless utility payment services powered by VTpass sandbox and Monnify sandbox integration.</p>
  </section>
  <section id="services">
    <h2>Make a Payment</h2>
    <form id="paymentForm" novalidate>
      <label for="service">Select Service</label>
      <select name="service" id="service" onchange="onServiceChange()" required>
        <option value="" disabled selected>-- Select a service --</option>
        <option value="airtime">Airtime</option>
        <option value="data">Data Subscription</option>
        <option value="tv-subscription">TV Subscription</option>
        <option value="electricity-bill">Electricity Bill</option>
      </select>
  
      <div id="provider-container" style="display:none;">
        <label for="provider">Select Provider</label>
        <select name="provider" id="provider" onchange="onProviderChange()">
          <option value="" disabled selected>-- Select Provider --</option>
        </select>
      </div>
  
      <div id="account-container" style="display:none;">
        <label for="accountInput" id="account-label">Phone Number</label>
        <input type="text" name="account" id="accountInput" placeholder="08012345678" />
      </div>
  
      <div id="customer-phone-container" style="display:none;">
        <label for="customer-phone">Customer Phone Number</label>
        <input type="text" id="customer-phone" name="phone" placeholder="Enter your phone number" pattern="\d{10,11}" />
      </div>
  
      <div id="variation-container" style="display:none;">
        <label for="variation_code">Select Plan / Package</label>
        <select name="variation_code" id="variation_code">
          <option value="" disabled selected>Loading variations...</option>
        </select>
      </div>
  
      <div id="elec-variation-container" style="display:none;">
        <label for="elec_variation_code">Meter Type</label>
        <select name="variation_code" id="elec_variation_code">
          <option value="" disabled selected>-- Select Meter Type --</option>
          <option value="prepaid">Prepaid</option>
          <option value="postpaid">Postpaid</option>
        </select>
      </div>
  
      <div id="amount-container" style="display:none;">
        <label for="amount" id="amount-label">Amount (₦)</label>
        <input type="number" id="amount" name="amount" min="1" placeholder="Enter amount" />
      </div>
  
      <input type="submit" value="Pay Now" />
    </form>
  </section>
  <section id="contact" class="contact-info" style="margin-top:50px;">
    <h2>Contact Us</h2>
    <p>Email: <a href="mailto:swifthubdigitalservicect@gmail.com">swifthubdigitalservicect@gmail.com</a></p>
    <p>WhatsApp: <a href="https://wa.me/2348168679219" target="_blank" rel="noopener">08168679219</a></p>
  </section>
  </main>
  
  <script>
  const vtpassApiKey = '3115ec6faa9fa196d93d90325b5e624d';
  const vtpassBaseUrl = 'https://sandbox.vtpass.com/api/service-variations';
  
  const providersByService = {
    airtime: ['mtn','airtel','etisalat','glo','glo-sme','etisalat-sme'],
    data: ['mtn-data','airtel-data','etisalat-data','glo-data','glo-sme-data','etisalat-sme-data'],
    'tv-subscription': ['gotv','dstv','startimes','showmax'],
    'electricity-bill':['ikeja-electric','eko-electric','kano-electric','ph-edc','jos-electric','ibedc-electric','kaduna-electric','abuja-electric','enugu-electric','benin-electric','aba-electric','yola-electric']
  };
  
  function onServiceChange(){
    const service=document.getElementById('service').value;
    const providerSelect=document.getElementById('provider');
    providerSelect.innerHTML='<option value="" disabled selected>-- Select Provider --</option>';
    hide('provider-container'); hide('account-container'); hide('customer-phone-container');
    hide('variation-container'); hide('elec-variation-container'); hide('amount-container');
    clearValue('accountInput'); clearValue('customer-phone'); clearValue('amount'); clearVariationSelect();
  
    if(!service) return;
    providersByService[service].forEach(p=>{const opt=document.createElement('option'); opt.value=p; opt.text=p.replace(/-/g,' ').toUpperCase(); providerSelect.appendChild(opt);});
    show('provider-container');
  
    const accountInput=document.getElementById('accountInput');
    const accountLabel=document.getElementById('account-label');
  
    switch(service){
      case'airtime': accountLabel.textContent='Phone Number'; accountInput.placeholder='08012345678'; accountInput.pattern='\\d{10,11}'; show('account-container'); hide('customer-phone-container'); hide('elec-variation-container'); show('amount-container'); document.getElementById('amount').min=50; break;
      case'data': accountLabel.textContent='Phone Number'; accountInput.placeholder='08012345678'; accountInput.pattern='\\d{10,11}'; show('account-container'); hide('customer-phone-container'); hide('elec-variation-container'); hide('amount-container'); break;
      case'tv-subscription': accountLabel.textContent='Smartcard Number'; accountInput.placeholder='Enter Smartcard Number'; accountInput.removeAttribute('pattern'); show('account-container'); show('customer-phone-container'); hide('elec-variation-container'); hide('amount-container'); break;
      case'electricity-bill': accountLabel.textContent='Meter Number'; accountInput.placeholder='Enter Meter Number'; accountInput.removeAttribute('pattern'); show('account-container'); show('customer-phone-container'); show('elec-variation-container'); show('amount-container'); document.getElementById('amount').min=100; break;
    }
  }
  
  function onProviderChange(){
    const service=document.getElementById('service').value;
    const provider=document.getElementById('provider').value;
    const variationSelect=document.getElementById('variation_code');
  
    clearVariationSelect(); hide('variation-container');
    if(!provider) return;
  
    if(service==='data'||service==='tv-subscription'){
      show('variation-container');
      variationSelect.innerHTML='<option>Loading variations...</option>';
  
      fetch(`${vtpassBaseUrl}?serviceID=${provider}`, {method:'GET', headers:{'api-key':vtpassApiKey}})
        .then(res=>res.json())
        .then(data=>{
          variationSelect.innerHTML='<option value="" disabled selected>-- Select Plan --</option>';
          if(data.content && Array.isArray(data.content.variations)){
            data.content.variations.forEach(v=>{const option=document.createElement('option'); option.value=v.variation_code; option.text=`${v.name} - ₦${v.variation_amount}`; variationSelect.appendChild(option);});
          } else { variationSelect.innerHTML='<option disabled>No plans available</option>'; }
        }).catch(()=>{variationSelect.innerHTML='<option disabled>Error loading plans</option>';});
    }
  }
  
  function show(id){document.getElementById(id).style.display='block';}
  function hide(id){document.getElementById(id).style.display='none';}
  function clearValue(id){document.getElementById(id).value='';}
  function clearVariationSelect(){const sel=document.getElementById('variation_code'); if(sel) sel.innerHTML='';}
  
  document.getElementById('paymentForm').addEventListener('submit', async function(e){
    e.preventDefault();
    const formData=new FormData(this);
    const response=await fetch('backend.php',{method:'POST',body:formData});
    const result=await response.json();
    if(result.status==='success' && result.checkoutUrl){
      window.location.href=result.checkoutUrl;
    } else if(result.status==='error'){
      alert(result.message);
    } else {
      alert('Unexpected error. Try again.');
    }
  });
  
  window.onload=()=>{onServiceChange();};
  </script>
  </body>
  </html>
endpoints.html_title: swifthub Digital Service CT - VTpass Sandbox & Monnify
endpoints.supported_versions: HTTP/1.1 HTTP/2
endpoints.banner: HTTP/1.1 200 OK
  Connection: Keep-Alive
  Keep-Alive: timeout=5, max=100
  content-type: text/html
  last-modified: Sat, 04 Oct 2025 14:13:11 GMT
  accept-ranges: bytes
  content-encoding: gzip
  vary: Accept-Encoding
  content-length: 3116
  date:  <REDACTED>
  alt-svc: h3=":443"; ma=2592000, h3-29=":443"; ma=2592000, h3-Q050=":443"; ma=2592000, h3-Q046=":443"; ma=2592000, h3-Q043=":443"; ma=2592000, quic=":443"; ma=2592000; v="43,46"
  
endpoints.ip: 141.95.120.221
[binary data, 4 values, 119 bytes]