contentful-management 1.8.1 → 1.9.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.
Files changed (74) hide show
  1. checksums.yaml +4 -4
  2. data/.rubocop.yml +1 -1
  3. data/CHANGELOG.md +15 -0
  4. data/README.md +209 -41
  5. data/contentful-management.gemspec +1 -1
  6. data/lib/contentful/management/asset.rb +1 -1
  7. data/lib/contentful/management/client.rb +155 -31
  8. data/lib/contentful/management/client_organization_methods_factory.rb +23 -0
  9. data/lib/contentful/management/client_personal_access_tokens_methods_factory.rb +27 -0
  10. data/lib/contentful/management/client_snapshot_methods_factory.rb +16 -6
  11. data/lib/contentful/management/client_space_membership_methods_factory.rb +15 -0
  12. data/lib/contentful/management/client_ui_extension_methods_factory.rb +15 -0
  13. data/lib/contentful/management/client_user_methods_factory.rb +27 -0
  14. data/lib/contentful/management/client_webhook_call_methods_factory.rb +30 -0
  15. data/lib/contentful/management/client_webhook_health_methods_factory.rb +27 -0
  16. data/lib/contentful/management/content_type.rb +10 -0
  17. data/lib/contentful/management/content_type_snapshot_methods_factory.rb +35 -0
  18. data/lib/contentful/management/editor_interface.rb +1 -1
  19. data/lib/contentful/management/organization.rb +20 -0
  20. data/lib/contentful/management/personal_access_token.rb +45 -0
  21. data/lib/contentful/management/request.rb +0 -1
  22. data/lib/contentful/management/resource.rb +4 -2
  23. data/lib/contentful/management/resource_builder.rb +15 -0
  24. data/lib/contentful/management/snapshot.rb +31 -20
  25. data/lib/contentful/management/space.rb +32 -10
  26. data/lib/contentful/management/space_membership.rb +43 -0
  27. data/lib/contentful/management/space_space_membership_methods_factory.rb +15 -0
  28. data/lib/contentful/management/space_ui_extension_methods_factory.rb +15 -0
  29. data/lib/contentful/management/ui_extension.rb +106 -0
  30. data/lib/contentful/management/user.rb +28 -0
  31. data/lib/contentful/management/version.rb +1 -1
  32. data/lib/contentful/management/webhook.rb +20 -0
  33. data/lib/contentful/management/webhook_call.rb +77 -0
  34. data/lib/contentful/management/webhook_health.rb +79 -0
  35. data/lib/contentful/management/webhook_webhook_call_methods_factory.rb +30 -0
  36. data/lib/contentful/management/webhook_webhook_health_methods_factory.rb +28 -0
  37. data/spec/fixtures/vcr_cassettes/get_request.yml +34 -17
  38. data/spec/fixtures/vcr_cassettes/organization/all.yml +100 -0
  39. data/spec/fixtures/vcr_cassettes/personal_access_token/all.yml +101 -0
  40. data/spec/fixtures/vcr_cassettes/personal_access_token/create.yml +94 -0
  41. data/spec/fixtures/vcr_cassettes/personal_access_token/find.yml +91 -0
  42. data/spec/fixtures/vcr_cassettes/personal_access_token/find_not_found.yml +88 -0
  43. data/spec/fixtures/vcr_cassettes/personal_access_token/revoke.yml +179 -0
  44. data/spec/fixtures/vcr_cassettes/snapshot/ct_all.yml +207 -0
  45. data/spec/fixtures/vcr_cassettes/snapshot/ct_find.yml +198 -0
  46. data/spec/fixtures/vcr_cassettes/snapshot/ct_find_not_found.yml +94 -0
  47. data/spec/fixtures/vcr_cassettes/space/all_disabled_cache.yml +428 -0
  48. data/spec/fixtures/vcr_cassettes/space/disabled_cache.yml +120 -0
  49. data/spec/fixtures/vcr_cassettes/space_memberships/all.yml +190 -0
  50. data/spec/fixtures/vcr_cassettes/space_memberships/create.yml +143 -0
  51. data/spec/fixtures/vcr_cassettes/space_memberships/delete.yml +322 -0
  52. data/spec/fixtures/vcr_cassettes/space_memberships/find.yml +141 -0
  53. data/spec/fixtures/vcr_cassettes/ui_extension/all.yml +1020 -0
  54. data/spec/fixtures/vcr_cassettes/ui_extension/create.yml +133 -0
  55. data/spec/fixtures/vcr_cassettes/ui_extension/delete.yml +291 -0
  56. data/spec/fixtures/vcr_cassettes/ui_extension/find.yml +126 -0
  57. data/spec/fixtures/vcr_cassettes/user/find.yml +96 -0
  58. data/spec/fixtures/vcr_cassettes/webhook_call/all.yml +151 -0
  59. data/spec/fixtures/vcr_cassettes/webhook_call/find.yml +88 -0
  60. data/spec/fixtures/vcr_cassettes/webhook_call/find_not_found.yml +93 -0
  61. data/spec/fixtures/vcr_cassettes/webhook_health/find.yml +111 -0
  62. data/spec/lib/contentful/management/client_spec.rb +25 -26
  63. data/spec/lib/contentful/management/entry_spec.rb +48 -48
  64. data/spec/lib/contentful/management/organization_spec.rb +33 -0
  65. data/spec/lib/contentful/management/personal_access_token_spec.rb +85 -0
  66. data/spec/lib/contentful/management/snapshot_spec.rb +134 -47
  67. data/spec/lib/contentful/management/space_membership_spec.rb +147 -0
  68. data/spec/lib/contentful/management/space_spec.rb +35 -1
  69. data/spec/lib/contentful/management/ui_extension_spec.rb +276 -0
  70. data/spec/lib/contentful/management/user_spec.rb +52 -0
  71. data/spec/lib/contentful/management/webhook_calls_spec.rb +69 -0
  72. data/spec/lib/contentful/management/webhook_health_spec.rb +51 -0
  73. metadata +88 -8
  74. data/lib/contentful/management/http_client.rb +0 -89
