---
# System prepended metadata

title: Machine Readable Governance (rules draft)

---

# Machine Readable Governance (rules draft)
```
{
  "@context": ["https://github.com/hyperledger/aries-rfcs/blob/master/concepts/0430-machine-readable-governance-frameworks/context.jsonld"],
  "name": "Health Governance",
  "version": "0.1",
  "description": "Issuance and verification of health credentials. Provides a source of truth for current schemas, issuers, and verifiers",
  "docs_uri": "TBA",
  "data_uri": "TBA",
  "topics": ["medical"],
  "jurisdictions": ["us>ny>nyc"],
  "geos": ["USA"],
  "schemas": ["test_id", "test_result", "trusted_traveler"],
  "define": [
    {
      "name": "Government_Organization",
      "id": "update_with_did",
      "describe": {
        "label": "Government",
        "sublabel": "Full Government Organization Name",
        "website": "issuinggovernmentsite.org",
        "email": "credential_manager@issuinggovernmentsite.org"
      }
    },
    {
      "name": "Lab_Issuer",
      "id": "update_with_did",
      "describe": {
        "label": "Lab Issuer",
        "sublabel": "Full Organization Name",
        "website": "issuinglabsite.com",
        "email": "credential_manager@issuinglabsite.com"
      }
    },
    {
      "name": "Health_Verifier",
      "id": "update_with_did_please",
      "describe": {
        "label": "Health Verifier",
        "sublabel": "Verifying Org",
        "website": "verifyingorgsite.com",
        "email": "verifying_manager@verifyingorgsite.com"
      }
    }
  ], 
  "rules": [
	{"roles": ["issuer", "verifier"]},
	{"prerequisites": [
        {"name": "self_attested_identity", "uri": "TBA"},
        {"name": "test_id", "uri": "TBA"},
        {"name": "medical_exemption_record", "uri": "TBA"},
        {"name": "test_result", "uri": "TBA"},
        {"name": "health_proof", "uri": "TBA", "desease_target": [
            {"COVID-19": [
                {"health_proof_option": [
                    {"vaccine":[{
                        "type": "Moderna",
                        "doze_count": [1, 2] 
                    },
                    {
                        "type": "Pfizer",
                        "doze_count": [1, 2] 
                    },
                    {
                        "type": "Johnson and Johnson",
                        "doze_count": [1] 
                    }]},
                    {"PCR": [{
                        "positive": "false",
                        "negative_days_ago": [3]
                    }]},
                    {"exemption": [{
                        "approved_by": ["doctor", "ecclesiastical_leader", "self"],
                        "reason": ["medical", "religious", "philosophical"]
                    }]}
                ]}
            ]}
        ]},
		{"name": "trusted_traveler", "uri": "TBA"}
	]},
	{"requirements": [
		{    
            "grant": ["test_id"], 
            "when": [{"name": "Lab_Issuer", "roles": "issuer", "prerequisites": "self_attested_identity" }], 
            "thus": "issuer"
            },
		{
            "grant": ["test_result"], 
            "when": [{"name": "Lab_Issuer", "roles": "issuer", "prerequisites": ["self_attested_identity", "present test_id"]}], 
            "thus": "issuer"
            },
		{
            "grant": ["exemption"], 
            "when": [{"name": "Lab_Issuer", "roles": "issuer", "prerequisites": ["self_attested_identity", "medical_exemption_record"]}], 
            "thus": "issuer"
            },
		{
            "grant": ["vaccine credential"], 
            "when": [{"name": "Lab_Issuer", "roles": "issuer", "prerequisites": ["self_attested_identity", "test_result"]}], 
            "thus": "issuer"
            },
		{
            "grant": ["trusted_traveler"], 
            "when": [{"name": "Government_Organization", "roles": "issuer", "prerequisites": ["self_attested_identity", "health_proof"]}], 
            "thus": "issuer"
            },
		{
            "grant": ["service_approval"], 
            "when": [{"name": "Health_Verifier", "roles": "verifier", "prerequisites": ["self_attested_identity", "trusted_traveler"]}], 
            "thus": "verifier"
            }
    ]}
  ]
}
```

