Skip to content

Create by clientspec API taking random chain IDs. There should be validation for keytype EcdsaSecp256k1RecoveryMethod2020 #108

@Vishwas1

Description

@Vishwas1

Call API /create

Request Body

{
  "namespace": "testnet",
  "options": {
    "keyType": "EcdsaSecp256k1RecoveryMethod2020",
"walletAddress": "0xc75A6dE1174A2175013964Bd26Cd066D09B879e4",
"chainId": "0x2313" // Random chain id
  }
}
  • Result: This is passing
{
  "did": "did:hid:testnet:0xc75A6dE1174A2175013964Bd26Cd066D09B879e4",
  "registrationStatus": "UNREGISTRED",
  "metaData": {
    "didDocument": {
      "@context": [
        "https://www.w3.org/ns/did/v1"
      ],
      "id": "did:hid:testnet:0xc75A6dE1174A2175013964Bd26Cd066D09B879e4",
      "controller": [
        "did:hid:testnet:0xc75A6dE1174A2175013964Bd26Cd066D09B879e4"
      ],
      "alsoKnownAs": [
        "did:hid:testnet:0xc75A6dE1174A2175013964Bd26Cd066D09B879e4"
      ],
      "verificationMethod": [
        {
          "id": "did:hid:testnet:0xc75A6dE1174A2175013964Bd26Cd066D09B879e4#key-1",
          "type": "EcdsaSecp256k1RecoveryMethod2020",
          "controller": "did:hid:testnet:0xc75A6dE1174A2175013964Bd26Cd066D09B879e4",
          "blockchainAccountId": "eip155:8979:0xc75A6dE1174A2175013964Bd26Cd066D09B879e4" // this is random chainid
        }
      ],
      "authentication": [
        "did:hid:testnet:0xc75A6dE1174A2175013964Bd26Cd066D09B879e4#key-1"
      ],
      "assertionMethod": [
        "did:hid:testnet:0xc75A6dE1174A2175013964Bd26Cd066D09B879e4#key-1"
      ],
      "keyAgreement": [],
      "capabilityInvocation": [
        "did:hid:testnet:0xc75A6dE1174A2175013964Bd26Cd066D09B879e4#key-1"
      ],
      "capabilityDelegation": [
        "did:hid:testnet:0xc75A6dE1174A2175013964Bd26Cd066D09B879e4#key-1"
      ]
    }
  }
}
  • Expected: This should fail

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions