Project

General

Profile

Bug #3874

Updated by Jonathan CLARKE over 10 years ago

<pre> 
 # curl -X GET -H "X-API-Version: 2" -H "X-API-Token: wRY5qwr8k6XTY7aaRdxFl3csDanZfuZG"    http://buildbox.internal/rudder/api/nodes/pending/8c979d92-8c21-4ce0-a383-27ce7cc0997b 
 <?xml version="1.0" encoding="UTF-8"?> 
 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> 
 <html> <body>The Requested URL /rudder/api/nodes/pending/8c979d92-8c21-4ce0-a383-27ce7cc0997b was not found on this server</body> </html>   

 # curl -GET -H "X-API-Version: 2" -H "X-API-Token: wRY5qwr8k6XTY7aaRdxFl3csDanZfuZG"    http://buildbox.internal/rudder/api/nodes/pending 
 {"action":"listPendingNodes","result":"success","data":{"nodes":[{"id":"8c979d92-8c21-4ce0-a383-27ce7cc0997b","status":"pending","hostname":"ovz2.internal","osName":"Scientific"}]}} 

 # curl -X GET -H "X-API-Version: 2" -H "X-API-Token: wRY5qwr8k6XTY7aaRdxFl3csDanZfuZG"    http://buildbox.internal/rudder/api/nodes/pending -d "id=8c979d92-8c21-4ce0-a383-27ce7cc0997b"  
 {"action":"listPendingNodes","result":"success","data":{"nodes":[{"id":"8c979d92-8c21-4ce0-a383-27ce7cc0997b","status":"pending","hostname":"ovz2.internal","osName":"Scientific"}]}} 

 # curl -X POST -H "X-API-Version: 2" -H "X-API-Token: wRY5qwr8k6XTY7aaRdxFl3csDanZfuZG"    http://buildbox.internal/rudder/api/nodes/pending -d "id=8c979d92-8c21-4ce0-a383-27ce7cc0997b" -d "status=accepted" 
 {"action":"changePendingNodeStatus","result":"error","errorDetails":"You must add a node id as target"} 

 # curl -X POST -H "X-API-Version: 2" -H "X-API-Token: wRY5qwr8k6XTY7aaRdxFl3csDanZfuZG"    http://buildbox.internal/rudder/api/nodes/pending/8c979d92-8c21-4ce0-a383-27ce7cc0997b -d "status=accepted" 
 <?xml version="1.0" encoding="UTF-8"?> 
 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> 
 <html> <body>The Requested URL /rudder/api/nodes/pending/8c979d92-8c21-4ce0-a383-27ce7cc0997b was not found on this server</body> </html>   
 
 # curl -X POST -H "X-API-Version: 2" -H "X-API-Token: wRY5qwr8k6XTY7aaRdxFl3csDanZfuZG"    http://buildbox.internal/rudder/api/nodes/8c979d92-8c21-4ce0-a383-27ce7cc0997b -d "status=accepted" 
 <?xml version="1.0" encoding="UTF-8"?> 
 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> 
 <html> <body>The Requested URL /rudder/api/nodes/8c979d92-8c21-4ce0-a383-27ce7cc0997b was not found on this server</body> </html>   

 # curl -X POST -H "X-API-Version: 2" -H "X-API-Token: wRY5qwr8k6XTY7aaRdxFl3csDanZfuZG"    http://buildbox.internal/rudder/api/nodes -d "id=8c979d92-8c21-4ce0-a383-27ce7cc0997b" -d "status=accepted" 
 <?xml version="1.0" encoding="UTF-8"?> 
 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> 
 <html> <body>The Requested URL /rudder/api/nodes was not found on this server</body> </html>   
 </pre> 

   


 This makes impossible to accept nodes trough the API or i missed something in the API documentation.

Back