{ "openapi": "3.0.0", "info": { "contact": {}, "description": "baseURL: https://affico.ascendingbull.com:4448/", "title": "Affico AscendingBull API", "version": "1.0.0", "x-jentic-source-url": "https://api.swaggerhub.com/apis/luis.lopez3/AfficoAscendingBull/1.0.0/swagger.json" }, "servers": [ { "url": "https://affico.ascendingbull.com:4448/" } ], "paths": { "/auth": { "post": { "responses": { "200": { "content": { "*/*": { "schema": { "properties": { "data": { "properties": { "token": { "type": "string" } }, "type": "object" }, "error": { "default": "", "type": "string" }, "result": { "default": 1, "type": "integer" } }, "type": "object" } } }, "description": "Successfully created an auth token" } }, "tags": [ "auth" ], "description": "Endpoint to get authoritation token", "operationId": "post-auth", "requestBody": { "content": { "application/json": { "schema": { "properties": { "PartnerId": { "description": "Id provided by us", "type": "integer" }, "SecretKey": { "description": "Token provided by us", "type": "string" }, "Sign": { "description": "SHA256(PartnerId + Time + Secret_Key)", "type": "string" }, "Time": { "description": "Unix timeStamp", "type": "string" } }, "required": [ "PartnerId", "SecretKey", "Time", "Sign" ], "type": "object" } } }, "description": "affiliate information provided by us" } } }, "/create": { "post": { "parameters": [ { "description": "a bearer authorization header", "in": "header", "name": "Authorization", "required": true, "schema": { "default": "Bearer + token", "type": "string" } } ], "responses": { "200": { "content": { "*/*": { "schema": { "properties": { "data": { "properties": { "autologinUrl": { "type": "string" }, "crmId": { "type": "string" }, "tpId": { "type": "string" } }, "type": "object" }, "error": { "default": "", "type": "string" }, "result": { "default": 1, "type": "integer" } }, "type": "object" } } }, "description": "Customer successfully created" } }, "tags": [ "create" ], "description": "Endpoint to create a client", "operationId": "post-create", "requestBody": { "content": { "application/json": { "schema": { "properties": { "country": { "description": "ISO alpha-2 code", "type": "string" }, "email": { "type": "string" }, "firstName": { "type": "string" }, "lastName": { "type": "string" }, "password": { "description": "minlength 8, maxlength 15, at least one number, lowercase and capital letter", "type": "string" }, "phoneCountryCode": { "description": "phone country code with + included", "type": "string" }, "phoneNumber": { "description": "max lenght 10", "type": "string" }, "referral": { "description": "campaign where customer came from", "type": "string" }, "source": { "description": "page where customer came from", "type": "string" } }, "required": [ "firstName", "lastName", "email", "country", "phoneNumber", "phoneCountryCode", "referral", "password" ], "type": "object" } } }, "description": "Client information to create a client" } } }, "/get/Multiple": { "get": { "parameters": [ { "description": "an bearer authorization header", "in": "header", "name": "Authorization", "required": true, "schema": { "default": "Bearer + token", "type": "string" } }, { "description": "pagination number", "in": "query", "name": "page", "schema": { "default": 1, "type": "integer" } }, { "description": "start date for range in format YYYY-MM-DD", "in": "query", "name": "startDate", "schema": { "type": "string" } }, { "description": "end date for range in format YYYY-MM-DD", "in": "query", "name": "endDate", "schema": { "type": "string" } }, { "description": "number of records you want to read", "in": "query", "name": "rows", "schema": { "default": 500, "type": "integer" } }, { "description": "boolean to get only ftds or get every lead", "in": "query", "name": "onlyFtd", "schema": { "type": "boolean" } } ], "responses": { "200": { "content": { "*/*": { "schema": { "properties": { "data": { "items": { "properties": { "country": { "type": "string" }, "crmId": { "type": "string" }, "email": { "type": "string" }, "firstName": { "type": "string" }, "ftd": { "type": "integer" }, "ftdDate": { "description": "date in format YYYY-MM-DD HH:mm:SS", "type": "string" }, "insertDate": { "description": "date in format YYYY-MM-DD HH:mm:SS", "type": "string" }, "lastName": { "type": "string" }, "referral": { "type": "string" }, "source": { "type": "string" }, "status": { "type": "string" }, "tpId": { "type": "string" } }, "type": "object" }, "type": "array" }, "error": { "default": "", "type": "string" }, "result": { "default": 1, "type": "integer" } }, "type": "object" } } }, "description": "shows customers" } }, "tags": [ "get" ], "description": "Shows all customers inserted in a range of dates", "operationId": "get-get-multiple" } }, "/get/Single": { "get": { "parameters": [ { "description": "an bearer authorization header", "in": "header", "name": "Authorization", "required": true, "schema": { "default": "Bearer + token", "type": "string" } }, { "description": "Customer's email", "in": "query", "name": "email", "schema": { "type": "string" } } ], "responses": { "200": { "content": { "*/*": { "schema": { "properties": { "data": { "properties": { "country": { "type": "string" }, "crmId": { "type": "string" }, "email": { "type": "string" }, "firstName": { "type": "string" }, "ftd": { "type": "integer" }, "ftdDate": { "description": "date in format YYYY-MM-DD HH:mm:SS", "type": "string" }, "insertDate": { "description": "date in format YYYY-MM-DD HH:mm:SS", "type": "string" }, "lastName": { "type": "string" }, "referral": { "type": "string" }, "source": { "type": "string" }, "status": { "type": "string" }, "tpId": { "type": "string" } }, "type": "object" }, "error": { "default": "", "type": "string" }, "result": { "default": 1, "type": "integer" } }, "type": "object" } } }, "description": "customer information" } }, "tags": [ "get" ], "description": "Show customer information", "operationId": "get-get-single" } } }, "components": {}, "tags": [ { "name": "auth" }, { "name": "create" }, { "name": "get" } ] }