class GdsApi::PublishingApiV2
def lookup_content_id(base_path:, exclude_document_types: nil, exclude_unpublishing_types: nil, with_drafts: false)
- See: https://github.com/alphagov/publishing-api/blob/master/doc/api.md#post-lookup-by-base-path -
Returns:
-
(UUID)
- the `content_id` for the `base_path`
Parameters:
-
with_drafts
(Boolean
) -- (optional) -
exclude_unpublishing_types
(Array
) -- (optional) -
exclude_document_types
(Array
) -- (optional) -
base_path
(String
) --
def lookup_content_id(base_path:, exclude_document_types: nil, exclude_unpublishing_types: nil, with_drafts: false) lookups = lookup_content_ids( base_paths: [base_path], exclude_document_types: exclude_document_types, exclude_unpublishing_types: exclude_unpublishing_types, with_drafts: with_drafts, ) lookups[base_path] end