@procivis/react-native-one-core 1.41710.0 → 1.43299.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (31) hide show
  1. package/android/src/main/java/ch/procivis/one/core/DeserializeSpecific.kt +1 -1
  2. package/android/src/main/java/ch/procivis/one/core/ProcivisOneCoreModule.kt +37 -4
  3. package/android/src/main/java/ch/procivis/one/core/Serialize.kt +3 -1
  4. package/android/src/main/java/ch/procivis/one/core/SerializeSpecific.kt +13 -0
  5. package/core-sdk.json +6 -6
  6. package/dist/src/config.d.ts +3 -1
  7. package/dist/src/core.d.ts +9 -3
  8. package/dist/src/core.js +5 -0
  9. package/dist/src/credential.d.ts +6 -2
  10. package/dist/src/history.d.ts +5 -2
  11. package/dist/src/history.js +3 -0
  12. package/dist/src/identifier.d.ts +132 -0
  13. package/dist/src/identifier.js +29 -0
  14. package/dist/src/proof.d.ts +9 -4
  15. package/ios/Deserialize.swift +140 -813
  16. package/ios/EventEmitter.swift +84 -72
  17. package/ios/ProcivisOneCoreModule.m +19 -1
  18. package/ios/ProcivisOneCoreModule.swift +986 -806
  19. package/ios/ProcivisRNOneCore.xcodeproj/project.pbxproj +9 -1
  20. package/ios/RNDecoder/RNDecoder.swift +191 -0
  21. package/ios/RNDecoder/RNDecodingStorage.swift +33 -0
  22. package/ios/RNDecoder/RNKeyedDecodingContainer.swift +133 -0
  23. package/ios/RNDecoder/RNUnkeyedDecodingContainer.swift +175 -0
  24. package/ios/RNEncoder/RNAnyCodingKey.swift +31 -0
  25. package/ios/RNEncoder/RNEncoder.swift +95 -0
  26. package/ios/RNEncoder/RNKeyedEncodingContainer.swift +81 -0
  27. package/ios/RNEncoder/RNSingleValueEncodingContainer.swift +78 -0
  28. package/ios/RNEncoder/RNUnkeyedEncodingContainer.swift +84 -0
  29. package/ios/Serialize.swift +43 -613
  30. package/ios/Util.swift +35 -25
  31. package/package.json +2 -2
@@ -63,7 +63,7 @@ object DeserializeSpecific {
63
63
  },
64
64
  createdDateFrom = query.getString("createdDateFrom"),
65
65
  createdDateTo = query.getString("createdDateTo"),
66
- didId = query.getString("didId"),
66
+ identifierId = query.getString("identifierId"),
67
67
  credentialId = query.getString("credentialId"),
68
68
  credentialSchemaId = query.getString("credentialSchemaId"),
69
69
  search = historySearch(
@@ -153,6 +153,37 @@ class ProcivisOneCoreModule(reactContext: ReactApplicationContext) :
153
153
  }
154
154
  }
155
155
 
156
+ @ReactMethod
157
+ fun createIdentifier(identifierRequest: ReadableMap, promise: Promise) {
158
+ asyncCall(promise, scope) {
159
+ return@asyncCall getCore().createIdentifier(construct(identifierRequest))
160
+ }
161
+ }
162
+
163
+ @ReactMethod
164
+ fun getIdentifiers(query: ReadableMap, promise: Promise) {
165
+ asyncCall(promise, scope) {
166
+ val identifiers = getCore().listIdentifiers(construct(query))
167
+ return@asyncCall convertToRN(identifiers)
168
+ }
169
+ }
170
+
171
+ @ReactMethod
172
+ fun getIdentifier(identifierId: String, promise: Promise) {
173
+ asyncCall(promise, scope) {
174
+ val identifier = getCore().getIdentifier(identifierId)
175
+ return@asyncCall convertToRN(identifier)
176
+ }
177
+ }
178
+
179
+ @ReactMethod
180
+ fun deleteIdentifier(identifierId: String, promise: Promise) {
181
+ asyncCall(promise, scope) {
182
+ getCore().deleteIdentifier(identifierId)
183
+ return@asyncCall null
184
+ }
185
+ }
186
+
156
187
  @ReactMethod
