<?php
session_start();
$guest = true;
require_once '../config.php';
include_once '../layouts/header.php';
?>
<style>
     .btn-category {
        color: #ffffff !important;
        background-color: #B19973 !important;
    }

    .btn-category.active {
        color: #ffffff !important;
        background-color: #77684e !important;
    }
     .btn-category:hover {
    color: #ffffff !important;
        background-color: #ddc49c !important;
     }
</style>
<div class="row justify-content-center">
     <div class="col-12">
    <ul class="nav nav-pills nav-fill horitab-scroll" id="myTab" role="tablist">
            <li class="nav-item ms-1 nav-tab">
                <a class="btn-sm btn-category nav-link active" style="font-size:12px;" data-toggle="pill" href="#Order">Order</a>
            </li>
            <li class="nav-item ms-1 nav-tab">
                <a class="btn-sm btn-category nav-link" data-toggle="pill" style="font-size:12px;" href="#Profile">Profile</a>
            </li>
            <li class="nav-item ms-1 nav-tab">
                <a class="btn-sm btn-category nav-link" data-toggle="pill" style="font-size:12px;" href="#Layanan">Layanan</a>
            </li>
            <li class="nav-item ms-1 nav-tab">
                <a class="btn-sm btn-category nav-link" data-toggle="pill" style="font-size:12px;" href="#CekNick">Cek Nick</a>
            </li>
            <li class="nav-item ms-1 nav-tab">
                <a class="btn-sm btn-category nav-link" data-toggle="pill" style="font-size:12px;" href="#Mutasi">Mutasi BCA</a>
            </li>
        </ul></div>
</div>
<div class="tab-content">
<div id="Order" class="tab-pane active mb-5">
<div class="content-detached content-center">
    <div class="content-body">
        <div class="card shadow bg-dark">
            <div class="card-header">
                <h4 id="order" class="card-title">Order & Status</h4>
            </div>
            <div class="card-content collapse show" aria-expanded="true">
                <div class="card-body">
                    <div class="card-text">
                        <p>[<code>POST</code>] <?= base_url('api/order') ?></p>
                    </div>
                    <div class="table-responsive">
                        <table class="table table-striped table-dark table-bordered table-hover">
                            <thead>
                                <tr>
                                    <th>Parameter</th>
                                    <th>Type</th>
                                    <th>Value</th>
                                    <th>WAJIB</th>
                                </tr>
                            </thead>
                            <tbody>
                                <tr>
                                    <td>key</td>
                                    <td><code>string</code></td>
                                    <td>berisi apikey anda.</td>
                                    <td>IYA</td>
                                </tr>
                                <tr>
                                    <td>sign</td>
                                    <td><code>string</code></td>
                                    <td>berisi formula md5(API ID + API KEY + ORDER ID).</td>
                                    <td>IYA</td>
                                </tr>
                                <tr>
                                    <td>order_id</td>
                                    <td><code>string</code></td>
                                    <td>berisi order id dari website anda</td>
                                    <td>IYA</td>
                                </tr>
                                <tr>
                                    <td>sku</td>
                                    <td><code>string</code></td>
                                    <td>berisi kode layanan, <a href="<?= base_url('page/pricelist') ?>" target="blank">cek disini</a>.</td>
                                    <td>IYA</td>
                                </tr>
                                <tr>
                                    <td>userid</td>
                                    <td><code>string</code></td>
                                    <td>berisi data id tujuan</td>
                                    <td>IYA</td>
                                </tr>
                                <tr>
                                    <td>zoneid</td>
                                    <td><code>string</code></td>
                                    <td>berisi data zone tujuan bila ada</td>
                                    <td>TIDAK</td>
                                </tr>
                            </tbody>
                        </table>
                    </div>
                    <h4 class="mt-3">Example Response</h4>
                    <pre>
                        <code class="language-json">
<?= json_encode([
    'result' => true,
    'data' => [
            'order_id' => 'LS210121',
            'userid' => '123456781',
            'zoneid' => '1234',
            'games' => 'MOBILE LEGEND',
            'layanan' => '5 (5+0)',
            'status' => 'Waiting',
            'sn' => 'Transaksi Pending',
            'saldo' => '40021',
            'price' => '1600'
        ],'message' => 'Pesanan berhasil, pesanan akan diproses.'
], JSON_PRETTY_PRINT) ?>
                        </code>
                    </pre>
                </div>
            </div>
        </div>
    </div>
