Skip to main content
PATCH
Update CoC Policy (v1<->v2 conversion rules apply)

Authorizations

apikey
string
header
required

Headers

X-Enkrypt-Policy
string
required

The code of conduct policy name

Example:

"Test CoC Policy"

Body

Either the legacy trio (policy_rules + total_rules, plus one of policy_file/policy_text) OR the v2 pair (v2_questionnaire + v2_config) must be provided. policy_file is optional in EITHER case — an archived source PDF is not v1-specific.

name
string
required

Name of the policy

Example:

"Healthcare Guidelines"

policy_rules
string

JSON string containing the policy rules

Example:

"1. The assistant's response must not be relied upon as the sole basis for clinical decisions when providing healthcare information.\n2. Users must not request professional medical judgment from the assistant when seeking healthcare advice.\n3. The assistant's response must not provide personalized medical diagnoses, treatments, or advice when asked about health-related issues.\n4. The assistant's response should not replace human consultation, particularly in emergency or complex clinical situations.\n5. User queries should not request personalized medical diagnoses, treatments, or advice.\n6. Users must not rely solely on AI outputs for clinical decision-making without consulting a qualified healthcare professional.\n7. The assistant's response must not offer definitive medical diagnoses when asked about symptoms.\n8. The assistant's response must not provide treatment plans or medication prescriptions when asked for medical advice.\n9. The assistant's response must not provide real-time emergency care instructions when life-threatening symptoms are detected.\n10. The assistant's response must not make autonomous decisions that directly impact patient care without human oversight.\n11. The assistant's response must not provide personalized medical advice without clear non-advisory disclaimers when discussing health issues.\n12. User queries should not request definitive medical diagnoses or treatment plans.\n13. Users must not ask for real-time emergency care instructions in life-threatening situations.\n14. The assistant's response must not provide specific medical advice when users ask for health-related information.\n15. Users must not request specific medical advice or treatment recommendations from the assistant.\n16. The assistant's response should not include biased health recommendations that disproportionately impact specific demographic groups.\n17. Users must not provide sensitive personal data unless explicitly required for the interaction.\n18. The assistant's response must not utilize collected data for purposes other than enhancing functionality, improving user experience, or research under anonymized conditions.\n19. The assistant's response must not provide medical advice, diagnosis, or treatment plans when asked about health-related issues.\n20. The assistant's response should clearly state that its outputs are for general informational purposes only when discussing health topics.\n21. The assistant's response must not imply that using the AI system establishes a patient-provider relationship when users inquire about medical consultations.\n22. Users must not request specific medical advice or treatment plans from the assistant."

total_rules
integer

Total number of rules in the policy

Required range: x >= 1
Example:

22

policy_file
file

Optional archived PDF of the policy document. Valid alongside either the legacy policy_rules/total_rules/policy_text trio or the v2 v2_questionnaire/v2_config pair — this field is not v1-specific.

policy_text
string | null
default:""

Optional policy text content if not provided in the file. Legacy (v1) field only.

v2_questionnaire
WizardProfile · object

The Policy Wizard questionnaire this policy was generated from. Sent as a JSON-stringified form field (parsed server-side), the same convention policy_rules already uses. Presence of this field is what marks a multipart submission as v2 — required together with v2_config in that case; omit both to submit the legacy v1 format instead.

v2_config
PolicyWizardGenerateRulesResponse · object

The full generate-rules response (enabled/disabled rules + stats) this policy stores, verbatim. Sent as a JSON-stringified form field (parsed server-side), the same convention policy_rules already uses. Required together with v2_questionnaire to submit a Policy Wizard (v2) policy via multipart.

Response

Successful Response

message
string
required
Example:

"Policy details updated successfully"

data
CoCPolicyResponseObject · object
required