{% extends "base.html" %} {% block title %}Sraosha — {{ "New Contract" if mode == "create" else "Edit " + form.title }}{% endblock %} {% block head %} {% endblock %} {% block content %}
← Back

{% if mode == "create" %}New Contract{% else %}Edit {{ form.title or contract_id }}{% endif %}

{% if errors %}
{% for err in errors %}

{{ err }}

{% endfor %}
{% endif %}
{% set steps = [ (1, "General Info", "M13 16h-1v-4h-1m1-4h.01M21 12a9 9 0 11-18 0 9 9 0 0118 0z"), (2, "Data Source", "M5 12h14M5 12a2 2 0 01-2-2V6a2 2 0 012-2h14a2 2 0 012 2v4a2 2 0 01-2 2M5 12a2 2 0 00-2 2v4a2 2 0 002 2h14a2 2 0 002-2v-4a2 2 0 00-2-2"), (3, "Models & Fields","M4 7v10c0 2.21 3.582 4 8 4s8-1.79 8-4V7M4 7c0 2.21 3.582 4 8 4s8-1.79 8-4M4 7c0-2.21 3.582-4 8-4s8 1.79 8 4"), (4, "Governance", "M9 12l2 2 4-4m5.618-4.016A11.955 11.955 0 0112 2.944a11.955 11.955 0 01-8.618 3.04A12.02 12.02 0 003 9c0 5.591 3.824 10.29 9 11.622 5.176-1.332 9-6.03 9-11.622 0-1.042-.133-2.052-.382-3.016z"), (5, "Review & Create","M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2"), ] %} {% for num, label, icon in steps %} {% if num > 1 %}
{% endif %}
{{ num }}
{{ label }}
{% endfor %}

General Information

Identity, steward, and contact metadata. Link the contract to a compliance team in the Governance step.

Unique identifier for the contract

Maps to info.owner (human or org). Not the compliance team—set that under Governance.

Published in info.contact for this contract—not alert routing.

Data Source

Define the servers this contract connects to.

{% for server in form.servers %}
{% endfor %}
{% if not form.servers %}

No servers yet. Click "Add Server" to define a data source.

{% endif %}

Models & Fields

Define tables and their columns. Use auto-discover or add them manually.

{% for model in form.models %}
{% if model.fields %} {% for field in model.fields %} {% endfor %}
Field Name Type Required Unique
{% else %}
No fields yet. Click "+ Field" to add one.
{% endif %}
{% endfor %}
{% if not form.models %}

No models yet. Add one manually or use Auto-Discover.

{% endif %}

Enforcement

Configure how violations are handled.

Canonical link for compliance and rollups. Manage teams under Settings → Teams.

block = fail pipeline, warn = log and continue, log = silent

Dependencies

Map upstream table.column to local table.column for precise impact analysis.

{% for dep in form.depends_on|default([]) %}
{{ dep.contract }}
{% for m in dep.mappings|default([]) %}
{% endfor %}
{% endfor %}

Notifications

Routes for violation alerts—separate from General Info contact fields.

Reusable Slack/email channels; optional YAML overrides on the right.

Merged into x-sraosha.notify for alert routing only—not info.contact.

1 General Info

2 Data Source

3 Models & Fields

4 Governance

YAML Preview

You can edit the YAML directly above. When you submit, the YAML content takes precedence over form fields.

Cancel
{% endblock %}