157
188
  fun handleInvitation(
158
189
  url: String,
@@ -170,13 +201,14 @@ class ProcivisOneCoreModule(reactContext: ReactApplicationContext) :
170
201
  @ReactMethod
171
202
  fun holderAcceptCredential(
172
203
  interactionId: String,
173
- didId: String,
204
+ didId: String?,
205
+ identifierId: String?,
174
206
  keyId: String?,
175
207
  txCode: String?,
176
208
  promise: Promise
177
209
  ) {
178
210
  asyncCall(promise, scope) {
179
- getCore().holderAcceptCredential(interactionId, didId, keyId, txCode)
211
+ getCore().holderAcceptCredential(interactionId, didId, identifierId, keyId, txCode)
180
212
  return@asyncCall null
181
213
  }
182
214
  }
@@ -209,7 +241,8 @@ class ProcivisOneCoreModule(reactContext: ReactApplicationContext) :
209
241
  fun holderSubmitProof(
210
242
  interactionId: String,
211
243
  credentials: ReadableMap,
212
- didId: String,
244
+ didId: String?,
245
+ identifierId: String?,
213
246
  keyId: String?,
214
247
  promise: Promise
215
248
  ) {
@@ -220,7 +253,7 @@ class ProcivisOneCoreModule(reactContext: ReactApplicationContext) :
220
253
  val credential = entry.value as ReadableMap
221
254
  submitCredentials[entry.key] = construct(credential)
222
255
  }
223
- getCore().holderSubmitProof(interactionId, submitCredentials, didId, keyId)
256
+ getCore().holderSubmitProof(interactionId, submitCredentials, didId, identifierId, keyId)
224
257
  return@asyncCall null
225
258
  }
226
259
  }
@@ -43,7 +43,7 @@ object Serialize {
43
43
  } else if (type == Int::class.java || type == java.lang.Integer::class.java) {
44
44
  return Pair(RNType.INT, input as Int)
45
45
  } else if (type == Byte::class.java || type == java.lang.Byte::class.java) {
46
- return Pair(RNType.INT, (input as Byte).toInt())
46
+ return Pair(RNType.INT, (input as Byte).toUByte().toInt())
47
47
  } else if (type == Short::class.java || type == java.lang.Short::class.java) {
48
48
  return Pair(RNType.INT, (input as Short).toInt())
49
49
  } else if (type == Long::class.java || type == java.lang.Long::class.java) {
@@ -56,6 +56,8 @@ object Serialize {
56
56
  return Pair(RNType.STRING, (input as Char).toString())
57
57
  } else if (SerializeSpecific.Str.isCustomConversionType(input)) {
58
58
  return Pair(RNType.STRING, SerializeSpecific.Str.convertCustom(input))
59
+ } else if (SerializeSpecific.Arr.isCustomConversionType(input)) {
60
+ return Pair(RNType.ARRAY, SerializeSpecific.Arr.convertCustom(input))
59
61
  } else {
60
62
  return Pair(RNType.MAP, input)
61
63
  }
@@ -130,4 +130,17 @@ object SerializeSpecific {
130
130
  }
131
131
  }
132
132
  }
133
+
134
+ object Arr {
135
+ fun isCustomConversionType(input: Any?): Boolean {
136
+ return ByteArray::class.isInstance(input)
137
+ }
138
+
139
+ fun convertCustom(input: Any): List<*> {
140
+ if (input is ByteArray) {
141
+ return input.toList()
142
+ }
143
+ throw IllegalArgumentException("Invalid array conversion: $input")
144
+ }
145
+ }
133
146
  }
