dor-services-client 15.11.0 → 15.12.0

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.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 18ff6ef4f51e40372f52681a6bbe257c347ab020e3512dd8d64b8b760c757a3b
4
- data.tar.gz: 76eb8acbc819956390a0b60b20d88ffd62fdf698430d4b9c469daaea0b2160c9
3
+ metadata.gz: 0d25cb073f436c9dd92ecc738e8279216a84088e61d9452a4f7c81c9889e3138
4
+ data.tar.gz: 2d7db7153e6227ac47e93952ae44600fc0d7f1187127f96521bc4cdcbcd7b7a2
5
5
  SHA512:
6
- metadata.gz: d5639ed16ce0185cc344ae98459593e91bf2286223500a182242e51820041021f8ac8b2685935a0213d842084e9a955b7bc482c03e639b6568768c3f128dc318
7
- data.tar.gz: 14256c492c36a3c03975a00393325541e6a65896ee49ef2e0bfba40f283dd1e3bc56c36cd0f398b6a3851552d875f4e7edf5d5f916389fe6ccbf06c75d1915c1
6
+ metadata.gz: 59aee4af11f92713f68e2a114af9db4be1cb684fd2d06660463a57c3bf9762dccfffad527c441abfe4cf8ac6a607f010676765b1d01b2792c955216a62b23f12
7
+ data.tar.gz: 903bc3b83d1c664cd9b198e0a1985ad0e9727bb8fb50502e74faa265c7dbce3dd103e3fbc35e92a4af4617437dbcd2c70abf4dc8a6ff1248606e73a5388e70e9
data/Gemfile.lock CHANGED
@@ -1,9 +1,9 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- dor-services-client (15.11.0)
4
+ dor-services-client (15.12.0)
5
5
  activesupport (>= 7.0.0)
6
- cocina-models (~> 0.103.2)
6
+ cocina-models (~> 0.104.0)
7
7
  deprecation
8
8
  faraday (~> 2.0)
9
9
  faraday-retry
@@ -31,9 +31,9 @@ GEM
31
31
  attr_extras (7.1.0)
32
32
  base64 (0.3.0)
33
33
  benchmark (0.4.1)
34
- bigdecimal (3.2.1)
34
+ bigdecimal (3.2.2)
35
35
  byebug (12.0.0)
36
- cocina-models (0.103.2)
36
+ cocina-models (0.104.0)
37
37
  activesupport
38
38
  deprecation
39
39
  dry-struct (~> 1.0)
@@ -72,7 +72,7 @@ GEM
72
72
  dry-types (~> 1.8, >= 1.8.2)
73
73
  ice_nine (~> 0.11)
74
74
  zeitwerk (~> 2.6)
75
- dry-types (1.8.2)
75
+ dry-types (1.8.3)
76
76
  bigdecimal (~> 3.0)
77
77
  concurrent-ruby (~> 1.0)
78
78
  dry-core (~> 1.0)
@@ -87,9 +87,9 @@ GEM
87
87
  faraday-net_http (>= 2.0, < 3.5)
88
88
  json
89
89
  logger
90
- faraday-net_http (3.4.0)
90
+ faraday-net_http (3.4.1)
91
91
  net-http (>= 0.5.0)
92
- faraday-retry (2.3.1)
92
+ faraday-retry (2.3.2)
93
93
  faraday (~> 2.0)
94
94
  hashdiff (1.2.0)
95
95
  i18n (1.14.7)
@@ -139,7 +139,7 @@ GEM
139
139
  diff-lcs (>= 1.2.0, < 2.0)
140
140
  rspec-support (~> 3.13.0)
141
141
  rspec-support (3.13.4)
142
- rubocop (1.75.8)
142
+ rubocop (1.77.0)
143
143
  json (~> 2.3)
144
144
  language_server-protocol (~> 3.17.0.2)
145
145
  lint_roller (~> 1.1.0)
@@ -147,10 +147,10 @@ GEM
147
147
  parser (>= 3.3.0.2)
148
148
  rainbow (>= 2.2.2, < 4.0)
149
149
  regexp_parser (>= 2.9.3, < 3.0)
150
- rubocop-ast (>= 1.44.0, < 2.0)
150
+ rubocop-ast (>= 1.45.1, < 2.0)
151
151
  ruby-progressbar (~> 1.7)
152
152
  unicode-display_width (>= 2.4.0, < 4.0)
153
- rubocop-ast (1.44.1)
153
+ rubocop-ast (1.45.1)
154
154
  parser (>= 3.3.7.2)
155
155
  prism (~> 1.4)
156
156
  rubocop-rspec (3.6.0)
@@ -164,7 +164,7 @@ GEM
164
164
  simplecov_json_formatter (~> 0.1)
165
165
  simplecov-html (0.13.1)
166
166
  simplecov_json_formatter (0.1.4)
167
- super_diff (0.15.0)
167
+ super_diff (0.16.0)
168
168
  attr_extras (>= 6.2.4)
