Files
svc-api-x/v1/taffy/snippets/Taffy/Application cfc-script.xml
T
2024-10-23 11:17:42 +03:00

49 lines
1.2 KiB
XML

<?xml version="1.0" encoding="utf-8"?>
<snippet filetemplate="false" extension="">
<name>Application cfc-script</name>
<help>Creates an Application.cfc skeleton for a Taffy API using cfscript syntax</help>
<starttext><![CDATA[component extends="taffy.core.api"
{
this.name = "]]></starttext>
<endtext><![CDATA[";
variables.framework = {
reloadKey = "reload"
,reloadPassword = "true"
,reloadOnEveryRequest = false
,defaultRepresentationClass = "taffy.core.nativeJsonRepresentation"
,dashboardKey = "dashboard"
,disableDashboard = false
,unhandledPaths = "/flex2gateway"
,allowCrossDomain = false
,globalHeaders = structNew()
,debugKey = "debug"
,returnExceptionsAsJson = true
,exceptionLogAdapter = "taffy.bonus.LogToEmail"
,exceptionLogAdapterConfig = {
emailFrom = "api-error@yourdomain.com"
,emailTo = "you@yourdomain.com"
,emailSubj = "Exception Trapped in API"
,emailType = "html"
}
,beanFactory = ""
}
function onApplicationStart()
{
return super.onApplicationStart();
}
function onRequestStart()
{
return super.onRequestStart();
}
function onTaffyRequest(verb,cfc,requestArguments,mimeExt,headers,methodMetadata)
{
}
}]]></endtext>
</snippet>