CIPs icon indicating copy to clipboard operation
CIPs copied to clipboard

Discussion Crypto Accounts Definition

Open michaelsena opened this issue 4 years ago • 1 comments

Discussion for CIP-21. See PR for up to date spec: https://github.com/ceramicnetwork/CIP/pull/67

michaelsena avatar Jun 15 '20 22:06 michaelsena

The schema for this is a bit tricky. There is a regex that matches the key and the value of the map:

{
  "$schema": "http://json-schema.org/draft-06/schema#",
  "$ref": "#/definitions/AccountLinks",
  "definitions": {
    "AccountLinks": {
      "type": "object",
      "patternProperties": {
        "^[a-zA-Z0-9]{1,63}@[-a-zA-Z0-9]{3,16}:[-a-zA-Z0-9]{1,47}": {
            "type": "string",
            "pattern": "^ceramic:\/\/.+"
        }
      },
      "additionalProperties": false,
      "title": "AccountLinks"
    }
  }
}

oed avatar Jul 14 '20 16:07 oed