<?xml version="1.0" encoding="UTF-8"?>

<configuration>
	<system.web>
		<compilation debug="false" targetFramework="4.7.2" />
		<httpRuntime targetFramework="4.7.2" requestValidationMode="2.0" />
		<webServices>
			<protocols>
				<add name="HttpPost"/>
			</protocols>
		</webServices>
	</system.web>
	<system.webServer>
		<defaultDocument>
			<files>
				<add value="FieldCall.asmx" />
			</files>
		</defaultDocument>
		<directoryBrowse enabled="false" />
        	<validation validateIntegratedModeConfiguration="false" />
	</system.webServer>
	<connectionStrings>
		<add name="MpoweredSQL" connectionString="Server=YOURHOST;Database=INSTANCE;User ID=MpoweredWeb;Password=*****" />
		<add name="MpoweredORA" connectionString="Data Source=YOURHOST:1521/INSTANCE;User ID=MpoweredWeb;Password=*****"/>
	</connectionStrings>
	<appSettings>
		<!-- Each setting in this group is required in order to process notifications -->
		<!-- IMPORTANT: After making changes to this Web.config file AND BEFORE SAVING, validate with an online validator such as: https://elmah.io/tools/config-validator/ -->
		<!-- The ba_notifications method does the Notifications checks, see the FieldCall Qref guide for more details as to how ba_notifications works. -->
		<!-- To automatically run the ba_notifications method: -->
		<!-- The ba_notifications method is most-easily run using a Windows Powerscript file (e.g. fc_notifications_runner.ps) on the Internal server containing these 5 lines: -->
		<!-- $res=Invoke-WebRequest -Uri http://localhost/Mpowered/ftws/FieldCall.asmx/ba_notifications -Method POST -Body @{log_level='0'} -->
		<!-- echo $res.StatusCode -->
		<!-- echo $res.StatusDescription -->
		<!-- echo "" -->
		<!-- echo $res.RawContent -->
		<!-- (changing the Uri parameter to match your Internal services location, of course) -->
		<!-- To get debug output from the ba_notifications method, change log_level='0' to log_level='3' in the Invoke-WebRequest line above, and run manually with Pwershell ISE --->
		<!-- Then to run automatically at a frequency (e.g. 15 min), create a Windows Task Scheduler schedule with the one Action being to run the powerscript above. -->
		<!-- If the database we are connected to is a Test database, then Notification emails are automatically watermarked as originating from TEST -->
		<add key="app-000.060" value="[your.mail.server]" /> <!-- SMTP (mail) server name -->
		<add key="app-000.070" value="25" /> <!-- SMTP (mail) server port -->
		<add key="app-000.080" value="FieldCall Error &lt;it@city.ca>" /> <!-- ALL Notifications processing failure notifications email FROM: address -->
		<add key="app-000.081" value="FieldCall &lt;noreply@city.ca>" /> <!-- Notification email FROM: address -->
		<!-- Windows Task Scheduler settings are limited, so these next 3 settings allow us to specify an operational time window (in the server's time zone) -->
		<add key="app-000.090" value="Monday,Tuesday,Wednesday,Thursday,Friday" /> <!-- Days of Week to ALLOW Notifications checks to proceed -->
		<add key="app-000.092" value="07:00" /> <!-- Time of day (24hr clock) e.g. 07:00 to START allowing Notifications checks to proceed-->
		<add key="app-000.094" value="17:00" /> <!-- Time of day (24hr clock) e.g. 17:00 to STOP allowing Notifications checks to proceed-->
		
	</appSettings>
</configuration>
