# IbmWorkloadSchedulerApi.UserPreferencesApi

All URIs are relative to *https://localhost/ibm/TWSWebUI/Simple/rest*

Method | HTTP request | Description
------------- | ------------- | -------------
[**getTimezone**](UserPreferencesApi.md#getTimezone) | **GET** /UserPreferences/timezone | 
[**setTimezone**](UserPreferencesApi.md#setTimezone) | **POST** /UserPreferences/timezone | 
[**updateTimezone**](UserPreferencesApi.md#updateTimezone) | **PUT** /UserPreferences/timezone | 


<a name="getTimezone"></a>
# **getTimezone**
> &#39;String&#39; getTimezone(tenantId, opts)



Get the user time zone. 

### Example
```javascript
var IbmWorkloadSchedulerApi = require('ibm-workload-scheduler-api');
var defaultClient = IbmWorkloadSchedulerApi.ApiClient.default;

// Configure HTTP basic authorization: basicAuth
var basicAuth = defaultClient.authentications['basicAuth'];
basicAuth.username = 'YOUR USERNAME';
basicAuth.password = 'YOUR PASSWORD';

var apiInstance = new IbmWorkloadSchedulerApi.UserPreferencesApi();

var tenantId = "tenantId_example"; // String | The id of the Tenant that is making the call

var opts = { 
  'engineName': "engineName_example", // String | The name of the engine to connect to. Leave default in cloud environments
  'engineOwner': "engineOwner_example" // String | The owner of the engine definition. Leave default in cloud environments.
};

var callback = function(error, data, response) {
  if (error) {
    console.error(error);
  } else {
    console.log('API called successfully. Returned data: ' + data);
  }
};
apiInstance.getTimezone(tenantId, opts, callback);
```

### Parameters

Name | Type | Description  | Notes
------------- | ------------- | ------------- | -------------
 **tenantId** | **String**| The id of the Tenant that is making the call | 
 **engineName** | **String**| The name of the engine to connect to. Leave default in cloud environments | [optional] 
 **engineOwner** | **String**| The owner of the engine definition. Leave default in cloud environments. | [optional] 

### Return type

**&#39;String&#39;**

### Authorization

[basicAuth](../README.md#basicAuth)

### HTTP request headers

 - **Content-Type**: Not defined
 - **Accept**: application/json

<a name="setTimezone"></a>
# **setTimezone**
> &#39;String&#39; setTimezone(body, tenantId, opts)



Set the user time zone.. 

### Example
```javascript
var IbmWorkloadSchedulerApi = require('ibm-workload-scheduler-api');
var defaultClient = IbmWorkloadSchedulerApi.ApiClient.default;

// Configure HTTP basic authorization: basicAuth
var basicAuth = defaultClient.authentications['basicAuth'];
basicAuth.username = 'YOUR USERNAME';
basicAuth.password = 'YOUR PASSWORD';

var apiInstance = new IbmWorkloadSchedulerApi.UserPreferencesApi();

var body = "body_example"; // String | Time zone

var tenantId = "tenantId_example"; // String | The id of the Tenant that is making the call

var opts = { 
  'engineName': "engineName_example", // String | The name of the engine to connect to. Leave default in cloud environments
  'engineOwner': "engineOwner_example" // String | The owner of the engine definition. Leave default in cloud environments.
};

var callback = function(error, data, response) {
  if (error) {
    console.error(error);
  } else {
    console.log('API called successfully. Returned data: ' + data);
  }
};
apiInstance.setTimezone(body, tenantId, opts, callback);
```

### Parameters

Name | Type | Description  | Notes
------------- | ------------- | ------------- | -------------
 **body** | **String**| Time zone | 
 **tenantId** | **String**| The id of the Tenant that is making the call | 
 **engineName** | **String**| The name of the engine to connect to. Leave default in cloud environments | [optional] 
 **engineOwner** | **String**| The owner of the engine definition. Leave default in cloud environments. | [optional] 

### Return type

**&#39;String&#39;**

### Authorization

[basicAuth](../README.md#basicAuth)

### HTTP request headers

 - **Content-Type**: application/json
 - **Accept**: application/json

<a name="updateTimezone"></a>
# **updateTimezone**
> &#39;String&#39; updateTimezone(body, tenantId, opts)



Update the user time zone. 

### Example
```javascript
var IbmWorkloadSchedulerApi = require('ibm-workload-scheduler-api');
var defaultClient = IbmWorkloadSchedulerApi.ApiClient.default;

// Configure HTTP basic authorization: basicAuth
var basicAuth = defaultClient.authentications['basicAuth'];
basicAuth.username = 'YOUR USERNAME';
basicAuth.password = 'YOUR PASSWORD';

var apiInstance = new IbmWorkloadSchedulerApi.UserPreferencesApi();

var body = "body_example"; // String | Time zone

var tenantId = "tenantId_example"; // String | The id of the Tenant that is making the call

var opts = { 
  'engineName': "engineName_example", // String | The name of the engine to connect to. Leave default in cloud environments
  'engineOwner': "engineOwner_example" // String | The owner of the engine definition. Leave default in cloud environments.
};

var callback = function(error, data, response) {
  if (error) {
    console.error(error);
  } else {
    console.log('API called successfully. Returned data: ' + data);
  }
};
apiInstance.updateTimezone(body, tenantId, opts, callback);
```

### Parameters

Name | Type | Description  | Notes
------------- | ------------- | ------------- | -------------
 **body** | **String**| Time zone | 
 **tenantId** | **String**| The id of the Tenant that is making the call | 
 **engineName** | **String**| The name of the engine to connect to. Leave default in cloud environments | [optional] 
 **engineOwner** | **String**| The owner of the engine definition. Leave default in cloud environments. | [optional] 

### Return type

**&#39;String&#39;**

### Authorization

[basicAuth](../README.md#basicAuth)

### HTTP request headers

 - **Content-Type**: application/json
 - **Accept**: application/json

