trinsic_service_clients 1.1.4229 → 1.1.5018

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. checksums.yaml +4 -4
  2. data/lib/generated/credentials/credentials_client.rb +288 -16
  3. data/lib/generated/credentials/models/agent_endpoint.rb +0 -3
  4. data/lib/generated/credentials/models/attribute_filter.rb +8 -8
  5. data/lib/generated/credentials/models/basic_message_record.rb +30 -32
  6. data/lib/generated/credentials/models/credential_contract.rb +11 -0
  7. data/lib/generated/credentials/models/credential_definition_from_schema_parameters.rb +23 -23
  8. data/lib/generated/credentials/models/credential_offer_parameters.rb +3 -1
  9. data/lib/generated/credentials/models/proof_attribute_info.rb +1 -1
  10. data/lib/generated/credentials/models/proof_predicate_info.rb +23 -23
  11. data/lib/generated/credentials/models/proof_request.rb +3 -3
  12. data/lib/generated/credentials/models/schema_record.rb +33 -35
  13. data/lib/generated/credentials/models/tenant_parameters.rb +28 -7
  14. data/lib/generated/credentials/models/verification_policy_contract.rb +11 -11
  15. data/lib/generated/credentials/models/verification_policy_revocation_requirement.rb +11 -0
  16. data/lib/generated/credentials/version.rb +1 -1
  17. data/lib/generated/provider/models/tenant_contract.rb +12 -0
  18. data/lib/generated/provider/models/tenant_parameters.rb +11 -0
  19. data/lib/generated/provider/provider_client.rb +502 -1
  20. data/lib/generated/provider/version.rb +1 -1
  21. data/lib/generated/wallet.rb +10 -9
  22. data/lib/generated/wallet/models/agent_endpoint.rb +0 -3
  23. data/lib/generated/wallet/models/credential_contract.rb +11 -0
  24. data/lib/generated/wallet/models/verification_data_policy_credential_parameters.rb +65 -0
  25. data/lib/generated/wallet/models/verification_policy_attribute_contract.rb +1 -1
  26. data/lib/generated/wallet/models/verification_policy_parameters.rb +2 -2
  27. data/lib/generated/wallet/models/{verification_policy_revocation_reqirement.rb → verification_policy_revocation_requirement.rb} +15 -4
  28. data/lib/generated/wallet/version.rb +1 -1
  29. data/lib/generated/wallet/wallet_client.rb +574 -13
  30. data/trinsic_service_clients.gemspec +1 -1
  31. metadata +8 -6
@@ -4,5 +4,5 @@
4
4
  # regenerated.
5
5
 
6
6
  module Provider
7
- VERSION = '1.1.4229'
7
+ VERSION = '1.1.5018'
8
8
  end
@@ -22,23 +22,24 @@ module Wallet
22
22
  autoload :WalletClient, 'generated/wallet/wallet_client.rb'
23
23
 
24
24
  module Models
25
- autoload :VerificationPolicyRevocationReqirement, 'generated/wallet/models/verification_policy_revocation_reqirement.rb'
26
25
  autoload :VerificationPolicyParameters, 'generated/wallet/models/verification_policy_parameters.rb'
27
- autoload :ConnectionContract, 'generated/wallet/models/connection_contract.rb'
26
+ autoload :AgentEndpoint, 'generated/wallet/models/agent_endpoint.rb'
28
27
  autoload :ProposedAttribute, 'generated/wallet/models/proposed_attribute.rb'
29
- autoload :ProofAttributeContract, 'generated/wallet/models/proof_attribute_contract.rb'
28
+ autoload :CredentialContract, 'generated/wallet/models/credential_contract.rb'
30
29
  autoload :ProposedPredicate, 'generated/wallet/models/proposed_predicate.rb'
31
- autoload :VerificationPolicyRestriction, 'generated/wallet/models/verification_policy_restriction.rb'
30
+ autoload :VerificationPolicyRestrictionAttribute, 'generated/wallet/models/verification_policy_restriction_attribute.rb'
32
31
  autoload :ProofProposal, 'generated/wallet/models/proof_proposal.rb'
33
- autoload :VerificationPolicyPredicateContract, 'generated/wallet/models/verification_policy_predicate_contract.rb'
32
+ autoload :VerificationPolicyAttributeContract, 'generated/wallet/models/verification_policy_attribute_contract.rb'
34
33
  autoload :VerificationContract, 'generated/wallet/models/verification_contract.rb'
35
- autoload :CredentialContract, 'generated/wallet/models/credential_contract.rb'
34
+ autoload :VerificationPolicyRevocationRequirement, 'generated/wallet/models/verification_policy_revocation_requirement.rb'
36
35
  autoload :VerificationPolicyCredentialParameters, 'generated/wallet/models/verification_policy_credential_parameters.rb'
37
- autoload :VerificationPolicyAttributeContract, 'generated/wallet/models/verification_policy_attribute_contract.rb'
36
+ autoload :ProofAttributeContract, 'generated/wallet/models/proof_attribute_contract.rb'
38
37
  autoload :VerificationPolicyCredentialContract, 'generated/wallet/models/verification_policy_credential_contract.rb'
