Skip to main content

Protocols

Dispatch Protocols define structured response procedures with trigger-based activation, assessment questions, and supporting attachments. The module is managed by the ProtocolsController.

Protocol List

Authorization: Protocol_View policy

Displays all dispatch protocols for the department.

Creating Protocols

Authorization: Protocol_Create policy

Protocol Fields

FieldRequiredDescription
NameYesProtocol name
CodeYesProtocol code (stored uppercased)
DescriptionNoProtocol description
TextNoFull protocol text/instructions

Triggers

Protocols can have multiple triggers that determine when they activate:

Trigger FieldDescription
Trigger TypeType of trigger (from enum)
Starts OnTime-based start condition
Ends OnTime-based end condition
Call PriorityActivate for specific call priority
Call TypeActivate for specific call type

Questions & Answers

Protocols include assessment questions with weighted answers:

FieldDescription
Question TextThe assessment question
Answer OptionsMultiple-choice answers
Answer WeightsNumeric weight per answer (for scoring)
Correct AnswerDesignated correct response

Questions and answers are parsed from dynamic form fields (question_*, answerForQuestion_{q}_{a}, weightForAnswer_{q}_{a}).

File Attachments

ConstraintValue
Maximum file size30 MB
Allowed file typesjpg, jpeg, png, gif, pdf, doc, docx, ppt, pptx, pps, ppsx, odt, xls, xlsx, txt, mpg, avi, mpeg

Viewing Protocols

Authorization: Protocol_View policy + CanUserViewProtocolAsync runtime check

Displays the full protocol with text, triggers, questions, and attachments.

Deleting Protocols

Authorization: Protocol_Delete policy + CanUserModifyProtocolAsync runtime check

Dynamic Protocol Matching

The GetProtocolsForPrioType endpoint is a key API used during call creation:

  1. Receives a call priority and call type
  2. Creates a mock Call object with those parameters
  3. Runs all department protocols through IProtocolsService.ProcessTriggers
  4. Returns matching protocols as JSON

This enables the dispatch UI to dynamically suggest applicable protocols based on the call being created.

Protocol Attachments

Attachments can be downloaded individually:

  • Validates the user can view the parent protocol
  • Returns file with original content type and filename

Protocol Text API

The GetTextForProtocol endpoint returns just the protocol name and text as JSON (returns "No Protocol Text Present" if empty).

Data Endpoints

EndpointPurpose
GetProtocolFull protocol as JSON
GetProtocolsForPrioTypeMatching protocols for priority/type combo
GetProtocolAttachmentDownload attachment file
GetTextForProtocolProtocol name and text only

Interactions with Other Modules

ModuleInteraction
DispatchProtocols attached to calls; dynamic matching during call creation
TypesCall types and priorities used in trigger configuration