gds-api-adapters 97.5.0 → 97.6.0

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: f1eb266c1aeb0bea17c497f8fc50f2c63acde3d912ac9912fee8ab5f75e98fde
4
- data.tar.gz: d77d9241107d1c03ce40eed9c590819419475f8ba0e3b1a0b544ecc29c4a755e
3
+ metadata.gz: 546bac9e86b385628f50ab89c8bc1f619fe7517f4cecea5d1ca373c1df2fe7c3
4
+ data.tar.gz: 1f51515b81f17c573cf1c69b1c15cc5dbc3e59d6af20ce48d00b3819ae7e5857
5
5
  SHA512:
6
- metadata.gz: 94266ef292952415ab4115c3725f11aacd433e26ee1c13ca21990be51c5b858d2bfa3a3857d26a311fcb60d429c7676f75331139870156348b7a6824185fe95e
7
- data.tar.gz: d4227f9e0aaa8a3ac834bf2df109b560ba00bceb9186a2221421494f0bab4f611d75bc701982d1213a47dfbde809ad47c499381b2bf204b9f162dc0164a152c4
6
+ metadata.gz: e0ffc11729c1b4a907eaa57d777c862b481bcbd64570aa0d4b2135d0d0bf012761df48afcc96527631d7bd4a4980d0c5b24a516e16d56d744ac5e8d360b927f0
7
+ data.tar.gz: 6c63c18fe23adced762bdf531ffd304d61cb3631617229bed9171052306676a1b5779453608b682e847183558db38e2a0235298b0694143825cc477cc4213a65
@@ -356,6 +356,23 @@ class GdsApi::PublishingApi < GdsApi::Base
356
356
  get_json("#{endpoint}/v2/content/#{content_id}/host-content#{query}")
357
357
  end
358
358
 
359
+ # Get a specific content item which embeds a reusable content_id
360
+ #
361
+ # @param content_id [UUID]
362
+ # @param host_content_id [UUID]
363
+ #
364
+ # publishing_api.get_host_content_item_for_content_id(
365
+ # "4b148ebc-b2bb-40db-8e48-dd8cff363ff7",
366
+ # "10d91dd1-cc9d-4c4c-9540-219ebb8d4501",
367
+ # )
368
+ #
369
+ # @return [GdsApi::Response] A response containing the content item which embeds the target.
370
+ #
371
+ # @see https://github.com/alphagov/publishing-api/blob/main/docs/api.md#get-v2contentcontent_idhost-contenthost_content_id
372
+ def get_host_content_item_for_content_id(content_id, host_content_id)
373
+ get_json("#{endpoint}/v2/content/#{content_id}/host-content/#{host_content_id}")
374
+ end
375
+
359
376
  def get_content_by_embedded_document(content_id, params = {})
360
377
  warn "GdsAPI::PublishingApi: #get_content_by_embedded_document deprecated (please use #get_host_content_for_content_id)"
361
378
  get_host_content_for_content_id(content_id, params)
@@ -1,3 +1,3 @@
1
1
  module GdsApi
2
- VERSION = "97.5.0".freeze
2
+ VERSION = "97.6.0".freeze
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: gds-api-adapters
3
3
  version: !ruby/object:Gem::Version
4
- version: 97.5.0
4
+ version: 97.6.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - GOV.UK Dev
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2024-12-03 00:00:00.000000000 Z
11
+ date: 2024-12-09 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: addressable
@@ -268,14 +268,14 @@ dependencies:
268
268
  requirements:
269
269
  - - '='
270
270
  - !ruby/object:Gem::Version
271
- version: 5.0.4
271
+ version: 5.0.5
272
272
  type: :development
273
273
  prerelease: false
274
274
  version_requirements: !ruby/object:Gem::Requirement
275
275
  requirements:
276
276
  - - '='
277
277
  - !ruby/object:Gem::Version
278
- version: 5.0.4
278
+ version: 5.0.5
279
279
  - !ruby/object:Gem::Dependency
280
280
  name: simplecov
281
281
  requirement: !ruby/object:Gem::Requirement