39
- autoload :VerificationPolicyRestrictionAttribute, 'generated/wallet/models/verification_policy_restriction_attribute.rb'
38
+ autoload :VerificationPolicyPredicateContract, 'generated/wallet/models/verification_policy_predicate_contract.rb'
39
+ autoload :VerificationDataPolicyCredentialParameters, 'generated/wallet/models/verification_data_policy_credential_parameters.rb'
40
+ autoload :VerificationPolicyRestriction, 'generated/wallet/models/verification_policy_restriction.rb'
40
41
  autoload :CustodianWalletContract, 'generated/wallet/models/custodian_wallet_contract.rb'
41
- autoload :AgentEndpoint, 'generated/wallet/models/agent_endpoint.rb'
42
+ autoload :ConnectionContract, 'generated/wallet/models/connection_contract.rb'
42
43
  autoload :WalletParameters, 'generated/wallet/models/wallet_parameters.rb'
43
44
  end
44
45
  end
@@ -36,7 +36,6 @@ module Wallet
36
36
  did: {
37
37
  client_side_validation: true,
38
38
  required: false,
39
- read_only: true,
40
39
  serialized_name: 'did',
41
40
  type: {
42
41
  name: 'String'
@@ -45,7 +44,6 @@ module Wallet
45
44
  verkey: {
46
45
  client_side_validation: true,
47
46
  required: false,
48
- read_only: true,
49
47
  serialized_name: 'verkey',
50
48
  type: {
51
49
  name: 'Sequence',
@@ -62,7 +60,6 @@ module Wallet
62
60
  uri: {
63
61
  client_side_validation: true,
64
62
  required: false,
65
- read_only: true,
66
63
  serialized_name: 'uri',
67
64
  type: {
68
65
  name: 'String'
@@ -41,6 +41,9 @@ module Wallet
41
41
  # @return [Hash{String => String}]
42
42
  attr_accessor :values
43
43
 
44
+ # @return [String]
45
+ attr_accessor :correlation_id
46
+
44
47
 
45
48
  #
46
49
  # Mapper for CredentialContract class as Ruby Hash.
@@ -142,6 +145,14 @@ module Wallet
142
145
  }
143
146
  }
144
147
  }
148
+ },
149
+ correlation_id: {
150
+ client_side_validation: true,
151
+ required: false,
152
+ serialized_name: 'correlationId',
153
+ type: {
154
+ name: 'String'
155
+ }
145
156
  }
146
157
  }
147
158
  }
@@ -0,0 +1,65 @@
1
+ # encoding: utf-8
2
+ # Code generated by Microsoft (R) AutoRest Code Generator.
3
+ # Changes may cause incorrect behavior and will be lost if the code is
4
+ # regenerated.
5
+
6
+ module Wallet
7
+ module Models
8
+ #
9
+ # Model object.
10
+ #
11
+ #
12
+ class VerificationDataPolicyCredentialParameters
13
+ # @return [String]
14
+ attr_accessor :verification_data
15
+
16
+ # @return [Array<VerificationPolicyCredentialParameters>]
17
+ attr_accessor :parameters
18
+
19
+
20
+ #
21
+ # Mapper for VerificationDataPolicyCredentialParameters class as Ruby
22
+ # Hash.
23
+ # This will be used for serialization/deserialization.
24
+ #
25
+ def self.mapper()
26
+ {
27
+ client_side_validation: true,
28
+ required: false,
29
+ serialized_name: 'VerificationDataPolicyCredentialParameters',
30
+ type: {
31
+ name: 'Composite',
32
+ class_name: 'VerificationDataPolicyCredentialParameters',
33
+ model_properties: {
34
+ verification_data: {
35
+ client_side_validation: true,
36
+ required: false,
37
+ serialized_name: 'verificationData',
38
+ type: {
39
+ name: 'String'
40
+ }
41
+ },
42
+ parameters: {
43
+ client_side_validation: true,
44
+ required: false,
45
+ serialized_name: 'parameters',
46
+ type: {
47
+ name: 'Sequence',
48
+ element: {
49
+ client_side_validation: true,
50
+ required: false,
51
+ serialized_name: 'VerificationPolicyCredentialParametersElementType',
52
+ type: {
53
+ name: 'Composite',
54
+ class_name: 'VerificationPolicyCredentialParameters'
55
+ }
56
+ }
57
+ }
58
+ }
59
+ }
60
+ }
61
+ }
62
+ end
63
+ end
64
+ end
65
+ end
@@ -43,7 +43,7 @@ module Wallet
43
43
  },
44
44
  attribute_names: {
45
45
  client_side_validation: true,
46
- required: false,
46
+ required: true,
47
47
  serialized_name: 'attributeNames',
48
48
  type: {
49
49
  name: 'Sequence',
@@ -22,7 +22,7 @@ module Wallet
22
22
  # @return [Array<VerificationPolicyPredicateContract>]
23
23
  attr_accessor :predicates
24
24
 
25
- # @return [VerificationPolicyRevocationReqirement]
25
+ # @return [VerificationPolicyRevocationRequirement]
26
26
  attr_accessor :revocation_requirement
27
27
 
28
28
 
@@ -95,7 +95,7 @@ module Wallet
95
95
  serialized_name: 'revocationRequirement',
96
96
  type: {
97
97
  name: 'Composite',
98
- class_name: 'VerificationPolicyRevocationReqirement'
98
+ class_name: 'VerificationPolicyRevocationRequirement'
99
99
  }
100
100
  }
101
101
  }
