# CloudSmlApi.ScoringsApi

All URIs are relative to *https://localhost/api/v1*

Method | HTTP request | Description
------------- | ------------- | -------------
[**deleteScoringById**](ScoringsApi.md#deleteScoringById) | **DELETE** /scorings/{scoring_id} | Delete a scoring by ID
[**getScoringById**](ScoringsApi.md#getScoringById) | **GET** /scorings/{scoring_id} | Get scoring details by ID
[**getScorings**](ScoringsApi.md#getScorings) | **GET** /scorings/ | List of scorings
[**optionsScoringById**](ScoringsApi.md#optionsScoringById) | **OPTIONS** /scorings/{scoring_id} | Check which methods are allowed
[**optionsScorings**](ScoringsApi.md#optionsScorings) | **OPTIONS** /scorings/ | Check which methods are allowed
[**patchScoringById**](ScoringsApi.md#patchScoringById) | **PATCH** /scorings/{scoring_id} | Modify scoring details by ID
[**scoringModel**](ScoringsApi.md#scoringModel) | **POST** /scorings/ | Score a model


<a name="deleteScoringById"></a>
# **deleteScoringById**
> deleteScoringById(scoringId)

Delete a scoring by ID

**PERMISSIONS: Workspace Member may execute this action**

### Example
```javascript
var CloudSmlApi = require('cloud_sml_api');
var defaultClient = CloudSmlApi.ApiClient.default;

// Configure OAuth2 access token for authorization: oauth2_password
var oauth2_password = defaultClient.authentications['oauth2_password'];
oauth2_password.accessToken = 'YOUR ACCESS TOKEN';

var apiInstance = new CloudSmlApi.ScoringsApi();

var scoringId = 56; // Number | 


var callback = function(error, data, response) {
  if (error) {
    console.error(error);
  } else {
    console.log('API called successfully.');
  }
};
apiInstance.deleteScoringById(scoringId, callback);
```

### Parameters

Name | Type | Description  | Notes
------------- | ------------- | ------------- | -------------
 **scoringId** | **Number**|  | 

### Return type

null (empty response body)

### Authorization

[oauth2_password](../README.md#oauth2_password)

### HTTP request headers

 - **Content-Type**: application/json
 - **Accept**: application/json

<a name="getScoringById"></a>
# **getScoringById**
> DetailedScoring getScoringById(scoringId)

Get scoring details by ID

**PERMISSIONS: Workspace Member may execute this action**

### Example
```javascript
var CloudSmlApi = require('cloud_sml_api');
var defaultClient = CloudSmlApi.ApiClient.default;

// Configure OAuth2 access token for authorization: oauth2_password
var oauth2_password = defaultClient.authentications['oauth2_password'];
oauth2_password.accessToken = 'YOUR ACCESS TOKEN';

var apiInstance = new CloudSmlApi.ScoringsApi();

var scoringId = 56; // Number | 


var callback = function(error, data, response) {
  if (error) {
    console.error(error);
  } else {
    console.log('API called successfully. Returned data: ' + data);
  }
};
apiInstance.getScoringById(scoringId, callback);
```

### Parameters

Name | Type | Description  | Notes
------------- | ------------- | ------------- | -------------
 **scoringId** | **Number**|  | 

### Return type

[**DetailedScoring**](DetailedScoring.md)

### Authorization

[oauth2_password](../README.md#oauth2_password)

### HTTP request headers

 - **Content-Type**: application/json
 - **Accept**: application/json

<a name="getScorings"></a>
# **getScorings**
> [BaseScoring] getScorings(opts)

List of scorings

**PERMISSIONS: At least Active user is required.**   Returns a list of scorings starting from &#x60;&#x60;offset&#x60;&#x60; limited by &#x60;&#x60;limit&#x60;&#x60; parameter.

### Example
```javascript
var CloudSmlApi = require('cloud_sml_api');
var defaultClient = CloudSmlApi.ApiClient.default;

// Configure OAuth2 access token for authorization: oauth2_password
var oauth2_password = defaultClient.authentications['oauth2_password'];
oauth2_password.accessToken = 'YOUR ACCESS TOKEN';

var apiInstance = new CloudSmlApi.ScoringsApi();

var opts = { 
  'offset': 56, // Number | a number of items to skip, default is 0.
  'limit': 20 // Number | limit a number of items (allowed range is 1-100), default is 20.
};

var callback = function(error, data, response) {
  if (error) {
    console.error(error);
  } else {
    console.log('API called successfully. Returned data: ' + data);
  }
};
apiInstance.getScorings(opts, callback);
```

### Parameters

Name | Type | Description  | Notes
------------- | ------------- | ------------- | -------------
 **offset** | **Number**| a number of items to skip, default is 0. | [optional] 
 **limit** | **Number**| limit a number of items (allowed range is 1-100), default is 20. | [optional] [default to 20]

### Return type

[**[BaseScoring]**](BaseScoring.md)

### Authorization

[oauth2_password](../README.md#oauth2_password)

### HTTP request headers

 - **Content-Type**: application/json
 - **Accept**: application/json

<a name="optionsScoringById"></a>
# **optionsScoringById**
> optionsScoringById(scoringId)

Check which methods are allowed

Use this method if you need to know what operations are allowed to be performed on this endpoint, e.g. to decide wether to display a button in your UI.  The list of allowed methods is provided in &#x60;Allow&#x60; response header.

### Example
```javascript
var CloudSmlApi = require('cloud_sml_api');

var apiInstance = new CloudSmlApi.ScoringsApi();

var scoringId = 56; // Number | 


var callback = function(error, data, response) {
  if (error) {
    console.error(error);
  } else {
    console.log('API called successfully.');
  }
};
apiInstance.optionsScoringById(scoringId, callback);
```

### Parameters

Name | Type | Description  | Notes
------------- | ------------- | ------------- | -------------
 **scoringId** | **Number**|  | 

### Return type

null (empty response body)

### Authorization

No authorization required

### HTTP request headers

 - **Content-Type**: application/json
 - **Accept**: application/json

<a name="optionsScorings"></a>
# **optionsScorings**
> optionsScorings()

Check which methods are allowed

Use this method if you need to know what operations are allowed to be performed on this endpoint, e.g. to decide wether to display a button in your UI.  The list of allowed methods is provided in &#x60;Allow&#x60; response header.

### Example
```javascript
var CloudSmlApi = require('cloud_sml_api');

var apiInstance = new CloudSmlApi.ScoringsApi();

var callback = function(error, data, response) {
  if (error) {
    console.error(error);
  } else {
    console.log('API called successfully.');
  }
};
apiInstance.optionsScorings(callback);
```

### Parameters
This endpoint does not need any parameter.

### Return type

null (empty response body)

### Authorization

No authorization required

### HTTP request headers

 - **Content-Type**: application/json
 - **Accept**: application/json

<a name="patchScoringById"></a>
# **patchScoringById**
> DetailedScoring patchScoringById(scoringIdbody)

Modify scoring details by ID

**PERMISSIONS: Workspace Member may execute this action**

### Example
```javascript
var CloudSmlApi = require('cloud_sml_api');
var defaultClient = CloudSmlApi.ApiClient.default;

// Configure OAuth2 access token for authorization: oauth2_password
var oauth2_password = defaultClient.authentications['oauth2_password'];
oauth2_password.accessToken = 'YOUR ACCESS TOKEN';

var apiInstance = new CloudSmlApi.ScoringsApi();

var scoringId = 56; // Number | 

var body = [new CloudSmlApi.Body2()]; // [Body2] | 


var callback = function(error, data, response) {
  if (error) {
    console.error(error);
  } else {
    console.log('API called successfully. Returned data: ' + data);
  }
};
apiInstance.patchScoringById(scoringIdbody, callback);
```

### Parameters

Name | Type | Description  | Notes
------------- | ------------- | ------------- | -------------
 **scoringId** | **Number**|  | 
 **body** | [**[Body2]**](Body2.md)|  | 

### Return type

[**DetailedScoring**](DetailedScoring.md)

### Authorization

[oauth2_password](../README.md#oauth2_password)

### HTTP request headers

 - **Content-Type**: application/json
 - **Accept**: application/json

<a name="scoringModel"></a>
# **scoringModel**
> DetailedScoring scoringModel(name, opts)

Score a model

**PERMISSIONS: At least Active user is required.**

### Example
```javascript
var CloudSmlApi = require('cloud_sml_api');
var defaultClient = CloudSmlApi.ApiClient.default;

// Configure OAuth2 access token for authorization: oauth2_password
var oauth2_password = defaultClient.authentications['oauth2_password'];
oauth2_password.accessToken = 'YOUR ACCESS TOKEN';

var apiInstance = new CloudSmlApi.ScoringsApi();

var name = "name_example"; // String | 

var opts = { 
  'dataTransformationId': "dataTransformationId_example", // String | 
  'predictiveModelId': "predictiveModelId_example" // String | 
};

var callback = function(error, data, response) {
  if (error) {
    console.error(error);
  } else {
    console.log('API called successfully. Returned data: ' + data);
  }
};
apiInstance.scoringModel(name, opts, callback);
```

### Parameters

Name | Type | Description  | Notes
------------- | ------------- | ------------- | -------------
 **name** | **String**|  | 
 **dataTransformationId** | **String**|  | [optional] 
 **predictiveModelId** | **String**|  | [optional] 

### Return type

[**DetailedScoring**](DetailedScoring.md)

### Authorization

[oauth2_password](../README.md#oauth2_password)

### HTTP request headers

 - **Content-Type**: application/x-www-form-urlencoded, multipart/form-data
 - **Accept**: application/json

