Skip to content

Commit

Permalink
chore: update types for additional linked info (#759)
Browse files Browse the repository at this point in the history
Update types
  • Loading branch information
ntn-x2 committed Jun 15, 2023
1 parent 2e142bd commit 569b078
Show file tree
Hide file tree
Showing 2 changed files with 18 additions and 13 deletions.
10 changes: 3 additions & 7 deletions packages/type-definitions/src/runtime/dipProvider.ts
Original file line number Diff line number Diff line change
Expand Up @@ -13,15 +13,11 @@ export const calls: DefinitionsCall = {
methods: {
generate_proof: {
description:
'Generate a Merkle proof for the DIP protocol for the specified DID and public keys.',
'Generate a Merkle proof for the DIP protocol for the specified request parameters.',
params: [
{
name: 'identifier',
type: 'AccountId32',
},
{
name: 'keys',
type: 'Vec<Hash>',
name: 'request',
type: 'DipProofRequest',
},
],
type: 'Result<CompleteMerkleProof, ()>',
Expand Down
21 changes: 15 additions & 6 deletions packages/type-definitions/src/types_11000.ts
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,12 @@ import { types10900 } from './types_10900.js'
export const types11000: RegistryTypes = {
...types10900,
// DipProvider state_call
DipProofRequest: {
identifier: 'AccountId32',
keys: 'Vec<Hash>',
accounts: 'Vec<PalletDidLookupLinkableAccountLinkableAccountId>',
shouldIncludeWeb3Name: 'bool',
},
CompleteMerkleProof: {
root: 'MerkleRoot',
proof: 'MerkleProof',
Expand All @@ -26,14 +32,12 @@ export const types11000: RegistryTypes = {
RevealedLeaves: 'Vec<RevealedLeaf>',
RevealedLeaf: {
_enum: {
KeyReference: '(KeyReferenceKey, KeyReferenceValue)',
KeyDetails: '(KeyDetailsKey, KeyDetailsValue)',
DidKey: '(DidKeyMerkleKey, DidKeyMerkleValue)',
Web3Name: '(Web3NameMerkleKey, Web3NameMerkleValue)',
LinkedAccount: '(LinkedAccountMerkleKey, LinkedAccountMerkleValue)',
},
},
KeyReferenceKey: '(KeyId, KeyRelationship)',
KeyReferenceValue: 'Null',
KeyDetailsKey: 'KeyId',
KeyDetailsValue: 'DidDidDetailsDidPublicKeyDetails',
DidKeyMerkleKey: '(KeyId, KeyRelationship)',
KeyId: 'Hash',
KeyRelationship: {
_enum: {
Expand All @@ -49,4 +53,9 @@ export const types11000: RegistryTypes = {
'AssertionMethod',
],
},
DidKeyMerkleValue: 'DidDidDetailsDidPublicKeyDetails',
Web3NameMerkleKey: 'Text',
Web3NameMerkleValue: 'BlockNumber',
LinkedAccountMerkleKey: 'PalletDidLookupLinkableAccountLinkableAccountId',
LinkedAccountMerkleValue: 'Null',
}

0 comments on commit 569b078

Please sign in to comment.