Updates from osb
This commit is contained in:
parent
7cdbc3bf91
commit
853ad4562f
33
src/API.php
33
src/API.php
@ -3,12 +3,11 @@
|
|||||||
namespace Dreamscape;
|
namespace Dreamscape;
|
||||||
|
|
||||||
use Dreamscape\Response\Base;
|
use Dreamscape\Response\Base;
|
||||||
|
use Dreamscape\Response\Generic;
|
||||||
use Illuminate\Support\Arr;
|
use Illuminate\Support\Arr;
|
||||||
use Illuminate\Support\Facades\Cache;
|
use Illuminate\Support\Facades\Cache;
|
||||||
use Illuminate\Support\Facades\Log;
|
use Illuminate\Support\Facades\Log;
|
||||||
|
|
||||||
use Dreamscape\Response\Generic;
|
|
||||||
|
|
||||||
final class API
|
final class API
|
||||||
{
|
{
|
||||||
private const LOGKEY = 'API';
|
private const LOGKEY = 'API';
|
||||||
@ -19,6 +18,36 @@ final class API
|
|||||||
private string $key;
|
private string $key;
|
||||||
private string $url;
|
private string $url;
|
||||||
|
|
||||||
|
private const CUSTOMER_STATUS = [
|
||||||
|
1 => 'Active', // Account active
|
||||||
|
2 => 'Pending', // Account is waiting for email verification
|
||||||
|
3 => 'Suspended', // Account suspended, can only login and add additional credit
|
||||||
|
4 => 'Disabled', // Account disabled, no login or any other action allowed
|
||||||
|
5 => 'Terminated', // Account deleted.
|
||||||
|
];
|
||||||
|
|
||||||
|
// https://doc-reseller-api.ds.network
|
||||||
|
private const DOMAIN_STATUS = [
|
||||||
|
1 => 'Awaiting Registration',
|
||||||
|
2 => 'Registered',
|
||||||
|
3 => 'Awaiting Renewal',
|
||||||
|
4 => 'Awaiting Deleted',
|
||||||
|
5 => 'Deleted',
|
||||||
|
6 => 'Expired',
|
||||||
|
7 => 'Awaiting Transfer In',
|
||||||
|
8 => 'Awaiting Transfer Out',
|
||||||
|
9 => 'Error',
|
||||||
|
];
|
||||||
|
|
||||||
|
private const PRODUCT_STATUS = [
|
||||||
|
1 => 'Awaiting Registration',
|
||||||
|
2 => 'Registered',
|
||||||
|
3 => 'Awaiting Renewal',
|
||||||
|
4 => 'Awaiting Deleted',
|
||||||
|
5 => 'Deleted',
|
||||||
|
6 => 'Expired',
|
||||||
|
];
|
||||||
|
|
||||||
public function __construct(string $id,string $key,bool $tryprod=FALSE)
|
public function __construct(string $id,string $key,bool $tryprod=FALSE)
|
||||||
{
|
{
|
||||||
$this->url = (config('app.env') == 'local' && ! $tryprod) ? 'https://reseller-api.sandbox.ds.network' : 'https://reseller-api.ds.network';
|
$this->url = (config('app.env') == 'local' && ! $tryprod) ? 'https://reseller-api.sandbox.ds.network' : 'https://reseller-api.ds.network';
|
||||||
|
@ -9,7 +9,7 @@ use Illuminate\Support\Facades\Log;
|
|||||||
use Dreamscape\Models\{Customer,Domain};
|
use Dreamscape\Models\{Customer,Domain};
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* This parent class handles responses received from Trello
|
* This parent class handles responses received from Dreamscape
|
||||||
*
|
*
|
||||||
* @note: This class is used for events not specifically created.
|
* @note: This class is used for events not specifically created.
|
||||||
*/
|
*/
|
||||||
|
Loading…
Reference in New Issue
Block a user