@@ -9,23 +9,26 @@ module Wallet
9
9
  # Model object.
10
10
  #
11
11
  #
12
- class VerificationPolicyRevocationReqirement
12
+ class VerificationPolicyRevocationRequirement
13
13
  # @return [DateTime]
14
14
  attr_accessor :valid_at
15
15
 
16
+ # @return [Boolean]
17
+ attr_accessor :valid_now
18
+
16
19
 
17
20
  #
18
- # Mapper for VerificationPolicyRevocationReqirement class as Ruby Hash.
21
+ # Mapper for VerificationPolicyRevocationRequirement class as Ruby Hash.
19
22
  # This will be used for serialization/deserialization.
20
23
  #
21
24
  def self.mapper()
22
25
  {
23
26
  client_side_validation: true,
24
27
  required: false,
25
- serialized_name: 'VerificationPolicyRevocationReqirement',
28
+ serialized_name: 'VerificationPolicyRevocationRequirement',
26
29
  type: {
27
30
  name: 'Composite',
28
- class_name: 'VerificationPolicyRevocationReqirement',
31
+ class_name: 'VerificationPolicyRevocationRequirement',
29
32
  model_properties: {
30
33
  valid_at: {
31
34
  client_side_validation: true,
@@ -34,6 +37,14 @@ module Wallet
34
37
  type: {
35
38
  name: 'DateTime'
36
39
  }
40
+ },
41
+ valid_now: {
42
+ client_side_validation: true,
43
+ required: false,
44
+ serialized_name: 'validNow',
45
+ type: {
46
+ name: 'Boolean'
47
+ }
37
48
  }
38
49
  }
39
50
  }
@@ -4,5 +4,5 @@
4
4
  # regenerated.
5
5
 
6
6
  module Wallet
7
- VERSION = '1.1.4229'
7
+ VERSION = '1.1.5018'
8
8
  end
@@ -98,7 +98,7 @@ module Wallet
98
98
  # data.
99
99
  #
100
100
  # @param wallet_id [String] The wallet identifier
101
- # @param invitation [String]
101
+ # @param invitation [String] The base 64 encoded invitation
102
102
  # @param custom_headers [Hash{String => String}] A hash of custom headers that
103
103
  # will be added to the HTTP request.
104
104
  #
@@ -117,7 +117,7 @@ module Wallet
117
117
  # data.
118
118
  #
119
119
  # @param wallet_id [String] The wallet identifier
120
- # @param invitation [String]
120
+ # @param invitation [String] The base 64 encoded invitation
121
121
  # @param custom_headers [Hash{String => String}] A hash of custom headers that
122
122
  # will be added to the HTTP request.
123
123
  #
@@ -135,7 +135,7 @@ module Wallet
135
135
  # data.
136
136
  #
137
137
  # @param wallet_id [String] The wallet identifier
138
- # @param invitation [String]
138
+ # @param invitation [String] The base 64 encoded invitation
139
139
  # @param [Hash{String => String}] A hash of custom headers that will be added
140
140
  # to the HTTP request.
141
141
  #
@@ -282,6 +282,79 @@ module Wallet
282
282
  promise.execute
283
283
  end
284
284
 
285
+ #
286
+ # Delete a connection with the given identifier.
287
+ #
288
+ # @param wallet_id [String] The wallet identifier.
289
+ # @param connection_id [String] The connection identifier.
290
+ # @param custom_headers [Hash{String => String}] A hash of custom headers that
291
+ # will be added to the HTTP request.
292
+ #
293
+ #
294
+ def delete_connection(wallet_id, connection_id, custom_headers:nil)
295
+ response = delete_connection_async(wallet_id, connection_id, custom_headers:custom_headers).value!
296
+ nil
297
+ end
298
+
299
+ #
300
+ # Delete a connection with the given identifier.
301
+ #
302
+ # @param wallet_id [String] The wallet identifier.
303
+ # @param connection_id [String] The connection identifier.
304
+ # @param custom_headers [Hash{String => String}] A hash of custom headers that
305
+ # will be added to the HTTP request.
306
+ #
307
+ # @return [MsRest::HttpOperationResponse] HTTP response information.
308
+ #
309
+ def delete_connection_with_http_info(wallet_id, connection_id, custom_headers:nil)
310
+ delete_connection_async(wallet_id, connection_id, custom_headers:custom_headers).value!
311
+ end
312
+
313
+ #
314
+ # Delete a connection with the given identifier.
315
+ #
316
+ # @param wallet_id [String] The wallet identifier.
317
+ # @param connection_id [String] The connection identifier.
318
+ # @param [Hash{String => String}] A hash of custom headers that will be added
319
+ # to the HTTP request.
320
+ #
321
+ # @return [Concurrent::Promise] Promise object which holds the HTTP response.
322
+ #
323
+ def delete_connection_async(wallet_id, connection_id, custom_headers:nil)
324
+ fail ArgumentError, 'wallet_id is nil' if wallet_id.nil?
325
+ fail ArgumentError, 'connection_id is nil' if connection_id.nil?
326
+
327
+
328
+ request_headers = {}
329
+ request_headers['Content-Type'] = 'application/json; charset=utf-8'
330
+ path_template = 'api/{walletId}/connections/{connectionId}'
331
+
332
+ request_url = @base_url || self.base_url
333
+
334
+ options = {
335
+ middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]],
336
+ path_params: {'walletId' => wallet_id,'connectionId' => connection_id},
337
+ headers: request_headers.merge(custom_headers || {}),
338
+ base_url: request_url
339
+ }
340
+ promise = self.make_request_async(:delete, path_template, options)
341
+
342
+ promise = promise.then do |result|
343
+ http_response = result.response
344
+ status_code = http_response.status
345
+ response_content = http_response.body
346
+ unless status_code == 200 || status_code == 401 || status_code == 403
347
+ error_model = JSON.load(response_content)
348
+ fail MsRest::HttpOperationError.new(result.request, http_response, error_model)
349
+ end
350
+
351
+
352
+ result
353
+ end
354
+
355
+ promise.execute
356
+ end
357
+
285
358
  #
