Add devices.destroy API call
This commit is contained in:
		
							父節點
							
								
									35405f8612
								
							
						
					
					
						當前提交
						e930881e0f
					
				@ -71,6 +71,21 @@ OAUTH3.api['devices.detach'] = function (providerUri, opts) {
 | 
			
		||||
  });
 | 
			
		||||
};
 | 
			
		||||
 | 
			
		||||
OAUTH3.api['devices.destroy'] = function (providerUri, opts) {
 | 
			
		||||
  var session = opts.session;
 | 
			
		||||
  var device = opts.device;
 | 
			
		||||
 | 
			
		||||
  return OAUTH3.request({
 | 
			
		||||
    url: OAUTH3.url.normalize(providerUri)
 | 
			
		||||
      + '/api/com.daplie.domains/accounts/' + session.token.sub
 | 
			
		||||
			+ '/devices/' + device
 | 
			
		||||
  , method: 'DELETE'
 | 
			
		||||
  , session: session
 | 
			
		||||
  }, {}).then(function (res) {
 | 
			
		||||
    return res.data.device || res.data;
 | 
			
		||||
  });
 | 
			
		||||
};
 | 
			
		||||
 | 
			
		||||
OAUTH3.api['dns.set'] = function (providerUri, opts) {
 | 
			
		||||
  var session = opts.session;
 | 
			
		||||
  var tld = opts.tld;
 | 
			
		||||
 | 
			
		||||
		載入中…
	
	
			
			x
			
			
		
	
		新增問題並參考
	
	Block a user