{"info":{"_postman_id":"fba9b998-cd30-4a67-972f-45d068727efd","name":"Event Manager","description":"<html><head></head><body><p>This endpoint can be used to create/update/get/delete an event. An event refers to any visual event that can be detected from one video frame, for example \"door left open\".<br>Once an event is created, a model gets trained based on the positive and negative samples provided for that event. </p>\n</body></html>","schema":"https://schema.getpostman.com/json/collection/v2.0.0/collection.json","toc":[],"owner":"13573136","collectionId":"fba9b998-cd30-4a67-972f-45d068727efd","publishedId":"TVewYj9a","public":true,"customColor":{"top-bar":"FFFFFF","right-sidebar":"303030","highlight":"3578E5"},"publishDate":"2020-11-24T03:23:36.000Z"},"item":[{"name":"Create a new event","id":"5f0b89da-bb3b-472b-95fe-0b1237e893a3","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"POST","header":[{"key":"Content-Type","value":"application/json","type":"text"}],"body":{"mode":"raw","raw":"{\n    \"event_id\": \"ckk84fpq\",\n    \"event_name\": \"Door left open\",\n    \"camera_id\": \"czp87vy\",\n    \"n_positive\": 2,\n    \"n_negative\": 3,\n    \"confidence_threshold\": 0.75,\n    \"client_id\": \"ckk3edsq\",\n    \"samples_bucket\": \"xyzbucket\",\n    \"samples_folder\": \"xyzfolder\"\n}","options":{"raw":{"language":"json"}}},"url":"https://visualone.info/event","description":"<p>Used to create a new event. \nWhen an event is created, a model is also trained using the provided positive and negative samples. </p>\n<h5 id=\"payload-description\">Payload description</h5>\n<p><code>event_id</code>: A unique string associated with the event used as an identifier.<br /><code>event_name</code>: The name of the event<br /><code>camera_id</code>: The camera id for which the event is being created.<br /><code>n_positive</code>: Number of positive samples<br /><code>n_negative</code>: Number of negative samples<br /><code>confidence_threshold</code>: A number between 0 and 1. The confidence threshold representing how confident the model must be that the event is happening.<br /><code>client_id</code>: The client id associated with your account.<br /><code>samples_bucket</code>: The name of the S3 bucket which the samples have been uploaded to.<br /><code>samples_folder</code>: The name of the S3 folder which the samples have been uploaded to.\\</p>\n<p>The positive samples must be uploaded to the S3 bucket with the following naming schema:<br />&lt;event_id&gt;_positive_&lt;index&gt;.jpg<br />index starts from 1.</p>\n<p>The negative samples must be uploaded to the S3 bucket with the following naming schema:<br />&lt;event_id&gt;_negative_&lt;index&gt;.jpg<br />index starts from 1.</p>\n<h5 id=\"response\">Response</h5>\n<p><code>success</code>: 1 if event creation succeeded, 0 if it failed.<br /><code>message</code>: A message describing any potential issues.<br /><code>event_id</code>: The event id corresponding to the created event.</p>\n","auth":{"type":"apikey","apikey":{"basicConfig":[{"key":"key","value":"VO_API_KEY"},{"key":"value","value":"<value>"}]},"isInherited":true,"source":{"_postman_id":"fba9b998-cd30-4a67-972f-45d068727efd","id":"fba9b998-cd30-4a67-972f-45d068727efd","name":"Event Manager","type":"collection"}},"urlObject":{"path":["event"],"host":["https://visualone.info"],"query":[],"variable":[]}},"response":[{"id":"2806a972-8ffe-4dfc-9291-2c4342ed72c3","name":"Create a new event","originalRequest":{"method":"POST","header":[{"key":"Content-Type","value":"application/json","type":"text"}],"body":{"mode":"raw","raw":"{\n    \"event_id\": \"ckk84fpq\",\n    \"event_name\": \"Door left open\",\n    \"camera_id\": \"czp87vy\",\n    \"n_positive\": 2,\n    \"n_negative\": 3,\n    \"confidence_threshold\": 0.75,\n    \"client_id\": \"ckk3edsq\",\n    \"samples_bucket\": \"xyzbucket\",\n    \"samples_folder\": \"xyzfolder\"\n}","options":{"raw":{"language":"json"}}},"url":"https://visualone.info/event"},"_postman_previewlanguage":null,"header":[],"cookie":[],"responseTime":null,"body":"{\n    \"message\": \"Event was created and a model was trained successfully.\", \n    \"success\": 1, \n    \"event_id\": \"ckk84fpq\"\n}"}],"_postman_id":"5f0b89da-bb3b-472b-95fe-0b1237e893a3"},{"name":"Update an event","id":"93376b7f-82dc-4cba-80ae-d775fa7031f2","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"PUT","header":[],"url":"https://visualone.info/event","description":"<p>Used to update an existing event. </p>\n<h5 id=\"payload-description\">Payload description</h5>\n<p><code>event_id</code>: A unique string associated with the event used as an identifier.<br /><code>event_name</code>: The name of the event<br /><code>camera_id</code>: The camera id for which the event is being created.<br /><code>n_positive</code>: Number of positive samples<br /><code>n_negative</code>: Number of negative samples<br /><code>confidence_threshold</code>: A number between 0 and 1. The confidence threshold representing how confident the model must be that the event is happening.<br /><code>client_id</code>: The client id associated with your account.\n<code>samples_bucket</code>: The name of the S3 bucket which the samples have been uploaded to.<br /><code>samples_folder</code>: The name of the S3 folder which the samples have been uploaded to.<br /><code>retrain</code>: A boolean to trigger model retraining. Must be true only if any of the samples has changed or a new samples has been added.</p>\n<p>The positive samples must be uploaded to the S3 bucket with the following naming schema:<br />&lt;event_id&gt;_positive_&lt;index&gt;.jpg<br />index starts from 1.</p>\n<p>The negative samples must be uploaded to the S3 bucket with the following naming schema:<br />&lt;event_id&gt;_negative_&lt;index&gt;.jpg<br />index starts from 1.</p>\n<h5 id=\"response\">Response</h5>\n<p><code>success</code>: 1 if event update succeeded, 0 if it failed.<br /><code>message</code>: A message describing any potential issues.</p>\n","auth":{"type":"apikey","apikey":{"basicConfig":[{"key":"key","value":"VO_API_KEY"},{"key":"value","value":"<value>"}]},"isInherited":true,"source":{"_postman_id":"fba9b998-cd30-4a67-972f-45d068727efd","id":"fba9b998-cd30-4a67-972f-45d068727efd","name":"Event Manager","type":"collection"}},"urlObject":{"path":["event"],"host":["https://visualone.info"],"query":[],"variable":[]}},"response":[],"_postman_id":"93376b7f-82dc-4cba-80ae-d775fa7031f2"},{"name":"Get an event","id":"f80aa512-31ac-4271-8dfe-37e25b752259","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"GET","header":[],"url":"https://visualone.info/event?event_id=<event_id>","description":"<p>Used to get the metadata associated with an event.</p>\n<p><code>event_id</code>: The event id corresponding to the desired event.</p>\n<h5 id=\"response\">Response</h5>\n<p><code>event_id</code>: The event id.<br /><code>event_name</code>: The name of the event<br /><code>camera_id</code>: The camera id for which the event is being created.<br /><code>n_positive</code>: Number of positive samples<br /><code>n_negative</code>: Number of negative samples<br /><code>confidence_threshold</code>: A number between 0 and 1. The confidence threshold representing how confident the model must be that the event is happening.<br /><code>client_id</code>: The client id associated with your account.<br /><code>samples_bucket</code>: The name of the S3 bucket which the samples have been uploaded to.<br /><code>samples_folder</code>: The name of the S3 folder which the samples have been uploaded to.\\</p>\n","auth":{"type":"apikey","apikey":{"basicConfig":[{"key":"key","value":"VO_API_KEY"},{"key":"value","value":"<value>"}]},"isInherited":true,"source":{"_postman_id":"fba9b998-cd30-4a67-972f-45d068727efd","id":"fba9b998-cd30-4a67-972f-45d068727efd","name":"Event Manager","type":"collection"}},"urlObject":{"path":["event"],"host":["https://visualone.info"],"query":[{"key":"event_id","value":"<event_id>"}],"variable":[]}},"response":[{"id":"3a9a72e4-74a9-4e00-8814-1574e54cc9f2","name":"Get an event","originalRequest":{"method":"GET","header":[],"url":{"raw":"https://visualone.info/event?event_id=ckk84fpq","host":["https://visualone.info"],"path":["event"],"query":[{"key":"event_id","value":"ckk84fpq"}]}},"_postman_previewlanguage":null,"header":null,"cookie":[],"responseTime":null,"body":"{\n  \"event_id\": \"ckk84fpq\",\n  \"event_name\": \"Door left open\",\n  \"camera_id\": \"czp87vy\",\n  \"n_positive\": 2,\n  \"n_negative\": 3,\n  \"confidence_threshold\": 0.75,\n  \"client_id\": \"ckk3edsq\",\n  \"samples_bucket\": \"xyzbucket\",\n  \"samples_folder\": \"xyzfolder\"\n}"}],"_postman_id":"f80aa512-31ac-4271-8dfe-37e25b752259"},{"name":"Delete an event","id":"a3d036b1-578b-4c7c-983c-50eb0f0a3e01","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"DELETE","header":[],"url":"https://visualone.info/event?event_id=<event_id>","description":"<p>Used to delete an existing event. </p>\n<p><code>event_id</code>: The event id corresponding to the event to be deleted.</p>\n<h5 id=\"response\">Response</h5>\n<p><code>success</code>: 1 if event deletion succeeded, 0 if it failed.<br /><code>message</code>: A message describing any potential issues.</p>\n","auth":{"type":"apikey","apikey":{"basicConfig":[{"key":"key","value":"VO_API_KEY"},{"key":"value","value":"<value>"}]},"isInherited":true,"source":{"_postman_id":"fba9b998-cd30-4a67-972f-45d068727efd","id":"fba9b998-cd30-4a67-972f-45d068727efd","name":"Event Manager","type":"collection"}},"urlObject":{"path":["event"],"host":["https://visualone.info"],"query":[{"key":"event_id","value":"<event_id>"}],"variable":[]}},"response":[{"id":"05f2ee56-7d30-4fbb-a8e4-679570c2027c","name":"Delete an event","originalRequest":{"method":"DELETE","header":[],"url":{"raw":"https://visualone.info/event?event_id=ckk84fpq","host":["https://visualone.info"],"path":["event"],"query":[{"key":"event_id","value":"ckk84fpq"}]}},"_postman_previewlanguage":null,"header":null,"cookie":[],"responseTime":null,"body":"{\n  \"message\": \"Event was deleted successfully.\",\n  \"success\": 1\n}"}],"_postman_id":"a3d036b1-578b-4c7c-983c-50eb0f0a3e01"}],"auth":{"type":"apikey","apikey":{"basicConfig":[{"key":"key","value":"VO_API_KEY"},{"key":"value","value":"<value>"}]}},"event":[{"listen":"prerequest","script":{"id":"3236e033-7bcf-4aa4-ac4f-0b4ef99aaa32","type":"text/javascript","exec":[""]}},{"listen":"test","script":{"id":"e2235458-0fed-493c-940f-887dd8ff9f6d","type":"text/javascript","exec":[""]}}],"variable":[{"key":"base_url0","value":"http://44.241.247.218:8081"},{"key":"base_url","value":"https://visualone.info"},{"key":"event_id","value":"event_id"}]}