Skip to content

Commit 7e6f234

Browse files
sunil-lakshmanishaileshmishraharshithad0703
authored
Added bulk operations class implementation (#29) (#30)
* Added users and organisations api methods User Session Logging in/out Users Get User Update User Activate User Request Password Reset Password Organizations Get All Organizations Get Single Organization Organization Roles Organization Users Transfer Organization Ownership Organization Stacks Organization Logs * added requirements.txt file * loaded install, changlog , codeowners and release.yml file * Organized package structure * Developed stack Implementation * Code Optimized * Added Mock test and Api Test cases * Added test cases and coverage packages * Added API documentation and added stacks test cases * Added coverage reports generartion in github action Added coverage report github action Changed methods name Changed unit test cases Code improvements API Documentation * Added global fields class * - General code improvements - Corrected few testcases - Single place for credentials - linting added * Feat/cs 40287 workflow class implemetation (#14) * feat: ✨ implemented branches and aliases with unit and api test cases * test: ✅ added mock tests for branches and aliases * docs: 📝 added api documentation for branches and aliases * feat: ✨ content type implementation with api references, unit test cases and api test cases * test: renamed the api, mock, unit test file names of branch and alias * test: renamed file path in branch and alias mock tests * test: improved coverage report for branches and aliases * test: Added mock test cases for content type * docs: 📝 Cleared typo errors * test: removed unwanted test files * refactor: Code improvement for branches, aliases and content type implementation * - General code improvements - Testcases improvements * - General code improvements - Testcases improvements * - General code improvements - Formats are updated * code enhancement * Created Entry class and test cases Created Entry Class created entry class test cases * feat: ✨ asset class implementation with tests and api docs * Code improvements and changed test cases to new structure * test: ✅ added resources and made some changes in api and unit test cases * Updated Unit test cases. * Webhook class Implementation * Created workflow class * Deleted secrets-scan.yml file * Updated variable name * Deleted sast-scan.yml file * Feat/cs 40545 metadata class implemetation (#15) * Metadata class implementation * Deleted sast-scan.yml file * Fixed PR comments * Code optimisation and handling custom error exception * Removed uids * Feat/cs 40549 roles class implementation (#16) * Created roles class with unit testcases, mock test cases and api test cases * Updated coverage report github workflow file * Added coverage install command * Added pytest install command * Updated stack class unit test file * Added html coverage * Added coverage reports and visualizations * Removed visualisation * Generating coverage report in svg format * Added coverage-badge install command * Fixed PR comments and code optimisation * Added coverage reports graphical visualisation in github page * Created readme file * changed variable name * Updated readme file * Update README.md * Added auditlog class and license file (#17) * Added auditlog class and license file * Added test case for invalid inputs * commented the idiom It Allows You to Execute Code When the File Runs as a Script, but Not When It’s Imported as a Module --------- Co-authored-by: Shailesh Mishra <[email protected]> --------- Co-authored-by: Shailesh Mishra <[email protected]> * Developed environment class implementation (#19) * Developed environment class implementation * Updated variable name * Added CI-CD implementation (#20) * Added CI-CD implementation Added CICD implemetation Updated code Optimization Updated code for check package in test environment. * Removed Unused files * Feat/cs 41198 locale class implementation (#21) * Added locale class implementation * Implemented taxonomy support (#22) --------- Co-authored-by: harshithad0703 <[email protected]> Co-authored-by: Shailesh Mishra <[email protected]> Co-authored-by: Shailesh Mishra <[email protected]> * Feat/cs 41199 label class implementation (#25) * Next (#23) * Added users and organisations api methods User Session Logging in/out Users Get User Update User Activate User Request Password Reset Password Organizations Get All Organizations Get Single Organization Organization Roles Organization Users Transfer Organization Ownership Organization Stacks Organization Logs * added requirements.txt file * loaded install, changlog , codeowners and release.yml file * Organized package structure * Developed stack Implementation * Code Optimized * Added Mock test and Api Test cases * Added test cases and coverage packages * Added API documentation and added stacks test cases * Added coverage reports generartion in github action Added coverage report github action Changed methods name Changed unit test cases Code improvements API Documentation * Added global fields class * - General code improvements - Corrected few testcases - Single place for credentials - linting added * Feat/cs 40287 workflow class implemetation (#14) * feat: ✨ implemented branches and aliases with unit and api test cases * test: ✅ added mock tests for branches and aliases * docs: 📝 added api documentation for branches and aliases * feat: ✨ content type implementation with api references, unit test cases and api test cases * test: renamed the api, mock, unit test file names of branch and alias * test: renamed file path in branch and alias mock tests * test: improved coverage report for branches and aliases * test: Added mock test cases for content type * docs: 📝 Cleared typo errors * test: removed unwanted test files * refactor: Code improvement for branches, aliases and content type implementation * - General code improvements - Testcases improvements * - General code improvements - Testcases improvements * - General code improvements - Formats are updated * code enhancement * Created Entry class and test cases Created Entry Class created entry class test cases * feat: ✨ asset class implementation with tests and api docs * Code improvements and changed test cases to new structure * test: ✅ added resources and made some changes in api and unit test cases * Updated Unit test cases. * Webhook class Implementation * Created workflow class * Deleted secrets-scan.yml file * Updated variable name * Deleted sast-scan.yml file * Feat/cs 40545 metadata class implemetation (#15) * Metadata class implementation * Deleted sast-scan.yml file * Fixed PR comments * Code optimisation and handling custom error exception * Removed uids * Feat/cs 40549 roles class implementation (#16) * Created roles class with unit testcases, mock test cases and api test cases * Updated coverage report github workflow file * Added coverage install command * Added pytest install command * Updated stack class unit test file * Added html coverage * Added coverage reports and visualizations * Removed visualisation * Generating coverage report in svg format * Added coverage-badge install command * Fixed PR comments and code optimisation * Added coverage reports graphical visualisation in github page * Created readme file * changed variable name * Updated readme file * Update README.md * Added auditlog class and license file (#17) * Added auditlog class and license file * Added test case for invalid inputs * commented the idiom It Allows You to Execute Code When the File Runs as a Script, but Not When It’s Imported as a Module --------- Co-authored-by: Shailesh Mishra <[email protected]> --------- Co-authored-by: Shailesh Mishra <[email protected]> * Developed environment class implementation (#19) * Developed environment class implementation * Updated variable name * Added CI-CD implementation (#20) * Added CI-CD implementation Added CICD implemetation Updated code Optimization Updated code for check package in test environment. * Removed Unused files * Feat/cs 41198 locale class implementation (#21) * Added locale class implementation * Implemented taxonomy support (#22) --------- Co-authored-by: harshithad0703 <[email protected]> Co-authored-by: Shailesh Mishra <[email protected]> Co-authored-by: Shailesh Mishra <[email protected]> --------- Co-authored-by: Shailesh Mishra <[email protected]> Co-authored-by: Shailesh Mishra <[email protected]> Co-authored-by: harshithad0703 <[email protected]> * Deleted .idea directory (#24) * Deleted .idea directory * Deleted Test apidoc files * Deleted coverage.txt file * Created label class implementation * Updated document data --------- Co-authored-by: Shailesh Mishra <[email protected]> Co-authored-by: Shailesh Mishra <[email protected]> Co-authored-by: harshithad0703 <[email protected]> * Feat/cs 41332 terms class implemetation (#27) * Next (#26) * Added users and organisations api methods User Session Logging in/out Users Get User Update User Activate User Request Password Reset Password Organizations Get All Organizations Get Single Organization Organization Roles Organization Users Transfer Organization Ownership Organization Stacks Organization Logs * added requirements.txt file * loaded install, changlog , codeowners and release.yml file * Organized package structure * Developed stack Implementation * Code Optimized * Added Mock test and Api Test cases * Added test cases and coverage packages * Added API documentation and added stacks test cases * Added coverage reports generartion in github action Added coverage report github action Changed methods name Changed unit test cases Code improvements API Documentation * Added global fields class * - General code improvements - Corrected few testcases - Single place for credentials - linting added * Feat/cs 40287 workflow class implemetation (#14) * feat: ✨ implemented branches and aliases with unit and api test cases * test: ✅ added mock tests for branches and aliases * docs: 📝 added api documentation for branches and aliases * feat: ✨ content type implementation with api references, unit test cases and api test cases * test: renamed the api, mock, unit test file names of branch and alias * test: renamed file path in branch and alias mock tests * test: improved coverage report for branches and aliases * test: Added mock test cases for content type * docs: 📝 Cleared typo errors * test: removed unwanted test files * refactor: Code improvement for branches, aliases and content type implementation * - General code improvements - Testcases improvements * - General code improvements - Testcases improvements * - General code improvements - Formats are updated * code enhancement * Created Entry class and test cases Created Entry Class created entry class test cases * feat: ✨ asset class implementation with tests and api docs * Code improvements and changed test cases to new structure * test: ✅ added resources and made some changes in api and unit test cases * Updated Unit test cases. * Webhook class Implementation * Created workflow class * Deleted secrets-scan.yml file * Updated variable name * Deleted sast-scan.yml file * Feat/cs 40545 metadata class implemetation (#15) * Metadata class implementation * Deleted sast-scan.yml file * Fixed PR comments * Code optimisation and handling custom error exception * Removed uids * Feat/cs 40549 roles class implementation (#16) * Created roles class with unit testcases, mock test cases and api test cases * Updated coverage report github workflow file * Added coverage install command * Added pytest install command * Updated stack class unit test file * Added html coverage * Added coverage reports and visualizations * Removed visualisation * Generating coverage report in svg format * Added coverage-badge install command * Fixed PR comments and code optimisation * Added coverage reports graphical visualisation in github page * Created readme file * changed variable name * Updated readme file * Update README.md * Added auditlog class and license file (#17) * Added auditlog class and license file * Added test case for invalid inputs * commented the idiom It Allows You to Execute Code When the File Runs as a Script, but Not When It’s Imported as a Module --------- Co-authored-by: Shailesh Mishra <[email protected]> --------- Co-authored-by: Shailesh Mishra <[email protected]> * Developed environment class implementation (#19) * Developed environment class implementation * Updated variable name * Added CI-CD implementation (#20) * Added CI-CD implementation Added CICD implemetation Updated code Optimization Updated code for check package in test environment. * Removed Unused files * Feat/cs 41198 locale class implementation (#21) * Added locale class implementation * Implemented taxonomy support (#22) --------- Co-authored-by: harshithad0703 <[email protected]> Co-authored-by: Shailesh Mishra <[email protected]> Co-authored-by: Shailesh Mishra <[email protected]> * Feat/cs 41199 label class implementation (#25) * Next (#23) * Added users and organisations api methods User Session Logging in/out Users Get User Update User Activate User Request Password Reset Password Organizations Get All Organizations Get Single Organization Organization Roles Organization Users Transfer Organization Ownership Organization Stacks Organization Logs * added requirements.txt file * loaded install, changlog , codeowners and release.yml file * Organized package structure * Developed stack Implementation * Code Optimized * Added Mock test and Api Test cases * Added test cases and coverage packages * Added API documentation and added stacks test cases * Added coverage reports generartion in github action Added coverage report github action Changed methods name Changed unit test cases Code improvements API Documentation * Added global fields class * - General code improvements - Corrected few testcases - Single place for credentials - linting added * Feat/cs 40287 workflow class implemetation (#14) * feat: ✨ implemented branches and aliases with unit and api test cases * test: ✅ added mock tests for branches and aliases * docs: 📝 added api documentation for branches and aliases * feat: ✨ content type implementation with api references, unit test cases and api test cases * test: renamed the api, mock, unit test file names of branch and alias * test: renamed file path in branch and alias mock tests * test: improved coverage report for branches and aliases * test: Added mock test cases for content type * docs: 📝 Cleared typo errors * test: removed unwanted test files * refactor: Code improvement for branches, aliases and content type implementation * - General code improvements - Testcases improvements * - General code improvements - Testcases improvements * - General code improvements - Formats are updated * code enhancement * Created Entry class and test cases Created Entry Class created entry class test cases * feat: ✨ asset class implementation with tests and api docs * Code improvements and changed test cases to new structure * test: ✅ added resources and made some changes in api and unit test cases * Updated Unit test cases. * Webhook class Implementation * Created workflow class * Deleted secrets-scan.yml file * Updated variable name * Deleted sast-scan.yml file * Feat/cs 40545 metadata class implemetation (#15) * Metadata class implementation * Deleted sast-scan.yml file * Fixed PR comments * Code optimisation and handling custom error exception * Removed uids * Feat/cs 40549 roles class implementation (#16) * Created roles class with unit testcases, mock test cases and api test cases * Updated coverage report github workflow file * Added coverage install command * Added pytest install command * Updated stack class unit test file * Added html coverage * Added coverage reports and visualizations * Removed visualisation * Generating coverage report in svg format * Added coverage-badge install command * Fixed PR comments and code optimisation * Added coverage reports graphical visualisation in github page * Created readme file * changed variable name * Updated readme file * Update README.md * Added auditlog class and license file (#17) * Added auditlog class and license file * Added test case for invalid inputs * commented the idiom It Allows You to Execute Code When the File Runs as a Script, but Not When It’s Imported as a Module --------- Co-authored-by: Shailesh Mishra <[email protected]> --------- Co-authored-by: Shailesh Mishra <[email protected]> * Developed environment class implementation (#19) * Developed environment class implementation * Updated variable name * Added CI-CD implementation (#20) * Added CI-CD implementation Added CICD implemetation Updated code Optimization Updated code for check package in test environment. * Removed Unused files * Feat/cs 41198 locale class implementation (#21) * Added locale class implementation * Implemented taxonomy support (#22) --------- Co-authored-by: harshithad0703 <[email protected]> Co-authored-by: Shailesh Mishra <[email protected]> Co-authored-by: Shailesh Mishra <[email protected]> --------- Co-authored-by: Shailesh Mishra <[email protected]> Co-authored-by: Shailesh Mishra <[email protected]> Co-authored-by: harshithad0703 <[email protected]> * Deleted .idea directory (#24) * Deleted .idea directory * Deleted Test apidoc files * Deleted coverage.txt file * Created label class implementation * Updated document data --------- Co-authored-by: Shailesh Mishra <[email protected]> Co-authored-by: Shailesh Mishra <[email protected]> Co-authored-by: harshithad0703 <[email protected]> --------- Co-authored-by: Shailesh Mishra <[email protected]> Co-authored-by: Shailesh Mishra <[email protected]> Co-authored-by: harshithad0703 <[email protected]> * Added terms class implementation --------- Co-authored-by: Shailesh Mishra <[email protected]> Co-authored-by: Shailesh Mishra <[email protected]> Co-authored-by: harshithad0703 <[email protected]> * Added bulk operations class implementation (#29) --------- Co-authored-by: Shailesh Mishra <[email protected]> Co-authored-by: Shailesh Mishra <[email protected]> Co-authored-by: harshithad0703 <[email protected]>
1 parent 031af0f commit 7e6f234

File tree

8 files changed

+718
-0
lines changed

8 files changed

+718
-0
lines changed

.talismanrc

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -268,4 +268,12 @@ fileignoreconfig:
268268
- filename: tests/unit/terms/test_terms_unit.py
269269
checksum: 1723d11c8e22d67e28409c0868781c3e4ec7e1d8e97d63e718716d26e486c8ad
270270
version: ""
271+
fileignoreconfig:
272+
- filename: tests/mock/bulk_operations/test_bulk_operations_mock.py
273+
checksum: f672aa30ff2595147a1de4bcaff1d42a3bd2242b70c139f03d2bf4c3f86d9185
274+
- filename: tests/api/bulk_operations/test_bulk_operations_api.py
275+
checksum: 1cd949c89caaea5b4a7560627a2c745ceec292adbed382450b6a88444a0b667e
276+
- filename: tests/unit/bulk_operations/test_bulk_operations_unit.py
277+
checksum: 1cfaea5cacaef44f2154bd25150d599e6e7be541477b3cef2e909ab16ef86636
278+
version: ""
271279

contentstack_management/__init__.py

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -23,6 +23,8 @@
2323
from .locale.locale import Locale
2424
from .taxonomies.taxonomy import Taxonomy
2525
from .labels.label import Label
26+
from .terms.terms import Terms
27+
from .bulk_operations.bulk_operation import BulkOperation
2628

2729

2830
__all__ = (
@@ -50,6 +52,8 @@
5052
"Locale",
5153
"Taxonomy",
5254
"Label",
55+
"Terms",
56+
"BulkOperation"
5357
)
5458

5559
__title__ = 'contentstack-management-python'
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
from contentstack_management import contentstack
Lines changed: 230 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,230 @@
1+
"""This class takes a base URL as an argument when it's initialized,
2+
which is the endpoint for the RESTFUL API that we'll be interacting with.
3+
The create(), read(), update(), and delete() methods each correspond to
4+
the CRUD operations that can be performed on the API """
5+
6+
import json
7+
from ..common import Parameter
8+
from urllib.parse import quote
9+
from .._errors import ArgumentException
10+
11+
class BulkOperation(Parameter):
12+
"""
13+
This class takes a base URL as an argument when it's initialized,
14+
which is the endpoint for the RESTFUL API that
15+
we'll be interacting with. The create(), read(), update(), and delete()
16+
methods each correspond to the CRUD
17+
operations that can be performed on the API """
18+
19+
def __init__(self, client):
20+
self.client = client
21+
super().__init__(self.client)
22+
self.path = "bulk"
23+
24+
25+
def publish(self, data: dict):
26+
"""
27+
The Publish entries and assets in bulk request allows you to publish multiple entries and assets at the same time.
28+
29+
:param data: The `data` parameter is a dictionary that contains the data to be published
30+
:type data: dict
31+
:return: The `publish` method is returning the result of the `post` request made by the
32+
`client.post` method.
33+
-------------------------------
34+
[Example:]
35+
>>> data = {
36+
>>> "entries":[
37+
>>> {
38+
>>> "uid":"entry_uid",
39+
>>> "content_type":"ct0",
40+
>>> "version":"5",
41+
>>> "locale":"en-us"
42+
>>> },
43+
>>> {
44+
>>> "uid":"entry_uid",
45+
>>> "content_type":"ct0",
46+
>>> "version":"1",
47+
>>> "locale":"en-us"
48+
>>> },
49+
>>> {
50+
>>> "uid":"entry_uid",
51+
>>> "content_type":"ct5",
52+
>>> "version":"2",
53+
>>> "locale":"en-us"
54+
>>> }
55+
>>> ],
56+
>>> "locales":[
57+
>>> "en-us"
58+
>>> ],
59+
>>> "environments":[
60+
>>> "env1"
61+
>>> ],
62+
>>> "rules":{
63+
>>> "approvals":"true/false"
64+
>>> },
65+
>>> "scheduled_at":"scheduled_time",
66+
>>> "publish_with_reference":true
67+
>>> }
68+
>>> from contentstack_management import contentstack
69+
>>> client = contentstack.client(authtoken='your_authtoken')
70+
>>> result = client.stack('api_key').bulk_operation().publish(data).json()
71+
72+
-------------------------------
73+
"""
74+
url = f"{self.path}/publish"
75+
data = json.dumps(data)
76+
return self.client.post(url, headers = self.client.headers, data = data)
77+
78+
def unpublish(self, data: dict):
79+
"""
80+
The Unpublish entries and assets in bulk request allows you to unpublish multiple entries and assets at the same time.
81+
82+
:param data: The `data` parameter is a dictionary that contains the information needed to
83+
unpublish a resource. The specific keys and values in the dictionary will depend on the
84+
requirements of the API you are using
85+
:type data: dict
86+
:return: The method is returning the result of the `post` request made to the specified URL.
87+
-------------------------------
88+
[Example:]
89+
>>> data = {
90+
>>> "entries": [
91+
>>> {
92+
>>> "content_type": "news",
93+
>>> "uid": "entry_uid",
94+
>>> "locale": "en-us"
95+
>>> },
96+
>>> {
97+
>>> "content_type": "article",
98+
>>> "uid": "entry_uid",
99+
>>> "locale": "en-us"
100+
>>> }
101+
>>> ],
102+
>>> "workflow": {
103+
>>> "workflow_stage": {
104+
>>> "comment": "String Comment",
105+
>>> "due_date": "Thu Dec 01 2018",
106+
>>> "notify": false,
107+
>>> "uid": "workflow_uid",
108+
>>> "assigned_to": [
109+
>>> {
110+
>>> "uid": "user_uid",
111+
>>> "name": "user_name",
112+
>>> "email": "user_email_ID"
113+
>>> }
114+
>>> ],
115+
>>> "assigned_by_roles": [
116+
>>> {
117+
>>> "uid": "role_uid",
118+
>>> "name": "Content Manager"
119+
>>> }
120+
>>> ]
121+
>>> }
122+
>>> },
123+
>>> "locales": [
124+
>>> "en-us"
125+
>>> ],
126+
>>> "environments": [
127+
>>> "env_uid"
128+
>>> ]
129+
>>> }
130+
>>> from contentstack_management import contentstack
131+
>>> client = contentstack.client(authtoken='your_authtoken')
132+
>>> result = client.stack('api_key').bulk_operation().unpublish(data).json()
133+
134+
-------------------------------
135+
"""
136+
137+
url = f"{self.path}/unpublish"
138+
data = json.dumps(data)
139+
return self.client.post(url, headers = self.client.headers, data = data)
140+
141+
def delete(self, data: dict):
142+
"""
143+
The Delete entries and assets in bulk request allows you to delete multiple entries and assets at the same time.
144+
145+
:param data: The `data` parameter is a dictionary that contains the information needed to delete
146+
or unpublish a resource. The specific contents of the dictionary will depend on the requirements
147+
of the API you are using
148+
:type data: dict
149+
:return: the result of the `post` request made to the specified URL.
150+
-------------------------------
151+
[Example:]
152+
>>> data = {
153+
>>> "entries":[{
154+
>>> "content_type":"content_type_uid",
155+
>>> "uid":"entry_uid",
156+
>>> "locale":"locale"
157+
>>> },{
158+
>>> "content_type":"content_type_uid",
159+
>>> "uid":"entry_uid",
160+
>>> "locale":"entry_locale"
161+
>>> }
162+
>>> ],
163+
>>> "assets": [{
164+
>>> "uid": "uid"
165+
>>> }]
166+
>>> }
167+
>>> from contentstack_management import contentstack
168+
>>> client = contentstack.client(authtoken='your_authtoken')
169+
>>> result = client.stack('api_key').bulk_operation().delete(data).json()
170+
171+
-------------------------------
172+
"""
173+
174+
url = f"{self.path}/delete"
175+
data = json.dumps(data)
176+
return self.client.post(url, headers = self.client.headers, data = data)
177+
178+
def update(self, data: dict):
179+
"""
180+
The above function updates the bulk_operation of an object by sending a POST request to the specified
181+
URL with the provided data.
182+
183+
:param data: The `data` parameter is a dictionary that contains the information to be updated.
184+
It is converted to a JSON string using the `json.dumps()` function before being sent in the
185+
request
186+
:type data: dict
187+
:return: the result of the `post` request made to the specified URL with the provided headers
188+
and data.
189+
-------------------------------
190+
[Example:]
191+
>>> data = {
192+
>>> "entries": [{
193+
>>> "content_type": "content_type_uid1",
194+
>>> "uid": "entry_uid",
195+
>>> "locale": "en-us"
196+
>>> }, {
197+
>>> "content_type": "content_type_uid2",
198+
>>> "uid": "entry_uid",
199+
>>> "locale": "en-us"
200+
>>> }],
201+
>>> "workflow": {
202+
>>> "workflow_stage": {
203+
>>> "comment": "Workflow-related Comments",
204+
>>> "due_date": "Thu Dec 01 2018",
205+
>>> "notify": false,
206+
>>> "uid": "workflow_stage_uid",
207+
>>> "assigned_to": [{
208+
>>> "uid": "user_uid",
209+
>>> "name": "user_name",
210+
>>> "email": "user_email_id"
211+
>>> }],
212+
>>> "assigned_by_roles": [{
213+
>>> "uid": "role_uid",
214+
>>> "name": "role_name"
215+
>>> }]
216+
>>> }
217+
>>> }
218+
>>> }
219+
>>> from contentstack_management import contentstack
220+
>>> client = contentstack.client(authtoken='your_authtoken')
221+
>>> result = client.stack('api_key').bulk_operation().update(data).json()
222+
223+
-------------------------------
224+
"""
225+
226+
url = f"{self.path}/workflow"
227+
data = json.dumps(data)
228+
return self.client.post(url, headers = self.client.headers, data = data)
229+
230+

contentstack_management/stack/stack.py

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,7 @@
1414
from ..locale.locale import Locale
1515
from ..taxonomies.taxonomy import Taxonomy
1616
from ..labels.label import Label
17+
from ..bulk_operations.bulk_operation import BulkOperation
1718

1819

1920

@@ -352,4 +353,7 @@ def taxonomy(self, taxonomy_uid: str = None):
352353

353354
def label(self, label_uid: str = None):
354355
return Label(self.client, label_uid)
356+
357+
def bulk_operation(self):
358+
return BulkOperation(self.client)
355359

0 commit comments

Comments
 (0)