{"openapi":"3.0.0","servers":[{"description":"SwaggerHub API Auto Mocking","url":"https://virtserver.swaggerhub.com/Wunder2021/121app/1.2.3"},{"description":"SwaggerHub API Auto Mocking","url":"https://virtserver.swaggerhub.com/adam.cernohous/121app/1.0.0"}],"info":{"description":"Concept of 121 app API","version":"1.2.3","title":"121 App API","contact":{"email":"adam.cernohous@wundermanthompson.com"}},"security":[{"ApiKeyAuth":[]}],"paths":{"/isAlive":{"get":{"summary":"API monitoring","operationId":"isAlive","responses":{"200":{"description":"search results matching criteria"}}}},"/ageRanges":{"get":{"summary":"Get all age ranges","operationId":"searchAgeRange","responses":{"200":{"description":"search results matching criteria","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/AgeRangeResponseDto"}}}}},"403":{"description":"Access forbidden"},"500":{"description":"API runtime error"}}}},"/events":{"get":{"summary":"Get all events include places","operationId":"searchEvents","responses":{"200":{"description":"search results matching criteria","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/EventResponseDto"}}}}},"403":{"description":"Access forbidden"},"500":{"description":"API runtime error"}}}},"/gifts":{"get":{"summary":"Get all marketing gifts","operationId":"searchGifts","responses":{"200":{"description":"search results matching criteria","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/GiftResponseDto"}}}}},"403":{"description":"Access forbidden"},"500":{"description":"API runtime error"}}}},"/giftsCombinations":{"get":{"summary":"Return gift combinations in HTML format","operationId":"searchGiftCombination","responses":{"200":{"description":"search results matching criteria","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/GiftCombinationResponseDto"}}}}},"403":{"description":"Access forbidden"},"500":{"description":"API runtime error"}}}},"/hostesses":{"get":{"summary":"Get all hostesses","operationId":"searchHostesses","responses":{"200":{"description":"search results matching criteria","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/HostessResponseDto"}}}}},"403":{"description":"Access forbidden"},"500":{"description":"API runtime error"}}}},"/leads/event":{"post":{"tags":["leads"],"summary":"Create a new lead record","operationId":"placeLead","responses":{"201":{"description":"Lead created","content":{"application/json":{"schema":{"$ref":"#/components/schemas/EventLeadResponseDto"}}}},"400":{"description":"Data validation error"},"403":{"description":"Access forbidden"},"500":{"description":"API runtime error"}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/EventLeadRequestDto"}}},"required":true}}},"/leads/gift/{leadId}":{"post":{"tags":["leads"],"summary":"Assign gift(s) to already created event lead","operationId":"placeFestivalResult","parameters":[{"name":"leadId","in":"path","description":"ID of event that needs to be updated","required":true,"schema":{"type":"integer","format":"int64"}}],"responses":{"201":{"description":"successful operation"},"400":{"description":"Data validation error"},"403":{"description":"Access forbidden"},"500":{"description":"API runtime error"}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AssignGiftRequestDto"}}},"required":true}}},"/leads/ploom":{"post":{"tags":["leads"],"summary":"Create a ploom lead record","operationId":"placePloomLead","responses":{"201":{"description":"successful operation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PloomLeadResponseDto"}}}},"400":{"description":"Data validation error"},"403":{"description":"Access forbidden"},"500":{"description":"API runtime error"}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PloomLeadRequestDto"}}},"required":true}}},"/leads/ploom/unsuccessful":{"post":{"tags":["leads"],"summary":"Create an unsuccessful ploom lead record","operationId":"placeUnsuccessfulPloomLead","responses":{"201":{"description":"successful operation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UnsuccessfulPloomLeadResponseDto"}}}},"400":{"description":"Data validation error"},"403":{"description":"Access forbidden"},"500":{"description":"API runtime error"}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/UnsuccessfulPloomLeadRequestDto"}}},"required":true}}},"/matrix":{"get":{"tags":["matrix"],"summary":"Returns selected matrix","operationId":"getMatrix","parameters":[{"in":"query","name":"activationType","required":true,"schema":{"type":"string","enum":["festival","retail","horeca"]}},{"in":"query","name":"festivalType","schema":{"type":"string","enum":["camel","winston"]},"description":"Only for festival activation type."}],"responses":{"200":{"description":"successful operation","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/MatrixResponseDto"}}}}},"204":{"description":"no content"}}}},"/matrix/productToBrand":{"get":{"tags":["matrix"],"summary":"Returns association between product and group","operationId":"getProductsInGroup","responses":{"200":{"description":"successful operation","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/ProductToBrandResponseDto"}}}}}}}},"/matrix/products":{"get":{"tags":["matrix"],"summary":"Returns products","operationId":"getProducts","responses":{"200":{"description":"successful operation","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/ProductResponseDto"}}}}}}}},"/matrix/brands":{"get":{"tags":["matrix"],"summary":"Returns brands","operationId":"getBrands","responses":{"200":{"description":"successful operation","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/BrandResponseDto"}}}}}}}}},"components":{"securitySchemes":{"ApiKeyAuth":{"type":"apiKey","in":"header","name":"X-API-KEY"}},"schemas":{"PlaceRequestDto":{"type":"object","properties":{"name":{"type":"string","example":"place name"},"code":{"type":"string","example":"place code"},"address":{"type":"string","example":"retail only yet"},"city":{"type":"string","example":"retail only yet"}}},"EventResponseDto":{"type":"object","properties":{"id":{"type":"integer"},"name":{"type":"string"},"activationType":{"type":"string","example":"festival | retail | horeca"},"places":{"type":"array","items":{"$ref":"#/components/schemas/PlaceRequestDto"}},"festivalEventType":{"type":"string","nullable":true,"example":"camel"},"festivalPeopleTarget":{"type":"integer"},"createdAt":{"type":"string","format":"date-time","example":"2021-12-06T13:49:04+0000"},"updatedAt":{"type":"string","format":"date-time","example":"2021-12-06T13:49:04+0000"}}},"GiftResponseDto":{"type":"object","properties":{"id":{"type":"integer"},"name":{"type":"string","example":"Zapalovac"},"activationType":{"type":"string","example":"festival | retail | horeca"},"minSoldQty":{"type":"integer"},"disclaimerText":{"type":"string"}}},"GiftCombinationResponseDto":{"type":"object","properties":{"id":{"type":"integer"},"name":{"type":"string"},"activationType":{"type":"string","example":"retail | instant | horeca"},"html":{"type":"string","example":"<p>1x Winston (všechny SKU) = zapalovač DJEEP</p><p>1x Winston Compact = 1x krabička Winston Compact navíc* </p>"}}},"HostessResponseDto":{"type":"object","properties":{"id":{"type":"integer"},"username":{"type":"string","format":"uuid"},"password":{"type":"string","example":"Bcrypted password","format":"password"}}},"AgeRangeResponseDto":{"type":"object","properties":{"id":{"type":"integer"},"range":{"type":"string","example":"18-21"}}},"EventLeadRequestDto":{"type":"object","properties":{"eventId":{"type":"integer"},"eventPlaceCode":{"type":"string"},"fillingFormStartDate":{"type":"string","format":"date-time","example":"2021-12-06T13:49:04+0000"},"fillingFormEndDate":{"type":"string","format":"date-time","example":"2021-12-06T13:49:04+0000"},"smoker":{"type":"boolean"},"willingToParticipate":{"type":"boolean"},"gender":{"type":"string","example":"male"},"ageRangeId":{"type":"integer","minimum":0,"maximum":1},"currentProductId":{"type":"integer"},"selectedProductId":{"type":"integer"},"participatedInEvent":{"type":"boolean"},"purchasedProductsQty":{"type":"integer"},"comment":{"type":"string"},"signature":{"type":"string","format":"byte","example":"base64 encoded image"},"agreementGdpr":{"type":"boolean","default":false},"agreementSignature":{"type":"boolean","default":false},"deviceId":{"type":"string"}},"required":["eventId","eventPlaceCode","fillingFormStartDate","fillingFormEndDate","smoker","willingToParticipate","deviceId"]},"EventLeadResponseDto":{"type":"object","properties":{"id":{"type":"integer"},"message":{"type":"string","example":"Lead created"}}},"AssignGiftRequestDto":{"type":"object","properties":{"giftIds":{"type":"array","items":{"type":"integer"}}}},"PloomLeadRequestDto":{"type":"object","properties":{"eventId":{"type":"integer"},"eventLeadId":{"type":"integer"},"firstName":{"type":"string"},"lastName":{"type":"string"},"zipCode":{"type":"integer","example":11000},"phoneNumber":{"type":"string","example":"+420 000 000"},"isAdult":{"type":"boolean"},"smokeCigarettes":{"type":"boolean"},"smokeHeatedTobacco":{"type":"boolean"},"signature":{"type":"string","format":"byte","example":"base64 encoded image"},"agreementGdpr":{"type":"boolean"},"agreementNewsletter":{"type":"boolean"},"agreementSignature":{"type":"boolean"},"deviceId":{"type":"string"}},"required":["eventId","firstName","lastName","zipCode","phoneNumber","isAdult","smokeCigarettes","smokeHeatedTobacco","signature","agreementGdpr","agreementNewsletter","agreementSignature","deviceId"]},"PloomLeadResponseDto":{"type":"object","properties":{"id":{"type":"integer"},"message":{"type":"string","example":"Ploom lead successfully created"}}},"UnsuccessfulPloomLeadRequestDto":{"type":"object","properties":{"eventId":{"type":"integer"},"deviceId":{"type":"string"}},"required":["eventId","deviceId"]},"UnsuccessfulPloomLeadResponseDto":{"type":"object","properties":{"message":{"type":"string","example":"Unsuccessful Ploom lead successfully created"}}},"MatrixResponseDto":{"type":"object","properties":{"matrixCurrentProductId":{"type":"integer"},"matrixProposedProductId":{"type":"integer"},"matrixAlternativeProductId":{"type":"integer"}}},"ProductToBrandResponseDto":{"type":"object","properties":{"productId":{"type":"integer"},"brandId":{"type":"integer"}}},"ProductResponseDto":{"type":"object","properties":{"id":{"type":"integer"},"name":{"type":"string","example":"Lucky Strike Red 30g"},"text":{"type":"string"},"pictureUrl":{"type":"string","example":"https://www.google.com/filename.jpg"},"pictureUpdatedAt":{"type":"string","format":"date-time","example":"2021-12-06T13:49:04+0000"}}},"BrandResponseDto":{"type":"object","properties":{"id":{"type":"integer"},"name":{"type":"string","example":"Lucky Strike"}}}}}}