</div>
</div>
<div id="Mutasi" class="tab-pane fade mb-5">
<div class="content-detached content-center">
    <div class="content-body">
        <div class="card shadow bg-dark">
            <div class="card-header">
                <h4 id="order" class="card-title">Mutasi BCA</h4>
            </div>
            <div class="card-content collapse show" aria-expanded="true">
                <div class="card-body">
                    <div class="card-text">
                        <p>[<code>POST</code>] <?= base_url('api/mutasi') ?></p>
                    </div>
                    <div class="table-responsive">
                        <table class="table table-striped table-dark table-bordered table-hover">
                            <thead>
                                <tr>
                                    <th>Parameter</th>
                                    <th>Type</th>
                                    <th>Value</th>
                                    <th>WAJIB</th>
                                </tr>
                            </thead>
                            <tbody>
                                <tr>
                                    <td>key</td>
                                    <td><code>string</code></td>
                                    <td>berisi apikey anda.</td>
                                    <td>IYA</td>
                                </tr>
                                <tr>
                                    <td>sign</td>
                                    <td><code>string</code></td>
                                    <td>berisi formula md5(API ID + API KEY).</td>
                                    <td>IYA</td>
                                </tr>
                                <tr>
                                    <td>username</td>
                                    <td><code>string</code></td>
                                    <td>berisi user id BCA</td>
                                    <td>IYA</td>
                                </tr>
                                <tr>
                                    <td>password</td>
                                    <td><code>string</code></td>
                                    <td>berisi pin BCA</td>
                                    <td>IYA</td>
                                </tr>
                                <tr>
                                    <td>from</td>
                                    <td><code>date</code></td>
                                    <td>berisi tanggal -7 sebelum hari ini</td>
                                    <td>IYA</td>
                                </tr>
                                <tr>
                                    <td>to</td>
                                    <td><code>date</code></td>
                                    <td>berisi tanggal hari ini</td>
                                    <td>IYA</td>
                                </tr>
                            </tbody>
                        </table>
                    </div>
                    <h4 class="mt-3">Example Response</h4>
                    <pre>
                        <code class="language-json">
<?= json_encode([
    'result' => true,
    'data' => [
            [
            'date' => date('Y-m-d'),
            'description' => 'SWITCHING CR TANGGAL: 24/12 LynchStore 100,000.00',
            'amount' => '100000',
            'type' => 'CR'
            ]
        ],'message' => 'Mutasi BCA berhasil didapatkan'
], JSON_PRETTY_PRINT) ?>
                        </code>
                    </pre>
                </div>
            </div>
        </div>
    </div>
</div>
</div>
<div id="CekNick" class="tab-pane fade mb-5">
<div class="content-detached content-center">
    <div class="content-body">
        <div class="card shadow bg-dark">
            <div class="card-header">
                <h4 id="order" class="card-title">Cek Nickname</h4>
            </div>
            <div class="card-content collapse show" aria-expanded="true">
                <div class="card-body">
                    <div class="card-text">
                        <p>[<code>POST</code>] <?= base_url('api/ceknick') ?></p>
                    </div>
                    <div class="table-responsive">
                        <table class="table table-striped table-dark table-bordered table-hover">
                            <thead>
                                <tr>
                                    <th>Parameter</th>
                                    <th>Type</th>
                                    <th>Value</th>
                                    <th>WAJIB</th>
                                </tr>
                            </thead>
                            <tbody>
                                <tr>
                                    <td>key</td>
                                    <td><code>string</code></td>
                                    <td>berisi apikey anda.</td>
                                    <td>IYA</td>
                                </tr>
                                <tr>
                                    <td>name</td>
                                    <td><code>string</code></td>
                                    <td><a href="/api/nickname-code.txt">Lihat Disini</a></td>
                                    <td>IYA</td>
                                </tr>
                                <tr>
                                    <td>no</td>
                                    <td><code>string</code></td>
                                    <td>berisi userid/nomor telpon</td>
                                    <td>IYA</td>
                                </tr>
                                <tr>
                                    <td>server</td>
                                    <td><code>string</code></td>
                                    <td>berisi serverid</td>
                                    <td>TIDAK</td>
                                </tr>
                            </tbody>
                        </table>
                    </div>
                    <h4 class="mt-3">Example Response</h4>
                    <pre>
                        <code class="language-json">
<?= json_encode([
    'result' => 200,
    'data' => [
        'username' => 'LookitStore',
    ],
    'message' => 'Nickname berhasil didapatkan'
], JSON_PRETTY_PRINT) ?>
                        </code>
                    </pre>
                </div>
            </div>
        </div>
    </div>