@@ -0,0 +1,15 @@
1
+ require_relative 'client_association_methods_factory'
2
+
3
+ module Contentful
4
+ module Management
5
+ # Wrapper for Space Membership API for usage from within Client
6
+ # @private
7
+ class ClientSpaceMembershipMethodsFactory
8
+ include Contentful::Management::ClientAssociationMethodsFactory
9
+
10
+ def new(*)
11
+ fail 'Not supported'
12
+ end
13
+ end
14
+ end
15
+ end
@@ -0,0 +1,15 @@
1
+ require_relative 'client_association_methods_factory'
2
+
3
+ module Contentful
4
+ module Management
5
+ # Wrapper for UI Extension API for usage from within Client
6
+ # @private
7
+ class ClientUIExtensionMethodsFactory
8
+ include Contentful::Management::ClientAssociationMethodsFactory
9
+
10
+ def new(*)
11
+ fail 'Not supported'
12
+ end
13
+ end
14
+ end
15
+ end
@@ -0,0 +1,27 @@
1
+ require_relative 'client_association_methods_factory'
2
+
3
+ module Contentful
4
+ module Management
5
+ # Wrapper for Users API for usage from within Client
6
+ # @private
7
+ class ClientUserMethodsFactory
8
+ include Contentful::Management::ClientAssociationMethodsFactory
9
+
10
+ def new(*)
11
+ fail 'Not supported'
12
+ end
13
+
14
+ def find(user_id)
15
+ super(nil, user_id)
16
+ end
17
+
18
+ def me
19
+ find('me')
20
+ end
21
+
22
+ def all(*)
23
+ fail 'Not supported'
24
+ end
25
+ end
26
+ end
27
+ end
@@ -0,0 +1,30 @@
1
+ require_relative 'client_association_methods_factory'
2
+
3
+ module Contentful
4
+ module Management
5
+ # Wrapper for Webhook Call API for usage from within Client
6
+ # @private
7
+ class ClientWebhookCallMethodsFactory
8
+ include Contentful::Management::ClientAssociationMethodsFactory
9
+
10
+ def all(space_id, webhook_id, _params = {})
11
+ @resource_requester.find(
12
+ space_id: space_id,
13
+ webhook_id: webhook_id
14
+ )
15
+ end
16
+
17
+ def find(space_id, webhook_id, call_id)
18
+ @resource_requester.find(
19
+ space_id: space_id,
20
+ webhook_id: webhook_id,
21
+ call_id: call_id
22
+ )
23
+ end
24
+
25
+ def new(*)
26
+ fail 'Not supported'
27
+ end
28
+ end
29
+ end
30
+ end
@@ -0,0 +1,27 @@
1
+ require_relative 'client_association_methods_factory'
2
+
3
+ module Contentful
4
+ module Management
5
+ # Wrapper for Webhook Health API for usage from within Client
6
+ # @private
7
+ class ClientWebhookHealthMethodsFactory
8
+ include Contentful::Management::ClientAssociationMethodsFactory
9
+
10
+ # Not supported
11
+ def all(*)
12
+ fail 'Not supported'
13
+ end
14
+
15
+ def find(space_id, webhook_id)
16
+ @resource_requester.find(
17
+ space_id: space_id,
18
+ webhook_id: webhook_id
19
+ )
20
+ end
21
+
22
+ def new(*)
23
+ fail 'Not supported'
24
+ end
25
+ end
26
+ end
27
+ end
@@ -3,6 +3,7 @@ require_relative 'field'
3
3
  require_relative 'validation'
