{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://xcim.invalid/ietf/p1/schemas/mp.schema.json",
  "title": "P1 Message Presentation payload",
  "type": "object", "additionalProperties": false,
  "required": ["proposal_version", "object_type", "issuer", "app_id", "app_epoch", "receipt_id", "permission_id", "purpose_id", "authorization_kind", "binding_commitment", "signer_authorization_commitment", "message_profile", "message_commitment", "presentation_id", "from_domain", "dkim_domain", "iat", "exp"],
  "properties": {
    "proposal_version": {"const": "p1"}, "object_type": {"const": "message_presentation"},
    "issuer": {"$ref": "common.schema.json#/$defs/issuer"},
    "app_id": {"$ref": "common.schema.json#/$defs/app_id"},
    "app_epoch": {"$ref": "common.schema.json#/$defs/epoch"},
    "receipt_id": {"$ref": "common.schema.json#/$defs/receipt_id"},
    "permission_id": {"$ref": "common.schema.json#/$defs/permission_id"},
    "purpose_id": {"$ref": "common.schema.json#/$defs/purpose_id"},
    "authorization_kind": {"const": "explicit_consent"},
    "binding_commitment": {"$ref": "common.schema.json#/$defs/hash32"},
    "signer_authorization_commitment": {"$ref": "common.schema.json#/$defs/hash32"},
    "message_profile": {"const": "xcim-message-relaxed-p1"},
    "message_commitment": {"$ref": "common.schema.json#/$defs/hash32"},
    "presentation_id": {"$ref": "common.schema.json#/$defs/hash32"},
    "from_domain": {"$ref": "common.schema.json#/$defs/domain"},
    "dkim_domain": {"$ref": "common.schema.json#/$defs/domain"},
    "iat": {"$ref": "common.schema.json#/$defs/time"},
    "exp": {"$ref": "common.schema.json#/$defs/time"}
  },
  "$comment": "Cross-object scope/hash matching, key authority, exclusive expiry, message/DKIM checks and replay require semantic validation."
}
