Files
api/documentation/_site_rebuild_20260317/senddepartmentgoalprogressalerttest.html
T

112 lines
11 KiB
HTML

<!DOCTYPE html SYSTEM "about:legacy-compat">
<html lang="en-US" data-preset="contrast" data-primary-color="#307FFF"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"><meta charset="UTF-8"><meta name="robots" content="noindex"><meta name="built-on" content="2026-03-17T15:44:30.523975514"><title>Send a test progress alert for a department goal | Copenhagen Truck Wash API</title><script type="application/json" id="virtual-toc-data">[{"id":"endpoint","level":0,"title":"Endpoint","anchor":"#endpoint"},{"id":"operation","level":0,"title":"Operation","anchor":"#operation"},{"id":"authentication","level":0,"title":"Authentication","anchor":"#authentication"},{"id":"request-body","level":0,"title":"Request Body","anchor":"#request-body"},{"id":"responses","level":0,"title":"Responses","anchor":"#responses"}]</script><script type="application/json" id="topic-shortcuts"></script><link href="https://resources.jetbrains.com/writerside/apidoc/6.26.0-b913/app.css" rel="stylesheet"><meta name="msapplication-TileColor" content="#000000"><link rel="apple-touch-icon" sizes="180x180" href="https://jetbrains.com/apple-touch-icon.png"><link rel="icon" type="image/png" sizes="32x32" href="https://jetbrains.com/favicon-32x32.png"><link rel="icon" type="image/png" sizes="16x16" href="https://jetbrains.com/favicon-16x16.png"><meta name="msapplication-TileImage" content="https://resources.jetbrains.com/storage/ui/favicons/mstile-144x144.png"><meta name="msapplication-square70x70logo" content="https://resources.jetbrains.com/storage/ui/favicons/mstile-70x70.png"><meta name="msapplication-square150x150logo" content="https://resources.jetbrains.com/storage/ui/favicons/mstile-150x150.png"><meta name="msapplication-wide310x150logo" content="https://resources.jetbrains.com/storage/ui/favicons/mstile-310x150.png"><meta name="msapplication-square310x310logo" content="https://resources.jetbrains.com/storage/ui/favicons/mstile-310x310.png"><meta name="image" content=""><!-- Open Graph --><meta property="og:title" content="Send a test progress alert for a department goal | Copenhagen Truck Wash API"><meta property="og:description" content=""><meta property="og:image" content=""><meta property="og:site_name" content="Copenhagen Truck Wash API Help"><meta property="og:type" content="website"><meta property="og:locale" content="en_US"><meta property="og:url" content="writerside-documentation/senddepartmentgoalprogressalerttest.html"><!-- End Open Graph --><!-- Twitter Card --><meta name="twitter:card" content="summary_large_image"><meta name="twitter:site" content=""><meta name="twitter:title" content="Send a test progress alert for a department goal | Copenhagen Truck Wash API"><meta name="twitter:description" content=""><meta name="twitter:creator" content=""><meta name="twitter:image:src" content=""><!-- End Twitter Card --><!-- Schema.org WebPage --><script type="application/ld+json">{
"@context": "http://schema.org",
"@type": "WebPage",
"@id": "writerside-documentation/senddepartmentgoalprogressalerttest.html#webpage",
"url": "writerside-documentation/senddepartmentgoalprogressalerttest.html",
"name": "Send a test progress alert for a department goal | Copenhagen Truck Wash API",
"description": "",
"image": "",
"inLanguage":"en-US"
}</script><!-- End Schema.org --><!-- Schema.org WebSite --><script type="application/ld+json">{
"@type": "WebSite",
"@id": "writerside-documentation/#website",
"url": "writerside-documentation/",
"name": "Copenhagen Truck Wash API Help"
}</script><!-- End Schema.org --></head><body data-id="sendDepartmentGoalProgressAlertTest" data-main-title="Send a test progress alert for a department goal" data-article-props="{&quot;seeAlsoStyle&quot;:&quot;links&quot;}" data-template="article" data-breadcrumbs="API-Reference.topic|API Reference///Tag_Goals.topic|Goals///Tag_Goals_Page_1.topic|Goals - Page 1 of 1"><div class="wrapper"><main class="panel _main"><header class="panel__header"><div class="container"><h3>Copenhagen Truck Wash API Help</h3><div class="panel-trigger"></div></div></header><section class="panel__content"><div class="container"><article class="article" data-shortcut-switcher="inactive"><h1 data-toc="sendDepartmentGoalProgressAlertTest" id="sendDepartmentGoalProgressAlertTest.topic">Send a test progress alert for a department goal</h1><p id="-1xqvvu_2">This endpoint documentation is generated directly from <code class="code" id="-1xqvvu_8">openapi.yaml</code>.</p><section class="chapter"><h2 id="endpoint" data-toc="endpoint">Endpoint</h2><div class="code-block" data-lang="http">POST /goals/department/progress-alert/test</div></section><section class="chapter"><h2 id="operation" data-toc="operation">Operation</h2><p id="-1xqvvu_10">Operation ID: <code class="code" id="-1xqvvu_12">sendDepartmentGoalProgressAlertTest</code></p><p id="-1xqvvu_11">Sends a progress alert for a department goal to the destination defined in the goal&amp;#x27;s criteria. Permission required: `goals_department_progress_alert_test`. Access control: - The caller must be a superuser or belong to all departments targeted by the goal. Behavior: - Looks up the goal by `id`. - Rebuilds the criteria from stored JSON and attaches the goal&amp;#x27;s departments. - Renders the alert using the server-side renderer (respecting progress type/style/format and destination limits). - Sends the alert to Slack, Email, or SMS depending on `progress_alert_destination`, unless overridden.</p></section><section class="chapter"><h2 id="authentication" data-toc="authentication">Authentication</h2><p id="-1xqvvu_13">Security requirements:</p><div class="table-wrapper"><table class="wide" id="-1xqvvu_14"><thead><tr class="ijRowHead" id="-1xqvvu_15"><th id="-1xqvvu_17"><p>Scheme</p></th><th id="-1xqvvu_18"><p>Scopes</p></th></tr></thead><tbody><tr id="-1xqvvu_16"><td id="-1xqvvu_19"><p>BearerAuth</p></td><td id="-1xqvvu_20"><p>-</p></td></tr></tbody></table></div></section><section class="chapter"><h2 id="request-body" data-toc="request-body">Request Body</h2><p id="-1xqvvu_21">Required: yes.</p><p id="-1xqvvu_22">Content type: <code class="code" id="-1xqvvu_24">application/json</code></p><div class="code-block" data-lang="json">
{
&quot;properties&quot;: {
&quot;department_id&quot;: {
&quot;description&quot;: &quot;Department id to use that department's Slack webhook when destination is SLACK&quot;,
&quot;example&quot;: 3,
&quot;type&quot;: &quot;integer&quot;
},
&quot;email_to&quot;: {
&quot;description&quot;: &quot;Email recipient when destination is EMAIL&quot;,
&quot;example&quot;: &quot;tester@example.com&quot;,
&quot;format&quot;: &quot;email&quot;,
&quot;type&quot;: &quot;string&quot;
},
&quot;id&quot;: {
&quot;description&quot;: &quot;The department goal id&quot;,
&quot;example&quot;: 42,
&quot;type&quot;: &quot;integer&quot;
},
&quot;overrideDestination&quot;: {
&quot;description&quot;: &quot;Override the destination for this test&quot;,
&quot;enum&quot;: [
&quot;SLACK&quot;,
&quot;EMAIL&quot;,
&quot;SMS&quot;,
&quot;NONE&quot;
],
&quot;example&quot;: &quot;SLACK&quot;,
&quot;type&quot;: &quot;string&quot;
},
&quot;slack_webhook&quot;: {
&quot;description&quot;: &quot;Slack webhook URL when destination is SLACK&quot;,
&quot;example&quot;: &quot;https://hooks.slack.com/services/T000/B000/XXX&quot;,
&quot;type&quot;: &quot;string&quot;
},
&quot;sms_to&quot;: {
&quot;description&quot;: &quot;One or more MSISDN recipients when destination is SMS&quot;,
&quot;oneOf&quot;: [
{
&quot;description&quot;: &quot;Comma or semicolon separated list&quot;,
&quot;example&quot;: &quot;+4512345678, +4598765432&quot;,
&quot;type&quot;: &quot;string&quot;
},
{
&quot;example&quot;: [
&quot;+4512345678&quot;,
&quot;+4598765432&quot;
],
&quot;items&quot;: {
&quot;type&quot;: &quot;string&quot;
},
&quot;type&quot;: &quot;array&quot;
}
]
},
&quot;subject&quot;: {
&quot;description&quot;: &quot;Optional email subject when destination is EMAIL&quot;,
&quot;example&quot;: &quot;Dept Goal Progress Test&quot;,
&quot;type&quot;: &quot;string&quot;
}
},
&quot;required&quot;: [
&quot;id&quot;
],
&quot;type&quot;: &quot;object&quot;
}
</div></section><section class="chapter"><h2 id="responses" data-toc="responses">Responses</h2><div class="table-wrapper"><table class="wide" id="-1xqvvu_25"><thead><tr class="ijRowHead" id="-1xqvvu_28"><th id="-1xqvvu_35"><p>Status</p></th><th id="-1xqvvu_36"><p>Description</p></th><th id="-1xqvvu_37"><p>Content Types</p></th></tr></thead><tbody><tr id="-1xqvvu_29"><td id="-1xqvvu_38"><p>200</p></td><td id="-1xqvvu_39"><p>Alert sent successfully</p></td><td id="-1xqvvu_40"><p>application/json</p></td></tr><tr id="-1xqvvu_30"><td id="-1xqvvu_41"><p>400</p></td><td id="-1xqvvu_42"></td><td id="-1xqvvu_43"></td></tr><tr id="-1xqvvu_31"><td id="-1xqvvu_44"><p>401</p></td><td id="-1xqvvu_45"></td><td id="-1xqvvu_46"></td></tr><tr id="-1xqvvu_32"><td id="-1xqvvu_47"><p>403</p></td><td id="-1xqvvu_48"></td><td id="-1xqvvu_49"></td></tr><tr id="-1xqvvu_33"><td id="-1xqvvu_50"><p>404</p></td><td id="-1xqvvu_51"></td><td id="-1xqvvu_52"></td></tr><tr id="-1xqvvu_34"><td id="-1xqvvu_53"><p>500</p></td><td id="-1xqvvu_54"></td><td id="-1xqvvu_55"></td></tr></tbody></table></div><p id="-1xqvvu_26">Schema for response <code class="code" id="-1xqvvu_56">200</code> (<code class="code" id="-1xqvvu_57">application/json</code>):</p><div class="code-block" data-lang="json">
{
&quot;properties&quot;: {
&quot;destination&quot;: {
&quot;description&quot;: &quot;Final destination used&quot;,
&quot;enum&quot;: [
&quot;SLACK&quot;,
&quot;EMAIL&quot;,
&quot;SMS&quot;,
&quot;NONE&quot;
],
&quot;type&quot;: &quot;string&quot;
},
&quot;id&quot;: {
&quot;description&quot;: &quot;Goal id&quot;,
&quot;type&quot;: &quot;integer&quot;
},
&quot;message_preview&quot;: {
&quot;description&quot;: &quot;Rendered message preview&quot;,
&quot;type&quot;: &quot;string&quot;
},
&quot;provider_response&quot;: {
&quot;description&quot;: &quot;Provider-specific response or status message&quot;
},
&quot;target&quot;: {
&quot;description&quot;: &quot;The target used for delivery (email address, phone numbers, department id, or webhook)&quot;
}
},
&quot;type&quot;: &quot;object&quot;
}
</div></section><div class="last-modified">17 March 2026</div><div data-feedback-placeholder="true"></div><div class="navigation-links _bottom"><a href="deletedepartmentgoal.html" class="navigation-links__prev">Delete department goal</a><a href="tag-subusers.html" class="navigation-links__next">Subusers</a></div></article><div id="disqus_thread"></div></div></section></main></div><script src="https://resources.jetbrains.com/writerside/apidoc/6.26.0-b913/app.js"></script></body></html>