Class: GdsApi::ContentStore

Inherits:
Base
  • Object
show all
Defined in:
lib/gds_api/content_store.rb

Instance Attribute Summary

Attributes inherited from Base

#options

Instance Method Summary collapse

Methods inherited from Base

#client, #create_client, #get_list!, #initialize, #url_for_slug

Constructor Details

This class inherits a constructor from GdsApi::Base

Instance Method Details

#content_item(base_path) ⇒ Object



6
7
8
# File 'lib/gds_api/content_store.rb', line 6

def content_item(base_path)
  get_json(content_item_url(base_path))
end

#content_item!(base_path) ⇒ Object



10
11
12
# File 'lib/gds_api/content_store.rb', line 10

def content_item!(base_path)
  get_json!(content_item_url(base_path))
end

#put_content_item(base_path, payload) ⇒ Object



14
15
16
# File 'lib/gds_api/content_store.rb', line 14

def put_content_item(base_path, payload)
  put_json(content_item_url(base_path), payload)
end

#put_content_item!(base_path, payload) ⇒ Object



18
19
20
# File 'lib/gds_api/content_store.rb', line 18

def put_content_item!(base_path, payload)
  put_json!(content_item_url(base_path), payload)
end