package/core-sdk.json CHANGED
@@ -1,16 +1,16 @@
1
1
  {
2
2
  "android": {
3
3
  "debug": {
4
- "url": "https://onetfstatestorage.blob.core.windows.net/core-sdk/android/41710/onecore-debug.aar",
5
- "sha1": "c07081741f81c7482148ef2d84ec85d869509563"
4
+ "url": "https://onetfstatestorage.blob.core.windows.net/core-sdk/android/43299/onecore-debug.aar",
5
+ "sha1": "e91d8516dc481aeed056e959cc400da77f4e219a"
6
6
  },
7
7
  "release": {
8
- "url": "https://onetfstatestorage.blob.core.windows.net/core-sdk/android/41710/onecore-release.aar",
9
- "sha1": "75e3b007ef873221f996b96be8bf4471b44d3919"
8
+ "url": "https://onetfstatestorage.blob.core.windows.net/core-sdk/android/43299/onecore-release.aar",
9
+ "sha1": "1bc346d9dbead545aab319eb44da27b4ea193d12"
10
10
  }
11
11
  },
12
12
  "ios": {
13
- "url": "https://onetfstatestorage.blob.core.windows.net/core-sdk/ios/41710/deploy.zip",
14
- "sha1": "938ca63f338b0539c9138808be5a4f2a7919a3c3"
13
+ "url": "https://onetfstatestorage.blob.core.windows.net/core-sdk/ios/43299/deploy.zip",
14
+ "sha1": "6514bce639ad35a283e59fd64d99ad4cd59dbb89"
15
15
  }
16
16
  }
@@ -47,6 +47,8 @@ export interface FormatCapabilities {
47
47
  datatypes: Array<DataTypeEnum | string>;
48
48
  allowedSchemaIds: string[];
49
49
  forbiddenClaimNames: string[];
50
+ issuanceIdentifierTypes: string[];
51
+ verificationIdentifierTypes: string[];
50
52
  }