286
359
  # List all connections
287
360
  #
@@ -787,6 +860,79 @@ module Wallet
787
860
  promise.execute
788
861
  end
789
862
 
863
+ #
864
+ # Deletes the credential with the given identifier.
865
+ #
866
+ # @param wallet_id [String] The wallet identifier.
867
+ # @param credential_id [String] The credential identifier.
868
+ # @param custom_headers [Hash{String => String}] A hash of custom headers that
869
+ # will be added to the HTTP request.
870
+ #
871
+ #
872
+ def delete_credential(wallet_id, credential_id, custom_headers:nil)
873
+ response = delete_credential_async(wallet_id, credential_id, custom_headers:custom_headers).value!
874
+ nil
875
+ end
876
+
877
+ #
878
+ # Deletes the credential with the given identifier.
879
+ #
880
+ # @param wallet_id [String] The wallet identifier.
881
+ # @param credential_id [String] The credential identifier.
882
+ # @param custom_headers [Hash{String => String}] A hash of custom headers that
883
+ # will be added to the HTTP request.
884
+ #
885
+ # @return [MsRest::HttpOperationResponse] HTTP response information.
886
+ #
887
+ def delete_credential_with_http_info(wallet_id, credential_id, custom_headers:nil)
888
+ delete_credential_async(wallet_id, credential_id, custom_headers:custom_headers).value!
889
+ end
890
+
891
+ #
892
+ # Deletes the credential with the given identifier.
893
+ #
894
+ # @param wallet_id [String] The wallet identifier.
895
+ # @param credential_id [String] The credential identifier.
896
+ # @param [Hash{String => String}] A hash of custom headers that will be added
897
+ # to the HTTP request.
898
+ #
899
+ # @return [Concurrent::Promise] Promise object which holds the HTTP response.
900
+ #
901
+ def delete_credential_async(wallet_id, credential_id, custom_headers:nil)
902
+ fail ArgumentError, 'wallet_id is nil' if wallet_id.nil?
903
+ fail ArgumentError, 'credential_id is nil' if credential_id.nil?
904
+
905
+
906
+ request_headers = {}
907
+ request_headers['Content-Type'] = 'application/json; charset=utf-8'
908
+ path_template = 'api/{walletId}/credentials/{credentialId}'
909
+
910
+ request_url = @base_url || self.base_url
911
+
912
+ options = {
913
+ middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]],
914
+ path_params: {'walletId' => wallet_id,'credentialId' => credential_id},
915
+ headers: request_headers.merge(custom_headers || {}),
916
+ base_url: request_url
917
+ }
918
+ promise = self.make_request_async(:delete, path_template, options)
919
+
920
+ promise = promise.then do |result|
921
+ http_response = result.response
922
+ status_code = http_response.status
923
+ response_content = http_response.body
924
+ unless status_code == 200 || status_code == 401 || status_code == 403
925
+ error_model = JSON.load(response_content)
926
+ fail MsRest::HttpOperationError.new(result.request, http_response, error_model)
927
+ end
928
+
929
+
930
+ result
931
+ end
932
+
933
+ promise.execute
934
+ end
935
+
790
936
  #
791
937
  # Accept credential offer
792
938
  #
@@ -875,7 +1021,7 @@ module Wallet
875
1021
  # This endpoint is used to accept connectionless credential issuance.
876
1022
  #
877
1023
  # @param wallet_id [String] The wallet identifier
878
- # @param credential_data [String]
1024
+ # @param credential_data [String] The credential data as URL or base64
879
1025
  # @param custom_headers [Hash{String => String}] A hash of custom headers that
880
1026
  # will be added to the HTTP request.
881
1027
  #
@@ -895,7 +1041,7 @@ module Wallet
895
1041
  # This endpoint is used to accept connectionless credential issuance.
896
1042
  #
897
1043
  # @param wallet_id [String] The wallet identifier
898
- # @param credential_data [String]
1044
+ # @param credential_data [String] The credential data as URL or base64
899
1045
  # @param custom_headers [Hash{String => String}] A hash of custom headers that