</div>
</div>
<div id="Layanan" class="tab-pane fade mb-5">
<div class="content-detached content-center">
    <div class="content-body">
        <div class="card shadow bg-dark ">
            <div class="card-header">
                <h4 id="services" class="card-title">Layanan</h4>
                <div class="heading-elements">
                    <ul class="list-inline mb-0">
                        <li><a data-action="collapse"><i class="feather icon-chevron-down"></i></a></li>
                        <li><a data-action="expand"><i class="feather icon-maximize"></i></a></li>
                    </ul>
                </div>
            </div>
            <div class="card-content collapse show" aria-expanded="true">
                <div class="card-body">
                    <div class="card-text">
                        <p>[<code>POST</code>] <?= base_url('api/layanan') ?></p>
                    </div>
                    <div class="table-responsive">
                        <table class="table table-striped table-dark table-bordered table-hover">
                            <thead>
                                <tr>
                                    <th>Parameter</th>
                                    <th>Type</th>
                                    <th>Value</th>
                                    <th>WAJIB</th>
                                </tr>
                            </thead>
                            <tbody>
                                <tr>
                                    <td>key</td>
                                    <td><code>string</code></td>
                                    <td>berisi apikey anda.</td>
                                    <td>IYA</td>
                                </tr>
                                <tr>
                                    <td>sign</td>
                                    <td><code>string</code></td>
                                    <td>berisi formula md5(API ID + API KEY).</td>
                                    <td>IYA</td>
                                </tr>
                            </tbody>
                        </table>
                    </div>
                    <h4 class="mt-3">Example Response</h4>
                    <pre>
                        <code class="language-json">
<?= json_encode([
    'result' => true,
    'data' => [
        [
            'sku' => 'ML5',
            'games' => 'MOBILE LEGEND',
            'layanan' => '5 (5+0)',
            'price' => 1836,
            'status' => 'Normal'
        ],
    ],
    'message' => 'Daftar layanan berhasil didapatkan.'
], JSON_PRETTY_PRINT) ?>
                        </code>
                    </pre>
                </div>
            </div>
        </div>
    </div>
</div>
</div>
<div id="Profile" class="tab-pane fade mb-5">
<div class="content-detached content-center">
    <div class="content-body">
        <div class="card shadow bg-dark">
            <div class="card-header">
                <h4 id="order" class="card-title">Profile</h4>
                <div class="heading-elements">
                    <ul class="list-inline mb-0">
                        <li><a data-action="collapse"><i class="feather icon-chevron-down"></i></a></li>
                        <li><a data-action="expand"><i class="feather icon-maximize"></i></a></li>
                    </ul>
                </div>
            </div>
            <div class="card-content collapse show" aria-expanded="true">
                <div class="card-body">
                    <div class="card-text">
                        <p>[<code>POST</code>] <?= base_url('api/profile') ?></p>
                    </div>
                    <div class="table-responsive">
                        <table class="table table-striped table-dark table-bordered table-hover">
                            <thead>
                                <tr>
                                    <th>Parameter</th>
                                    <th>Type</th>
                                    <th>Value</th>
                                    <th>WAJIB</th>
                                </tr>
                            </thead>
                            <tbody>
                                <tr>
                                    <td>key</td>
                                    <td><code>string</code></td>
                                    <td>berisi apikey anda.</td>
                                    <td>IYA</td>
                                </tr>
                                <tr>
                                    <td>sign</td>
                                    <td><code>string</code></td>
                                    <td>berisi formula md5(API ID + API KEY).</td>
                                    <td>IYA</td>
                                </tr>
                            </tbody>
                        </table>
                    </div>
                    <h4 class="mt-3">Example Response</h4>
                    <pre>
                        <code class="language-json">
<?= json_encode([
    'result' => true,
    'data' => [
        'full_name' => isset($data_user) ? $data_user['name'] : 'your full name',
        'username' => isset($data_user) ? $data_user['username'] : 'lynchstore',
        'email' => isset($data_user) ? $data_user['email'] : 'cs@lynchstore.xyz',
        'phone' => isset($data_user) ? $data_user['phone'] : '628xxxxxxxxx',
        'saldo' => isset($data_user) ? (int)$data_user['saldo'] : '0',
        'level' => isset($data_user) ? $data_user['level'] : 'Member',
        'registered' => isset($data_user) ? $data_user['register_at'] : date('Y-m-d H:i:s'),
    ],
    'message' => 'Successfully got your account details.'
], JSON_PRETTY_PRINT) ?>
                        </code>
                    </pre>
                </div>
            </div>
        </div>
    </div>
</div>
</div>
<?php require '../layouts/footer.php';?>