# BuyBorghiMobileServices.DeviceApi

All URIs are relative to *http://buyborghi.imolinfo.it/BuyBorghiApi/rest*

Method | HTTP request | Description
------------- | ------------- | -------------
[**route28**](DeviceApi.md#route28) | **POST** /device/ | Registra il dispositivo mobile sul push notification server
[**route29**](DeviceApi.md#route29) | **DELETE** /device/{token} | Rimuove il dispositivo mobile dalla piattaforma


<a name="route28"></a>
# **route28**
> route28(body)

Registra il dispositivo mobile sul push notification server

### Example
```javascript
var BuyBorghiMobileServices = require('buy_borghi_mobile_services');

var apiInstance = new BuyBorghiMobileServices.DeviceApi();

var body = new BuyBorghiMobileServices.DeviceToken(); // DeviceToken | 


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

### Parameters

Name | Type | Description  | Notes
------------- | ------------- | ------------- | -------------
 **body** | [**DeviceToken**](DeviceToken.md)|  | 

### Return type

null (empty response body)

### Authorization

No authorization required

### HTTP request headers

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

<a name="route29"></a>
# **route29**
> BaseResult route29(token, device)

Rimuove il dispositivo mobile dalla piattaforma

### Example
```javascript
var BuyBorghiMobileServices = require('buy_borghi_mobile_services');

var apiInstance = new BuyBorghiMobileServices.DeviceApi();

var token = "token_example"; // String | Token da rimuovere dal push server notification e dalla pagina utente. Valore del tipo 'alfanumerico_tipoDevice'

var device = "device_example"; // String | Tipo di dispositivo mobile


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

### Parameters

Name | Type | Description  | Notes
------------- | ------------- | ------------- | -------------
 **token** | **String**| Token da rimuovere dal push server notification e dalla pagina utente. Valore del tipo 'alfanumerico_tipoDevice' | 
 **device** | **String**| Tipo di dispositivo mobile | 

### Return type

[**BaseResult**](BaseResult.md)

### Authorization

No authorization required

### HTTP request headers

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

