pyxetabase 4.0.0.dev1__tar.gz → 4.0.0.dev2__tar.gz

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.

Potentially problematic release.


This version of pyxetabase might be problematic. Click here for more details.

Files changed (41) hide show
  1. {pyxetabase-4.0.0.dev1 → pyxetabase-4.0.0.dev2}/PKG-INFO +1 -1
  2. {pyxetabase-4.0.0.dev1 → pyxetabase-4.0.0.dev2}/pyxetabase/rest_clients/admin_client.py +1 -1
  3. {pyxetabase-4.0.0.dev1 → pyxetabase-4.0.0.dev2}/pyxetabase/rest_clients/clinical_analysis_client.py +112 -5
  4. {pyxetabase-4.0.0.dev1 → pyxetabase-4.0.0.dev2}/pyxetabase/rest_clients/file_client.py +15 -2
  5. {pyxetabase-4.0.0.dev1 → pyxetabase-4.0.0.dev2}/pyxetabase/rest_clients/job_client.py +1 -1
  6. {pyxetabase-4.0.0.dev1 → pyxetabase-4.0.0.dev2}/pyxetabase/rest_clients/study_client.py +2 -1
  7. pyxetabase-4.0.0.dev2/pyxetabase/rest_clients/user_tool_client.py +459 -0
  8. {pyxetabase-4.0.0.dev1 → pyxetabase-4.0.0.dev2}/pyxetabase/rest_clients/workflow_client.py +1 -1
  9. {pyxetabase-4.0.0.dev1 → pyxetabase-4.0.0.dev2}/pyxetabase.egg-info/PKG-INFO +1 -1
  10. {pyxetabase-4.0.0.dev1 → pyxetabase-4.0.0.dev2}/pyxetabase.egg-info/SOURCES.txt +1 -0
  11. {pyxetabase-4.0.0.dev1 → pyxetabase-4.0.0.dev2}/setup.py +1 -1
  12. {pyxetabase-4.0.0.dev1 → pyxetabase-4.0.0.dev2}/LICENSE +0 -0
  13. {pyxetabase-4.0.0.dev1 → pyxetabase-4.0.0.dev2}/README.rst +0 -0
  14. {pyxetabase-4.0.0.dev1 → pyxetabase-4.0.0.dev2}/pyxetabase/__init__.py +0 -0
  15. {pyxetabase-4.0.0.dev1 → pyxetabase-4.0.0.dev2}/pyxetabase/commons.py +0 -0
  16. {pyxetabase-4.0.0.dev1 → pyxetabase-4.0.0.dev2}/pyxetabase/exceptions.py +0 -0
  17. {pyxetabase-4.0.0.dev1 → pyxetabase-4.0.0.dev2}/pyxetabase/opencga_client.py +0 -0
  18. {pyxetabase-4.0.0.dev1 → pyxetabase-4.0.0.dev2}/pyxetabase/opencga_config.py +0 -0
  19. {pyxetabase-4.0.0.dev1 → pyxetabase-4.0.0.dev2}/pyxetabase/rest_clients/__init__.py +0 -0
  20. {pyxetabase-4.0.0.dev1 → pyxetabase-4.0.0.dev2}/pyxetabase/rest_clients/_parent_rest_clients.py +0 -0
  21. {pyxetabase-4.0.0.dev1 → pyxetabase-4.0.0.dev2}/pyxetabase/rest_clients/alignment_client.py +0 -0
  22. {pyxetabase-4.0.0.dev1 → pyxetabase-4.0.0.dev2}/pyxetabase/rest_clients/cohort_client.py +0 -0
  23. {pyxetabase-4.0.0.dev1 → pyxetabase-4.0.0.dev2}/pyxetabase/rest_clients/cvdb_client.py +0 -0
  24. {pyxetabase-4.0.0.dev1 → pyxetabase-4.0.0.dev2}/pyxetabase/rest_clients/disease_panel_client.py +0 -0
  25. {pyxetabase-4.0.0.dev1 → pyxetabase-4.0.0.dev2}/pyxetabase/rest_clients/family_client.py +0 -0
  26. {pyxetabase-4.0.0.dev1 → pyxetabase-4.0.0.dev2}/pyxetabase/rest_clients/federation_client.py +0 -0
  27. {pyxetabase-4.0.0.dev1 → pyxetabase-4.0.0.dev2}/pyxetabase/rest_clients/ga4gh_client.py +0 -0
  28. {pyxetabase-4.0.0.dev1 → pyxetabase-4.0.0.dev2}/pyxetabase/rest_clients/individual_client.py +0 -0
  29. {pyxetabase-4.0.0.dev1 → pyxetabase-4.0.0.dev2}/pyxetabase/rest_clients/meta_client.py +0 -0
  30. {pyxetabase-4.0.0.dev1 → pyxetabase-4.0.0.dev2}/pyxetabase/rest_clients/organization_client.py +0 -0
  31. {pyxetabase-4.0.0.dev1 → pyxetabase-4.0.0.dev2}/pyxetabase/rest_clients/project_client.py +0 -0
  32. {pyxetabase-4.0.0.dev1 → pyxetabase-4.0.0.dev2}/pyxetabase/rest_clients/sample_client.py +0 -0
  33. {pyxetabase-4.0.0.dev1 → pyxetabase-4.0.0.dev2}/pyxetabase/rest_clients/user_client.py +0 -0
  34. {pyxetabase-4.0.0.dev1 → pyxetabase-4.0.0.dev2}/pyxetabase/rest_clients/variant_client.py +0 -0
  35. {pyxetabase-4.0.0.dev1 → pyxetabase-4.0.0.dev2}/pyxetabase/rest_clients/variant_operation_client.py +0 -0
  36. {pyxetabase-4.0.0.dev1 → pyxetabase-4.0.0.dev2}/pyxetabase/rest_response.py +0 -0
  37. {pyxetabase-4.0.0.dev1 → pyxetabase-4.0.0.dev2}/pyxetabase/retry.py +0 -0
  38. {pyxetabase-4.0.0.dev1 → pyxetabase-4.0.0.dev2}/pyxetabase.egg-info/dependency_links.txt +0 -0
  39. {pyxetabase-4.0.0.dev1 → pyxetabase-4.0.0.dev2}/pyxetabase.egg-info/requires.txt +0 -0
  40. {pyxetabase-4.0.0.dev1 → pyxetabase-4.0.0.dev2}/pyxetabase.egg-info/top_level.txt +0 -0
  41. {pyxetabase-4.0.0.dev1 → pyxetabase-4.0.0.dev2}/setup.cfg +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: pyxetabase