900
1046
  # will be added to the HTTP request.
901
1047
  #
@@ -914,7 +1060,7 @@ module Wallet
914
1060
  # This endpoint is used to accept connectionless credential issuance.
915
1061
  #
916
1062
  # @param wallet_id [String] The wallet identifier
917
- # @param credential_data [String]
1063
+ # @param credential_data [String] The credential data as URL or base64
918
1064
  # @param [Hash{String => String}] A hash of custom headers that will be added
919
1065
  # to the HTTP request.
920
1066
  #
@@ -1272,6 +1418,79 @@ module Wallet
1272
1418
  promise.execute
1273
1419
  end
1274
1420
 
1421
+ #
1422
+ # Deletes the verification with the given identifier.
1423
+ #
1424
+ # @param wallet_id [String] The wallet identifier.
1425
+ # @param verification_id [String] The verification identifier.
1426
+ # @param custom_headers [Hash{String => String}] A hash of custom headers that
1427
+ # will be added to the HTTP request.
1428
+ #
1429
+ #
1430
+ def delete_verification(wallet_id, verification_id, custom_headers:nil)
1431
+ response = delete_verification_async(wallet_id, verification_id, custom_headers:custom_headers).value!
1432
+ nil
1433
+ end
1434
+
1435
+ #
1436
+ # Deletes the verification with the given identifier.
1437
+ #
1438
+ # @param wallet_id [String] The wallet identifier.
1439
+ # @param verification_id [String] The verification identifier.
1440
+ # @param custom_headers [Hash{String => String}] A hash of custom headers that
1441
+ # will be added to the HTTP request.
1442
+ #
1443
+ # @return [MsRest::HttpOperationResponse] HTTP response information.
1444
+ #
1445
+ def delete_verification_with_http_info(wallet_id, verification_id, custom_headers:nil)
1446
+ delete_verification_async(wallet_id, verification_id, custom_headers:custom_headers).value!
1447
+ end
1448
+
1449
+ #
1450
+ # Deletes the verification with the given identifier.
1451
+ #
1452
+ # @param wallet_id [String] The wallet identifier.
1453
+ # @param verification_id [String] The verification identifier.
1454
+ # @param [Hash{String => String}] A hash of custom headers that will be added
1455
+ # to the HTTP request.
1456
+ #
1457
+ # @return [Concurrent::Promise] Promise object which holds the HTTP response.
1458
+ #
1459
+ def delete_verification_async(wallet_id, verification_id, custom_headers:nil)
1460
+ fail ArgumentError, 'wallet_id is nil' if wallet_id.nil?
1461
+ fail ArgumentError, 'verification_id is nil' if verification_id.nil?
1462
+
1463
+
1464
+ request_headers = {}
1465
+ request_headers['Content-Type'] = 'application/json; charset=utf-8'
1466
+ path_template = 'api/{walletId}/verifications/{verificationId}'
1467
+
1468
+ request_url = @base_url || self.base_url
1469
+
1470
+ options = {
1471
+ middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]],
1472
+ path_params: {'walletId' => wallet_id,'verificationId' => verification_id},
1473
+ headers: request_headers.merge(custom_headers || {}),
1474
+ base_url: request_url
1475
+ }
1476
+ promise = self.make_request_async(:delete, path_template, options)
1477
+
1478
+ promise = promise.then do |result|
1479
+ http_response = result.response
1480
+ status_code = http_response.status
1481
+ response_content = http_response.body
1482
+ unless status_code == 200 || status_code == 401 || status_code == 403
1483
+ error_model = JSON.load(response_content)
1484
+ fail MsRest::HttpOperationError.new(result.request, http_response, error_model)
1485
+ end
1486
+
1487
+
1488
+ result
1489
+ end
1490
+
1491
+ promise.execute
1492
+ end
1493
+
1275
1494
  #
1276
1495
  # Submit verification using policy parameters
1277
1496
  #
@@ -1683,7 +1902,7 @@ module Wallet
1683
1902
  # Verification data can be in the form of a URL or base64 data.
1684
1903
  #
1685
1904
  # @param wallet_id [String] The wallet identifier
1686
- # @param verification_data [String]
1905
+ # @param verification_data [String] The verification
1687
1906
  # @param custom_headers [Hash{String => String}] A hash of custom headers that
1688
1907
  # will be added to the HTTP request.
1689
1908
  #
@@ -1700,7 +1919,7 @@ module Wallet
1700
1919
  # Verification data can be in the form of a URL or base64 data.
1701
1920
  #
1702
1921
  # @param wallet_id [String] The wallet identifier
1703
- # @param verification_data [String]
1922
+ # @param verification_data [String] The verification
1704
1923
  # @param custom_headers [Hash{String => String}] A hash of custom headers that
1705
1924
  # will be added to the HTTP request.
1706
1925
  #
@@ -1717,7 +1936,7 @@ module Wallet
1717
1936
  # Verification data can be in the form of a URL or base64 data.
1718
1937
  #
1719
1938
  # @param wallet_id [String] The wallet identifier
1720
- # @param verification_data [String]
1939
+ # @param verification_data [String] The verification
1721
1940
  # @param [Hash{String => String}] A hash of custom headers that will be added
