{"openapi":"3.0.0","servers":[{"description":"SwaggerHub API Auto Mocking","url":"https://virtserver.swaggerhub.com/mejsion100/8flow_API/1.0.0"},{"description":"Amazon AWS API","url":"https://dopkgn13jb.execute-api.us-east-1.amazonaws.com/production/"}],"info":{"version":"1.0.0","title":"8flow-api","description":"The API for 8flow project"},"paths":{"/auth/user":{"get":{"tags":["Auth"],"description":"Get one user","parameters":[{"in":"query","name":"email","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"User","content":{"application/json":{"schema":{"$ref":"#/components/schemas/User"}}}},"400":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/NotFound"}}}}}},"post":{"tags":["Auth"],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateUserReq"}}}},"responses":{"200":{"description":"Successfully created user","content":{"application/json":{"schema":{"$ref":"#/components/schemas/User"}}}}}},"delete":{"tags":["Auth"],"description":"Delete user by email","parameters":[{"in":"query","name":"email","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Successfully deleted"}}}},"/auth/validate":{"post":{"tags":["Auth"],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ValidateReq"}}}},"responses":{"200":{"description":"User","content":{"application/json":{"schema":{"$ref":"#/components/schemas/User"}}}},"500":{"description":"Not exist"}}}},"/amplitude/add-custom-event":{"post":{"tags":["Amplitude Events"],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AddCustomEventReq"}}}},"responses":{"200":{"description":"Successfully created","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Created"}}}}}}},"/user/mod":{"post":{"tags":["User"],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/UserModReq"}}}},"responses":{"200":{"description":"Successfully updated","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Updated"}}}}}}},"/pinpads":{"get":{"tags":["Pinpad"],"parameters":[{"in":"query","name":"uid","required":true,"schema":{"type":"string"}},{"in":"query","name":"pinpad_id","schema":{"type":"string"}}],"responses":{"200":{"description":"PinPad","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PinPad"}}}},"400":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/NotFound"}}}}}},"post":{"tags":["Pinpad"],"parameters":[{"in":"query","name":"uid","required":true,"schema":{"type":"string"}},{"in":"query","name":"pinpad_id","schema":{"type":"string"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PinPadCreateReq"}}}},"responses":{"200":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Created"}}}},"400":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/NotFound"}}}}}},"delete":{"tags":["Pinpad"],"parameters":[{"in":"query","name":"pinpad_id","required":true,"schema":{"type":"string"}},{"in":"query","name":"uid","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Deleted"}}}},"400":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/NotFound"}}}}}}},"/pinpads/pins":{"get":{"tags":["Pinpad Pins"],"parameters":[{"in":"query","name":"pinpad_id","required":true,"schema":{"type":"string"}},{"in":"query","name":"uid","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Successfully response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PinPadPins"}}}}}},"post":{"tags":["Pinpad Pins"],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PinPadPinCreateReq"}}}},"parameters":[{"in":"query","name":"pinpad_id","required":true,"schema":{"type":"string"}},{"in":"query","name":"uid","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Successfuly created","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Created"}}}},"400":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/NotFound"}}}}}},"delete":{"tags":["Pinpad Pins"],"parameters":[{"in":"query","name":"pinpad_id","required":true,"schema":{"type":"string"}},{"in":"query","name":"uid","required":true,"schema":{"type":"string"}},{"in":"query","name":"pin_id","schema":{"type":"string"}}],"responses":{"200":{"description":"response"}}}},"/events/pinning":{"get":{"tags":["Pinning"],"parameters":[{"in":"query","name":"email","required":true,"schema":{"type":"string"}},{"in":"query","name":"top","schema":{"type":"integer"}},{"in":"query","name":"record_type","schema":{"type":"string"}}],"responses":{"200":{"description":"Successfully response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PinningEvent"}}}},"400":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/NotFound"}}}}}},"post":{"tags":["Pinning"],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateEventPinningReq"}}}},"parameters":[{"in":"query","name":"user_id","required":true,"description":"unique UID","schema":{"type":"string"}}],"responses":{"200":{"description":"Successfully updated","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Updated"}}}},"201":{"description":"Successfully created","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Created"}}}},"400":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/NotFound"}}}}}},"delete":{"tags":["Pinning"],"parameters":[{"in":"query","name":"email","description":"email address","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Successfully deleted!","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Deleted"}}}},"400":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/NotFound"}}}}}}},"/shortcuts":{"get":{"tags":["Shortcut"],"parameters":[{"in":"query","name":"email","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Schortcuts"}}}},"400":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/NotFound"}}}}}},"post":{"tags":["Shortcut"],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ShortcutCreateReq"}}}},"responses":{"200":{"description":"Successfully created","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Created"}}}},"400":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/NotFound"}}}}}},"delete":{"tags":["Shortcut"],"parameters":[{"in":"query","name":"id","description":"id unique identifier","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Successfully deleted!","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Deleted"}}}},"400":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/NotFound"}}}}}}}},"components":{"schemas":{"Deleted":{"type":"object","example":{"message":"Successfully deleted!"}},"NotFound":{"type":"object","example":{"message":"Not found"}},"Created":{"type":"object","example":{"message":"Successfully created"}},"Schortcuts":{"type":"object","example":[{"title":"some title","destFavicon":"something","srcUrl":"https://google.com","copiedContent":"kewl","destTitle":"Google","destURL":"not empty","destSelector":"selector","_id":"632282ab004e3a8680468a70"}]},"PinningEvent":{"type":"object","example":[{"domain_url":"www.instagram.com","full_url":"https://www.instagram.com/direct/t/34028236684171030094912815770510253…","field_label":"var2","field_type":"string","action":"unpin","timestamp":1663186185,"count":1,"record_type":"unknown","_id":"632235090f0c0e9d10cfeec4"}]},"Updated":{"type":"object","example":{"message":"Successfully updated"}},"User":{"type":"object","example":{"_id":"6319cbe8aa12032912458da2","email":"dev.mejison@gmail.com","enabled":true,"last_validated":1663168419}},"PinPad":{"type":"object","example":{"title":"test","ticket_id":33333,"ticket_type":"type1","short_description":"description","state":"state1","priority":"priority","icon":"icon","domain_url":"asdf","full_url":"aasdfasd","timestamp":1663170357}},"PinPadPins":{"type":"object","example":{"associated_pins":[{"name":"test","slug":"test"}],"disassociated_pins":[{"name":"test","icon":"icon","slug":"slug","src_url":"src_url","group_name":"group_name"}]}},"CreateUserReq":{"type":"object","example":{"email":"test@test.com","required":true}},"ValidateReq":{"type":"object","example":{"email":"test@test.com","enabled":false}},"AddCustomEventReq":{"type":"object","example":{"body":{"email":"test@test.com","domain_url":"http://google.com","full_url":"http://google.com/some-page","field_label":"variable","field_type":"value"}}},"PinPadCreateReq":{"type":"object","example":{"title":"some titile","ticket_id":"2f2f3f2fef2f2f2f2f2f","ticket_type":"type1","icon":"https://google.com/favicon.ico","domain_url":"https://google.com","full_url":"https://google.com/some-page","quickview":{}}},"PinPadPinCreateReq":{"type":"object","example":{"name":"some name","icon":"https://google.com/favicon.ico","slug":"some slug","src_url":"https://google.com/some-page","domain_url":"https://google.com"}},"CreateEventPinningReq":{"type":"object","example":{"user_id":"632874949101820e3b412ece","domain_url":"https://google.com","full_url":"https://google.com/some-url","field_label":"var 1","field_type":"some val","action":"pin","timestamp":12341234}},"ShortcutCreateReq":{"type":"object","example":{"user_id":"632874949101820e3b412ece","title":"some title","srcUrl":"https://google.com","copiedContent":"content","destTitle":"Google","destURL":"https://google.com/some-page","destFavicon":"https://google.com/favicon.ico","destSelector":"html > body > h1:nth-child(1)"}},"UserModReq":{"type":"object","example":{"email":"test@test.com","first_name":"first","last_name":"last","login_state":"login","ticketing_platform":"youtube","enabled":true}}}}}