{"info":{"_postman_id":"dbd8322b-007f-41f1-9594-1da862481944","name":"PDU Controller Rest API","description":"<html><head></head><body><p>This collection allows for control of switched power distribution units.</p>\n<p>The host <em>must</em> be localhost:4000. Edit the pre-request script to set variable values.</p>\n<p>In every request, the value of <code>socket</code> ranges from 1 to 8. The possible values of <code>name</code> are obtained from the List All PDUs GET request.</p>\n</body></html>","schema":"https://schema.getpostman.com/json/collection/v2.0.0/collection.json","toc":[],"owner":"10212413","collectionId":"dbd8322b-007f-41f1-9594-1da862481944","publishedId":"SzzkdxSc","public":true,"customColor":{"top-bar":"FFFFFF","right-sidebar":"303030","highlight":"EF5B25"},"publishDate":"2020-06-18T13:59:31.000Z"},"item":[{"name":"List All PDUs","id":"dc518e5f-dd3d-427b-bca2-5c66f781a6c4","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"GET","header":[],"url":"http://localhost:4000/pdu","description":"<p>Get list of all PDUs by name. </p>\n","urlObject":{"protocol":"http","port":"4000","path":["pdu"],"host":["localhost"],"query":[],"variable":[]}},"response":[],"_postman_id":"dc518e5f-dd3d-427b-bca2-5c66f781a6c4"},{"name":"Get PDU Config","event":[{"listen":"prerequest","script":{"id":"aed1ee2c-1c09-41d5-a5b7-ee82034903f2","exec":["pm.environment.set(\"name\", \"pdu03\");"],"type":"text/javascript"}}],"id":"ee94a332-80b1-4ae9-b8c1-fbb7f73e2fa9","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"GET","header":[],"url":"http://localhost:4000/pdu/{{name}}","description":"<p>Get list of all devices plugged into power bar <code>name</code>.</p>\n","urlObject":{"protocol":"http","port":"4000","path":["pdu","{{name}}"],"host":["localhost"],"query":[],"variable":[]}},"response":[],"_postman_id":"ee94a332-80b1-4ae9-b8c1-fbb7f73e2fa9"},{"name":"Set Socket State","event":[{"listen":"prerequest","script":{"id":"8c30ae7b-ff23-4eff-b076-96f9ea17c351","exec":["pm.environment.set(\"name\", \"pdu03\");","pm.environment.set(\"socket\", \"6\");"],"type":"text/javascript"}}],"id":"60d51aa2-7e07-481d-8ada-9140abc8bac0","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"PUT","header":[],"body":{"mode":"raw","raw":"{\n\t\"action\" : \"IMMEDIATE_OFF\"\n}","options":{"raw":{"language":"json"}}},"url":"localhost:4000/pdu/{{name}}/socket/{{socket}}/state","description":"<p>Set socket state <code>socket</code> on power bar <code>name</code>. The available actions are <code>IMMEDIATE_ON</code>, <code>IMMEDIATE_OFF</code>, and <code>IMMEDIATE_REBOOT</code>.</p>\n","urlObject":{"port":"4000","path":["pdu","{{name}}","socket","{{socket}}","state"],"host":["localhost"],"query":[],"variable":[]}},"response":[],"_postman_id":"60d51aa2-7e07-481d-8ada-9140abc8bac0"},{"name":"Get Socket State","event":[{"listen":"prerequest","script":{"id":"34a633b3-846a-4b80-8b8a-98ca437119f0","exec":["pm.environment.set(\"name\", \"pdu03\");","pm.environment.set(\"socket\", \"6\");"],"type":"text/javascript"}}],"id":"86b008fb-f9b1-49aa-9b40-8f0eefae14bd","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"GET","header":[],"body":{"mode":"raw","raw":"","options":{"raw":{"language":"json"}}},"url":"localhost:4000/pdu/{{name}}/socket/{{socket}}/state","description":"<p>Get power state of <code>socket</code> from powerbar <code>name</code>. The possible states are <code>ON</code> and <code>OFF</code>.</p>\n","urlObject":{"port":"4000","path":["pdu","{{name}}","socket","{{socket}}","state"],"host":["localhost"],"query":[],"variable":[]}},"response":[],"_postman_id":"86b008fb-f9b1-49aa-9b40-8f0eefae14bd"},{"name":"Get Socket Name","event":[{"listen":"prerequest","script":{"id":"48e6e3ee-39f3-4a91-9368-febb86ac4507","exec":["pm.environment.set(\"name\", \"pdu03\");","pm.environment.set(\"socket\", \"6\");"],"type":"text/javascript"}}],"id":"98bbdf24-3ed7-41f1-b8fa-b966eb99cf12","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"GET","header":[],"body":{"mode":"raw","raw":"","options":{"raw":{"language":"json"}}},"url":"localhost:4000/pdu/{{name}}/socket/{{socket}}/name","description":"<p>Get name of device plugged in to powerbar <code>name</code> in <code>socket</code>. </p>\n","urlObject":{"port":"4000","path":["pdu","{{name}}","socket","{{socket}}","name"],"host":["localhost"],"query":[],"variable":[]}},"response":[],"_postman_id":"98bbdf24-3ed7-41f1-b8fa-b966eb99cf12"}]}