3
- Version: 4.0.0.dev1
3
+ Version: 4.0.0.dev2
4
4
  Summary: A REST client for OpenCGA enterprise REST web services
5
5
  Author: Daniel Perez-Gil
6
6
  Author-email: daniel.perez@zettagenomics.com
@@ -27,7 +27,7 @@ class Admin(_ParentRestClient):
27
27
  :param str entity: Entity to be grouped by. Allowed values: ['AUDIT
28
28
  NOTE ORGANIZATION USER PROJECT STUDY FILE SAMPLE JOB INDIVIDUAL
29
29
  COHORT DISEASE_PANEL FAMILY CLINICAL_ANALYSIS INTERPRETATION
30
- VARIANT ALIGNMENT CLINICAL EXPRESSION RGA FUNCTIONAL WORKFLOW
30
+ VARIANT ALIGNMENT CLINICAL EXPRESSION RGA FUNCTIONAL EXTERNAL_TOOL
31
31
  RESOURCE'] (REQUIRED)
32
32
  :param str fields: Comma separated list of fields by which to group
33
33
  by. (REQUIRED)
@@ -502,6 +502,111 @@ class ClinicalAnalysis(_ParentRestClient):
502
502
 
503
503
  return self._post(category='analysis', resource='load', subcategory='clinical', data=data, **options)
504
504
 
505
+ def run_ngs_pipeline(self, data=None, **options):
506
+ """
507
+ NGS pipeline that performs QC (e.g.: FastQC), mapping (e.g.: BWA),
508
+ variant calling (e.g., GATK) and variant indexing in OpenCGA
509
+ storage.
510
+ PATH: /{apiVersion}/analysis/clinical/ngsPipeline/run
511
+
512
+ :param dict data: Variant caller pipeline parameters. (REQUIRED)
513
+ :param str study: study.
514
+ :param str job_id: Job ID. It must be a unique string within the
515
+ study. An ID will be autogenerated automatically if not provided.
516
+ :param str job_description: Job description.
517
+ :param str job_depends_on: Comma separated list of existing job IDs
518
+ the job will depend on.
519
+ :param str job_tags: Job tags.
520
+ :param str job_scheduled_start_time: Time when the job is scheduled to
521
+ start.
522
+ :param str job_priority: Priority of the job.
523
+ :param bool job_dry_run: Flag indicating that the job will be executed
524
+ in dry-run mode. In this mode, OpenCGA will validate that all
525
+ parameters and prerequisites are correctly set for successful
526
+ execution, but the job will not actually run.
527
+ """
528
+
529
+ return self._post(category='analysis', resource='run', subcategory='clinical/ngsPipeline', data=data, **options)
530
+
531
+ def run_pipeline_affy(self, data=None, **options):
532
+ """
533
+ Execute the clinical genomics pipeline that performs QC (e.g.:
534
+ FastQC), mapping (e.g.: BWA), variant calling (e.g., GATK) and
535
+ variant indexing in OpenCGA storage.
536
+ PATH: /{apiVersion}/analysis/clinical/pipeline/affy/run
537
+
538
+ :param dict data: JSON with parameters to execute the command
539
+ ngs-pipeline-genomics. (REQUIRED)
540
+ :param str study: study.
541
+ :param str job_id: Job ID. It must be a unique string within the
542
+ study. An ID will be autogenerated automatically if not provided.
543
+ :param str job_description: Job description.
544
+ :param str job_depends_on: Comma separated list of existing job IDs
545
+ the job will depend on.
546
+ :param str job_tags: Job tags.
547
+ :param str job_scheduled_start_time: Time when the job is scheduled to
548
+ start.
549
+ :param str job_priority: Priority of the job.
550
+ :param bool job_dry_run: Flag indicating that the job will be executed
551
+ in dry-run mode. In this mode, OpenCGA will validate that all
552
+ parameters and prerequisites are correctly set for successful
553
+ execution, but the job will not actually run.
554
+ """
555
+
556
+ return self._post(category='analysis', resource='run', subcategory='clinical/pipeline/affy', data=data, **options)
557
+
558
+ def run_pipeline_genomics(self, data=None, **options):
559
+ """
560
+ Execute the clinical genomics pipeline that performs QC (e.g.:
561
+ FastQC), mapping (e.g.: BWA), variant calling (e.g., GATK) and
562
+ variant indexing in OpenCGA storage.
563
+ PATH: /{apiVersion}/analysis/clinical/pipeline/genomics/run
564
+
565
+ :param dict data: JSON with parameters to execute the command
566
+ ngs-pipeline-genomics. (REQUIRED)
567
+ :param str study: study.
568
+ :param str job_id: Job ID. It must be a unique string within the
569
+ study. An ID will be autogenerated automatically if not provided.
570
+ :param str job_description: Job description.
571
+ :param str job_depends_on: Comma separated list of existing job IDs
572
+ the job will depend on.
573
+ :param str job_tags: Job tags.
574
+ :param str job_scheduled_start_time: Time when the job is scheduled to
575
+ start.
576
+ :param str job_priority: Priority of the job.
577
+ :param bool job_dry_run: Flag indicating that the job will be executed
578
+ in dry-run mode. In this mode, OpenCGA will validate that all
579
+ parameters and prerequisites are correctly set for successful
580
+ execution, but the job will not actually run.
581
+ """
582
+
583
+ return self._post(category='analysis', resource='run', subcategory='clinical/pipeline/genomics', data=data, **options)
584
+
585
+ def run_pipeline_prepare(self, data=None, **options):
586
+ """
587
+ Prepare the clinical pipeline.
588
+ PATH: /{apiVersion}/analysis/clinical/pipeline/prepare/run
589
+
590
+ :param dict data: JSON with parameters to execute the command
591
+ ngs-pipeline-prepare. (REQUIRED)
592
+ :param str study: study.
593
+ :param str job_id: Job ID. It must be a unique string within the
594
+ study. An ID will be autogenerated automatically if not provided.
595
+ :param str job_description: Job description.
596
+ :param str job_depends_on: Comma separated list of existing job IDs
597
+ the job will depend on.
598
+ :param str job_tags: Job tags.
599
+ :param str job_scheduled_start_time: Time when the job is scheduled to
600
+ start.
601
+ :param str job_priority: Priority of the job.
602
+ :param bool job_dry_run: Flag indicating that the job will be executed
603
+ in dry-run mode. In this mode, OpenCGA will validate that all
604
+ parameters and prerequisites are correctly set for successful
605
+ execution, but the job will not actually run.
606
+ """
607
+
608
+ return self._post(category='analysis', resource='run', subcategory='clinical/pipeline/prepare', data=data, **options)
609
+
505
610
  def aggregation_stats_rga(self, field, **options):
506
611
  """
507
612
  RGA aggregation stats.
@@ -1086,6 +1191,9 @@ class ClinicalAnalysis(_ParentRestClient):
1086
1191
  analysts is being updated. Allowed values: ['ADD SET REMOVE']
1087
1192
  :param str files_action: Action to be performed if the array of files
1088
1193
  is being updated. Allowed values: ['ADD SET REMOVE']
1194
+ :param str reported_files_action: Action to be performed if the array
1195
+ of reported files is being updated. Allowed values: ['ADD SET
1196
+ REMOVE']
1089
1197
  :param str panels_action: Action to be performed if the array of
1090
1198
  panels is being updated. Allowed values: ['ADD SET REMOVE']
1091
1199
  :param str annotation_sets_action: Action to be performed if the array
@@ -1260,11 +1368,10 @@ class ClinicalAnalysis(_ParentRestClient):
1260
1368
  project can be either the ID or UUID.
1261
1369
  :param str comments_action: Action to be performed if the array of
1262
1370
  comments is being updated. Allowed values: ['ADD REMOVE REPLACE']
1263
- :param str supporting_evidences_action: Action to be performed if the
1264
- array of supporting evidences is being updated. Allowed values:
1265
- ['ADD SET REMOVE']
1266
- :param str files_action: Action to be performed if the array of files
1267
- is being updated. Allowed values: ['ADD SET REMOVE']
1371
+ :param str signatures_action: Action to be performed if the array of
1372
+ signatures is being updated. Allowed values: ['ADD SET REMOVE']
1373
+ :param str references_action: Action to be performed if the array of
1374
+ references is being updated. Allowed values: ['ADD SET REMOVE']
1268
1375
  :param bool include_result: Flag indicating to include the created or
1269
1376
  updated document result in the response.
1270
1377
  """
@@ -407,11 +407,11 @@ class File(_ParentRestClient):
407
407
  :param str format: File format. Allowed values: ['VCF BCF GVCF TBI
408
408
  BIGWIG SAM BAM BAI CRAM CRAI FASTQ FASTA PED TAB_SEPARATED_VALUES
409
409
  COMMA_SEPARATED_VALUES XML PROTOCOL_BUFFER JSON AVRO PARQUET PDF
410
- IMAGE PLAIN BINARY NONE UNKNOWN']
410
+ IMAGE PLAIN BINARY JAVASCRIPT NONE UNKNOWN']
411
411
  :param str file_format: [DEPRECATED] File format. Allowed values:
412
412
  ['VCF BCF GVCF TBI BIGWIG SAM BAM BAI CRAM CRAI FASTQ FASTA PED
413
413
  TAB_SEPARATED_VALUES COMMA_SEPARATED_VALUES XML PROTOCOL_BUFFER
414
- JSON AVRO PARQUET PDF IMAGE PLAIN BINARY NONE UNKNOWN']
414
+ JSON AVRO PARQUET PDF IMAGE PLAIN BINARY JAVASCRIPT NONE UNKNOWN']
415
415
  :param str bioformat: File bioformat. Allowed values:
416
416
  ['MICROARRAY_EXPRESSION_ONECHANNEL_AGILENT
417
417
  MICROARRAY_EXPRESSION_ONECHANNEL_AFFYMETRIX
@@ -557,6 +557,19 @@ class File(_ParentRestClient):
557
557
 
558
558
  return self._post(category='files', resource='annotations/update', query_id=file, subcategory='annotationSets', second_query_id=annotation_set, data=data, **options)
559
559
 
560
+ def update_content(self, file, data=None, **options):
561
+ """
562
+ Overwrite the content of a file.
563
+ PATH: /{apiVersion}/files/{file}/content/update
564
+
565
+ :param dict data: File parameters. (REQUIRED)
566
+ :param str file: File id or name. (REQUIRED)
567
+ :param str study: Study [[organization@]project:]study where study and
568
+ project can be either the ID or UUID.
569
+ """
570
+
571
+ return self._post(category='files', resource='update', query_id=file, subcategory='content', data=data, **options)
572
+
560
573
  def download(self, file, **options):
561
574
  """
562
575
  Download file.
@@ -265,7 +265,7 @@ class Job(_ParentRestClient):
265
265
  Execute an analysis from a custom binary.
266
266
  PATH: /{apiVersion}/jobs/tool/run
267
267
 
268
- :param dict data: NextFlow run parameters. (REQUIRED)
268
+ :param dict data: Workflow tool run parameters. (REQUIRED)
269
269
  :param str study: Study [[organization@]project:]study where study and
270
270
  project can be either the ID or UUID.
271
271
  :param str job_id: Job ID. It must be a unique string within the
@@ -139,7 +139,8 @@ class Study(_ParentRestClient):
139
139
  :param str resource: Resource involved. Allowed values: ['AUDIT NOTE
140
140
  ORGANIZATION USER PROJECT STUDY FILE SAMPLE JOB INDIVIDUAL COHORT
141
141
  DISEASE_PANEL FAMILY CLINICAL_ANALYSIS INTERPRETATION VARIANT
142
- ALIGNMENT CLINICAL EXPRESSION RGA FUNCTIONAL WORKFLOW RESOURCE']
142
+ ALIGNMENT CLINICAL EXPRESSION RGA FUNCTIONAL EXTERNAL_TOOL
143
+ RESOURCE']
143
144
  :param str resource_id: Resource ID.
144
145
  :param str resource_uuid: resource UUID.
145
146
  :param str status: Filter by status. Allowed values: ['SUCCESS ERROR']
@@ -0,0 +1,459 @@
1
+ """
2
+ WARNING: AUTOGENERATED CODE
3
+
4
+ This code was generated by a tool.
5
+
6
+ Manual changes to this file may cause unexpected behavior in your application.
7
+ Manual changes to this file will be overwritten if the code is regenerated.
8
+ """
9
+
10
+ from pyxetabase.rest_clients._parent_rest_clients import _ParentRestClient
11
+
12
+
13
+ class UserTool(_ParentRestClient):
14
+ """
15
+ This class contains methods for the 'User Tools' webservices
16
+ PATH: /{apiVersion}/tools
17
+ """
18
+
19
+ def __init__(self, configuration, token=None, login_handler=None, *args, **kwargs):
20
+ super(UserTool, self).__init__(configuration, token, login_handler, *args, **kwargs)
21
+
22
+ def update_acl(self, members, action, data=None, **options):
23
+ """
24
+ Update the set of user tool permissions granted for the member.
25
+ PATH: /{apiVersion}/tools/acl/{members}/update
26
+
27
+ :param dict data: JSON containing the parameters to update the
28
+ permissions. (REQUIRED)
29
+ :param str action: Action to be performed [ADD, SET, REMOVE or RESET].
30
+ Allowed values: ['SET ADD REMOVE RESET'] (REQUIRED)
31
+ :param str members: Comma separated list of user or group ids.
32
+ (REQUIRED)
33
+ :param str study: Study [[organization@]project:]study where study and
34
+ project can be either the ID or UUID.
35
+ """
36
+
37
+ options['action'] = action
38
+ return self._post(category='tools', resource='update', subcategory='acl', second_query_id=members, data=data, **options)
39
+
40
+ def aggregation_stats(self, **options):
41
+ """
42
+ Fetch user tool stats.
43
+ PATH: /{apiVersion}/tools/aggregationStats
44
+
45
+ :param str study: Study [[organization@]project:]study where study and
46
+ project can be either the ID or UUID.
47
+ :param str id: Comma separated list of external tool IDs up to a
48
+ maximum of 100. Also admits basic regular expressions using the
49
+ operator '~', i.e. '~{perl-regex}' e.g. '~value' for case
50
+ sensitive, '~/value/i' for case insensitive search.
51
+ :param str name: Comma separated list of external tool names up to a
52
+ maximum of 100. Also admits basic regular expressions using the
53
+ operator '~', i.e. '~{perl-regex}' e.g. '~value' for case
54
+ sensitive, '~/value/i' for case insensitive search.
55
+ :param str uuid: Comma separated list of external tool UUIDs up to a
56
+ maximum of 100.
57
+ :param str tags: Comma separated list of tags.
58
+ :param bool draft: Boolean field indicating whether the workflow is a
59
+ draft or not.
60
+ :param str internal.registration_user_id: UserId that created the
61
+ workflow.
62
+ :param str type: External tool type. Allowed types: [CUSTOM_TOOL,
63
+ VARIANT_WALKER or WORKFLOW].
64
+ :param str scope: External tool scope. Allowed types:
65
+ [CLINICAL_INTERPRETATION, SECONDARY_ANALYSIS, RESEARCH or OTHER].
66
+ :param str workflow_repository_name: Workflow repository name.
67
+ :param str docker_name: Docker name.
68
+ :param str creation_date: Creation date. Format: yyyyMMddHHmmss.
69
+ Examples: >2018, 2017-2018, <201805.
70
+ :param str modification_date: Modification date. Format:
71
+ yyyyMMddHHmmss. Examples: >2018, 2017-2018, <201805.
72
+ :param str acl: Filter entries for which a user has the provided
73
+ permissions. Format: acl={user}:{permissions}. Example:
74
+ acl=john:WRITE,WRITE_ANNOTATIONS will return all entries for which
75
+ user john has both WRITE and WRITE_ANNOTATIONS permissions. Only
76
+ study owners or administrators can query by this field. .
77
+ :param str release: Release when it was created.
78
+ :param int snapshot: Snapshot value (Latest version of the entry in
79
+ the specified release).
80
+ :param bool deleted: Boolean to retrieve deleted entries.
81
+ :param str field: Field to apply aggregation statistics to (or a list
82
+ of fields separated by semicolons), e.g.:
83
+ studies;type;numSamples[0..10]:1;format:sum(size).
84
+ """
85
+
86
+ return self._get(category='tools', resource='aggregationStats', **options)
87
+
88
+ def run_custom_builder(self, data=None, **options):
89
+ """
90
+ Execute an analysis from a custom binary.
91
+ PATH: /{apiVersion}/tools/custom/builder/run
92
+
93
+ :param dict data: body. (REQUIRED)
94
+ :param str study: Study [[organization@]project:]study where study and
95
+ project can be either the ID or UUID.
96
+ :param str job_id: Job ID. It must be a unique string within the
97
+ study. An ID will be autogenerated automatically if not provided.
98
+ :param str job_description: Job description.
99
+ :param str job_depends_on: Comma separated list of existing job IDs
100
+ the job will depend on.
101
+ :param str job_tags: Job tags.
102
+ :param str job_scheduled_start_time: Time when the job is scheduled to
103
+ start.
104
+ :param str job_priority: Priority of the job.
105
+ :param bool job_dry_run: Flag indicating that the job will be executed
106
+ in dry-run mode. In this mode, OpenCGA will validate that all
107
+ parameters and prerequisites are correctly set for successful
108
+ execution, but the job will not actually run.
109
+ """
110
+
111
+ return self._post(category='tools', resource='run', subcategory='custom/builder', data=data, **options)
112
+
113
+ def create_custom(self, data=None, **options):
114
+ """
115
+ Register a new user tool of type CUSTOM_TOOL.
116
+ PATH: /{apiVersion}/tools/custom/create
117
+
118
+ :param dict data: JSON containing workflow information. (REQUIRED)
119
+ :param str include: Fields included in the response, whole JSON path
120
+ must be provided.
121
+ :param str exclude: Fields excluded in the response, whole JSON path
122
+ must be provided.
123
+ :param str study: Study [[organization@]project:]study where study and
124
+ project can be either the ID or UUID.
125
+ :param bool include_result: Flag indicating to include the created or
126
+ updated document result in the response.
127
+ """
128
+
129
+ return self._post(category='tools', resource='create', subcategory='custom', data=data, **options)
130
+
131
+ def run_custom_docker(self, data=None, **options):
132
+ """
133
+ Execute an analysis from a custom binary.
134
+ PATH: /{apiVersion}/tools/custom/run
135
+
136
+ :param dict data: External tool run parameters. (REQUIRED)
137
+ :param str study: Study [[organization@]project:]study where study and
138
+ project can be either the ID or UUID.
139
+ :param str job_id: Job ID. It must be a unique string within the
140
+ study. An ID will be autogenerated automatically if not provided.
141
+ :param str job_description: Job description.
142
+ :param str job_depends_on: Comma separated list of existing job IDs
143
+ the job will depend on.
144
+ :param str job_tags: Job tags.
145
+ :param str job_scheduled_start_time: Time when the job is scheduled to
146
+ start.
147
+ :param str job_priority: Priority of the job.
148
+ :param bool job_dry_run: Flag indicating that the job will be executed
149
+ in dry-run mode. In this mode, OpenCGA will validate that all
150
+ parameters and prerequisites are correctly set for successful
151
+ execution, but the job will not actually run.
152
+ """
153
+
154
+ return self._post(category='tools', resource='run', subcategory='custom', data=data, **options)
155
+
156
+ def run_custom(self, tool_id, data=None, **options):
157
+ """
158
+ Execute an analysis from a custom binary.
159
+ PATH: /{apiVersion}/tools/custom/{toolId}/run
160
+
161
+ :param dict data: External tool run parameters. (REQUIRED)
162
+ :param str tool_id: Comma separated list of external tool IDs up to a
163
+ maximum of 100. Also admits basic regular expressions using the
164
+ operator '~', i.e. '~{perl-regex}' e.g. '~value' for case
165
+ sensitive, '~/value/i' for case insensitive search. (REQUIRED)
166
+ :param int version: Tool version. If not provided, the latest version
167
+ will be used.
168
+ :param str study: Study [[organization@]project:]study where study and
169
+ project can be either the ID or UUID.
170
+ :param str job_id: Job ID. It must be a unique string within the
171
+ study. An ID will be autogenerated automatically if not provided.
172
+ :param str job_description: Job description.
173
+ :param str job_depends_on: Comma separated list of existing job IDs
174
+ the job will depend on.
175
+ :param str job_tags: Job tags.
176
+ :param str job_scheduled_start_time: Time when the job is scheduled to
177
+ start.
178
+ :param str job_priority: Priority of the job.
179
+ :param bool job_dry_run: Flag indicating that the job will be executed
180
+ in dry-run mode. In this mode, OpenCGA will validate that all
181
+ parameters and prerequisites are correctly set for successful
182
+ execution, but the job will not actually run.
183
+ """
184
+
185
+ return self._post(category='tools', resource='run', subcategory='custom', second_query_id=tool_id, data=data, **options)
186
+
187
+ def update_custom(self, tool_id, data=None, **options):
188
+ """
189
+ Update some custom user tool attributes.
190
+ PATH: /{apiVersion}/tools/custom/{toolId}/update
191
+
192
+ :param str tool_id: Comma separated list of external tool IDs up to a
193
+ maximum of 100. Also admits basic regular expressions using the
194
+ operator '~', i.e. '~{perl-regex}' e.g. '~value' for case
195
+ sensitive, '~/value/i' for case insensitive search. (REQUIRED)
196
+ :param str include: Fields included in the response, whole JSON path
197
+ must be provided.
198
+ :param str exclude: Fields excluded in the response, whole JSON path
199
+ must be provided.
200
+ :param str study: Study [[organization@]project:]study where study and
201
+ project can be either the ID or UUID.
202
+ :param bool include_result: Flag indicating to include the created or
203
+ updated document result in the response.
204
+ :param dict data: body.
205
+ """
206
+
207
+ return self._post(category='tools', resource='update', subcategory='custom', second_query_id=tool_id, data=data, **options)
208
+
209
+ def distinct(self, field, **options):
210
+ """
211
+ User tool distinct method.
212
+ PATH: /{apiVersion}/tools/distinct
213
+
214
+ :param str field: Comma separated list of fields for which to obtain
215
+ the distinct values. (REQUIRED)
216
+ :param str study: Study [[organization@]project:]study where study and
217
+ project can be either the ID or UUID.
218
+ :param str id: Comma separated list of external tool IDs up to a
219
+ maximum of 100. Also admits basic regular expressions using the
220
+ operator '~', i.e. '~{perl-regex}' e.g. '~value' for case
221
+ sensitive, '~/value/i' for case insensitive search.
222
+ :param str name: Comma separated list of external tool names up to a
223
+ maximum of 100. Also admits basic regular expressions using the
224
+ operator '~', i.e. '~{perl-regex}' e.g. '~value' for case
225
+ sensitive, '~/value/i' for case insensitive search.
226
+ :param str uuid: Comma separated list of external tool UUIDs up to a
227
+ maximum of 100.
228
+ :param str tags: Comma separated list of tags.
229
+ :param bool draft: Boolean field indicating whether the workflow is a
230
+ draft or not.
231
+ :param str internal.registration_user_id: UserId that created the
232
+ workflow.
233
+ :param str type: External tool type. Allowed types: [CUSTOM_TOOL,
234
+ VARIANT_WALKER or WORKFLOW].
235
+ :param str scope: External tool scope. Allowed types:
236
+ [CLINICAL_INTERPRETATION, SECONDARY_ANALYSIS, RESEARCH or OTHER].
237
+ :param str workflow_repository_name: Workflow repository name.
238
+ :param str docker_name: Docker name.
239
+ :param str creation_date: Creation date. Format: yyyyMMddHHmmss.
240
+ Examples: >2018, 2017-2018, <201805.
241
+ :param str modification_date: Modification date. Format:
242
+ yyyyMMddHHmmss. Examples: >2018, 2017-2018, <201805.
243
+ :param str acl: Filter entries for which a user has the provided
244
+ permissions. Format: acl={user}:{permissions}. Example:
245
+ acl=john:WRITE,WRITE_ANNOTATIONS will return all entries for which
246
+ user john has both WRITE and WRITE_ANNOTATIONS permissions. Only
247
+ study owners or administrators can query by this field. .
248
+ :param str release: Release when it was created.
249
+ :param int snapshot: Snapshot value (Latest version of the entry in
250
+ the specified release).
251
+ :param bool deleted: Boolean to retrieve deleted entries.
252
+ """
253
+
254
+ options['field'] = field
255
+ return self._get(category='tools', resource='distinct', **options)
256
+
257
+ def search(self, **options):
258
+ """
259
+ User tool search method.
260
+ PATH: /{apiVersion}/tools/search
261
+
262
+ :param str include: Fields included in the response, whole JSON path
263
+ must be provided.
264
+ :param str exclude: Fields excluded in the response, whole JSON path
265
+ must be provided.
266
+ :param int limit: Number of results to be returned.
267
+ :param int skip: Number of results to skip.
268
+ :param bool count: Get the total number of results matching the query.
269
+ Deactivated by default.
270
+ :param str study: Study [[organization@]project:]study where study and
271
+ project can be either the ID or UUID.
272
+ :param str id: Comma separated list of external tool IDs up to a
273
+ maximum of 100. Also admits basic regular expressions using the
274
+ operator '~', i.e. '~{perl-regex}' e.g. '~value' for case
275
+ sensitive, '~/value/i' for case insensitive search.
276
+ :param str name: Comma separated list of external tool names up to a
277
+ maximum of 100. Also admits basic regular expressions using the
278
+ operator '~', i.e. '~{perl-regex}' e.g. '~value' for case
279
+ sensitive, '~/value/i' for case insensitive search.
280
+ :param str uuid: Comma separated list of external tool UUIDs up to a
281
+ maximum of 100.
282
+ :param str tags: Comma separated list of tags.
283
+ :param bool draft: Boolean field indicating whether the workflow is a
284
+ draft or not.
285
+ :param str internal.registration_user_id: UserId that created the
286
+ workflow.
287
+ :param str type: External tool type. Allowed types: [CUSTOM_TOOL,
288
+ VARIANT_WALKER or WORKFLOW].
289
+ :param str scope: External tool scope. Allowed types:
290
+ [CLINICAL_INTERPRETATION, SECONDARY_ANALYSIS, RESEARCH or OTHER].
291
+ :param str workflow_repository_name: Workflow repository name.
292
+ :param str docker_name: Docker name.
293
+ :param str creation_date: Creation date. Format: yyyyMMddHHmmss.
294
+ Examples: >2018, 2017-2018, <201805.
295
+ :param str modification_date: Modification date. Format:
296
+ yyyyMMddHHmmss. Examples: >2018, 2017-2018, <201805.
297
+ :param str acl: Filter entries for which a user has the provided
298
+ permissions. Format: acl={user}:{permissions}. Example:
299
+ acl=john:WRITE,WRITE_ANNOTATIONS will return all entries for which
300
+ user john has both WRITE and WRITE_ANNOTATIONS permissions. Only
301
+ study owners or administrators can query by this field. .
302
+ :param str release: Release when it was created.
303
+ :param int snapshot: Snapshot value (Latest version of the entry in
304
+ the specified release).
305
+ :param bool deleted: Boolean to retrieve deleted entries.
306
+ """
307
+
308
+ return self._get(category='tools', resource='search', **options)
309
+
310
+ def create_walker(self, data=None, **options):
311
+ """
312
+ Register a new user tool of type VARIANT_WALKER.
313
+ PATH: /{apiVersion}/tools/walker/create
314
+
315
+ :param dict data: JSON containing workflow information. (REQUIRED)
316
+ :param str include: Fields included in the response, whole JSON path
317
+ must be provided.
318
+ :param str exclude: Fields excluded in the response, whole JSON path
319
+ must be provided.
320
+ :param str study: Study [[organization@]project:]study where study and
321
+ project can be either the ID or UUID.
322
+ :param bool include_result: Flag indicating to include the created or
323
+ updated document result in the response.
324
+ """
325
+
326
+ return self._post(category='tools', resource='create', subcategory='walker', data=data, **options)
327
+
328
+ def create_workflow(self, data=None, **options):
329
+ """
330
+ Register a new user tool of type WORKFLOW.
331
+ PATH: /{apiVersion}/tools/workflow/create
332
+
333
+ :param dict data: JSON containing workflow information. (REQUIRED)
334
+ :param str include: Fields included in the response, whole JSON path
335
+ must be provided.
336
+ :param str exclude: Fields excluded in the response, whole JSON path
337
+ must be provided.
338
+ :param str study: Study [[organization@]project:]study where study and
339
+ project can be either the ID or UUID.
340
+ :param bool include_result: Flag indicating to include the created or
341
+ updated document result in the response.
342
+ """
343
+
344
+ return self._post(category='tools', resource='create', subcategory='workflow', data=data, **options)
345
+
346
+ def import_workflow(self, data=None, **options):
347
+ """
348
+ Import a user tool of type WORKFLOW.
349
+ PATH: /{apiVersion}/tools/workflow/import
350
+
351
+ :param dict data: Repository parameters. (REQUIRED)
352
+ :param str study: Study [[organization@]project:]study where study and
353
+ project can be either the ID or UUID.
354
+ """
355
+
356
+ return self._post(category='tools', resource='import', subcategory='workflow', data=data, **options)
357
+
358
+ def run_workflow(self, tool_id, data=None, **options):
359
+ """
360
+ Execute a user tool of type WORKFLOW.
361
+ PATH: /{apiVersion}/tools/workflow/{toolId}/run
362
+
363
+ :param dict data: External tool run parameters. (REQUIRED)
364
+ :param str tool_id: Comma separated list of external tool IDs up to a
365
+ maximum of 100. Also admits basic regular expressions using the
366
+ operator '~', i.e. '~{perl-regex}' e.g. '~value' for case
367
+ sensitive, '~/value/i' for case insensitive search. (REQUIRED)
368
+ :param int version: Tool version. If not provided, the latest version
369
+ will be used.
370
+ :param str study: Study [[organization@]project:]study where study and
371
+ project can be either the ID or UUID.
372
+ :param str job_id: Job ID. It must be a unique string within the
373
+ study. An ID will be autogenerated automatically if not provided.
374
+ :param str job_description: Job description.
375
+ :param str job_depends_on: Comma separated list of existing job IDs
376
+ the job will depend on.
377
+ :param str job_tags: Job tags.
378
+ :param str job_scheduled_start_time: Time when the job is scheduled to
379
+ start.
380
+ :param str job_priority: Priority of the job.
381
+ :param bool job_dry_run: Flag indicating that the job will be executed
382
+ in dry-run mode. In this mode, OpenCGA will validate that all
383
+ parameters and prerequisites are correctly set for successful
384
+ execution, but the job will not actually run.
385
+ """
386
+
387
+ return self._post(category='tools', resource='run', subcategory='workflow', second_query_id=tool_id, data=data, **options)
388
+
389
+ def update_workflow(self, tool_id, data=None, **options):
390
+ """
391
+ Update some user tool attributes.
392
+ PATH: /{apiVersion}/tools/workflow/{toolId}/update
393
+
394
+ :param str tool_id: Comma separated list of external tool IDs up to a
395
+ maximum of 100. Also admits basic regular expressions using the
396
+ operator '~', i.e. '~{perl-regex}' e.g. '~value' for case
397
+ sensitive, '~/value/i' for case insensitive search. (REQUIRED)
398
+ :param str include: Fields included in the response, whole JSON path
399
+ must be provided.
400
+ :param str exclude: Fields excluded in the response, whole JSON path
401
+ must be provided.
402
+ :param str study: Study [[organization@]project:]study where study and
403
+ project can be either the ID or UUID.
404
+ :param bool include_result: Flag indicating to include the created or
405
+ updated document result in the response.
406
+ :param dict data: body.
407
+ """
408
+
409
+ return self._post(category='tools', resource='update', subcategory='workflow', second_query_id=tool_id, data=data, **options)
410
+
411
+ def acl(self, tools, **options):
412
+ """
413
+ Returns the acl of the user tools. If member is provided, it will only
414
+ return the acl for the member.
415
+ PATH: /{apiVersion}/tools/{tools}/acl
416
+
417
+ :param str tools: Comma separated of external tool ids. (REQUIRED)
418
+ :param str study: Study [[organization@]project:]study where study and
419
+ project can be either the ID or UUID.
420
+ :param str member: User or group id.
421
+ :param bool silent: Boolean to retrieve all possible entries that are
422
+ queried for, false to raise an exception whenever one of the
423
+ entries looked for cannot be shown for whichever reason.
424
+ """
425
+
426
+ return self._get(category='tools', resource='acl', query_id=tools, **options)
427
+
428
+ def delete(self, tools, **options):
429
+ """
430
+ Delete user tools.
431
+ PATH: /{apiVersion}/tools/{tools}/delete
432
+
433
+ :param str tools: Comma separated of external tool ids. (REQUIRED)
434
+ :param str study: Study [[organization@]project:]study where study and
435
+ project can be either the ID or UUID.
436
+ """
437
+
438
+ return self._delete(category='tools', resource='delete', query_id=tools, **options)
439
+
440
+ def info(self, tools, **options):
441
+ """
442
+ Get user tool information.
443
+ PATH: /{apiVersion}/tools/{tools}/info
444
+
445
+ :param str tools: Comma separated of external tool ids. (REQUIRED)
446
+ :param str include: Fields included in the response, whole JSON path
447
+ must be provided.
448
+ :param str exclude: Fields excluded in the response, whole JSON path
449
+ must be provided.
450
+ :param str study: Study [[organization@]project:]study where study and
451
+ project can be either the ID or UUID.
452
+ :param str version: Comma separated list of external tool versions.
453
+ 'all' to get all the external tool versions. Not supported if
454
+ multiple external tool ids are provided.
455
+ :param bool deleted: Boolean to retrieve deleted entries.
456
+ """
457
+
458
+ return self._get(category='tools', resource='info', query_id=tools, **options)
459
+
@@ -118,7 +118,7 @@ class Workflow(_ParentRestClient):
118
118
  Execute a workflow analysis.
119
119
  PATH: /{apiVersion}/workflows/run
120
120
 
121
- :param dict data: NextFlow run parameters. (REQUIRED)
121
+ :param dict data: Workflow tool run parameters. (REQUIRED)
122
122
  :param str study: Study [[organization@]project:]study where study and
123
123
  project can be either the ID or UUID.
124
124
  :param str job_id: Job ID. It must be a unique string within the
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: pyxetabase
3
- Version: 4.0.0.dev1
3
+ Version: 4.0.0.dev2
4
4
  Summary: A REST client for OpenCGA enterprise REST web services
5
5
  Author: Daniel Perez-Gil
6
6
  Author-email: daniel.perez@zettagenomics.com
@@ -33,6 +33,7 @@ pyxetabase/rest_clients/project_client.py
33
33
  pyxetabase/rest_clients/sample_client.py
34
34
  pyxetabase/rest_clients/study_client.py
35
35
  pyxetabase/rest_clients/user_client.py
36
+ pyxetabase/rest_clients/user_tool_client.py
36
37
  pyxetabase/rest_clients/variant_client.py
37
38
  pyxetabase/rest_clients/variant_operation_client.py
38
39
  pyxetabase/rest_clients/workflow_client.py
@@ -14,7 +14,7 @@ with open(path.join(here, 'README.rst'), encoding='utf-8') as f:
14
14
 
15
15
  setup(
16
16
  name='pyxetabase',
17
- version='4.0.0.dev1',
17
+ version='4.0.0.dev2',
18
18
  description='A REST client for OpenCGA enterprise REST web services',
19
19
  long_description=long_description,
20
20
  long_description_content_type='text/x-rst',
File without changes