51
53
  export declare enum RevocationOperationEnum {
52
54
  REVOKE = "REVOKE",
@@ -58,7 +60,7 @@ export interface RevocationCapabilities {
58
60
  export interface ConfigEntity<Capabilities> {
59
61
  enabled?: boolean;
60
62
  capabilities: Capabilities;
61
- display: string;
63
+ display: string | Record<string, string>;
62
64
  order: number;
63
65
  }
64
66
  export type ConfigEntities<Capabilities = undefined, Params = {
@@ -11,12 +11,14 @@ import { CreateProofSchemaRequest, ImportProofSchemaRequest, ProofSchema, ProofS
11
11
  import { CreateRemoteTrustEntityRequest, CreateTrustAnchorRequest, CreateTrustEntityRequest, TrustAnchor, TrustAnchorListItem, TrustAnchorListQuery, TrustEntity, TrustEntityListItem, TrustEntityListQuery, UpdateRemoteTrustEntityRequest } from "./trust";
12
12
  import { CacheType } from "./cache";
13
13
  import { CreateOrganisationRequest, UpsertOrganisationRequest } from "./organisation";
14
+ import { CreateIdentifierRequest, IdentifierDetail, IdentifierListItem, IdentifierListQuery } from "./identifier";
14
15
  export * from "./backup";
15
16
  export * from "./cache";
16
17
  export * from "./config";
17
18
  export * from "./credential";
18
19
  export * from "./credentialSchema";
19
20
  export * from "./did";
21
+ export * from "./identifier";
20
22
  export * from "./history";
21
23
  export * from "./key";
22
24
  export * from "./list";
@@ -45,12 +47,16 @@ export interface ONECore {
45
47
  generateKey(keyRequest: KeyRequest): Promise<string>;
46
48
  createDid(didRequest: DidRequest): Promise<string>;
47
49
  getDids(query: DidListQuery): Promise<ItemList<DidListItem>>;
50
+ createIdentifier(identifierRequest: CreateIdentifierRequest): Promise<string>;
51
+ getIdentifiers(query: IdentifierListQuery): Promise<ItemList<IdentifierListItem>>;
52
+ getIdentifier(identifierId: IdentifierListItem["id"]): Promise<IdentifierDetail>;
53
+ deleteIdentifier(identifierId: IdentifierListItem["id"]): Promise<void>;
48
54
  handleInvitation(url: string, organisationId: string, transport: string[] | undefined): Promise<InvitationResult>;
49
- holderAcceptCredential(interactionId: InvitationResultCredentialIssuance["interactionId"], didId: string, keyId: string | undefined, txCode: string | undefined): Promise<void>;
55
+ holderAcceptCredential(interactionId: InvitationResultCredentialIssuance["interactionId"], didId: DidListItem["id"] | undefined, identifierId: IdentifierListItem["id"] | undefined, keyId: string | undefined, txCode: string | undefined): Promise<void>;
50
56
  holderRejectCredential(interactionId: InvitationResultCredentialIssuance["interactionId"]): Promise<void>;
51
57
  getPresentationDefinition(proofId: ProofDetail["id"]): Promise<PresentationDefinition>;
52
58
  holderRejectProof(interactionId: InvitationResultProofRequest["interactionId"]): Promise<void>;
53
- holderSubmitProof(interactionId: InvitationResultProofRequest["interactionId"], credentials: Record<PresentationDefinitionRequestedCredential["id"], PresentationSubmitCredentialRequest>, didId: string, keyId: string | undefined): Promise<void>;
59
+ holderSubmitProof(interactionId: InvitationResultProofRequest["interactionId"], credentials: Record<PresentationDefinitionRequestedCredential["id"], PresentationSubmitCredentialRequest>, didId: DidListItem["id"] | undefined, identifierId: IdentifierListItem["id"] | undefined, keyId: string | undefined): Promise<void>;
54
60
  getCredentials(query: CredentialListQuery): Promise<ItemList<CredentialListItem>>;
55
61
  runTask(task: string): Promise<string>;
56
62
  checkCertificate(keyId: KeyListItem["id"], certificate: KeyCheckCertificateRequestBindingDto): Promise<void>;
@@ -122,4 +128,4 @@ export interface ONECore {
122
128
  */
123
129
  uninitialize(deleteData: boolean): Promise<void>;
124
130
  }
125
- export declare const interfaceMethodNames: readonly ["getVersion", "getConfig", "createOrganisation", "upsertOrganisation", "generateKey", "createDid", "getDids", "handleInvitation", "holderAcceptCredential", "holderRejectCredential", "getPresentationDefinition", "holderRejectProof", "holderSubmitProof", "getCredentials", "runTask", "checkCertificate", "deleteProofClaims", "getCredential", "deleteCredential", "importCredentialSchema", "getCredentialSchema", "getCredentialSchemas", "deleteCredentialSchema", "createProof", "shareProof", "shareProofSchema", "shareCredentialSchema", "getProof", "getProofs", "deleteProof", "proposeProof", "createProofSchema", "getProofSchemas", "getProofSchema", "deleteProofSchema", "importProofSchema", "checkRevocation", "createTrustAnchor", "deleteTrustAnchor", "getTrustAnchor", "getTrustAnchors", "createTrustEntity", "getTrustEntity", "getTrustEntities", "getTrustEntityByDid", "createRemoteTrustEntity", "getRemoteTrustEntity", "updateRemoteTrustEntity", "getHistory", "getHistoryEntry", "createBackup", "backupInfo", "deleteCache", "unpackBackup", "finalizeImport", "rollbackImport", "resolveJsonldContext", "uninitialize"];
131
+ export declare const interfaceMethodNames: readonly ["getVersion", "getConfig", "createOrganisation", "upsertOrganisation", "generateKey", "createDid", "getDids", "createIdentifier", "getIdentifier", "getIdentifiers", "deleteIdentifier", "handleInvitation", "holderAcceptCredential", "holderRejectCredential", "getPresentationDefinition", "holderRejectProof", "holderSubmitProof", "getCredentials", "runTask", "checkCertificate", "deleteProofClaims", "getCredential", "deleteCredential", "importCredentialSchema", "getCredentialSchema", "getCredentialSchemas", "deleteCredentialSchema", "createProof", "shareProof", "shareProofSchema", "shareCredentialSchema", "getProof", "getProofs", "deleteProof", "proposeProof", "createProofSchema", "getProofSchemas", "getProofSchema", "deleteProofSchema", "importProofSchema", "checkRevocation", "createTrustAnchor", "deleteTrustAnchor", "getTrustAnchor", "getTrustAnchors", "createTrustEntity", "getTrustEntity", "getTrustEntities", "getTrustEntityByDid", "createRemoteTrustEntity", "getRemoteTrustEntity", "updateRemoteTrustEntity", "getHistory", "getHistoryEntry", "createBackup", "backupInfo", "deleteCache", "unpackBackup", "finalizeImport", "rollbackImport", "resolveJsonldContext", "uninitialize"];
package/dist/src/core.js CHANGED
@@ -4,6 +4,7 @@ export * from "./config";
4
4
  export * from "./credential";
5
5
  export * from "./credentialSchema";
6
6
  export * from "./did";
7
+ export * from "./identifier";
7
8
  export * from "./history";
8
9
  export * from "./key";
9
10
  export * from "./list";
@@ -20,6 +21,10 @@ export const interfaceMethodNames = [
20
21
  "generateKey",
21
22
  "createDid",
22
23
  "getDids",
24
+ "createIdentifier",
25
+ "getIdentifier",
26
+ "getIdentifiers",
27
+ "deleteIdentifier",
23
28
  "handleInvitation",
24
29
  "holderAcceptCredential",
25
30
  "holderRejectCredential",
@@ -2,6 +2,7 @@ import { DataTypeEnum } from "./config";
2
2
  import { CredentialSchema } from "./credentialSchema";
3
3
  import { ListQuery, SortDirection } from "./list";
4
4
  import { DidListItem } from "./did";
5
+ import { IdentifierListItem } from "./identifier";
5
6
  export declare enum CredentialStateEnum {
6
7
  CREATED = "CREATED",
7
8
  PENDING = "PENDING",
@@ -47,20 +48,23 @@ export interface CredentialListItem {
47
48
  issuanceDate: string;
48
49
  lastModified: string;
49
50
  revocationDate?: string;
50
- issuerDid?: string;
51
+ issuerDid?: DidListItem["id"];
52
+ issuer?: IdentifierListItem["id"];
51
53
  state: CredentialStateEnum;
52
54
  schema: CredentialSchema;
53
55
  role: CredentialRoleEnum;
54
56
  suspendEndDate?: string;
55
57
  exchange: string;
56
58
  }
57
- export interface CredentialDetail extends Omit<CredentialListItem, "issuerDid"> {
59
+ export interface CredentialDetail extends Omit<CredentialListItem, "issuerDid" | "issuer"> {
58
60
  claims: Claim[];
59
61
  redirectUri?: string;
60
62
  lvvcIssuanceDate?: string;
61
63
  mdocMsoValidity?: MdocMsoValidity;
62
64
  issuerDid?: DidListItem;
65
+ issuer?: IdentifierListItem;
63
66
  holderDid?: DidListItem;
67
+ holder?: IdentifierListItem;
64
68
  }
65
69
  export interface MdocMsoValidity {
66
70
  expiration: string;
@@ -23,11 +23,14 @@ export declare enum HistoryActionEnum {
23
23
  REMOVED = "REMOVED",
24
24
  UPDATED = "UPDATED",
25
25
  REACTIVATED = "REACTIVATED",
26
- CSR_GENERATED = "CSR_GENERATED"
26
+ CSR_GENERATED = "CSR_GENERATED",
27
+ EXPIRED = "EXPIRED"
27
28
  }
28
29
  export declare enum HistoryEntityTypeEnum {
29
30
  KEY = "KEY",
30
31
  DID = "DID",
32
+ IDENTIFIER = "IDENTIFIER",
33
+ CERTIFICATE = "CERTIFICATE",
31
34
  CREDENTIAL = "CREDENTIAL",
32
35
  CREDENTIAL_SCHEMA = "CREDENTIAL_SCHEMA",
33
36
  PROOF = "PROOF",
@@ -55,7 +58,7 @@ export interface HistoryListQuery extends ListQuery {
55
58
  createdDateFrom?: string;
56
59
  /** accepts the RFC3339 format, e.g. use the {@link Date.toISOString} */
57
60
  createdDateTo?: string;
58
- didId?: string;
61
+ identifierId?: string;
59
62
  credentialId?: string;
60
63
  credentialSchemaId?: string;
61
64
  proofSchemaId?: string;
@@ -23,11 +23,14 @@ export var HistoryActionEnum;
23
23
  HistoryActionEnum["UPDATED"] = "UPDATED";
24
24
  HistoryActionEnum["REACTIVATED"] = "REACTIVATED";
25
25
  HistoryActionEnum["CSR_GENERATED"] = "CSR_GENERATED";
26
+ HistoryActionEnum["EXPIRED"] = "EXPIRED";
26
27
  })(HistoryActionEnum || (HistoryActionEnum = {}));
27
28
  export var HistoryEntityTypeEnum;
28
29
  (function (HistoryEntityTypeEnum) {
29
30
  HistoryEntityTypeEnum["KEY"] = "KEY";
30
31
  HistoryEntityTypeEnum["DID"] = "DID";
32
+ HistoryEntityTypeEnum["IDENTIFIER"] = "IDENTIFIER";
33
+ HistoryEntityTypeEnum["CERTIFICATE"] = "CERTIFICATE";
31
34
  HistoryEntityTypeEnum["CREDENTIAL"] = "CREDENTIAL";
32
35
  HistoryEntityTypeEnum["CREDENTIAL_SCHEMA"] = "CREDENTIAL_SCHEMA";
33
36
  HistoryEntityTypeEnum["PROOF"] = "PROOF";
@@ -0,0 +1,132 @@
1
+ import { DidRequestKeys, DidTypeEnum, KeyRoleEnum } from "./did";
2
+ import { KeyListItem } from "./key";
3
+ import { ListQuery, SortDirection } from "./list";
4
+ export declare enum IdentifierStateEnum {
5
+ ACTIVE = "ACTIVE",
6
+ DEACTIVATED = "DEACTIVATED"
7
+ }
8
+ export declare enum IdentifierTypeEnum {
9
+ KEY = "KEY",
10
+ DID = "DID",
11
+ CERTIFICATE = "CERTIFICATE"
12
+ }
13
+ export interface CreateIdentifierRequest {
14
+ organisationId: string;
15
+ name: string;
16
+ keyId?: KeyListItem["id"];
17
+ did?: CreateIdentifierDidRequest;
18
+ certificates?: CreateIdentifierCertificateRequest[];
19
+ }
20
+ export interface CreateIdentifierDidRequest {
21
+ name?: string;
22
+ method: string;
23
+ keys: DidRequestKeys;
24
+ params: Record<string, string>;
25
+ }
26
+ export interface CreateIdentifierCertificateRequest {
27
+ name?: string;
28
+ chain: string;
29
+ keyId: string;
30
+ }
31
+ export interface IdentifierDetail {
32
+ id: string;
33
+ createdDate: string;
34
+ lastModified: string;
35
+ name: string;
36
+ organisationId: string;
37
+ type: IdentifierTypeEnum;
38
+ isRemote: boolean;
39
+ state: IdentifierStateEnum;
40
+ did?: IdentifierDidDetail;
41
+ key?: IdentifierKeyDetail;
42
+ certificates?: IdentifierCertificateDetail[];
43
+ }
44
+ export interface IdentifierDidDetail {
45
+ id: string;
46
+ createdDate: string;
47
+ lastModified: string;
48
+ name: string;
49
+ organisationId: string;
50
+ did: string;
51
+ didType: DidTypeEnum;
52
+ didMethod: string;
53
+ keys: {
54
+ authentication: KeyListItem[];
55
+ assertionMethod: KeyListItem[];
56
+ keyAgreement: KeyListItem[];
57
+ capabilityInvocation: KeyListItem[];
58
+ capabilityDelegation: KeyListItem[];
59
+ };
60
+ deactivated: boolean;
61
+ }
62
+ export interface IdentifierKeyDetail {
63
+ id: string;
64
+ createdDate: string;
65
+ lastModified: string;
66
+ organisationId: string;
67
+ name: string;
68
+ publicKey: number[];
69
+ keyType: string;
70
+ storageType: string;
71
+ }
72
+ export interface IdentifierCertificateDetail {
73
+ id: string;
74
+ createdDate: string;
75
+ lastModified: string;
76
+ state: CertificateStateEnum;
77
+ name: string;
78
+ chain: string;
79
+ key: KeyListItem;
80
+ x509Attributes: X509Attributes;
81
+ }
82
+ export declare enum CertificateStateEnum {
83
+ NOT_YET_ACTIVE = "NOT_YET_ACTIVE",
84
+ ACTIVE = "ACTIVE",
85
+ REVOKED = "REVOKED",
86
+ EXPIRED = "EXPIRED"
87
+ }
88
+ export interface X509Attributes {
89
+ serialNumber: string;
90
+ notBefore: string;
91
+ notAfter: string;
92
+ issuer: string;
93
+ subject: string;
94
+ fingerprint: string;
95
+ extensions: X509Extension[];
96
+ }
97
+ export interface X509Extension {
98
+ oid: string;
99
+ value: string;
100
+ critical: boolean;
101
+ }
102
+ export interface IdentifierListItem {
103
+ id: string;
104
+ createdDate: string;
105
+ lastModified: string;
106
+ name: string;
107
+ type: IdentifierTypeEnum;
108
+ isRemote: boolean;
109
+ state: IdentifierStateEnum;
110
+ }
111
+ export declare enum SortableIdentifierColumnEnum {
112
+ NAME = "NAME",
113
+ CREATED_DATE = "CREATED_DATE",
114
+ TYPE = "TYPE",
115
+ STATE = "STATE"
116
+ }
117
+ export declare enum ExactIdentifierFilterColumnEnum {
118
+ NAME = "NAME"
119
+ }
120
+ export interface IdentifierListQuery extends ListQuery {
121
+ sort?: SortableIdentifierColumnEnum;
122
+ sortDirection?: SortDirection;
123
+ name?: string;
124
+ type?: IdentifierTypeEnum;
125
+ state?: IdentifierStateEnum;
126
+ exact?: ExactIdentifierFilterColumnEnum[];
127
+ didMethods?: string[];
128
+ isRemote?: boolean;
129
+ keyAlgorithms?: string[];
130
+ keyRoles?: KeyRoleEnum[];
131
+ keyStorages?: string[];
132
+ }
@@ -0,0 +1,29 @@
1
+ export var IdentifierStateEnum;
2
+ (function (IdentifierStateEnum) {
3
+ IdentifierStateEnum["ACTIVE"] = "ACTIVE";
4
+ IdentifierStateEnum["DEACTIVATED"] = "DEACTIVATED";
5
+ })(IdentifierStateEnum || (IdentifierStateEnum = {}));
6
+ export var IdentifierTypeEnum;
7
+ (function (IdentifierTypeEnum) {
8
+ IdentifierTypeEnum["KEY"] = "KEY";
9
+ IdentifierTypeEnum["DID"] = "DID";
10
+ IdentifierTypeEnum["CERTIFICATE"] = "CERTIFICATE";
11
+ })(IdentifierTypeEnum || (IdentifierTypeEnum = {}));
12
+ export var CertificateStateEnum;
13
+ (function (CertificateStateEnum) {
14
+ CertificateStateEnum["NOT_YET_ACTIVE"] = "NOT_YET_ACTIVE";
15
+ CertificateStateEnum["ACTIVE"] = "ACTIVE";
16
+ CertificateStateEnum["REVOKED"] = "REVOKED";
17
+ CertificateStateEnum["EXPIRED"] = "EXPIRED";
18
+ })(CertificateStateEnum || (CertificateStateEnum = {}));
19
+ export var SortableIdentifierColumnEnum;
20
+ (function (SortableIdentifierColumnEnum) {
21
+ SortableIdentifierColumnEnum["NAME"] = "NAME";
22
+ SortableIdentifierColumnEnum["CREATED_DATE"] = "CREATED_DATE";
23
+ SortableIdentifierColumnEnum["TYPE"] = "TYPE";
24
+ SortableIdentifierColumnEnum["STATE"] = "STATE";
25
+ })(SortableIdentifierColumnEnum || (SortableIdentifierColumnEnum = {}));
26
+ export var ExactIdentifierFilterColumnEnum;
27
+ (function (ExactIdentifierFilterColumnEnum) {
28
+ ExactIdentifierFilterColumnEnum["NAME"] = "NAME";
29
+ })(ExactIdentifierFilterColumnEnum || (ExactIdentifierFilterColumnEnum = {}));
@@ -3,6 +3,7 @@ import { CredentialSchema } from "./credentialSchema";
3
3
  import { ListQuery, SortDirection } from "./list";
4
4
  import { ProofInputClaimSchema, ProofSchemaListItem } from "./proofSchema";
5
5
  import { DidListItem } from "./did";
6
+ import { IdentifierListItem } from "./identifier";
6
7
  export declare enum ProofStateEnum {
7
8
  CREATED = "CREATED",
8
9
  PENDING = "PENDING",
@@ -35,7 +36,9 @@ export interface ProofDetail {
35
36
  role: ProofRoleEnum;
36
37
  proofSchema?: ProofSchemaListItem;
37
38
  verifierDid?: DidListItem;
39
+ verifier?: IdentifierListItem;
38
40
  holderDid?: DidListItem;
41
+ holder?: IdentifierListItem;
39
42
  exchange: string;
40
43
  transport: string;
41
44
  redirectUri?: string;
@@ -51,7 +54,8 @@ export interface ProofListItem {
51
54
  issuanceDate: string;
52
55
  requestedDate?: string;
53
56
  completedDate?: string;
54
- verifierDid?: string;
57
+ verifierDid?: DidListItem["id"];
58
+ verifier?: IdentifierListItem["id"];
55
59
  exchange: string;
56
60
  transport: string;
57
61
  state: ProofStateEnum;
@@ -60,9 +64,9 @@ export interface ProofListItem {
60
64
  retainUntilDate?: string;
61
65
  }
62
66
  export interface CreateProofRequest {
63
- proofSchemaId: string;
64
- verifierDidId?: string;
65
- verifierIdentifierId?: string;
67
+ proofSchemaId: ProofSchemaListItem["id"];
68
+ verifierDidId?: DidListItem["id"];
69
+ verifierIdentifierId?: IdentifierListItem["id"];
66
70
  exchange: string;
67
71
  redirectUri?: string;
68
72
  verifierKey?: string;
@@ -84,6 +88,7 @@ export interface ShareProofResponse {
84
88
  }
85
89
  export interface PresentationDefinition {
86
90
  requestGroups: PresentationDefinitionRequestGroup[];
91
+ credentials: CredentialDetail[];
87
92
  }
88
93
  export interface PresentationDefinitionRequestGroup {
89
94
  id: string;