# Rules Draft Beautified
```
{
  "@context": [
    "https://github.com/hyperledger/aries-rfcs/blob/master/concepts/0430-machine-readable-governance-frameworks/context.jsonld"
  ],
  "name": "Health Governance",
  "version": "0.1",
  "description": "Issuance and verification of health credentials. Provides a source of truth for current schemas, issuers, and verifiers",
  "last_updated": "2021-06-10",
  "docs_uri": "need_to_create",
  "data_uri": "need_to_create",
  "schemas": [
    "test_id",
    "test_result",
    "trusted_traveler"
  ],
  "define": [
    {
      "name": "Government_Organization",
      "id": "update_with_did",
      "describe": {
        "label": "Government",
        "sublabel": "Full Government Organization Name",
        "website": "issuinggovernmentsite.org",
        "email": "credential_manager@issuinggovernmentsite.org"
      }
    },
    {
      "name": "Lab_Issuer",
      "id": "update_with_did",
      "describe": {
        "label": "Lab Issuer",
        "sublabel": "Full Organization Name",
        "website": "issuinglabsite.com",
        "email": "credential_manager@issuinglabsite.com"
      }
    },
    {
      "name": "Health_Verifier",
      "id": "update_with_did_please",
      "describe": {
        "label": "Health Verifier",
        "sublabel": "Verifying Org",
        "website": "verifyingorgsite.com",
        "email": "verifying_manager@verifyingorgsite.com"
      }
    }
  ],
  "rules": [
    {
      "roles": [
        "issuer",
        "verifier"
      ]
    },
    {
      "prerequisites": [
        {
          "name": "self_attested_identity",
          "uri": "TBA"
        },
        {
          "name": "test_id",
          "uri": "TBA"
        },
        {
          "name": "medical_exemption_record",
          "uri": "TBA"
        },
        {
          "name": "test_result",
          "uri": "TBA"
        },
        {
          "name": "health_proof",
          "uri": "TBA",
          "desease_target": [
            {
              "COVID-19": [
                {
                  "health_proof_option": [
                    {
                      "vaccine": [
                        {
                          "type": "Moderna",
                          "doze_count": [
                            1,
                            2
                          ]
                        },
                        {
                          "type": "Pfizer",
                          "doze_count": [
                            1,
                            2
                          ]
                        },
                        {
                          "type": "Johnson and Johnson",
                          "doze_count": [
                            1
                          ]
                        }
                      ]
                    },
                    {
                      "PCR": [
                        {
                          "positive": "false",
                          "negative_days_ago": [
                            3
                          ]
                        }
                      ]
                    },
                    {
                      "exemption": [
                        {
                          "approved_by": [
                            "doctor",
                            "ecclesiastical_leader",
                            "self"
                          ],
                          "reason": [
                            "medical",
                            "religious",
                            "moral"
                          ]
                        }
                      ]
                    }
                  ]
                }
              ]
            }
          ]
        },
        {
          "name": "trusted_traveler",
          "uri": "TBA"
        }
      ]
    },
    {
      "requirements": [
        {
          "grant": [
            "test_id"
          ],
          "when": [
            {
              "name": "Lab_Issuer",
              "roles": "issuer",
              "prerequisites": "self_attested_identity"
            }
          ],
          "thus": "issuer"
        },
        {
          "grant": [
            "test_result"
          ],
          "when": [
            {
              "name": "Lab_Issuer",
              "roles": "issuer",
              "prerequisites": [
                "self_attested_identity",
                "present test_id"
              ]
            }
          ],
          "thus": "issuer"
        },
        {
          "grant": [
            "exemption"
          ],
          "when": [
            {
              "name": "Lab_Issuer",
              "roles": "issuer",
              "prerequisites": [
                "self_attested_identity",
                "medical_exemption_record"
              ]
            }
          ],
          "thus": "issuer"
        },
        {
          "grant": [
            "vaccine credential"
          ],
          "when": [
            {
              "name": "Lab_Issuer",
              "roles": "issuer",
              "prerequisites": [
                "self_attested_identity",
                "test_result"
              ]
            }
          ],
          "thus": "issuer"
        },
        {
          "grant": [
            "trusted_traveler"
          ],
          "when": [
            {
              "name": "Government_Organization",
              "roles": "issuer",
              "prerequisites": [
                "self_attested_identity",
                "health_proof"
              ]
            }
          ],
          "thus": "issuer"
        },
        {
          "grant": [
            "service_approval"
          ],
          "when": [
            {
              "name": "Health_Verifier",
              "roles": "verifier",
              "prerequisites": [
                "self_attested_identity",
                "trusted_traveler"
              ]
            }
          ],
          "thus": "verifier"
        }
      ]
    }
  ]
}
```