1722
1941
  # to the HTTP request.
1723
1942
  #
@@ -1764,6 +1983,197 @@ module Wallet
1764
1983
  promise.execute
1765
1984
  end
1766
1985
 
1986
+ #
1987
+ # Gets the available credentials for parameters in a form of URL or proof
1988
+ # request data
1989
+ #
1990
+ # @param wallet_id [String] The wallet identifier.
1991
+ # @param verification_data [String] The verification.
1992
+ # @param custom_headers [Hash{String => String}] A hash of custom headers that
1993
+ # will be added to the HTTP request.
1994
+ #
1995
+ # @return [Array] operation results.
1996
+ #
1997
+ def get_available_credentials_for_parameters(wallet_id, verification_data, custom_headers:nil)
1998
+ response = get_available_credentials_for_parameters_async(wallet_id, verification_data, custom_headers:custom_headers).value!
1999
+ response.body unless response.nil?
2000
+ end
2001
+
2002
+ #
2003
+ # Gets the available credentials for parameters in a form of URL or proof
2004
+ # request data
2005
+ #
2006
+ # @param wallet_id [String] The wallet identifier.
2007
+ # @param verification_data [String] The verification.
2008
+ # @param custom_headers [Hash{String => String}] A hash of custom headers that
2009
+ # will be added to the HTTP request.
2010
+ #
2011
+ # @return [MsRest::HttpOperationResponse] HTTP response information.
2012
+ #
2013
+ def get_available_credentials_for_parameters_with_http_info(wallet_id, verification_data, custom_headers:nil)
2014
+ get_available_credentials_for_parameters_async(wallet_id, verification_data, custom_headers:custom_headers).value!
2015
+ end
2016
+
2017
+ #
2018
+ # Gets the available credentials for parameters in a form of URL or proof
2019
+ # request data
2020
+ #
2021
+ # @param wallet_id [String] The wallet identifier.
2022
+ # @param verification_data [String] The verification.
2023
+ # @param [Hash{String => String}] A hash of custom headers that will be added
2024
+ # to the HTTP request.
2025
+ #
2026
+ # @return [Concurrent::Promise] Promise object which holds the HTTP response.
2027
+ #
2028
+ def get_available_credentials_for_parameters_async(wallet_id, verification_data, custom_headers:nil)
2029
+ fail ArgumentError, 'wallet_id is nil' if wallet_id.nil?
2030
+ fail ArgumentError, 'verification_data is nil' if verification_data.nil?
2031
+
2032
+
2033
+ request_headers = {}
2034
+ request_headers['Content-Type'] = 'multipart/form-data'
2035
+
2036
+ # Set Form Data
2037
+ form_data = {}
2038
+ form_data['verificationData'] = verification_data unless verification_data.nil?
2039
+
2040
+ path_template = 'api/{walletId}/verifications/fromData/availableCredentials'
2041
+
2042
+ request_url = @base_url || self.base_url
2043
+
2044
+ options = {
2045
+ middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]],
2046
+ path_params: {'walletId' => wallet_id},
2047
+ headers: request_headers.merge(custom_headers || {}),
2048
+ body: URI.encode_www_form(form_data),
2049
+ base_url: request_url
2050
+ }
2051
+ promise = self.make_request_async(:post, path_template, options)
2052
+
2053
+ promise = promise.then do |result|
2054
+ http_response = result.response
2055
+ status_code = http_response.status
2056
+ response_content = http_response.body
2057
+ unless status_code == 200 || status_code == 401 || status_code == 403
2058
+ error_model = JSON.load(response_content)
2059
+ fail MsRest::HttpOperationError.new(result.request, http_response, error_model)
2060
+ end
2061
+
2062
+ # Deserialize Response
2063
+ if status_code == 200
2064
+ begin
2065
+ parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content)
2066
+ result_mapper = {
2067
+ client_side_validation: true,
2068
+ required: false,
2069
+ serialized_name: 'parsed_response',
2070
+ type: {
2071
+ name: 'Sequence',
2072
+ element: {
2073
+ client_side_validation: true,
2074
+ required: false,
2075
+ serialized_name: 'VerificationPolicyCredentialContractElementType',
2076
+ type: {
2077
+ name: 'Composite',
2078
+ class_name: 'VerificationPolicyCredentialContract'
2079
+ }
2080
+ }
2081
+ }
2082
+ }
2083
+ result.body = self.deserialize(result_mapper, parsed_response)
2084
+ rescue Exception => e
2085
+ fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result)
2086
+ end
2087
+ end
2088
+
2089
+ result
2090
+ end
2091
+
2092
+ promise.execute
2093
+ end
2094
+
2095
+ #
2096
+ # Submit verification using the provided policy parameters
2097
+ #
2098
+ # @param wallet_id [String] The wallet identifier.
2099
+ # @param body [VerificationDataPolicyCredentialParameters] The verification
2100
+ # parameters.
2101
+ # @param custom_headers [Hash{String => String}] A hash of custom headers that
2102
+ # will be added to the HTTP request.
2103
+ #
2104
+ #
2105
+ def submit_verification_for_parameters(wallet_id, body:nil, custom_headers:nil)
2106
+ response = submit_verification_for_parameters_async(wallet_id, body:body, custom_headers:custom_headers).value!
2107
+ nil
2108
+ end
2109
+
2110
+ #
2111
+ # Submit verification using the provided policy parameters
2112
+ #
2113
+ # @param wallet_id [String] The wallet identifier.
2114
+ # @param body [VerificationDataPolicyCredentialParameters] The verification
2115
+ # parameters.
2116
+ # @param custom_headers [Hash{String => String}] A hash of custom headers that
2117
+ # will be added to the HTTP request.
2118
+ #
2119
+ # @return [MsRest::HttpOperationResponse] HTTP response information.
2120
+ #
2121
+ def submit_verification_for_parameters_with_http_info(wallet_id, body:nil, custom_headers:nil)
2122
+ submit_verification_for_parameters_async(wallet_id, body:body, custom_headers:custom_headers).value!
2123
+ end
2124
+
2125
+ #
2126
+ # Submit verification using the provided policy parameters
2127
+ #
2128
+ # @param wallet_id [String] The wallet identifier.
2129
+ # @param body [VerificationDataPolicyCredentialParameters] The verification
2130
+ # parameters.
2131
+ # @param [Hash{String => String}] A hash of custom headers that will be added
2132
+ # to the HTTP request.
2133
+ #
2134
+ # @return [Concurrent::Promise] Promise object which holds the HTTP response.
2135
+ #
2136
+ def submit_verification_for_parameters_async(wallet_id, body:nil, custom_headers:nil)
2137
+ fail ArgumentError, 'wallet_id is nil' if wallet_id.nil?
2138
+
2139
+
2140
+ request_headers = {}
2141
+ request_headers['Content-Type'] = 'application/json; charset=utf-8'
2142
+
2143
+ # Serialize Request
2144
+ request_mapper = Wallet::Models::VerificationDataPolicyCredentialParameters.mapper()
2145
+ request_content = self.serialize(request_mapper, body)
2146
+ request_content = request_content != nil ? JSON.generate(request_content, quirks_mode: true) : nil
2147
+
2148
+ path_template = 'api/{walletId}/verifications/fromData'
2149
+
2150
+ request_url = @base_url || self.base_url
2151
+
2152
+ options = {
2153
+ middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]],
2154
+ path_params: {'walletId' => wallet_id},
2155
+ body: request_content,
2156
+ headers: request_headers.merge(custom_headers || {}),
2157
+ base_url: request_url
2158
+ }
2159
+ promise = self.make_request_async(:put, path_template, options)
2160
+
2161
+ promise = promise.then do |result|
2162
+ http_response = result.response
2163
+ status_code = http_response.status
2164
+ response_content = http_response.body
2165
+ unless status_code == 200 || status_code == 401 || status_code == 403
2166
+ error_model = JSON.load(response_content)
2167
+ fail MsRest::HttpOperationError.new(result.request, http_response, error_model)
2168
+ end
2169
+
2170
+
2171
+ result
2172
+ end
2173
+
2174
+ promise.execute
2175
+ end
2176
+
1767
2177
  #