4
4
  require_relative 'content_type_entry_methods_factory'
5
5
  require_relative 'content_type_editor_interface_methods_factory'
6
+ require_relative 'content_type_snapshot_methods_factory'
6
7
  require_relative 'support'
7
8
  require_relative 'resource/all_published'
8
9
  require_relative 'resource/publisher'
@@ -153,6 +154,15 @@ module Contentful
153
154
  Contentful::Management::ContentTypeEditorInterfaceMethodsFactory.new(self)
154
155
  end
155
156
 
157
+ # Allows manipulation of snapshots in context of the current content type
158
+ # Allows listing all snapshots belonging to this entry and finding one by id.
159
+ # @see _ README for details.
160
+ #
161
+ # @return [Contentful::Management::ContentTypeSnapshotMethodsFactory]
162
+ def snapshots
163
+ ContentTypeSnapshotMethodsFactory.new(self)
164
+ end
165
+
156
166
  # @private
157
167
  def self.fields_to_nested_properties_hash(fields)
158
168
  fields.map do |field|
@@ -0,0 +1,35 @@
1
+ require_relative 'resource_requester'
2
+
3
+ module Contentful
4
+ module Management
5
+ # Wrapper for Entry manipulation for a specific Content Type
6
+ # @private
7
+ class ContentTypeSnapshotMethodsFactory
8
+ attr_reader :content_type
9
+
10
+ # @private
11
+ def initialize(content_type)
12
+ @content_type = content_type
13
+ end
14
+
15
+ # Gets all snapshot for a specific content type.
16
+ #
17
+ # @see _ For complete option list: https://www.contentful.com/developers/docs/references/content-management-api/#/reference/snapshots/content-type-snapshots-collection
18
+ #
19
+ # @return [Contentful::Management::Array<Contentful::Management::Snapshot>]
20
+ def all(params = {})
21
+ Snapshot.all(content_type.client, content_type.space.id, content_type.id, 'content_types', params)
22
+ end
23
+
24
+ # Gets a snapshot by ID for a specific content type.
25
+ #
26
+ # @param [String] snapshot_id
27
+ # @see _ For complete option list: https://www.contentful.com/developers/docs/references/content-management-api/#/reference/snapshots/content-type-snapshots-collection
28
+ #
29
+ # @return [Contentful::Management::Array<Contentful::Management::Snapshot>]
30
+ def find(snapshot_id)
31
+ Snapshot.find(content_type.client, content_type.space.id, content_type.id, snapshot_id, 'content_types')
32
+ end
33
+ end
34
+ end
35
+ end
@@ -45,7 +45,7 @@ module Contentful
45
45
  space_id = endpoint_options.fetch(:space_id)
