{"info":{"_postman_id":"0bc77335-c12f-4475-a732-4b8aeb750221","name":"BonusGroups API","description":"<html><head></head><body><h1 id=\"overview\">Overview</h1>\n<h1 id=\"authentication\">Authentication</h1>\n<p>В каждом запросе требующем авторизации, необходимо присылать поля&nbsp;market,&nbsp;ts&nbsp;и&nbsp;secret.</p>\n<div class=\"click-to-expand-wrapper is-table-wrapper\"><table>\n<thead>\n<tr>\n<th>Header</th>\n<th>Value</th>\n<th>Description</th>\n</tr>\n</thead>\n<tbody>\n<tr>\n<td>market</td>\n<td>identifier</td>\n<td>market identifier</td>\n</tr>\n<tr>\n<td>ts</td>\n<td>any string</td>\n<td>ane value recommend unique for eeach request</td>\n</tr>\n<tr>\n<td>secret</td>\n<td>sha256</td>\n<td>sha256 from concatination both ts and secret</td>\n</tr>\n</tbody>\n</table>\n</div><h1 id=\"error-codes\">Error codes</h1>\n</body></html>","schema":"https://schema.getpostman.com/json/collection/v2.0.0/collection.json","toc":[{"content":"Overview","slug":"overview"},{"content":"Authentication","slug":"authentication"},{"content":"Error codes","slug":"error-codes"}],"owner":"317528","collectionId":"0bc77335-c12f-4475-a732-4b8aeb750221","publishedId":"RW89J92L","public":true,"customColor":{"top-bar":"FFFFFF","right-sidebar":"303030","highlight":"EF5B25"},"publishDate":"2018-05-23T02:33:12.000Z"},"item":[{"name":"Bonuses","item":[{"name":"Customer bonus info","id":"5e53ec6e-5996-4c81-9985-1ea522a083ee","request":{"auth":{"type":"bearer","bearer":{"basicConfig":[{"key":"token","value":"{{api-key}}"}]},"isInherited":false},"method":"GET","header":[{"key":"Authorization","value":"{{api-key}}"}],"body":{"mode":"formdata","formdata":[]},"url":"{{api-url}}/api/v1/customers/{{customerId}}/bonuses/info","description":"<p>Get information about customer's bonuses. There are a lot of types of bonuses that customer can have.</p>\n<div class=\"click-to-expand-wrapper is-table-wrapper\"><table>\n<thead>\n<tr>\n<th>Bonus Type</th>\n<th>Description</th>\n</tr>\n</thead>\n<tbody>\n<tr>\n<td>Registration</td>\n<td>Bonuses for registration, can get once</td>\n</tr>\n<tr>\n<td>Purchase</td>\n<td>Bonuses after each purchase</td>\n</tr>\n<tr>\n<td>Coupon</td>\n<td>Bonuses of coupon</td>\n</tr>\n<tr>\n<td>Gift</td>\n<td>Bonuses of gift</td>\n</tr>\n<tr>\n<td>Birthday</td>\n<td>Bonuses on birthday</td>\n</tr>\n</tbody>\n</table>\n</div>","urlObject":{"path":["api","v1","customers","{{customerId}}","bonuses","info"],"host":["{{api-url}}"],"query":[],"variable":[]}},"response":[{"id":"1125a473-f91f-48f5-8a9e-0fc885c0f4f7","name":"Customer bonus info","originalRequest":{"method":"GET","header":[{"key":"Authorization","value":"{{api-key}}","description":"Your API KEY"}],"body":{"mode":"formdata","formdata":[]},"url":"{{api-url}}/api/v1/customers/{{customerId}}/bonuses/info"},"status":"OK","code":200,"_postman_previewlanguage":"json","header":[{"key":"Content-Type","value":"application/json; charset=utf-8","name":"Content-Type","description":"The mime type of this content"},{"key":"Date","value":"Sun, 27 May 2018 21:26:39 GMT","name":"Date","description":"The date and time that the message was sent"},{"key":"Server","value":"Kestrel","name":"Server","description":"A name for the server"},{"key":"Transfer-Encoding","value":"chunked","name":"Transfer-Encoding","description":"The form of encoding used to safely transfer the entity to the user. Currently defined methods are: chunked, compress, deflate, gzip, identity."}],"cookie":[],"responseTime":null,"body":"{\"at\":\"2018-05-27T21:26:26.4672771+00:00\",\"totalAmount\":245.00,\"amountByPurchase\":245.00,\"amountByRegistration\":0.0,\"amountByBirthday\":0.0,\"amountByGift\":0.0,\"amountByCoupon\":0.0}"}],"_postman_id":"5e53ec6e-5996-4c81-9985-1ea522a083ee"},{"name":"Get Bonus Information by phone number","id":"77a4c9d4-2db4-4802-b2c8-d8e7bbc37962","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"auth":{"type":"noauth","isInherited":false},"method":"GET","header":[{"warning":"This is a duplicate header and will be overridden by the Authorization header generated by Postman.","key":"Authorization","value":"{{api-key}}","type":"text"}],"url":"{{api-url}}/api/v1/phones/{{customerPhoneNumber}}/bonuses/info","description":"<p>Useful for e-stores</p>\n","urlObject":{"path":["api","v1","phones","{{customerPhoneNumber}}","bonuses","info"],"host":["{{api-url}}"],"query":[],"variable":[]}},"response":[{"id":"f233f8c3-689a-4d3e-80d3-299ee58529d1","name":"Get Bonus Information by phone number","originalRequest":{"method":"GET","header":[{"warning":"This is a duplicate header and will be overridden by the Authorization header generated by Postman.","key":"Authorization","value":"{{api-key}}","type":"text"}],"url":"{{api-url}}/api/v1/phones/{{customerPhoneNumber}}/bonuses/info"},"status":"OK","code":200,"_postman_previewlanguage":"json","header":[{"key":"Date","value":"Thu, 28 Mar 2019 19:08:00 GMT"},{"key":"Content-Type","value":"application/json; charset=utf-8"},{"key":"Server","value":"Kestrel"},{"key":"Transfer-Encoding","value":"chunked"}],"cookie":[],"responseTime":null,"body":"{\n    \"at\": \"2019-03-28T19:07:59.7748003+00:00\",\n    \"totalAmount\": 777,\n    \"amountByPurchase\": 0,\n    \"amountByRegistration\": 0,\n    \"amountByBirthday\": 0,\n    \"amountByGift\": 0,\n    \"amountByCoupon\": 0,\n    \"amountByCouponSharing\": 0,\n    \"amountByGiftAfterLastPurchase\": 0,\n    \"amountByExtraPurchase\": 0,\n    \"amountByInstagramJoinTo\": 777\n}"}],"_postman_id":"77a4c9d4-2db4-4802-b2c8-d8e7bbc37962"}],"id":"4b257c30-ce75-41ab-aa7f-59821af1dfe3","_postman_id":"4b257c30-ce75-41ab-aa7f-59821af1dfe3","description":"","auth":{"type":"bearer","bearer":{"basicConfig":[{"key":"token","value":"2COk7UQOL-jWwz2VYXWmgoUZiGo8YAxdDrcAa8Aso8qXboRgjeATOWq"}]},"isInherited":true,"source":{"_postman_id":"0bc77335-c12f-4475-a732-4b8aeb750221","id":"0bc77335-c12f-4475-a732-4b8aeb750221","name":"BonusGroups API","type":"collection"}}},{"name":"Coupons","item":[{"name":"Share coupons","id":"2e92d3d5-ae05-487f-80c8-b46c2489ea0a","request":{"auth":{"type":"bearer","bearer":{"basicConfig":[{"key":"token","value":"{{api-key}}"}]},"isInherited":false},"method":"POST","header":[{"key":"Authorization","value":"{{api-key}}"},{"key":"Content-Type","value":"application/json"}],"body":{"mode":"raw","raw":"{\n\t\"toPhones\": [\n\t\t{\n\t\t\t\"phoneNumber\": \"79000000000\",\n\t\t\t\"fullName\": \"Иванов Иван Иванович\"\n\t\t}\n\t]\n}"},"url":"{{api-url}}/api/v1/customers/{{customerId}}/coupons/share?storeId=1","description":"<p>Share coupons for friends</p>\n","urlObject":{"path":["api","v1","customers","{{customerId}}","coupons","share"],"host":["{{api-url}}"],"query":[{"key":"storeId","value":"1"}],"variable":[]}},"response":[{"id":"e3322c13-1a98-4d8f-bae0-1c4733906a9b","name":"Success sharing coupons","originalRequest":{"method":"POST","header":[{"key":"Authorization","value":"{{api-key}}","warning":"This is a duplicate header and will be overridden by the Authorization header generated by Postman.","disabled":false},{"key":"Content-Type","name":"Content-Type","value":"application/json","disabled":false}],"body":{"mode":"raw","raw":"{\n\t\"toPhones\": [\n\t\t{\n\t\t\t\"phoneNumber\": \"79000000000\",\n\t\t\t\"fullName\": \"Иванов Иван Иванович\"\n\t\t}\n\t]\n}"},"url":{"raw":"{{api-url}}/api/v1/customers/{{customerId}}/coupons/share?storeId=1","host":["{{api-url}}"],"path":["api","v1","customers","{{customerId}}","coupons","share"],"query":[{"key":"storeId","value":"1"}]}},"status":"Created","code":201,"_postman_previewlanguage":"json","header":[{"key":"Content-Type","value":"application/json; charset=utf-8","name":"Content-Type","description":"The mime type of this content"},{"key":"Date","value":"Sat, 08 Sep 2018 09:27:58 GMT","name":"Date","description":"The date and time that the message was sent"},{"key":"Location","value":"http://localhost:53374/api/v1/customers/7/coupons/share?Length=9","name":"Location","description":"Used in redirection, or when a new resource has been created."},{"key":"Request-Context","value":"appId=cid-v1:","name":"Request-Context","description":"Custom header"},{"key":"Server","value":"Kestrel","name":"Server","description":"A name for the server"},{"key":"Transfer-Encoding","value":"chunked","name":"Transfer-Encoding","description":"The form of encoding used to safely transfer the entity to the user. Currently defined methods are: chunked, compress, deflate, gzip, identity."}],"cookie":[],"responseTime":null,"body":"{\"couponId\":4,\"description\":\"Раздача купонов друзьям\",\"fromCustomerId\":7,\"bonusAmount\":1000.00,\"fromCustomerFullName\":\"Piterov Andrey Valimirovich\",\"sharedAt\":\"2018-09-08T12:26:57.814498+03:00\",\"endAt\":null}"}],"_postman_id":"2e92d3d5-ae05-487f-80c8-b46c2489ea0a"},{"name":"Get available coupon","id":"4e7fadc1-941f-4465-9a88-274730a26005","request":{"auth":{"type":"bearer","bearer":{"basicConfig":[{"key":"token","value":"{{api-key}}"}]},"isInherited":false},"method":"GET","header":[{"key":"Authorization","value":"{{api-key}}"}],"body":{"mode":"formdata","formdata":[]},"url":"{{api-url}}/api/v1/customers/{{customerId}}/coupons","description":"<p>Get information about available coupon</p>\n","urlObject":{"path":["api","v1","customers","{{customerId}}","coupons"],"host":["{{api-url}}"],"query":[],"variable":[]}},"response":[{"id":"89e9e289-4e74-486a-876c-6bcae03df0ad","name":"no coupon","originalRequest":{"method":"GET","header":[{"key":"Authorization","value":"{{api-key}}","warning":"This is a duplicate header and will be overridden by the Authorization header generated by Postman.","disabled":false}],"body":{"mode":"formdata","formdata":[]},"url":"{{api-url}}/api/v1/customers/{{customerId}}/coupons"},"status":"OK","code":200,"_postman_previewlanguage":"json","header":[{"key":"Content-Type","value":"application/json; charset=utf-8","name":"Content-Type","description":"The mime type of this content"},{"key":"Date","value":"Fri, 14 Sep 2018 22:12:55 GMT","name":"Date","description":"The date and time that the message was sent"},{"key":"Server","value":"Kestrel","name":"Server","description":"A name for the server"},{"key":"Transfer-Encoding","value":"chunked","name":"Transfer-Encoding","description":"The form of encoding used to safely transfer the entity to the user. Currently defined methods are: chunked, compress, deflate, gzip, identity."}],"cookie":[],"responseTime":null,"body":"{\"couponId\":null,\"bonusId\":null,\"amount\":0.0,\"availableAmount\":0.0,\"used\":0.0,\"hasCoupon\":false,\"customerId\":7,\"customerFullName\":\"Piterov Andrey Valimirovich\",\"customerPhoneNumber\":\"79012345678\"}"},{"id":"a70273c8-c7fa-414c-8cf0-d113f4942cce","name":"customer has coupon","originalRequest":{"method":"GET","header":[{"key":"Authorization","value":"{{api-key}}","disabled":false}],"body":{"mode":"formdata","formdata":[]},"url":"{{api-url}}/api/v1/customers/10/coupons"},"status":"OK","code":200,"_postman_previewlanguage":"json","header":[{"key":"Content-Type","value":"application/json; charset=utf-8","name":"Content-Type","description":"The mime type of this content"},{"key":"Date","value":"Fri, 14 Sep 2018 22:15:34 GMT","name":"Date","description":"The date and time that the message was sent"},{"key":"Request-Context","value":"appId=cid-v1:","name":"Request-Context","description":"Custom header"},{"key":"Server","value":"Kestrel","name":"Server","description":"A name for the server"},{"key":"Transfer-Encoding","value":"chunked","name":"Transfer-Encoding","description":"The form of encoding used to safely transfer the entity to the user. Currently defined methods are: chunked, compress, deflate, gzip, identity."}],"cookie":[],"responseTime":null,"body":"{\n    \"couponId\": 4,\n    \"bonusId\": 466,\n    \"amount\": 1000,\n    \"availableAmount\": 0,\n    \"used\": 1000,\n    \"hasCoupon\": false,\n    \"customerId\": 10,\n    \"customerFullName\": \"Andrey\",\n    \"customerPhoneNumber\": \"79000000000\"\n}"},{"id":"fbf6ce48-cb38-487e-b16a-fd1fb60688f7","name":"customer not found","originalRequest":{"method":"GET","header":[{"key":"Authorization","value":"{{api-key}}","disabled":false}],"body":{"mode":"formdata","formdata":[]},"url":"{{api-url}}/api/v1/customers/1/coupons"},"status":"Bad Request","code":400,"_postman_previewlanguage":"json","header":[{"key":"Content-Type","value":"application/json; charset=utf-8","name":"Content-Type","description":"The mime type of this content"},{"key":"Date","value":"Fri, 14 Sep 2018 22:14:00 GMT","name":"Date","description":"The date and time that the message was sent"},{"key":"Request-Context","value":"appId=cid-v1:","name":"Request-Context","description":"Custom header"},{"key":"Server","value":"Kestrel","name":"Server","description":"A name for the server"},{"key":"Transfer-Encoding","value":"chunked","name":"Transfer-Encoding","description":"The form of encoding used to safely transfer the entity to the user. Currently defined methods are: chunked, compress, deflate, gzip, identity."}],"cookie":[],"responseTime":null,"body":"{\"message\":\"CustomerNotFound\"}"}],"_postman_id":"4e7fadc1-941f-4465-9a88-274730a26005"},{"name":"Get by phone number","id":"5d5c52c9-7841-4def-bc08-f1cf14501c19","request":{"auth":{"type":"bearer","bearer":{"basicConfig":[{"key":"token","value":"{{api-key}}"}]},"isInherited":false},"method":"GET","header":[{"key":"Authorization","value":"{{api-key}}"}],"body":{"mode":"formdata","formdata":[]},"url":"{{api-url}}/api/v1/phones/{{customerPhoneNumber}}/coupons","description":"<p>Get customer' coupon by his phone number</p>\n","urlObject":{"path":["api","v1","phones","{{customerPhoneNumber}}","coupons"],"host":["{{api-url}}"],"query":[],"variable":[]}},"response":[{"id":"473a6b19-f62b-4d3a-b430-76f5e05dad94","name":"Get by phone number","originalRequest":{"method":"GET","header":[{"key":"Authorization","value":"{{api-key}}","warning":"This is a duplicate header and will be overridden by the Authorization header generated by Postman.","disabled":false}],"body":{"mode":"formdata","formdata":[]},"url":"{{api-url}}/api/v1/phones/{{customerPhoneNumber}}/coupons"},"status":"OK","code":200,"_postman_previewlanguage":"json","header":[{"key":"Content-Type","value":"application/json; charset=utf-8","name":"Content-Type","description":"The mime type of this content"},{"key":"Date","value":"Sat, 15 Sep 2018 20:29:45 GMT","name":"Date","description":"The date and time that the message was sent"},{"key":"Request-Context","value":"appId=cid-v1:","name":"Request-Context","description":"Custom header"},{"key":"Server","value":"Kestrel","name":"Server","description":"A name for the server"},{"key":"Transfer-Encoding","value":"chunked","name":"Transfer-Encoding","description":"The form of encoding used to safely transfer the entity to the user. Currently defined methods are: chunked, compress, deflate, gzip, identity."}],"cookie":[],"responseTime":null,"body":"{\n    \"couponId\": 4,\n    \"bonusId\": 466,\n    \"amount\": 1000,\n    \"availableAmount\": 0,\n    \"used\": 1000,\n    \"hasCoupon\": false,\n    \"customerId\": 10,\n    \"customerFullName\": \"Andrey\",\n    \"customerPhoneNumber\": \"79000000000\"\n}"}],"_postman_id":"5d5c52c9-7841-4def-bc08-f1cf14501c19"}],"id":"63212484-11da-4c51-83ea-2d443fb245ad","_postman_id":"63212484-11da-4c51-83ea-2d443fb245ad","description":"","auth":{"type":"bearer","bearer":{"basicConfig":[{"key":"token","value":"2COk7UQOL-jWwz2VYXWmgoUZiGo8YAxdDrcAa8Aso8qXboRgjeATOWq"}]},"isInherited":true,"source":{"_postman_id":"0bc77335-c12f-4475-a732-4b8aeb750221","id":"0bc77335-c12f-4475-a732-4b8aeb750221","name":"BonusGroups API","type":"collection"}}},{"name":"Customers","item":[{"name":"Paging","item":[{"name":"200 OK Response","id":"c2e9fcce-fcad-4e97-8c77-25d42d4b1ab7","request":{"auth":{"type":"bearer","bearer":{"basicConfig":[{"key":"token","value":"{{api-key}}"}]},"isInherited":false},"method":"GET","header":[{"key":"Authorization","value":"{{api-key}}"}],"body":{"mode":"formdata","formdata":[]},"url":"http://localhost:53374/api/v1/customers","description":"<p>By default first page (page=1) and items count per page is 50 (count=50)</p>\n","urlObject":{"path":["api","v1","customers"],"host":["http://localhost:53374"],"query":[],"variable":[]}},"response":[{"id":"a4d3801b-f97f-49fd-9012-750bd3c42f20","name":"200 OK Response","originalRequest":{"method":"GET","header":[{"key":"Authorization","value":"{{api-key}}"}],"body":{"mode":"formdata","formdata":[]},"url":"http://localhost:53374/api/v1/customers"},"status":"OK","code":200,"_postman_previewlanguage":"json","header":[{"key":"Content-Type","value":"application/json; charset=utf-8","name":"Content-Type","description":"The mime type of this content"},{"key":"Date","value":"Sat, 26 May 2018 22:06:59 GMT","name":"Date","description":"The date and time that the message was sent"},{"key":"Request-Context","value":"appId=cid-v1:","name":"Request-Context","description":"Custom header"},{"key":"Server","value":"Kestrel","name":"Server","description":"A name for the server"},{"key":"Transfer-Encoding","value":"chunked","name":"Transfer-Encoding","description":"The form of encoding used to safely transfer the entity to the user. Currently defined methods are: chunked, compress, deflate, gzip, identity."}],"cookie":[],"responseTime":null,"body":"{\"items\":[{\"customerId\":3,\"firstName\":\"Иван\",\"fullName\":\"Иван\",\"sellerId\":1,\"sellerName\":null,\"storeId\":1,\"storeName\":null,\"phoneNumber\":\"79100000000\",\"cardNumber\":null,\"lastName\":null,\"surname\":null,\"gender\":\"male\",\"birth\":{\"day\":null,\"month\":null,\"year\":null},\"registeredAt\":\"2018-05-26T23:27:45.194529+03:00\"},{\"customerId\":2,\"firstName\":\"Иван\",\"fullName\":\"Иван\",\"sellerId\":1,\"sellerName\":null,\"storeId\":1,\"storeName\":null,\"phoneNumber\":\"79000000000\",\"cardNumber\":null,\"lastName\":null,\"surname\":null,\"gender\":null,\"birth\":{\"day\":null,\"month\":null,\"year\":null},\"registeredAt\":\"2018-05-26T23:12:28.1295177+03:00\"},{\"customerId\":1,\"firstName\":\"Andrey\",\"fullName\":\"Питеров Andrey Владимирович\",\"sellerId\":1,\"sellerName\":null,\"storeId\":1,\"storeName\":null,\"phoneNumber\":\"79046779010\",\"cardNumber\":\"1111111111111\",\"lastName\":\"Питеров\",\"surname\":\"Владимирович\",\"gender\":\"male\",\"birth\":{\"day\":24,\"month\":3,\"year\":1990},\"registeredAt\":\"2018-05-26T21:00:42.1388485+03:00\"}],\"meta\":{\"pageNumber\":1,\"offset\":0,\"size\":50,\"totalElements\":3,\"totalPages\":1,\"hasPrev\":false,\"hasNext\":false}}"}],"_postman_id":"c2e9fcce-fcad-4e97-8c77-25d42d4b1ab7"},{"name":"specific page","id":"8b41210f-98b2-4dd5-a8a6-b6bd1e053a3b","request":{"auth":{"type":"bearer","bearer":{"basicConfig":[{"key":"token","value":"{{api-key}}"}]},"isInherited":false},"method":"GET","header":[{"key":"Authorization","value":"{{api-key}}"}],"body":{"mode":"formdata","formdata":[]},"url":"{{api-url}}/api/v1/customers?page=2&count=2","urlObject":{"path":["api","v1","customers"],"host":["{{api-url}}"],"query":[{"key":"page","value":"2"},{"key":"count","value":"2"}],"variable":[]}},"response":[{"id":"d8599fbb-2181-4773-a974-601fa613c0c2","name":"specific page","originalRequest":{"method":"GET","header":[{"key":"Authorization","value":"{{api-key}}"}],"body":{"mode":"formdata","formdata":[]},"url":{"raw":"{{api-url}}/api/v1/customers?page=2&count=2","host":["{{api-url}}"],"path":["api","v1","customers"],"query":[{"key":"page","value":"2"},{"key":"count","value":"2"}]}},"status":"OK","code":200,"_postman_previewlanguage":"json","header":[{"key":"Content-Type","value":"application/json; charset=utf-8","name":"Content-Type","description":"The mime type of this content"},{"key":"Date","value":"Sat, 26 May 2018 22:05:55 GMT","name":"Date","description":"The date and time that the message was sent"},{"key":"Request-Context","value":"appId=cid-v1:","name":"Request-Context","description":"Custom header"},{"key":"Server","value":"Kestrel","name":"Server","description":"A name for the server"},{"key":"Transfer-Encoding","value":"chunked","name":"Transfer-Encoding","description":"The form of encoding used to safely transfer the entity to the user. Currently defined methods are: chunked, compress, deflate, gzip, identity."}],"cookie":[],"responseTime":null,"body":"{\"items\":[{\"customerId\":1,\"firstName\":\"Andrey\",\"fullName\":\"Питеров Andrey Владимирович\",\"sellerId\":1,\"sellerName\":null,\"storeId\":1,\"storeName\":null,\"phoneNumber\":\"79046779010\",\"cardNumber\":\"1111111111111\",\"lastName\":\"Питеров\",\"surname\":\"Владимирович\",\"gender\":\"male\",\"birth\":{\"day\":24,\"month\":3,\"year\":1990},\"registeredAt\":\"2018-05-26T21:00:42.1388485+03:00\"}],\"meta\":{\"pageNumber\":2,\"offset\":2,\"size\":2,\"totalElements\":3,\"totalPages\":2,\"hasPrev\":true,\"hasNext\":false}}"}],"_postman_id":"8b41210f-98b2-4dd5-a8a6-b6bd1e053a3b"},{"name":"Get by ID","id":"8af65ee9-d4bd-419f-81b6-a38402246e0a","request":{"auth":{"type":"bearer","bearer":{"basicConfig":[{"key":"token","value":"{{api-key}}"}]},"isInherited":false},"method":"GET","header":[{"key":"Authorization","value":"{{api-key}}"}],"body":{"mode":"formdata","formdata":[]},"url":"{{api-url}}/api/v1/customers/{{customerId}}","description":"<p>Get Customer by ID</p>\n","urlObject":{"path":["api","v1","customers","{{customerId}}"],"host":["{{api-url}}"],"query":[],"variable":[]}},"response":[{"id":"41dd6746-06a9-49b6-8917-4df256e9f7d5","name":"Get by ID","originalRequest":{"method":"GET","header":[{"key":"Authorization","value":"{{api-key}}","warning":"This is a duplicate header and will be overridden by the Authorization header generated by Postman.","disabled":false}],"body":{"mode":"formdata","formdata":[]},"url":"{{api-url}}/api/v1/customers/{{customerId}}"},"status":"OK","code":200,"_postman_previewlanguage":"json","header":[{"key":"Content-Type","value":"application/json; charset=utf-8","name":"Content-Type","description":"The mime type of this content"},{"key":"Date","value":"Sat, 26 May 2018 22:18:55 GMT","name":"Date","description":"The date and time that the message was sent"},{"key":"Request-Context","value":"appId=cid-v1:","name":"Request-Context","description":"Custom header"},{"key":"Server","value":"Kestrel","name":"Server","description":"A name for the server"},{"key":"Transfer-Encoding","value":"chunked","name":"Transfer-Encoding","description":"The form of encoding used to safely transfer the entity to the user. Currently defined methods are: chunked, compress, deflate, gzip, identity."}],"cookie":[],"responseTime":null,"body":"{\"customerId\":2,\"firstName\":\"Иван\",\"fullName\":\"Иван\",\"sellerId\":1,\"sellerName\":null,\"storeId\":1,\"storeName\":null,\"phoneNumber\":\"79000000000\",\"cardNumber\":null,\"lastName\":null,\"surname\":null,\"gender\":null,\"birth\":{\"day\":null,\"month\":null,\"year\":null},\"registeredAt\":\"2018-05-26T23:12:28.1295177+03:00\"}"}],"_postman_id":"8af65ee9-d4bd-419f-81b6-a38402246e0a"}],"id":"9e53ed88-0074-4eef-a20f-fd4ff3c40b6b","description":"<p>By default items count per page is 50. The max items count per page is 50.</p>\n","event":[{"listen":"prerequest","script":{"id":"2d7f151a-e7cb-45ec-982b-2746d16b731e","type":"text/javascript","exec":[""]}},{"listen":"test","script":{"id":"86a6f99b-e7c8-4b9f-b090-4f712cbb7778","type":"text/javascript","exec":[""]}}],"_postman_id":"9e53ed88-0074-4eef-a20f-fd4ff3c40b6b","auth":{"type":"bearer","bearer":{"basicConfig":[{"key":"token","value":"2COk7UQOL-jWwz2VYXWmgoUZiGo8YAxdDrcAa8Aso8qXboRgjeATOWq"}]},"isInherited":true,"source":{"_postman_id":"0bc77335-c12f-4475-a732-4b8aeb750221","id":"0bc77335-c12f-4475-a732-4b8aeb750221","name":"BonusGroups API","type":"collection"}}},{"name":"Filtering","item":[{"name":"Filter by cardNumber","id":"0518edbd-4f88-4172-aec6-e9169fca7d6d","request":{"auth":{"type":"bearer","bearer":{"basicConfig":[{"key":"token","value":"{{api-key}}"}]},"isInherited":false},"method":"GET","header":[{"key":"Authorization","value":"{{api-key}}"}],"body":{"mode":"formdata","formdata":[]},"url":"{{api-url}}/api/v1/customers?cardNumber=1111111111112","urlObject":{"path":["api","v1","customers"],"host":["{{api-url}}"],"query":[{"key":"cardNumber","value":"1111111111112"}],"variable":[]}},"response":[{"id":"32e76f52-06a2-4309-a445-f104979e548e","name":"one customer","originalRequest":{"method":"GET","header":[{"key":"Authorization","value":"{{api-key}}","warning":"This is a duplicate header and will be overridden by the Authorization header generated by Postman.","disabled":false}],"body":{"mode":"formdata","formdata":[]},"url":{"raw":"{{api-url}}/api/v1/customers?cardNumber=1111111111112","host":["{{api-url}}"],"path":["api","v1","customers"],"query":[{"key":"cardNumber","value":"1111111111112"}]}},"status":"OK","code":200,"_postman_previewlanguage":"json","header":[{"key":"Content-Type","value":"application/json; charset=utf-8","name":"Content-Type","description":"The mime type of this content"},{"key":"Date","value":"Sat, 08 Sep 2018 14:13:00 GMT","name":"Date","description":"The date and time that the message was sent"},{"key":"Request-Context","value":"appId=cid-v1:","name":"Request-Context","description":"Custom header"},{"key":"Server","value":"Kestrel","name":"Server","description":"A name for the server"},{"key":"Transfer-Encoding","value":"chunked","name":"Transfer-Encoding","description":"The form of encoding used to safely transfer the entity to the user. Currently defined methods are: chunked, compress, deflate, gzip, identity."}],"cookie":[],"responseTime":null,"body":"{\"items\":[{\"customerId\":4,\"firstName\":\"Andrey\",\"fullName\":\"Питеров Andrey Владимирович\",\"sellerId\":1,\"sellerName\":null,\"storeId\":1,\"storeName\":null,\"phoneNumber\":\"79000000001\",\"cardNumber\":\"1111111111112\",\"lastName\":\"Питеров\",\"surname\":\"Владимирович\",\"gender\":\"male\",\"birth\":{\"day\":null,\"month\":null,\"year\":null},\"registeredAt\":\"2018-05-27T01:33:01.9236679+03:00\"}],\"meta\":{\"pageNumber\":1,\"offset\":0,\"size\":50,\"totalElements\":1,\"totalPages\":1,\"hasPrev\":false,\"hasNext\":false}}"}],"_postman_id":"0518edbd-4f88-4172-aec6-e9169fca7d6d"},{"name":"Filter by phoneNumber","id":"4653b0a7-17a0-4bb5-a797-adf91c58d273","request":{"auth":{"type":"bearer","bearer":{"basicConfig":[{"key":"token","value":"{{api-key}}"}]},"isInherited":false},"method":"GET","header":[{"key":"Authorization","value":"{{api-key}}"}],"body":{"mode":"formdata","formdata":[]},"url":"{{api-url}}/api/v1/customers?phoneNumber=79000000001","urlObject":{"path":["api","v1","customers"],"host":["{{api-url}}"],"query":[{"key":"phoneNumber","value":"79000000001"}],"variable":[]}},"response":[{"id":"5210bb8c-6451-4205-9c50-ab0de668a090","name":"one customer","originalRequest":{"method":"GET","header":[{"key":"Authorization","value":"{{api-key}}","disabled":false}],"body":{"mode":"formdata","formdata":[]},"url":{"raw":"{{api-url}}/api/v1/customers?phoneNumber=79000000001","host":["{{api-url}}"],"path":["api","v1","customers"],"query":[{"key":"phoneNumber","value":"79000000001"}]}},"status":"OK","code":200,"_postman_previewlanguage":"json","header":[{"key":"Content-Type","value":"application/json; charset=utf-8","name":"Content-Type","description":"The mime type of this content"},{"key":"Date","value":"Sat, 08 Sep 2018 14:15:34 GMT","name":"Date","description":"The date and time that the message was sent"},{"key":"Request-Context","value":"appId=cid-v1:","name":"Request-Context","description":"Custom header"},{"key":"Server","value":"Kestrel","name":"Server","description":"A name for the server"},{"key":"Transfer-Encoding","value":"chunked","name":"Transfer-Encoding","description":"The form of encoding used to safely transfer the entity to the user. Currently defined methods are: chunked, compress, deflate, gzip, identity."}],"cookie":[],"responseTime":null,"body":"{\"items\":[{\"customerId\":4,\"firstName\":\"Andrey\",\"fullName\":\"Питеров Andrey Владимирович\",\"sellerId\":1,\"sellerName\":null,\"storeId\":1,\"storeName\":null,\"phoneNumber\":\"79000000001\",\"cardNumber\":\"1111111111112\",\"lastName\":\"Питеров\",\"surname\":\"Владимирович\",\"gender\":\"male\",\"birth\":{\"day\":null,\"month\":null,\"year\":null},\"registeredAt\":\"2018-05-27T01:33:01.9236679+03:00\"}],\"meta\":{\"pageNumber\":1,\"offset\":0,\"size\":50,\"totalElements\":1,\"totalPages\":1,\"hasPrev\":false,\"hasNext\":false}}"}],"_postman_id":"4653b0a7-17a0-4bb5-a797-adf91c58d273"}],"id":"3ef71501-6d4e-4873-87d7-c04eaf8df0c5","_postman_id":"3ef71501-6d4e-4873-87d7-c04eaf8df0c5","description":"","auth":{"type":"bearer","bearer":{"basicConfig":[{"key":"token","value":"2COk7UQOL-jWwz2VYXWmgoUZiGo8YAxdDrcAa8Aso8qXboRgjeATOWq"}]},"isInherited":true,"source":{"_postman_id":"0bc77335-c12f-4475-a732-4b8aeb750221","id":"0bc77335-c12f-4475-a732-4b8aeb750221","name":"BonusGroups API","type":"collection"}}},{"name":"Saving","item":[{"name":"new customer","id":"5a197773-afed-48bb-9286-25ec4eb1fac1","request":{"auth":{"type":"bearer","bearer":{"basicConfig":[{"key":"token","value":"2COk7UQOL-jWwz2VYXWmgoUZiGo8YAxdDrcAa8Aso8qXboRgjeATOWq"}]},"isInherited":false},"method":"POST","header":[{"key":"Content-Type","value":"application/json"},{"key":"Authorization","value":"{{api-key}}"}],"body":{"mode":"raw","raw":"{\n\t\"firstName\":\"Иван\",\n\t\"phoneNumber\": \"79100000000\"\n}"},"url":"http://localhost:53374/api/v1/customers?sellerId=1&storeId=1","description":"<p>Required properties: firstName, phoneNumber or cardNumber.\nAlso required query parameters are sellerId - who save the customer, and storeId - in which store the customer is registered</p>\n","urlObject":{"path":["api","v1","customers"],"host":["http://localhost:53374"],"query":[{"key":"sellerId","value":"1"},{"key":"storeId","value":"1"}],"variable":[]}},"response":[{"id":"007b1cdf-5844-4f69-a976-4c380b90fa70","name":"already exists","originalRequest":{"method":"POST","header":[{"key":"Authorization","value":"{{api-key}}","disabled":false},{"key":"Content-Type","name":"Content-Type","value":"application/json","disabled":false}],"body":{"mode":"raw","raw":"{\n\t\"firstName\":\"Andrey\",\n\t\"lastName\":\"Питеров\",\n\t\"surname\":\"Владимирович\",\n\t\"phoneNumber\":\"79900000000\",\n\t\"cardNumber\":\"1111111111111\",\n\t\"birthdayAsString\":\"24/03/1990\",\n\t\"gender\":\"male\"\n}"},"url":{"raw":"http://localhost:53374/api/v1/customers?sellerId=1&storeId=1","host":["http://localhost:53374"],"path":["api","v1","customers"],"query":[{"key":"sellerId","value":"1"},{"key":"storeId","value":"1"}]}},"status":"Bad Request","code":400,"_postman_previewlanguage":"json","header":[{"key":"Content-Type","value":"application/json; charset=utf-8","name":"Content-Type","description":"The mime type of this content"},{"key":"Date","value":"Sat, 26 May 2018 22:40:43 GMT","name":"Date","description":"The date and time that the message was sent"},{"key":"Request-Context","value":"appId=cid-v1:","name":"Request-Context","description":"Custom header"},{"key":"Server","value":"Kestrel","name":"Server","description":"A name for the server"},{"key":"Transfer-Encoding","value":"chunked","name":"Transfer-Encoding","description":"The form of encoding used to safely transfer the entity to the user. Currently defined methods are: chunked, compress, deflate, gzip, identity."}],"cookie":[],"responseTime":null,"body":"{\"message\":\"AlreadyExist\"}"},{"id":"9d434f21-440e-475a-9095-d5ecf41b92ed","name":"full information","originalRequest":{"method":"POST","header":[{"key":"Authorization","value":"{{api-key}}","disabled":false},{"key":"Content-Type","value":"application/json","disabled":false}],"body":{"mode":"raw","raw":"{\n\t\"firstName\":\"Andrey\",\n\t\"lastName\":\"Питеров\",\n\t\"surname\":\"Владимирович\",\n\t\"phoneNumber\":\"79800000000\",\n\t\"cardNumber\":\"1111111111121\",\n\t\"birthday\":\"24/03/1990\",\n\t\"gender\":\"male\"\n}"},"url":{"raw":"http://localhost:53374/api/v1/customers?sellerId=1&storeId=1","host":["http://localhost:53374"],"path":["api","v1","customers"],"query":[{"key":"sellerId","value":"1"},{"key":"storeId","value":"1"}]}},"status":"Created","code":201,"_postman_previewlanguage":"json","header":[{"key":"Content-Type","value":"application/json; charset=utf-8","name":"Content-Type","description":"The mime type of this content"},{"key":"Date","value":"Sat, 26 May 2018 22:41:39 GMT","name":"Date","description":"The date and time that the message was sent"},{"key":"Location","value":"http://localhost:53374/api/customers/6?CompanyId=02f72ecf-6213-40f6-d749-08d5c166d7b9","name":"Location","description":"Used in redirection, or when a new resource has been created."},{"key":"Request-Context","value":"appId=cid-v1:","name":"Request-Context","description":"Custom header"},{"key":"Server","value":"Kestrel","name":"Server","description":"A name for the server"},{"key":"Transfer-Encoding","value":"chunked","name":"Transfer-Encoding","description":"The form of encoding used to safely transfer the entity to the user. Currently defined methods are: chunked, compress, deflate, gzip, identity."}],"cookie":[],"responseTime":null,"body":"{\"customerId\":6,\"firstName\":\"Andrey\",\"fullName\":\"Питеров Andrey Владимирович\",\"sellerId\":1,\"sellerName\":\"andrey\",\"storeId\":1,\"storeName\":null,\"phoneNumber\":\"79800000000\",\"cardNumber\":\"1111111111121\",\"lastName\":\"Питеров\",\"surname\":\"Владимирович\",\"gender\":\"male\",\"birth\":{\"day\":null,\"month\":null,\"year\":null},\"registeredAt\":\"2018-05-27T01:41:37.0986601+03:00\"}"},{"id":"d5d9e6fb-1159-4784-837b-76565a2f3522","name":"new customer","originalRequest":{"method":"POST","header":[{"key":"Content-Type","value":"application/json","disabled":false},{"key":"Authorization","value":"{{api-key}}","disabled":false}],"body":{"mode":"raw","raw":"{\n\t\"firstName\":\"Иван\",\n\t\"phoneNumber\": \"79900000000\"\n}"},"url":{"raw":"http://localhost:53374/api/v1/customers?sellerId=1&storeId=1","host":["http://localhost:53374"],"path":["api","v1","customers"],"query":[{"key":"sellerId","value":"1"},{"key":"storeId","value":"1"}]}},"status":"Created","code":201,"_postman_previewlanguage":"json","header":[{"key":"Content-Type","value":"application/json; charset=utf-8","name":"Content-Type","description":"The mime type of this content"},{"key":"Date","value":"Sat, 26 May 2018 22:38:38 GMT","name":"Date","description":"The date and time that the message was sent"},{"key":"Location","value":"http://localhost:53374/api/customers/5?CompanyId=02f72ecf-6213-40f6-d749-08d5c166d7b9","name":"Location","description":"Used in redirection, or when a new resource has been created."},{"key":"Request-Context","value":"appId=cid-v1:","name":"Request-Context","description":"Custom header"},{"key":"Server","value":"Kestrel","name":"Server","description":"A name for the server"},{"key":"Transfer-Encoding","value":"chunked","name":"Transfer-Encoding","description":"The form of encoding used to safely transfer the entity to the user. Currently defined methods are: chunked, compress, deflate, gzip, identity."}],"cookie":[],"responseTime":null,"body":"{\"customerId\":5,\"firstName\":\"Иван\",\"fullName\":\"Иван\",\"sellerId\":1,\"sellerName\":\"andrey\",\"storeId\":1,\"storeName\":null,\"phoneNumber\":\"79900000000\",\"cardNumber\":null,\"lastName\":null,\"surname\":null,\"gender\":\"male\",\"birth\":{\"day\":null,\"month\":null,\"year\":null},\"registeredAt\":\"2018-05-27T01:38:36.0254141+03:00\"}"}],"_postman_id":"5a197773-afed-48bb-9286-25ec4eb1fac1"}],"id":"20d53101-b8dd-4fff-bfdf-626e8f470f6a","event":[{"listen":"prerequest","script":{"id":"4b332d7c-a88a-4273-af83-64635c8e01c1","type":"text/javascript","exec":[""]}},{"listen":"test","script":{"id":"9d107054-2a5c-403f-a5ef-0a95c6a1cbe4","type":"text/javascript","exec":[""]}}],"_postman_id":"20d53101-b8dd-4fff-bfdf-626e8f470f6a","description":"","auth":{"type":"bearer","bearer":{"basicConfig":[{"key":"token","value":"2COk7UQOL-jWwz2VYXWmgoUZiGo8YAxdDrcAa8Aso8qXboRgjeATOWq"}]},"isInherited":true,"source":{"_postman_id":"0bc77335-c12f-4475-a732-4b8aeb750221","id":"0bc77335-c12f-4475-a732-4b8aeb750221","name":"BonusGroups API","type":"collection"}}},{"name":"Updating","item":[{"name":"update customer","id":"697515c2-4d73-45d5-875c-ddfab00c7746","request":{"auth":{"type":"bearer","bearer":{"basicConfig":[{"key":"token","value":"{{api-key}}"}]},"isInherited":false},"method":"PUT","header":[{"key":"Authorization","value":"{{api-key}}"},{"key":"Content-Type","value":"application/json"}],"body":{"mode":"raw","raw":"{\n\t\"isFirstNameChanged\": true,\n\t\"firstName\": \"Andrey\",\n\t\"isLastNameChanged\": true,\n\t\"lastName\": \"Piterov\",\n\t\"isSurnameChanged\": true,\n\t\"surname\": \"Valimirovich\",\n\t\"isGenderChanged\": true,\n\t\"gender\": \"male\",\n\t\"isBirthdayChanged\": true,\n\t\"birthday\": \"24-03\",\n\t\"isCardNumberChanged\": true,\n\t\"cardNumber\": \"xxx777yyy\",\n\t\"isPhoneNumberChanged\": true,\n\t\"phoneNumber\": \"79012345678\"\n}"},"url":"{{api-url}}/api/v1/customers/{{customerId}}","description":"<p>You can update customer' propeties below</p>\n<p>string FirstName\nstring LastName\nstring Surname</p>\n<p>string CardNumber\nstring PhoneNumber | 11 digits number, starts with 7</p>\n<p>string Birthday | 'DD-MM-YYYY' or 'DD-MM'\nstring Gender | 'male' or 'female'</p>\n<p>IMPORTANT! To tell server to update proper field you have to send boolean flag.</p>\n","urlObject":{"path":["api","v1","customers","{{customerId}}"],"host":["{{api-url}}"],"query":[],"variable":[]}},"response":[{"id":"04579c77-7a7d-4785-bf0d-75abea8cbd17","name":"update gender and birth","originalRequest":{"method":"PUT","header":[{"key":"Authorization","value":"{{api-key}}","disabled":false},{"key":"Content-Type","value":"application/json","disabled":false}],"body":{"mode":"raw","raw":"{\n\t\"isGenderChanged\": true,\n\t\"gender\": \"female\",\n\t\"isBirthdayChanged\": true,\n\t\"birthday\": \"21-12-1991\",\n}"},"url":"{{api-url}}/api/v1/customers/{{customerId}}"},"status":"No Content","code":204,"_postman_previewlanguage":"plain","header":[{"key":"Date","value":"Tue, 04 Sep 2018 22:07:01 GMT","name":"Date","description":"The date and time that the message was sent"},{"key":"Request-Context","value":"appId=cid-v1:","name":"Request-Context","description":"Custom header"},{"key":"Server","value":"Kestrel","name":"Server","description":"A name for the server"}],"cookie":[],"responseTime":null,"body":""},{"id":"ba49058a-3220-420f-8b05-e4cd9ef65372","name":"update all fields","originalRequest":{"method":"PUT","header":[{"key":"Authorization","value":"{{api-key}}","warning":"This is a duplicate header and will be overridden by the Authorization header generated by Postman.","disabled":false},{"key":"Content-Type","name":"Content-Type","value":"application/json","disabled":false}],"body":{"mode":"raw","raw":"{\n\t\"isFirstNameChanged\": true,\n\t\"firstName\": \"Andrey\",\n\t\"isLastNameChanged\": true,\n\t\"lastName\": \"Piterov\",\n\t\"isSurnameChanged\": true,\n\t\"surname\": \"Valimirovich\",\n\t\"isGenderChanged\": true,\n\t\"gender\": \"male\",\n\t\"isBirthdayChanged\": true,\n\t\"birthday\": \"24-03\",\n\t\"isCardNumberChanged\": true,\n\t\"cardNumber\": \"xxx777yyy\",\n\t\"isPhoneNumberChanged\": true,\n\t\"phoneNumber\": \"79012345678\"\n}"},"url":"{{api-url}}/api/v1/customers/{{customerId}}"},"status":"No Content","code":204,"_postman_previewlanguage":"plain","header":[{"key":"Date","value":"Tue, 04 Sep 2018 22:03:47 GMT","name":"Date","description":"The date and time that the message was sent"},{"key":"Request-Context","value":"appId=cid-v1:","name":"Request-Context","description":"Custom header"},{"key":"Server","value":"Kestrel","name":"Server","description":"A name for the server"}],"cookie":[],"responseTime":null,"body":""}],"_postman_id":"697515c2-4d73-45d5-875c-ddfab00c7746"}],"id":"148be249-7e3c-4cba-b9eb-d2f237d65e26","_postman_id":"148be249-7e3c-4cba-b9eb-d2f237d65e26","description":"","auth":{"type":"bearer","bearer":{"basicConfig":[{"key":"token","value":"2COk7UQOL-jWwz2VYXWmgoUZiGo8YAxdDrcAa8Aso8qXboRgjeATOWq"}]},"isInherited":true,"source":{"_postman_id":"0bc77335-c12f-4475-a732-4b8aeb750221","id":"0bc77335-c12f-4475-a732-4b8aeb750221","name":"BonusGroups API","type":"collection"}}},{"name":"Last seen","id":"52608e62-bcdd-423e-bf74-75faf9de4e5f","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"auth":{"type":"bearer","bearer":{"basicConfig":[{"key":"token","value":"{{api-key}}"}]},"isInherited":false},"method":"GET","header":[{"warning":"This is a duplicate header and will be overridden by the Authorization header generated by Postman.","key":"Authorization","value":"{{api-key}}","type":"text"}],"url":"{{api-url}}/api/v1/customers/{{customerId}}/last-seen","description":"<p>Get last seen information.</p>\n<p>If there is no any lost settings \"lostAfterDays\" will be always is 0.</p>\n","urlObject":{"path":["api","v1","customers","{{customerId}}","last-seen"],"host":["{{api-url}}"],"query":[],"variable":[]}},"response":[{"id":"5b0d4cea-019d-4016-b0ff-60450c6d0647","name":"Last seen (without lost settings)","originalRequest":{"method":"GET","header":[],"url":"{{api-url}}/api/v1/customers/{{customerId}}/last-seen"},"status":"OK","code":200,"_postman_previewlanguage":"json","header":[{"key":"Date","value":"Thu, 04 Apr 2019 12:15:29 GMT"},{"key":"Content-Type","value":"application/json; charset=utf-8"},{"key":"Server","value":"Kestrel"},{"key":"Transfer-Encoding","value":"chunked"}],"cookie":[],"responseTime":null,"body":"{\n    \"customerId\": 25,\n    \"lastSeen\": \"2019-01-17T10:06:49.9929503+03:00\",\n    \"lostAfterDays\": 0,\n    \"lastSeenDaysAgo\": 77,\n    \"event\": \"registration\",\n    \"isLost\": false\n}"},{"id":"c71f3600-8b27-4e84-96e3-c0940564dffd","name":"Last seen (with lost settings)","originalRequest":{"method":"GET","header":[],"url":"{{api-url}}/api/v1/customers/{{customerId}}/last-seen"},"status":"OK","code":200,"_postman_previewlanguage":"json","header":[{"key":"Date","value":"Thu, 04 Apr 2019 12:32:13 GMT"},{"key":"Content-Type","value":"application/json; charset=utf-8"},{"key":"Server","value":"Kestrel"},{"key":"Transfer-Encoding","value":"chunked"}],"cookie":[],"responseTime":null,"body":"{\n    \"customerId\": 25,\n    \"lastSeen\": \"2018-08-06T17:37:14.0756273+03:00\",\n    \"lostAfterDays\": 90,\n    \"lastSeenDaysAgo\": 240,\n    \"event\": \"purchase\",\n    \"isLost\": true\n}"},{"id":"d25c8992-47bc-45bf-bfee-e9b3659e428a","name":"Last seen (customer not found)","originalRequest":{"method":"GET","header":[],"url":"{{api-url}}/api/v1/customers/100000000/last-seen"},"status":"Not Found","code":404,"_postman_previewlanguage":"json","header":[{"key":"Date","value":"Thu, 04 Apr 2019 12:16:47 GMT"},{"key":"Content-Type","value":"application/json; charset=utf-8"},{"key":"Server","value":"Kestrel"},{"key":"Transfer-Encoding","value":"chunked"}],"cookie":[],"responseTime":null,"body":"{\n    \"message\": \"CustomerNotFound\"\n}"}],"_postman_id":"52608e62-bcdd-423e-bf74-75faf9de4e5f"}],"id":"eee00d1f-1815-4bb3-bb17-7fc7bd8e96d3","event":[{"listen":"prerequest","script":{"id":"9cedb88e-273c-49c9-be4d-da083abdffc2","type":"text/javascript","exec":[""]}},{"listen":"test","script":{"id":"f07366f6-3c5d-46e0-91da-8818d770d43d","type":"text/javascript","exec":[""]}}],"_postman_id":"eee00d1f-1815-4bb3-bb17-7fc7bd8e96d3","description":"","auth":{"type":"bearer","bearer":{"basicConfig":[{"key":"token","value":"2COk7UQOL-jWwz2VYXWmgoUZiGo8YAxdDrcAa8Aso8qXboRgjeATOWq"}]},"isInherited":true,"source":{"_postman_id":"0bc77335-c12f-4475-a732-4b8aeb750221","id":"0bc77335-c12f-4475-a732-4b8aeb750221","name":"BonusGroups API","type":"collection"}}},{"name":"Discount levels","item":[{"name":"Get discount level","id":"1eca13f0-6a99-499f-b18c-57aed8e981ad","request":{"auth":{"type":"bearer","bearer":{"basicConfig":[{"key":"token","value":"<token>"}]},"isInherited":false},"method":"GET","header":[{"key":"Authorization","value":"{{api-key}}"}],"body":{"mode":"formdata","formdata":[]},"url":"{{api-url}}/api/v1/customers/{{customerId}}/discount-level","description":"<p>Get current discount level</p>\n","urlObject":{"path":["api","v1","customers","{{customerId}}","discount-level"],"host":["{{api-url}}"],"query":[],"variable":[]}},"response":[],"_postman_id":"1eca13f0-6a99-499f-b18c-57aed8e981ad"}],"id":"8c4b7d21-dec6-414a-988f-731dd846a2fb","description":"<p>Customer discount level againt his total purchase sum.</p>\n","_postman_id":"8c4b7d21-dec6-414a-988f-731dd846a2fb","auth":{"type":"bearer","bearer":{"basicConfig":[{"key":"token","value":"2COk7UQOL-jWwz2VYXWmgoUZiGo8YAxdDrcAa8Aso8qXboRgjeATOWq"}]},"isInherited":true,"source":{"_postman_id":"0bc77335-c12f-4475-a732-4b8aeb750221","id":"0bc77335-c12f-4475-a732-4b8aeb750221","name":"BonusGroups API","type":"collection"}}},{"name":"Phones","item":[{"name":"Phone","id":"b58e6c10-284e-4b43-a0f2-9dd73c51697c","request":{"auth":{"type":"bearer","bearer":{"basicConfig":[{"key":"token","value":"{{api-key}}"}]},"isInherited":false},"method":"GET","header":[{"key":"Authorization","value":"{{api-key}}"}],"body":{"mode":"formdata","formdata":[]},"url":"http://localhost:53374/api/v1/phones/{{customerPhoneNumber}}","description":"<p>Make shure that a customer with that phone number exists in database</p>\n","urlObject":{"path":["api","v1","phones","{{customerPhoneNumber}}"],"host":["http://localhost:53374"],"query":[],"variable":[]}},"response":[{"id":"5411f277-5cbf-4b0c-9feb-fdc7751b1b69","name":"204 Phone Does Not Exist","originalRequest":{"method":"GET","header":[{"key":"Authorization","value":"{{api-key}}","disabled":false}],"body":{"mode":"formdata","formdata":[]},"url":"http://localhost:53374/api/v1/phones/79000000009"},"status":"No Content","code":204,"_postman_previewlanguage":"plain","header":[{"key":"Content-Length","value":"0","name":"Content-Length","description":"The length of the response body in octets (8-bit bytes)"},{"key":"Date","value":"Sat, 02 Jun 2018 07:49:48 GMT","name":"Date","description":"The date and time that the message was sent"},{"key":"Request-Context","value":"appId=cid-v1:","name":"Request-Context","description":"Custom header"},{"key":"Server","value":"Kestrel","name":"Server","description":"A name for the server"}],"cookie":[],"responseTime":null,"body":""},{"id":"5cd5401f-b5bc-41a9-8fcb-1e43d3aa80e4","name":"200 OK Phone exists","originalRequest":{"method":"GET","header":[{"key":"Authorization","value":"{{api-key}}","disabled":false}],"body":{"mode":"formdata","formdata":[]},"url":"http://localhost:53374/api/v1/phones/{{customerPhoneNumber}}"},"status":"OK","code":200,"_postman_previewlanguage":"json","header":[{"key":"Content-Type","value":"application/json; charset=utf-8","name":"Content-Type","description":"The mime type of this content"},{"key":"Date","value":"Sat, 02 Jun 2018 11:21:29 GMT","name":"Date","description":"The date and time that the message was sent"},{"key":"Server","value":"Kestrel","name":"Server","description":"A name for the server"},{"key":"Transfer-Encoding","value":"chunked","name":"Transfer-Encoding","description":"The form of encoding used to safely transfer the entity to the user. Currently defined methods are: chunked, compress, deflate, gzip, identity."}],"cookie":[],"responseTime":null,"body":"{\n    \"customerId\": 1,\n    \"firstName\": \"Andrey\",\n    \"fullName\": \"Питеров Andrey Владимирович\",\n    \"phoneNumber\": \"79000000001\",\n    \"lastName\": \"Питеров\",\n    \"surname\": \"Владимирович\",\n    \"gender\": \"male\",\n    \"birth\": {\n        \"day\": 24,\n        \"month\": 3,\n        \"year\": 1990\n    }\n}"},{"id":"f82f4f73-7e56-4592-8ccd-2daea1f77a1f","name":"400 Invalid Phone (invalid start digits)","originalRequest":{"method":"GET","header":[{"key":"Authorization","value":"{{api-key}}","disabled":false}],"body":{"mode":"formdata","formdata":[]},"url":"http://localhost:53374/api/v1/phones/71000000009"},"status":"Bad Request","code":400,"_postman_previewlanguage":"json","header":[{"key":"Content-Type","value":"application/json; charset=utf-8","name":"Content-Type","description":"The mime type of this content"},{"key":"Date","value":"Sat, 02 Jun 2018 07:53:02 GMT","name":"Date","description":"The date and time that the message was sent"},{"key":"Request-Context","value":"appId=cid-v1:","name":"Request-Context","description":"Custom header"},{"key":"Server","value":"Kestrel","name":"Server","description":"A name for the server"},{"key":"Transfer-Encoding","value":"chunked","name":"Transfer-Encoding","description":"The form of encoding used to safely transfer the entity to the user. Currently defined methods are: chunked, compress, deflate, gzip, identity."}],"cookie":[],"responseTime":null,"body":"{\"message\":\"InvalidPhoneStartDigits\"}"},{"id":"ffc58b90-9078-4e38-badb-7f1013fae521","name":"400 Invalid Phone (invalid length)","originalRequest":{"method":"GET","header":[{"key":"Authorization","value":"{{api-key}}","disabled":false}],"body":{"mode":"formdata","formdata":[]},"url":"http://localhost:53374/api/v1/phones/790000000"},"status":"Bad Request","code":400,"_postman_previewlanguage":"json","header":[{"key":"Content-Type","value":"application/json; charset=utf-8","name":"Content-Type","description":"The mime type of this content"},{"key":"Date","value":"Sat, 02 Jun 2018 07:47:15 GMT","name":"Date","description":"The date and time that the message was sent"},{"key":"Request-Context","value":"appId=cid-v1:","name":"Request-Context","description":"Custom header"},{"key":"Server","value":"Kestrel","name":"Server","description":"A name for the server"},{"key":"Transfer-Encoding","value":"chunked","name":"Transfer-Encoding","description":"The form of encoding used to safely transfer the entity to the user. Currently defined methods are: chunked, compress, deflate, gzip, identity."}],"cookie":[],"responseTime":null,"body":"{\"message\":\"InvalidPhoneLength\"}"}],"_postman_id":"b58e6c10-284e-4b43-a0f2-9dd73c51697c"}],"id":"01c7f95f-1058-46fe-8e75-6ccfddb49c3b","description":"<p>Deal against phones directly</p>\n","auth":{"type":"bearer","bearer":{"basicConfig":[{"key":"token","value":"{{api-key}}"}]},"isInherited":false},"_postman_id":"01c7f95f-1058-46fe-8e75-6ccfddb49c3b"},{"name":"Promotions","item":[{"name":"Get promotions","id":"c7465bdf-b015-45f4-bf3a-c3e5ab8bba65","request":{"auth":{"type":"bearer","bearer":{"basicConfig":[{"key":"token","value":"{{api-key}}"}]},"isInherited":false},"method":"GET","header":[{"key":"Authorization","value":"{{api-key}}"}],"body":{"mode":"formdata","formdata":[]},"url":"http://localhost:53374/api/v1/promotions","description":"<p>get promotions, by default first 50 items</p>\n","urlObject":{"path":["api","v1","promotions"],"host":["http://localhost:53374"],"query":[],"variable":[]}},"response":[{"id":"d482341a-f5b8-4640-a7bf-ffdad7b2927d","name":"Get promotions by paging","originalRequest":{"method":"GET","header":[{"key":"Authorization","value":"{{api-key}}","disabled":false}],"body":{"mode":"formdata","formdata":[]},"url":{"raw":"http://localhost:53374/api/v1/promotions?page=1&count=2","host":["http://localhost:53374"],"path":["api","v1","promotions"],"query":[{"key":"page","value":"1"},{"key":"count","value":"2"}]}},"status":"OK","code":200,"_postman_previewlanguage":"json","header":[{"key":"Content-Type","value":"application/json; charset=utf-8","name":"Content-Type","description":"The mime type of this content"},{"key":"Date","value":"Thu, 30 Aug 2018 09:29:34 GMT","name":"Date","description":"The date and time that the message was sent"},{"key":"Request-Context","value":"appId=cid-v1:","name":"Request-Context","description":"Custom header"},{"key":"Server","value":"Kestrel","name":"Server","description":"A name for the server"},{"key":"Transfer-Encoding","value":"chunked","name":"Transfer-Encoding","description":"The form of encoding used to safely transfer the entity to the user. Currently defined methods are: chunked, compress, deflate, gzip, identity."}],"cookie":[],"responseTime":null,"body":"{\"items\":[{\"promotionId\":1,\"title\":\"10-10\",\"description\":null,\"percentPerPurchase\":10.0,\"decreaseOnPercent\":10.0,\"startAt\":\"2018-06-09T17:53:57.0777833+00:00\",\"endAt\":null,\"deactivatedAt\":null,\"createdAt\":\"2018-06-09T17:53:57.0775868+00:00\",\"stores\":[]},{\"promotionId\":2,\"title\":\"Акция НГ\",\"description\":null,\"percentPerPurchase\":33.0,\"decreaseOnPercent\":null,\"startAt\":\"2018-08-30T09:25:38.1445448+00:00\",\"endAt\":null,\"deactivatedAt\":null,\"createdAt\":\"2018-08-30T09:25:38.1444632+00:00\",\"stores\":[]}],\"meta\":{\"pageNumber\":1,\"offset\":0,\"size\":2,\"totalElements\":3,\"totalPages\":2,\"hasPrev\":false,\"hasNext\":true}}"},{"id":"f3be629f-ee7b-4f8a-b758-4e673ad21dcd","name":"Get promotions","originalRequest":{"method":"GET","header":[{"key":"Authorization","value":"{{api-key}}","warning":"This is a duplicate header and will be overridden by the Authorization header generated by Postman.","disabled":false}],"body":{"mode":"formdata","formdata":[]},"url":"http://localhost:53374/api/v1/promotions"},"status":"OK","code":200,"_postman_previewlanguage":"json","header":[{"key":"Content-Type","value":"application/json; charset=utf-8","name":"Content-Type","description":"The mime type of this content"},{"key":"Date","value":"Thu, 30 Aug 2018 09:28:05 GMT","name":"Date","description":"The date and time that the message was sent"},{"key":"Server","value":"Kestrel","name":"Server","description":"A name for the server"},{"key":"Transfer-Encoding","value":"chunked","name":"Transfer-Encoding","description":"The form of encoding used to safely transfer the entity to the user. Currently defined methods are: chunked, compress, deflate, gzip, identity."}],"cookie":[],"responseTime":null,"body":"{\"items\":[{\"promotionId\":1,\"title\":\"10-10\",\"description\":null,\"percentPerPurchase\":10.0,\"decreaseOnPercent\":10.0,\"startAt\":\"2018-06-09T17:53:57.0777833+00:00\",\"endAt\":null,\"deactivatedAt\":null,\"createdAt\":\"2018-06-09T17:53:57.0775868+00:00\",\"stores\":[]},{\"promotionId\":2,\"title\":\"Акция НГ\",\"description\":null,\"percentPerPurchase\":33.0,\"decreaseOnPercent\":null,\"startAt\":\"2018-08-30T09:25:38.1445448+00:00\",\"endAt\":null,\"deactivatedAt\":null,\"createdAt\":\"2018-08-30T09:25:38.1444632+00:00\",\"stores\":[]},{\"promotionId\":3,\"title\":\"DoJo\",\"description\":null,\"percentPerPurchase\":null,\"decreaseOnPercent\":55.0,\"startAt\":\"2018-08-30T09:26:26.1687418+00:00\",\"endAt\":null,\"deactivatedAt\":null,\"createdAt\":\"2018-08-30T09:26:26.1687409+00:00\",\"stores\":[]}],\"meta\":{\"pageNumber\":1,\"offset\":0,\"size\":50,\"totalElements\":3,\"totalPages\":1,\"hasPrev\":false,\"hasNext\":false}}"}],"_postman_id":"c7465bdf-b015-45f4-bf3a-c3e5ab8bba65"}],"id":"5e3789e9-f206-408e-8434-89c3aa8523df","_postman_id":"5e3789e9-f206-408e-8434-89c3aa8523df","description":"","auth":{"type":"bearer","bearer":{"basicConfig":[{"key":"token","value":"2COk7UQOL-jWwz2VYXWmgoUZiGo8YAxdDrcAa8Aso8qXboRgjeATOWq"}]},"isInherited":true,"source":{"_postman_id":"0bc77335-c12f-4475-a732-4b8aeb750221","id":"0bc77335-c12f-4475-a732-4b8aeb750221","name":"BonusGroups API","type":"collection"}}},{"name":"Purchases","item":[{"name":"Filtering","item":[{"name":"Get purchases after some date","id":"53912c20-99a0-470f-97a4-183d57dc3658","request":{"auth":{"type":"bearer","bearer":{"basicConfig":[{"key":"token","value":"{{api-key}}"}]},"isInherited":false},"method":"GET","header":[{"key":"Authorization","value":"{{api-key}}"}],"body":{"mode":"formdata","formdata":[]},"url":"http://localhost:53374/api/v1/purchases/q?before=2018-05-28T01:32:00+03:00","urlObject":{"path":["api","v1","purchases","q"],"host":["http://localhost:53374"],"query":[{"key":"before","value":"2018-05-28T01:32:00+03:00"}],"variable":[]}},"response":[{"id":"0194a9bc-bf8d-4f5a-8d42-bff3603fc15b","name":"Get purchases after","originalRequest":{"method":"GET","header":[{"key":"Authorization","value":"{{api-key}}","disabled":false}],"body":{"mode":"formdata","formdata":[]},"url":{"raw":"http://localhost:53374/api/v1/purchases/q?after=2018-06-10","host":["http://localhost:53374"],"path":["api","v1","purchases","q"],"query":[{"key":"after","value":"2018-06-10"}]}},"status":"OK","code":200,"_postman_previewlanguage":"json","header":[{"key":"Content-Type","value":"application/json; charset=utf-8","name":"Content-Type","description":"The mime type of this content"},{"key":"Date","value":"Thu, 30 Aug 2018 11:38:11 GMT","name":"Date","description":"The date and time that the message was sent"},{"key":"Request-Context","value":"appId=cid-v1:","name":"Request-Context","description":"Custom header"},{"key":"Server","value":"Kestrel","name":"Server","description":"A name for the server"},{"key":"Transfer-Encoding","value":"chunked","name":"Transfer-Encoding","description":"The form of encoding used to safely transfer the entity to the user. Currently defined methods are: chunked, compress, deflate, gzip, identity."}],"cookie":[],"responseTime":null,"body":"{\"items\":[{\"purchaseId\":27,\"customerId\":3,\"storeId\":1,\"sellerId\":1,\"price\":1000.00,\"purchasedAt\":\"2018-07-02T14:36:17.7002162+03:00\",\"canceledAt\":null,\"minus\":100.00,\"promotionId\":1,\"type\":2,\"purchaseType\":\"promo\",\"bonusAmount\":90.00,\"percentPerPurchase\":10.0,\"paidAmount\":900.00,\"salePercent\":10.0,\"paidPercent\":90.0,\"purchaseSum\":900.00,\"customerFullName\":\"Иван\",\"customerPhone\":null,\"customerCard\":null,\"sellerFullName\":\"andrey\",\"storeAddress\":\"Cairo, Nasr City, 32\",\"promotionTitle\":\"\"},{\"purchaseId\":26,\"customerId\":14,\"storeId\":1,\"sellerId\":1,\"price\":1000.00,\"purchasedAt\":\"2018-06-14T19:51:54.9902801+03:00\",\"canceledAt\":null,\"minus\":500.00,\"promotionId\":null,\"type\":1,\"purchaseType\":\"coupon\",\"bonusAmount\":0.00,\"percentPerPurchase\":0.0,\"paidAmount\":500.00,\"salePercent\":50.0,\"paidPercent\":50.0,\"purchaseSum\":500.00,\"customerFullName\":\"Andrew\",\"customerPhone\":null,\"customerCard\":null,\"sellerFullName\":\"andrey\",\"storeAddress\":\"Cairo, Nasr City, 32\",\"promotionTitle\":\"\"},{\"purchaseId\":24,\"customerId\":13,\"storeId\":1,\"sellerId\":1,\"price\":7000.00,\"purchasedAt\":\"2018-06-10T15:53:57.3768306+03:00\",\"canceledAt\":null,\"minus\":440.00,\"promotionId\":null,\"type\":0,\"purchaseType\":\"normal\",\"bonusAmount\":656.00,\"percentPerPurchase\":10.0,\"paidAmount\":6560.00,\"salePercent\":6.2857142857142857142857142900,\"paidPercent\":93.71428571428571428571428571,\"purchaseSum\":6560.00,\"customerFullName\":\"Vasya\",\"customerPhone\":null,\"customerCard\":null,\"sellerFullName\":\"andrey\",\"storeAddress\":\"Cairo, Nasr City, 32\",\"promotionTitle\":\"\"},{\"purchaseId\":23,\"customerId\":13,\"storeId\":1,\"sellerId\":1,\"price\":5000.00,\"purchasedAt\":\"2018-06-10T15:53:14.1080649+03:00\",\"canceledAt\":null,\"minus\":581.00,\"promotionId\":1,\"type\":2,\"purchaseType\":\"promo\",\"bonusAmount\":441.90,\"percentPerPurchase\":10.0,\"paidAmount\":4419.00,\"salePercent\":11.6200,\"paidPercent\":88.3800,\"purchaseSum\":4419.00,\"customerFullName\":\"Vasya\",\"customerPhone\":null,\"customerCard\":null,\"sellerFullName\":\"andrey\",\"storeAddress\":\"Cairo, Nasr City, 32\",\"promotionTitle\":\"\"},{\"purchaseId\":22,\"customerId\":13,\"storeId\":1,\"sellerId\":1,\"price\":1190.00,\"purchasedAt\":\"2018-06-10T15:14:25.3968962+03:00\",\"canceledAt\":null,\"minus\":290.00,\"promotionId\":1,\"type\":2,\"purchaseType\":\"promo\",\"bonusAmount\":90.00,\"percentPerPurchase\":10.0,\"paidAmount\":900.00,\"salePercent\":24.369747899159663865546218490,\"paidPercent\":75.630252100840336134453781510,\"purchaseSum\":900.00,\"customerFullName\":\"Vasya\",\"customerPhone\":null,\"customerCard\":null,\"sellerFullName\":\"andrey\",\"storeAddress\":\"Cairo, Nasr City, 32\",\"promotionTitle\":\"\"},{\"purchaseId\":21,\"customerId\":13,\"storeId\":1,\"sellerId\":1,\"price\":1000.00,\"purchasedAt\":\"2018-06-10T15:12:55.0888912+03:00\",\"canceledAt\":null,\"minus\":100.00,\"promotionId\":1,\"type\":2,\"purchaseType\":\"promo\",\"bonusAmount\":90.00,\"percentPerPurchase\":10.0,\"paidAmount\":900.00,\"salePercent\":10.0,\"paidPercent\":90.0,\"purchaseSum\":900.00,\"customerFullName\":\"Vasya\",\"customerPhone\":null,\"customerCard\":null,\"sellerFullName\":\"andrey\",\"storeAddress\":\"Cairo, Nasr City, 32\",\"promotionTitle\":\"\"},{\"purchaseId\":20,\"customerId\":13,\"storeId\":1,\"sellerId\":1,\"price\":1000.00,\"purchasedAt\":\"2018-06-10T14:56:38.9307178+03:00\",\"canceledAt\":null,\"minus\":0.00,\"promotionId\":1,\"type\":2,\"purchaseType\":\"promo\",\"bonusAmount\":100.00,\"percentPerPurchase\":10.0,\"paidAmount\":1000.00,\"salePercent\":0.0,\"paidPercent\":100.0,\"purchaseSum\":1000.00,\"customerFullName\":\"Vasya\",\"customerPhone\":null,\"customerCard\":null,\"sellerFullName\":\"andrey\",\"storeAddress\":\"Cairo, Nasr City, 32\",\"promotionTitle\":\"\"},{\"purchaseId\":19,\"customerId\":12,\"storeId\":1,\"sellerId\":1,\"price\":1000.00,\"purchasedAt\":\"2018-06-10T12:23:55.5194274+03:00\",\"canceledAt\":null,\"minus\":190.00,\"promotionId\":1,\"type\":2,\"purchaseType\":\"promo\",\"bonusAmount\":81.00,\"percentPerPurchase\":10.0,\"paidAmount\":810.00,\"salePercent\":19.00,\"paidPercent\":81.00,\"purchaseSum\":810.00,\"customerFullName\":\"Петя\",\"customerPhone\":null,\"customerCard\":null,\"sellerFullName\":\"andrey\",\"storeAddress\":\"Cairo, Nasr City, 32\",\"promotionTitle\":\"\"},{\"purchaseId\":17,\"customerId\":12,\"storeId\":1,\"sellerId\":1,\"price\":1000.00,\"purchasedAt\":\"2018-06-10T12:00:18.1167651+03:00\",\"canceledAt\":null,\"minus\":100.00,\"promotionId\":null,\"type\":0,\"purchaseType\":\"normal\",\"bonusAmount\":90.00,\"percentPerPurchase\":10.0,\"paidAmount\":900.00,\"salePercent\":10.0,\"paidPercent\":90.0,\"purchaseSum\":900.00,\"customerFullName\":\"Петя\",\"customerPhone\":null,\"customerCard\":null,\"sellerFullName\":\"andrey\",\"storeAddress\":\"Cairo, Nasr City, 32\",\"promotionTitle\":\"\"},{\"purchaseId\":16,\"customerId\":12,\"storeId\":1,\"sellerId\":1,\"price\":1000.00,\"purchasedAt\":\"2018-06-10T11:48:32.5486532+03:00\",\"canceledAt\":null,\"minus\":100.00,\"promotionId\":null,\"type\":0,\"purchaseType\":\"normal\",\"bonusAmount\":90.00,\"percentPerPurchase\":10.0,\"paidAmount\":900.00,\"salePercent\":10.0,\"paidPercent\":90.0,\"purchaseSum\":900.00,\"customerFullName\":\"Петя\",\"customerPhone\":null,\"customerCard\":null,\"sellerFullName\":\"andrey\",\"storeAddress\":\"Cairo, Nasr City, 32\",\"promotionTitle\":\"\"},{\"purchaseId\":15,\"customerId\":12,\"storeId\":1,\"sellerId\":1,\"price\":1000.00,\"purchasedAt\":\"2018-06-10T11:46:16.5798337+03:00\",\"canceledAt\":null,\"minus\":100.00,\"promotionId\":null,\"type\":0,\"purchaseType\":\"normal\",\"bonusAmount\":90.00,\"percentPerPurchase\":10.0,\"paidAmount\":900.00,\"salePercent\":10.0,\"paidPercent\":90.0,\"purchaseSum\":900.00,\"customerFullName\":\"Петя\",\"customerPhone\":null,\"customerCard\":null,\"sellerFullName\":\"andrey\",\"storeAddress\":\"Cairo, Nasr City, 32\",\"promotionTitle\":\"\"},{\"purchaseId\":14,\"customerId\":12,\"storeId\":1,\"sellerId\":1,\"price\":1000.00,\"purchasedAt\":\"2018-06-10T11:44:33.7781543+03:00\",\"canceledAt\":null,\"minus\":50.00,\"promotionId\":null,\"type\":0,\"purchaseType\":\"normal\",\"bonusAmount\":95.00,\"percentPerPurchase\":10.0,\"paidAmount\":950.00,\"salePercent\":5.00,\"paidPercent\":95.00,\"purchaseSum\":950.00,\"customerFullName\":\"Петя\",\"customerPhone\":null,\"customerCard\":null,\"sellerFullName\":\"andrey\",\"storeAddress\":\"Cairo, Nasr City, 32\",\"promotionTitle\":\"\"},{\"purchaseId\":13,\"customerId\":12,\"storeId\":1,\"sellerId\":1,\"price\":1000.00,\"purchasedAt\":\"2018-06-10T11:43:44.0874708+03:00\",\"canceledAt\":null,\"minus\":0.00,\"promotionId\":null,\"type\":0,\"purchaseType\":\"normal\",\"bonusAmount\":100.00,\"percentPerPurchase\":10.0,\"paidAmount\":1000.00,\"salePercent\":0.0,\"paidPercent\":100.0,\"purchaseSum\":1000.00,\"customerFullName\":\"Петя\",\"customerPhone\":null,\"customerCard\":null,\"sellerFullName\":\"andrey\",\"storeAddress\":\"Cairo, Nasr City, 32\",\"promotionTitle\":\"\"},{\"purchaseId\":12,\"customerId\":11,\"storeId\":1,\"sellerId\":1,\"price\":1000.00,\"purchasedAt\":\"2018-06-10T07:29:22.9927055+03:00\",\"canceledAt\":null,\"minus\":269.20,\"promotionId\":1,\"type\":2,\"purchaseType\":\"promo\",\"bonusAmount\":73.08,\"percentPerPurchase\":10.0,\"paidAmount\":730.80,\"salePercent\":26.9200,\"paidPercent\":73.0800,\"purchaseSum\":730.80,\"customerFullName\":\"Иван\",\"customerPhone\":null,\"customerCard\":null,\"sellerFullName\":\"andrey\",\"storeAddress\":\"Cairo, Nasr City, 32\",\"promotionTitle\":\"\"},{\"purchaseId\":11,\"customerId\":11,\"storeId\":1,\"sellerId\":1,\"price\":1000.00,\"purchasedAt\":\"2018-06-10T07:18:49.0995572+03:00\",\"canceledAt\":null,\"minus\":197.20,\"promotionId\":1,\"type\":2,\"purchaseType\":\"promo\",\"bonusAmount\":80.28,\"percentPerPurchase\":10.0,\"paidAmount\":802.80,\"salePercent\":19.7200,\"paidPercent\":80.2800,\"purchaseSum\":802.80,\"customerFullName\":\"Иван\",\"customerPhone\":null,\"customerCard\":null,\"sellerFullName\":\"andrey\",\"storeAddress\":\"Cairo, Nasr City, 32\",\"promotionTitle\":\"\"}],\"meta\":{\"pageNumber\":1,\"offset\":0,\"size\":50,\"totalElements\":15,\"totalPages\":1,\"hasPrev\":false,\"hasNext\":false}}"},{"id":"a8d33bad-199c-4184-a790-6cb4dbd3da7e","name":"Get purchases after some date with time","originalRequest":{"method":"GET","header":[{"key":"Authorization","value":"{{api-key}}","warning":"This is a duplicate header and will be overridden by the Authorization header generated by Postman.","disabled":false}],"body":{"mode":"formdata","formdata":[]},"url":{"raw":"http://localhost:53374/api/v1/purchases/q?after=2018-07-02T14:36:17+03:00","host":["http://localhost:53374"],"path":["api","v1","purchases","q"],"query":[{"key":"after","value":"2018-07-02T14:36:17+03:00"}]}},"status":"OK","code":200,"_postman_previewlanguage":"json","header":[{"key":"Content-Type","value":"application/json; charset=utf-8","name":"Content-Type","description":"The mime type of this content"},{"key":"Date","value":"Thu, 30 Aug 2018 11:37:24 GMT","name":"Date","description":"The date and time that the message was sent"},{"key":"Request-Context","value":"appId=cid-v1:","name":"Request-Context","description":"Custom header"},{"key":"Server","value":"Kestrel","name":"Server","description":"A name for the server"},{"key":"Transfer-Encoding","value":"chunked","name":"Transfer-Encoding","description":"The form of encoding used to safely transfer the entity to the user. Currently defined methods are: chunked, compress, deflate, gzip, identity."}],"cookie":[],"responseTime":null,"body":"{\"items\":[{\"purchaseId\":27,\"customerId\":3,\"storeId\":1,\"sellerId\":1,\"price\":1000.00,\"purchasedAt\":\"2018-07-02T14:36:17.7002162+03:00\",\"canceledAt\":null,\"minus\":100.00,\"promotionId\":1,\"type\":2,\"purchaseType\":\"promo\",\"bonusAmount\":90.00,\"percentPerPurchase\":10.0,\"paidAmount\":900.00,\"salePercent\":10.0,\"paidPercent\":90.0,\"purchaseSum\":900.00,\"customerFullName\":\"Иван\",\"customerPhone\":null,\"customerCard\":null,\"sellerFullName\":\"andrey\",\"storeAddress\":\"Cairo, Nasr City, 32\",\"promotionTitle\":\"\"}],\"meta\":{\"pageNumber\":1,\"offset\":0,\"size\":50,\"totalElements\":1,\"totalPages\":1,\"hasPrev\":false,\"hasNext\":false}}"}],"_postman_id":"53912c20-99a0-470f-97a4-183d57dc3658"},{"name":"Get purchases before saome date","id":"1cb072dc-d94c-45ec-aa6a-6416204ca5e9","request":{"method":"GET","header":[],"body":{"mode":"formdata","formdata":[]},"url":"","description":"<p>The date is against PurchaseAt</p>\n","auth":{"type":"bearer","bearer":{"basicConfig":[{"key":"token","value":"2COk7UQOL-jWwz2VYXWmgoUZiGo8YAxdDrcAa8Aso8qXboRgjeATOWq"}]},"isInherited":true,"source":{"_postman_id":"0bc77335-c12f-4475-a732-4b8aeb750221","id":"0bc77335-c12f-4475-a732-4b8aeb750221","name":"BonusGroups API","type":"collection"}},"urlObject":{"query":[],"variable":[]}},"response":[{"id":"d624093b-6340-473e-8191-6787c6c11417","name":"date","originalRequest":{"method":"GET","header":[{"key":"Authorization","value":"{{api-key}}","disabled":false}],"body":{"mode":"formdata","formdata":[]},"url":{"raw":"http://localhost:53374/api/v1/purchases/q?before=2018-05-28","host":["http://localhost:53374"],"path":["api","v1","purchases","q"],"query":[{"key":"before","value":"2018-05-28"}]}},"status":"OK","code":200,"_postman_previewlanguage":"json","header":[{"key":"Content-Type","value":"application/json; charset=utf-8","name":"Content-Type","description":"The mime type of this content"},{"key":"Date","value":"Thu, 30 Aug 2018 11:55:11 GMT","name":"Date","description":"The date and time that the message was sent"},{"key":"Request-Context","value":"appId=cid-v1:","name":"Request-Context","description":"Custom header"},{"key":"Server","value":"Kestrel","name":"Server","description":"A name for the server"},{"key":"Transfer-Encoding","value":"chunked","name":"Transfer-Encoding","description":"The form of encoding used to safely transfer the entity to the user. Currently defined methods are: chunked, compress, deflate, gzip, identity."}],"cookie":[],"responseTime":null,"body":"{\"items\":[{\"purchaseId\":6,\"customerId\":7,\"storeId\":1,\"sellerId\":1,\"price\":1000.00,\"purchasedAt\":\"2018-05-28T01:32:34.1848722+03:00\",\"canceledAt\":null,\"minus\":0.00,\"promotionId\":null,\"type\":0,\"purchaseType\":\"normal\",\"bonusAmount\":100.00,\"percentPerPurchase\":10.0,\"paidAmount\":1000.00,\"salePercent\":0.0,\"paidPercent\":100.0,\"purchaseSum\":1000.00,\"externalPurchaseId\":null,\"customerFullName\":\"Питерова Анастасия\",\"customerPhone\":null,\"customerCard\":null,\"sellerFullName\":\"andrey\",\"storeAddress\":\"Cairo, Nasr City, 32\",\"promotionTitle\":\"\"},{\"purchaseId\":5,\"customerId\":7,\"storeId\":1,\"sellerId\":1,\"price\":7000.00,\"purchasedAt\":\"2018-05-28T01:06:20.7515795+03:00\",\"canceledAt\":null,\"minus\":0.00,\"promotionId\":null,\"type\":0,\"purchaseType\":\"normal\",\"bonusAmount\":700.00,\"percentPerPurchase\":10.0,\"paidAmount\":7000.00,\"salePercent\":0.0,\"paidPercent\":100.0,\"purchaseSum\":7000.00,\"externalPurchaseId\":null,\"customerFullName\":\"Питерова Анастасия\",\"customerPhone\":null,\"customerCard\":null,\"sellerFullName\":\"andrey\",\"storeAddress\":\"Cairo, Nasr City, 32\",\"promotionTitle\":\"\"},{\"purchaseId\":4,\"customerId\":2,\"storeId\":1,\"sellerId\":1,\"price\":1000.00,\"purchasedAt\":\"2018-05-28T00:56:39.3765907+03:00\",\"canceledAt\":null,\"minus\":0.00,\"promotionId\":null,\"type\":0,\"purchaseType\":\"normal\",\"bonusAmount\":100.00,\"percentPerPurchase\":10.0,\"paidAmount\":1000.00,\"salePercent\":0.0,\"paidPercent\":100.0,\"purchaseSum\":1000.00,\"externalPurchaseId\":null,\"customerFullName\":\"Иван\",\"customerPhone\":null,\"customerCard\":null,\"sellerFullName\":\"andrey\",\"storeAddress\":\"Cairo, Nasr City, 32\",\"promotionTitle\":\"\"},{\"purchaseId\":3,\"customerId\":2,\"storeId\":1,\"sellerId\":1,\"price\":2000.00,\"purchasedAt\":\"2018-05-27T20:33:39.6204395+03:00\",\"canceledAt\":null,\"minus\":50.00,\"promotionId\":null,\"type\":0,\"purchaseType\":\"normal\",\"bonusAmount\":195.00,\"percentPerPurchase\":10.0,\"paidAmount\":1950.00,\"salePercent\":2.500,\"paidPercent\":97.500,\"purchaseSum\":1950.00,\"externalPurchaseId\":null,\"customerFullName\":\"Иван\",\"customerPhone\":null,\"customerCard\":null,\"sellerFullName\":\"andrey\",\"storeAddress\":\"Cairo, Nasr City, 32\",\"promotionTitle\":\"\"},{\"purchaseId\":2,\"customerId\":2,\"storeId\":1,\"sellerId\":1,\"price\":1000.00,\"purchasedAt\":\"2018-05-27T20:22:12.5907761+03:00\",\"canceledAt\":null,\"minus\":0.00,\"promotionId\":null,\"type\":0,\"purchaseType\":\"normal\",\"bonusAmount\":100.00,\"percentPerPurchase\":10.0,\"paidAmount\":1000.00,\"salePercent\":0.0,\"paidPercent\":100.0,\"purchaseSum\":1000.00,\"externalPurchaseId\":null,\"customerFullName\":\"Иван\",\"customerPhone\":null,\"customerCard\":null,\"sellerFullName\":\"andrey\",\"storeAddress\":\"Cairo, Nasr City, 32\",\"promotionTitle\":\"\"},{\"purchaseId\":1,\"customerId\":1,\"storeId\":1,\"sellerId\":1,\"price\":1000.00,\"purchasedAt\":\"2018-05-27T19:25:41.1970087+03:00\",\"canceledAt\":null,\"minus\":0.00,\"promotionId\":null,\"type\":0,\"purchaseType\":\"normal\",\"bonusAmount\":100.00,\"percentPerPurchase\":10.0,\"paidAmount\":1000.00,\"salePercent\":0.0,\"paidPercent\":100.0,\"purchaseSum\":1000.00,\"externalPurchaseId\":null,\"customerFullName\":\"Питеров Andrey Владимирович\",\"customerPhone\":null,\"customerCard\":null,\"sellerFullName\":\"andrey\",\"storeAddress\":\"Cairo, Nasr City, 32\",\"promotionTitle\":\"\"}],\"meta\":{\"pageNumber\":1,\"offset\":0,\"size\":50,\"totalElements\":6,\"totalPages\":1,\"hasPrev\":false,\"hasNext\":false}}"},{"id":"df997bde-d639-4576-8c2e-9a6e529e44c5","name":"date with time","originalRequest":{"method":"GET","header":[{"key":"Authorization","value":"{{api-key}}","warning":"This is a duplicate header and will be overridden by the Authorization header generated by Postman.","disabled":false}],"body":{"mode":"formdata","formdata":[]},"url":{"raw":"http://localhost:53374/api/v1/purchases/q?before=2018-05-28T01:32:00+03:00","host":["http://localhost:53374"],"path":["api","v1","purchases","q"],"query":[{"key":"before","value":"2018-05-28T01:32:00+03:00"}]}},"status":"OK","code":200,"_postman_previewlanguage":"json","header":[{"key":"Content-Type","value":"application/json; charset=utf-8","name":"Content-Type","description":"The mime type of this content"},{"key":"Date","value":"Thu, 30 Aug 2018 11:54:38 GMT","name":"Date","description":"The date and time that the message was sent"},{"key":"Server","value":"Kestrel","name":"Server","description":"A name for the server"},{"key":"Transfer-Encoding","value":"chunked","name":"Transfer-Encoding","description":"The form of encoding used to safely transfer the entity to the user. Currently defined methods are: chunked, compress, deflate, gzip, identity."}],"cookie":[],"responseTime":null,"body":"{\"items\":[{\"purchaseId\":5,\"customerId\":7,\"storeId\":1,\"sellerId\":1,\"price\":7000.00,\"purchasedAt\":\"2018-05-28T01:06:20.7515795+03:00\",\"canceledAt\":null,\"minus\":0.00,\"promotionId\":null,\"type\":0,\"purchaseType\":\"normal\",\"bonusAmount\":700.00,\"percentPerPurchase\":10.0,\"paidAmount\":7000.00,\"salePercent\":0.0,\"paidPercent\":100.0,\"purchaseSum\":7000.00,\"externalPurchaseId\":null,\"customerFullName\":\"Питерова Анастасия\",\"customerPhone\":null,\"customerCard\":null,\"sellerFullName\":\"andrey\",\"storeAddress\":\"Cairo, Nasr City, 32\",\"promotionTitle\":\"\"},{\"purchaseId\":4,\"customerId\":2,\"storeId\":1,\"sellerId\":1,\"price\":1000.00,\"purchasedAt\":\"2018-05-28T00:56:39.3765907+03:00\",\"canceledAt\":null,\"minus\":0.00,\"promotionId\":null,\"type\":0,\"purchaseType\":\"normal\",\"bonusAmount\":100.00,\"percentPerPurchase\":10.0,\"paidAmount\":1000.00,\"salePercent\":0.0,\"paidPercent\":100.0,\"purchaseSum\":1000.00,\"externalPurchaseId\":null,\"customerFullName\":\"Иван\",\"customerPhone\":null,\"customerCard\":null,\"sellerFullName\":\"andrey\",\"storeAddress\":\"Cairo, Nasr City, 32\",\"promotionTitle\":\"\"},{\"purchaseId\":3,\"customerId\":2,\"storeId\":1,\"sellerId\":1,\"price\":2000.00,\"purchasedAt\":\"2018-05-27T20:33:39.6204395+03:00\",\"canceledAt\":null,\"minus\":50.00,\"promotionId\":null,\"type\":0,\"purchaseType\":\"normal\",\"bonusAmount\":195.00,\"percentPerPurchase\":10.0,\"paidAmount\":1950.00,\"salePercent\":2.500,\"paidPercent\":97.500,\"purchaseSum\":1950.00,\"externalPurchaseId\":null,\"customerFullName\":\"Иван\",\"customerPhone\":null,\"customerCard\":null,\"sellerFullName\":\"andrey\",\"storeAddress\":\"Cairo, Nasr City, 32\",\"promotionTitle\":\"\"},{\"purchaseId\":2,\"customerId\":2,\"storeId\":1,\"sellerId\":1,\"price\":1000.00,\"purchasedAt\":\"2018-05-27T20:22:12.5907761+03:00\",\"canceledAt\":null,\"minus\":0.00,\"promotionId\":null,\"type\":0,\"purchaseType\":\"normal\",\"bonusAmount\":100.00,\"percentPerPurchase\":10.0,\"paidAmount\":1000.00,\"salePercent\":0.0,\"paidPercent\":100.0,\"purchaseSum\":1000.00,\"externalPurchaseId\":null,\"customerFullName\":\"Иван\",\"customerPhone\":null,\"customerCard\":null,\"sellerFullName\":\"andrey\",\"storeAddress\":\"Cairo, Nasr City, 32\",\"promotionTitle\":\"\"},{\"purchaseId\":1,\"customerId\":1,\"storeId\":1,\"sellerId\":1,\"price\":1000.00,\"purchasedAt\":\"2018-05-27T19:25:41.1970087+03:00\",\"canceledAt\":null,\"minus\":0.00,\"promotionId\":null,\"type\":0,\"purchaseType\":\"normal\",\"bonusAmount\":100.00,\"percentPerPurchase\":10.0,\"paidAmount\":1000.00,\"salePercent\":0.0,\"paidPercent\":100.0,\"purchaseSum\":1000.00,\"externalPurchaseId\":null,\"customerFullName\":\"Питеров Andrey Владимирович\",\"customerPhone\":null,\"customerCard\":null,\"sellerFullName\":\"andrey\",\"storeAddress\":\"Cairo, Nasr City, 32\",\"promotionTitle\":\"\"}],\"meta\":{\"pageNumber\":1,\"offset\":0,\"size\":50,\"totalElements\":5,\"totalPages\":1,\"hasPrev\":false,\"hasNext\":false}}"}],"_postman_id":"1cb072dc-d94c-45ec-aa6a-6416204ca5e9"},{"name":"customer's purchases","id":"6ee038ba-358d-46b3-8884-44b8370aa6ab","request":{"method":"GET","header":[],"body":{"mode":"formdata","formdata":[]},"url":"","auth":{"type":"bearer","bearer":{"basicConfig":[{"key":"token","value":"2COk7UQOL-jWwz2VYXWmgoUZiGo8YAxdDrcAa8Aso8qXboRgjeATOWq"}]},"isInherited":true,"source":{"_postman_id":"0bc77335-c12f-4475-a732-4b8aeb750221","id":"0bc77335-c12f-4475-a732-4b8aeb750221","name":"BonusGroups API","type":"collection"}},"urlObject":{"query":[],"variable":[]}},"response":[{"id":"ab01efa0-b252-4b16-ba59-90c7efc6240d","name":"customer's purchases after some date","originalRequest":{"method":"GET","header":[{"key":"Authorization","value":"{{api-key}}","disabled":false}],"body":{"mode":"formdata","formdata":[]},"url":{"raw":"http://localhost:53374/api/v1/purchases/q?customerId=7&after=2018-08-30","host":["http://localhost:53374"],"path":["api","v1","purchases","q"],"query":[{"key":"customerId","value":"7"},{"key":"after","value":"2018-08-30"}]}},"status":"OK","code":200,"_postman_previewlanguage":"json","header":[{"key":"Content-Type","value":"application/json; charset=utf-8","name":"Content-Type","description":"The mime type of this content"},{"key":"Date","value":"Thu, 30 Aug 2018 12:36:05 GMT","name":"Date","description":"The date and time that the message was sent"},{"key":"Request-Context","value":"appId=cid-v1:","name":"Request-Context","description":"Custom header"},{"key":"Server","value":"Kestrel","name":"Server","description":"A name for the server"},{"key":"Transfer-Encoding","value":"chunked","name":"Transfer-Encoding","description":"The form of encoding used to safely transfer the entity to the user. Currently defined methods are: chunked, compress, deflate, gzip, identity."}],"cookie":[],"responseTime":null,"body":"{\"items\":[{\"purchaseId\":28,\"customerId\":7,\"storeId\":1,\"sellerId\":1,\"price\":1000.00,\"purchasedAt\":\"2018-08-30T15:00:57.5822102+03:00\",\"canceledAt\":null,\"minus\":0.00,\"promotionId\":null,\"type\":0,\"purchaseType\":\"normal\",\"bonusAmount\":100.00,\"percentPerPurchase\":10.0,\"paidAmount\":1000.00,\"salePercent\":0.0,\"paidPercent\":100.0,\"purchaseSum\":1000.00,\"externalPurchaseId\":\"x47502JHL\",\"customerFullName\":\"Питерова Анастасия\",\"customerPhone\":null,\"customerCard\":null,\"sellerFullName\":\"andrey\",\"storeAddress\":\"Cairo, Nasr City, 32\",\"promotionTitle\":\"\"}],\"meta\":{\"pageNumber\":1,\"offset\":0,\"size\":50,\"totalElements\":1,\"totalPages\":1,\"hasPrev\":false,\"hasNext\":false}}"},{"id":"cf6118ba-cf5b-4bc5-a52b-cfce087ee09f","name":"customer's purchases","originalRequest":{"method":"GET","header":[{"key":"Authorization","value":"{{api-key}}","warning":"This is a duplicate header and will be overridden by the Authorization header generated by Postman.","disabled":false}],"body":{"mode":"formdata","formdata":[]},"url":{"raw":"http://localhost:53374/api/v1/purchases/q?customerId=7","host":["http://localhost:53374"],"path":["api","v1","purchases","q"],"query":[{"key":"customerId","value":"7"}]}},"status":"OK","code":200,"_postman_previewlanguage":"json","header":[{"key":"Content-Type","value":"application/json; charset=utf-8","name":"Content-Type","description":"The mime type of this content"},{"key":"Date","value":"Thu, 30 Aug 2018 12:35:04 GMT","name":"Date","description":"The date and time that the message was sent"},{"key":"Server","value":"Kestrel","name":"Server","description":"A name for the server"},{"key":"Transfer-Encoding","value":"chunked","name":"Transfer-Encoding","description":"The form of encoding used to safely transfer the entity to the user. Currently defined methods are: chunked, compress, deflate, gzip, identity."}],"cookie":[],"responseTime":null,"body":"{\"items\":[{\"purchaseId\":28,\"customerId\":7,\"storeId\":1,\"sellerId\":1,\"price\":1000.00,\"purchasedAt\":\"2018-08-30T15:00:57.5822102+03:00\",\"canceledAt\":null,\"minus\":0.00,\"promotionId\":null,\"type\":0,\"purchaseType\":\"normal\",\"bonusAmount\":100.00,\"percentPerPurchase\":10.0,\"paidAmount\":1000.00,\"salePercent\":0.0,\"paidPercent\":100.0,\"purchaseSum\":1000.00,\"externalPurchaseId\":\"x47502JHL\",\"customerFullName\":\"Питерова Анастасия\",\"customerPhone\":null,\"customerCard\":null,\"sellerFullName\":\"andrey\",\"storeAddress\":\"Cairo, Nasr City, 32\",\"promotionTitle\":\"\"},{\"purchaseId\":6,\"customerId\":7,\"storeId\":1,\"sellerId\":1,\"price\":1000.00,\"purchasedAt\":\"2018-05-28T01:32:34.1848722+03:00\",\"canceledAt\":null,\"minus\":0.00,\"promotionId\":null,\"type\":0,\"purchaseType\":\"normal\",\"bonusAmount\":100.00,\"percentPerPurchase\":10.0,\"paidAmount\":1000.00,\"salePercent\":0.0,\"paidPercent\":100.0,\"purchaseSum\":1000.00,\"externalPurchaseId\":null,\"customerFullName\":\"Питерова Анастасия\",\"customerPhone\":null,\"customerCard\":null,\"sellerFullName\":\"andrey\",\"storeAddress\":\"Cairo, Nasr City, 32\",\"promotionTitle\":\"\"},{\"purchaseId\":5,\"customerId\":7,\"storeId\":1,\"sellerId\":1,\"price\":7000.00,\"purchasedAt\":\"2018-05-28T01:06:20.7515795+03:00\",\"canceledAt\":null,\"minus\":0.00,\"promotionId\":null,\"type\":0,\"purchaseType\":\"normal\",\"bonusAmount\":700.00,\"percentPerPurchase\":10.0,\"paidAmount\":7000.00,\"salePercent\":0.0,\"paidPercent\":100.0,\"purchaseSum\":7000.00,\"externalPurchaseId\":null,\"customerFullName\":\"Питерова Анастасия\",\"customerPhone\":null,\"customerCard\":null,\"sellerFullName\":\"andrey\",\"storeAddress\":\"Cairo, Nasr City, 32\",\"promotionTitle\":\"\"}],\"meta\":{\"pageNumber\":1,\"offset\":0,\"size\":50,\"totalElements\":3,\"totalPages\":1,\"hasPrev\":false,\"hasNext\":false}}"}],"_postman_id":"6ee038ba-358d-46b3-8884-44b8370aa6ab"}],"id":"a8e0b493-cce7-4a0c-a972-79909bde1983","description":"<p>You can filter purchases by:</p>\n<ol>\n<li>after against PurchaseAt</li>\n<li>before against PurchaseAt</li>\n</ol>\n","event":[{"listen":"prerequest","script":{"id":"1f2f1689-4f9c-496b-8557-166b01e79f16","type":"text/javascript","exec":[""]}},{"listen":"test","script":{"id":"fe916281-5a62-4121-b30b-1ceccb05938d","type":"text/javascript","exec":[""]}}],"_postman_id":"a8e0b493-cce7-4a0c-a972-79909bde1983","auth":{"type":"bearer","bearer":{"basicConfig":[{"key":"token","value":"2COk7UQOL-jWwz2VYXWmgoUZiGo8YAxdDrcAa8Aso8qXboRgjeATOWq"}]},"isInherited":true,"source":{"_postman_id":"0bc77335-c12f-4475-a732-4b8aeb750221","id":"0bc77335-c12f-4475-a732-4b8aeb750221","name":"BonusGroups API","type":"collection"}}},{"name":"The purchase","id":"409f5b3a-5d5f-49fd-878f-21ec1f2c12bf","request":{"auth":{"type":"bearer","bearer":{"basicConfig":[{"key":"token","value":"{{api-key}}"}]},"isInherited":false},"method":"GET","header":[{"key":"Authorization","value":"{{api-key}}"}],"body":{"mode":"formdata","formdata":[]},"url":"http://localhost:53374/api/v1/purchases/{{purchaseId}}","description":"<p>Get Purchase by ID</p>\n","urlObject":{"path":["api","v1","purchases","{{purchaseId}}"],"host":["http://localhost:53374"],"query":[],"variable":[]}},"response":[{"id":"a9938b30-a44d-403b-8e28-e6cc8c67dbde","name":"success","originalRequest":{"method":"GET","header":[{"key":"Authorization","value":"{{api-key}}","disabled":false}],"body":{"mode":"formdata","formdata":[]},"url":"http://localhost:53374/api/v1/purchases/{{purchaseId}}"},"status":"OK","code":200,"_postman_previewlanguage":"json","header":[{"key":"Content-Type","value":"application/json; charset=utf-8","name":"Content-Type","description":"The mime type of this content"},{"key":"Date","value":"Wed, 05 Sep 2018 08:54:08 GMT","name":"Date","description":"The date and time that the message was sent"},{"key":"Server","value":"Kestrel","name":"Server","description":"A name for the server"},{"key":"Transfer-Encoding","value":"chunked","name":"Transfer-Encoding","description":"The form of encoding used to safely transfer the entity to the user. Currently defined methods are: chunked, compress, deflate, gzip, identity."}],"cookie":[],"responseTime":null,"body":"{\"purchaseId\":15,\"customerId\":12,\"storeId\":1,\"sellerId\":1,\"price\":1000.00,\"purchasedAt\":\"2018-06-10T11:46:16.5798337+03:00\",\"canceledAt\":null,\"minus\":100.00,\"promotionId\":null,\"type\":0,\"purchaseType\":\"normal\",\"bonusAmount\":90.00,\"percentPerPurchase\":10.0,\"paidAmount\":900.00,\"salePercent\":10.0,\"paidPercent\":90.0,\"purchaseSum\":900.00,\"externalPurchaseId\":null,\"customerFullName\":\"Петя\",\"customerPhone\":null,\"customerCard\":null,\"sellerFullName\":\"andrey\",\"storeAddress\":\"Cairo, Nasr City, 32\",\"promotionTitle\":\"\"}"}],"_postman_id":"409f5b3a-5d5f-49fd-878f-21ec1f2c12bf"},{"name":"simple purchase","id":"ec82a31f-f0a7-4937-89e0-f6dbad06ebaf","request":{"auth":{"type":"bearer","bearer":{"basicConfig":[{"key":"token","value":"{{api-key}}"}]},"isInherited":false},"method":"POST","header":[{"key":"Authorization","value":"{{api-key}}"},{"key":"Content-Type","value":"application/json"}],"body":{"mode":"raw","raw":"{\n\t\"price\": 1000,\n\t\"externalId\": \"x47502JHL\",\n\t\"storeId\": 1,\n\t\"sellerId\": 1\n}"},"url":"{{api-url}}/api/v1/customers/{{customerId}}/purchases","description":"<p>Simple (or Normal) purchase with minimum requirements</p>\n<div class=\"click-to-expand-wrapper is-table-wrapper\"><table>\n<thead>\n<tr>\n<th>Property</th>\n<th>Required</th>\n<th>Decription</th>\n</tr>\n</thead>\n<tbody>\n<tr>\n<td>price</td>\n<td>required</td>\n<td>Price of Product</td>\n</tr>\n<tr>\n<td>storeId</td>\n<td>required</td>\n<td>Store</td>\n</tr>\n<tr>\n<td>sellerId</td>\n<td>required</td>\n<td>Seller</td>\n</tr>\n<tr>\n<td>externalId</td>\n<td>optional</td>\n<td>Id of purchase from another programs like 1C or Frontol</td>\n</tr>\n<tr>\n<td>minus</td>\n<td>optional</td>\n<td>Bonus amount that customer used with the purchase</td>\n</tr>\n</tbody>\n</table>\n</div>","urlObject":{"path":["api","v1","customers","{{customerId}}","purchases"],"host":["{{api-url}}"],"query":[],"variable":[]}},"response":[{"id":"2e38b532-c570-466b-98f9-de97ba1c63e9","name":"simple purchase","originalRequest":{"method":"POST","header":[{"key":"Authorization","value":"{{api-key}}","warning":"This is a duplicate header and will be overridden by the Authorization header generated by Postman.","disabled":false},{"key":"Content-Type","name":"Content-Type","value":"application/json","disabled":false}],"body":{"mode":"raw","raw":"{\n\t\"price\": 1000,\n\t\"storeId\": 1,\n\t\"sellerId\": 1\n}"},"url":"{{api-url}}/api/v1/customers/{{customerId}}/purchases"},"status":"Created","code":201,"_postman_previewlanguage":"json","header":[{"key":"Content-Type","value":"application/json; charset=utf-8","name":"Content-Type","description":"The mime type of this content"},{"key":"Date","value":"Sun, 27 May 2018 17:22:20 GMT","name":"Date","description":"The date and time that the message was sent"},{"key":"Location","value":"http://localhost:53374/api/customers/2/purchases/2?companyId=02f72ecf-6213-40f6-d749-08d5c166d7b9","name":"Location","description":"Used in redirection, or when a new resource has been created."},{"key":"Server","value":"Kestrel","name":"Server","description":"A name for the server"},{"key":"Transfer-Encoding","value":"chunked","name":"Transfer-Encoding","description":"The form of encoding used to safely transfer the entity to the user. Currently defined methods are: chunked, compress, deflate, gzip, identity."}],"cookie":[],"responseTime":null,"body":"{\n    \"purchaseId\": 2,\n    \"customerId\": 2,\n    \"storeId\": 1,\n    \"sellerId\": 1,\n    \"price\": 1000,\n    \"purchasedAt\": \"2018-05-27T20:22:12.5907761+03:00\",\n    \"canceledAt\": null,\n    \"minus\": 0,\n    \"promotionId\": null,\n    \"purchaseType\": \"normal\",\n    \"bonusAmount\": 100,\n    \"percentPerPurchase\": 10,\n    \"paidAmount\": 1000,\n    \"salePercent\": 0,\n    \"paidPercent\": 100,\n    \"purchaseSum\": 1000,\n    \"customerFullName\": null,\n    \"customerPhone\": null,\n    \"customerCard\": null,\n    \"sellerFullName\": \"Андрей\",\n    \"storeAddress\": \"Москва, на Чапаева\"\n}"},{"id":"589fc126-19e1-4d8a-8856-c2ebdfbc79f9","name":"simple purchase with externalId","originalRequest":{"method":"POST","header":[{"key":"Authorization","value":"{{api-key}}","disabled":false},{"key":"Content-Type","value":"application/json","disabled":false}],"body":{"mode":"raw","raw":"{\n\t\"price\": 1000,\n\t\"externalId\": \"x47502JHL\",\n\t\"storeId\": 1,\n\t\"sellerId\": 1\n}"},"url":"{{api-url}}/api/v1/customers/{{customerId}}/purchases"},"status":"Created","code":201,"_postman_previewlanguage":"json","header":[{"key":"Content-Type","value":"application/json; charset=utf-8","name":"Content-Type","description":"The mime type of this content"},{"key":"Date","value":"Thu, 30 Aug 2018 12:01:14 GMT","name":"Date","description":"The date and time that the message was sent"},{"key":"Location","value":"http://localhost:53374/api/customers/7/purchases/28?companyId=02f72ecf-6213-40f6-d749-08d5c166d7b9","name":"Location","description":"Used in redirection, or when a new resource has been created."},{"key":"Request-Context","value":"appId=cid-v1:","name":"Request-Context","description":"Custom header"},{"key":"Server","value":"Kestrel","name":"Server","description":"A name for the server"},{"key":"Transfer-Encoding","value":"chunked","name":"Transfer-Encoding","description":"The form of encoding used to safely transfer the entity to the user. Currently defined methods are: chunked, compress, deflate, gzip, identity."}],"cookie":[],"responseTime":null,"body":"{\"purchaseId\":28,\"customerId\":7,\"storeId\":1,\"sellerId\":1,\"price\":1000.0,\"purchasedAt\":\"2018-08-30T15:00:57.5822102+03:00\",\"canceledAt\":null,\"minus\":0.0,\"promotionId\":null,\"type\":0,\"purchaseType\":\"normal\",\"bonusAmount\":100.00,\"percentPerPurchase\":10.0,\"paidAmount\":1000.0,\"salePercent\":0.0,\"paidPercent\":100.0,\"purchaseSum\":1000.0,\"externalPurchaseId\":\"x47502JHL\",\"customerFullName\":null,\"customerPhone\":null,\"customerCard\":null,\"sellerFullName\":\"andrey\",\"storeAddress\":\"Cairo, Nasr City, 32\",\"promotionTitle\":\"\"}"},{"id":"5e981def-18c0-47d3-a6e0-b22d867dafea","name":"simple purchase with write-off (minus)","originalRequest":{"method":"POST","header":[{"key":"Authorization","value":"{{api-key}}","disabled":false},{"key":"Content-Type","value":"application/json","disabled":false}],"body":{"mode":"raw","raw":"{\n\t\"price\": 2000,\n\t\"minus\": 50,\n\t\"storeId\": 1,\n\t\"sellerId\": 1\n}"},"url":"{{api-url}}/api/v1/customers/{{customerId}}/purchases"},"status":"Created","code":201,"_postman_previewlanguage":"json","header":[{"key":"Content-Type","value":"application/json; charset=utf-8","name":"Content-Type","description":"The mime type of this content"},{"key":"Date","value":"Sun, 27 May 2018 17:34:02 GMT","name":"Date","description":"The date and time that the message was sent"},{"key":"Location","value":"http://localhost:53374/api/customers/2/purchases/3?companyId=02f72ecf-6213-40f6-d749-08d5c166d7b9","name":"Location","description":"Used in redirection, or when a new resource has been created."},{"key":"Server","value":"Kestrel","name":"Server","description":"A name for the server"},{"key":"Transfer-Encoding","value":"chunked","name":"Transfer-Encoding","description":"The form of encoding used to safely transfer the entity to the user. Currently defined methods are: chunked, compress, deflate, gzip, identity."}],"cookie":[],"responseTime":null,"body":"{\n    \"purchaseId\": 3,\n    \"customerId\": 2,\n    \"storeId\": 1,\n    \"sellerId\": 1,\n    \"price\": 2000,\n    \"purchasedAt\": \"2018-05-27T20:33:39.6204395+03:00\",\n    \"canceledAt\": null,\n    \"minus\": 50,\n    \"promotionId\": null,\n    \"type\": 0,\n    \"purchaseType\": \"normal\",\n    \"bonusAmount\": 195,\n    \"percentPerPurchase\": 10,\n    \"paidAmount\": 1950,\n    \"salePercent\": 2.5,\n    \"paidPercent\": 97.5,\n    \"purchaseSum\": 1950,\n    \"customerFullName\": null,\n    \"customerPhone\": null,\n    \"customerCard\": null,\n    \"sellerFullName\": \"Andrey\",\n    \"storeAddress\": \"Cairo\"\n}"}],"_postman_id":"ec82a31f-f0a7-4937-89e0-f6dbad06ebaf"},{"name":"Customer purchases","id":"96b8b835-b8ce-45dc-ae13-b42427751f9d","request":{"method":"GET","header":[],"body":{"mode":"formdata","formdata":[]},"url":"","description":"<p>Get customer' purchases, by default 25 items, sorted by PurchaseAt date (new purchases are first)</p>\n","auth":{"type":"bearer","bearer":{"basicConfig":[{"key":"token","value":"2COk7UQOL-jWwz2VYXWmgoUZiGo8YAxdDrcAa8Aso8qXboRgjeATOWq"}]},"isInherited":true,"source":{"_postman_id":"0bc77335-c12f-4475-a732-4b8aeb750221","id":"0bc77335-c12f-4475-a732-4b8aeb750221","name":"BonusGroups API","type":"collection"}},"urlObject":{"query":[],"variable":[]}},"response":[{"id":"57ed1b2a-854d-4412-9f43-2a2cbf6aaf25","name":"Customer purchases","originalRequest":{"method":"GET","header":[{"key":"Authorization","value":"{{api-key}}","warning":"This is a duplicate header and will be overridden by the Authorization header generated by Postman.","disabled":false}],"body":{"mode":"formdata","formdata":[]},"url":"http://localhost:53374/api/v1/customers/7/purchases"},"status":"OK","code":200,"_postman_previewlanguage":"json","header":[{"key":"Content-Type","value":"application/json; charset=utf-8","name":"Content-Type","description":"The mime type of this content"},{"key":"Date","value":"Thu, 30 Aug 2018 09:50:56 GMT","name":"Date","description":"The date and time that the message was sent"},{"key":"Server","value":"Kestrel","name":"Server","description":"A name for the server"},{"key":"Transfer-Encoding","value":"chunked","name":"Transfer-Encoding","description":"The form of encoding used to safely transfer the entity to the user. Currently defined methods are: chunked, compress, deflate, gzip, identity."}],"cookie":[],"responseTime":null,"body":"{\"items\":[{\"purchaseId\":6,\"customerId\":7,\"storeId\":1,\"sellerId\":1,\"price\":1000.00,\"purchasedAt\":\"2018-05-28T01:32:34.1848722+03:00\",\"canceledAt\":null,\"minus\":0.00,\"promotionId\":null,\"type\":0,\"purchaseType\":\"normal\",\"bonusAmount\":100.00,\"percentPerPurchase\":10.0,\"paidAmount\":1000.00,\"salePercent\":0.0,\"paidPercent\":100.0,\"purchaseSum\":1000.00,\"customerFullName\":null,\"customerPhone\":null,\"customerCard\":null,\"sellerFullName\":null,\"storeAddress\":null,\"promotionTitle\":\"\"},{\"purchaseId\":5,\"customerId\":7,\"storeId\":1,\"sellerId\":1,\"price\":7000.00,\"purchasedAt\":\"2018-05-28T01:06:20.7515795+03:00\",\"canceledAt\":null,\"minus\":0.00,\"promotionId\":null,\"type\":0,\"purchaseType\":\"normal\",\"bonusAmount\":700.00,\"percentPerPurchase\":10.0,\"paidAmount\":7000.00,\"salePercent\":0.0,\"paidPercent\":100.0,\"purchaseSum\":7000.00,\"customerFullName\":null,\"customerPhone\":null,\"customerCard\":null,\"sellerFullName\":null,\"storeAddress\":null,\"promotionTitle\":\"\"}],\"meta\":{\"pageNumber\":1,\"offset\":0,\"size\":25,\"totalElements\":2,\"totalPages\":1,\"hasPrev\":false,\"hasNext\":false}}"}],"_postman_id":"96b8b835-b8ce-45dc-ae13-b42427751f9d"},{"name":"Get purchases before some date","id":"33553e89-4a11-4736-8d65-e8ef83ec1d6f","request":{"method":"GET","header":[],"body":{"mode":"formdata","formdata":[]},"url":"","description":"<p>The date against PurchaseAt</p>\n","auth":{"type":"bearer","bearer":{"basicConfig":[{"key":"token","value":"2COk7UQOL-jWwz2VYXWmgoUZiGo8YAxdDrcAa8Aso8qXboRgjeATOWq"}]},"isInherited":true,"source":{"_postman_id":"0bc77335-c12f-4475-a732-4b8aeb750221","id":"0bc77335-c12f-4475-a732-4b8aeb750221","name":"BonusGroups API","type":"collection"}},"urlObject":{"query":[],"variable":[]}},"response":[],"_postman_id":"33553e89-4a11-4736-8d65-e8ef83ec1d6f"},{"name":"save purchase with Promotion","id":"218c1bcf-4523-4666-9879-6f7b84881a6a","request":{"auth":{"type":"bearer","bearer":{"basicConfig":[{"key":"token","value":"{{api-key}}"}]},"isInherited":false},"method":"POST","header":[{"key":"Authorization","value":"{{api-key}}"},{"key":"Content-Type","value":"application/json"}],"body":{"mode":"raw","raw":"{\n\t\"price\": 1000,\n\t\"promotionId\": 1,\n\t\"storeId\": 1,\n\t\"sellerId\": 1\n}"},"url":"{{api-url}}/api/v1/customers/{{customerId}}/purchases","description":"<p>Set <em>promotionId</em> in body</p>\n","urlObject":{"path":["api","v1","customers","{{customerId}}","purchases"],"host":["{{api-url}}"],"query":[],"variable":[]}},"response":[{"id":"26a4d630-0ec1-42ad-bb1b-0f23e15c2f05","name":"save purchase with Promotion","originalRequest":{"method":"POST","header":[{"key":"Authorization","value":"{{api-key}}"},{"key":"Content-Type","value":"application/json"}],"body":{"mode":"raw","raw":"{\n\t\"price\": 1000,\n\t\"promotionId\": 1,\n\t\"storeId\": 1,\n\t\"sellerId\": 1\n}"},"url":"{{api-url}}/api/v1/customers/{{customerId}}/purchases"},"status":"Created","code":201,"_postman_previewlanguage":"json","header":[{"key":"Content-Type","value":"application/json; charset=utf-8","name":"Content-Type","description":"The mime type of this content"},{"key":"Date","value":"Mon, 03 Sep 2018 11:18:35 GMT","name":"Date","description":"The date and time that the message was sent"},{"key":"Location","value":"http://localhost:53374/api/customers/7/purchases/29?companyId=02f72ecf-6213-40f6-d749-08d5c166d7b9","name":"Location","description":"Used in redirection, or when a new resource has been created."},{"key":"Server","value":"Kestrel","name":"Server","description":"A name for the server"},{"key":"Transfer-Encoding","value":"chunked","name":"Transfer-Encoding","description":"The form of encoding used to safely transfer the entity to the user. Currently defined methods are: chunked, compress, deflate, gzip, identity."}],"cookie":[],"responseTime":null,"body":"{\"purchaseId\":29,\"customerId\":7,\"storeId\":1,\"sellerId\":1,\"price\":1000.0,\"purchasedAt\":\"2018-09-03T14:18:23.2663206+03:00\",\"canceledAt\":null,\"minus\":100.00,\"promotionId\":1,\"type\":2,\"purchaseType\":\"promo\",\"bonusAmount\":90.0000,\"percentPerPurchase\":10.0,\"paidAmount\":900.00,\"salePercent\":10.00,\"paidPercent\":90.00,\"purchaseSum\":900.00,\"externalPurchaseId\":null,\"customerFullName\":null,\"customerPhone\":null,\"customerCard\":null,\"sellerFullName\":\"andrey\",\"storeAddress\":\"Cairo, Nasr City, 32\",\"promotionTitle\":\"10-10\"}"}],"_postman_id":"218c1bcf-4523-4666-9879-6f7b84881a6a"},{"name":"Delete purchase","id":"f49a3c23-616d-4948-98cd-8c80cae29903","request":{"auth":{"type":"bearer","bearer":{"basicConfig":[{"key":"token","value":"{{api-key}}"}]},"isInherited":false},"method":"DELETE","header":[{"key":"Authorization","value":"{{api-key}}"}],"body":{"mode":"formdata","formdata":[]},"url":"{{api-url}}/api/v1/purchases/{{purchaseId}}","urlObject":{"path":["api","v1","purchases","{{purchaseId}}"],"host":["{{api-url}}"],"query":[],"variable":[]}},"response":[{"id":"52678f06-e4ac-4caf-bdf3-aec1af166f84","name":"purchase is not exist","originalRequest":{"method":"DELETE","header":[{"key":"Authorization","value":"{{api-key}}","disabled":false}],"body":{"mode":"formdata","formdata":[]},"url":"{{api-url}}/api/v1/purchases/57"},"status":"Bad Request","code":400,"_postman_previewlanguage":"json","header":[{"key":"Content-Type","value":"application/json; charset=utf-8","name":"Content-Type","description":"The mime type of this content"},{"key":"Date","value":"Sat, 08 Sep 2018 09:53:51 GMT","name":"Date","description":"The date and time that the message was sent"},{"key":"Request-Context","value":"appId=cid-v1:","name":"Request-Context","description":"Custom header"},{"key":"Server","value":"Kestrel","name":"Server","description":"A name for the server"},{"key":"Transfer-Encoding","value":"chunked","name":"Transfer-Encoding","description":"The form of encoding used to safely transfer the entity to the user. Currently defined methods are: chunked, compress, deflate, gzip, identity."}],"cookie":[],"responseTime":null,"body":"{\"message\":\"PurchaseNotFound\"}"},{"id":"87ef16e3-24f6-48fa-b1f9-2f6b1270ec56","name":"purchase with writeoff","originalRequest":{"method":"DELETE","header":[{"key":"Authorization","value":"{{api-key}}"}],"body":{"mode":"formdata","formdata":[]},"url":"{{api-url}}/api/v1/purchases/{{purchaseId}}"},"status":"Bad Request","code":400,"_postman_previewlanguage":"json","header":[{"key":"Content-Type","value":"application/json; charset=utf-8","name":"Content-Type","description":"The mime type of this content"},{"key":"Date","value":"Sat, 08 Sep 2018 09:50:43 GMT","name":"Date","description":"The date and time that the message was sent"},{"key":"Server","value":"Kestrel","name":"Server","description":"A name for the server"},{"key":"Transfer-Encoding","value":"chunked","name":"Transfer-Encoding","description":"The form of encoding used to safely transfer the entity to the user. Currently defined methods are: chunked, compress, deflate, gzip, identity."}],"cookie":[],"responseTime":null,"body":"{\"message\":\"PurchaseAlreadyHasWriteOffs\"}"},{"id":"99cf9efb-3658-40ec-bee2-8b92906914d0","name":"success deletion","originalRequest":{"method":"DELETE","header":[{"key":"Authorization","value":"{{api-key}}","disabled":false}],"body":{"mode":"formdata","formdata":[]},"url":"{{api-url}}/api/v1/purchases/24"},"status":"No Content","code":204,"_postman_previewlanguage":"plain","header":[{"key":"Date","value":"Sat, 08 Sep 2018 09:57:43 GMT","name":"Date","description":"The date and time that the message was sent"},{"key":"Request-Context","value":"appId=cid-v1:","name":"Request-Context","description":"Custom header"},{"key":"Server","value":"Kestrel","name":"Server","description":"A name for the server"}],"cookie":[],"responseTime":null,"body":""}],"_postman_id":"f49a3c23-616d-4948-98cd-8c80cae29903"}],"id":"c18e43ae-8e93-4ecc-934f-cf1320b18ad3","_postman_id":"c18e43ae-8e93-4ecc-934f-cf1320b18ad3","description":"","auth":{"type":"bearer","bearer":{"basicConfig":[{"key":"token","value":"2COk7UQOL-jWwz2VYXWmgoUZiGo8YAxdDrcAa8Aso8qXboRgjeATOWq"}]},"isInherited":true,"source":{"_postman_id":"0bc77335-c12f-4475-a732-4b8aeb750221","id":"0bc77335-c12f-4475-a732-4b8aeb750221","name":"BonusGroups API","type":"collection"}}},{"name":"Reports","item":[{"name":"Get main report","id":"09abadf4-acf2-4a96-bc51-044e4183bed7","request":{"auth":{"type":"bearer","bearer":{"basicConfig":[{"key":"token","value":"{{api-key}}"}]},"isInherited":false},"method":"GET","header":[{"key":"Authorization","value":"{{api-key}}"}],"body":{"mode":"formdata","formdata":[]},"url":"{{api-url}}/api/v1/reports/main?from=2018-08-01&till=2018-08-31&sellerId=1&storeId=1","description":"<p>NOTE! Date range can not be greater than 2 month.</p>\n","urlObject":{"path":["api","v1","reports","main"],"host":["{{api-url}}"],"query":[{"description":{"content":"<p>(required) Date as \"YYYY-MM-DD\" </p>\n","type":"text/plain"},"key":"from","value":"2018-08-01"},{"description":{"content":"<p>(required) Date as \"YYYY-MM-DD\"</p>\n","type":"text/plain"},"key":"till","value":"2018-08-31"},{"description":{"content":"<p>Seller Id</p>\n","type":"text/plain"},"key":"sellerId","value":"1"},{"description":{"content":"<p>Store Id</p>\n","type":"text/plain"},"key":"storeId","value":"1"}],"variable":[]}},"response":[{"id":"0d36fd5a-ded5-4460-ae74-f5bfb3795557","name":"more than 2 months","originalRequest":{"method":"GET","header":[{"key":"Authorization","value":"{{api-key}}","disabled":false}],"body":{"mode":"formdata","formdata":[]},"url":{"raw":"{{api-url}}/api/v1/reports/main?from=2018-05-01&till=2018-08-31","host":["{{api-url}}"],"path":["api","v1","reports","main"],"query":[{"key":"from","value":"2018-05-01","description":"(required) Date as \"YYYY-MM-DD\" "},{"key":"till","value":"2018-08-31","description":"(required) Date as \"YYYY-MM-DD\""}]}},"status":"Bad Request","code":400,"_postman_previewlanguage":"json","header":[{"key":"Content-Type","value":"application/json; charset=utf-8","name":"Content-Type","description":"The mime type of this content"},{"key":"Date","value":"Sat, 08 Sep 2018 12:09:20 GMT","name":"Date","description":"The date and time that the message was sent"},{"key":"Request-Context","value":"appId=cid-v1:","name":"Request-Context","description":"Custom header"},{"key":"Server","value":"Kestrel","name":"Server","description":"A name for the server"},{"key":"Transfer-Encoding","value":"chunked","name":"Transfer-Encoding","description":"The form of encoding used to safely transfer the entity to the user. Currently defined methods are: chunked, compress, deflate, gzip, identity."}],"cookie":[],"responseTime":null,"body":"{\"message\":\"TooLongDateRange\"}"},{"id":"5eb26d21-a36c-4a32-b0e1-885dd13a7bc1","name":"bad request","originalRequest":{"method":"GET","header":[{"key":"Authorization","value":"{{api-key}}","disabled":false}],"body":{"mode":"formdata","formdata":[]},"url":{"raw":"{{api-url}}/api/v1/reports/main?from=2018-08-01&sellerId=1&storeId=1","host":["{{api-url}}"],"path":["api","v1","reports","main"],"query":[{"key":"from","value":"2018-08-01","description":"(required) Date as \"YYYY-MM-DD\" "},{"key":"till","value":"2018-08-31","description":"(required) Date as \"YYYY-MM-DD\"","disabled":true},{"key":"sellerId","value":"1","description":"Seller Id"},{"key":"storeId","value":"1","description":"Store Id"}]}},"status":"Bad Request","code":400,"_postman_previewlanguage":"json","header":[{"key":"Content-Type","value":"application/json; charset=utf-8","name":"Content-Type","description":"The mime type of this content"},{"key":"Date","value":"Sat, 08 Sep 2018 12:07:57 GMT","name":"Date","description":"The date and time that the message was sent"},{"key":"Request-Context","value":"appId=cid-v1:","name":"Request-Context","description":"Custom header"},{"key":"Server","value":"Kestrel","name":"Server","description":"A name for the server"},{"key":"Transfer-Encoding","value":"chunked","name":"Transfer-Encoding","description":"The form of encoding used to safely transfer the entity to the user. Currently defined methods are: chunked, compress, deflate, gzip, identity."}],"cookie":[],"responseTime":null,"body":"{\"message\":\"InvalidModel\"}"},{"id":"d9730205-478f-42f0-9a88-39aea22472ee","name":"monthly report","originalRequest":{"method":"GET","header":[{"key":"Authorization","value":"{{api-key}}","disabled":false}],"body":{"mode":"formdata","formdata":[]},"url":{"raw":"{{api-url}}/api/v1/reports/main?from=2018-08-01&till=2018-08-31","host":["{{api-url}}"],"path":["api","v1","reports","main"],"query":[{"key":"from","value":"2018-08-01","description":"(required) Date as \"YYYY-MM-DD\" "},{"key":"till","value":"2018-08-31","description":"(required) Date as \"YYYY-MM-DD\""}]}},"status":"OK","code":200,"_postman_previewlanguage":"json","header":[{"key":"Content-Type","value":"application/json; charset=utf-8","name":"Content-Type","description":"The mime type of this content"},{"key":"Date","value":"Sat, 08 Sep 2018 12:08:47 GMT","name":"Date","description":"The date and time that the message was sent"},{"key":"Request-Context","value":"appId=cid-v1:","name":"Request-Context","description":"Custom header"},{"key":"Server","value":"Kestrel","name":"Server","description":"A name for the server"},{"key":"Transfer-Encoding","value":"chunked","name":"Transfer-Encoding","description":"The form of encoding used to safely transfer the entity to the user. Currently defined methods are: chunked, compress, deflate, gzip, identity."}],"cookie":[],"responseTime":null,"body":"{\"startAt\":\"2018-08-30T15:00:57.5822102+03:00\",\"endAt\":\"2018-08-30T15:00:57.5822102+03:00\",\"totalSum\":1000.00,\"avg\":1000.00,\"doublePurchaseCount\":0,\"doubleTotalSum\":0.0,\"doubleAvgSum\":0.0,\"newBonuses\":100.00,\"writeOffBonuses\":0,\"motivationFactor\":0.0,\"motivationSum\":1000.00,\"customerCount\":1,\"purchaseCount\":1}"}],"_postman_id":"09abadf4-acf2-4a96-bc51-044e4183bed7"}],"id":"07ea0cdf-9465-426b-a04f-e8931c5f6786","_postman_id":"07ea0cdf-9465-426b-a04f-e8931c5f6786","description":"","auth":{"type":"bearer","bearer":{"basicConfig":[{"key":"token","value":"2COk7UQOL-jWwz2VYXWmgoUZiGo8YAxdDrcAa8Aso8qXboRgjeATOWq"}]},"isInherited":true,"source":{"_postman_id":"0bc77335-c12f-4475-a732-4b8aeb750221","id":"0bc77335-c12f-4475-a732-4b8aeb750221","name":"BonusGroups API","type":"collection"}}},{"name":"Sellers","item":[{"name":"All sellers","id":"8c5c271e-bd95-4906-af5e-19d913763fae","request":{"auth":{"type":"bearer","bearer":{"basicConfig":[{"key":"token","value":"{{api-key}}"}]},"isInherited":false},"method":"GET","header":[{"key":"Authorization","value":"{{api-key}}"}],"body":{"mode":"formdata","formdata":[]},"url":"{{api-url}}/api/v1/sellers","urlObject":{"path":["api","v1","sellers"],"host":["{{api-url}}"],"query":[],"variable":[]}},"response":[{"id":"ec7a9b4f-55d9-4ec5-8a35-a5c8070a0844","name":"All sellers","originalRequest":{"method":"GET","header":[{"key":"Authorization","value":"{{api-key}}","warning":"This is a duplicate header and will be overridden by the Authorization header generated by Postman.","disabled":false}],"body":{"mode":"formdata","formdata":[]},"url":"{{api-url}}/api/v1/sellers"},"status":"OK","code":200,"_postman_previewlanguage":"json","header":[{"key":"Content-Type","value":"application/json; charset=utf-8","name":"Content-Type","description":"The mime type of this content"},{"key":"Date","value":"Thu, 31 May 2018 13:20:49 GMT","name":"Date","description":"The date and time that the message was sent"},{"key":"Server","value":"Kestrel","name":"Server","description":"A name for the server"},{"key":"Transfer-Encoding","value":"chunked","name":"Transfer-Encoding","description":"The form of encoding used to safely transfer the entity to the user. Currently defined methods are: chunked, compress, deflate, gzip, identity."}],"cookie":[],"responseTime":null,"body":"{\n    \"items\": [\n        {\n            \"sellerId\": 1,\n            \"firstName\": \"andrey\",\n            \"username\": null,\n            \"email\": null,\n            \"createdAt\": \"2018-05-26T20:38:18.6813305+03:00\",\n            \"deactivatedAt\": null,\n            \"isStoreOwner\": null\n        },\n        {\n            \"sellerId\": 2,\n            \"firstName\": \"Вася\",\n            \"username\": null,\n            \"email\": null,\n            \"createdAt\": \"2018-05-28T19:24:10.623654+03:00\",\n            \"deactivatedAt\": null,\n            \"isStoreOwner\": null\n        }\n    ],\n    \"meta\": {\n        \"pageNumber\": 1,\n        \"offset\": 0,\n        \"size\": 2,\n        \"totalElements\": 2,\n        \"totalPages\": 1,\n        \"hasPrev\": false,\n        \"hasNext\": false\n    }\n}"}],"_postman_id":"8c5c271e-bd95-4906-af5e-19d913763fae"},{"name":"Seller by ID","id":"c7eb3633-12da-4eb3-959f-f5e76cb8013f","request":{"auth":{"type":"bearer","bearer":{"basicConfig":[{"key":"token","value":"{{api-key}}"}]},"isInherited":false},"method":"GET","header":[{"key":"Authorization","value":"{{api-key}}"}],"body":{"mode":"formdata","formdata":[]},"url":"{{api-url}}/api/v1/sellers/2","urlObject":{"path":["api","v1","sellers","2"],"host":["{{api-url}}"],"query":[],"variable":[]}},"response":[{"id":"6e7f1636-f23d-4026-98c8-47112e2c28e4","name":"Seller by ID","originalRequest":{"method":"GET","header":[{"key":"Authorization","value":"{{api-key}}","disabled":false}],"body":{"mode":"formdata","formdata":[]},"url":"{{api-url}}/api/v1/sellers/2"},"status":"OK","code":200,"_postman_previewlanguage":"json","header":[{"key":"Content-Type","value":"application/json; charset=utf-8","name":"Content-Type","description":"The mime type of this content"},{"key":"Date","value":"Thu, 31 May 2018 13:22:56 GMT","name":"Date","description":"The date and time that the message was sent"},{"key":"Server","value":"Kestrel","name":"Server","description":"A name for the server"},{"key":"Transfer-Encoding","value":"chunked","name":"Transfer-Encoding","description":"The form of encoding used to safely transfer the entity to the user. Currently defined methods are: chunked, compress, deflate, gzip, identity."}],"cookie":[],"responseTime":null,"body":"{\n    \"sellerId\": 2,\n    \"firstName\": \"Вася\",\n    \"username\": null,\n    \"email\": null,\n    \"createdAt\": \"2018-05-28T19:24:10.623654+03:00\",\n    \"deactivatedAt\": null,\n    \"isStoreOwner\": null\n}"}],"_postman_id":"c7eb3633-12da-4eb3-959f-f5e76cb8013f"},{"name":"Sellers in their stores","id":"d197453d-37de-4545-bdcb-6db1775c1bcd","request":{"auth":{"type":"bearer","bearer":{"basicConfig":[{"key":"token","value":"{{api-key}}"}]},"isInherited":false},"method":"GET","header":[{"key":"Authorization","value":"{{api-key}}"}],"body":{"mode":"formdata","formdata":[]},"url":"{{api-url}}/api/v1/sellers/in/stores","urlObject":{"path":["api","v1","sellers","in","stores"],"host":["{{api-url}}"],"query":[],"variable":[]}},"response":[{"id":"24118446-d2b8-4194-a79b-c7a257de7027","name":"Sellers in their stores","originalRequest":{"method":"GET","header":[{"key":"Authorization","value":"{{api-key}}","disabled":false}],"body":{"mode":"formdata","formdata":[]},"url":"{{api-url}}/api/v1/sellers/in/stores"},"status":"OK","code":200,"_postman_previewlanguage":"json","header":[{"key":"Content-Type","value":"application/json; charset=utf-8","name":"Content-Type","description":"The mime type of this content"},{"key":"Date","value":"Thu, 31 May 2018 13:26:50 GMT","name":"Date","description":"The date and time that the message was sent"},{"key":"Request-Context","value":"appId=cid-v1:","name":"Request-Context","description":"Custom header"},{"key":"Server","value":"Kestrel","name":"Server","description":"A name for the server"},{"key":"Transfer-Encoding","value":"chunked","name":"Transfer-Encoding","description":"The form of encoding used to safely transfer the entity to the user. Currently defined methods are: chunked, compress, deflate, gzip, identity."}],"cookie":[],"responseTime":null,"body":"[{\"sellerId\":1,\"storeId\":1,\"seller\":null,\"store\":null},{\"sellerId\":2,\"storeId\":1,\"seller\":null,\"store\":null}]"},{"id":"2412efad-d55c-40e0-9132-34a50495c92b","name":"Sellers in their stores with store and seller objects","originalRequest":{"method":"GET","header":[{"key":"Authorization","value":"{{api-key}}","disabled":false}],"body":{"mode":"formdata","formdata":[]},"url":{"raw":"{{api-url}}/api/v1/sellers/in/stores?include=stores,sellers","host":["{{api-url}}"],"path":["api","v1","sellers","in","stores"],"query":[{"key":"include","value":"stores,sellers"}]}},"status":"OK","code":200,"_postman_previewlanguage":"json","header":[{"key":"Content-Type","value":"application/json; charset=utf-8","name":"Content-Type","description":"The mime type of this content"},{"key":"Date","value":"Thu, 31 May 2018 13:40:26 GMT","name":"Date","description":"The date and time that the message was sent"},{"key":"Request-Context","value":"appId=cid-v1:","name":"Request-Context","description":"Custom header"},{"key":"Server","value":"Kestrel","name":"Server","description":"A name for the server"},{"key":"Transfer-Encoding","value":"chunked","name":"Transfer-Encoding","description":"The form of encoding used to safely transfer the entity to the user. Currently defined methods are: chunked, compress, deflate, gzip, identity."}],"cookie":[],"responseTime":null,"body":"[{\"sellerId\":1,\"storeId\":1,\"store\":{\"storeId\":1,\"address\":\"Cairo\"},\"seller\":{\"sellerId\":1,\"firstName\":\"andrey\"}},{\"sellerId\":2,\"storeId\":1,\"store\":{\"storeId\":1,\"address\":\"Cairo\"},\"seller\":{\"sellerId\":2,\"firstName\":\"Вася\"}}]"}],"_postman_id":"d197453d-37de-4545-bdcb-6db1775c1bcd"},{"name":"Validate seller","id":"3c5c6a4c-bec4-455d-84ef-17032ba98ee8","request":{"auth":{"type":"bearer","bearer":{"basicConfig":[{"key":"token","value":"{{api-key}}"}]},"isInherited":false},"method":"POST","header":[{"key":"Content-Type","value":"application/json"}],"body":{"mode":"raw","raw":"{\n\t\"username\": \"first.andrey\",\n\t\"password\": \"9p@Q\"\n}"},"url":"{{api-url}}/api/v1/validate/seller","description":"<p>Validate seller and get his stores in response.</p>\n","urlObject":{"path":["api","v1","validate","seller"],"host":["{{api-url}}"],"query":[],"variable":[]}},"response":[{"id":"0026c294-497f-44d3-8e16-d394c5363e71","name":"seller is valid","originalRequest":{"method":"POST","header":[{"key":"Content-Type","value":"application/json","disabled":false}],"body":{"mode":"raw","raw":"{\n\t\"username\": \"first.andrey\",\n\t\"password\": \"9p@Q\"\n}"},"url":"{{api-url}}/api/v1/validate/seller"},"status":"OK","code":200,"_postman_previewlanguage":"json","header":[{"key":"Content-Type","value":"application/json; charset=utf-8","name":"Content-Type","description":"The mime type of this content"},{"key":"Date","value":"Sat, 08 Sep 2018 12:53:06 GMT","name":"Date","description":"The date and time that the message was sent"},{"key":"Request-Context","value":"appId=cid-v1:","name":"Request-Context","description":"Custom header"},{"key":"Server","value":"Kestrel","name":"Server","description":"A name for the server"},{"key":"Transfer-Encoding","value":"chunked","name":"Transfer-Encoding","description":"The form of encoding used to safely transfer the entity to the user. Currently defined methods are: chunked, compress, deflate, gzip, identity."}],"cookie":[],"responseTime":null,"body":"{\"sellerId\":1,\"stores\":[{\"storeId\":1,\"address\":\"Cairo, Nasr City, 32\"}]}"},{"id":"6a747f80-5f8a-4a5d-b228-1f152363dfd0","name":"seller is invalid","originalRequest":{"method":"POST","header":[{"key":"Content-Type","value":"application/json","disabled":false}],"body":{"mode":"raw","raw":"{\n\t\"username\": \"first.andrey\",\n\t\"password\": \"9p@Q1\"\n}"},"url":"{{api-url}}/api/v1/validate/seller"},"status":"Bad Request","code":400,"_postman_previewlanguage":"plain","header":[{"key":"Content-Length","value":"0","name":"Content-Length","description":"The length of the response body in octets (8-bit bytes)"},{"key":"Date","value":"Sat, 08 Sep 2018 12:55:43 GMT","name":"Date","description":"The date and time that the message was sent"},{"key":"Request-Context","value":"appId=cid-v1:","name":"Request-Context","description":"Custom header"},{"key":"Server","value":"Kestrel","name":"Server","description":"A name for the server"}],"cookie":[],"responseTime":null,"body":""}],"_postman_id":"3c5c6a4c-bec4-455d-84ef-17032ba98ee8"}],"id":"8aee2a1f-930d-44d9-9ca5-a2d1adb3660e","_postman_id":"8aee2a1f-930d-44d9-9ca5-a2d1adb3660e","description":"","auth":{"type":"bearer","bearer":{"basicConfig":[{"key":"token","value":"2COk7UQOL-jWwz2VYXWmgoUZiGo8YAxdDrcAa8Aso8qXboRgjeATOWq"}]},"isInherited":true,"source":{"_postman_id":"0bc77335-c12f-4475-a732-4b8aeb750221","id":"0bc77335-c12f-4475-a732-4b8aeb750221","name":"BonusGroups API","type":"collection"}}},{"name":"Settings","item":[{"name":"Get general settings","id":"122aa55c-45e9-4991-a8b8-fa53dd970b64","request":{"auth":{"type":"bearer","bearer":{"basicConfig":[{"key":"token","value":"{{api-key}}"}]},"isInherited":false},"method":"GET","header":[{"key":"Authorization","value":"{{api-key}}"}],"body":{"mode":"formdata","formdata":[]},"url":"{{api-url}}/api/v1/settings/general","urlObject":{"path":["api","v1","settings","general"],"host":["{{api-url}}"],"query":[],"variable":[]}},"response":[{"id":"dca5f2b6-24e2-48f7-8ccb-123a81670ce6","name":"general settings","originalRequest":{"method":"GET","header":[{"key":"Authorization","value":"{{api-key}}","warning":"This is a duplicate header and will be overridden by the Authorization header generated by Postman.","disabled":false}],"body":{"mode":"formdata","formdata":[]},"url":"{{api-url}}/api/v1/settings/general"},"status":"OK","code":200,"_postman_previewlanguage":"json","header":[{"key":"Content-Type","value":"application/json; charset=utf-8","name":"Content-Type","description":"The mime type of this content"},{"key":"Date","value":"Sat, 08 Sep 2018 08:33:00 GMT","name":"Date","description":"The date and time that the message was sent"},{"key":"Server","value":"Kestrel","name":"Server","description":"A name for the server"},{"key":"Transfer-Encoding","value":"chunked","name":"Transfer-Encoding","description":"The form of encoding used to safely transfer the entity to the user. Currently defined methods are: chunked, compress, deflate, gzip, identity."}],"cookie":[],"responseTime":null,"body":"{\"smsSenderName\":\"ProgBonus\",\"shouldSendSms\":true,\"timeZone\":3}"}],"_postman_id":"122aa55c-45e9-4991-a8b8-fa53dd970b64"},{"name":"Get store' settings","id":"14ad3f7d-b474-431e-802d-5417c3464144","request":{"auth":{"type":"bearer","bearer":{"basicConfig":[{"key":"token","value":"{{api-key}}"}]},"isInherited":false},"method":"GET","header":[{"key":"Authorization","value":"{{api-key}}"}],"body":{"mode":"formdata","formdata":[]},"url":"{{api-url}}/api/v1/settings/offline-stores","description":"<p>Get store' settings</p>\n","urlObject":{"path":["api","v1","settings","offline-stores"],"host":["{{api-url}}"],"query":[],"variable":[]}},"response":[{"id":"bdd1dd48-22a5-424f-8bcb-4be064b3f060","name":"store' settings","originalRequest":{"method":"GET","header":[{"key":"Authorization","value":"{{api-key}}","warning":"This is a duplicate header and will be overridden by the Authorization header generated by Postman.","disabled":false}],"body":{"mode":"formdata","formdata":[]},"url":"{{api-url}}/api/v1/settings/offline-stores"},"status":"OK","code":200,"_postman_previewlanguage":"json","header":[{"key":"Content-Type","value":"application/json; charset=utf-8","name":"Content-Type","description":"The mime type of this content"},{"key":"Date","value":"Sat, 08 Sep 2018 08:40:21 GMT","name":"Date","description":"The date and time that the message was sent"},{"key":"Server","value":"Kestrel","name":"Server","description":"A name for the server"},{"key":"Transfer-Encoding","value":"chunked","name":"Transfer-Encoding","description":"The form of encoding used to safely transfer the entity to the user. Currently defined methods are: chunked, compress, deflate, gzip, identity."}],"cookie":[],"responseTime":null,"body":"{\"percentPerPurchase\":null,\"maxWriteOffPercent\":50.0}"}],"_postman_id":"14ad3f7d-b474-431e-802d-5417c3464144"},{"name":"Get store settings 2","id":"da7936a5-0c87-4d48-8440-d77217ca9e09","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"auth":{"type":"noauth","isInherited":false},"method":"GET","header":[{"key":"Authorization","value":"{{api-key}}","type":"text"}],"url":"{{api-url}}/api/v1/stores/{{internetStoreId}}/settings","urlObject":{"path":["api","v1","stores","{{internetStoreId}}","settings"],"host":["{{api-url}}"],"query":[],"variable":[]}},"response":[],"_postman_id":"da7936a5-0c87-4d48-8440-d77217ca9e09"}],"id":"27d629b1-210d-485d-8aeb-2f439c91bc46","_postman_id":"27d629b1-210d-485d-8aeb-2f439c91bc46","description":"","auth":{"type":"bearer","bearer":{"basicConfig":[{"key":"token","value":"2COk7UQOL-jWwz2VYXWmgoUZiGo8YAxdDrcAa8Aso8qXboRgjeATOWq"}]},"isInherited":true,"source":{"_postman_id":"0bc77335-c12f-4475-a732-4b8aeb750221","id":"0bc77335-c12f-4475-a732-4b8aeb750221","name":"BonusGroups API","type":"collection"}}},{"name":"Stores","item":[{"name":"All stores","id":"bd6a663f-9406-41ae-89df-0e35e785bb45","request":{"auth":{"type":"bearer","bearer":{"basicConfig":[{"key":"token","value":"{{api-key}}"}]},"isInherited":false},"method":"GET","header":[],"body":{"mode":"formdata","formdata":[]},"url":"{{api-url}}/api/v1/stores","urlObject":{"path":["api","v1","stores"],"host":["{{api-url}}"],"query":[],"variable":[]}},"response":[{"id":"bbd9056a-44d1-47e4-a4e6-9bbb539a0486","name":"All stores","originalRequest":{"method":"GET","header":[{"key":"Authorization","value":"{{api-key}}","warning":"This is a duplicate header and will be overridden by the Authorization header generated by Postman."}],"body":{"mode":"formdata","formdata":[]},"url":"{{api-url}}/api/v1/stores"},"status":"OK","code":200,"_postman_previewlanguage":"json","header":[{"key":"Content-Type","value":"application/json; charset=utf-8","name":"Content-Type","description":"The mime type of this content"},{"key":"Date","value":"Thu, 31 May 2018 13:25:23 GMT","name":"Date","description":"The date and time that the message was sent"},{"key":"Request-Context","value":"appId=cid-v1:","name":"Request-Context","description":"Custom header"},{"key":"Server","value":"Kestrel","name":"Server","description":"A name for the server"},{"key":"Transfer-Encoding","value":"chunked","name":"Transfer-Encoding","description":"The form of encoding used to safely transfer the entity to the user. Currently defined methods are: chunked, compress, deflate, gzip, identity."}],"cookie":[],"responseTime":null,"body":"{\"items\":[{\"storeId\":1,\"address\":\"Cairo\",\"storeType\":\"offline\",\"createdAt\":\"2018-05-26T17:38:52.5428306+00:00\"}],\"meta\":{\"pageNumber\":1,\"offset\":0,\"size\":100,\"totalElements\":1,\"totalPages\":1,\"hasPrev\":false,\"hasNext\":false}}"}],"_postman_id":"bd6a663f-9406-41ae-89df-0e35e785bb45"},{"name":"Store by ID","id":"ffd35c9b-83ad-40b7-be1f-5abfd57f14fa","request":{"auth":{"type":"bearer","bearer":{"basicConfig":[{"key":"token","value":"{{api-key}}"}]},"isInherited":false},"method":"GET","header":[],"body":{"mode":"formdata","formdata":[]},"url":"{{api-url}}/api/v1/stores/1","urlObject":{"path":["api","v1","stores","1"],"host":["{{api-url}}"],"query":[],"variable":[]}},"response":[{"id":"f7b98d41-1f41-4f2e-ae37-28c8a1bd10cf","name":"Store by ID","originalRequest":{"method":"GET","header":[{"key":"Authorization","value":"{{api-key}}","warning":"This is a duplicate header and will be overridden by the Authorization header generated by Postman."}],"body":{"mode":"formdata","formdata":[]},"url":"{{api-url}}/api/v1/stores/1"},"status":"OK","code":200,"_postman_previewlanguage":"json","header":[{"key":"Content-Type","value":"application/json; charset=utf-8","name":"Content-Type","description":"The mime type of this content"},{"key":"Date","value":"Thu, 31 May 2018 13:25:55 GMT","name":"Date","description":"The date and time that the message was sent"},{"key":"Request-Context","value":"appId=cid-v1:","name":"Request-Context","description":"Custom header"},{"key":"Server","value":"Kestrel","name":"Server","description":"A name for the server"},{"key":"Transfer-Encoding","value":"chunked","name":"Transfer-Encoding","description":"The form of encoding used to safely transfer the entity to the user. Currently defined methods are: chunked, compress, deflate, gzip, identity."}],"cookie":[],"responseTime":null,"body":"{\"storeId\":1,\"address\":\"Cairo\",\"storeType\":\"offline\",\"createdAt\":\"2018-05-26T17:38:52.5428306+00:00\"}"}],"_postman_id":"ffd35c9b-83ad-40b7-be1f-5abfd57f14fa"}],"id":"914eba53-2f4f-493c-820b-1c859ff5a494","_postman_id":"914eba53-2f4f-493c-820b-1c859ff5a494","description":"","auth":{"type":"bearer","bearer":{"basicConfig":[{"key":"token","value":"2COk7UQOL-jWwz2VYXWmgoUZiGo8YAxdDrcAa8Aso8qXboRgjeATOWq"}]},"isInherited":true,"source":{"_postman_id":"0bc77335-c12f-4475-a732-4b8aeb750221","id":"0bc77335-c12f-4475-a732-4b8aeb750221","name":"BonusGroups API","type":"collection"}}},{"name":"Instagram","item":[{"name":"Followers","item":[{"name":"Get followers","id":"be1c810a-12f7-408b-8c5d-7f827aaf9f2a","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"GET","header":[],"url":"","description":"<p>Get a page of followers by page and count parameters</p>\n","auth":{"type":"bearer","bearer":{"basicConfig":[{"key":"token","value":"2COk7UQOL-jWwz2VYXWmgoUZiGo8YAxdDrcAa8Aso8qXboRgjeATOWq"}]},"isInherited":true,"source":{"_postman_id":"0bc77335-c12f-4475-a732-4b8aeb750221","id":"0bc77335-c12f-4475-a732-4b8aeb750221","name":"BonusGroups API","type":"collection"}},"urlObject":{"query":[],"variable":[]}},"response":[],"_postman_id":"be1c810a-12f7-408b-8c5d-7f827aaf9f2a"},{"name":"Check promocode","id":"831c7e8f-f1dd-42f2-93d6-81401cc5ebb1","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"GET","header":[],"url":"api/v1/followers/by/promocode/XYZ","auth":{"type":"bearer","bearer":{"basicConfig":[{"key":"token","value":"2COk7UQOL-jWwz2VYXWmgoUZiGo8YAxdDrcAa8Aso8qXboRgjeATOWq"}]},"isInherited":true,"source":{"_postman_id":"0bc77335-c12f-4475-a732-4b8aeb750221","id":"0bc77335-c12f-4475-a732-4b8aeb750221","name":"BonusGroups API","type":"collection"}},"urlObject":{"path":["v1","followers","by","promocode","XYZ"],"host":["api"],"query":[],"variable":[]}},"response":[],"_postman_id":"831c7e8f-f1dd-42f2-93d6-81401cc5ebb1"},{"name":"Get follower","id":"2e637e42-c6bb-40be-b51d-e4b442c2b66f","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"GET","header":[],"url":"api/v1/followers?username=ap1ter","description":"<p>by username</p>\n","auth":{"type":"bearer","bearer":{"basicConfig":[{"key":"token","value":"2COk7UQOL-jWwz2VYXWmgoUZiGo8YAxdDrcAa8Aso8qXboRgjeATOWq"}]},"isInherited":true,"source":{"_postman_id":"0bc77335-c12f-4475-a732-4b8aeb750221","id":"0bc77335-c12f-4475-a732-4b8aeb750221","name":"BonusGroups API","type":"collection"}},"urlObject":{"path":["v1","followers"],"host":["api"],"query":[{"key":"username","value":"ap1ter"}],"variable":[]}},"response":[],"_postman_id":"2e637e42-c6bb-40be-b51d-e4b442c2b66f"},{"name":"Save new customer","id":"319c232a-5bb7-4ccf-b6d9-699f2b6419a4","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"PUT","header":[{"key":"Content-Type","name":"Content-Type","value":"application/json","type":"text"}],"body":{"mode":"raw","raw":"{\n\t\"firstName\": \"Andrey\",\n\t\"phoneNumber\": \"66-88-66\"\n}"},"url":"api/v1/followers/{pk}","description":"<p>Save followers as new customer</p>\n","auth":{"type":"bearer","bearer":{"basicConfig":[{"key":"token","value":"2COk7UQOL-jWwz2VYXWmgoUZiGo8YAxdDrcAa8Aso8qXboRgjeATOWq"}]},"isInherited":true,"source":{"_postman_id":"0bc77335-c12f-4475-a732-4b8aeb750221","id":"0bc77335-c12f-4475-a732-4b8aeb750221","name":"BonusGroups API","type":"collection"}},"urlObject":{"path":["v1","followers","{pk}"],"host":["api"],"query":[],"variable":[]}},"response":[],"_postman_id":"319c232a-5bb7-4ccf-b6d9-699f2b6419a4"},{"name":"Save follower as exist customer","id":"4f0d6b74-e497-4eb6-b1bd-0d6c9d80c949","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"PUT","header":[],"url":"api/v1/followers/{pk}/as/customer/{customerId}","description":"<p>If a customer already exists you should connect follower with him.</p>\n","auth":{"type":"bearer","bearer":{"basicConfig":[{"key":"token","value":"2COk7UQOL-jWwz2VYXWmgoUZiGo8YAxdDrcAa8Aso8qXboRgjeATOWq"}]},"isInherited":true,"source":{"_postman_id":"0bc77335-c12f-4475-a732-4b8aeb750221","id":"0bc77335-c12f-4475-a732-4b8aeb750221","name":"BonusGroups API","type":"collection"}},"urlObject":{"path":["v1","followers","{pk}","as","customer","{customerId}"],"host":["api"],"query":[],"variable":[]}},"response":[],"_postman_id":"4f0d6b74-e497-4eb6-b1bd-0d6c9d80c949"}],"id":"10253fbd-2040-49db-8751-a3f4295e24bb","_postman_id":"10253fbd-2040-49db-8751-a3f4295e24bb","description":"","auth":{"type":"bearer","bearer":{"basicConfig":[{"key":"token","value":"2COk7UQOL-jWwz2VYXWmgoUZiGo8YAxdDrcAa8Aso8qXboRgjeATOWq"}]},"isInherited":true,"source":{"_postman_id":"0bc77335-c12f-4475-a732-4b8aeb750221","id":"0bc77335-c12f-4475-a732-4b8aeb750221","name":"BonusGroups API","type":"collection"}}}],"id":"acdfb04e-1bae-4c17-9d76-cb48ff1dbb7a","_postman_id":"acdfb04e-1bae-4c17-9d76-cb48ff1dbb7a","description":"","auth":{"type":"bearer","bearer":{"basicConfig":[{"key":"token","value":"2COk7UQOL-jWwz2VYXWmgoUZiGo8YAxdDrcAa8Aso8qXboRgjeATOWq"}]},"isInherited":true,"source":{"_postman_id":"0bc77335-c12f-4475-a732-4b8aeb750221","id":"0bc77335-c12f-4475-a732-4b8aeb750221","name":"BonusGroups API","type":"collection"}}}],"auth":{"type":"bearer","bearer":{"basicConfig":[{"key":"token","value":"2COk7UQOL-jWwz2VYXWmgoUZiGo8YAxdDrcAa8Aso8qXboRgjeATOWq"}]}},"event":[{"listen":"prerequest","script":{"id":"294e25a2-8d00-415f-8ac9-edbfd781b354","type":"text/javascript","exec":[""]}},{"listen":"test","script":{"id":"ea8eb6bd-ce76-40e0-a72b-bcff33a401a0","type":"text/javascript","exec":[""]}}],"variable":[{"key":"api-endpoint","value":"http://localhost:53374"},{"key":"company-api-key","value":"2COk7UQOL-jWwz2VYXWmgoUZiGo8YAxdDrcAa8Aso8qXboRgjeATOWq"},{"key":"storeId","value":"1"},{"key":"sellerId","value":"1"}]}