1768
2178
  # List all wallets
1769
2179
  #
@@ -1954,8 +2364,9 @@ module Wallet
1954
2364
  end
1955
2365
 
1956
2366
  #
1957
- # Delete wallet by query
2367
+ # [Deprecated] Delete wallet by query
1958
2368
  #
2369
+ # Please use the DELETE /wallets/{walletId} endpoint instead.
1959
2370
  # Permanently delete all connections, credentials and verification records for
1960
2371
  # the specified wallet.
1961
2372
  #
@@ -1970,8 +2381,9 @@ module Wallet
1970
2381
  end
1971
2382
 
1972
2383
  #
1973
- # Delete wallet by query
2384
+ # [Deprecated] Delete wallet by query
1974
2385
  #
2386
+ # Please use the DELETE /wallets/{walletId} endpoint instead.
1975
2387
  # Permanently delete all connections, credentials and verification records for
1976
2388
  # the specified wallet.
1977
2389
  #
@@ -1986,8 +2398,9 @@ module Wallet
1986
2398
  end
1987
2399
 
1988
2400
  #
1989
- # Delete wallet by query
2401
+ # [Deprecated] Delete wallet by query
1990
2402
  #
2403
+ # Please use the DELETE /wallets/{walletId} endpoint instead.
1991
2404
  # Permanently delete all connections, credentials and verification records for
1992
2405
  # the specified wallet.
1993
2406
  #
@@ -2031,6 +2444,154 @@ module Wallet
2031
2444
  promise.execute
2032
2445
  end
2033
2446
 
