ApplicationService
ApplicationService(tm1_rest)
Bases: ObjectService
Service to Read and Write TM1 Applications
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
tm1_rest
|
RestService
|
|
required |
Source code in TM1py/Services/ApplicationService.py
create(application, private=False, **kwargs)
Create Planning Analytics application
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
application
|
Union[Application, DocumentApplication]
|
instance of Application |
required |
private
|
bool
|
boolean |
False
|
Returns:
| Type | Description |
|---|---|
Response
|
|
Source code in TM1py/Services/ApplicationService.py
create_document_from_file(path_to_file, application_path, application_name, private=False, **kwargs)
Create DocumentApplication in TM1 from local file
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
path_to_file
|
str
|
|
required |
application_path
|
str
|
|
required |
application_name
|
str
|
|
required |
private
|
bool
|
|
False
|
Returns:
| Type | Description |
|---|---|
Response
|
|
Source code in TM1py/Services/ApplicationService.py
delete(path, application_type, application_name, private=False, **kwargs)
Delete Planning Analytics application reference
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
path
|
str
|
path through folder structure to delete the applications entry. For instance: "Finance/Reports" |
required |
application_type
|
Union[str, ApplicationTypes]
|
type of the to be deleted application entry |
required |
application_name
|
str
|
name of the to be deleted application entry |
required |
private
|
bool
|
Access level of the to be deleted object |
False
|
Returns:
| Type | Description |
|---|---|
Response
|
|
Source code in TM1py/Services/ApplicationService.py
exists(path, application_type, name, private=False, **kwargs)
Check if application exists
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
path
|
str
|
|
required |
application_type
|
Union[str, ApplicationTypes]
|
|
required |
name
|
str
|
|
required |
private
|
bool
|
|
False
|
Returns:
| Type | Description |
|---|---|
bool
|
|
Source code in TM1py/Services/ApplicationService.py
get(path, application_type, name, private=False, **kwargs)
Retrieve Planning Analytics Application
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
path
|
str
|
path with forward slashes |
required |
application_type
|
Union[str, ApplicationTypes]
|
str or ApplicationType from Enum |
required |
name
|
str
|
|
required |
private
|
bool
|
|
False
|
Returns:
| Type | Description |
|---|---|
Application
|
|
Source code in TM1py/Services/ApplicationService.py
73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 | |
get_all_private_root_names(**kwargs)
Source code in TM1py/Services/ApplicationService.py
get_all_public_root_names(**kwargs)
Retrieve all public root application names.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
kwargs
|
Additional arguments for the REST request. |
{}
|
Returns:
| Type | Description |
|---|---|
|
List of public root application names. |
Source code in TM1py/Services/ApplicationService.py
get_document(path, name, private=False, **kwargs)
Get Excel Application from TM1 Server in binary format. Can be dumped to file.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
path
|
str
|
path through folder structure to application. For instance: "Finance/P&L.xlsx" |
required |
name
|
str
|
name of the application |
required |
private
|
bool
|
boolean |
False
|
Returns:
| Type | Description |
|---|---|
DocumentApplication
|
Return DocumentApplication |
Source code in TM1py/Services/ApplicationService.py
get_names(path, private=False, **kwargs)
Retrieve Planning Analytics Application names in given path
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
path
|
str
|
path with forward slashes |
required |
private
|
bool
|
boolean |
False
|
Returns:
| Type | Description |
|---|---|
|
list of application names |
Source code in TM1py/Services/ApplicationService.py
rename(path, application_type, application_name, new_application_name, private=False, **kwargs)
Source code in TM1py/Services/ApplicationService.py
update(application, private=False, **kwargs)
Update Planning Analytics application
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
application
|
Union[Application, DocumentApplication]
|
instance of Application |
required |
private
|
bool
|
boolean |
False
|
Returns:
| Type | Description |
|---|---|
Response
|
|
Source code in TM1py/Services/ApplicationService.py
update_document_from_file(path_to_file, application_path, application_name, private=False, **kwargs)
Update DocumentApplication in TM1 from local file
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
path_to_file
|
str
|
|
required |
application_path
|
str
|
|
required |
application_name
|
str
|
|
required |
private
|
bool
|
|
False
|
Returns:
| Type | Description |
|---|---|
Response
|
|
Source code in TM1py/Services/ApplicationService.py
update_or_create(application, private=False, **kwargs)
Update or create Planning Analytics application
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
application
|
Union[Application, DocumentApplication]
|
instance of Application |
required |
private
|
bool
|
boolean |
False
|
Returns:
| Type | Description |
|---|---|
Response
|
Response |
Source code in TM1py/Services/ApplicationService.py
update_or_create_document_from_file(path, name, path_to_file, private=False, **kwargs)
Update or create application from file
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
path
|
str
|
application path on server, i.e. 'Finance/Reports' |
required |
name
|
str
|
name of the application on server, i.e. 'Flash.xlsx' |
required |
path_to_file
|
str
|
full local file path of file, i.e. 'C:\Users\User\Flash.xslx' |
required |
private
|
bool
|
access level of the object |
False
|
Returns:
| Type | Description |
|---|---|
Response
|
Response |