46
46
  content_type_id = endpoint_options.fetch(:content_type_id)
47
47
 
48
- "/#{space_id}/content_types/#{content_type_id}/editor_interface"
48
+ "spaces/#{space_id}/content_types/#{content_type_id}/editor_interface"
49
49
  end
50
50
 
51
51
  # Updates an Editor Interface
@@ -0,0 +1,20 @@
1
+ require_relative 'resource'
2
+
3
+ module Contentful
4
+ module Management
5
+ # Resource class for Organization.
6
+ # @see _ https://www.contentful.com/developers/docs/references/content-management-api/#/reference/organizations
7
+ class Organization
8
+ include Contentful::Management::Resource
9
+ include Contentful::Management::Resource::SystemProperties
10
+ include Contentful::Management::Resource::Refresher
11
+
12
+ property :name
13
+
14
+ # @private
15
+ def self.build_endpoint(_endpoint_options)
16
+ '/organizations'
17
+ end
18
+ end
19
+ end
20
+ end
@@ -0,0 +1,45 @@
1
+ require_relative 'resource'
2
+
3
+ module Contentful
4
+ module Management
5
+ # Resource class for PersonalAccessToken.
6
+ # @see _ https://www.contentful.com/developers/docs/references/content-management-api/#/reference/personal-access-tokens
7
+ class PersonalAccessToken
8
+ include Contentful::Management::Resource
9
+ include Contentful::Management::Resource::SystemProperties
10
+ include Contentful::Management::Resource::Refresher
11
+
12
+ property :name, :string
13
+ property :revokedAt, :date
14
+ property :scopes, :array
15
+ property :token, :string
16
+
17
+ # @private
18
+ def self.build_endpoint(endpoint_options)
19
+ endpoint = 'users/me/access_tokens'
20
+ endpoint = "#{endpoint}/#{endpoint_options[:resource_id]}" if endpoint_options[:resource_id]
21
+ endpoint = "#{endpoint}#{endpoint_options[:suffix]}" if endpoint_options[:suffix]
22
+ endpoint
23
+ end
24
+
25
+ # @private
26
+ def self.create_attributes(_client, attributes)
27
+ attributes
28
+ end
29
+
30
+ # Not supported
31
+ def destroy
32
+ fail 'Not supported'
33
+ end
34
+
35
+ # Revokes the personal access token.
36
+ def revoke
37
+ ResourceRequester.new(client, self.class).update(
38
+ self,
39
+ resource_id: id,
40
+ suffix: '/revoked'
41
+ )
42
+ end
43
+ end
44
+ end
45
+ end
@@ -17,7 +17,6 @@ module Contentful
17
17
 
18
18
  case query
19
19
  when Hash
20
- @client.zero_length = query.empty?
21
20
  @query = normalize_query(query) if query && !query.empty?
22
21
  else
23
22
  @query = query
@@ -152,6 +152,8 @@ module Contentful
152
152
  COERCIONS[what] ? COERCIONS[what][value] : value
153
153
  when Class
154
154
  what.new(value, client)
155
+ when Proc
156
+ what[value]
155
157
  else
156
158
  value
157
159
  end
@@ -166,8 +168,8 @@ module Contentful
166
168
 
167
169
  # @private
168
170
  def build_endpoint(endpoint_options)
169
- return "/#{endpoint_options[:space_id]}/public/#{endpoint}" if endpoint_options.key?(:public)
170
- base = "/#{endpoint_options[:space_id]}/#{endpoint}"
171
+ return "spaces/#{endpoint_options[:space_id]}/public/#{endpoint}" if endpoint_options.key?(:public)
172
+ base = "spaces/#{endpoint_options[:space_id]}/#{endpoint}"
171
173
  return "#{base}/#{endpoint_options[:resource_id]}#{endpoint_options[:suffix]}" if endpoint_options.key?(:resource_id)