2447
+ #
2448
+ # Delete wallet
2449
+ #
2450
+ # Permanently delete all connections, credentials and verification records for
2451
+ # the specified wallet.
2452
+ #
2453
+ # @param wallet_id [String] The wallet identifier
2454
+ # @param custom_headers [Hash{String => String}] A hash of custom headers that
2455
+ # will be added to the HTTP request.
2456
+ #
2457
+ #
2458
+ def delete_wallet(wallet_id, custom_headers:nil)
2459
+ response = delete_wallet_async(wallet_id, custom_headers:custom_headers).value!
2460
+ nil
2461
+ end
2462
+
2463
+ #
2464
+ # Delete wallet
2465
+ #
2466
+ # Permanently delete all connections, credentials and verification records for
2467
+ # the specified wallet.
2468
+ #
2469
+ # @param wallet_id [String] The wallet identifier
2470
+ # @param custom_headers [Hash{String => String}] A hash of custom headers that
2471
+ # will be added to the HTTP request.
2472
+ #
2473
+ # @return [MsRest::HttpOperationResponse] HTTP response information.
2474
+ #
2475
+ def delete_wallet_with_http_info(wallet_id, custom_headers:nil)
2476
+ delete_wallet_async(wallet_id, custom_headers:custom_headers).value!
2477
+ end
2478
+
2479
+ #
2480
+ # Delete wallet
2481
+ #
2482
+ # Permanently delete all connections, credentials and verification records for
2483
+ # the specified wallet.
2484
+ #
2485
+ # @param wallet_id [String] The wallet identifier
2486
+ # @param [Hash{String => String}] A hash of custom headers that will be added
2487
+ # to the HTTP request.
2488
+ #
2489
+ # @return [Concurrent::Promise] Promise object which holds the HTTP response.
2490
+ #
2491
+ def delete_wallet_async(wallet_id, custom_headers:nil)
2492
+ fail ArgumentError, 'wallet_id is nil' if wallet_id.nil?
2493
+
2494
+
2495
+ request_headers = {}
2496
+ request_headers['Content-Type'] = 'application/json; charset=utf-8'
2497
+ path_template = 'api/wallets/{walletId}'
2498
+
2499
+ request_url = @base_url || self.base_url
2500
+
2501
+ options = {
2502
+ middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]],
2503
+ path_params: {'walletId' => wallet_id},
2504
+ headers: request_headers.merge(custom_headers || {}),
2505
+ base_url: request_url
2506
+ }
2507
+ promise = self.make_request_async(:delete, path_template, options)
2508
+
2509
+ promise = promise.then do |result|
2510
+ http_response = result.response
2511
+ status_code = http_response.status
2512
+ response_content = http_response.body
2513
+ unless status_code == 200 || status_code == 401 || status_code == 403
2514
+ error_model = JSON.load(response_content)
2515
+ fail MsRest::HttpOperationError.new(result.request, http_response, error_model)
2516
+ end
2517
+
2518
+
2519
+ result
2520
+ end
2521
+
2522
+ promise.execute
2523
+ end
2524
+
2525
+ #
2526
+ # Health check
2527
+ #
2528
+ # Check the health of the API.
2529
+ #
2530
+ # @param custom_headers [Hash{String => String}] A hash of custom headers that
2531
+ # will be added to the HTTP request.
2532
+ #
2533
+ #
2534
+ def health(custom_headers:nil)
2535
+ response = health_async(custom_headers:custom_headers).value!
2536
+ nil
2537
+ end
2538
+
2539
+ #
2540
+ # Health check
2541
+ #
2542
+ # Check the health of the API.
2543
+ #
2544
+ # @param custom_headers [Hash{String => String}] A hash of custom headers that
2545
+ # will be added to the HTTP request.
2546
+ #
2547
+ # @return [MsRest::HttpOperationResponse] HTTP response information.
2548
+ #
2549
+ def health_with_http_info(custom_headers:nil)
2550
+ health_async(custom_headers:custom_headers).value!
2551
+ end
2552
+
2553
+ #
2554
+ # Health check
2555
+ #
2556
+ # Check the health of the API.
2557
+ #
2558
+ # @param [Hash{String => String}] A hash of custom headers that will be added
2559
+ # to the HTTP request.
2560
+ #
2561
+ # @return [Concurrent::Promise] Promise object which holds the HTTP response.
2562
+ #
2563
+ def health_async(custom_headers:nil)
2564
+
2565
+
2566
+ request_headers = {}
2567
+ request_headers['Content-Type'] = 'application/json; charset=utf-8'
2568
+ path_template = 'health'
2569
+
2570
+ request_url = @base_url || self.base_url
2571
+
2572
+ options = {
2573
+ middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]],
2574
+ headers: request_headers.merge(custom_headers || {}),
2575
+ base_url: request_url
2576
+ }
2577
+ promise = self.make_request_async(:get, path_template, options)
2578
+
2579
+ promise = promise.then do |result|
2580
+ http_response = result.response
2581
+ status_code = http_response.status
2582
+ response_content = http_response.body
2583
+ unless status_code == 200
2584
+ error_model = JSON.load(response_content)
2585
+ fail MsRest::HttpOperationError.new(result.request, http_response, error_model)
2586
+ end
2587
+
2588
+
2589
+ result
2590
+ end
2591
+
2592
+ promise.execute
2593
+ end
2594
+
2034
2595
 
2035
2596
  private
2036
2597
  #
@@ -2038,7 +2599,7 @@ module Wallet
2038
2599
  #
2039
2600
  def add_telemetry
2040
2601
  sdk_information = 'wallet'
2041
- sdk_information = "#{sdk_information}/1.1.4229"
2602
+ sdk_information = "#{sdk_information}/1.1.5018"
2042
2603
  add_user_agent_information(sdk_information)
2043
2604
  end
2044
2605
  end