Intellivoid-Services-Web/src/runtime_scripts/coa_sniffles.dyn

21 lines
817 B
Plaintext

<?php
use COASniffle\Abstracts\ApplicationType;
use COASniffle\COASniffle;
use DynamicalWeb\DynamicalWeb;
/**
* This script defines the COA Application and registers the constructed objects into
* DynamicalWeb Memory Objects, this is a runtime script that is executed before anything
*/
$COASniffle = new COASniffle();
$ApplicationConfiguration = json_decode(file_get_contents(__DIR__ . DIRECTORY_SEPARATOR . 'coasniffle.json'), true);
$COASniffle->defineApplication(
$ApplicationConfiguration['PUBLIC_APPLICATION_ID'],
$ApplicationConfiguration['SECRET_KEY'],
ApplicationType::Redirect
);
DynamicalWeb::setMemoryObject('coasniffle', $COASniffle);
DynamicalWeb::setMemoryObject('application_configuration', $ApplicationConfiguration);