{"openapi":"3.0.0","info":{"title":"API Integration Specification - Onit & Microsoft","description":"API interface between the Microsoft system and the Onit platform. The interface enables customer management, status updates, and real-time data retrieval.\n **Environment:** Azure Israel Central\n **Status:** Pre-Production / Testing\n","version":"1.0.0"},"servers":[{"description":"SwaggerHub API Auto Mocking","url":"https://virtserver.swaggerhub.com/onit-80f/Onit-Microsoft-Integration/1.0.0"},{"url":"https://preprod-app.onitfast.com/api/External","description":"Pre-Production Server (Azure Israel Central)"}],"components":{"securitySchemes":{"ApiKeyAuth":{"type":"apiKey","in":"header","name":"Authorization","description":"Uniq Authorization Token"}},"schemas":{"MessageResponse":{"type":"object","properties":{"code":{"type":"integer"},"description":{"type":"null"}},"x-examples":{"Example 1":{"code":1,"description":null}}},"CreateRequest":{"type":"object","properties":{"firstName":{"type":"string","example":"Israel"},"lastName":{"type":"string","example":"Israeli"},"mobilePhone":{"type":"string","example":"0542223601"},"email":{"type":"string","format":"email","example":"test@microsoft.com"},"idNumber":{"type":"string","example":"123456789","nullable":true},"birthDate":{"type":"string","format":"date","example":"1975-11-05"},"gender":{"type":"string","enum":["Male","Female"],"example":"Male"}},"title":""},"UpdateRequest":{"type":"object","x-examples":{"Example 1":{"email":"blabla80@gg.com","customerExternalID":"7E1030DB-14A1-4553-933E-843AC37AB017","status":"Active","isSurveyEligible":true}},"required":["customerExternalID"],"properties":{"email":{"type":"string"},"customerExternalID":{"type":"string"},"status":{"type":"string"},"isSurveyEligible":{"type":"boolean"}}},"GetRequest":{"title":"GetRequest","type":"object","x-examples":{"Example 1":{"customerExternalId":"7CF4B856-AD04-4649-8CF6-A27EAF959C8D","email":"sh@microsoft.com"}},"required":["customerExternalId","email"],"properties":{"customerExternalId":{"type":"string","x-stoplight":{"id":"lhsl26enwgapi"}},"email":{"type":"string","x-stoplight":{"id":"3eokyv8cw5zkw"}}}}}},"security":[{"ApiKeyAuth":[]}],"paths":{"/CreateCustomer":{"post":{"summary":"create new client","description":"create customer object .","tags":["Customer Management"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateRequest","required":["firstName","lastName","mobilePhone","email"]}}}},"responses":{"200":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"message":{"$ref":"#/components/schemas/MessageResponse"},"customerExternalID":{"type":"string","format":"uuid","example":"7cf4b856-ad04-4649-8cf6-a27eaf959c8d"}}},"examples":{"Example 1":{"value":{"message":{"code":1,"description":null},"customerExternalID":"7cf4b856-ad04-4649-8cf6-a27eaf959c8d"}},"Example 2":{"value":{"message":{"code":2,"description":"Not valid IdNumber 123456789!!"},"customerExternalID":null}},"Example 3":{"value":{"message":{"code":2,"description":"שגיאה בעדכון לקוח"},"customerExternalID":null}}}}}},"401":{"description":"Unauthorized"}}}},"/UpdateCustomer":{"patch":{"summary":"update client","tags":[],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"message":{"$ref":"#/components/schemas/MessageResponse"},"customerExternalID":{"type":"string","x-stoplight":{"id":"p4igex0b04vam"}}}}}}},"401":{"description":"Unauthorized"}},"operationId":"עדכון לקוח קיים","requestBody":{"content":{"application/json":{"schema":{"type":"object","properties":{"customerExternalID":{"type":"string","x-stoplight":{"id":"0cfdho3fri91x"}},"email":{"type":"string","x-stoplight":{"id":"ptkanrnebu8sf"}},"status":{"type":"string","x-stoplight":{"id":"gzf3sb2f62hqf"}},"isSurveyEligible":{"type":"boolean","x-stoplight":{"id":"o2ukkbecvri0m"}}}}}}}}},"/GetCustomer":{"get":{"summary":"get client by externalId","tags":[],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"customerExternalID":{"type":"string","x-stoplight":{"id":"w1k125m8xj7ua"}},"firstName":{"type":"string","x-stoplight":{"id":"d23a00bsl5ams"}},"lastName":{"type":"string","x-stoplight":{"id":"xrif93gsvfk4r"}},"companyName":{"type":"string","x-stoplight":{"id":"s0xowbclpqsyy"}},"message":{"$ref":"#/components/schemas/MessageResponse"}}}}}},"401":{"description":"Unauthorized"}},"operationId":"get-GetCustomer","parameters":[{"schema":{"type":"string"},"in":"query","name":"customerExternalId"},{"schema":{"type":"string"},"in":"query","name":"email"}]}}}}