169
169
  diff-lcs
170
170
  patience_diff
data/README.md CHANGED
@@ -154,6 +154,9 @@ object_client.reindex
154
154
 
155
155
  # Search for administrative tags:
156
156
  Dor::Services::Client.administrative_tags.search(q: 'Project')
157
+
158
+ # Get a list of workflow templates
159
+ Dor::Services::Client.workflows.templates
157
160
  ```
158
161
 
159
162
  ## Asynchronous results
@@ -25,7 +25,7 @@ Gem::Specification.new do |spec|
25
25
  spec.required_ruby_version = '>= 3.0', '< 4'
26
26
 
27
27
  spec.add_dependency 'activesupport', '>= 7.0.0'
28
- spec.add_dependency 'cocina-models', '~> 0.103.2'
28
+ spec.add_dependency 'cocina-models', '~> 0.104.0'
29
29
  spec.add_dependency 'deprecation', '>= 0'
30
30
  spec.add_dependency 'faraday', '~> 2.0'
31
31
  spec.add_dependency 'faraday-retry'
@@ -3,7 +3,7 @@
3
3
  module Dor
4
4
  module Services
5
5
  class Client
6
- VERSION = '15.11.0'
6
+ VERSION = '15.12.0'
7
7
  end
8
8
  end
9
9
  end
@@ -0,0 +1,23 @@
1
+ # frozen_string_literal: true
2
+
3
+ module Dor
4
+ module Services
5
+ class Client
6
+ # API calls around workflows in DOR
7
+ class Workflows < VersionedService
8
+ # Retrieves a list of workflow template name
9
+ # @return [Array<String>] the list of templates
10
+ def templates
11
+ resp = connection.post do |req|
12
+ req.url "#{api_version}/workflow_templates"
13
+ req.headers['Content-Type'] = 'application/json'
14
+ req.headers['Accept'] = 'application/json'
15
+ end
16
+ raise_exception_based_on_response!(resp) unless resp.success?
17
+
18
+ JSON.parse(resp.body)
19
+ end
20
+ end
21
+ end
22
+ end
23
+ end
@@ -116,6 +116,11 @@ module Dor
116
116
  @background_job_results ||= BackgroundJobResults.new(connection: connection, version: DEFAULT_VERSION)
117
117
  end
118
118
 
119
+ # @return [Dor::Services::Client::Workflows] an instance of the `Client::Workflows` class
120
+ def workflows
121
+ @workflows ||= Workflows.new(connection: connection, version: DEFAULT_VERSION)
122
+ end
123
+
119
124
  class << self
120
125
  # @param [String] url the base url of the endpoint the client should connect to (required)
121
126
  # @param [String] token a bearer token for HTTP authentication (required)
@@ -133,7 +138,7 @@ module Dor
133
138
  self
134
139
  end
135
140
 
136
- delegate :background_job_results, :objects, :object, :virtual_objects, :administrative_tags, to: :instance
141
+ delegate :background_job_results, :objects, :object, :virtual_objects, :administrative_tags, :workflows, to: :instance
137
142
  end
138
143
 
139
144
  attr_writer :url, :token, :connection, :enable_get_retries, :logger
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: dor-services-client
3
3
  version: !ruby/object:Gem::Version
4
- version: 15.11.0
4
+ version: 15.12.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Justin Coyne
8
8
  - Michael Giarlo
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2025-06-05 00:00:00.000000000 Z
11
+ date: 2025-06-24 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: activesupport
@@ -30,14 +30,14 @@ dependencies:
30
30
  requirements:
31
31
  - - "~>"
32
32
  - !ruby/object:Gem::Version
33
- version: 0.103.2
33
+ version: 0.104.0
34
34
  type: :runtime
35
35
  prerelease: false
36
36
  version_requirements: !ruby/object:Gem::Requirement
37
37
  requirements:
38
38
  - - "~>"
39
39
  - !ruby/object:Gem::Version
40
- version: 0.103.2
40
+ version: 0.104.0
41
41
  - !ruby/object:Gem::Dependency
42
42
  name: deprecation
43
43
  requirement: !ruby/object:Gem::Requirement
@@ -248,6 +248,7 @@ files:
248
248
  - lib/dor/services/client/version.rb
249
249
  - lib/dor/services/client/versioned_service.rb
250
250
  - lib/dor/services/client/virtual_objects.rb
251
+ - lib/dor/services/client/workflows.rb
251
252
  - lib/dor/services/client/workspace.rb
252
253
  homepage: https://github.com/sul-dlss/dor-services-client
253
254
  licenses: []
@@ -270,7 +271,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
270
271
  - !ruby/object:Gem::Version
271
272
  version: '0'
272
273
  requirements: []
273
- rubygems_version: 3.6.3
274
+ rubygems_version: 3.6.2
274
275
  specification_version: 4
275
276
  summary: A client for dor-services-app
276
277
  test_files: []