172
174
  base
173
175
  end
@@ -5,12 +5,19 @@ require_relative 'dynamic_entry'
5
5
  require_relative 'array'
6
6
  require_relative 'link'
7
7
  require_relative 'space'
8
+ require_relative 'space_membership'
9
+ require_relative 'organization'
10
+ require_relative 'user'
8
11
  require_relative 'content_type'
9
12
  require_relative 'asset'
10
13
  require_relative 'webhook'
14
+ require_relative 'webhook_call'
15
+ require_relative 'webhook_health'
11
16
  require_relative 'api_key'
17
+ require_relative 'personal_access_token'
12
18
  require_relative 'locale'
13
19
  require_relative 'role'
20
+ require_relative 'ui_extension'
14
21
  require_relative 'editor_interface'
15
22
  require_relative 'snapshot'
16
23
  require_relative 'upload'
@@ -24,15 +31,23 @@ module Contentful
24
31
  # @see _ README for more information on Resource Mapping
25
32
  DEFAULT_RESOURCE_MAPPING = {
26
33
  'Space' => Contentful::Management::Space,
34
+ 'SpaceMembership' => Contentful::Management::SpaceMembership,
35
+ 'Organization' => Contentful::Management::Organization,
36
+ 'User' => Contentful::Management::User,
27
37
  'ContentType' => Contentful::Management::ContentType,
28
38
  'Entry' => :find_entry_class,
29
39
  'Asset' => Contentful::Management::Asset,
30
40
  'Array' => :array_or_sync_page,
31
41
  'Link' => Contentful::Management::Link,
32
42
  'WebhookDefinition' => Contentful::Management::Webhook,
43
+ 'WebhookCallOverview' => Contentful::Management::WebhookCall,
44
+ 'WebhookCallDetails' => Contentful::Management::WebhookCall,
45
+ 'Webhook' => Contentful::Management::WebhookHealth,
33
46
  'ApiKey' => Contentful::Management::ApiKey,
47
+ 'PersonalAccessToken' => Contentful::Management::PersonalAccessToken,
34
48
  'Locale' => Contentful::Management::Locale,
35
49
  'Role' => Contentful::Management::Role,
50
+ 'Extension' => Contentful::Management::UIExtension,
36
51
  'EditorInterface' => Contentful::Management::EditorInterface,
37
52
  'Snapshot' => Contentful::Management::Snapshot,
38
53
  'Upload' => Contentful::Management::Upload
@@ -10,34 +10,48 @@ module Contentful
10
10
  include Contentful::Management::Resource::SystemProperties
11
11
  include Contentful::Management::Resource::Refresher
12
12
 
13
- property :snapshot, DynamicEntry
13
+ # @private
14
+ def self.property_coercions
15
+ {
16
+ snapshot: lambda do |h|
17
+ case h.fetch('sys', {})['type']
18
+ when 'Entry'
19
+ DynamicEntry.new(h)
20
+ when 'ContentType'
21
+ ContentType.new(h)
22
+ end
23
+ end
24
+ }
25
+ end
26
+
27
+ property :snapshot
14
28
 
15
- # Gets all Snapshots for an Entry
29
+ # Gets all snapshots for a resource
16
30
  #
17
31
  # @param [Contentful::Management::Client] client
18
32
  # @param [String] space_id
19
- # @param [String] entry_id
33
+ # @param [String] resource_id
34
+ # @param [String] resource_type
20
35
  #
21
36
  # @return [Contentful::Management::Array<Contentful::Management::Snapshot>]
22
- def self.all(client, space_id, entry_id)
23
- ClientSnapshotMethodsFactory.new(client).all(space_id, entry_id)
37
+ def self.all(client, space_id, resource_id, resource_type = 'entries', params = {})
38
+ ClientSnapshotMethodsFactory.new(client, resource_type).all(space_id, resource_id, params)
24
39
  end
25
40
 
26
- # Gets a Snapshot by ID
41
+ # Gets a snapshot by ID
27
42
  #
28
43
  # @param [Contentful::Management::Client] client
29
44
  # @param [String] space_id
30
- # @param [String] entry_id
45
+ # @param [String] resource_id
31
46
  # @param [String] snapshot_id
47
+ # @param [String] resource_type
32
48
  #
33
49
  # @return [Contentful::Management::Snapshot]
34
- def self.find(client, space_id, entry_id, snapshot_id)
35
- ClientSnapshotMethodsFactory.new(client).find(space_id, entry_id, snapshot_id)
50
+ def self.find(client, space_id, resource_id, snapshot_id, resource_type = 'entries')
51
+ ClientSnapshotMethodsFactory.new(client, resource_type).find(space_id, resource_id, snapshot_id)
36
52
  end
37
53
 
38
- # Creates a Snapshot
39
- #
40
- # Not Supported
54
+ # Not supported
41
55
  def self.create(*)
42
56
  fail 'Not supported'
43
57
  end
@@ -49,26 +63,23 @@ module Contentful
49
63
 
50
64
  # @private
51
65
  def self.build_endpoint(endpoint_options)
66
+ resource_type = endpoint_options.fetch(:resource_type, 'entries')
52
67
  space_id = endpoint_options.fetch(:space_id)
53
- entry_id = endpoint_options.fetch(:entry_id)
68
+ resource_id = endpoint_options.fetch(:resource_id)
54
69
  snapshot_id = endpoint_options.fetch(:snapshot_id, nil)
55
70
 
56
- endpoint = "/#{space_id}/entries/#{entry_id}/snapshots"
71
+ endpoint = "spaces/#{space_id}/#{resource_type}/#{resource_id}/snapshots"
57
72
  endpoint = "#{endpoint}/#{snapshot_id}" unless snapshot_id.nil?
58
73
 
59
74
  endpoint
60
75
  end
61
76
 
62
- # Deletes a Snapshot
63
- #
64
- # Not Supported
77
+ # Not supported
65
78
  def destroy
66
79
  fail 'Not supported'
67
80
  end
68
81
 
69
- # Updates a Snapshot
70
- #
71
- # Not Supported
82
+ # Not supported
72
83
  def update(*)
73
84
  fail 'Not supported'
74
85
  end
@@ -1,4 +1,6 @@
1
1
  require_relative 'resource'
2
+ require_relative 'space_membership'
3
+ require_relative 'space_space_membership_methods_factory'
2
4
  require_relative 'locale'
3
5
  require_relative 'space_locale_methods_factory'
4
6
  require_relative 'content_type'
@@ -11,6 +13,8 @@ require_relative 'webhook'
11
13
  require_relative 'space_webhook_methods_factory'
12
14
  require_relative 'role'
13
15
  require_relative 'space_role_methods_factory'
16
+ require_relative 'ui_extension'
17
+ require_relative 'space_ui_extension_methods_factory'
14
18
  require_relative 'editor_interface'
15
19
  require_relative 'space_editor_interface_methods_factory'
16
20
  require_relative 'api_key'
@@ -33,8 +37,8 @@ module Contentful
33
37
 
34
38
  # @private
35
39
  def self.build_endpoint(endpoint_options)
36
- return "/#{endpoint_options[:space_id]}" if endpoint_options.key?(:space_id)
37
- ''
40
+ return "spaces/#{endpoint_options[:space_id]}" if endpoint_options.key?(:space_id)
41
+ 'spaces'
38
42
  end
39
43
 
40
44
  # Gets all Spaces
@@ -123,7 +127,7 @@ module Contentful
123
127
  end
124
128
 
125
129
  # Allows manipulation of content types in context of the current space
126
- # Allows listing all content types of space, creating new and finding one by id.
130
+ # Allows listing all content types of space, creating new and finding one by ID.
127
131
  # @see _ README for details.
128
132
  #
129
133
  # @return [Contentful::Management::SpaceContentTypeMethodsFactory]
@@ -132,7 +136,7 @@ module Contentful
132
136
  end
133
137
 
134
138
  # Allows manipulation of api keys in context of the current space
135
- # Allows listing all api keys of space, creating new and finding one by id.
139
+ # Allows listing all api keys of space, creating new and finding one by ID.
136
140
  # @see _ README for details.
137
141
  #
138
142
  # @return [Contentful::Management::SpaceApiKeyMethodsFactory]
@@ -141,7 +145,7 @@ module Contentful
141
145
  end
142
146
 
143
147
  # Allows manipulation of locales in context of the current space
144
- # Allows listing all locales of space, creating new and finding one by id.
148
+ # Allows listing all locales of space, creating new and finding one by ID.
145
149
  # @see _ README for details.
146
150
  #
147
151
  # @return [Contentful::Management::SpaceLocaleMethodsFactory]
@@ -149,8 +153,17 @@ module Contentful
149
153
  SpaceLocaleMethodsFactory.new(self)
150
154
  end
151
155
 
156
+ # Allows manipulation of space memberships in context of the current space
157
+ # Allows listing all space memberships of space, creating new and finding one by ID.
158
+ # @see _ README for details.
159
+ #
160
+ # @return [Contentful::Management::SpaceSpaceMembershipMethodsFactory]
161
+ def space_memberships
162
+ SpaceSpaceMembershipMethodsFactory.new(self)
163
+ end
164
+
152
165
  # Allows manipulation of roles in context of the current space
153
- # Allows listing all roles of space, creating new and finding one by id.
166
+ # Allows listing all roles of space, creating new and finding one by ID.
154
167
  # @see _ README for details.
155
168
  #
156
169
  # @return [Contentful::Management::SpaceRoleMethodsFactory]
@@ -158,8 +171,17 @@ module Contentful
158
171
  SpaceRoleMethodsFactory.new(self)
159
172
  end
160
173
 
174
+ # Allows manipulation of UI extension in context of the current space
175
+ # Allows listing all UI extension of space, creating new and finding one by ID.
176
+ # @see _ README for details.
177
+ #
178
+ # @return [Contentful::Management::SpaceUIExtensionMethodsFactory]
179
+ def ui_extensions
180
+ SpaceUIExtensionMethodsFactory.new(self)
181
+ end
182
+
161
183
  # Allows manipulation of editor interfaces in context of the current space
162
- # Allows listing all editor interfaces of space, creating new and finding one by id.
184
+ # Allows listing all editor interfaces of space, creating new and finding one by ID.
163
185
  # @see _ README for details.
164
186
  #
165
187
  # @return [Contentful::Management::SpaceEditorInterfaceMethodsFactory]
@@ -168,7 +190,7 @@ module Contentful
168
190
  end
169
191
 
170
192
  # Allows manipulation of assets in context of the current space
171
- # Allows listing all assets of space, creating new and finding one by id.
193
+ # Allows listing all assets of space, creating new and finding one by ID.
172
194
  # @see _ README for details.
173
195
  #
174
196
  # @return [Contentful::Management::SpaceAssetMethodsFactory]
@@ -177,7 +199,7 @@ module Contentful
177
199
  end
178
200
 
179
201
  # Allows manipulation of entries in context of the current space
180
- # Allows listing all entries for space and finding one by id.
202
+ # Allows listing all entries for space and finding one by ID.
181
203
  # @see _ README for details.
182
204
  #
183
205
  # @return [Contentful::Management::SpaceEntryMethodsFactory]
@@ -186,7 +208,7 @@ module Contentful
186
208
  end
187
209
 
188
210
  # Allows manipulation of webhooks in context of the current space
189
- # Allows listing all webhooks for space and finding one by id.
211
+ # Allows listing all webhooks for space and finding one by ID.
190
212
  # @see _ README for details.
191
213
  #
192
214
  # @return [Contentful::Management::SpaceWebhookMethodsFactory]