src/APIResponse.php
public function getResponseStructure($success = false, $payload = null, $message = '', $debug = null)
    {
        if (isset($debug)) {
            $data = [
                'success' => $success,
                'message' => $message,
                'payload' => $payload,
                'debug' => $debug
            ];
        } else {
            $data = [
                'success' => $success,
                'message' => $message,
                'payload' => $payload
            ];
        }
        return $data;
    }
public function getResponseStructure($success = false, $payload = null, $message = '', $debug = null)
    {
        if (isset($debug)) {
            $data = [
                'success' => $success,
                'message' => $message,
                'payload' => $payload,
                'debug' => $debug
            ];
        } else {
            $data = [
                'success' => $success,
                'message' => $message,
                'payload' => $payload
            ];
        }
        return $data;
    }
public function getResponseStructure ( $ success = false , $ payload = null , $ message = '' , $ debug = null ) { if ( isset ( $ debug ) ) { $ data = [ 'success' => $ success , 'message' => $ message , 'payload' => $ payload , 'debug' => $ debug ] ; } else { $ data = [ 'success' => $ success , 'message' => $ message , 'payload' => $ payload ] ; } return $ data ; }
create API structure.

@param boolean $success
@param null    $payload
@param string  $message
@param null    $debug

@return object
create API structure .