diff --git a/.gitmodules b/.gitmodules new file mode 100644 index 00000000000..9ec50069494 --- /dev/null +++ b/.gitmodules @@ -0,0 +1,3 @@ +[submodule "swagger-js-codegen"] + path = swagger-js-codegen + url = https://github.com/wcandillon/swagger-js-codegen.git diff --git a/configurations/IrisConfiguration.json b/configurations/IrisConfiguration.json new file mode 100644 index 00000000000..bd22d630559 --- /dev/null +++ b/configurations/IrisConfiguration.json @@ -0,0 +1,3 @@ +{ +"invokerPackage":"Iris\Client" +} diff --git a/coupon-gateway.json b/coupon-gateway.json new file mode 100644 index 00000000000..2c4189546f5 --- /dev/null +++ b/coupon-gateway.json @@ -0,0 +1 @@ +{"swagger":"2.0","info":{"description":"Api Documentation","version":"1.0","title":"Api Documentation","termsOfService":"urn:tos","contact":{},"license":{"name":"Apache 2.0","url":"http://www.apache.org/licenses/LICENSE-2.0"}},"host":"localhost:8080","basePath":"/","tags":[{"name":"org-gateway-mapping-resource","description":"Org Gateway Mapping Resource"},{"name":"coupon-gateway-resource","description":"Coupon Gateway Resource"},{"name":"gateway-resource","description":"Gateway Resource"},{"name":"coupon-resource","description":"Coupon Resource"}],"paths":{"/v1/coupon/issue":{"post":{"tags":["coupon-resource"],"summary":"issueCoupon","operationId":"issueCouponUsingPOST","consumes":["application/json"],"produces":["application/json"],"parameters":[{"in":"body","name":"issueCouponRequest","description":"issueCouponRequest","required":true,"schema":{"$ref":"#/definitions/IssueCouponRequest"}}],"responses":{"200":{"description":"OK","schema":{"$ref":"#/definitions/ResponseWrapper«IssueCouponResponse»"}},"201":{"description":"Created"},"401":{"description":"Unauthorized"},"403":{"description":"Forbidden"},"404":{"description":"Not Found"}}}},"/v1/coupongateway/isAlive":{"get":{"tags":["coupon-gateway-resource"],"summary":"isAlive","operationId":"isAliveUsingGET","consumes":["application/json"],"produces":["*/*"],"responses":{"200":{"description":"OK","schema":{"type":"string"}},"401":{"description":"Unauthorized"},"403":{"description":"Forbidden"},"404":{"description":"Not Found"}}}},"/v1/coupongateway/version":{"get":{"tags":["coupon-gateway-resource"],"summary":"getVersion","operationId":"getVersionUsingGET","consumes":["application/json"],"produces":["*/*"],"responses":{"200":{"description":"OK","schema":{"$ref":"#/definitions/VersionData"}},"401":{"description":"Unauthorized"},"403":{"description":"Forbidden"},"404":{"description":"Not Found"}}}},"/v1/gatewaymappings":{"get":{"tags":["org-gateway-mapping-resource"],"summary":"getAllGatewayMappingsByOrgId","operationId":"getAllGatewayMappingsByOrgIdUsingGET","consumes":["application/json"],"produces":["application/json"],"parameters":[{"name":"orgId","in":"query","description":"orgId","required":true,"type":"integer","format":"int64"},{"name":"includeInactive","in":"query","description":"includeInactive","required":false,"type":"boolean","default":false}],"responses":{"200":{"description":"OK","schema":{"$ref":"#/definitions/ResponseWrapper«List«OrgCouponGatewayMapping»»"}},"401":{"description":"Unauthorized"},"403":{"description":"Forbidden"},"404":{"description":"Not Found"}}},"post":{"tags":["org-gateway-mapping-resource"],"summary":"createGatewayMappings","operationId":"createGatewayMappingsUsingPOST","consumes":["application/json"],"produces":["application/json"],"parameters":[{"in":"body","name":"orgCouponGatewayMapping","description":"orgCouponGatewayMapping","required":true,"schema":{"$ref":"#/definitions/OrgCouponGatewayMapping"}}],"responses":{"200":{"description":"OK","schema":{"$ref":"#/definitions/ResponseWrapper«OrgCouponGatewayMapping»"}},"201":{"description":"Created"},"401":{"description":"Unauthorized"},"403":{"description":"Forbidden"},"404":{"description":"Not Found"}}}},"/v1/gatewaymappings/{gatewayMappingId}/activate":{"put":{"tags":["org-gateway-mapping-resource"],"summary":"activateGatewayMapping","operationId":"activateGatewayMappingUsingPUT","consumes":["application/json"],"produces":["application/json"],"parameters":[{"name":"gatewayMappingId","in":"path","description":"gatewayMappingId","required":true,"type":"string"}],"responses":{"200":{"description":"OK","schema":{"$ref":"#/definitions/ResponseWrapper«boolean»"}},"201":{"description":"Created"},"401":{"description":"Unauthorized"},"403":{"description":"Forbidden"},"404":{"description":"Not Found"}}}},"/v1/gatewaymappings/{gatewayMappingId}/deactivate":{"put":{"tags":["org-gateway-mapping-resource"],"summary":"deActivateGatewayMapping","operationId":"deActivateGatewayMappingUsingPUT","consumes":["application/json"],"produces":["application/json"],"parameters":[{"name":"gatewayMappingId","in":"path","description":"gatewayMappingId","required":true,"type":"string"}],"responses":{"200":{"description":"OK","schema":{"$ref":"#/definitions/ResponseWrapper«boolean»"}},"201":{"description":"Created"},"401":{"description":"Unauthorized"},"403":{"description":"Forbidden"},"404":{"description":"Not Found"}}}},"/v1/gatewaymappings/{id}":{"get":{"tags":["org-gateway-mapping-resource"],"summary":"getByGatewayMappingId","operationId":"getByGatewayMappingIdUsingGET","consumes":["application/json"],"produces":["application/json"],"parameters":[{"name":"id","in":"path","description":"id","required":true,"type":"string"}],"responses":{"200":{"description":"OK","schema":{"$ref":"#/definitions/ResponseWrapper«OrgCouponGatewayMapping»"}},"401":{"description":"Unauthorized"},"403":{"description":"Forbidden"},"404":{"description":"Not Found"}}},"put":{"tags":["org-gateway-mapping-resource"],"summary":"updateGatewayMappings","operationId":"updateGatewayMappingsUsingPUT","consumes":["application/json"],"produces":["application/json"],"parameters":[{"name":"id","in":"path","description":"id","required":true,"type":"string"},{"in":"body","name":"orgCouponGatewayMapping","description":"orgCouponGatewayMapping","required":true,"schema":{"$ref":"#/definitions/OrgCouponGatewayMapping"}}],"responses":{"200":{"description":"OK","schema":{"$ref":"#/definitions/ResponseWrapper«OrgCouponGatewayMapping»"}},"201":{"description":"Created"},"401":{"description":"Unauthorized"},"403":{"description":"Forbidden"},"404":{"description":"Not Found"}}}},"/v1/gateways":{"post":{"tags":["gateway-resource"],"summary":"create","operationId":"createUsingPOST","consumes":["application/json"],"produces":["application/json"],"parameters":[{"in":"body","name":"couponGateway","description":"couponGateway","required":true,"schema":{"$ref":"#/definitions/CouponGateway"}}],"responses":{"200":{"description":"OK","schema":{"$ref":"#/definitions/ResponseWrapper«CouponGateway»"}},"201":{"description":"Created"},"401":{"description":"Unauthorized"},"403":{"description":"Forbidden"},"404":{"description":"Not Found"}}}},"/v1/gateways/":{"get":{"tags":["gateway-resource"],"summary":"getAllGateways","operationId":"getAllGatewaysUsingGET","consumes":["application/json"],"produces":["application/json"],"parameters":[{"name":"includeInactive","in":"query","description":"includeInactive","required":false,"type":"boolean","default":false}],"responses":{"200":{"description":"OK","schema":{"$ref":"#/definitions/ResponseWrapper«List«CouponGateway»»"}},"401":{"description":"Unauthorized"},"403":{"description":"Forbidden"},"404":{"description":"Not Found"}}}},"/v1/gateways/{gatewayId}":{"get":{"tags":["gateway-resource"],"summary":"getById","operationId":"getByIdUsingGET","consumes":["application/json"],"produces":["application/json"],"parameters":[{"name":"gatewayId","in":"path","description":"gatewayId","required":true,"type":"string"}],"responses":{"200":{"description":"OK","schema":{"$ref":"#/definitions/ResponseWrapper«CouponGateway»"}},"401":{"description":"Unauthorized"},"403":{"description":"Forbidden"},"404":{"description":"Not Found"}}},"put":{"tags":["gateway-resource"],"summary":"update","operationId":"updateUsingPUT","consumes":["application/json"],"produces":["application/json"],"parameters":[{"name":"gatewayId","in":"path","description":"gatewayId","required":true,"type":"string"},{"in":"body","name":"couponGateway","description":"couponGateway","required":true,"schema":{"$ref":"#/definitions/CouponGateway"}}],"responses":{"200":{"description":"OK","schema":{"$ref":"#/definitions/ResponseWrapper«CouponGateway»"}},"201":{"description":"Created"},"401":{"description":"Unauthorized"},"403":{"description":"Forbidden"},"404":{"description":"Not Found"}}}},"/v1/gateways/{gatewayId}/activate":{"put":{"tags":["gateway-resource"],"summary":"activateGateway","operationId":"activateGatewayUsingPUT","consumes":["application/json"],"produces":["application/json"],"parameters":[{"name":"gatewayId","in":"path","description":"gatewayId","required":true,"type":"string"}],"responses":{"200":{"description":"OK","schema":{"$ref":"#/definitions/ResponseWrapper«boolean»"}},"201":{"description":"Created"},"401":{"description":"Unauthorized"},"403":{"description":"Forbidden"},"404":{"description":"Not Found"}}}},"/v1/gateways/{gatewayId}/deactivate":{"put":{"tags":["gateway-resource"],"summary":"deActivateGateway","operationId":"deActivateGatewayUsingPUT","consumes":["application/json"],"produces":["application/json"],"parameters":[{"name":"gatewayId","in":"path","description":"gatewayId","required":true,"type":"string"}],"responses":{"200":{"description":"OK","schema":{"$ref":"#/definitions/ResponseWrapper«boolean»"}},"201":{"description":"Created"},"401":{"description":"Unauthorized"},"403":{"description":"Forbidden"},"404":{"description":"Not Found"}}}}},"definitions":{"ApiError":{"type":"object","properties":{"code":{"type":"integer","format":"int32"},"getIsRetryable":{"type":"boolean"},"message":{"type":"string"}}},"CouponGateway":{"type":"object","properties":{"active":{"type":"boolean"},"baseUrl":{"type":"string"},"batchSize":{"type":"integer","format":"int32"},"concurrency":{"type":"integer","format":"int32"},"createdBy":{"type":"integer","format":"int64"},"createdOn":{"type":"string","format":"date-time"},"gatewayProperties":{"type":"array","items":{"$ref":"#/definitions/Property"}},"id":{"type":"string"},"name":{"type":"string"},"requiredFields":{"type":"array","items":{"type":"string"}},"timeoutInMillis":{"type":"integer","format":"int32"},"updatedBy":{"type":"integer","format":"int64"},"updatedOn":{"type":"string","format":"date-time"}}},"CouponSeries":{"type":"object","properties":{"customProperties":{"type":"object","additionalProperties":{"type":"string"}},"discountType":{"type":"string","enum":["PERC","ABS"]},"discountValue":{"type":"number","format":"double"},"id":{"type":"integer","format":"int64"},"seriesExpiryDate":{"type":"integer","format":"int64"}}},"IssueCouponRequest":{"type":"object","properties":{"couponSeries":{"$ref":"#/definitions/CouponSeries"},"issuedBy":{"$ref":"#/definitions/OrgEntity"},"orgCouponGatewayId":{"type":"string"},"orgId":{"type":"integer","format":"int64"},"requestId":{"type":"string"},"userInfo":{"$ref":"#/definitions/UserInfo"}}},"IssueCouponResponse":{"type":"object","properties":{"issuedCouponDetails":{"$ref":"#/definitions/IssuedCouponDetails"},"serverRequestId":{"type":"string"}}},"IssuedCouponDetails":{"type":"object","properties":{"additionalInfo":{"type":"string"},"couponCode":{"type":"string"},"error":{"$ref":"#/definitions/ApiError"},"issuedTime":{"type":"integer","format":"int64"},"userInfo":{"$ref":"#/definitions/UserInfo"}}},"OrgCouponGatewayMapping":{"type":"object","properties":{"active":{"type":"boolean"},"couponGateway":{"$ref":"#/definitions/CouponGateway"},"couponGatewayId":{"type":"string"},"createdBy":{"type":"integer","format":"int64"},"createdOn":{"type":"string","format":"date-time"},"id":{"type":"string"},"orgCouponGatewayProperties":{"type":"array","items":{"$ref":"#/definitions/Property"}},"orgId":{"type":"integer","format":"int64"},"updatedBy":{"type":"integer","format":"int64"},"updatedOn":{"type":"string","format":"date-time"}}},"OrgEntity":{"type":"object","properties":{"id":{"type":"integer","format":"int64"}}},"Property":{"type":"object","properties":{"key":{"type":"string"},"value":{"type":"string"}}},"ResponseWrapper«CouponGateway»":{"type":"object","properties":{"data":{"$ref":"#/definitions/CouponGateway"},"errors":{"type":"array","items":{"$ref":"#/definitions/ApiError"}}}},"ResponseWrapper«IssueCouponResponse»":{"type":"object","properties":{"data":{"$ref":"#/definitions/IssueCouponResponse"},"errors":{"type":"array","items":{"$ref":"#/definitions/ApiError"}}}},"ResponseWrapper«List«CouponGateway»»":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/definitions/CouponGateway"}},"errors":{"type":"array","items":{"$ref":"#/definitions/ApiError"}}}},"ResponseWrapper«List«OrgCouponGatewayMapping»»":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/definitions/OrgCouponGatewayMapping"}},"errors":{"type":"array","items":{"$ref":"#/definitions/ApiError"}}}},"ResponseWrapper«OrgCouponGatewayMapping»":{"type":"object","properties":{"data":{"$ref":"#/definitions/OrgCouponGatewayMapping"},"errors":{"type":"array","items":{"$ref":"#/definitions/ApiError"}}}},"ResponseWrapper«boolean»":{"type":"object","properties":{"data":{"type":"boolean"},"errors":{"type":"array","items":{"$ref":"#/definitions/ApiError"}}}},"Transaction":{"type":"object","properties":{"amount":{"type":"number","format":"double"},"id":{"type":"integer","format":"int64"},"transactionNumber":{"type":"string"},"transactionTime":{"type":"integer","format":"int64"}}},"UserInfo":{"type":"object","properties":{"email":{"type":"string"},"externalId":{"type":"string"},"mobile":{"type":"string"},"transaction":{"$ref":"#/definitions/Transaction"},"userId":{"type":"integer","format":"int64"}}},"VersionData":{"type":"object","properties":{"artifactVersion":{"type":"string"}}}}} diff --git a/modules/swagger-codegen-cli/pom.xml b/modules/swagger-codegen-cli/pom.xml index 6b56d5a6f56..212fd58e5d5 100644 --- a/modules/swagger-codegen-cli/pom.xml +++ b/modules/swagger-codegen-cli/pom.xml @@ -3,7 +3,7 @@ io.swagger swagger-codegen-project - 2.2.2-SNAPSHOT + 2.2.2 ../.. 4.0.0 diff --git a/modules/swagger-codegen-maven-plugin/pom.xml b/modules/swagger-codegen-maven-plugin/pom.xml index 4df64ca4e61..002f0a4498c 100644 --- a/modules/swagger-codegen-maven-plugin/pom.xml +++ b/modules/swagger-codegen-maven-plugin/pom.xml @@ -6,7 +6,7 @@ io.swagger swagger-codegen-project - 2.2.2-SNAPSHOT + 2.2.2 ../.. swagger-codegen-maven-plugin diff --git a/modules/swagger-codegen/pom.xml b/modules/swagger-codegen/pom.xml index 21e44ce2547..5cdb9bba741 100644 --- a/modules/swagger-codegen/pom.xml +++ b/modules/swagger-codegen/pom.xml @@ -3,7 +3,7 @@ io.swagger swagger-codegen-project - 2.2.2-SNAPSHOT + 2.2.2 ../.. 4.0.0 diff --git a/modules/swagger-codegen/src/main/java/io/swagger/codegen/languages/AbstractJavaCodegen.java b/modules/swagger-codegen/src/main/java/io/swagger/codegen/languages/AbstractJavaCodegen.java index 052a0f82316..cd00722657b 100644 --- a/modules/swagger-codegen/src/main/java/io/swagger/codegen/languages/AbstractJavaCodegen.java +++ b/modules/swagger-codegen/src/main/java/io/swagger/codegen/languages/AbstractJavaCodegen.java @@ -8,6 +8,7 @@ import java.util.List; import java.util.ListIterator; import java.util.Map; +import java.util.Date; import java.util.regex.Pattern; import org.apache.commons.lang3.BooleanUtils; @@ -285,6 +286,9 @@ else if (dateLibrary.startsWith("java8")) { typeMapping.put("DateTime", "OffsetDateTime"); importMapping.put("OffsetDateTime", "java.time.OffsetDateTime"); } + + typeMapping.put("DateTime", "Date"); + importMapping.put("DateTime", "java.util.Date"); } } @@ -933,7 +937,8 @@ public String escapeQuotationMark(String input) { @Override public String escapeUnsafeCharacters(String input) { - return input.replace("*/", "*_/").replace("/*", "/_*"); + return input; + //return input.replace("*/", "*_/").replace("/*", "/_*"); } /* diff --git a/modules/swagger-codegen/src/main/resources/Java/libraries/okhttp-gson/pom.mustache b/modules/swagger-codegen/src/main/resources/Java/libraries/okhttp-gson/pom.mustache index 698c1a97f94..9593df769f9 100644 --- a/modules/swagger-codegen/src/main/resources/Java/libraries/okhttp-gson/pom.mustache +++ b/modules/swagger-codegen/src/main/resources/Java/libraries/okhttp-gson/pom.mustache @@ -102,6 +102,13 @@ 2.10.4 + + + org.apache.maven.wagon + wagon-ssh + 2.9 + + @@ -161,4 +168,18 @@ 4.12 UTF-8 + + + capillarymavenrepo + Capillary Maven Repo + scp://capillary@mvnrepo.capillary.co.in/data/mvn/releases + default + + + capillarymavensnapshotrepo + Capillary Maven Snapshot Repo + scp://capillary@mvnrepo.capillary.co.in/data/mvn/snapshots + default + + \ No newline at end of file diff --git a/modules/swagger-codegen/src/main/resources/csharp/ApiClient.mustache b/modules/swagger-codegen/src/main/resources/csharp/ApiClient.mustache index 33b631280c2..ae0bdb94772 100644 --- a/modules/swagger-codegen/src/main/resources/csharp/ApiClient.mustache +++ b/modules/swagger-codegen/src/main/resources/csharp/ApiClient.mustache @@ -23,7 +23,9 @@ namespace {{packageName}}.Client { private JsonSerializerSettings serializerSettings = new JsonSerializerSettings { - ConstructorHandling = ConstructorHandling.AllowNonPublicDefaultConstructor + ConstructorHandling = ConstructorHandling.AllowNonPublicDefaultConstructor, + DateFormatHandling= DateFormatHandling.IsoDateFormat, + DateTimeZoneHandling= DateTimeZoneHandling.Utc }; /// @@ -178,6 +180,18 @@ namespace {{packageName}}.Client // set user agent RestClient.UserAgent = Configuration.UserAgent; + if(!String.IsNullOrEmpty(Configuration.ProxyUrl)){ + + IWebProxy proxy = new WebProxy(Configuration.ProxyUrl, true); + if (!String.IsNullOrEmpty(Configuration.ProxyUsername)) + { + var credential = new NetworkCredential(Configuration.ProxyUsername, Configuration.ProxyPassword); + proxy.Credentials = credential; + } + } + + RestClient.Proxy=proxy; + InterceptRequest(request); {{^supportsUWP}} var response = RestClient.Execute(request); diff --git a/modules/swagger-codegen/src/main/resources/csharp/Configuration.mustache b/modules/swagger-codegen/src/main/resources/csharp/Configuration.mustache index 108b85e48f8..166d94deb9e 100644 --- a/modules/swagger-codegen/src/main/resources/csharp/Configuration.mustache +++ b/modules/swagger-codegen/src/main/resources/csharp/Configuration.mustache @@ -85,6 +85,10 @@ namespace {{packageName}}.Client /// public static readonly ExceptionFactory DefaultExceptionFactory = (methodName, response) => { + if (response.ErrorException is WebException && (response.ErrorException as WebException).Status == WebExceptionStatus.NameResolutionFailure) + { + return new ApiException(523, String.Format("Error calling {0}: {1}", methodName, response.ErrorMessage), response.ErrorMessage); + } int status = (int) response.StatusCode; if (status >= 400) return new ApiException(status, String.Format("Error calling {0}: {1}", methodName, response.Content), response.Content); if (status == 0) return new ApiException(status, String.Format("Error calling {0}: {1}", methodName, response.ErrorMessage), response.ErrorMessage); @@ -200,6 +204,24 @@ namespace {{packageName}}.Client /// The password. public String Password { get; set; } + /// + /// Gets or sets the proxyurl (HTTP basic authentication). + /// + /// The proxyurl. + public String ProxyUrl { get; set; } + + /// + /// Gets or sets the proxy username (HTTP basic authentication). + /// + /// The proxy username. + public String ProxyUsername { get; set; } + + /// + /// Gets or sets the proxy password (HTTP basic authentication). + /// + /// The proxy password. + public String ProxyPassword { get; set; } + /// /// Gets or sets the access token for OAuth2 authentication. /// diff --git a/modules/swagger-codegen/src/main/resources/csharp/modelGeneric.mustache b/modules/swagger-codegen/src/main/resources/csharp/modelGeneric.mustache index 8f0ec47a1fa..f5023b955b5 100644 --- a/modules/swagger-codegen/src/main/resources/csharp/modelGeneric.mustache +++ b/modules/swagger-codegen/src/main/resources/csharp/modelGeneric.mustache @@ -1,11 +1,12 @@ /// /// {{#description}}{{.}}{{/description}}{{^description}}{{classname}}{{/description}} /// + [Serializable] [DataContract] {{#generatePropertyChanged}} [ImplementPropertyChanged] {{/generatePropertyChanged}} - public partial class {{classname}} : {{#parent}}{{{parent}}}, {{/parent}} IEquatable<{{classname}}>, IValidatableObject + public partial class {{classname}} : {{#parent}}{{{parent}}}, {{/parent}} IEquatable<{{classname}}> { {{#vars}} {{#isEnum}} @@ -84,7 +85,7 @@ this.{{name}} = {{name}}; {{/isReadOnly}} {{/vars}} } - + {{#vars}} {{^isEnum}} /// @@ -109,7 +110,7 @@ this.{{name}} = {{name}}; sb.Append("}\n"); return sb.ToString(); } - + /// /// Returns the JSON string presentation of the object /// @@ -188,39 +189,5 @@ this.{{name}} = {{name}}; } {{/generatePropertyChanged}} - public IEnumerable Validate(ValidationContext validationContext) - { {{#vars}}{{#hasValidation}}{{#maxLength}} - // {{{name}}} ({{{datatype}}}) maxLength - if(this.{{{name}}} != null && this.{{{name}}}.Length > {{maxLength}}) - { - yield return new ValidationResult("Invalid value for {{{name}}}, length must be less than {{maxLength}}.", new [] { "{{{name}}}" }); - } -{{/maxLength}}{{#minLength}} - // {{{name}}} ({{{datatype}}}) minLength - if(this.{{{name}}} != null && this.{{{name}}}.Length < {{minLength}}) - { - yield return new ValidationResult("Invalid value for {{{name}}}, length must be greater than {{minLength}}.", new [] { "{{{name}}}" }); - } -{{/minLength}}{{#maximum}} - // {{{name}}} ({{{datatype}}}) maximum - if(this.{{{name}}} > ({{{datatype}}}){{maximum}}) - { - yield return new ValidationResult("Invalid value for {{{name}}}, must be a value less than or equal to {{maximum}}.", new [] { "{{{name}}}" }); - } -{{/maximum}}{{#minimum}} - // {{{name}}} ({{{datatype}}}) minimum - if(this.{{{name}}} < ({{{datatype}}}){{minimum}}) - { - yield return new ValidationResult("Invalid value for {{{name}}}, must be a value greater than or equal to {{minimum}}.", new [] { "{{{name}}}" }); - } -{{/minimum}}{{#pattern}} - // {{{name}}} ({{{datatype}}}) pattern - Regex regex{{{name}}} = new Regex(@"{{vendorExtensions.x-regex}}"{{#vendorExtensions.x-modifiers}}{{#-first}}, {{/-first}}RegexOptions.{{.}}{{^-last}} | {{/-last}}{{/vendorExtensions.x-modifiers}}); - if (false == regex{{{name}}}.Match(this.{{{name}}}).Success) - { - yield return new ValidationResult("Invalid value for {{{name}}}, must match a pattern of {{pattern}}.", new [] { "{{{name}}}" }); - } -{{/pattern}}{{/hasValidation}}{{/vars}} - yield break; - } + } diff --git a/modules/swagger-codegen/src/main/resources/php/.php_cs b/modules/swagger-codegen/src/main/resources/php/.php_cs index 6b8e23c818a..c06f4a27403 100644 --- a/modules/swagger-codegen/src/main/resources/php/.php_cs +++ b/modules/swagger-codegen/src/main/resources/php/.php_cs @@ -4,13 +4,13 @@ return Symfony\CS\Config::create() ->level(Symfony\CS\FixerInterface::PSR2_LEVEL) ->setUsingCache(true) ->fixers( - [ + array( 'ordered_use', 'phpdoc_order', 'short_array_syntax', 'strict', 'strict_param' - ] + ) ) ->finder( Symfony\CS\Finder\DefaultFinder::create() diff --git a/modules/swagger-codegen/src/main/resources/php/ApiClient.mustache b/modules/swagger-codegen/src/main/resources/php/ApiClient.mustache index effdbedb7f8..2df3626fe57 100644 --- a/modules/swagger-codegen/src/main/resources/php/ApiClient.mustache +++ b/modules/swagger-codegen/src/main/resources/php/ApiClient.mustache @@ -129,7 +129,7 @@ class ApiClient */ public function callApi($resourcePath, $method, $queryParams, $postData, $headerParams, $responseType = null, $endpointPath = null) { - $headers = []; + $headers = array(); // construct the http header $headerParams = array_merge( @@ -238,7 +238,7 @@ class ApiClient } elseif ($response_info['http_code'] >= 200 && $response_info['http_code'] <= 299) { // return raw body if response is a file if ($responseType === '\SplFileObject' || $responseType === 'string') { - return [$http_body, $response_info['http_code'], $http_header]; + return array($http_body, $response_info['http_code'], $http_header); } $data = json_decode($http_body); @@ -258,7 +258,7 @@ class ApiClient $data ); } - return [$data, $response_info['http_code'], $http_header]; + return array($data, $response_info['http_code'], $http_header); } /** @@ -307,7 +307,7 @@ class ApiClient protected function httpParseHeaders($raw_headers) { // ref/credit: http://php.net/manual/en/function.http-parse-headers.php#112986 - $headers = []; + $headers = array(); $key = ''; foreach (explode("\n", $raw_headers) as $h) { @@ -317,9 +317,9 @@ class ApiClient if (!isset($headers[$h[0]])) { $headers[$h[0]] = trim($h[1]); } elseif (is_array($headers[$h[0]])) { - $headers[$h[0]] = array_merge($headers[$h[0]], [trim($h[1])]); + $headers[$h[0]] = array_merge($headers[$h[0]], array(trim($h[1]))); } else { - $headers[$h[0]] = array_merge([$headers[$h[0]]], [trim($h[1])]); + $headers[$h[0]] = array_merge(array($headers[$h[0]]), array(trim($h[1]))); } $key = $h[0]; diff --git a/modules/swagger-codegen/src/main/resources/php/ObjectSerializer.mustache b/modules/swagger-codegen/src/main/resources/php/ObjectSerializer.mustache index 7208e4c7784..d0a9a758dad 100644 --- a/modules/swagger-codegen/src/main/resources/php/ObjectSerializer.mustache +++ b/modules/swagger-codegen/src/main/resources/php/ObjectSerializer.mustache @@ -50,11 +50,13 @@ class ObjectSerializer } return $data; } elseif (is_object($data)) { - $values = []; + $values = array(); foreach (array_keys($data::swaggerTypes()) as $property) { - $getter = $data::getters()[$property]; + $dataGetters = $data::getters(); + $getter = $dataGetters[$property]; if ($data->$getter() !== null) { - $values[$data::attributeMap()[$property]] = self::sanitizeForSerialization($data->$getter()); + $dataAttrMap = $data::attributeMap(); + $values[$dataAttrMap[$property]] = self::sanitizeForSerialization($data->$getter()); } } return (object)$values; @@ -212,7 +214,7 @@ class ObjectSerializer return null; } elseif (substr($class, 0, 4) === 'map[') { // for associative array e.g. map[string,int] $inner = substr($class, 4, -1); - $deserialized = []; + $deserialized = array(); if (strrpos($inner, ",") !== false) { $subClass_array = explode(',', $inner, 2); $subClass = $subClass_array[1]; @@ -223,7 +225,7 @@ class ObjectSerializer return $deserialized; } elseif (strcasecmp(substr($class, -2), '[]') === 0) { $subClass = substr($class, 0, -2); - $values = []; + $values = array(); foreach ($data as $key => $value) { $values[] = self::deserialize($value, $subClass, null, $discriminator); } @@ -243,7 +245,7 @@ class ObjectSerializer } else { return null; } - } elseif (in_array($class, [{{&primitives}}], true)) { + } elseif (in_array($class, array({{&primitives}}), true)) { settype($data, $class); return $data; } elseif ($class === '\SplFileObject') { @@ -271,13 +273,14 @@ class ObjectSerializer } $instance = new $class(); foreach ($instance::swaggerTypes() as $property => $type) { - $propertySetter = $instance::setters()[$property]; - - if (!isset($propertySetter) || !isset($data->{$instance::attributeMap()[$property]})) { + $instSetters = $instance::setters(); + $propertySetter = $instSetters[$property]; + $instAttrMap = $instance::attributeMap(); + if (!isset($propertySetter) || !isset($data->{$instAttrMap[$property]})) { continue; } - $propertyValue = $data->{$instance::attributeMap()[$property]}; + $propertyValue = $data->{$instAttrMap[$property]}; if (isset($propertyValue)) { $instance->$propertySetter(self::deserialize($propertyValue, $type, null, $discriminator)); } diff --git a/modules/swagger-codegen/src/main/resources/php/api.mustache b/modules/swagger-codegen/src/main/resources/php/api.mustache index 26583a6f3d1..e2941d1ea2f 100644 --- a/modules/swagger-codegen/src/main/resources/php/api.mustache +++ b/modules/swagger-codegen/src/main/resources/php/api.mustache @@ -98,7 +98,10 @@ use \{{invokerPackage}}\ObjectSerializer; */ public function {{operationId}}({{#allParams}}${{paramName}}{{^required}} = null{{/required}}{{#hasMore}}, {{/hasMore}}{{/allParams}}) { - list($response) = $this->{{operationId}}WithHttpInfo({{#allParams}}${{paramName}}{{#hasMore}}, {{/hasMore}}{{/allParams}}); + $responseWithHeaders = $this->{{operationId}}WithHttpInfo({{#allParams}}${{paramName}}{{#hasMore}}, {{/hasMore}}{{/allParams}}); + list($response) = $responseWithHeaders; + $response["api_status"] = $responseWithHeaders["1"]; + $response["headers"] = $responseWithHeaders["2"]; return $response; } @@ -168,14 +171,14 @@ use \{{invokerPackage}}\ObjectSerializer; // parse inputs $resourcePath = "{{path}}"; $httpBody = ''; - $queryParams = []; - $headerParams = []; - $formParams = []; - $_header_accept = $this->apiClient->selectHeaderAccept([{{#produces}}'{{{mediaType}}}'{{#hasMore}}, {{/hasMore}}{{/produces}}]); + $queryParams = array(); + $headerParams = array(); + $formParams = array(); + $_header_accept = $this->apiClient->selectHeaderAccept(array({{#produces}}'{{{mediaType}}}'{{#hasMore}}, {{/hasMore}}{{/produces}})); if (!is_null($_header_accept)) { $headerParams['Accept'] = $_header_accept; } - $headerParams['Content-Type'] = $this->apiClient->selectHeaderContentType([{{#consumes}}'{{{mediaType}}}'{{#hasMore}}, {{/hasMore}}{{/consumes}}]); + $headerParams['Content-Type'] = $this->apiClient->selectHeaderContentType(array({{#consumes}}'{{{mediaType}}}'{{#hasMore}}, {{/hasMore}}{{/consumes}})); {{#queryParams}} // query params @@ -286,10 +289,10 @@ use \{{invokerPackage}}\ObjectSerializer; ); {{#returnType}} - return [$this->apiClient->getSerializer()->deserialize($response, '{{returnType}}', $httpHeader{{#discriminator}}, '{{discriminator}}'{{/discriminator}}), $statusCode, $httpHeader]; + return array($this->apiClient->getSerializer()->deserialize($response, '{{returnType}}', $httpHeader{{#discriminator}}, '{{discriminator}}'{{/discriminator}}), $statusCode, $httpHeader); {{/returnType}} {{^returnType}} - return [null, $statusCode, $httpHeader]; + return array(null, $statusCode, $httpHeader); {{/returnType}} } catch (ApiException $e) { switch ($e->getCode()) { diff --git a/modules/swagger-codegen/src/main/resources/php/configuration.mustache b/modules/swagger-codegen/src/main/resources/php/configuration.mustache index bae256b3bd3..1853b88719d 100644 --- a/modules/swagger-codegen/src/main/resources/php/configuration.mustache +++ b/modules/swagger-codegen/src/main/resources/php/configuration.mustache @@ -38,14 +38,14 @@ class Configuration * * @var string[] */ - protected $apiKeys = []; + protected $apiKeys = array(); /** * Associate array to store API prefix (e.g. Bearer) * * @var string[] */ - protected $apiKeyPrefixes = []; + protected $apiKeyPrefixes = array(); /** * Access token for OAuth @@ -73,7 +73,7 @@ class Configuration * * @var array */ - protected $defaultHeaders = []; + protected $defaultHeaders = array(); /** * The host diff --git a/modules/swagger-codegen/src/main/resources/php/model_enum.mustache b/modules/swagger-codegen/src/main/resources/php/model_enum.mustache index c9250081b82..8287a875a70 100644 --- a/modules/swagger-codegen/src/main/resources/php/model_enum.mustache +++ b/modules/swagger-codegen/src/main/resources/php/model_enum.mustache @@ -9,10 +9,10 @@ class {{classname}} { */ public function {{getter}}AllowableValues() { - return [ + return array( {{#allowableValues}}{{#enumVars}}self::{{datatypeWithEnum}}_{{{name}}},{{^-last}} {{/-last}}{{/enumVars}}{{/allowableValues}} - ]; + ); } {{/isEnum}}{{/vars}} } \ No newline at end of file diff --git a/modules/swagger-codegen/src/main/resources/php/model_generic.mustache b/modules/swagger-codegen/src/main/resources/php/model_generic.mustache index 1e221b78377..e09a7507e12 100644 --- a/modules/swagger-codegen/src/main/resources/php/model_generic.mustache +++ b/modules/swagger-codegen/src/main/resources/php/model_generic.mustache @@ -10,10 +10,10 @@ class {{classname}} {{#parentSchema}}extends {{{parent}}} {{/parentSchema}}imple * Array of property to type mappings. Used for (de)serialization * @var string[] */ - protected static $swaggerTypes = [ + protected static $swaggerTypes = array( {{#vars}}'{{name}}' => '{{{datatype}}}'{{#hasMore}}, {{/hasMore}}{{/vars}} - ]; + ); public static function swaggerTypes() { @@ -24,30 +24,30 @@ class {{classname}} {{#parentSchema}}extends {{{parent}}} {{/parentSchema}}imple * Array of attributes where the key is the local name, and the value is the original name * @var string[] */ - protected static $attributeMap = [ + protected static $attributeMap = array( {{#vars}}'{{name}}' => '{{baseName}}'{{#hasMore}}, {{/hasMore}}{{/vars}} - ]; + ); /** * Array of attributes to setter functions (for deserialization of responses) * @var string[] */ - protected static $setters = [ + protected static $setters = array( {{#vars}}'{{name}}' => '{{setter}}'{{#hasMore}}, {{/hasMore}}{{/vars}} - ]; + ); /** * Array of attributes to getter functions (for serialization of requests) * @var string[] */ - protected static $getters = [ + protected static $getters = array( {{#vars}}'{{name}}' => '{{getter}}'{{#hasMore}}, {{/hasMore}}{{/vars}} - ]; + ); public static function attributeMap() { @@ -74,10 +74,10 @@ class {{classname}} {{#parentSchema}}extends {{{parent}}} {{/parentSchema}}imple */ public function {{getter}}AllowableValues() { - return [ + return array( {{#allowableValues}}{{#enumVars}}self::{{enumName}}_{{{name}}},{{^-last}} {{/-last}}{{/enumVars}}{{/allowableValues}} - ]; + ); } {{/isEnum}}{{/vars}} @@ -85,7 +85,7 @@ class {{classname}} {{#parentSchema}}extends {{{parent}}} {{/parentSchema}}imple * Associative array for storing property values * @var mixed[] */ - protected $container = []; + protected $container = array(); /** * Constructor @@ -115,7 +115,7 @@ class {{classname}} {{#parentSchema}}extends {{{parent}}} {{/parentSchema}}imple */ public function listInvalidProperties() { - $invalid_properties = []; + $invalid_properties = array(); {{#vars}} {{#required}} if ($this->container['{{name}}'] === null) { @@ -124,7 +124,7 @@ class {{classname}} {{#parentSchema}}extends {{{parent}}} {{/parentSchema}}imple {{/required}} {{#isEnum}} {{^isContainer}} - $allowed_values = [{{#allowableValues}}{{#values}}"{{{this}}}"{{^-last}}, {{/-last}}{{/values}}{{/allowableValues}}]; + $allowed_values = array({{#allowableValues}}{{#values}}"{{{this}}}"{{^-last}}, {{/-last}}{{/values}}{{/allowableValues}}); if (!in_array($this->container['{{name}}'], $allowed_values)) { $invalid_properties[] = "invalid value for '{{name}}', must be one of #{allowed_values}."; } @@ -195,7 +195,7 @@ class {{classname}} {{#parentSchema}}extends {{{parent}}} {{/parentSchema}}imple {{/required}} {{#isEnum}} {{^isContainer}} - $allowed_values = [{{#allowableValues}}{{#values}}"{{{this}}}"{{^-last}}, {{/-last}}{{/values}}{{/allowableValues}}]; + $allowed_values = array({{#allowableValues}}{{#values}}"{{{this}}}"{{^-last}}, {{/-last}}{{/values}}{{/allowableValues}}); if (!in_array($this->container['{{name}}'], $allowed_values)) { return false; } diff --git a/modules/swagger-generator/pom.xml b/modules/swagger-generator/pom.xml index c44e4c2afd0..d579907d4f7 100644 --- a/modules/swagger-generator/pom.xml +++ b/modules/swagger-generator/pom.xml @@ -4,7 +4,7 @@ io.swagger swagger-codegen-project - 2.2.2-SNAPSHOT + 2.2.2 ../.. swagger-generator @@ -77,7 +77,7 @@ 8079 stopit - 8080 + 8083 60000 diff --git a/nodejs_sdk_gen b/nodejs_sdk_gen new file mode 100644 index 00000000000..f9bfd993c04 --- /dev/null +++ b/nodejs_sdk_gen @@ -0,0 +1,6 @@ +var fs = require('fs'); +var CodeGen = require('swagger-js-codegen').CodeGen; +var file = '../swagger.json'; +var swagger = JSON.parse(fs.readFileSync(file, 'UTF-8')); +var nodejsSourceCode = CodeGen.getNodeCode({ className: 'Test', swagger: swagger }); +console.log(nodejsSourceCode); \ No newline at end of file diff --git a/orchestrator.json b/orchestrator.json new file mode 100644 index 00000000000..c8ea1308369 --- /dev/null +++ b/orchestrator.json @@ -0,0 +1,5518 @@ +{ + "swagger": "2.0", + "info": { + "description": "Potato OTA Transaction Orchestrator", + "version": "1.0", + "title": "POTATO", + "contact": { + "name": "Capillary Technologies", + "url": "https://www.capillarytech.com" + }, + "license": {} + }, + "host": "localhost:8100", + "basePath": "/", + "tags": [ + { + "name": "_2c-2p-callback-resource", + "description": "_2c 2p Callback Resource" + }, + { + "name": "admin-workflow-resource", + "description": "Admin Workflow Resource" + }, + { + "name": "eghl-call-back-resource", + "description": "Eghl Call Back Resource" + }, + { + "name": "eghl-reconciliation", + "description": "EGHL Reconciliation" + }, + { + "name": "external-api-error-code-mapping-resource", + "description": "External API Error Code Mapping Resource" + }, + { + "name": "health-check-resource", + "description": "Health Check Resource" + }, + { + "name": "mobile-card-registration-resource", + "description": "Mobile Card Registration Resource" + }, + { + "name": "open-api-web-mvc-resource", + "description": "Open Api Web Mvc Resource" + }, + { + "name": "payments-resource", + "description": "Payments Resource" + }, + { + "name": "psp-auth-support-resource", + "description": "Psp Auth Support Resource" + }, + { + "name": "psp-performance-resource", + "description": "Psp Performance Resource" + }, + { + "name": "pump-life-cycle-resource", + "description": "Pump Life Cycle Resource" + }, + { + "name": "pump-performance-resource", + "description": "Pump Performance Resource" + }, + { + "name": "register-rest-controller", + "description": "Register Rest Controller" + }, + { + "name": "site-cancel-resource", + "description": "Site Cancel Resource" + }, + { + "name": "site-server-to-server-resource", + "description": "Site Server To Server Resource" + }, + { + "name": "swagger-config-resource", + "description": "Swagger Config Resource" + }, + { + "name": "test-fuelling-workflow-resource", + "description": "Test Fuelling Workflow Resource" + }, + { + "name": "transaction-status-resource", + "description": "Transaction Status Resource" + }, + { + "name": "txn-status-resource", + "description": "Txn Status Resource" + } + ], + "paths": { + "/external/errorcode/mapping": { + "get": { + "tags": [ + "external-api-error-code-mapping-resource" + ], + "summary": "getMapping", + "operationId": "getMappingUsingGET", + "produces": [ + "*/*" + ], + "parameters": [ + { + "name": "brand", + "in": "query", + "required": false, + "type": "string", + "enum": [ + "SHELL" + ] + }, + { + "name": "useCase", + "in": "query", + "required": false, + "type": "string", + "enum": [ + "CARD_REGISTRATION", + "FUELING", + "NON" + ] + } + ], + "responses": { + "200": { + "description": "OK", + "schema": { + "type": "array", + "items": { + "$ref": "#/definitions/ExternalAPIErrorCodeMappingDto" + } + } + }, + "401": { + "description": "Unauthorized" + }, + "403": { + "description": "Forbidden" + }, + "404": { + "description": "Not Found" + } + }, + "security": [ + { + "X-CAP-API-AUTH-ORG-ID": [ + "global" + ] + }, + { + "X-CAP-API-AUTH-ENTITY-ID": [ + "global" + ] + }, + { + "X-CAP-ENTITY-CODE": [ + "global" + ] + }, + { + "X-CAP-ENTITY-ID": [ + "global" + ] + } + ] + }, + "post": { + "tags": [ + "external-api-error-code-mapping-resource" + ], + "summary": "create", + "operationId": "createUsingPOST_1", + "consumes": [ + "application/json" + ], + "produces": [ + "*/*" + ], + "parameters": [ + { + "in": "body", + "name": "errorMapping", + "description": "errorMapping", + "required": true, + "schema": { + "$ref": "#/definitions/ExternalAPIErrorCodeMapping" + } + } + ], + "responses": { + "200": { + "description": "OK", + "schema": { + "$ref": "#/definitions/SingleResponse«ExternalAPIErrorCodeMappingResponse»" + } + }, + "201": { + "description": "Created" + }, + "401": { + "description": "Unauthorized" + }, + "403": { + "description": "Forbidden" + }, + "404": { + "description": "Not Found" + } + }, + "security": [ + { + "X-CAP-API-AUTH-ORG-ID": [ + "global" + ] + }, + { + "X-CAP-API-AUTH-ENTITY-ID": [ + "global" + ] + }, + { + "X-CAP-ENTITY-CODE": [ + "global" + ] + }, + { + "X-CAP-ENTITY-ID": [ + "global" + ] + } + ] + } + }, + "/external/errorcode/mapping/bulk": { + "post": { + "tags": [ + "external-api-error-code-mapping-resource" + ], + "summary": "bulkCreate", + "operationId": "bulkCreateUsingPOST", + "consumes": [ + "application/json" + ], + "produces": [ + "*/*" + ], + "parameters": [ + { + "in": "body", + "name": "errorMappingList", + "description": "errorMappingList", + "required": true, + "schema": { + "type": "array", + "items": { + "$ref": "#/definitions/ExternalAPIErrorCodeMapping" + } + } + } + ], + "responses": { + "200": { + "description": "OK", + "schema": { + "type": "integer", + "format": "int32" + } + }, + "201": { + "description": "Created" + }, + "401": { + "description": "Unauthorized" + }, + "403": { + "description": "Forbidden" + }, + "404": { + "description": "Not Found" + } + }, + "security": [ + { + "X-CAP-API-AUTH-ORG-ID": [ + "global" + ] + }, + { + "X-CAP-API-AUTH-ENTITY-ID": [ + "global" + ] + }, + { + "X-CAP-ENTITY-CODE": [ + "global" + ] + }, + { + "X-CAP-ENTITY-ID": [ + "global" + ] + } + ] + } + }, + "/hi": { + "post": { + "tags": [ + "register-rest-controller" + ], + "summary": "register", + "operationId": "registerUsingPOST", + "consumes": [ + "application/json" + ], + "produces": [ + "*/*" + ], + "responses": { + "200": { + "description": "OK", + "schema": { + "type": "string" + } + }, + "201": { + "description": "Created" + }, + "401": { + "description": "Unauthorized" + }, + "403": { + "description": "Forbidden" + }, + "404": { + "description": "Not Found" + } + }, + "security": [ + { + "X-CAP-API-AUTH-ORG-ID": [ + "global" + ] + }, + { + "X-CAP-API-AUTH-ENTITY-ID": [ + "global" + ] + }, + { + "X-CAP-ENTITY-CODE": [ + "global" + ] + }, + { + "X-CAP-ENTITY-ID": [ + "global" + ] + } + ] + } + }, + "/orchestrator/payments/app": { + "get": { + "tags": [ + "pump-life-cycle-resource" + ], + "summary": "get", + "operationId": "getUsingGET_1", + "produces": [ + "*/*" + ], + "responses": { + "200": { + "description": "OK", + "schema": { + "type": "string" + } + }, + "401": { + "description": "Unauthorized" + }, + "403": { + "description": "Forbidden" + }, + "404": { + "description": "Not Found" + } + }, + "security": [ + { + "X-CAP-API-AUTH-ORG-ID": [ + "global" + ] + }, + { + "X-CAP-API-AUTH-ENTITY-ID": [ + "global" + ] + }, + { + "X-CAP-ENTITY-CODE": [ + "global" + ] + }, + { + "X-CAP-ENTITY-ID": [ + "global" + ] + } + ] + } + }, + "/orchestrator/payments/app/pumpReserve/{version}": { + "post": { + "tags": [ + "test-fuelling-workflow-resource" + ], + "summary": "pumpReserveWithGivenVersion", + "operationId": "pumpReserveWithGivenVersionUsingPOST", + "consumes": [ + "application/json" + ], + "produces": [ + "*/*" + ], + "parameters": [ + { + "in": "body", + "name": "pumpReserve", + "description": "pumpReserve", + "required": true, + "schema": { + "$ref": "#/definitions/PumpReserve" + } + }, + { + "name": "version", + "in": "path", + "description": "version", + "required": true, + "type": "string" + } + ], + "responses": { + "200": { + "description": "OK", + "schema": { + "$ref": "#/definitions/MobileResponseBody«PumpReserve»" + } + }, + "201": { + "description": "Created" + }, + "401": { + "description": "Unauthorized" + }, + "403": { + "description": "Forbidden" + }, + "404": { + "description": "Not Found" + } + }, + "security": [ + { + "X-CAP-API-AUTH-ORG-ID": [ + "global" + ] + }, + { + "X-CAP-API-AUTH-ENTITY-ID": [ + "global" + ] + }, + { + "X-CAP-ENTITY-CODE": [ + "global" + ] + }, + { + "X-CAP-ENTITY-ID": [ + "global" + ] + } + ] + } + }, + "/orchestrator/payments/app/v1/failure-rate/bank": { + "get": { + "tags": [ + "psp-performance-resource" + ], + "summary": "pspStat", + "operationId": "pspStatUsingGET", + "produces": [ + "*/*" + ], + "parameters": [ + { + "name": "bankName", + "in": "query", + "required": false, + "type": "array", + "items": { + "type": "string" + }, + "collectionFormat": "multi" + }, + { + "name": "durationHours", + "in": "query", + "required": false, + "type": "integer", + "format": "int32" + }, + { + "name": "psp", + "in": "query", + "required": false, + "type": "string" + } + ], + "responses": { + "200": { + "description": "OK", + "schema": { + "$ref": "#/definitions/StatResponse«Map«string,PerformanceBo»»" + } + }, + "401": { + "description": "Unauthorized" + }, + "403": { + "description": "Forbidden" + }, + "404": { + "description": "Not Found" + } + }, + "security": [ + { + "X-CAP-API-AUTH-ORG-ID": [ + "global" + ] + }, + { + "X-CAP-API-AUTH-ENTITY-ID": [ + "global" + ] + }, + { + "X-CAP-ENTITY-CODE": [ + "global" + ] + }, + { + "X-CAP-ENTITY-ID": [ + "global" + ] + } + ] + } + }, + "/orchestrator/payments/app/v1/failure-rate/pump": { + "get": { + "tags": [ + "pump-performance-resource" + ], + "summary": "pumpStat", + "operationId": "pumpStatUsingGET", + "produces": [ + "*/*" + ], + "parameters": [ + { + "name": "durationHours", + "in": "query", + "required": false, + "type": "integer", + "format": "int32" + }, + { + "name": "siteId", + "in": "query", + "required": false, + "type": "string" + } + ], + "responses": { + "200": { + "description": "OK", + "schema": { + "$ref": "#/definitions/StatResponse«Map«string,PerformanceBo»»" + } + }, + "401": { + "description": "Unauthorized" + }, + "403": { + "description": "Forbidden" + }, + "404": { + "description": "Not Found" + } + }, + "security": [ + { + "X-CAP-API-AUTH-ORG-ID": [ + "global" + ] + }, + { + "X-CAP-API-AUTH-ENTITY-ID": [ + "global" + ] + }, + { + "X-CAP-ENTITY-CODE": [ + "global" + ] + }, + { + "X-CAP-ENTITY-ID": [ + "global" + ] + } + ] + } + }, + "/orchestrator/payments/app/v1/fuelling-status": { + "get": { + "tags": [ + "transaction-status-resource" + ], + "summary": "status", + "operationId": "statusUsingGET", + "produces": [ + "*/*" + ], + "parameters": [ + { + "name": "customerId", + "in": "query", + "required": false, + "type": "integer", + "format": "int64" + }, + { + "name": "paymentId", + "in": "query", + "required": false, + "type": "string" + } + ], + "responses": { + "200": { + "description": "OK", + "schema": { + "$ref": "#/definitions/AppTransactionStatusResponse" + } + }, + "401": { + "description": "Unauthorized" + }, + "403": { + "description": "Forbidden" + }, + "404": { + "description": "Not Found" + } + }, + "security": [ + { + "X-CAP-API-AUTH-ORG-ID": [ + "global" + ] + }, + { + "X-CAP-API-AUTH-ENTITY-ID": [ + "global" + ] + }, + { + "X-CAP-ENTITY-CODE": [ + "global" + ] + }, + { + "X-CAP-ENTITY-ID": [ + "global" + ] + } + ] + } + }, + "/orchestrator/payments/app/v1/hash/{paymentId}": { + "get": { + "tags": [ + "psp-auth-support-resource" + ], + "summary": "hashing", + "operationId": "hashingUsingGET", + "produces": [ + "*/*" + ], + "parameters": [ + { + "name": "paymentId", + "in": "path", + "description": "paymentId", + "required": true, + "type": "string" + }, + { + "name": "pspName", + "in": "query", + "required": false, + "type": "string", + "enum": [ + "2C2P", + "EGHL" + ] + }, + { + "name": "timeout", + "in": "query", + "required": false, + "type": "string" + } + ], + "responses": { + "200": { + "description": "OK", + "schema": { + "$ref": "#/definitions/HashingSupportResponse" + } + }, + "401": { + "description": "Unauthorized" + }, + "403": { + "description": "Forbidden" + }, + "404": { + "description": "Not Found" + } + }, + "security": [ + { + "X-CAP-API-AUTH-ORG-ID": [ + "global" + ] + }, + { + "X-CAP-API-AUTH-ENTITY-ID": [ + "global" + ] + }, + { + "X-CAP-ENTITY-CODE": [ + "global" + ] + }, + { + "X-CAP-ENTITY-ID": [ + "global" + ] + } + ] + } + }, + "/orchestrator/payments/app/v1/pump-activate": { + "post": { + "tags": [ + "pump-life-cycle-resource" + ], + "summary": "activatePump", + "operationId": "activatePumpUsingPOST", + "consumes": [ + "application/json" + ], + "produces": [ + "*/*" + ], + "parameters": [ + { + "in": "body", + "name": "preAuthorizeRequest", + "description": "preAuthorizeRequest", + "required": true, + "schema": { + "$ref": "#/definitions/PreAuthorizeStep" + } + } + ], + "responses": { + "200": { + "description": "OK", + "schema": { + "$ref": "#/definitions/MobileResponseBody«PreAuthorizeStep»" + } + }, + "201": { + "description": "Created" + }, + "401": { + "description": "Unauthorized" + }, + "403": { + "description": "Forbidden" + }, + "404": { + "description": "Not Found" + } + }, + "security": [ + { + "X-CAP-API-AUTH-ORG-ID": [ + "global" + ] + }, + { + "X-CAP-API-AUTH-ENTITY-ID": [ + "global" + ] + }, + { + "X-CAP-ENTITY-CODE": [ + "global" + ] + }, + { + "X-CAP-ENTITY-ID": [ + "global" + ] + } + ] + } + }, + "/orchestrator/payments/app/v1/pump-cancel": { + "post": { + "tags": [ + "pump-life-cycle-resource" + ], + "summary": "cancelPump", + "operationId": "cancelPumpUsingPOST", + "consumes": [ + "application/json" + ], + "produces": [ + "*/*" + ], + "parameters": [ + { + "in": "body", + "name": "cancelRequest", + "description": "cancelRequest", + "required": true, + "schema": { + "$ref": "#/definitions/CancelRequest" + } + } + ], + "responses": { + "200": { + "description": "OK", + "schema": { + "$ref": "#/definitions/CancelResponse" + } + }, + "201": { + "description": "Created" + }, + "401": { + "description": "Unauthorized" + }, + "403": { + "description": "Forbidden" + }, + "404": { + "description": "Not Found" + } + }, + "security": [ + { + "X-CAP-API-AUTH-ORG-ID": [ + "global" + ] + }, + { + "X-CAP-API-AUTH-ENTITY-ID": [ + "global" + ] + }, + { + "X-CAP-ENTITY-CODE": [ + "global" + ] + }, + { + "X-CAP-ENTITY-ID": [ + "global" + ] + } + ] + } + }, + "/orchestrator/payments/app/v1/pump-reserve": { + "post": { + "tags": [ + "pump-life-cycle-resource" + ], + "summary": "pumpReserve", + "operationId": "pumpReserveUsingPOST", + "consumes": [ + "application/json" + ], + "produces": [ + "*/*" + ], + "parameters": [ + { + "in": "body", + "name": "pumpReserve", + "description": "pumpReserve", + "required": true, + "schema": { + "$ref": "#/definitions/PumpReserve" + } + } + ], + "responses": { + "200": { + "description": "OK", + "schema": { + "$ref": "#/definitions/MobileResponseBody«PumpReserve»" + } + }, + "201": { + "description": "Created" + }, + "401": { + "description": "Unauthorized" + }, + "403": { + "description": "Forbidden" + }, + "404": { + "description": "Not Found" + } + }, + "security": [ + { + "X-CAP-API-AUTH-ORG-ID": [ + "global" + ] + }, + { + "X-CAP-API-AUTH-ENTITY-ID": [ + "global" + ] + }, + { + "X-CAP-ENTITY-CODE": [ + "global" + ] + }, + { + "X-CAP-ENTITY-ID": [ + "global" + ] + } + ] + } + }, + "/orchestrator/payments/app/v1/register-paymentId": { + "post": { + "tags": [ + "mobile-card-registration-resource" + ], + "summary": "generatePaymentIdentifier", + "operationId": "generatePaymentIdentifierUsingPOST", + "consumes": [ + "application/json" + ], + "produces": [ + "*/*" + ], + "parameters": [ + { + "in": "body", + "name": "tokenizeRO", + "description": "tokenizeRO", + "required": true, + "schema": { + "$ref": "#/definitions/TokenizeRO" + } + } + ], + "responses": { + "200": { + "description": "OK", + "schema": { + "$ref": "#/definitions/MobileResponseBody«TokenizeRO»" + } + }, + "201": { + "description": "Created" + }, + "401": { + "description": "Unauthorized" + }, + "403": { + "description": "Forbidden" + }, + "404": { + "description": "Not Found" + } + }, + "security": [ + { + "X-CAP-API-AUTH-ORG-ID": [ + "global" + ] + }, + { + "X-CAP-API-AUTH-ENTITY-ID": [ + "global" + ] + }, + { + "X-CAP-ENTITY-CODE": [ + "global" + ] + }, + { + "X-CAP-ENTITY-ID": [ + "global" + ] + } + ] + } + }, + "/orchestrator/payments/intouch/txn-status/payment-id/{paymentId}": { + "get": { + "tags": [ + "txn-status-resource" + ], + "summary": "getStatusByPaymentId", + "operationId": "getStatusByPaymentIdUsingGET", + "produces": [ + "application/json" + ], + "parameters": [ + { + "name": "paymentId", + "in": "path", + "description": "paymentId", + "required": true, + "type": "string" + } + ], + "responses": { + "200": { + "description": "OK", + "schema": { + "$ref": "#/definitions/SingleResponse«TxnStatusBo»" + } + }, + "401": { + "description": "Unauthorized" + }, + "403": { + "description": "Forbidden" + }, + "404": { + "description": "Not Found" + } + }, + "security": [ + { + "X-CAP-API-AUTH-ORG-ID": [ + "global" + ] + }, + { + "X-CAP-API-AUTH-ENTITY-ID": [ + "global" + ] + }, + { + "X-CAP-ENTITY-CODE": [ + "global" + ] + }, + { + "X-CAP-ENTITY-ID": [ + "global" + ] + } + ] + } + }, + "/orchestrator/payments/intouch/txn-status/user-id/{userId}": { + "get": { + "tags": [ + "txn-status-resource" + ], + "summary": "OTATransactionsByUserId", + "operationId": "OTATransactionsByUserIdUsingGET", + "produces": [ + "application/json" + ], + "parameters": [ + { + "name": "userId", + "in": "path", + "description": "userId", + "required": true, + "type": "string" + } + ], + "responses": { + "200": { + "description": "OK", + "schema": { + "$ref": "#/definitions/SingleResponse«List«UserTransactionBo»»" + } + }, + "401": { + "description": "Unauthorized" + }, + "403": { + "description": "Forbidden" + }, + "404": { + "description": "Not Found" + } + }, + "security": [ + { + "X-CAP-API-AUTH-ORG-ID": [ + "global" + ] + }, + { + "X-CAP-API-AUTH-ENTITY-ID": [ + "global" + ] + }, + { + "X-CAP-ENTITY-CODE": [ + "global" + ] + }, + { + "X-CAP-ENTITY-ID": [ + "global" + ] + } + ] + } + }, + "/orchestrator/payments/v1/site/cancel": { + "post": { + "tags": [ + "site-cancel-resource" + ], + "summary": "cancel", + "operationId": "cancelUsingPOST", + "consumes": [ + "application/json" + ], + "produces": [ + "*/*" + ], + "parameters": [ + { + "in": "body", + "name": "cancelRO", + "description": "cancelRO", + "required": true, + "schema": { + "$ref": "#/definitions/CancelRO" + } + } + ], + "responses": { + "200": { + "description": "OK" + }, + "201": { + "description": "Created" + }, + "401": { + "description": "Unauthorized" + }, + "403": { + "description": "Forbidden" + }, + "404": { + "description": "Not Found" + } + }, + "security": [ + { + "X-CAP-API-AUTH-ORG-ID": [ + "global" + ] + }, + { + "X-CAP-API-AUTH-ENTITY-ID": [ + "global" + ] + }, + { + "X-CAP-ENTITY-CODE": [ + "global" + ] + }, + { + "X-CAP-ENTITY-ID": [ + "global" + ] + } + ] + } + }, + "/orchestrator/payments/v1/site/finalize-txn": { + "post": { + "tags": [ + "site-server-to-server-resource" + ], + "summary": "finalizeTransaction", + "operationId": "finalizeTransactionUsingPOST", + "consumes": [ + "application/json" + ], + "produces": [ + "*/*" + ], + "parameters": [ + { + "in": "body", + "name": "transactionAddRO", + "description": "transactionAddRO", + "required": true, + "schema": { + "$ref": "#/definitions/TransactionAddRO" + } + } + ], + "responses": { + "200": { + "description": "OK" + }, + "201": { + "description": "Created" + }, + "401": { + "description": "Unauthorized" + }, + "403": { + "description": "Forbidden" + }, + "404": { + "description": "Not Found" + } + }, + "security": [ + { + "X-CAP-API-AUTH-ORG-ID": [ + "global" + ] + }, + { + "X-CAP-API-AUTH-ENTITY-ID": [ + "global" + ] + }, + { + "X-CAP-ENTITY-CODE": [ + "global" + ] + }, + { + "X-CAP-ENTITY-ID": [ + "global" + ] + } + ] + } + }, + "/orchestrator/payments/v1/site/get-offers": { + "post": { + "tags": [ + "site-server-to-server-resource" + ], + "summary": "offerEvaluation", + "operationId": "offerEvaluationUsingPOST", + "consumes": [ + "application/json" + ], + "produces": [ + "*/*" + ], + "parameters": [ + { + "in": "body", + "name": "offerEvaluationReq", + "description": "offerEvaluationReq", + "required": true, + "schema": { + "$ref": "#/definitions/OfferEvaluation" + } + } + ], + "responses": { + "200": { + "description": "OK", + "schema": { + "$ref": "#/definitions/OfferEvaluation" + } + }, + "201": { + "description": "Created" + }, + "401": { + "description": "Unauthorized" + }, + "403": { + "description": "Forbidden" + }, + "404": { + "description": "Not Found" + } + }, + "security": [ + { + "X-CAP-API-AUTH-ORG-ID": [ + "global" + ] + }, + { + "X-CAP-API-AUTH-ENTITY-ID": [ + "global" + ] + }, + { + "X-CAP-ENTITY-CODE": [ + "global" + ] + }, + { + "X-CAP-ENTITY-ID": [ + "global" + ] + } + ] + } + }, + "/orchestrator/payments/webhooks/2c2p/fuelling-callback": { + "post": { + "tags": [ + "_2c-2p-callback-resource" + ], + "summary": "fuellingCallBack", + "operationId": "fuellingCallBackUsingPOST", + "consumes": [ + "application/json" + ], + "produces": [ + "*/*" + ], + "parameters": [ + { + "in": "body", + "name": "callbackRequest", + "description": "callbackRequest", + "required": true, + "schema": { + "$ref": "#/definitions/_2c2pCallbackRequest" + } + }, + { + "name": "defaultCard", + "in": "query", + "required": false, + "type": "boolean" + }, + { + "name": "extCorrelationID", + "in": "query", + "required": false, + "type": "string" + }, + { + "name": "orgId", + "in": "query", + "required": false, + "type": "integer", + "format": "int64" + }, + { + "name": "paymentProvider", + "in": "query", + "required": false, + "type": "string" + }, + { + "name": "userId", + "in": "query", + "required": false, + "type": "integer", + "format": "int64" + } + ], + "responses": { + "200": { + "description": "OK", + "schema": { + "type": "string" + } + }, + "201": { + "description": "Created" + }, + "401": { + "description": "Unauthorized" + }, + "403": { + "description": "Forbidden" + }, + "404": { + "description": "Not Found" + } + }, + "security": [ + { + "X-CAP-API-AUTH-ORG-ID": [ + "global" + ] + }, + { + "X-CAP-API-AUTH-ENTITY-ID": [ + "global" + ] + }, + { + "X-CAP-ENTITY-CODE": [ + "global" + ] + }, + { + "X-CAP-ENTITY-ID": [ + "global" + ] + } + ] + } + }, + "/orchestrator/payments/webhooks/2c2p/register-callback": { + "post": { + "tags": [ + "_2c-2p-callback-resource" + ], + "summary": "registerCallBack", + "operationId": "registerCallBackUsingPOST", + "consumes": [ + "application/json" + ], + "produces": [ + "*/*" + ], + "parameters": [ + { + "in": "body", + "name": "callbackRequest", + "description": "callbackRequest", + "required": true, + "schema": { + "$ref": "#/definitions/_2c2pCallbackRequest" + } + }, + { + "name": "defaultCard", + "in": "query", + "required": false, + "type": "boolean" + }, + { + "name": "extCorrelationID", + "in": "query", + "required": false, + "type": "string" + }, + { + "name": "orgId", + "in": "query", + "required": false, + "type": "integer", + "format": "int64" + }, + { + "name": "paymentProvider", + "in": "query", + "required": false, + "type": "string" + }, + { + "name": "userId", + "in": "query", + "required": false, + "type": "integer", + "format": "int64" + } + ], + "responses": { + "200": { + "description": "OK", + "schema": { + "type": "string" + } + }, + "201": { + "description": "Created" + }, + "401": { + "description": "Unauthorized" + }, + "403": { + "description": "Forbidden" + }, + "404": { + "description": "Not Found" + } + }, + "security": [ + { + "X-CAP-API-AUTH-ORG-ID": [ + "global" + ] + }, + { + "X-CAP-API-AUTH-ENTITY-ID": [ + "global" + ] + }, + { + "X-CAP-ENTITY-CODE": [ + "global" + ] + }, + { + "X-CAP-ENTITY-ID": [ + "global" + ] + } + ] + } + }, + "/orchestrator/payments/webhooks/eghl/transaction": { + "post": { + "tags": [ + "eghl-call-back-resource" + ], + "summary": "callback", + "operationId": "callbackUsingPOST", + "consumes": [ + "application/json" + ], + "produces": [ + "*/*" + ], + "parameters": [ + { + "in": "body", + "name": "callBackData", + "description": "callBackData", + "required": true, + "schema": { + "type": "string" + } + } + ], + "responses": { + "200": { + "description": "OK", + "schema": { + "type": "string" + } + }, + "201": { + "description": "Created" + }, + "401": { + "description": "Unauthorized" + }, + "403": { + "description": "Forbidden" + }, + "404": { + "description": "Not Found" + } + }, + "security": [ + { + "X-CAP-API-AUTH-ORG-ID": [ + "global" + ] + }, + { + "X-CAP-API-AUTH-ENTITY-ID": [ + "global" + ] + }, + { + "X-CAP-ENTITY-CODE": [ + "global" + ] + }, + { + "X-CAP-ENTITY-ID": [ + "global" + ] + } + ] + } + }, + "/ping": { + "get": { + "tags": [ + "health-check-resource" + ], + "summary": "application health check", + "operationId": "healthCheckUsingGET", + "produces": [ + "*/*" + ], + "responses": { + "200": { + "description": "OK", + "schema": { + "type": "string" + } + }, + "401": { + "description": "Unauthorized" + }, + "403": { + "description": "Forbidden" + }, + "404": { + "description": "Not Found" + } + }, + "security": [ + { + "X-CAP-API-AUTH-ORG-ID": [ + "global" + ] + }, + { + "X-CAP-API-AUTH-ENTITY-ID": [ + "global" + ] + }, + { + "X-CAP-ENTITY-CODE": [ + "global" + ] + }, + { + "X-CAP-ENTITY-ID": [ + "global" + ] + } + ] + } + }, + "/v1/workflow": { + "get": { + "tags": [ + "admin-workflow-resource" + ], + "summary": "get", + "operationId": "getUsingGET", + "produces": [ + "*/*" + ], + "parameters": [ + { + "name": "allVersions", + "in": "query", + "required": false, + "type": "boolean" + }, + { + "name": "name", + "in": "query", + "required": false, + "type": "string" + }, + { + "name": "version", + "in": "query", + "required": false, + "type": "string" + } + ], + "responses": { + "200": { + "description": "OK", + "schema": { + "$ref": "#/definitions/GetEntityResponse" + } + }, + "401": { + "description": "Unauthorized" + }, + "403": { + "description": "Forbidden" + }, + "404": { + "description": "Not Found" + } + }, + "security": [ + { + "X-CAP-API-AUTH-ORG-ID": [ + "global" + ] + }, + { + "X-CAP-API-AUTH-ENTITY-ID": [ + "global" + ] + }, + { + "X-CAP-ENTITY-CODE": [ + "global" + ] + }, + { + "X-CAP-ENTITY-ID": [ + "global" + ] + } + ] + }, + "post": { + "tags": [ + "admin-workflow-resource" + ], + "summary": "create", + "operationId": "createUsingPOST", + "consumes": [ + "application/json" + ], + "produces": [ + "*/*" + ], + "parameters": [ + { + "in": "body", + "name": "workflowProcess", + "description": "workflowProcess", + "required": true, + "schema": { + "$ref": "#/definitions/WorkflowProcess" + } + } + ], + "responses": { + "200": { + "description": "OK", + "schema": { + "$ref": "#/definitions/SingleResponse«WorkFlowCreationResponse»" + } + }, + "201": { + "description": "Created" + }, + "401": { + "description": "Unauthorized" + }, + "403": { + "description": "Forbidden" + }, + "404": { + "description": "Not Found" + } + }, + "security": [ + { + "X-CAP-API-AUTH-ORG-ID": [ + "global" + ] + }, + { + "X-CAP-API-AUTH-ENTITY-ID": [ + "global" + ] + }, + { + "X-CAP-ENTITY-CODE": [ + "global" + ] + }, + { + "X-CAP-ENTITY-ID": [ + "global" + ] + } + ] + } + }, + "/v1/workflow/promotion": { + "put": { + "tags": [ + "admin-workflow-resource" + ], + "summary": "promoteWorkFlow", + "operationId": "promoteWorkFlowUsingPUT", + "consumes": [ + "application/json" + ], + "produces": [ + "*/*" + ], + "parameters": [ + { + "in": "body", + "name": "workFlowPromote", + "description": "workFlowPromote", + "required": true, + "schema": { + "$ref": "#/definitions/WorkFlowPromote" + } + } + ], + "responses": { + "200": { + "description": "OK", + "schema": { + "$ref": "#/definitions/UpdatedEntityResponse" + } + }, + "201": { + "description": "Created" + }, + "401": { + "description": "Unauthorized" + }, + "403": { + "description": "Forbidden" + }, + "404": { + "description": "Not Found" + } + }, + "security": [ + { + "X-CAP-API-AUTH-ORG-ID": [ + "global" + ] + }, + { + "X-CAP-API-AUTH-ENTITY-ID": [ + "global" + ] + }, + { + "X-CAP-ENTITY-CODE": [ + "global" + ] + }, + { + "X-CAP-ENTITY-ID": [ + "global" + ] + } + ] + } + }, + "/v1/workflow/psp/reconciliation/capture": { + "post": { + "tags": [ + "eghl-reconciliation" + ], + "summary": "reconciliationCapture", + "operationId": "reconciliationCaptureUsingPOST", + "consumes": [ + "application/json" + ], + "produces": [ + "*/*" + ], + "responses": { + "200": { + "description": "OK", + "schema": { + "type": "string" + } + }, + "201": { + "description": "Created" + }, + "401": { + "description": "Unauthorized" + }, + "403": { + "description": "Forbidden" + }, + "404": { + "description": "Not Found" + } + }, + "security": [ + { + "X-CAP-API-AUTH-ORG-ID": [ + "global" + ] + }, + { + "X-CAP-API-AUTH-ENTITY-ID": [ + "global" + ] + }, + { + "X-CAP-ENTITY-CODE": [ + "global" + ] + }, + { + "X-CAP-ENTITY-ID": [ + "global" + ] + } + ] + } + }, + "/v1/workflow/psp/reconciliation/fuelling-reversal": { + "post": { + "tags": [ + "eghl-reconciliation" + ], + "summary": "reconciliationFuellingReversal", + "operationId": "reconciliationFuellingReversalUsingPOST", + "consumes": [ + "application/json" + ], + "produces": [ + "*/*" + ], + "responses": { + "200": { + "description": "OK", + "schema": { + "type": "string" + } + }, + "201": { + "description": "Created" + }, + "401": { + "description": "Unauthorized" + }, + "403": { + "description": "Forbidden" + }, + "404": { + "description": "Not Found" + } + }, + "security": [ + { + "X-CAP-API-AUTH-ORG-ID": [ + "global" + ] + }, + { + "X-CAP-API-AUTH-ENTITY-ID": [ + "global" + ] + }, + { + "X-CAP-ENTITY-CODE": [ + "global" + ] + }, + { + "X-CAP-ENTITY-ID": [ + "global" + ] + } + ] + } + }, + "/v1/workflow/psp/reconciliation/registration-reversal": { + "post": { + "tags": [ + "eghl-reconciliation" + ], + "summary": "reconciliationRegistrationReversal", + "operationId": "reconciliationRegistrationReversalUsingPOST", + "consumes": [ + "application/json" + ], + "produces": [ + "*/*" + ], + "responses": { + "200": { + "description": "OK", + "schema": { + "type": "string" + } + }, + "201": { + "description": "Created" + }, + "401": { + "description": "Unauthorized" + }, + "403": { + "description": "Forbidden" + }, + "404": { + "description": "Not Found" + } + }, + "security": [ + { + "X-CAP-API-AUTH-ORG-ID": [ + "global" + ] + }, + { + "X-CAP-API-AUTH-ENTITY-ID": [ + "global" + ] + }, + { + "X-CAP-ENTITY-CODE": [ + "global" + ] + }, + { + "X-CAP-ENTITY-ID": [ + "global" + ] + } + ] + } + }, + "/v1/workflow/shell/billing/evaluateOffer": { + "post": { + "tags": [ + "payments-resource" + ], + "summary": "evaluateOffers", + "operationId": "evaluateOffersUsingPOST", + "consumes": [ + "application/json" + ], + "produces": [ + "*/*" + ], + "parameters": [ + { + "in": "body", + "name": "completeRequest", + "description": "completeRequest", + "required": true, + "schema": { + "$ref": "#/definitions/OfferEvaluationReq" + } + } + ], + "responses": { + "200": { + "description": "OK", + "schema": { + "$ref": "#/definitions/SingleResponse«OfferEvaluation»" + } + }, + "201": { + "description": "Created" + }, + "401": { + "description": "Unauthorized" + }, + "403": { + "description": "Forbidden" + }, + "404": { + "description": "Not Found" + } + }, + "security": [ + { + "X-CAP-API-AUTH-ORG-ID": [ + "global" + ] + }, + { + "X-CAP-API-AUTH-ENTITY-ID": [ + "global" + ] + }, + { + "X-CAP-ENTITY-CODE": [ + "global" + ] + }, + { + "X-CAP-ENTITY-ID": [ + "global" + ] + } + ] + } + }, + "/v1/workflow/shell/billing/transactionAdd": { + "post": { + "tags": [ + "payments-resource" + ], + "summary": "txnAdd", + "operationId": "txnAddUsingPOST", + "consumes": [ + "application/json" + ], + "produces": [ + "*/*" + ], + "parameters": [ + { + "in": "body", + "name": "transactionAddRO", + "description": "transactionAddRO", + "required": true, + "schema": { + "$ref": "#/definitions/TransactionAddRO" + } + } + ], + "responses": { + "200": { + "description": "OK", + "schema": { + "$ref": "#/definitions/TransactionAddResponse" + } + }, + "201": { + "description": "Created" + }, + "401": { + "description": "Unauthorized" + }, + "403": { + "description": "Forbidden" + }, + "404": { + "description": "Not Found" + } + }, + "security": [ + { + "X-CAP-API-AUTH-ORG-ID": [ + "global" + ] + }, + { + "X-CAP-API-AUTH-ENTITY-ID": [ + "global" + ] + }, + { + "X-CAP-ENTITY-CODE": [ + "global" + ] + }, + { + "X-CAP-ENTITY-ID": [ + "global" + ] + } + ] + } + }, + "/v3/api-docs": { + "get": { + "tags": [ + "open-api-web-mvc-resource" + ], + "summary": "openapiJson", + "operationId": "openapiJsonUsingGET", + "produces": [ + "application/json" + ], + "parameters": [ + { + "name": "apiDocsUrl", + "in": "query", + "description": "apiDocsUrl", + "required": false, + "type": "string" + }, + { + "name": "country", + "in": "query", + "required": false, + "type": "string" + }, + { + "name": "displayCountry", + "in": "query", + "required": false, + "type": "string" + }, + { + "name": "displayLanguage", + "in": "query", + "required": false, + "type": "string" + }, + { + "name": "displayName", + "in": "query", + "required": false, + "type": "string" + }, + { + "name": "displayScript", + "in": "query", + "required": false, + "type": "string" + }, + { + "name": "displayVariant", + "in": "query", + "required": false, + "type": "string" + }, + { + "name": "extensionKeys", + "in": "query", + "required": false, + "type": "array", + "items": { + "type": "string" + }, + "collectionFormat": "multi" + }, + { + "name": "ISO3Country", + "in": "query", + "required": false, + "type": "string" + }, + { + "name": "ISO3Language", + "in": "query", + "required": false, + "type": "string" + }, + { + "name": "language", + "in": "query", + "required": false, + "type": "string" + }, + { + "name": "script", + "in": "query", + "required": false, + "type": "string" + }, + { + "name": "unicodeLocaleAttributes", + "in": "query", + "required": false, + "type": "array", + "items": { + "type": "string" + }, + "collectionFormat": "multi" + }, + { + "name": "unicodeLocaleKeys", + "in": "query", + "required": false, + "type": "array", + "items": { + "type": "string" + }, + "collectionFormat": "multi" + }, + { + "name": "variant", + "in": "query", + "required": false, + "type": "string" + } + ], + "responses": { + "200": { + "description": "OK", + "schema": { + "type": "string" + } + }, + "401": { + "description": "Unauthorized" + }, + "403": { + "description": "Forbidden" + }, + "404": { + "description": "Not Found" + } + }, + "security": [ + { + "X-CAP-API-AUTH-ORG-ID": [ + "global" + ] + }, + { + "X-CAP-API-AUTH-ENTITY-ID": [ + "global" + ] + }, + { + "X-CAP-ENTITY-CODE": [ + "global" + ] + }, + { + "X-CAP-ENTITY-ID": [ + "global" + ] + } + ] + } + }, + "/v3/api-docs.yaml": { + "get": { + "tags": [ + "open-api-web-mvc-resource" + ], + "summary": "openapiYaml", + "operationId": "openapiYamlUsingGET", + "produces": [ + "application/vnd.oai.openapi" + ], + "parameters": [ + { + "name": "apiDocsUrl", + "in": "query", + "description": "apiDocsUrl", + "required": false, + "type": "string" + }, + { + "name": "country", + "in": "query", + "required": false, + "type": "string" + }, + { + "name": "displayCountry", + "in": "query", + "required": false, + "type": "string" + }, + { + "name": "displayLanguage", + "in": "query", + "required": false, + "type": "string" + }, + { + "name": "displayName", + "in": "query", + "required": false, + "type": "string" + }, + { + "name": "displayScript", + "in": "query", + "required": false, + "type": "string" + }, + { + "name": "displayVariant", + "in": "query", + "required": false, + "type": "string" + }, + { + "name": "extensionKeys", + "in": "query", + "required": false, + "type": "array", + "items": { + "type": "string" + }, + "collectionFormat": "multi" + }, + { + "name": "ISO3Country", + "in": "query", + "required": false, + "type": "string" + }, + { + "name": "ISO3Language", + "in": "query", + "required": false, + "type": "string" + }, + { + "name": "language", + "in": "query", + "required": false, + "type": "string" + }, + { + "name": "script", + "in": "query", + "required": false, + "type": "string" + }, + { + "name": "unicodeLocaleAttributes", + "in": "query", + "required": false, + "type": "array", + "items": { + "type": "string" + }, + "collectionFormat": "multi" + }, + { + "name": "unicodeLocaleKeys", + "in": "query", + "required": false, + "type": "array", + "items": { + "type": "string" + }, + "collectionFormat": "multi" + }, + { + "name": "variant", + "in": "query", + "required": false, + "type": "string" + } + ], + "responses": { + "200": { + "description": "OK", + "schema": { + "type": "string" + } + }, + "401": { + "description": "Unauthorized" + }, + "403": { + "description": "Forbidden" + }, + "404": { + "description": "Not Found" + } + }, + "security": [ + { + "X-CAP-API-AUTH-ORG-ID": [ + "global" + ] + }, + { + "X-CAP-API-AUTH-ENTITY-ID": [ + "global" + ] + }, + { + "X-CAP-ENTITY-CODE": [ + "global" + ] + }, + { + "X-CAP-ENTITY-ID": [ + "global" + ] + } + ] + } + }, + "/v3/api-docs/swagger-config": { + "get": { + "tags": [ + "swagger-config-resource" + ], + "summary": "openapiJson", + "operationId": "openapiJsonUsingGET_1", + "produces": [ + "application/json" + ], + "responses": { + "200": { + "description": "OK", + "schema": { + "type": "object" + } + }, + "401": { + "description": "Unauthorized" + }, + "403": { + "description": "Forbidden" + }, + "404": { + "description": "Not Found" + } + }, + "security": [ + { + "X-CAP-API-AUTH-ORG-ID": [ + "global" + ] + }, + { + "X-CAP-API-AUTH-ENTITY-ID": [ + "global" + ] + }, + { + "X-CAP-ENTITY-CODE": [ + "global" + ] + }, + { + "X-CAP-ENTITY-ID": [ + "global" + ] + } + ] + } + } + }, + "securityDefinitions": { + "X-CAP-API-AUTH-ENTITY-ID": { + "type": "apiKey", + "name": "X-CAP-API-AUTH-ENTITY-ID", + "in": "header" + }, + "X-CAP-API-AUTH-ORG-ID": { + "type": "apiKey", + "name": "X-CAP-API-AUTH-ORG-ID", + "in": "header" + }, + "X-CAP-ENTITY-CODE": { + "type": "apiKey", + "name": "X-CAP-ENTITY-CODE", + "in": "header" + }, + "X-CAP-ENTITY-ID": { + "type": "apiKey", + "name": "X-CAP-ENTITY-ID", + "in": "header" + } + }, + "definitions": { + "ActionInput": { + "type": "object", + "properties": { + "actionName": { + "type": "string" + }, + "brand": { + "type": "string", + "enum": [ + "SHELL" + ] + }, + "customerId": { + "type": "integer", + "format": "int64" + }, + "customerInfo": { + "$ref": "#/definitions/CustomerInfo" + }, + "entityCode": { + "type": "string" + }, + "entityId": { + "type": "integer", + "format": "int64" + }, + "input": { + "type": "object" + }, + "merchantIDStrategy": { + "type": "string", + "enum": [ + "ORG_LEVEL", + "PER_STORE" + ] + }, + "orgId": { + "type": "integer", + "format": "int64" + }, + "processInstanceId": { + "type": "string" + }, + "resetStepOnFailure": { + "type": "boolean" + }, + "rollbackOnFailure": { + "type": "boolean" + }, + "useCase": { + "type": "string", + "enum": [ + "CARD_REGISTRATION", + "FUELING", + "NON" + ] + }, + "version": { + "type": "string" + }, + "workFlowName": { + "type": "string" + } + }, + "title": "ActionInput" + }, + "AppTransactionStatusResponse": { + "type": "object", + "properties": { + "billingAmount": { + "type": "string" + }, + "billingLines": { + "type": "array", + "items": { + "type": "string" + } + }, + "customerId": { + "type": "integer", + "format": "int64" + }, + "digitalCard": { + "type": "string" + }, + "errors": { + "type": "array", + "items": { + "$ref": "#/definitions/StatusCode" + } + }, + "maskedCard": { + "type": "string" + }, + "mop": { + "type": "string" + }, + "mopName": { + "type": "string" + }, + "paymentId": { + "type": "string" + }, + "pointsAllocated": { + "type": "string" + }, + "preAuthAmount": { + "type": "string" + }, + "processInstanceId": { + "type": "string" + }, + "pspReferenceNumber": { + "type": "string" + }, + "pumpActivateTime": { + "type": "string" + }, + "pumpNumber": { + "type": "string" + }, + "pumpReserveTime": { + "type": "string" + }, + "stationId": { + "type": "string" + }, + "transactionState": { + "type": "string", + "enum": [ + "BILLING_IN_PROGRESS", + "BILL_GENERATED", + "CARD_REGISTERED", + "CARD_REGISTER_IN_PROGRESS", + "FUELING_CANCELLED_BY_CUSTOMER", + "FUELING_CANCELLED_BY_STATION", + "IN_PROGRESS", + "PSP_AUTH_FAIL", + "PUMP_ACTIVATION_FAIL", + "PUMP_ACTIVATION_SUCCESS", + "PUMP_RESERVE_FAIL", + "PUMP_RESERVE_SUCCESS", + "TXN_STATE_UNKNOWN" + ] + }, + "violations": { + "type": "array", + "items": { + "$ref": "#/definitions/Violation" + } + } + }, + "title": "AppTransactionStatusResponse" + }, + "ApplicableVoucher": { + "type": "object", + "properties": { + "additionalVoucherInfo": { + "type": "string" + }, + "expiryDate": { + "type": "string" + }, + "products": { + "type": "array", + "items": { + "$ref": "#/definitions/Product" + } + }, + "promotionType": { + "type": "string" + }, + "referenceID": { + "type": "string" + }, + "voucherCode": { + "type": "string" + }, + "voucherType": { + "type": "string" + }, + "voucherValue": { + "type": "number" + } + }, + "title": "ApplicableVoucher" + }, + "ApplicableVoucherReq": { + "type": "object", + "properties": { + "additionVoucherInfo": { + "type": "string" + }, + "expiryDate": { + "type": "string", + "format": "date-time" + }, + "products": { + "type": "array", + "items": { + "$ref": "#/definitions/Product" + } + }, + "promotionType": { + "type": "string" + }, + "referenceID": { + "type": "string" + }, + "voucherCode": { + "type": "string" + }, + "voucherType": { + "type": "string" + }, + "voucherValue": { + "type": "string" + } + }, + "title": "ApplicableVoucherReq" + }, + "ApplicableVoucherRes": { + "type": "object", + "properties": { + "additionalVoucherInfo": { + "type": "string" + }, + "expiryDate": { + "type": "string" + }, + "products": { + "type": "array", + "items": { + "$ref": "#/definitions/Product" + } + }, + "promotionType": { + "type": "string" + }, + "referenceID": { + "type": "string" + }, + "voucherCode": { + "type": "string" + }, + "voucherType": { + "type": "string" + }, + "voucherValue": { + "type": "number" + } + }, + "title": "ApplicableVoucherRes" + }, + "Authorization": { + "type": "object", + "properties": { + "approvalCode": { + "type": "string" + }, + "batch": { + "type": "string" + }, + "couponCode": { + "type": "string" + }, + "coupons": { + "type": "string" + }, + "merchantName": { + "type": "string" + }, + "siteAddress": { + "type": "string" + }, + "siteName": { + "type": "string" + }, + "stan": { + "type": "string" + }, + "terminalID": { + "type": "string" + } + }, + "title": "Authorization" + }, + "CancelRO": { + "type": "object", + "properties": { + "mobilePaymentData": { + "$ref": "#/definitions/MobilePaymentData" + }, + "requestData": { + "$ref": "#/definitions/RequestData" + } + }, + "title": "CancelRO" + }, + "CancelRequest": { + "type": "object", + "properties": { + "customerID": { + "type": "string" + }, + "paymentID": { + "type": "string" + } + }, + "title": "CancelRequest" + }, + "CancelResponse": { + "type": "object", + "properties": { + "errors": { + "type": "array", + "items": { + "$ref": "#/definitions/StatusCode" + } + }, + "paymentId": { + "type": "string" + }, + "success": { + "type": "boolean" + }, + "warnings": { + "type": "array", + "items": { + "$ref": "#/definitions/StatusCode" + } + } + }, + "title": "CancelResponse" + }, + "CardValue": { + "type": "object", + "properties": { + "cardCircuit": { + "type": "string" + }, + "cardEntryMode": { + "type": "string" + }, + "cardID": { + "type": "string" + }, + "inString": { + "type": "string" + }, + "loyaltyExceptionIndicator": { + "type": "integer", + "format": "int32" + }, + "methodOfPaymentID": { + "type": "string" + }, + "methodOfPaymentName": { + "type": "string" + }, + "pointsRedeemed": { + "type": "integer", + "format": "int32" + }, + "totalAmount": { + "type": "string" + }, + "trackers": { + "type": "array", + "items": { + "$ref": "#/definitions/Tracker" + } + } + }, + "title": "CardValue" + }, + "CustomerData": { + "type": "object", + "properties": { + "customerDataType": { + "type": "string" + }, + "customerDataValue": { + "type": "string" + }, + "loyaltyType": { + "type": "string" + }, + "pointsRedeemed": { + "type": "number" + } + }, + "title": "CustomerData" + }, + "CustomerInfo": { + "type": "object", + "properties": { + "accountId": { + "type": "string" + }, + "customerId": { + "type": "integer", + "format": "int64" + }, + "identifierName": { + "type": "string", + "enum": [ + "cardnumber", + "customerId", + "email", + "externalId", + "mobile", + "wechat" + ] + }, + "identifierValue": { + "type": "string" + }, + "source": { + "type": "string" + } + }, + "title": "CustomerInfo" + }, + "ExternalAPIErrorCodeMapping": { + "type": "object", + "properties": { + "apiName": { + "type": "string" + }, + "brand": { + "type": "string", + "enum": [ + "SHELL" + ] + }, + "errorNumber": { + "type": "integer", + "format": "int32" + }, + "otaErrorNumber": { + "type": "string" + }, + "retryable": { + "type": "boolean" + }, + "useCase": { + "type": "string", + "enum": [ + "CARD_REGISTRATION", + "FUELING", + "NON" + ] + } + }, + "title": "ExternalAPIErrorCodeMapping" + }, + "ExternalAPIErrorCodeMappingDto": { + "type": "object", + "properties": { + "apiName": { + "type": "string" + }, + "brand": { + "type": "string", + "enum": [ + "SHELL" + ] + }, + "errorNumber": { + "type": "integer", + "format": "int32" + }, + "id": { + "type": "integer", + "format": "int64" + }, + "otaErrorNumber": { + "type": "string" + }, + "retryable": { + "type": "boolean" + }, + "useCase": { + "type": "string", + "enum": [ + "CARD_REGISTRATION", + "FUELING", + "NON" + ] + } + }, + "title": "ExternalAPIErrorCodeMappingDto" + }, + "ExternalAPIErrorCodeMappingResponse": { + "type": "object", + "properties": { + "apiName": { + "type": "string" + }, + "brand": { + "type": "string", + "enum": [ + "SHELL" + ] + }, + "errorCode": { + "type": "integer", + "format": "int32" + }, + "otaErrorNumber": { + "type": "string" + }, + "retryable": { + "type": "boolean" + }, + "useCase": { + "type": "string", + "enum": [ + "CARD_REGISTRATION", + "FUELING", + "NON" + ] + } + }, + "title": "ExternalAPIErrorCodeMappingResponse" + }, + "GetEntityResponse": { + "type": "object", + "properties": { + "errors": { + "type": "array", + "items": { + "$ref": "#/definitions/StatusCode" + } + }, + "violations": { + "type": "array", + "items": { + "$ref": "#/definitions/Violation" + } + }, + "warnings": { + "type": "array", + "items": { + "$ref": "#/definitions/StatusCode" + } + }, + "workflowMeta": { + "type": "array", + "items": { + "$ref": "#/definitions/OrgWorkflowMetaDto" + } + } + }, + "title": "GetEntityResponse" + }, + "HashingSupportResponse": { + "type": "object", + "properties": { + "hash": { + "type": "string" + }, + "success": { + "type": "boolean" + } + }, + "title": "HashingSupportResponse" + }, + "IntermediateCatchEvent": { + "type": "object", + "properties": { + "intermediateCatchEventType": { + "type": "string", + "enum": [ + "DELAYED_TIMER" + ] + }, + "properties": { + "type": "object", + "additionalProperties": { + "type": "string" + } + } + }, + "title": "IntermediateCatchEvent" + }, + "LoyaltyDetails": { + "type": "object", + "properties": { + "loyaltyPAN": { + "type": "string" + }, + "loyaltyType": { + "type": "string" + }, + "methodOfPaymentID": { + "type": "string" + }, + "methodOfPaymentName": { + "type": "string" + }, + "pointsRedeemed": { + "type": "integer", + "format": "int32" + }, + "totalAmount": { + "type": "number" + }, + "trackers": { + "type": "array", + "items": { + "$ref": "#/definitions/Tracker" + } + } + }, + "title": "LoyaltyDetails" + }, + "LoyaltyOffer": { + "type": "object", + "properties": { + "loyaltyOfferDescription": { + "type": "string" + }, + "loyaltyOfferID": { + "type": "string" + }, + "promotionType": { + "type": "string", + "enum": [ + "Cart", + "lineitem" + ] + }, + "referenceID": { + "type": "string" + } + }, + "title": "LoyaltyOffer" + }, + "Message": { + "type": "object", + "properties": { + "cashierMessage": { + "type": "string" + } + }, + "title": "Message" + }, + "MobilePaymentData": { + "type": "object", + "properties": { + "acquirerID": { + "type": "string" + }, + "globalRetailSiteID": { + "type": "string" + }, + "loyaltyDetails": { + "type": "array", + "items": { + "$ref": "#/definitions/LoyaltyDetails" + } + }, + "loyaltyExceptionIndicator": { + "type": "integer", + "format": "int32" + }, + "merchantID": { + "type": "string" + }, + "methodOfPaymentID": { + "type": "string" + }, + "methodOfPaymentName": { + "type": "string" + }, + "paymentData": { + "type": "string" + }, + "paymentServiceProvider": { + "type": "string" + }, + "pumpNumber": { + "type": "integer", + "format": "int32" + }, + "totalAmount": { + "type": "number" + } + }, + "title": "MobilePaymentData" + }, + "MobileResponseBody«PreAuthorizeStep»": { + "type": "object", + "properties": { + "data": { + "$ref": "#/definitions/PreAuthorizeStep" + }, + "errors": { + "type": "array", + "items": { + "$ref": "#/definitions/StatusCode" + } + }, + "processInstanceId": { + "type": "string" + }, + "success": { + "type": "boolean" + }, + "violations": { + "type": "array", + "items": { + "$ref": "#/definitions/Violation" + } + }, + "warnings": { + "type": "array", + "items": { + "$ref": "#/definitions/StatusCode" + } + } + }, + "title": "MobileResponseBody«PreAuthorizeStep»" + }, + "MobileResponseBody«PumpReserve»": { + "type": "object", + "properties": { + "data": { + "$ref": "#/definitions/PumpReserve" + }, + "errors": { + "type": "array", + "items": { + "$ref": "#/definitions/StatusCode" + } + }, + "processInstanceId": { + "type": "string" + }, + "success": { + "type": "boolean" + }, + "violations": { + "type": "array", + "items": { + "$ref": "#/definitions/Violation" + } + }, + "warnings": { + "type": "array", + "items": { + "$ref": "#/definitions/StatusCode" + } + } + }, + "title": "MobileResponseBody«PumpReserve»" + }, + "MobileResponseBody«TokenizeRO»": { + "type": "object", + "properties": { + "data": { + "$ref": "#/definitions/TokenizeRO" + }, + "errors": { + "type": "array", + "items": { + "$ref": "#/definitions/StatusCode" + } + }, + "processInstanceId": { + "type": "string" + }, + "success": { + "type": "boolean" + }, + "violations": { + "type": "array", + "items": { + "$ref": "#/definitions/Violation" + } + }, + "warnings": { + "type": "array", + "items": { + "$ref": "#/definitions/StatusCode" + } + } + }, + "title": "MobileResponseBody«TokenizeRO»" + }, + "OfferEvaluation": { + "type": "object", + "properties": { + "applicableVouchers": { + "type": "array", + "items": { + "$ref": "#/definitions/ApplicableVoucher" + } + }, + "customerData": { + "type": "array", + "items": { + "$ref": "#/definitions/CustomerData" + } + }, + "messages": { + "$ref": "#/definitions/Message" + }, + "posData": { + "$ref": "#/definitions/PosData" + }, + "predictedTender": { + "$ref": "#/definitions/PredictedTender" + }, + "receipt": { + "$ref": "#/definitions/Receipt" + }, + "remainder": { + "type": "number" + }, + "requestData": { + "$ref": "#/definitions/RequestData" + }, + "responseData": { + "$ref": "#/definitions/ResponseData" + }, + "saleItems": { + "type": "array", + "items": { + "$ref": "#/definitions/SaleItem" + } + }, + "siteData": { + "$ref": "#/definitions/SiteData" + }, + "tenders": { + "type": "array", + "items": { + "$ref": "#/definitions/Tender" + } + }, + "totalAmount": { + "type": "number" + }, + "voucherCodesResult": { + "type": "array", + "items": { + "$ref": "#/definitions/VoucherCodesResult" + } + } + }, + "title": "OfferEvaluation" + }, + "OfferEvaluationReq": { + "type": "object", + "properties": { + "applicableVouchers": { + "type": "array", + "items": { + "$ref": "#/definitions/ApplicableVoucherReq" + } + }, + "customerData": { + "type": "array", + "items": { + "$ref": "#/definitions/CustomerData" + } + }, + "messages": { + "$ref": "#/definitions/Message" + }, + "posData": { + "$ref": "#/definitions/PosDataReq" + }, + "predictedTender": { + "$ref": "#/definitions/PredictedTender" + }, + "receipt": { + "$ref": "#/definitions/Receipt" + }, + "remainder": { + "type": "number" + }, + "requestData": { + "$ref": "#/definitions/RequestDataReq" + }, + "responseData": { + "$ref": "#/definitions/ResponseDataReq" + }, + "saleItems": { + "type": "array", + "items": { + "$ref": "#/definitions/SaleItemReq" + } + }, + "siteData": { + "$ref": "#/definitions/SiteDataReq" + }, + "tenders": { + "type": "array", + "items": { + "$ref": "#/definitions/TenderReq" + } + }, + "totalAmount": { + "type": "number" + }, + "voucherCodesResult": { + "type": "array", + "items": { + "$ref": "#/definitions/VoucherCodesResult" + } + } + }, + "title": "OfferEvaluationReq" + }, + "OfferEvaluationRes": { + "type": "object", + "properties": { + "applicableVouchers": { + "type": "array", + "items": { + "$ref": "#/definitions/ApplicableVoucherRes" + } + }, + "customerData": { + "type": "array", + "items": { + "$ref": "#/definitions/CustomerData" + } + }, + "messages": { + "$ref": "#/definitions/Message" + }, + "posData": { + "$ref": "#/definitions/PosDataRes" + }, + "predictedTender": { + "$ref": "#/definitions/PredictedTender" + }, + "receipt": { + "$ref": "#/definitions/Receipt" + }, + "remainder": { + "type": "number" + }, + "requestData": { + "$ref": "#/definitions/RequestDataRes" + }, + "responseData": { + "$ref": "#/definitions/ResponseDataRes" + }, + "saleItems": { + "type": "array", + "items": { + "$ref": "#/definitions/SaleItemRes" + } + }, + "siteData": { + "$ref": "#/definitions/SiteDataRes" + }, + "tenders": { + "type": "array", + "items": { + "$ref": "#/definitions/TenderRes" + } + }, + "totalAmount": { + "type": "number" + }, + "voucherCodesResult": { + "type": "array", + "items": { + "$ref": "#/definitions/VoucherCodesResult" + } + } + }, + "title": "OfferEvaluationRes" + }, + "OrgWorkflowMetaDto": { + "type": "object", + "properties": { + "autoUpdateTime": { + "type": "string", + "format": "date-time" + }, + "createdBy": { + "type": "integer", + "format": "int64" + }, + "createdOn": { + "type": "string", + "format": "date-time" + }, + "diffJson": { + "type": "string" + }, + "id": { + "type": "integer", + "format": "int64" + }, + "isActive": { + "type": "boolean" + }, + "isApproved": { + "type": "boolean" + }, + "isAsync": { + "type": "boolean" + }, + "isDefault": { + "type": "boolean" + }, + "merchantIdStrategy": { + "type": "string", + "enum": [ + "ORG_LEVEL", + "PER_STORE" + ] + }, + "orgId": { + "type": "integer", + "format": "int64" + }, + "processId": { + "type": "string" + }, + "promotedOn": { + "type": "string", + "format": "date-time" + }, + "useCase": { + "type": "string" + }, + "versionName": { + "type": "string" + }, + "workflowJson": { + "type": "string" + }, + "workflowName": { + "type": "string" + } + }, + "title": "OrgWorkflowMetaDto" + }, + "OriginalTransaction": { + "type": "object", + "properties": { + "approvalCode": { + "type": "string" + }, + "authorizationToken": { + "type": "string" + }, + "stan": { + "type": "string" + }, + "terminalBatch": { + "type": "string" + }, + "terminalID": { + "type": "string" + }, + "timeStamp": { + "type": "string", + "format": "date-time" + } + }, + "title": "OriginalTransaction" + }, + "PerformanceBo": { + "type": "object", + "properties": { + "count": { + "type": "integer", + "format": "int64" + }, + "failurePercentage": { + "type": "number" + } + }, + "title": "PerformanceBo" + }, + "PosData": { + "type": "object", + "properties": { + "LanguageCode": { + "type": "string" + }, + "posTimeStamp": { + "type": "string" + }, + "transactionNumber": { + "type": "string" + } + }, + "title": "PosData" + }, + "PosDataReq": { + "type": "object", + "properties": { + "actionCode": { + "type": "string" + }, + "actionCodeDescription": { + "type": "string" + }, + "clerkID": { + "type": "string" + }, + "originalSalePosTimeStamp": { + "type": "string" + }, + "posTimeStamp": { + "type": "string", + "format": "date-time" + }, + "pumpNumber": { + "type": "string" + }, + "terminalID": { + "type": "string" + }, + "transactionNumber": { + "type": "string" + } + }, + "title": "PosDataReq" + }, + "PosDataRes": { + "type": "object", + "properties": { + "LanguageCode": { + "type": "string" + }, + "posTimeStamp": { + "type": "string" + }, + "transactionNumber": { + "type": "string" + } + }, + "title": "PosDataRes" + }, + "PreAuthorizeStep": { + "type": "object", + "properties": { + "paymentId": { + "type": "string" + }, + "processInstanceId": { + "type": "string" + }, + "pspReferenceNumber": { + "type": "string" + } + }, + "title": "PreAuthorizeStep" + }, + "PredictedTender": { + "type": "object", + "properties": { + "acquirer": { + "type": "string" + }, + "amount": { + "type": "number" + }, + "methodOfPayment": { + "type": "string" + }, + "substractDiscountAmount": { + "type": "boolean" + } + }, + "title": "PredictedTender" + }, + "PriceAdjustment": { + "type": "object", + "properties": { + "additionalProductCode": { + "type": "string" + }, + "amount": { + "type": "number" + }, + "categoryCode": { + "type": "string" + }, + "loyaltyOfferID": { + "type": "string" + }, + "priceAdjustmentID": { + "type": "string" + }, + "priceAdjustmentType": { + "type": "string", + "enum": [ + "Coupon", + "Gift", + "Local Discount", + "Price Override", + "RealtimeOffer-A", + "RealtimeOffer-U", + "Voucher" + ] + }, + "promotionType": { + "type": "string" + }, + "quantity": { + "type": "number" + }, + "reason": { + "type": "string" + }, + "referenceID": { + "type": "string" + }, + "unitPrice": { + "type": "number" + } + }, + "title": "PriceAdjustment" + }, + "PriceAdjustmentReq": { + "type": "object", + "properties": { + "additionalProductCode": { + "type": "string" + }, + "amount": { + "type": "number" + }, + "categoryCode": { + "type": "string" + }, + "loyaltyOfferID": { + "type": "string" + }, + "netAmount": { + "type": "number" + }, + "originalAmount": { + "type": "number" + }, + "originalNetAmount": { + "type": "number" + }, + "priceAdjustmentID": { + "type": "string" + }, + "priceAdjustmentType": { + "type": "string", + "enum": [ + "Coupon", + "Gift", + "Local Discount", + "Price Override", + "RealtimeOffer-A", + "RealtimeOffer-U", + "Voucher" + ] + }, + "productCode": { + "type": "string" + }, + "promotionType": { + "type": "string" + }, + "quantity": { + "type": "number" + }, + "reason": { + "type": "string" + }, + "referenceID": { + "type": "string" + }, + "taxSplit": { + "type": "array", + "items": { + "$ref": "#/definitions/TaxSplit" + } + }, + "unitOfMeasure": { + "type": "string" + }, + "unitPrice": { + "type": "number" + }, + "vat": { + "type": "number" + } + }, + "title": "PriceAdjustmentReq" + }, + "PriceAdjustmentRes": { + "type": "object", + "properties": { + "additionalProductCode": { + "type": "string" + }, + "amount": { + "type": "number" + }, + "categoryCode": { + "type": "string" + }, + "loyaltyOfferID": { + "type": "string" + }, + "priceAdjustmentID": { + "type": "string" + }, + "priceAdjustmentType": { + "type": "string", + "enum": [ + "Coupon", + "Gift", + "Local Discount", + "Price Override", + "RealtimeOffer-A", + "RealtimeOffer-U", + "Voucher" + ] + }, + "promotionType": { + "type": "string" + }, + "quantity": { + "type": "number" + }, + "reason": { + "type": "string" + }, + "referenceID": { + "type": "string" + }, + "unitPrice": { + "type": "number" + } + }, + "title": "PriceAdjustmentRes" + }, + "Product": { + "type": "object", + "properties": { + "additionalProductCode": { + "type": "string" + }, + "additionalProductInfo": { + "type": "string" + }, + "categoryCode": { + "type": "string" + }, + "productCode": { + "type": "string" + }, + "subCategoryCode": { + "type": "string" + } + }, + "title": "Product" + }, + "PumpReserve": { + "type": "object", + "properties": { + "additionalFields": { + "type": "object", + "additionalProperties": { + "type": "string" + } + }, + "cardIdentifier": { + "type": "string" + }, + "currencyCode": { + "type": "string" + }, + "customerInfo": { + "$ref": "#/definitions/CustomerInfo" + }, + "languageCode": { + "type": "string" + }, + "merchantIdentifier": { + "type": "string" + }, + "paymentId": { + "type": "string" + }, + "preAuthAmount": { + "type": "string" + }, + "pspIdentifier": { + "type": "string", + "enum": [ + "2C2P", + "EGHL" + ] + }, + "pumpNumber": { + "type": "string" + }, + "siteId": { + "type": "string" + }, + "siteName": { + "type": "string" + } + }, + "title": "PumpReserve" + }, + "Receipt": { + "type": "object", + "properties": { + "receiptLines": { + "type": "array", + "items": { + "type": "string" + } + } + }, + "title": "Receipt" + }, + "RequestData": { + "type": "object", + "properties": { + "cartEvaluationID": { + "type": "string" + }, + "extCorrelationId": { + "type": "string" + }, + "payTokenID": { + "type": "string" + }, + "processInstanceId": { + "type": "string" + }, + "referenceNumber": { + "type": "string" + }, + "requestID": { + "type": "string" + }, + "requestType": { + "type": "string" + }, + "workstationID": { + "type": "string" + } + }, + "title": "RequestData" + }, + "RequestDataReq": { + "type": "object", + "properties": { + "actionCode": { + "type": "string" + }, + "actionCodeDescription": { + "type": "string" + }, + "cartEvaluationID": { + "type": "string" + }, + "countryCode": { + "type": "string" + }, + "extCorrelationId": { + "type": "string" + }, + "payTokenID": { + "type": "string" + }, + "paymentServiceProvider": { + "type": "string" + }, + "processInstanceId": { + "type": "string" + }, + "referenceNumber": { + "type": "string" + }, + "requestID": { + "type": "string" + }, + "requestType": { + "type": "string" + }, + "transactionNumber": { + "type": "string" + }, + "workstationID": { + "type": "string" + } + }, + "title": "RequestDataReq" + }, + "RequestDataRes": { + "type": "object", + "properties": { + "overallResult": { + "type": "string" + }, + "requestID": { + "type": "string" + } + }, + "title": "RequestDataRes" + }, + "ResponseData": { + "type": "object", + "properties": { + "actionCode": { + "type": "string" + }, + "actionCodeDescription": { + "type": "string" + }, + "cartEvaluationID": { + "type": "string" + }, + "extCorrelationID": { + "type": "string" + }, + "overallResult": { + "type": "string" + }, + "referenceNumber": { + "type": "string" + }, + "requestID": { + "type": "string" + }, + "requestType": { + "type": "string" + }, + "workstationID": { + "type": "string" + } + }, + "title": "ResponseData" + }, + "ResponseDataReq": { + "type": "object", + "properties": { + "actionCode": { + "type": "string" + }, + "actionCodeDescription": { + "type": "string" + }, + "cartEvaluationID": { + "type": "string" + }, + "extCorrelationID": { + "type": "string" + }, + "overallResult": { + "type": "string" + }, + "referenceNumber": { + "type": "string" + }, + "requestID": { + "type": "string" + }, + "requestType": { + "type": "string" + }, + "workstationID": { + "type": "string" + } + }, + "title": "ResponseDataReq" + }, + "ResponseDataRes": { + "type": "object", + "properties": { + "requestType": { + "type": "string" + } + }, + "title": "ResponseDataRes" + }, + "SaleItem": { + "type": "object", + "properties": { + "additionalProductCode": { + "type": "string" + }, + "additionalProductInfo": { + "type": "string" + }, + "amount": { + "type": "number" + }, + "categoryCode": { + "type": "string" + }, + "itemID": { + "type": "integer", + "format": "int32" + }, + "loyaltyOffers": { + "type": "array", + "items": { + "$ref": "#/definitions/LoyaltyOffer" + } + }, + "markDownIndicator": { + "type": "boolean" + }, + "originalAmount": { + "type": "number" + }, + "priceAdjustments": { + "type": "array", + "items": { + "$ref": "#/definitions/PriceAdjustment" + } + }, + "productCode": { + "type": "string" + }, + "quantity": { + "type": "number" + }, + "saleChannel": { + "type": "integer", + "format": "int32" + }, + "saleItemType": { + "type": "string" + }, + "subCategoryCode": { + "type": "string" + }, + "unitMeasure": { + "type": "string" + }, + "unitPrice": { + "type": "number" + }, + "vatRate": { + "type": "number" + } + }, + "title": "SaleItem" + }, + "SaleItemReq": { + "type": "object", + "properties": { + "LineNo": { + "type": "string" + }, + "additionalProductCode": { + "type": "string" + }, + "additionalProductInfo": { + "type": "string" + }, + "amount": { + "type": "number" + }, + "categoryCode": { + "type": "string" + }, + "loyaltyOffers": { + "type": "array", + "items": { + "$ref": "#/definitions/LoyaltyOffer" + } + }, + "markDownIndicator": { + "type": "boolean" + }, + "netAmount": { + "type": "number" + }, + "originalAmount": { + "type": "number" + }, + "originalNetAmount": { + "type": "number" + }, + "priceAdjustments": { + "type": "array", + "items": { + "$ref": "#/definitions/PriceAdjustmentReq" + } + }, + "productCode": { + "type": "string" + }, + "quantity": { + "type": "number" + }, + "saleChannel": { + "type": "string" + }, + "saleItemType": { + "type": "string" + }, + "taxAmount": { + "type": "number" + }, + "taxCode": { + "type": "string" + }, + "taxRate": { + "type": "number" + }, + "unitOfMeasure": { + "type": "string" + }, + "unitPrice": { + "type": "number" + }, + "vatRate": { + "type": "number" + } + }, + "title": "SaleItemReq" + }, + "SaleItemRes": { + "type": "object", + "properties": { + "additionalProductCode": { + "type": "string" + }, + "additionalProductInfo": { + "type": "string" + }, + "amount": { + "type": "number" + }, + "categoryCode": { + "type": "string" + }, + "itemID": { + "type": "integer", + "format": "int32" + }, + "loyaltyOffers": { + "type": "array", + "items": { + "$ref": "#/definitions/LoyaltyOffer" + } + }, + "markDownIndicator": { + "type": "boolean" + }, + "originalAmount": { + "type": "number" + }, + "priceAdjustments": { + "type": "array", + "items": { + "$ref": "#/definitions/PriceAdjustmentRes" + } + }, + "productCode": { + "type": "string" + }, + "quantity": { + "type": "number" + }, + "saleChannel": { + "type": "integer", + "format": "int32" + }, + "saleItemType": { + "type": "string" + }, + "subCategoryCode": { + "type": "string" + }, + "unitMeasure": { + "type": "string" + }, + "unitPrice": { + "type": "number" + }, + "vatRate": { + "type": "number" + } + }, + "title": "SaleItemRes" + }, + "SaleTransaction": { + "type": "object", + "properties": { + "authorization": { + "$ref": "#/definitions/Authorization" + }, + "coupons": { + "type": "array", + "items": { + "type": "string" + } + }, + "currency": { + "type": "string" + }, + "currencyCode": { + "type": "string" + }, + "extraDiscountAmount": { + "type": "number" + }, + "loyaltyPointAmount": { + "type": "integer", + "format": "int32" + }, + "merchantName": { + "type": "string" + }, + "netAmount": { + "type": "number" + }, + "siteAddress": { + "type": "string" + }, + "siteName": { + "type": "string" + }, + "taxReferenceNumber": { + "type": "string" + }, + "terminalID": { + "type": "string" + }, + "timeStamp": { + "type": "string" + }, + "totalAmount": { + "type": "number" + }, + "totalDiscountAmount": { + "type": "number" + }, + "totalTaxAmount": { + "type": "number" + }, + "transactionNumber": { + "type": "string" + } + }, + "title": "SaleTransaction" + }, + "ShellTransactionResponse": { + "type": "object", + "properties": { + "requestData": { + "$ref": "#/definitions/RequestDataRes" + }, + "responseData": { + "$ref": "#/definitions/ResponseDataRes" + } + }, + "title": "ShellTransactionResponse" + }, + "SingleResponse«ExternalAPIErrorCodeMappingResponse»": { + "type": "object", + "properties": { + "data": { + "$ref": "#/definitions/ExternalAPIErrorCodeMappingResponse" + }, + "errors": { + "type": "array", + "items": { + "$ref": "#/definitions/StatusCode" + } + }, + "processId": { + "type": "string" + }, + "violations": { + "type": "array", + "items": { + "$ref": "#/definitions/Violation" + } + }, + "warnings": { + "type": "array", + "items": { + "$ref": "#/definitions/StatusCode" + } + } + }, + "title": "SingleResponse«ExternalAPIErrorCodeMappingResponse»" + }, + "SingleResponse«List«UserTransactionBo»»": { + "type": "object", + "properties": { + "data": { + "type": "array", + "items": { + "$ref": "#/definitions/UserTransactionBo" + } + }, + "errors": { + "type": "array", + "items": { + "$ref": "#/definitions/StatusCode" + } + }, + "processId": { + "type": "string" + }, + "violations": { + "type": "array", + "items": { + "$ref": "#/definitions/Violation" + } + }, + "warnings": { + "type": "array", + "items": { + "$ref": "#/definitions/StatusCode" + } + } + }, + "title": "SingleResponse«List«UserTransactionBo»»" + }, + "SingleResponse«OfferEvaluation»": { + "type": "object", + "properties": { + "data": { + "$ref": "#/definitions/OfferEvaluationRes" + }, + "errors": { + "type": "array", + "items": { + "$ref": "#/definitions/StatusCode" + } + }, + "processId": { + "type": "string" + }, + "violations": { + "type": "array", + "items": { + "$ref": "#/definitions/Violation" + } + }, + "warnings": { + "type": "array", + "items": { + "$ref": "#/definitions/StatusCode" + } + } + }, + "title": "SingleResponse«OfferEvaluation»" + }, + "SingleResponse«TxnStatusBo»": { + "type": "object", + "properties": { + "data": { + "$ref": "#/definitions/TxnStatusBo" + }, + "errors": { + "type": "array", + "items": { + "$ref": "#/definitions/StatusCode" + } + }, + "processId": { + "type": "string" + }, + "violations": { + "type": "array", + "items": { + "$ref": "#/definitions/Violation" + } + }, + "warnings": { + "type": "array", + "items": { + "$ref": "#/definitions/StatusCode" + } + } + }, + "title": "SingleResponse«TxnStatusBo»" + }, + "SingleResponse«WorkFlowCreationResponse»": { + "type": "object", + "properties": { + "data": { + "$ref": "#/definitions/WorkFlowCreationResponse" + }, + "errors": { + "type": "array", + "items": { + "$ref": "#/definitions/StatusCode" + } + }, + "processId": { + "type": "string" + }, + "violations": { + "type": "array", + "items": { + "$ref": "#/definitions/Violation" + } + }, + "warnings": { + "type": "array", + "items": { + "$ref": "#/definitions/StatusCode" + } + } + }, + "title": "SingleResponse«WorkFlowCreationResponse»" + }, + "SiteData": { + "type": "object", + "properties": { + "countryCode": { + "type": "string" + }, + "siteID": { + "type": "string" + } + }, + "title": "SiteData" + }, + "SiteDataReq": { + "type": "object", + "properties": { + "countryCode": { + "type": "string" + }, + "siteId": { + "type": "string" + } + }, + "title": "SiteDataReq" + }, + "SiteDataRes": { + "type": "object", + "properties": { + "countryCode": { + "type": "string" + }, + "siteID": { + "type": "string" + } + }, + "title": "SiteDataRes" + }, + "StatResponse«Map«string,PerformanceBo»»": { + "type": "object", + "properties": { + "data": { + "type": "object", + "additionalProperties": { + "$ref": "#/definitions/PerformanceBo" + } + }, + "errors": { + "type": "array", + "items": { + "$ref": "#/definitions/StatusCode" + } + }, + "success": { + "type": "boolean" + }, + "violations": { + "type": "array", + "items": { + "$ref": "#/definitions/Violation" + } + }, + "warnings": { + "type": "array", + "items": { + "$ref": "#/definitions/StatusCode" + } + } + }, + "title": "StatResponse«Map«string,PerformanceBo»»" + }, + "StatusCode": { + "type": "object", + "properties": { + "code": { + "type": "integer", + "format": "int32" + }, + "isWarning": { + "type": "boolean" + }, + "message": { + "type": "string" + } + }, + "title": "StatusCode" + }, + "TaxSplit": { + "type": "object", + "properties": { + "additionalAmount": { + "type": "number" + }, + "amount": { + "type": "number" + }, + "code": { + "type": "string" + }, + "rate": { + "type": "number" + }, + "taxID": { + "type": "integer", + "format": "int32" + } + }, + "title": "TaxSplit" + }, + "Tender": { + "type": "object", + "properties": { + "acquirerID": { + "type": "string" + }, + "cashRedeemed": { + "type": "number" + }, + "currencyCode": { + "type": "string" + }, + "methodOfPayment": { + "type": "string" + }, + "methodOfPaymentID": { + "type": "string" + }, + "netTenderAmount": { + "type": "number" + }, + "pointsRedeemed": { + "type": "number" + }, + "substractDiscountAmount": { + "type": "boolean" + }, + "tenderID": { + "type": "integer", + "format": "int32" + }, + "totalAmount": { + "type": "number" + }, + "voucherRules": { + "type": "array", + "items": { + "$ref": "#/definitions/VoucherRule" + } + } + }, + "title": "Tender" + }, + "TenderReq": { + "type": "object", + "properties": { + "acquirerID": { + "type": "string" + }, + "methodOfPayment": { + "type": "string" + }, + "methodOfPaymentID": { + "type": "string" + }, + "netTenderAmount": { + "type": "string" + }, + "pointsRedeemed": { + "type": "string" + }, + "substractDiscountAmount": { + "type": "boolean" + }, + "tenderID": { + "type": "string" + }, + "totalAmount": { + "type": "string" + }, + "voucherRules": { + "type": "array", + "items": { + "$ref": "#/definitions/VoucherRuleReq" + } + } + }, + "title": "TenderReq" + }, + "TenderRes": { + "type": "object", + "properties": { + "acquirerID": { + "type": "string" + }, + "cashRedeemed": { + "type": "number" + }, + "currencyCode": { + "type": "string" + }, + "methodOfPayment": { + "type": "string" + }, + "methodOfPaymentID": { + "type": "string" + }, + "netTenderAmount": { + "type": "number" + }, + "pointsRedeemed": { + "type": "number" + }, + "substractDiscountAmount": { + "type": "boolean" + }, + "tenderID": { + "type": "integer", + "format": "int32" + }, + "totalAmount": { + "type": "number" + }, + "voucherRules": { + "type": "array", + "items": { + "$ref": "#/definitions/VoucherRuleRes" + } + } + }, + "title": "TenderRes" + }, + "Terminal": { + "type": "object", + "properties": { + "stan": { + "type": "string" + }, + "terminalBatch": { + "type": "string" + } + }, + "title": "Terminal" + }, + "TokenizeRO": { + "type": "object", + "properties": { + "additionalFields": { + "type": "object", + "additionalProperties": { + "type": "string" + } + }, + "currencyCode": { + "type": "string" + }, + "customerInfo": { + "$ref": "#/definitions/CustomerInfo" + }, + "merchantIdentifier": { + "type": "string" + }, + "paymentId": { + "type": "string" + }, + "pspIdentifier": { + "type": "string", + "enum": [ + "2C2P", + "EGHL" + ] + }, + "registrationAmount": { + "type": "string" + } + }, + "title": "TokenizeRO" + }, + "Tracker": { + "type": "object", + "properties": { + "trackerEarned": { + "type": "string" + }, + "trackerRedeemed": { + "type": "string" + }, + "trackerType": { + "type": "string" + }, + "trackerValue": { + "type": "string" + } + }, + "title": "Tracker" + }, + "TransactionAddRO": { + "type": "object", + "properties": { + "applicableVouchers": { + "type": "array", + "items": { + "$ref": "#/definitions/ApplicableVoucher" + } + }, + "billingNumber": { + "type": "string" + }, + "cardValues": { + "type": "array", + "items": { + "$ref": "#/definitions/CardValue" + } + }, + "customerData": { + "type": "array", + "items": { + "$ref": "#/definitions/CustomerData" + } + }, + "mobilePaymentData": { + "$ref": "#/definitions/MobilePaymentData" + }, + "originalTransaction": { + "$ref": "#/definitions/OriginalTransaction" + }, + "posData": { + "$ref": "#/definitions/PosData" + }, + "receipt": { + "$ref": "#/definitions/Receipt" + }, + "requestData": { + "$ref": "#/definitions/RequestData" + }, + "saleItems": { + "type": "array", + "items": { + "$ref": "#/definitions/SaleItem" + } + }, + "saleTransaction": { + "$ref": "#/definitions/SaleTransaction" + }, + "siteData": { + "$ref": "#/definitions/SiteData" + }, + "tenders": { + "type": "array", + "items": { + "$ref": "#/definitions/Tender" + } + }, + "terminal": { + "$ref": "#/definitions/Terminal" + }, + "totalAmount": { + "type": "number" + } + }, + "title": "TransactionAddRO" + }, + "TransactionAddResponse": { + "type": "object", + "properties": { + "shellResponse": { + "type": "array", + "items": { + "$ref": "#/definitions/ShellTransactionResponse" + } + } + }, + "title": "TransactionAddResponse" + }, + "TxnStatusBo": { + "type": "object", + "properties": { + "cardType": { + "type": "string" + }, + "currencyCode": { + "type": "string" + }, + "customerId": { + "type": "string" + }, + "digitalCard": { + "type": "string" + }, + "extCorrelationId": { + "type": "string" + }, + "finalStatus": { + "type": "string" + }, + "invoice": { + "type": "string" + }, + "languageCode": { + "type": "string" + }, + "maskedCard": { + "type": "string" + }, + "merchantId": { + "type": "string" + }, + "metaData": { + "type": "object", + "additionalProperties": { + "type": "object", + "additionalProperties": { + "type": "string" + } + } + }, + "methodOfPaymentId": { + "type": "string" + }, + "mopId": { + "type": "string" + }, + "mopName": { + "type": "string" + }, + "orgId": { + "type": "integer", + "format": "int64" + }, + "paymentId": { + "type": "string" + }, + "paymentProviderName": { + "type": "string" + }, + "preAuthAmount": { + "type": "string" + }, + "processInstanceId": { + "type": "string" + }, + "pumpNumber": { + "type": "string" + }, + "siteId": { + "type": "string" + }, + "siteName": { + "type": "string" + }, + "startTimestamp": { + "type": "string" + }, + "startTimestampOld": { + "type": "string" + }, + "status": { + "type": "string" + }, + "type": { + "type": "string" + }, + "workFlowName": { + "type": "string" + }, + "workFlowVersion": { + "type": "string" + }, + "fuelType": { + "type": "string" + }, + "fuelGrade": { + "type": "string" + }, + "isSubsidyRequested": { + "type": "boolean" + } + }, + "title": "TxnStatusBo" + }, + "UpdatedEntityResponse": { + "type": "object", + "properties": { + "errors": { + "type": "array", + "items": { + "$ref": "#/definitions/StatusCode" + } + }, + "success": { + "type": "boolean" + }, + "violations": { + "type": "array", + "items": { + "$ref": "#/definitions/Violation" + } + }, + "warnings": { + "type": "array", + "items": { + "$ref": "#/definitions/StatusCode" + } + } + }, + "title": "UpdatedEntityResponse" + }, + "UserTransactionBo": { + "type": "object", + "properties": { + "extCorrelationId": { + "type": "string" + }, + "id": { + "type": "integer", + "format": "int64" + }, + "invoice": { + "type": "string" + }, + "paymentId": { + "type": "string" + }, + "preAuthAmount": { + "type": "string" + }, + "pumpId": { + "type": "string" + }, + "siteId": { + "type": "string" + }, + "startTimestamp": { + "type": "string" + }, + "startTimestampOld": { + "type": "string", + "format": "date-time" + }, + "status": { + "type": "string" + }, + "type": { + "type": "string" + } + }, + "title": "UserTransactionBo" + }, + "Violation": { + "type": "object", + "properties": { + "fieldName": { + "type": "string" + }, + "invalidValue": { + "type": "object" + }, + "message": { + "type": "string" + } + }, + "title": "Violation" + }, + "VoucherCodesResult": { + "type": "object", + "properties": { + "actionCode": { + "type": "integer", + "format": "int32" + }, + "actionCodeDescription": { + "type": "string" + }, + "voucherCode": { + "type": "string" + } + }, + "title": "VoucherCodesResult" + }, + "VoucherRule": { + "type": "object", + "properties": { + "additionalVoucherInfo": { + "type": "string" + }, + "expiryDate": { + "type": "string" + }, + "products": { + "type": "array", + "items": { + "$ref": "#/definitions/Product" + } + }, + "promotionType": { + "type": "string" + }, + "referenceID": { + "type": "string" + }, + "voucherCode": { + "type": "string" + }, + "voucherQuantity": { + "type": "integer", + "format": "int32" + }, + "voucherType": { + "type": "string" + }, + "voucherValue": { + "type": "number" + } + }, + "title": "VoucherRule" + }, + "VoucherRuleReq": { + "type": "object", + "properties": { + "additionalVoucherInfo": { + "type": "string" + }, + "expiryDate": { + "type": "string", + "format": "date-time" + }, + "products": { + "type": "array", + "items": { + "$ref": "#/definitions/Product" + } + }, + "referenceId": { + "type": "string" + }, + "voucherCode": { + "type": "string" + }, + "voucherType": { + "type": "string" + }, + "voucherValue": { + "type": "number" + } + }, + "title": "VoucherRuleReq" + }, + "VoucherRuleRes": { + "type": "object", + "properties": { + "additionalVoucherInfo": { + "type": "string" + }, + "expiryDate": { + "type": "string" + }, + "products": { + "type": "array", + "items": { + "$ref": "#/definitions/Product" + } + }, + "promotionType": { + "type": "string" + }, + "referenceID": { + "type": "string" + }, + "voucherCode": { + "type": "string" + }, + "voucherQuantity": { + "type": "integer", + "format": "int32" + }, + "voucherType": { + "type": "string" + }, + "voucherValue": { + "type": "number" + } + }, + "title": "VoucherRuleRes" + }, + "WorkFlowCreationResponse": { + "type": "object", + "properties": { + "deploymentId": { + "type": "string" + }, + "version": { + "type": "string" + } + }, + "title": "WorkFlowCreationResponse" + }, + "WorkFlowPromote": { + "type": "object", + "properties": { + "usecase": { + "type": "string", + "enum": [ + "CARD_REGISTRATION", + "FUELING", + "NON" + ] + }, + "version": { + "type": "string" + }, + "workFlowName": { + "type": "string" + } + }, + "title": "WorkFlowPromote" + }, + "WorkflowInputAction": { + "type": "object", + "properties": { + "actionGroupType": { + "type": "string", + "enum": [ + "PARALLEL", + "SERIAL", + "XOR" + ] + }, + "connectBoundaryEvent": { + "type": "boolean" + }, + "delayTimeInRetrial": { + "type": "integer", + "format": "int32" + }, + "httpCallInputProperties": { + "$ref": "#/definitions/ActionInput" + }, + "httpCallInputPropertiesRollback": { + "$ref": "#/definitions/ActionInput" + }, + "intermediateCatchEvent": { + "$ref": "#/definitions/IntermediateCatchEvent" + }, + "isAsync": { + "type": "boolean" + }, + "name": { + "type": "string" + }, + "retrialCount": { + "type": "integer", + "format": "int32" + }, + "rollbackName": { + "type": "string" + }, + "rollbackType": { + "type": "string", + "enum": [ + "CCCaptureAction", + "addTransactionAction", + "authorizePaymentWithPsp", + "cardRegistrationTimedOutAction", + "confirmAuthWithPSPAction", + "customerLockAction", + "dummyAction", + "eghlHashGenerationAction", + "emptyAction", + "generatePaymentIdAction", + "invalid", + "oAuthHttpAction", + "offerEvaluationAction", + "publishNotificationAction", + "pumpAuthNotificationAction", + "pumpAuthReversalNotificationAction", + "pumpReserveTimedOutAction", + "releaseCustomerLockAction", + "saveCCardAction", + "tokenizationReversalWithPSPAction", + "txnAddNotificationAction", + "verifyAuthWithPSPAction" + ] + }, + "serialNumber": { + "type": "integer", + "format": "int32" + }, + "type": { + "type": "string", + "enum": [ + "CCCaptureAction", + "addTransactionAction", + "authorizePaymentWithPsp", + "cardRegistrationTimedOutAction", + "confirmAuthWithPSPAction", + "customerLockAction", + "dummyAction", + "eghlHashGenerationAction", + "emptyAction", + "generatePaymentIdAction", + "invalid", + "oAuthHttpAction", + "offerEvaluationAction", + "publishNotificationAction", + "pumpAuthNotificationAction", + "pumpAuthReversalNotificationAction", + "pumpReserveTimedOutAction", + "releaseCustomerLockAction", + "saveCCardAction", + "tokenizationReversalWithPSPAction", + "txnAddNotificationAction", + "verifyAuthWithPSPAction" + ] + } + }, + "title": "WorkflowInputAction" + }, + "WorkflowProcess": { + "type": "object", + "properties": { + "brand": { + "type": "string", + "enum": [ + "SHELL" + ] + }, + "countryCode": { + "type": "string" + }, + "isAsync": { + "type": "boolean" + }, + "merchantIDStrategy": { + "type": "string", + "enum": [ + "ORG_LEVEL", + "PER_STORE" + ] + }, + "name": { + "type": "string" + }, + "steps": { + "type": "array", + "items": { + "$ref": "#/definitions/WorkflowStep" + } + }, + "useCase": { + "type": "string", + "enum": [ + "CARD_REGISTRATION", + "FUELING", + "NON" + ] + } + }, + "title": "WorkflowProcess" + }, + "WorkflowStep": { + "type": "object", + "properties": { + "actions": { + "type": "array", + "items": { + "$ref": "#/definitions/WorkflowInputAction" + } + }, + "boundaryEventType": { + "type": "string", + "enum": [ + "DELAYED_TIMER" + ] + }, + "delayedTimeInMillis": { + "type": "integer", + "format": "int64" + }, + "maxWaitTimeInMillis": { + "type": "integer", + "format": "int32" + }, + "name": { + "type": "string" + }, + "serialNumber": { + "type": "integer", + "format": "int32" + }, + "startBoundaryEventActionList": { + "type": "array", + "items": { + "$ref": "#/definitions/WorkflowInputAction" + } + }, + "startUserStep": { + "type": "boolean" + } + }, + "title": "WorkflowStep" + }, + "_2c2pCallbackRequest": { + "type": "object", + "properties": { + "payload": { + "type": "string" + } + }, + "title": "_2c2pCallbackRequest" + } + } +} diff --git a/pom.xml b/pom.xml index 14183730254..c791aad4f99 100644 --- a/pom.xml +++ b/pom.xml @@ -9,7 +9,7 @@ swagger-codegen-project pom swagger-codegen-project - 2.2.2-SNAPSHOT + 2.2.2 https://github.com/swagger-api/swagger-codegen scm:git:git@github.com:swagger-api/swagger-codegen.git @@ -807,7 +807,7 @@ - 1.0.24-SNAPSHOT + 1.0.24 2.11.1 2.3.4 1.5.10 diff --git a/promotion-engine.json b/promotion-engine.json new file mode 100644 index 00000000000..49974b06e63 --- /dev/null +++ b/promotion-engine.json @@ -0,0 +1,5494 @@ +{ + "swagger": "2.0", + "info": { + "description": "Api Documentation", + "version": "1.0", + "title": "Api Documentation", + "termsOfService": "urn:tos", + "contact": {}, + "license": { + "name": "Apache 2.0", + "url": "http://www.apache.org/licenses/LICENSE-2.0" + } + }, + "host": "promotion-engine-api.crm-nightly-new.cc.capillarytech.com", + "basePath": "/", + "tags": [ + { + "name": "audit-log-resource", + "description": "Audit Log Resource" + }, + { + "name": "cart-evaluation-log-resource", + "description": "Cart Evaluation Log Resource" + }, + { + "name": "code-based-promotion-meta-resource", + "description": "Code Based Promotion Meta Resource" + }, + { + "name": "code-based-promotion-resource", + "description": "Code Based Promotion Resource" + }, + { + "name": "health-check-resource", + "description": "Health Check Resource" + }, + { + "name": "promotion-communication-resource", + "description": "Promotion Communication Resource" + }, + { + "name": "promotion-earning-management-resource", + "description": "Promotion Earning Management Resource" + }, + { + "name": "promotion-earning-resource", + "description": "Promotion Earning Resource" + }, + { + "name": "promotion-language-resource", + "description": "Promotion Language Resource" + }, + { + "name": "promotion-meta-resource", + "description": "Promotion Meta Resource" + }, + { + "name": "promotion-redemption-resource", + "description": "Promotion Redemption Resource" + }, + { + "name": "promotion-resource", + "description": "Promotion Resource" + }, + { + "name": "promotion-settings-resource", + "description": "Promotion Settings Resource" + } + ], + "paths": { + "/health/isalive": { + "get": { + "tags": [ + "health-check-resource" + ], + "summary": "isAlive", + "operationId": "isAliveUsingGET", + "produces": [ + "application/json" + ], + "responses": { + "200": { + "description": "OK", + "schema": { + "type": "string" + } + }, + "401": { + "description": "Unauthorized" + }, + "403": { + "description": "Forbidden" + }, + "404": { + "description": "Not Found" + } + } + } + }, + "/v1/management/promotions": { + "get": { + "tags": [ + "promotion-meta-resource" + ], + "summary": "getAllPromotionConfigs", + "operationId": "getAllPromotionConfigsUsingGET", + "produces": [ + "application/json" + ], + "parameters": [ + { + "name": "active", + "in": "query", + "required": false, + "type": "boolean" + }, + { + "name": "campaignId", + "in": "query", + "required": false, + "type": "string" + }, + { + "name": "endDate", + "in": "query", + "required": false, + "type": "integer", + "format": "int64" + }, + { + "name": "isLoyaltyOnly", + "in": "query", + "required": false, + "type": "boolean" + }, + { + "name": "limit", + "in": "query", + "required": false, + "type": "integer", + "format": "int32" + }, + { + "name": "loyaltyProgramId", + "in": "query", + "required": false, + "type": "integer", + "format": "int64" + }, + { + "name": "name", + "in": "query", + "required": false, + "type": "string" + }, + { + "name": "order", + "in": "query", + "required": false, + "type": "string", + "enum": [ + "ASC", + "DESC" + ] + }, + { + "name": "pageNumber", + "in": "query", + "required": false, + "type": "integer", + "format": "int32" + }, + { + "name": "partnerProgramId", + "in": "query", + "required": false, + "type": "integer", + "format": "int32" + }, + { + "name": "programType", + "in": "query", + "required": false, + "type": "string", + "enum": [ + "SUBSCRIPTION", + "TIER" + ] + }, + { + "name": "promotionMode", + "in": "query", + "required": false, + "type": "string", + "enum": [ + "DISCOUNT", + "PAYMENT_VOUCHER" + ] + }, + { + "name": "promotionType", + "in": "query", + "required": false, + "type": "string", + "enum": [ + "CODE", + "CUSTOMER", + "EARNING", + "POS", + "REWARD" + ] + }, + { + "name": "sortOn", + "in": "query", + "required": false, + "type": "string", + "enum": [ + "ID", + "NAME", + "START_DATE" + ] + }, + { + "name": "startDate", + "in": "query", + "required": false, + "type": "integer", + "format": "int64" + } + ], + "responses": { + "200": { + "description": "OK", + "schema": { + "$ref": "#/definitions/ResponseWrapper«List«PromotionMetaRO»»" + } + }, + "401": { + "description": "Unauthorized" + }, + "403": { + "description": "Forbidden" + }, + "404": { + "description": "Not Found" + } + } + }, + "post": { + "tags": [ + "promotion-meta-resource" + ], + "summary": "createPromotionConfig", + "operationId": "createPromotionConfigUsingPOST", + "consumes": [ + "application/json" + ], + "produces": [ + "application/json" + ], + "parameters": [ + { + "in": "body", + "name": "promotion", + "description": "promotion", + "required": true, + "schema": { + "$ref": "#/definitions/PromotionMetaROReq" + } + } + ], + "responses": { + "200": { + "description": "OK", + "schema": { + "$ref": "#/definitions/ResponseWrapper«PromotionMetaRO»" + } + }, + "201": { + "description": "Created" + }, + "401": { + "description": "Unauthorized" + }, + "403": { + "description": "Forbidden" + }, + "404": { + "description": "Not Found" + } + } + } + }, + "/v1/management/promotions/auditLogs/versions": { + "get": { + "tags": [ + "audit-log-resource" + ], + "summary": "getAuditLogVersions", + "operationId": "getAuditLogVersionsUsingGET", + "produces": [ + "application/json" + ], + "parameters": [ + { + "name": "endDate", + "in": "query", + "required": false, + "type": "integer", + "format": "int64" + }, + { + "name": "entityId", + "in": "query", + "required": true, + "type": "string" + }, + { + "name": "entityType", + "in": "query", + "required": true, + "type": "string", + "enum": [ + "PROMOTION_EXPIRY_REMINDER", + "PROMOTION_META", + "PROMOTION_SETTING" + ] + }, + { + "name": "limit", + "in": "query", + "required": false, + "type": "integer", + "format": "int32" + }, + { + "name": "order", + "in": "query", + "required": false, + "type": "string", + "enum": [ + "ASC", + "DESC" + ] + }, + { + "name": "pageNumber", + "in": "query", + "required": false, + "type": "integer", + "format": "int32" + }, + { + "name": "startDate", + "in": "query", + "required": false, + "type": "integer", + "format": "int64" + } + ], + "responses": { + "200": { + "description": "OK", + "schema": { + "$ref": "#/definitions/ResponseWrapper«List«AuditLogVersionRO»»" + } + }, + "401": { + "description": "Unauthorized" + }, + "403": { + "description": "Forbidden" + }, + "404": { + "description": "Not Found" + } + } + } + }, + "/v1/management/promotions/auditLogs/{entityType}/{entityId}/{version}": { + "get": { + "tags": [ + "audit-log-resource" + ], + "summary": "getAuditLogEntity", + "operationId": "getAuditLogEntityUsingGET", + "produces": [ + "application/json" + ], + "parameters": [ + { + "name": "entityId", + "in": "path", + "description": "entityId", + "required": true, + "type": "string" + }, + { + "name": "entityType", + "in": "path", + "description": "entityType", + "required": true, + "type": "string", + "enum": [ + "PROMOTION_EXPIRY_REMINDER", + "PROMOTION_META", + "PROMOTION_SETTING" + ] + }, + { + "name": "version", + "in": "path", + "description": "version", + "required": true, + "type": "string" + } + ], + "responses": { + "200": { + "description": "OK", + "schema": { + "$ref": "#/definitions/ResponseWrapper«object»" + } + }, + "401": { + "description": "Unauthorized" + }, + "403": { + "description": "Forbidden" + }, + "404": { + "description": "Not Found" + } + } + } + }, + "/v1/management/promotions/evaluationLogs/{evaluationId}": { + "get": { + "tags": [ + "cart-evaluation-log-resource" + ], + "summary": "getEvaluationLogs", + "operationId": "getEvaluationLogsUsingGET", + "produces": [ + "application/json" + ], + "parameters": [ + { + "name": "evaluationId", + "in": "path", + "description": "evaluationId", + "required": true, + "type": "string" + } + ], + "responses": { + "200": { + "description": "OK", + "schema": { + "$ref": "#/definitions/ResponseWrapper«CartEvaluationRO»" + } + }, + "401": { + "description": "Unauthorized" + }, + "403": { + "description": "Forbidden" + }, + "404": { + "description": "Not Found" + } + } + } + }, + "/v1/management/promotions/filters": { + "get": { + "tags": [ + "promotion-meta-resource" + ], + "summary": "getFilteredPromotions", + "operationId": "getFilteredPromotionsUsingGET", + "produces": [ + "application/json" + ], + "parameters": [ + { + "name": "active", + "in": "query", + "required": false, + "type": "boolean" + }, + { + "name": "campaignId", + "in": "query", + "required": false, + "type": "string" + }, + { + "name": "endDate", + "in": "query", + "required": false, + "type": "integer", + "format": "int64" + }, + { + "name": "isLoyaltyOnly", + "in": "query", + "required": false, + "type": "boolean" + }, + { + "name": "limit", + "in": "query", + "required": false, + "type": "integer", + "format": "int32" + }, + { + "name": "loyaltyProgramId", + "in": "query", + "required": false, + "type": "integer", + "format": "int64" + }, + { + "name": "name", + "in": "query", + "required": false, + "type": "string" + }, + { + "name": "order", + "in": "query", + "required": false, + "type": "string", + "enum": [ + "ASC", + "DESC" + ] + }, + { + "name": "pageNumber", + "in": "query", + "required": false, + "type": "integer", + "format": "int32" + }, + { + "name": "partnerProgramId", + "in": "query", + "required": false, + "type": "integer", + "format": "int32" + }, + { + "name": "programType", + "in": "query", + "required": false, + "type": "string", + "enum": [ + "SUBSCRIPTION", + "TIER" + ] + }, + { + "name": "promotionMode", + "in": "query", + "required": false, + "type": "string", + "enum": [ + "DISCOUNT", + "PAYMENT_VOUCHER" + ] + }, + { + "name": "promotionType", + "in": "query", + "required": false, + "type": "string", + "enum": [ + "CODE", + "CUSTOMER", + "EARNING", + "POS", + "REWARD" + ] + }, + { + "name": "sortOn", + "in": "query", + "required": false, + "type": "string", + "enum": [ + "ID", + "NAME", + "START_DATE" + ] + }, + { + "name": "startDate", + "in": "query", + "required": false, + "type": "integer", + "format": "int64" + } + ], + "responses": { + "200": { + "description": "OK", + "schema": { + "$ref": "#/definitions/ResponseWrapper«List«PromotionSummaryRO»»" + } + }, + "401": { + "description": "Unauthorized" + }, + "403": { + "description": "Forbidden" + }, + "404": { + "description": "Not Found" + } + } + } + }, + "/v1/management/promotions/language": { + "get": { + "tags": [ + "promotion-language-resource" + ], + "summary": "getMultiLanguageDetails", + "operationId": "getMultiLanguageDetailsUsingGET", + "produces": [ + "application/json" + ], + "parameters": [ + { + "name": "entity", + "in": "query", + "required": true, + "type": "string", + "enum": [ + "PROMOTION_META" + ] + }, + { + "name": "entityId", + "in": "query", + "required": true, + "type": "string" + }, + { + "name": "languageCodes", + "in": "query", + "required": false, + "type": "array", + "items": { + "type": "string" + }, + "collectionFormat": "multi" + } + ], + "responses": { + "200": { + "description": "OK", + "schema": { + "$ref": "#/definitions/ResponseWrapper«PromotionLanguageRO»" + } + }, + "401": { + "description": "Unauthorized" + }, + "403": { + "description": "Forbidden" + }, + "404": { + "description": "Not Found" + } + } + }, + "post": { + "tags": [ + "promotion-language-resource" + ], + "summary": "saveMultiLanguageDetails", + "operationId": "saveMultiLanguageDetailsUsingPOST", + "consumes": [ + "application/json" + ], + "produces": [ + "application/json" + ], + "parameters": [ + { + "in": "body", + "name": "promotionLanguageRO", + "description": "promotionLanguageRO", + "required": true, + "schema": { + "$ref": "#/definitions/PromotionLanguageRO" + } + } + ], + "responses": { + "200": { + "description": "OK", + "schema": { + "$ref": "#/definitions/ResponseWrapper«PromotionLanguageRO»" + } + }, + "201": { + "description": "Created" + }, + "401": { + "description": "Unauthorized" + }, + "403": { + "description": "Forbidden" + }, + "404": { + "description": "Not Found" + } + } + } + }, + "/v1/management/promotions/settings/custom_field": { + "get": { + "tags": [ + "promotion-settings-resource" + ], + "summary": "getPromotionCustomFields", + "operationId": "getPromotionCustomFieldsUsingGET", + "produces": [ + "application/json" + ], + "parameters": [ + { + "name": "mode", + "in": "query", + "description": "mode", + "required": false, + "type": "string", + "default": "DISCOUNT", + "enum": [ + "DISCOUNT", + "PAYMENT_VOUCHER" + ] + } + ], + "responses": { + "200": { + "description": "OK", + "schema": { + "$ref": "#/definitions/ResponseWrapper«List«CustomMetadataFieldRO»»" + } + }, + "401": { + "description": "Unauthorized" + }, + "403": { + "description": "Forbidden" + }, + "404": { + "description": "Not Found" + } + } + }, + "post": { + "tags": [ + "promotion-settings-resource" + ], + "summary": "savePromotionCustomFields", + "operationId": "savePromotionCustomFieldsUsingPOST", + "consumes": [ + "application/json" + ], + "produces": [ + "application/json" + ], + "parameters": [ + { + "in": "body", + "name": "customMetadataFields", + "description": "customMetadataFields", + "required": true, + "schema": { + "type": "array", + "items": { + "$ref": "#/definitions/CustomMetadataFieldRO" + } + } + }, + { + "name": "mode", + "in": "query", + "description": "mode", + "required": false, + "type": "string", + "default": "DISCOUNT", + "enum": [ + "DISCOUNT", + "PAYMENT_VOUCHER" + ] + } + ], + "responses": { + "200": { + "description": "OK", + "schema": { + "$ref": "#/definitions/ResponseWrapper«List«CustomMetadataFieldRO»»" + } + }, + "201": { + "description": "Created" + }, + "401": { + "description": "Unauthorized" + }, + "403": { + "description": "Forbidden" + }, + "404": { + "description": "Not Found" + } + } + } + }, + "/v1/management/promotions/settings/strategy": { + "get": { + "tags": [ + "promotion-settings-resource" + ], + "summary": "getPromotionStrategy", + "operationId": "getPromotionStrategyUsingGET", + "produces": [ + "application/json" + ], + "parameters": [ + { + "name": "mode", + "in": "query", + "description": "mode", + "required": true, + "type": "string", + "enum": [ + "DISCOUNT", + "PAYMENT_VOUCHER" + ] + } + ], + "responses": { + "200": { + "description": "OK", + "schema": { + "$ref": "#/definitions/ResponseWrapper«PromotionStrategyRO»" + } + }, + "401": { + "description": "Unauthorized" + }, + "403": { + "description": "Forbidden" + }, + "404": { + "description": "Not Found" + } + } + }, + "post": { + "tags": [ + "promotion-settings-resource" + ], + "summary": "savePromotionStrategy", + "operationId": "savePromotionStrategyUsingPOST", + "consumes": [ + "application/json" + ], + "produces": [ + "application/json" + ], + "parameters": [ + { + "in": "body", + "name": "promotionStrategy", + "description": "promotionStrategy", + "required": true, + "schema": { + "$ref": "#/definitions/PromotionStrategyRO" + } + } + ], + "responses": { + "200": { + "description": "OK", + "schema": { + "$ref": "#/definitions/ResponseWrapper«PromotionStrategyRO»" + } + }, + "201": { + "description": "Created" + }, + "401": { + "description": "Unauthorized" + }, + "403": { + "description": "Forbidden" + }, + "404": { + "description": "Not Found" + } + } + } + }, + "/v1/management/promotions/{promotionId}": { + "get": { + "tags": [ + "promotion-meta-resource" + ], + "summary": "getPromotionConfig", + "operationId": "getPromotionConfigUsingGET", + "produces": [ + "application/json" + ], + "parameters": [ + { + "name": "promotionId", + "in": "path", + "description": "promotionId", + "required": true, + "type": "string" + } + ], + "responses": { + "200": { + "description": "OK", + "schema": { + "$ref": "#/definitions/ResponseWrapper«PromotionMetaRO»" + } + }, + "401": { + "description": "Unauthorized" + }, + "403": { + "description": "Forbidden" + }, + "404": { + "description": "Not Found" + } + } + }, + "put": { + "tags": [ + "promotion-meta-resource" + ], + "summary": "updatePromotionConfig", + "operationId": "updatePromotionConfigUsingPUT", + "consumes": [ + "application/json" + ], + "produces": [ + "application/json" + ], + "parameters": [ + { + "in": "body", + "name": "promotion", + "description": "promotion", + "required": true, + "schema": { + "$ref": "#/definitions/PromotionMetaROReq" + } + }, + { + "name": "promotionId", + "in": "path", + "description": "promotionId", + "required": true, + "type": "string" + } + ], + "responses": { + "200": { + "description": "OK", + "schema": { + "$ref": "#/definitions/ResponseWrapper«PromotionMetaRO»" + } + }, + "201": { + "description": "Created" + }, + "401": { + "description": "Unauthorized" + }, + "403": { + "description": "Forbidden" + }, + "404": { + "description": "Not Found" + } + } + } + }, + "/v1/management/promotions/{promotionId}/activate": { + "put": { + "tags": [ + "promotion-meta-resource" + ], + "summary": "activatePromotion", + "operationId": "activatePromotionUsingPUT", + "consumes": [ + "application/json" + ], + "produces": [ + "application/json" + ], + "parameters": [ + { + "name": "promotionId", + "in": "path", + "description": "promotionId", + "required": true, + "type": "string" + } + ], + "responses": { + "200": { + "description": "OK", + "schema": { + "$ref": "#/definitions/ResponseWrapper«boolean»" + } + }, + "201": { + "description": "Created" + }, + "401": { + "description": "Unauthorized" + }, + "403": { + "description": "Forbidden" + }, + "404": { + "description": "Not Found" + } + } + } + }, + "/v1/management/promotions/{promotionId}/code_meta": { + "get": { + "tags": [ + "code-based-promotion-meta-resource" + ], + "summary": "getAllCodeBasedMetaConfigs", + "operationId": "getAllCodeBasedMetaConfigsUsingGET", + "produces": [ + "application/json" + ], + "parameters": [ + { + "name": "promotionId", + "in": "path", + "description": "promotionId", + "required": true, + "type": "string" + } + ], + "responses": { + "200": { + "description": "OK", + "schema": { + "$ref": "#/definitions/ResponseWrapper«List«CodeBasedPromotionMetaRO»»" + } + }, + "401": { + "description": "Unauthorized" + }, + "403": { + "description": "Forbidden" + }, + "404": { + "description": "Not Found" + } + } + }, + "post": { + "tags": [ + "code-based-promotion-meta-resource" + ], + "summary": "createCodeBasedPromotionJob", + "operationId": "createCodeBasedPromotionJobUsingPOST", + "consumes": [ + "application/json" + ], + "produces": [ + "application/json" + ], + "parameters": [ + { + "in": "body", + "name": "codeBasedPromotionMetaRO", + "description": "codeBasedPromotionMetaRO", + "required": true, + "schema": { + "$ref": "#/definitions/CodeBasedPromotionMetaRO" + } + }, + { + "name": "promotionId", + "in": "path", + "description": "promotionId", + "required": true, + "type": "string" + } + ], + "responses": { + "200": { + "description": "OK", + "schema": { + "$ref": "#/definitions/ResponseWrapper«CodeBasedPromotionMetaRO»" + } + }, + "201": { + "description": "Created" + }, + "401": { + "description": "Unauthorized" + }, + "403": { + "description": "Forbidden" + }, + "404": { + "description": "Not Found" + } + } + } + }, + "/v1/management/promotions/{promotionId}/deactivate": { + "put": { + "tags": [ + "promotion-meta-resource" + ], + "summary": "deactivatePromotion", + "operationId": "deactivatePromotionUsingPUT", + "consumes": [ + "application/json" + ], + "produces": [ + "application/json" + ], + "parameters": [ + { + "name": "promotionId", + "in": "path", + "description": "promotionId", + "required": true, + "type": "string" + } + ], + "responses": { + "200": { + "description": "OK", + "schema": { + "$ref": "#/definitions/ResponseWrapper«boolean»" + } + }, + "201": { + "description": "Created" + }, + "401": { + "description": "Unauthorized" + }, + "403": { + "description": "Forbidden" + }, + "404": { + "description": "Not Found" + } + } + } + }, + "/v1/management/promotions/{promotionId}/expiryReminders": { + "get": { + "tags": [ + "promotion-communication-resource" + ], + "summary": "getPromotionExpiryReminders", + "operationId": "getPromotionExpiryRemindersUsingGET", + "produces": [ + "application/json" + ], + "parameters": [ + { + "name": "promotionId", + "in": "path", + "description": "promotionId", + "required": true, + "type": "string" + } + ], + "responses": { + "200": { + "description": "OK", + "schema": { + "$ref": "#/definitions/ResponseWrapper«List«PromotionExpiryReminderRO»»" + } + }, + "401": { + "description": "Unauthorized" + }, + "403": { + "description": "Forbidden" + }, + "404": { + "description": "Not Found" + } + } + }, + "post": { + "tags": [ + "promotion-communication-resource" + ], + "summary": "createPromotionExpiryReminder", + "operationId": "createPromotionExpiryReminderUsingPOST", + "consumes": [ + "application/json" + ], + "produces": [ + "application/json" + ], + "parameters": [ + { + "in": "body", + "name": "promotionExpiryReminder", + "description": "promotionExpiryReminder", + "required": true, + "schema": { + "$ref": "#/definitions/PromotionExpiryReminderRO" + } + }, + { + "name": "promotionId", + "in": "path", + "description": "promotionId", + "required": true, + "type": "string" + } + ], + "responses": { + "200": { + "description": "OK", + "schema": { + "$ref": "#/definitions/ResponseWrapper«PromotionExpiryReminderRO»" + } + }, + "201": { + "description": "Created" + }, + "401": { + "description": "Unauthorized" + }, + "403": { + "description": "Forbidden" + }, + "404": { + "description": "Not Found" + } + } + } + }, + "/v1/management/promotions/{promotionId}/expiryReminders/{expiryReminderId}": { + "get": { + "tags": [ + "promotion-communication-resource" + ], + "summary": "getPromotionExpiryReminder", + "operationId": "getPromotionExpiryReminderUsingGET", + "produces": [ + "application/json" + ], + "parameters": [ + { + "name": "expiryReminderId", + "in": "path", + "description": "expiryReminderId", + "required": true, + "type": "string" + }, + { + "name": "promotionId", + "in": "path", + "description": "promotionId", + "required": true, + "type": "string" + } + ], + "responses": { + "200": { + "description": "OK", + "schema": { + "$ref": "#/definitions/ResponseWrapper«PromotionExpiryReminderRO»" + } + }, + "401": { + "description": "Unauthorized" + }, + "403": { + "description": "Forbidden" + }, + "404": { + "description": "Not Found" + } + } + }, + "put": { + "tags": [ + "promotion-communication-resource" + ], + "summary": "updatePromotionExpiryReminder", + "operationId": "updatePromotionExpiryReminderUsingPUT", + "consumes": [ + "application/json" + ], + "produces": [ + "application/json" + ], + "parameters": [ + { + "name": "expiryReminderId", + "in": "path", + "description": "expiryReminderId", + "required": true, + "type": "string" + }, + { + "in": "body", + "name": "promotionExpiryReminder", + "description": "promotionExpiryReminder", + "required": true, + "schema": { + "$ref": "#/definitions/PromotionExpiryReminderRO" + } + }, + { + "name": "promotionId", + "in": "path", + "description": "promotionId", + "required": true, + "type": "string" + } + ], + "responses": { + "200": { + "description": "OK", + "schema": { + "$ref": "#/definitions/ResponseWrapper«PromotionExpiryReminderRO»" + } + }, + "201": { + "description": "Created" + }, + "401": { + "description": "Unauthorized" + }, + "403": { + "description": "Forbidden" + }, + "404": { + "description": "Not Found" + } + } + } + }, + "/v1/management/promotions/{promotionId}/expiryReminders/{expiryReminderId}/activate": { + "put": { + "tags": [ + "promotion-communication-resource" + ], + "summary": "activatePromotionExpiryReminder", + "operationId": "activatePromotionExpiryReminderUsingPUT", + "consumes": [ + "application/json" + ], + "produces": [ + "application/json" + ], + "parameters": [ + { + "name": "expiryReminderId", + "in": "path", + "description": "expiryReminderId", + "required": true, + "type": "string" + }, + { + "name": "promotionId", + "in": "path", + "description": "promotionId", + "required": true, + "type": "string" + } + ], + "responses": { + "200": { + "description": "OK", + "schema": { + "$ref": "#/definitions/ResponseWrapper«boolean»" + } + }, + "201": { + "description": "Created" + }, + "401": { + "description": "Unauthorized" + }, + "403": { + "description": "Forbidden" + }, + "404": { + "description": "Not Found" + } + } + } + }, + "/v1/management/promotions/{promotionId}/expiryReminders/{expiryReminderId}/deactivate": { + "put": { + "tags": [ + "promotion-communication-resource" + ], + "summary": "deactivatePromotionExpiryReminder", + "operationId": "deactivatePromotionExpiryReminderUsingPUT", + "consumes": [ + "application/json" + ], + "produces": [ + "application/json" + ], + "parameters": [ + { + "name": "expiryReminderId", + "in": "path", + "description": "expiryReminderId", + "required": true, + "type": "string" + }, + { + "name": "promotionId", + "in": "path", + "description": "promotionId", + "required": true, + "type": "string" + } + ], + "responses": { + "200": { + "description": "OK", + "schema": { + "$ref": "#/definitions/ResponseWrapper«boolean»" + } + }, + "201": { + "description": "Created" + }, + "401": { + "description": "Unauthorized" + }, + "403": { + "description": "Forbidden" + }, + "404": { + "description": "Not Found" + } + } + } + }, + "/v1/management/promotions/{promotionId}/issueBulk": { + "post": { + "tags": [ + "promotion-earning-management-resource" + ], + "summary": "issuePromotionsInBulk", + "operationId": "issuePromotionsInBulkUsingPOST", + "consumes": [ + "application/json" + ], + "produces": [ + "application/json" + ], + "parameters": [ + { + "name": "contextId", + "in": "query", + "description": "contextId", + "required": true, + "type": "string" + }, + { + "in": "body", + "name": "customerIds", + "description": "customerIds", + "required": true, + "schema": { + "type": "array", + "items": { + "type": "integer", + "format": "int64" + } + } + }, + { + "name": "promotionId", + "in": "path", + "description": "promotionId", + "required": true, + "type": "string" + } + ], + "responses": { + "200": { + "description": "OK", + "schema": { + "$ref": "#/definitions/ResponseWrapper«Map«long,CustomerEarnedPromotionRO»»" + } + }, + "201": { + "description": "Created" + }, + "401": { + "description": "Unauthorized" + }, + "403": { + "description": "Forbidden" + }, + "404": { + "description": "Not Found" + } + } + } + }, + "/v1/promotions/code": { + "get": { + "tags": [ + "code-based-promotion-resource" + ], + "summary": "getPromotionForCodes", + "operationId": "getPromotionForCodesUsingGET", + "produces": [ + "application/json" + ], + "parameters": [ + { + "name": "codes", + "in": "query", + "required": true, + "type": "array", + "items": { + "type": "string" + }, + "collectionFormat": "multi" + }, + { + "name": "includeRedemptions", + "in": "query", + "required": false, + "type": "boolean" + }, + { + "name": "mode", + "in": "query", + "required": true, + "type": "string", + "enum": [ + "DISCOUNT", + "PAYMENT_VOUCHER" + ] + } + ], + "responses": { + "200": { + "description": "OK", + "schema": { + "$ref": "#/definitions/ResponseWrapper«List«CodeBasedPromotionRO»»" + } + }, + "401": { + "description": "Unauthorized" + }, + "403": { + "description": "Forbidden" + }, + "404": { + "description": "Not Found" + } + } + } + }, + "/v1/promotions/code/link": { + "post": { + "tags": [ + "code-based-promotion-resource" + ], + "summary": "linkCode", + "operationId": "linkCodeUsingPOST", + "consumes": [ + "application/json" + ], + "produces": [ + "application/json" + ], + "parameters": [ + { + "in": "body", + "name": "saveCodeRequest", + "description": "saveCodeRequest", + "required": true, + "schema": { + "$ref": "#/definitions/SaveCodeRequest" + } + } + ], + "responses": { + "200": { + "description": "OK", + "schema": { + "$ref": "#/definitions/ResponseWrapper«CodeBasedPromotionRO»" + } + }, + "201": { + "description": "Created" + }, + "401": { + "description": "Unauthorized" + }, + "403": { + "description": "Forbidden" + }, + "404": { + "description": "Not Found" + } + } + } + }, + "/v1/promotions/config": { + "get": { + "tags": [ + "promotion-resource" + ], + "summary": "getPromotionConfig", + "operationId": "getPromotionConfigUsingGET_1", + "produces": [ + "application/json" + ], + "parameters": [ + { + "name": "includeExpired", + "in": "query", + "required": false, + "type": "boolean" + }, + { + "name": "includeInactive", + "in": "query", + "required": false, + "type": "boolean" + }, + { + "name": "promotionIds", + "in": "query", + "required": true, + "type": "array", + "items": { + "type": "string" + }, + "collectionFormat": "multi" + } + ], + "responses": { + "200": { + "description": "OK", + "schema": { + "$ref": "#/definitions/ResponseWrapper«List«PromotionConfigRO»»" + } + }, + "401": { + "description": "Unauthorized" + }, + "403": { + "description": "Forbidden" + }, + "404": { + "description": "Not Found" + } + } + } + }, + "/v1/promotions/customer/{customerId}": { + "get": { + "tags": [ + "promotion-earning-resource" + ], + "summary": "getAllForCustomer", + "operationId": "getAllForCustomerUsingGET", + "produces": [ + "application/json" + ], + "parameters": [ + { + "name": "customerId", + "in": "path", + "description": "customerId", + "required": true, + "type": "integer", + "format": "int64" + }, + { + "name": "entityId", + "in": "query", + "required": false, + "type": "integer", + "format": "int64" + }, + { + "name": "includeCodeLinkedPromotions", + "in": "query", + "required": false, + "type": "boolean" + }, + { + "name": "includeExpired", + "in": "query", + "required": false, + "type": "boolean" + }, + { + "name": "includeRedemptions", + "in": "query", + "required": false, + "type": "boolean" + }, + { + "name": "includeSupplementaryPromotions", + "in": "query", + "required": false, + "type": "boolean" + }, + { + "name": "limit", + "in": "query", + "required": false, + "type": "integer", + "format": "int32" + }, + { + "name": "mode", + "in": "query", + "required": false, + "type": "string", + "enum": [ + "DISCOUNT", + "PAYMENT_VOUCHER" + ] + }, + { + "name": "order", + "in": "query", + "required": false, + "type": "string", + "enum": [ + "ASC", + "DESC" + ] + }, + { + "name": "pageNumber", + "in": "query", + "required": false, + "type": "integer", + "format": "int32" + }, + { + "name": "sortOn", + "in": "query", + "required": false, + "type": "string", + "enum": [ + "EVENT_TIME", + "VALID_TILL" + ] + } + ], + "responses": { + "200": { + "description": "OK", + "schema": { + "$ref": "#/definitions/ResponseWrapper«List«CustomerPromotionRO»»" + } + }, + "401": { + "description": "Unauthorized" + }, + "403": { + "description": "Forbidden" + }, + "404": { + "description": "Not Found" + } + } + } + }, + "/v1/promotions/earn/bulk": { + "post": { + "tags": [ + "promotion-earning-resource" + ], + "summary": "bulkEarnPromotion", + "operationId": "bulkEarnPromotionUsingPOST", + "consumes": [ + "application/json" + ], + "produces": [ + "application/json" + ], + "parameters": [ + { + "in": "body", + "name": "bulkEarnRO", + "description": "bulkEarnRO", + "required": true, + "schema": { + "$ref": "#/definitions/BulkEarnRO" + } + } + ], + "responses": { + "200": { + "description": "OK", + "schema": { + "$ref": "#/definitions/ResponseWrapper«List«BulkEarnedPromotionRO»»" + } + }, + "201": { + "description": "Created" + }, + "401": { + "description": "Unauthorized" + }, + "403": { + "description": "Forbidden" + }, + "404": { + "description": "Not Found" + } + } + } + }, + "/v1/promotions/evaluate": { + "post": { + "tags": [ + "promotion-redemption-resource" + ], + "summary": "evaluatePromotionOnCart", + "operationId": "evaluatePromotionOnCartUsingPOST", + "consumes": [ + "application/json" + ], + "produces": [ + "application/json" + ], + "parameters": [ + { + "in": "body", + "name": "cart", + "description": "cart", + "required": true, + "schema": { + "$ref": "#/definitions/CartROReq" + } + } + ], + "responses": { + "200": { + "description": "OK", + "schema": { + "$ref": "#/definitions/ResponseWrapper«CartRO»" + } + }, + "201": { + "description": "Created" + }, + "401": { + "description": "Unauthorized" + }, + "403": { + "description": "Forbidden" + }, + "404": { + "description": "Not Found" + } + } + } + }, + "/v1/promotions/redemptions": { + "get": { + "tags": [ + "promotion-redemption-resource" + ], + "summary": "getRedemptions", + "operationId": "getRedemptionsUsingGET", + "produces": [ + "application/json" + ], + "parameters": [ + { + "name": "customerId", + "in": "query", + "required": false, + "type": "integer", + "format": "int64" + }, + { + "name": "limit", + "in": "query", + "required": false, + "type": "integer", + "format": "int32" + }, + { + "name": "mode", + "in": "query", + "required": false, + "type": "string", + "enum": [ + "DISCOUNT", + "PAYMENT_VOUCHER" + ] + }, + { + "name": "order", + "in": "query", + "required": false, + "type": "string", + "enum": [ + "ASC", + "DESC" + ] + }, + { + "name": "pageNumber", + "in": "query", + "required": false, + "type": "integer", + "format": "int32" + }, + { + "name": "promotionId", + "in": "query", + "required": false, + "type": "string" + }, + { + "name": "sortOn", + "in": "query", + "required": false, + "type": "string", + "enum": [ + "REDEMPTION_DATE" + ] + }, + { + "name": "transactionEntityIdentifier", + "in": "query", + "required": false, + "type": "string" + }, + { + "name": "transactionIdentifier", + "in": "query", + "required": false, + "type": "string" + } + ], + "responses": { + "200": { + "description": "OK", + "schema": { + "$ref": "#/definitions/ResponseWrapper«List«PromotionRedemptionRO»»" + } + }, + "401": { + "description": "Unauthorized" + }, + "403": { + "description": "Forbidden" + }, + "404": { + "description": "Not Found" + } + } + } + }, + "/v1/promotions/revokeEarn": { + "post": { + "tags": [ + "promotion-earning-resource" + ], + "summary": "revokeEarn", + "operationId": "revokeEarnUsingPOST", + "consumes": [ + "application/json" + ], + "produces": [ + "application/json" + ], + "parameters": [ + { + "in": "body", + "name": "revokeEarnRequest", + "description": "revokeEarnRequest", + "required": true, + "schema": { + "$ref": "#/definitions/RevokeEarnRequest" + } + } + ], + "responses": { + "200": { + "description": "OK", + "schema": { + "$ref": "#/definitions/BulkResponseWrapper«RevokeEarnResponse,EarnRevokeError»" + } + }, + "201": { + "description": "Created" + }, + "401": { + "description": "Unauthorized" + }, + "403": { + "description": "Forbidden" + }, + "404": { + "description": "Not Found" + } + } + } + }, + "/v1/promotions/till/{tillId}": { + "get": { + "tags": [ + "promotion-resource" + ], + "summary": "getAllActivePosPromotionForTill", + "operationId": "getAllActivePosPromotionForTillUsingGET", + "produces": [ + "application/json" + ], + "parameters": [ + { + "name": "tillId", + "in": "path", + "description": "tillId", + "required": true, + "type": "integer", + "format": "int64" + } + ], + "responses": { + "200": { + "description": "OK", + "schema": { + "$ref": "#/definitions/ResponseWrapper«List«PromotionMetaRO»»" + } + }, + "401": { + "description": "Unauthorized" + }, + "403": { + "description": "Forbidden" + }, + "404": { + "description": "Not Found" + } + } + } + }, + "/v1/promotions/{promotionId}/activate": { + "post": { + "tags": [ + "promotion-earning-resource" + ], + "summary": "activate", + "operationId": "activateUsingPOST", + "consumes": [ + "application/json" + ], + "produces": [ + "application/json" + ], + "parameters": [ + { + "name": "customerId", + "in": "query", + "required": true, + "type": "integer", + "format": "int64" + }, + { + "name": "earnId", + "in": "query", + "required": false, + "type": "string" + }, + { + "name": "promotionId", + "in": "path", + "description": "promotionId", + "required": true, + "type": "string" + } + ], + "responses": { + "200": { + "description": "OK", + "schema": { + "$ref": "#/definitions/ResponseWrapper«boolean»" + } + }, + "201": { + "description": "Created" + }, + "401": { + "description": "Unauthorized" + }, + "403": { + "description": "Forbidden" + }, + "404": { + "description": "Not Found" + } + } + } + }, + "/v1/promotions/{promotionId}/deactivate": { + "post": { + "tags": [ + "promotion-earning-resource" + ], + "summary": "deactivate", + "operationId": "deactivateUsingPOST", + "consumes": [ + "application/json" + ], + "produces": [ + "application/json" + ], + "parameters": [ + { + "name": "customerId", + "in": "query", + "required": true, + "type": "integer", + "format": "int64" + }, + { + "name": "earnId", + "in": "query", + "required": false, + "type": "string" + }, + { + "name": "promotionId", + "in": "path", + "description": "promotionId", + "required": true, + "type": "string" + } + ], + "responses": { + "200": { + "description": "OK", + "schema": { + "$ref": "#/definitions/ResponseWrapper«boolean»" + } + }, + "201": { + "description": "Created" + }, + "401": { + "description": "Unauthorized" + }, + "403": { + "description": "Forbidden" + }, + "404": { + "description": "Not Found" + } + } + } + }, + "/v1/promotions/{promotionId}/earn": { + "post": { + "tags": [ + "promotion-earning-resource" + ], + "summary": "earnPromotion", + "operationId": "earnPromotionUsingPOST", + "consumes": [ + "application/json" + ], + "produces": [ + "application/json" + ], + "parameters": [ + { + "in": "body", + "name": "customerEarnedPromotion", + "description": "customerEarnedPromotion", + "required": true, + "schema": { + "$ref": "#/definitions/CustomerEarnedPromotionRO" + } + }, + { + "name": "promotionId", + "in": "path", + "description": "promotionId", + "required": true, + "type": "string" + } + ], + "responses": { + "200": { + "description": "OK", + "schema": { + "$ref": "#/definitions/ResponseWrapper«CustomerEarnedPromotionRO»" + } + }, + "201": { + "description": "Created" + }, + "401": { + "description": "Unauthorized" + }, + "403": { + "description": "Forbidden" + }, + "404": { + "description": "Not Found" + } + } + } + } + }, + "definitions": { + "Action": { + "type": "object", + "required": [ + "type" + ], + "properties": { + "cartBasedAction": { + "$ref": "#/definitions/CartBasedAction" + }, + "fixedPriceAction": { + "$ref": "#/definitions/FixedPriceAction" + }, + "freeProductAction": { + "$ref": "#/definitions/FreeProductAction" + }, + "productBasedAction": { + "$ref": "#/definitions/ProductBasedAction" + }, + "tenderBasedAction": { + "$ref": "#/definitions/TenderBasedAction" + }, + "type": { + "type": "string", + "enum": [ + "CART_BASED", + "FIXED_PRICE", + "FREE_PRODUCT", + "PRODUCT_BASED", + "TENDER" + ] + } + }, + "title": "Action" + }, + "ApiError": { + "type": "object", + "properties": { + "code": { + "type": "integer", + "format": "int64" + }, + "message": { + "type": "string" + } + }, + "title": "ApiError" + }, + "AppliedPromotionRO": { + "type": "object", + "properties": { + "discount": { + "type": "string" + }, + "discountAppliedOnQuantity": { + "type": "string" + }, + "earnedPromotionId": { + "type": "string" + }, + "identifier": { + "type": "string" + }, + "messageLabel": { + "type": "string" + }, + "name": { + "type": "string" + }, + "promoCode": { + "type": "string" + }, + "promotionAppliedOnQuantity": { + "type": "string" + }, + "promotionId": { + "type": "string" + }, + "promotionMode": { + "type": "string", + "enum": [ + "DISCOUNT", + "PAYMENT_VOUCHER" + ] + }, + "redeemableVoucherValue": { + "type": "string" + }, + "redemptionCount": { + "type": "integer", + "format": "int64" + }, + "tenderIdentifier": { + "type": "string" + }, + "tenderType": { + "type": "string", + "enum": [ + "CARD", + "CASH", + "PAYMENT_VOUCHER" + ] + }, + "totalVoucherValue": { + "type": "string" + } + }, + "title": "AppliedPromotionRO" + }, + "AuditLogVersionRO": { + "type": "object", + "properties": { + "action": { + "type": "string" + }, + "triggeredBy": { + "type": "integer", + "format": "int64" + }, + "triggeredOn": { + "type": "integer", + "format": "int64" + }, + "version": { + "type": "string" + } + }, + "title": "AuditLogVersionRO" + }, + "BulkEarnRO": { + "type": "object", + "required": [ + "customerId", + "earnedFromType", + "eventDetails", + "eventTime" + ], + "properties": { + "customerId": { + "type": "integer", + "format": "int64" + }, + "earnedFromType": { + "type": "string", + "enum": [ + "ACTIVITY", + "BULK_ISSUE", + "MILESTONE", + "REWARD" + ] + }, + "earnedPromotions": { + "type": "array", + "items": { + "$ref": "#/definitions/EarnedPromotion" + } + }, + "eventDetails": { + "$ref": "#/definitions/EventDetailsRO" + }, + "eventTime": { + "type": "integer", + "format": "int64" + }, + "orgId": { + "type": "integer", + "format": "int64" + } + }, + "title": "BulkEarnRO" + }, + "BulkEarnedPromotionRO": { + "type": "object", + "properties": { + "customerEarnedPromotions": { + "type": "array", + "items": { + "$ref": "#/definitions/CustomerEarnedPromotionRO" + } + }, + "earnedFromId": { + "type": "string" + }, + "errorDetails": { + "$ref": "#/definitions/ErrorDetails" + }, + "failedEarnCount": { + "type": "integer", + "format": "int32" + }, + "promotionId": { + "type": "string" + }, + "successfulEarnCount": { + "type": "integer", + "format": "int32" + } + }, + "title": "BulkEarnedPromotionRO" + }, + "BulkResponseWrapper«RevokeEarnResponse,EarnRevokeError»": { + "type": "object", + "properties": { + "data": { + "$ref": "#/definitions/RevokeEarnResponse" + }, + "errors": { + "type": "array", + "items": { + "$ref": "#/definitions/EarnRevokeError" + } + } + }, + "title": "BulkResponseWrapper«RevokeEarnResponse,EarnRevokeError»" + }, + "CartBasedAction": { + "type": "object", + "required": [ + "type", + "value" + ], + "properties": { + "type": { + "type": "string", + "enum": [ + "ABSOLUTE", + "PERCENTAGE" + ] + }, + "value": { + "type": "string" + } + }, + "title": "CartBasedAction" + }, + "CartCondition": { + "type": "object", + "required": [ + "kpi", + "operator", + "value" + ], + "properties": { + "kpi": { + "type": "string", + "enum": [ + "ITEMCOUNT", + "SUBTOTAL" + ] + }, + "operator": { + "type": "string", + "enum": [ + "EQUALS", + "GREATER_THAN", + "GREATER_THAN_OR_EQUAL", + "IN", + "LESS_THAN", + "LESS_THAN_OR_EQUAL", + "NONE" + ] + }, + "value": { + "type": "string" + } + }, + "title": "CartCondition" + }, + "CartEvaluationRO": { + "type": "object", + "properties": { + "cartRO": { + "$ref": "#/definitions/CartRO" + }, + "createdOn": { + "type": "string", + "format": "date-time" + }, + "evaluationLogs": { + "type": "array", + "items": { + "$ref": "#/definitions/PromotionLogRO" + } + }, + "id": { + "type": "string" + }, + "isRedeemed": { + "type": "boolean" + } + }, + "title": "CartEvaluationRO" + }, + "CartItemRO": { + "type": "object", + "required": [ + "amount", + "qty", + "sku" + ], + "properties": { + "amount": { + "type": "string" + }, + "appliedPromotions": { + "type": "array", + "items": { + "$ref": "#/definitions/AppliedPromotionRO" + } + }, + "attributes": { + "type": "object", + "additionalProperties": { + "type": "string" + } + }, + "brandList": { + "type": "array", + "items": { + "type": "string" + } + }, + "categoryList": { + "type": "array", + "items": { + "type": "string" + } + }, + "discount": { + "type": "string" + }, + "qty": { + "type": "string" + }, + "referenceId": { + "type": "string" + }, + "sku": { + "type": "string" + } + }, + "title": "CartItemRO" + }, + "CartRO": { + "type": "object", + "required": [ + "amount", + "cartItems" + ], + "properties": { + "amount": { + "type": "string" + }, + "appliedPaymentVouchers": { + "type": "array", + "items": { + "$ref": "#/definitions/AppliedPromotionRO" + } + }, + "appliedPromotions": { + "type": "array", + "items": { + "$ref": "#/definitions/AppliedPromotionRO" + } + }, + "cartItems": { + "type": "array", + "items": { + "$ref": "#/definitions/CartItemRO" + } + }, + "cartTenders": { + "type": "array", + "items": { + "$ref": "#/definitions/CartTenderRO" + } + }, + "categoryHierarchySentInPayload": { + "type": "boolean" + }, + "customerId": { + "type": "integer", + "format": "int64", + "minimum": 1, + "exclusiveMinimum": false + }, + "evaluationId": { + "type": "string" + }, + "paymentVoucherEvaluationLogs": { + "type": "array", + "items": { + "$ref": "#/definitions/CodeBasedEvaluationLog" + } + }, + "paymentVouchers": { + "type": "array", + "items": { + "type": "string" + } + }, + "promoCodeEvaluationLogs": { + "type": "array", + "items": { + "$ref": "#/definitions/CodeBasedEvaluationLog" + } + }, + "promoCodes": { + "type": "array", + "items": { + "type": "string" + } + } + }, + "title": "CartRO" + }, + "CartROReq": { + "type": "object", + "required": [ + "amount", + "cartItems" + ], + "properties": { + "amount": { + "type": "string" + }, + "appliedPaymentVouchers": { + "type": "array", + "items": { + "$ref": "#/definitions/AppliedPromotionRO" + } + }, + "appliedPromotions": { + "type": "array", + "items": { + "$ref": "#/definitions/AppliedPromotionRO" + } + }, + "cartItems": { + "type": "array", + "items": { + "$ref": "#/definitions/CartItemRO" + } + }, + "cartTenders": { + "type": "array", + "items": { + "$ref": "#/definitions/CartTenderRO" + } + }, + "categoryHierarchySentInPayload": { + "type": "boolean" + }, + "customerId": { + "type": "integer", + "format": "int64", + "minimum": 1, + "exclusiveMinimum": false + }, + "evaluationId": { + "type": "string" + }, + "paymentVoucherEvaluationLogs": { + "type": "array", + "items": { + "$ref": "#/definitions/CodeBasedEvaluationLogReq" + } + }, + "paymentVouchers": { + "type": "array", + "items": { + "type": "string" + } + }, + "promoCodeEvaluationLogs": { + "type": "array", + "items": { + "$ref": "#/definitions/CodeBasedEvaluationLogReq" + } + }, + "promoCodes": { + "type": "array", + "items": { + "type": "string" + } + } + }, + "title": "CartROReq" + }, + "CartRORes": { + "type": "object", + "required": [ + "amount", + "cartItems" + ], + "properties": { + "amount": { + "type": "string" + }, + "appliedPaymentVouchers": { + "type": "array", + "items": { + "$ref": "#/definitions/AppliedPromotionRO" + } + }, + "appliedPromotions": { + "type": "array", + "items": { + "$ref": "#/definitions/AppliedPromotionRO" + } + }, + "cartItems": { + "type": "array", + "items": { + "$ref": "#/definitions/CartItemRO" + } + }, + "cartTenders": { + "type": "array", + "items": { + "$ref": "#/definitions/CartTenderRO" + } + }, + "categoryHierarchySentInPayload": { + "type": "boolean" + }, + "customerId": { + "type": "integer", + "format": "int64", + "minimum": 1, + "exclusiveMinimum": false + }, + "evaluationId": { + "type": "string" + }, + "paymentVoucherEvaluationLogs": { + "type": "array", + "items": { + "$ref": "#/definitions/CodeBasedEvaluationLogRes" + } + }, + "paymentVouchers": { + "type": "array", + "items": { + "type": "string" + } + }, + "promoCodeEvaluationLogs": { + "type": "array", + "items": { + "$ref": "#/definitions/CodeBasedEvaluationLogRes" + } + }, + "promoCodes": { + "type": "array", + "items": { + "type": "string" + } + } + }, + "title": "CartRORes" + }, + "CartTenderRO": { + "type": "object", + "required": [ + "identifier" + ], + "properties": { + "adjustedAmount": { + "type": "string" + }, + "amount": { + "type": "string" + }, + "identifier": { + "type": "string" + } + }, + "title": "CartTenderRO" + }, + "CodeBasedEvaluationLog": { + "type": "object", + "properties": { + "codeType": { + "type": "string", + "enum": [ + "DISCOUNT", + "PAYMENT_VOUCHER" + ] + }, + "errorCode": { + "type": "integer", + "format": "int32" + }, + "message": { + "type": "string" + }, + "promoCode": { + "type": "string" + } + }, + "title": "CodeBasedEvaluationLog" + }, + "CodeBasedEvaluationLogReq": { + "type": "object", + "properties": { + "codeType": { + "type": "string", + "enum": [ + "DISCOUNT", + "PAYMENT_VOUCHER" + ] + }, + "errorCode": { + "type": "integer", + "format": "int32" + }, + "message": { + "type": "string" + }, + "promoCode": { + "type": "string" + } + }, + "title": "CodeBasedEvaluationLogReq" + }, + "CodeBasedEvaluationLogRes": { + "type": "object", + "properties": { + "codeType": { + "type": "string", + "enum": [ + "DISCOUNT", + "PAYMENT_VOUCHER" + ] + }, + "errorCode": { + "type": "integer", + "format": "int32" + }, + "message": { + "type": "string" + }, + "promoCode": { + "type": "string" + } + }, + "title": "CodeBasedEvaluationLogRes" + }, + "CodeBasedPromotionMetaRO": { + "type": "object", + "required": [ + "codeJobType" + ], + "properties": { + "codeJobType": { + "type": "string", + "enum": [ + "AUTO_GENERATED", + "UPLOADED" + ] + }, + "codeLength": { + "type": "integer", + "format": "int32", + "minimum": 5, + "maximum": 40, + "exclusiveMinimum": false, + "exclusiveMaximum": false + }, + "createdBy": { + "type": "integer", + "format": "int64" + }, + "createdOn": { + "type": "string", + "format": "date-time" + }, + "errorFileHandle": { + "type": "string" + }, + "errorMessages": { + "type": "array", + "items": { + "type": "string" + } + }, + "id": { + "type": "string" + }, + "isAlphaNumeric": { + "type": "boolean" + }, + "lastUpdatedBy": { + "type": "integer", + "format": "int64" + }, + "lastUpdatedOn": { + "type": "string", + "format": "date-time" + }, + "orgId": { + "type": "integer", + "format": "int64" + }, + "promotionId": { + "type": "string" + }, + "savedCount": { + "type": "integer", + "format": "int64" + }, + "status": { + "type": "string", + "enum": [ + "COMPLETED", + "ERRORED", + "GENERATING_CODE", + "OPEN", + "UPLOADING" + ] + }, + "successFileHandle": { + "type": "string" + }, + "totalCount": { + "type": "integer", + "format": "int64", + "maximum": 10000000, + "exclusiveMaximum": false + }, + "uploadedFile": { + "$ref": "#/definitions/UploadedFileRO" + } + }, + "title": "CodeBasedPromotionMetaRO" + }, + "CodeBasedPromotionRO": { + "type": "object", + "properties": { + "active": { + "type": "boolean" + }, + "apiError": { + "$ref": "#/definitions/ApiError" + }, + "code": { + "type": "string" + }, + "createdOn": { + "type": "integer", + "format": "int64" + }, + "customerId": { + "type": "integer", + "format": "int64" + }, + "id": { + "type": "string" + }, + "mode": { + "type": "string", + "enum": [ + "DISCOUNT", + "PAYMENT_VOUCHER" + ] + }, + "orgId": { + "type": "integer", + "format": "int64" + }, + "promotionId": { + "type": "string" + }, + "promotionName": { + "type": "string" + }, + "restrictions": { + "type": "object", + "additionalProperties": { + "type": "array", + "items": { + "$ref": "#/definitions/RestrictionDetailsRO" + } + } + }, + "validTill": { + "type": "integer", + "format": "int64" + } + }, + "title": "CodeBasedPromotionRO" + }, + "ComboProductConditionRO": { + "type": "object", + "required": [ + "productConditions" + ], + "properties": { + "productConditions": { + "type": "array", + "items": { + "$ref": "#/definitions/ProductCondition" + } + } + }, + "title": "ComboProductConditionRO" + }, + "CommunicationChannelRO": { + "type": "object", + "properties": { + "accountId": { + "type": "string" + }, + "channelType": { + "type": "string", + "enum": [ + "ANDROID", + "EMAIL", + "IOS", + "SMS" + ] + }, + "domainPropertyId": { + "type": "string" + }, + "message": { + "type": "string" + }, + "pushNotificationCta": { + "$ref": "#/definitions/PushNotificationCtaRO" + }, + "senderCDMA": { + "type": "string" + }, + "senderEmail": { + "type": "string" + }, + "senderGSM": { + "type": "string" + }, + "senderLabel": { + "type": "string" + }, + "senderReplyToEmail": { + "type": "string" + }, + "subject": { + "type": "string" + }, + "unsubscribeLabel": { + "type": "string" + } + }, + "title": "CommunicationChannelRO" + }, + "Condition": { + "type": "object", + "required": [ + "type" + ], + "properties": { + "cartCondition": { + "$ref": "#/definitions/CartCondition" + }, + "comboProductCondition": { + "$ref": "#/definitions/ComboProductConditionRO" + }, + "productCondition": { + "$ref": "#/definitions/ProductCondition" + }, + "tenderCondition": { + "$ref": "#/definitions/TenderCondition" + }, + "type": { + "type": "string", + "enum": [ + "CART", + "COMBO_PRODUCT", + "PRODUCT", + "TENDER" + ] + } + }, + "title": "Condition" + }, + "CustomMetadataFieldRO": { + "type": "object", + "required": [ + "dataType", + "fieldName" + ], + "properties": { + "dataType": { + "type": "string", + "enum": [ + "DATE", + "NUMBER", + "STRING" + ] + }, + "fieldName": { + "type": "string" + }, + "isRequired": { + "type": "boolean" + } + }, + "title": "CustomMetadataFieldRO" + }, + "CustomerEarnedPromotionRO": { + "type": "object", + "required": [ + "customerId", + "earnedFromId", + "earnedFromType", + "eventDetails", + "eventTime" + ], + "properties": { + "customerId": { + "type": "integer", + "format": "int64" + }, + "earnedFromId": { + "type": "string" + }, + "earnedFromType": { + "type": "string", + "enum": [ + "ACTIVITY", + "BULK_ISSUE", + "MILESTONE", + "REWARD" + ] + }, + "errorDetails": { + "$ref": "#/definitions/ErrorDetails" + }, + "eventDetails": { + "$ref": "#/definitions/EventDetailsRO" + }, + "eventTime": { + "type": "integer", + "format": "int64" + }, + "id": { + "type": "string" + }, + "promotionId": { + "type": "string" + }, + "validTill": { + "type": "integer", + "format": "int64" + } + }, + "title": "CustomerEarnedPromotionRO" + }, + "CustomerPromotionRO": { + "type": "object", + "properties": { + "applicationMode": { + "type": "string", + "enum": [ + "DISCOUNT", + "PAYMENT_VOUCHER" + ] + }, + "code": { + "type": "string" + }, + "customFieldValues": { + "type": "object", + "additionalProperties": { + "type": "string" + } + }, + "customerId": { + "type": "integer", + "format": "int64" + }, + "earnedFromId": { + "type": "string" + }, + "earnedPromotionId": { + "type": "string" + }, + "earnedStatus": { + "type": "string", + "enum": [ + "LOCKED", + "UNLOCKED" + ] + }, + "earnedType": { + "type": "string", + "enum": [ + "CODE", + "MILESTONE_EARN", + "NONE", + "REWARD", + "SINGLE_ACTIVITY_EARN", + "SUBSCRIPTION", + "TIER" + ] + }, + "mileStoneId": { + "type": "integer", + "format": "int64" + }, + "promotionId": { + "type": "string" + }, + "promotionName": { + "type": "string" + }, + "promotionStatus": { + "type": "string", + "enum": [ + "ACTIVE", + "INACTIVE" + ] + }, + "restrictions": { + "type": "object", + "additionalProperties": { + "type": "array", + "items": { + "$ref": "#/definitions/RestrictionDetailsRO" + } + } + }, + "supplementaryCriteria": { + "$ref": "#/definitions/SupplementaryCriteria" + }, + "unlockedDate": { + "type": "integer", + "format": "int64" + }, + "validTill": { + "type": "integer", + "format": "int64" + } + }, + "title": "CustomerPromotionRO" + }, + "DecimalRoundingStrategy": { + "type": "object", + "properties": { + "decimalPlaces": { + "type": "integer", + "format": "int32" + }, + "roundingMode": { + "type": "string", + "enum": [ + "CEILING", + "DOWN", + "FLOOR", + "HALF_DOWN", + "HALF_EVEN", + "HALF_UP", + "UNNECESSARY", + "UP" + ] + } + }, + "title": "DecimalRoundingStrategy" + }, + "Duration": { + "type": "object", + "properties": { + "period": { + "type": "integer", + "format": "int32" + }, + "type": { + "type": "string", + "enum": [ + "DAYS", + "HOURS", + "MINUTES" + ] + } + }, + "title": "Duration" + }, + "EarnRevokeDetail": { + "type": "object", + "required": [ + "promotionId" + ], + "properties": { + "earnIds": { + "type": "array", + "items": { + "type": "string" + } + }, + "promotionId": { + "type": "string" + } + }, + "title": "EarnRevokeDetail" + }, + "EarnRevokeError": { + "type": "object", + "properties": { + "code": { + "type": "integer", + "format": "int64" + }, + "earnIds": { + "type": "array", + "items": { + "type": "string" + } + }, + "message": { + "type": "string" + }, + "promotionId": { + "type": "string" + } + }, + "title": "EarnRevokeError" + }, + "EarnedPromotion": { + "type": "object", + "required": [ + "earnCount", + "earnedFromId", + "promotionId" + ], + "properties": { + "earnCount": { + "type": "integer", + "format": "int32" + }, + "earnedFromId": { + "type": "string" + }, + "promotionId": { + "type": "string" + } + }, + "title": "EarnedPromotion" + }, + "EarningCriteriaRO": { + "type": "object", + "required": [ + "earnedFromType" + ], + "properties": { + "active": { + "type": "boolean" + }, + "criteriaDsl": { + "type": "string" + }, + "criteriaDslJson": { + "type": "string" + }, + "criteriaName": { + "type": "string" + }, + "duration": { + "$ref": "#/definitions/Duration" + }, + "earnedFromType": { + "type": "string", + "enum": [ + "ACTIVITY", + "BULK_ISSUE", + "MILESTONE", + "REWARD" + ] + }, + "earningValidTillDays": { + "type": "integer", + "format": "int32", + "minimum": 1, + "exclusiveMinimum": false + }, + "eventType": { + "type": "string", + "enum": [ + "CustomerRegistration", + "CustomerUpdate", + "TransactionAdd" + ] + }, + "groupId": { + "type": "integer", + "format": "int64" + }, + "milestoneId": { + "type": "integer", + "format": "int64" + }, + "storeCriteria": { + "$ref": "#/definitions/StoreCriteria" + }, + "timeCriteria": { + "$ref": "#/definitions/TimeCriteria" + } + }, + "title": "EarningCriteriaRO" + }, + "EarningCriteriaROReq": { + "type": "object", + "required": [ + "earnedFromType" + ], + "properties": { + "active": { + "type": "boolean" + }, + "criteriaDsl": { + "type": "string" + }, + "criteriaDslJson": { + "type": "string" + }, + "criteriaName": { + "type": "string" + }, + "duration": { + "$ref": "#/definitions/Duration" + }, + "earnedFromType": { + "type": "string", + "enum": [ + "ACTIVITY", + "BULK_ISSUE", + "MILESTONE", + "REWARD" + ] + }, + "earningValidTillDays": { + "type": "integer", + "format": "int32", + "minimum": 1, + "exclusiveMinimum": false + }, + "eventType": { + "type": "string", + "enum": [ + "CustomerRegistration", + "CustomerUpdate", + "TransactionAdd" + ] + }, + "groupId": { + "type": "integer", + "format": "int64" + }, + "milestoneId": { + "type": "integer", + "format": "int64" + }, + "storeCriteria": { + "$ref": "#/definitions/StoreCriteria" + }, + "timeCriteria": { + "$ref": "#/definitions/TimeCriteriaReq" + } + }, + "title": "EarningCriteriaROReq" + }, + "EarningCriteriaRORes": { + "type": "object", + "required": [ + "earnedFromType" + ], + "properties": { + "active": { + "type": "boolean" + }, + "criteriaDsl": { + "type": "string" + }, + "criteriaDslJson": { + "type": "string" + }, + "criteriaName": { + "type": "string" + }, + "duration": { + "$ref": "#/definitions/Duration" + }, + "earnedFromType": { + "type": "string", + "enum": [ + "ACTIVITY", + "BULK_ISSUE", + "MILESTONE", + "REWARD" + ] + }, + "earningValidTillDays": { + "type": "integer", + "format": "int32", + "minimum": 1, + "exclusiveMinimum": false + }, + "eventType": { + "type": "string", + "enum": [ + "CustomerRegistration", + "CustomerUpdate", + "TransactionAdd" + ] + }, + "groupId": { + "type": "integer", + "format": "int64" + }, + "milestoneId": { + "type": "integer", + "format": "int64" + }, + "storeCriteria": { + "$ref": "#/definitions/StoreCriteria" + }, + "timeCriteria": { + "$ref": "#/definitions/TimeCriteriaRes" + } + }, + "title": "EarningCriteriaRORes" + }, + "ErrorDetails": { + "type": "object", + "properties": { + "errorCode": { + "type": "integer", + "format": "int64" + }, + "errorMessages": { + "type": "string" + } + }, + "title": "ErrorDetails" + }, + "EventDetailsRO": { + "type": "object", + "properties": { + "eventPayload": { + "type": "object" + }, + "id": { + "type": "string" + }, + "type": { + "type": "string" + } + }, + "title": "EventDetailsRO" + }, + "FixedPriceAction": { + "type": "object", + "required": [ + "value" + ], + "properties": { + "productBasedCondition": { + "$ref": "#/definitions/Condition" + }, + "value": { + "type": "string" + } + }, + "title": "FixedPriceAction" + }, + "FreeProductAction": { + "type": "object", + "required": [ + "productBasedCondition" + ], + "properties": { + "productBasedCondition": { + "$ref": "#/definitions/Condition" + } + }, + "title": "FreeProductAction" + }, + "LanguageDescription": { + "type": "object", + "properties": { + "name": { + "type": "string" + }, + "type": { + "type": "string", + "enum": [ + "CUSTOM", + "STANDARD" + ] + }, + "value": { + "type": "string" + } + }, + "title": "LanguageDescription" + }, + "LocalTime": { + "type": "object", + "properties": { + "hour": { + "type": "integer", + "format": "int32" + }, + "minute": { + "type": "integer", + "format": "int32" + }, + "nano": { + "type": "integer", + "format": "int32" + }, + "second": { + "type": "integer", + "format": "int32" + } + }, + "title": "LocalTime" + }, + "LocalTimeReq": { + "type": "object", + "properties": { + "hour": { + "type": "string", + "format": "byte" + }, + "minute": { + "type": "string", + "format": "byte" + }, + "nano": { + "type": "integer", + "format": "int32" + }, + "second": { + "type": "string", + "format": "byte" + } + }, + "title": "LocalTimeReq" + }, + "LocalTimeRes": { + "type": "object", + "properties": { + "hour": { + "type": "integer", + "format": "int32" + }, + "minute": { + "type": "integer", + "format": "int32" + }, + "nano": { + "type": "integer", + "format": "int32" + }, + "second": { + "type": "integer", + "format": "int32" + } + }, + "title": "LocalTimeRes" + }, + "MultiLanguageDetails": { + "type": "object", + "required": [ + "languageCode", + "languageDescriptionList" + ], + "properties": { + "languageCode": { + "type": "string" + }, + "languageDescriptionList": { + "type": "array", + "items": { + "$ref": "#/definitions/LanguageDescription" + } + } + }, + "title": "MultiLanguageDetails" + }, + "ProductBasedAction": { + "type": "object", + "required": [ + "type", + "value" + ], + "properties": { + "productBasedCondition": { + "$ref": "#/definitions/Condition" + }, + "type": { + "type": "string", + "enum": [ + "ABSOLUTE", + "PERCENTAGE" + ] + }, + "value": { + "type": "string" + } + }, + "title": "ProductBasedAction" + }, + "ProductCondition": { + "type": "object", + "required": [ + "criteriaList", + "kpi" + ], + "properties": { + "criteriaList": { + "type": "array", + "items": { + "$ref": "#/definitions/ProductSelectionCriteriaRO" + } + }, + "kpi": { + "type": "string", + "enum": [ + "AMOUNT", + "NONE", + "QUANTITY" + ] + }, + "operator": { + "type": "string", + "enum": [ + "EQUALS", + "GREATER_THAN", + "GREATER_THAN_OR_EQUAL", + "IN", + "LESS_THAN", + "LESS_THAN_OR_EQUAL", + "NONE" + ] + }, + "value": { + "type": "string" + } + }, + "title": "ProductCondition" + }, + "ProductSelectionCriteriaRO": { + "type": "object", + "required": [ + "entity", + "values" + ], + "properties": { + "attributeName": { + "type": "string" + }, + "entity": { + "type": "string", + "enum": [ + "ATTRIBUTE", + "BRAND", + "CATEGORY", + "SKU" + ] + }, + "operator": { + "type": "string", + "enum": [ + "IN", + "NOT_IN" + ] + }, + "values": { + "type": "array", + "items": { + "type": "string" + } + } + }, + "title": "ProductSelectionCriteriaRO" + }, + "PromotionConfigRO": { + "type": "object", + "properties": { + "customFieldValues": { + "type": "object", + "additionalProperties": { + "type": "string" + } + }, + "description": { + "type": "string" + }, + "expiry": { + "type": "integer", + "format": "int64" + }, + "groupId": { + "type": "integer", + "format": "int64" + }, + "isActive": { + "type": "boolean" + }, + "maxEarningPerCustomer": { + "type": "integer", + "format": "int32" + }, + "milestoneId": { + "type": "integer", + "format": "int64" + }, + "promotionId": { + "type": "string" + }, + "promotionName": { + "type": "string" + }, + "promotionRestrictions": { + "type": "object", + "additionalProperties": { + "type": "array", + "items": { + "$ref": "#/definitions/RestrictionKPIRO" + } + } + }, + "promotionType": { + "type": "string", + "enum": [ + "CODE", + "CUSTOMER", + "EARNING", + "POS", + "REWARD" + ] + }, + "reward": { + "type": "string" + }, + "ruleId": { + "type": "integer", + "format": "int64" + }, + "storeCriteria": { + "$ref": "#/definitions/StoreCriteria" + }, + "supplementaryCriteria": { + "$ref": "#/definitions/SupplementaryCriteria" + } + }, + "title": "PromotionConfigRO" + }, + "PromotionExpiryReminderRO": { + "type": "object", + "required": [ + "communicationChannels", + "numberOfDaysBeforeExpiry" + ], + "properties": { + "active": { + "type": "boolean" + }, + "communicationChannels": { + "type": "object", + "additionalProperties": { + "$ref": "#/definitions/CommunicationChannelRO" + } + }, + "createdBy": { + "type": "integer", + "format": "int64" + }, + "createdOn": { + "type": "integer", + "format": "int64" + }, + "id": { + "type": "string" + }, + "lastUpdatedBy": { + "type": "integer", + "format": "int64" + }, + "lastUpdatedOn": { + "type": "integer", + "format": "int64" + }, + "numberOfDaysBeforeExpiry": { + "type": "integer", + "format": "int32", + "minimum": 0, + "exclusiveMinimum": false + }, + "promotionId": { + "type": "string" + } + }, + "title": "PromotionExpiryReminderRO" + }, + "PromotionLanguageRO": { + "type": "object", + "required": [ + "entity", + "entityId", + "multiLanguageDetails" + ], + "properties": { + "entity": { + "type": "string", + "enum": [ + "PROMOTION_META" + ] + }, + "entityId": { + "type": "string" + }, + "multiLanguageDetails": { + "type": "array", + "items": { + "$ref": "#/definitions/MultiLanguageDetails" + } + } + }, + "title": "PromotionLanguageRO" + }, + "PromotionLogRO": { + "type": "object", + "properties": { + "earnedPromotionId": { + "type": "string" + }, + "evaluationStatus": { + "type": "boolean" + }, + "logType": { + "type": "string" + }, + "message": { + "type": "string" + }, + "promoCode": { + "type": "string" + }, + "promotionId": { + "type": "string" + } + }, + "title": "PromotionLogRO" + }, + "PromotionMetaRO": { + "type": "object", + "required": [ + "action", + "campaignId", + "endDate", + "name", + "startDate", + "type" + ], + "properties": { + "action": { + "$ref": "#/definitions/Action" + }, + "active": { + "type": "boolean" + }, + "campaignId": { + "type": "integer", + "format": "int64" + }, + "condition": { + "$ref": "#/definitions/Condition" + }, + "createdBy": { + "type": "integer", + "format": "int64" + }, + "createdOn": { + "type": "string", + "format": "date-time" + }, + "customFieldValues": { + "type": "object", + "additionalProperties": { + "type": "string" + } + }, + "customerActivationRequired": { + "type": "boolean" + }, + "earnLimitedToSpecificAudience": { + "type": "boolean" + }, + "earningCriteria": { + "$ref": "#/definitions/EarningCriteriaRO" + }, + "endDate": { + "type": "integer", + "format": "int64" + }, + "id": { + "type": "string" + }, + "isLoyaltyOnly": { + "type": "boolean" + }, + "languagesConfigured": { + "type": "array", + "items": { + "type": "string" + } + }, + "lastUpdatedBy": { + "type": "integer", + "format": "int64" + }, + "lastUpdatedOn": { + "type": "string", + "format": "date-time" + }, + "loyaltyEarningExpiryDays": { + "type": "integer", + "format": "int32" + }, + "maxEarningPerCustomer": { + "type": "integer", + "format": "int32" + }, + "maxIssuancePerCustomer": { + "type": "integer", + "format": "int32", + "minimum": 1, + "maximum": 10, + "exclusiveMinimum": false, + "exclusiveMaximum": false + }, + "messageLabel": { + "type": "string" + }, + "mode": { + "type": "string", + "enum": [ + "DISCOUNT", + "PAYMENT_VOUCHER" + ] + }, + "name": { + "type": "string", + "minLength": 1, + "maxLength": 50 + }, + "onEarnCommunicationChannels": { + "type": "object", + "additionalProperties": { + "$ref": "#/definitions/CommunicationChannelRO" + } + }, + "orgId": { + "type": "integer", + "format": "int64" + }, + "priority": { + "type": "integer", + "format": "int32" + }, + "promotionRestrictions": { + "type": "object", + "additionalProperties": { + "type": "array", + "items": { + "$ref": "#/definitions/RestrictionKPIRO" + } + } + }, + "startDate": { + "type": "integer", + "format": "int64" + }, + "storeCriteria": { + "$ref": "#/definitions/StoreCriteria" + }, + "supplementaryCriteria": { + "$ref": "#/definitions/SupplementaryCriteria" + }, + "timeCriteria": { + "$ref": "#/definitions/TimeCriteria" + }, + "type": { + "type": "string", + "enum": [ + "CODE", + "CUSTOMER", + "EARNING", + "POS", + "REWARD" + ] + } + }, + "title": "PromotionMetaRO" + }, + "PromotionMetaROReq": { + "type": "object", + "required": [ + "action", + "campaignId", + "endDate", + "name", + "startDate", + "type" + ], + "properties": { + "action": { + "$ref": "#/definitions/Action" + }, + "active": { + "type": "boolean" + }, + "campaignId": { + "type": "integer", + "format": "int64" + }, + "condition": { + "$ref": "#/definitions/Condition" + }, + "createdBy": { + "type": "integer", + "format": "int64" + }, + "createdOn": { + "type": "string", + "format": "date-time" + }, + "customFieldValues": { + "type": "object", + "additionalProperties": { + "type": "string" + } + }, + "customerActivationRequired": { + "type": "boolean" + }, + "earnLimitedToSpecificAudience": { + "type": "boolean" + }, + "earningCriteria": { + "$ref": "#/definitions/EarningCriteriaROReq" + }, + "endDate": { + "type": "integer", + "format": "int64" + }, + "id": { + "type": "string" + }, + "isLoyaltyOnly": { + "type": "boolean" + }, + "languagesConfigured": { + "type": "array", + "items": { + "type": "string" + } + }, + "lastUpdatedBy": { + "type": "integer", + "format": "int64" + }, + "lastUpdatedOn": { + "type": "string", + "format": "date-time" + }, + "loyaltyEarningExpiryDays": { + "type": "integer", + "format": "int32" + }, + "maxEarningPerCustomer": { + "type": "integer", + "format": "int32" + }, + "maxIssuancePerCustomer": { + "type": "integer", + "format": "int32", + "minimum": 1, + "maximum": 10, + "exclusiveMinimum": false, + "exclusiveMaximum": false + }, + "messageLabel": { + "type": "string" + }, + "mode": { + "type": "string", + "enum": [ + "DISCOUNT", + "PAYMENT_VOUCHER" + ] + }, + "name": { + "type": "string", + "minLength": 1, + "maxLength": 50 + }, + "onEarnCommunicationChannels": { + "type": "object", + "additionalProperties": { + "$ref": "#/definitions/CommunicationChannelRO" + } + }, + "orgId": { + "type": "integer", + "format": "int64" + }, + "priority": { + "type": "integer", + "format": "int32" + }, + "promotionRestrictions": { + "type": "object", + "additionalProperties": { + "type": "array", + "items": { + "$ref": "#/definitions/RestrictionKPIRO" + } + } + }, + "startDate": { + "type": "integer", + "format": "int64" + }, + "storeCriteria": { + "$ref": "#/definitions/StoreCriteria" + }, + "supplementaryCriteria": { + "$ref": "#/definitions/SupplementaryCriteria" + }, + "timeCriteria": { + "$ref": "#/definitions/TimeCriteriaReq" + }, + "type": { + "type": "string", + "enum": [ + "CODE", + "CUSTOMER", + "EARNING", + "POS", + "REWARD" + ] + } + }, + "title": "PromotionMetaROReq" + }, + "PromotionMetaRORes": { + "type": "object", + "required": [ + "action", + "campaignId", + "endDate", + "name", + "startDate", + "type" + ], + "properties": { + "action": { + "$ref": "#/definitions/Action" + }, + "active": { + "type": "boolean" + }, + "campaignId": { + "type": "integer", + "format": "int64" + }, + "condition": { + "$ref": "#/definitions/Condition" + }, + "createdBy": { + "type": "integer", + "format": "int64" + }, + "createdOn": { + "type": "string", + "format": "date-time" + }, + "customFieldValues": { + "type": "object", + "additionalProperties": { + "type": "string" + } + }, + "customerActivationRequired": { + "type": "boolean" + }, + "earnLimitedToSpecificAudience": { + "type": "boolean" + }, + "earningCriteria": { + "$ref": "#/definitions/EarningCriteriaRORes" + }, + "endDate": { + "type": "integer", + "format": "int64" + }, + "id": { + "type": "string" + }, + "isLoyaltyOnly": { + "type": "boolean" + }, + "languagesConfigured": { + "type": "array", + "items": { + "type": "string" + } + }, + "lastUpdatedBy": { + "type": "integer", + "format": "int64" + }, + "lastUpdatedOn": { + "type": "string", + "format": "date-time" + }, + "loyaltyEarningExpiryDays": { + "type": "integer", + "format": "int32" + }, + "maxEarningPerCustomer": { + "type": "integer", + "format": "int32" + }, + "maxIssuancePerCustomer": { + "type": "integer", + "format": "int32", + "minimum": 1, + "maximum": 10, + "exclusiveMinimum": false, + "exclusiveMaximum": false + }, + "messageLabel": { + "type": "string" + }, + "mode": { + "type": "string", + "enum": [ + "DISCOUNT", + "PAYMENT_VOUCHER" + ] + }, + "name": { + "type": "string", + "minLength": 1, + "maxLength": 50 + }, + "onEarnCommunicationChannels": { + "type": "object", + "additionalProperties": { + "$ref": "#/definitions/CommunicationChannelRO" + } + }, + "orgId": { + "type": "integer", + "format": "int64" + }, + "priority": { + "type": "integer", + "format": "int32" + }, + "promotionRestrictions": { + "type": "object", + "additionalProperties": { + "type": "array", + "items": { + "$ref": "#/definitions/RestrictionKPIRO" + } + } + }, + "startDate": { + "type": "integer", + "format": "int64" + }, + "storeCriteria": { + "$ref": "#/definitions/StoreCriteria" + }, + "supplementaryCriteria": { + "$ref": "#/definitions/SupplementaryCriteria" + }, + "timeCriteria": { + "$ref": "#/definitions/TimeCriteriaRes" + }, + "type": { + "type": "string", + "enum": [ + "CODE", + "CUSTOMER", + "EARNING", + "POS", + "REWARD" + ] + } + }, + "title": "PromotionMetaRORes" + }, + "PromotionRedemptionRO": { + "type": "object", + "properties": { + "amount": { + "type": "string" + }, + "cartEvaluationId": { + "type": "string" + }, + "customerId": { + "type": "integer", + "format": "int64" + }, + "discount": { + "type": "string" + }, + "discountAppliedQuantity": { + "type": "string" + }, + "earnedPromotionId": { + "type": "string" + }, + "id": { + "type": "string" + }, + "orgId": { + "type": "integer", + "format": "int64" + }, + "productId": { + "type": "integer", + "format": "int64" + }, + "promoCode": { + "type": "string" + }, + "promotionAppliedQuantity": { + "type": "string" + }, + "promotionId": { + "type": "string" + }, + "promotionMessageLabel": { + "type": "string" + }, + "promotionName": { + "type": "string" + }, + "redemptionCount": { + "type": "integer", + "format": "int64" + }, + "redemptionDate": { + "type": "string", + "format": "date-time" + }, + "redemptionTill": { + "type": "integer", + "format": "int64" + }, + "redemptionType": { + "type": "string", + "enum": [ + "CART", + "LINEITEM", + "PAYMENT_VOUCHER" + ] + }, + "sku": { + "type": "string" + }, + "taxEntityId": { + "type": "string" + }, + "transactionEntityIdentifier": { + "type": "string" + }, + "transactionIdentifier": { + "type": "string" + }, + "transactionNumber": { + "type": "string" + } + }, + "title": "PromotionRedemptionRO" + }, + "PromotionStrategyRO": { + "type": "object", + "required": [ + "promotionRankingStrategies" + ], + "properties": { + "conditionBasedRankingStrategy": { + "type": "string", + "enum": [ + "CART_BASED_FIRST", + "LINE_ITEM_BASED_FIRST" + ] + }, + "decimalRoundingStrategy": { + "$ref": "#/definitions/DecimalRoundingStrategy" + }, + "isActive": { + "type": "boolean" + }, + "mode": { + "type": "string", + "enum": [ + "DISCOUNT", + "PAYMENT_VOUCHER" + ] + }, + "promotionRankingStrategies": { + "type": "array", + "items": { + "type": "string", + "enum": [ + "BEST_COMBINATION", + "EXPIRY_BASED", + "MAX_DISCOUNT", + "MIN_DISCOUNT", + "PRIORITY" + ] + } + }, + "rewardRankingStrategies": { + "type": "array", + "items": { + "type": "string", + "enum": [ + "CODE_FIRST", + "NO_STRATEGY", + "PROMOTION_FIRST", + "REWARDS_FIRST" + ] + } + }, + "rewardStrategy": { + "type": "string", + "enum": [ + "CODE_FIRST", + "NO_STRATEGY", + "PROMOTION_FIRST", + "REWARDS_FIRST" + ] + }, + "singlePromotionPerLineitem": { + "type": "boolean" + } + }, + "title": "PromotionStrategyRO" + }, + "PromotionSummaryRO": { + "type": "object", + "properties": { + "customFieldValues": { + "type": "object", + "additionalProperties": { + "type": "string" + } + }, + "endDate": { + "type": "integer", + "format": "int64" + }, + "isActive": { + "type": "boolean" + }, + "lastEarned": { + "type": "integer", + "format": "int64" + }, + "lastRedeemed": { + "type": "integer", + "format": "int64" + }, + "orgId": { + "type": "integer", + "format": "int64" + }, + "promotionId": { + "type": "string" + }, + "promotionName": { + "type": "string" + }, + "promotionType": { + "type": "string", + "enum": [ + "CODE", + "CUSTOMER", + "EARNING", + "POS", + "REWARD" + ] + }, + "startDate": { + "type": "integer", + "format": "int64" + }, + "supplementaryCriteria": { + "$ref": "#/definitions/SupplementaryCriteria" + }, + "targetedCustomerCount": { + "type": "integer", + "format": "int64" + }, + "totalDiscount": { + "type": "string" + }, + "totalDiscountAppliedQuantity": { + "type": "number", + "format": "double" + }, + "totalEarned": { + "type": "string" + }, + "totalIssuedCount": { + "type": "integer", + "format": "int64" + }, + "totalPromoCodeCreated": { + "type": "integer", + "format": "int64" + }, + "totalPromotionAppliedQuantity": { + "type": "number", + "format": "double" + }, + "totalRedeemed": { + "type": "integer", + "format": "int64" + }, + "totalTransactions": { + "type": "integer", + "format": "int64" + } + }, + "title": "PromotionSummaryRO" + }, + "PushNotificationCtaActionRO": { + "type": "object", + "properties": { + "actionLink": { + "type": "string" + }, + "actionText": { + "type": "string" + }, + "templateCtaId": { + "type": "string" + }, + "type": { + "type": "string", + "enum": [ + "DEEP_LINK", + "EXTERNAL_URL" + ] + } + }, + "title": "PushNotificationCtaActionRO" + }, + "PushNotificationCtaRO": { + "type": "object", + "properties": { + "actionLink": { + "type": "string" + }, + "image": { + "type": "string" + }, + "pushNotificationCtaActionList": { + "type": "array", + "items": { + "$ref": "#/definitions/PushNotificationCtaActionRO" + } + }, + "type": { + "type": "string", + "enum": [ + "DEEP_LINK", + "EXTERNAL_URL" + ] + } + }, + "title": "PushNotificationCtaRO" + }, + "ResponseWrapper«CartEvaluationRO»": { + "type": "object", + "properties": { + "data": { + "$ref": "#/definitions/CartEvaluationRO" + }, + "errors": { + "type": "array", + "items": { + "$ref": "#/definitions/ApiError" + } + } + }, + "title": "ResponseWrapper«CartEvaluationRO»" + }, + "ResponseWrapper«CartRO»": { + "type": "object", + "properties": { + "data": { + "$ref": "#/definitions/CartRORes" + }, + "errors": { + "type": "array", + "items": { + "$ref": "#/definitions/ApiError" + } + } + }, + "title": "ResponseWrapper«CartRO»" + }, + "ResponseWrapper«CodeBasedPromotionMetaRO»": { + "type": "object", + "properties": { + "data": { + "$ref": "#/definitions/CodeBasedPromotionMetaRO" + }, + "errors": { + "type": "array", + "items": { + "$ref": "#/definitions/ApiError" + } + } + }, + "title": "ResponseWrapper«CodeBasedPromotionMetaRO»" + }, + "ResponseWrapper«CodeBasedPromotionRO»": { + "type": "object", + "properties": { + "data": { + "$ref": "#/definitions/CodeBasedPromotionRO" + }, + "errors": { + "type": "array", + "items": { + "$ref": "#/definitions/ApiError" + } + } + }, + "title": "ResponseWrapper«CodeBasedPromotionRO»" + }, + "ResponseWrapper«CustomerEarnedPromotionRO»": { + "type": "object", + "properties": { + "data": { + "$ref": "#/definitions/CustomerEarnedPromotionRO" + }, + "errors": { + "type": "array", + "items": { + "$ref": "#/definitions/ApiError" + } + } + }, + "title": "ResponseWrapper«CustomerEarnedPromotionRO»" + }, + "ResponseWrapper«List«AuditLogVersionRO»»": { + "type": "object", + "properties": { + "data": { + "type": "array", + "items": { + "$ref": "#/definitions/AuditLogVersionRO" + } + }, + "errors": { + "type": "array", + "items": { + "$ref": "#/definitions/ApiError" + } + } + }, + "title": "ResponseWrapper«List«AuditLogVersionRO»»" + }, + "ResponseWrapper«List«BulkEarnedPromotionRO»»": { + "type": "object", + "properties": { + "data": { + "type": "array", + "items": { + "$ref": "#/definitions/BulkEarnedPromotionRO" + } + }, + "errors": { + "type": "array", + "items": { + "$ref": "#/definitions/ApiError" + } + } + }, + "title": "ResponseWrapper«List«BulkEarnedPromotionRO»»" + }, + "ResponseWrapper«List«CodeBasedPromotionMetaRO»»": { + "type": "object", + "properties": { + "data": { + "type": "array", + "items": { + "$ref": "#/definitions/CodeBasedPromotionMetaRO" + } + }, + "errors": { + "type": "array", + "items": { + "$ref": "#/definitions/ApiError" + } + } + }, + "title": "ResponseWrapper«List«CodeBasedPromotionMetaRO»»" + }, + "ResponseWrapper«List«CodeBasedPromotionRO»»": { + "type": "object", + "properties": { + "data": { + "type": "array", + "items": { + "$ref": "#/definitions/CodeBasedPromotionRO" + } + }, + "errors": { + "type": "array", + "items": { + "$ref": "#/definitions/ApiError" + } + } + }, + "title": "ResponseWrapper«List«CodeBasedPromotionRO»»" + }, + "ResponseWrapper«List«CustomMetadataFieldRO»»": { + "type": "object", + "properties": { + "data": { + "type": "array", + "items": { + "$ref": "#/definitions/CustomMetadataFieldRO" + } + }, + "errors": { + "type": "array", + "items": { + "$ref": "#/definitions/ApiError" + } + } + }, + "title": "ResponseWrapper«List«CustomMetadataFieldRO»»" + }, + "ResponseWrapper«List«CustomerPromotionRO»»": { + "type": "object", + "properties": { + "data": { + "type": "array", + "items": { + "$ref": "#/definitions/CustomerPromotionRO" + } + }, + "errors": { + "type": "array", + "items": { + "$ref": "#/definitions/ApiError" + } + } + }, + "title": "ResponseWrapper«List«CustomerPromotionRO»»" + }, + "ResponseWrapper«List«PromotionConfigRO»»": { + "type": "object", + "properties": { + "data": { + "type": "array", + "items": { + "$ref": "#/definitions/PromotionConfigRO" + } + }, + "errors": { + "type": "array", + "items": { + "$ref": "#/definitions/ApiError" + } + } + }, + "title": "ResponseWrapper«List«PromotionConfigRO»»" + }, + "ResponseWrapper«List«PromotionExpiryReminderRO»»": { + "type": "object", + "properties": { + "data": { + "type": "array", + "items": { + "$ref": "#/definitions/PromotionExpiryReminderRO" + } + }, + "errors": { + "type": "array", + "items": { + "$ref": "#/definitions/ApiError" + } + } + }, + "title": "ResponseWrapper«List«PromotionExpiryReminderRO»»" + }, + "ResponseWrapper«List«PromotionMetaRO»»": { + "type": "object", + "properties": { + "data": { + "type": "array", + "items": { + "$ref": "#/definitions/PromotionMetaRO" + } + }, + "errors": { + "type": "array", + "items": { + "$ref": "#/definitions/ApiError" + } + } + }, + "title": "ResponseWrapper«List«PromotionMetaRO»»" + }, + "ResponseWrapper«List«PromotionRedemptionRO»»": { + "type": "object", + "properties": { + "data": { + "type": "array", + "items": { + "$ref": "#/definitions/PromotionRedemptionRO" + } + }, + "errors": { + "type": "array", + "items": { + "$ref": "#/definitions/ApiError" + } + } + }, + "title": "ResponseWrapper«List«PromotionRedemptionRO»»" + }, + "ResponseWrapper«List«PromotionSummaryRO»»": { + "type": "object", + "properties": { + "data": { + "type": "array", + "items": { + "$ref": "#/definitions/PromotionSummaryRO" + } + }, + "errors": { + "type": "array", + "items": { + "$ref": "#/definitions/ApiError" + } + } + }, + "title": "ResponseWrapper«List«PromotionSummaryRO»»" + }, + "ResponseWrapper«Map«long,CustomerEarnedPromotionRO»»": { + "type": "object", + "properties": { + "data": { + "type": "object", + "additionalProperties": { + "$ref": "#/definitions/CustomerEarnedPromotionRO" + } + }, + "errors": { + "type": "array", + "items": { + "$ref": "#/definitions/ApiError" + } + } + }, + "title": "ResponseWrapper«Map«long,CustomerEarnedPromotionRO»»" + }, + "ResponseWrapper«PromotionExpiryReminderRO»": { + "type": "object", + "properties": { + "data": { + "$ref": "#/definitions/PromotionExpiryReminderRO" + }, + "errors": { + "type": "array", + "items": { + "$ref": "#/definitions/ApiError" + } + } + }, + "title": "ResponseWrapper«PromotionExpiryReminderRO»" + }, + "ResponseWrapper«PromotionLanguageRO»": { + "type": "object", + "properties": { + "data": { + "$ref": "#/definitions/PromotionLanguageRO" + }, + "errors": { + "type": "array", + "items": { + "$ref": "#/definitions/ApiError" + } + } + }, + "title": "ResponseWrapper«PromotionLanguageRO»" + }, + "ResponseWrapper«PromotionMetaRO»": { + "type": "object", + "properties": { + "data": { + "$ref": "#/definitions/PromotionMetaRORes" + }, + "errors": { + "type": "array", + "items": { + "$ref": "#/definitions/ApiError" + } + } + }, + "title": "ResponseWrapper«PromotionMetaRO»" + }, + "ResponseWrapper«PromotionStrategyRO»": { + "type": "object", + "properties": { + "data": { + "$ref": "#/definitions/PromotionStrategyRO" + }, + "errors": { + "type": "array", + "items": { + "$ref": "#/definitions/ApiError" + } + } + }, + "title": "ResponseWrapper«PromotionStrategyRO»" + }, + "ResponseWrapper«boolean»": { + "type": "object", + "properties": { + "data": { + "type": "boolean" + }, + "errors": { + "type": "array", + "items": { + "$ref": "#/definitions/ApiError" + } + } + }, + "title": "ResponseWrapper«boolean»" + }, + "ResponseWrapper«object»": { + "type": "object", + "properties": { + "data": { + "type": "object" + }, + "errors": { + "type": "array", + "items": { + "$ref": "#/definitions/ApiError" + } + } + }, + "title": "ResponseWrapper«object»" + }, + "RestrictionDetailsRO": { + "type": "object", + "properties": { + "kpi": { + "type": "string", + "enum": [ + "DISCOUNT", + "REDEMPTION", + "TRANSACTION" + ] + }, + "maxLimit": { + "type": "string" + }, + "periodEnd": { + "type": "integer", + "format": "int64" + }, + "periodStart": { + "type": "integer", + "format": "int64" + }, + "remainingRedemption": { + "type": "string" + } + }, + "title": "RestrictionDetailsRO" + }, + "RestrictionKPIRO": { + "type": "object", + "properties": { + "frequency": { + "type": "string", + "enum": [ + "DAYS", + "WEEKS" + ] + }, + "kpi": { + "type": "string", + "enum": [ + "DISCOUNT", + "REDEMPTION", + "TRANSACTION" + ] + }, + "limit": { + "type": "string" + }, + "minTimeBetweenRepeat": { + "type": "integer", + "format": "int64" + } + }, + "title": "RestrictionKPIRO" + }, + "RevokeEarnRequest": { + "type": "object", + "required": [ + "customerId" + ], + "properties": { + "customerId": { + "type": "integer", + "format": "int64" + }, + "earnRevokeDetails": { + "type": "array", + "items": { + "$ref": "#/definitions/EarnRevokeDetail" + } + } + }, + "title": "RevokeEarnRequest" + }, + "RevokeEarnResponse": { + "type": "object", + "properties": { + "code": { + "type": "integer", + "format": "int64" + }, + "message": { + "type": "string" + } + }, + "title": "RevokeEarnResponse" + }, + "SaveCodeRequest": { + "type": "object", + "required": [ + "code", + "customerId", + "mode" + ], + "properties": { + "code": { + "type": "string" + }, + "customerId": { + "type": "integer", + "format": "int64", + "minimum": 1, + "exclusiveMinimum": false + }, + "mode": { + "type": "string", + "enum": [ + "DISCOUNT", + "PAYMENT_VOUCHER" + ] + } + }, + "title": "SaveCodeRequest" + }, + "StoreCriteria": { + "type": "object", + "required": [ + "operator", + "type", + "values" + ], + "properties": { + "operator": { + "type": "string", + "enum": [ + "IN", + "NOT_IN" + ] + }, + "type": { + "type": "string", + "enum": [ + "CONCEPT", + "STORE", + "ZONE" + ] + }, + "values": { + "type": "array", + "items": { + "type": "integer", + "format": "int64" + } + } + }, + "title": "StoreCriteria" + }, + "SupplementaryCriteria": { + "type": "object", + "required": [ + "loyaltyProgramId", + "partnerProgramId", + "programType" + ], + "properties": { + "loyaltyProgramId": { + "type": "integer", + "format": "int64" + }, + "partnerProgramId": { + "type": "integer", + "format": "int32" + }, + "programType": { + "type": "string", + "enum": [ + "SUBSCRIPTION", + "TIER" + ] + } + }, + "title": "SupplementaryCriteria" + }, + "TenderBasedAction": { + "type": "object", + "required": [ + "type", + "value" + ], + "properties": { + "type": { + "type": "string", + "enum": [ + "ABSOLUTE", + "PERCENTAGE" + ] + }, + "value": { + "type": "string" + } + }, + "title": "TenderBasedAction" + }, + "TenderCondition": { + "type": "object", + "required": [ + "type" + ], + "properties": { + "condition": { + "$ref": "#/definitions/Condition" + }, + "identifier": { + "type": "string" + }, + "type": { + "type": "string", + "enum": [ + "CARD", + "CASH", + "PAYMENT_VOUCHER" + ] + } + }, + "title": "TenderCondition" + }, + "TimeCriteria": { + "type": "object", + "properties": { + "durationInHours": { + "type": "integer", + "format": "int32" + }, + "monthlyDayValues": { + "type": "array", + "items": { + "type": "integer", + "format": "int32" + } + }, + "repeatFrequency": { + "type": "string", + "enum": [ + "DAYS", + "DOES_NOT_REPEAT", + "WEEKS" + ] + }, + "startTime": { + "$ref": "#/definitions/LocalTime" + }, + "weeklyValues": { + "type": "array", + "items": { + "type": "string", + "enum": [ + "FRIDAY", + "MONDAY", + "SATURDAY", + "SUNDAY", + "THURSDAY", + "TUESDAY", + "WEDNESDAY" + ] + } + } + }, + "title": "TimeCriteria" + }, + "TimeCriteriaReq": { + "type": "object", + "properties": { + "durationInHours": { + "type": "integer", + "format": "int32" + }, + "monthlyDayValues": { + "type": "array", + "items": { + "type": "integer", + "format": "int32" + } + }, + "repeatFrequency": { + "type": "string", + "enum": [ + "DAYS", + "DOES_NOT_REPEAT", + "WEEKS" + ] + }, + "startTime": { + "$ref": "#/definitions/LocalTimeReq" + }, + "weeklyValues": { + "type": "array", + "items": { + "type": "string", + "enum": [ + "FRIDAY", + "MONDAY", + "SATURDAY", + "SUNDAY", + "THURSDAY", + "TUESDAY", + "WEDNESDAY" + ] + } + } + }, + "title": "TimeCriteriaReq" + }, + "TimeCriteriaRes": { + "type": "object", + "properties": { + "durationInHours": { + "type": "integer", + "format": "int32" + }, + "monthlyDayValues": { + "type": "array", + "items": { + "type": "integer", + "format": "int32" + } + }, + "repeatFrequency": { + "type": "string", + "enum": [ + "DAYS", + "DOES_NOT_REPEAT", + "WEEKS" + ] + }, + "startTime": { + "$ref": "#/definitions/LocalTimeRes" + }, + "weeklyValues": { + "type": "array", + "items": { + "type": "string", + "enum": [ + "FRIDAY", + "MONDAY", + "SATURDAY", + "SUNDAY", + "THURSDAY", + "TUESDAY", + "WEDNESDAY" + ] + } + } + }, + "title": "TimeCriteriaRes" + }, + "UploadedFileRO": { + "type": "object", + "properties": { + "codeColumnIndex": { + "type": "integer", + "format": "int32" + }, + "containsHeader": { + "type": "boolean" + }, + "fileHandle": { + "type": "string" + } + }, + "title": "UploadedFileRO" + } + } +} diff --git a/samples/client/petstore-security-test/java/okhttp-gson/src/main/gen/io/swagger/client/BuildConfig.java b/samples/client/petstore-security-test/java/okhttp-gson/src/main/gen/io/swagger/client/BuildConfig.java new file mode 100644 index 00000000000..720765940d3 --- /dev/null +++ b/samples/client/petstore-security-test/java/okhttp-gson/src/main/gen/io/swagger/client/BuildConfig.java @@ -0,0 +1,8 @@ +/*___Generated_by_IDEA___*/ + +package io.swagger.client; + +/* This stub is only used by the IDE. It is NOT the BuildConfig class actually packed into the APK */ +public final class BuildConfig { + public final static boolean DEBUG = Boolean.parseBoolean(null); +} \ No newline at end of file diff --git a/samples/client/petstore-security-test/java/okhttp-gson/src/main/gen/io/swagger/client/Manifest.java b/samples/client/petstore-security-test/java/okhttp-gson/src/main/gen/io/swagger/client/Manifest.java new file mode 100644 index 00000000000..41e0523a208 --- /dev/null +++ b/samples/client/petstore-security-test/java/okhttp-gson/src/main/gen/io/swagger/client/Manifest.java @@ -0,0 +1,7 @@ +/*___Generated_by_IDEA___*/ + +package io.swagger.client; + +/* This stub is only used by the IDE. It is NOT the Manifest class actually packed into the APK */ +public final class Manifest { +} \ No newline at end of file diff --git a/samples/client/petstore-security-test/java/okhttp-gson/src/main/gen/io/swagger/client/R.java b/samples/client/petstore-security-test/java/okhttp-gson/src/main/gen/io/swagger/client/R.java new file mode 100644 index 00000000000..cd0683364d5 --- /dev/null +++ b/samples/client/petstore-security-test/java/okhttp-gson/src/main/gen/io/swagger/client/R.java @@ -0,0 +1,7 @@ +/*___Generated_by_IDEA___*/ + +package io.swagger.client; + +/* This stub is only used by the IDE. It is NOT the R class actually packed into the APK */ +public final class R { +} \ No newline at end of file diff --git a/samples/client/petstore/java/feign/src/main/gen/io/swagger/client/BuildConfig.java b/samples/client/petstore/java/feign/src/main/gen/io/swagger/client/BuildConfig.java new file mode 100644 index 00000000000..720765940d3 --- /dev/null +++ b/samples/client/petstore/java/feign/src/main/gen/io/swagger/client/BuildConfig.java @@ -0,0 +1,8 @@ +/*___Generated_by_IDEA___*/ + +package io.swagger.client; + +/* This stub is only used by the IDE. It is NOT the BuildConfig class actually packed into the APK */ +public final class BuildConfig { + public final static boolean DEBUG = Boolean.parseBoolean(null); +} \ No newline at end of file diff --git a/samples/client/petstore/java/feign/src/main/gen/io/swagger/client/Manifest.java b/samples/client/petstore/java/feign/src/main/gen/io/swagger/client/Manifest.java new file mode 100644 index 00000000000..41e0523a208 --- /dev/null +++ b/samples/client/petstore/java/feign/src/main/gen/io/swagger/client/Manifest.java @@ -0,0 +1,7 @@ +/*___Generated_by_IDEA___*/ + +package io.swagger.client; + +/* This stub is only used by the IDE. It is NOT the Manifest class actually packed into the APK */ +public final class Manifest { +} \ No newline at end of file diff --git a/samples/client/petstore/java/feign/src/main/gen/io/swagger/client/R.java b/samples/client/petstore/java/feign/src/main/gen/io/swagger/client/R.java new file mode 100644 index 00000000000..cd0683364d5 --- /dev/null +++ b/samples/client/petstore/java/feign/src/main/gen/io/swagger/client/R.java @@ -0,0 +1,7 @@ +/*___Generated_by_IDEA___*/ + +package io.swagger.client; + +/* This stub is only used by the IDE. It is NOT the R class actually packed into the APK */ +public final class R { +} \ No newline at end of file diff --git a/samples/client/petstore/java/jersey1/src/main/gen/io/swagger/client/BuildConfig.java b/samples/client/petstore/java/jersey1/src/main/gen/io/swagger/client/BuildConfig.java new file mode 100644 index 00000000000..720765940d3 --- /dev/null +++ b/samples/client/petstore/java/jersey1/src/main/gen/io/swagger/client/BuildConfig.java @@ -0,0 +1,8 @@ +/*___Generated_by_IDEA___*/ + +package io.swagger.client; + +/* This stub is only used by the IDE. It is NOT the BuildConfig class actually packed into the APK */ +public final class BuildConfig { + public final static boolean DEBUG = Boolean.parseBoolean(null); +} \ No newline at end of file diff --git a/samples/client/petstore/java/jersey1/src/main/gen/io/swagger/client/Manifest.java b/samples/client/petstore/java/jersey1/src/main/gen/io/swagger/client/Manifest.java new file mode 100644 index 00000000000..41e0523a208 --- /dev/null +++ b/samples/client/petstore/java/jersey1/src/main/gen/io/swagger/client/Manifest.java @@ -0,0 +1,7 @@ +/*___Generated_by_IDEA___*/ + +package io.swagger.client; + +/* This stub is only used by the IDE. It is NOT the Manifest class actually packed into the APK */ +public final class Manifest { +} \ No newline at end of file diff --git a/samples/client/petstore/java/jersey1/src/main/gen/io/swagger/client/R.java b/samples/client/petstore/java/jersey1/src/main/gen/io/swagger/client/R.java new file mode 100644 index 00000000000..cd0683364d5 --- /dev/null +++ b/samples/client/petstore/java/jersey1/src/main/gen/io/swagger/client/R.java @@ -0,0 +1,7 @@ +/*___Generated_by_IDEA___*/ + +package io.swagger.client; + +/* This stub is only used by the IDE. It is NOT the R class actually packed into the APK */ +public final class R { +} \ No newline at end of file diff --git a/samples/client/petstore/java/jersey2-java6/src/main/gen/io/swagger/client/BuildConfig.java b/samples/client/petstore/java/jersey2-java6/src/main/gen/io/swagger/client/BuildConfig.java new file mode 100644 index 00000000000..720765940d3 --- /dev/null +++ b/samples/client/petstore/java/jersey2-java6/src/main/gen/io/swagger/client/BuildConfig.java @@ -0,0 +1,8 @@ +/*___Generated_by_IDEA___*/ + +package io.swagger.client; + +/* This stub is only used by the IDE. It is NOT the BuildConfig class actually packed into the APK */ +public final class BuildConfig { + public final static boolean DEBUG = Boolean.parseBoolean(null); +} \ No newline at end of file diff --git a/samples/client/petstore/java/jersey2-java6/src/main/gen/io/swagger/client/Manifest.java b/samples/client/petstore/java/jersey2-java6/src/main/gen/io/swagger/client/Manifest.java new file mode 100644 index 00000000000..41e0523a208 --- /dev/null +++ b/samples/client/petstore/java/jersey2-java6/src/main/gen/io/swagger/client/Manifest.java @@ -0,0 +1,7 @@ +/*___Generated_by_IDEA___*/ + +package io.swagger.client; + +/* This stub is only used by the IDE. It is NOT the Manifest class actually packed into the APK */ +public final class Manifest { +} \ No newline at end of file diff --git a/samples/client/petstore/java/jersey2-java6/src/main/gen/io/swagger/client/R.java b/samples/client/petstore/java/jersey2-java6/src/main/gen/io/swagger/client/R.java new file mode 100644 index 00000000000..cd0683364d5 --- /dev/null +++ b/samples/client/petstore/java/jersey2-java6/src/main/gen/io/swagger/client/R.java @@ -0,0 +1,7 @@ +/*___Generated_by_IDEA___*/ + +package io.swagger.client; + +/* This stub is only used by the IDE. It is NOT the R class actually packed into the APK */ +public final class R { +} \ No newline at end of file diff --git a/samples/client/petstore/java/jersey2-java8/src/main/gen/io/swagger/client/BuildConfig.java b/samples/client/petstore/java/jersey2-java8/src/main/gen/io/swagger/client/BuildConfig.java new file mode 100644 index 00000000000..720765940d3 --- /dev/null +++ b/samples/client/petstore/java/jersey2-java8/src/main/gen/io/swagger/client/BuildConfig.java @@ -0,0 +1,8 @@ +/*___Generated_by_IDEA___*/ + +package io.swagger.client; + +/* This stub is only used by the IDE. It is NOT the BuildConfig class actually packed into the APK */ +public final class BuildConfig { + public final static boolean DEBUG = Boolean.parseBoolean(null); +} \ No newline at end of file diff --git a/samples/client/petstore/java/jersey2-java8/src/main/gen/io/swagger/client/Manifest.java b/samples/client/petstore/java/jersey2-java8/src/main/gen/io/swagger/client/Manifest.java new file mode 100644 index 00000000000..41e0523a208 --- /dev/null +++ b/samples/client/petstore/java/jersey2-java8/src/main/gen/io/swagger/client/Manifest.java @@ -0,0 +1,7 @@ +/*___Generated_by_IDEA___*/ + +package io.swagger.client; + +/* This stub is only used by the IDE. It is NOT the Manifest class actually packed into the APK */ +public final class Manifest { +} \ No newline at end of file diff --git a/samples/client/petstore/java/jersey2-java8/src/main/gen/io/swagger/client/R.java b/samples/client/petstore/java/jersey2-java8/src/main/gen/io/swagger/client/R.java new file mode 100644 index 00000000000..cd0683364d5 --- /dev/null +++ b/samples/client/petstore/java/jersey2-java8/src/main/gen/io/swagger/client/R.java @@ -0,0 +1,7 @@ +/*___Generated_by_IDEA___*/ + +package io.swagger.client; + +/* This stub is only used by the IDE. It is NOT the R class actually packed into the APK */ +public final class R { +} \ No newline at end of file diff --git a/samples/client/petstore/java/jersey2/src/main/gen/io/swagger/client/BuildConfig.java b/samples/client/petstore/java/jersey2/src/main/gen/io/swagger/client/BuildConfig.java new file mode 100644 index 00000000000..720765940d3 --- /dev/null +++ b/samples/client/petstore/java/jersey2/src/main/gen/io/swagger/client/BuildConfig.java @@ -0,0 +1,8 @@ +/*___Generated_by_IDEA___*/ + +package io.swagger.client; + +/* This stub is only used by the IDE. It is NOT the BuildConfig class actually packed into the APK */ +public final class BuildConfig { + public final static boolean DEBUG = Boolean.parseBoolean(null); +} \ No newline at end of file diff --git a/samples/client/petstore/java/jersey2/src/main/gen/io/swagger/client/Manifest.java b/samples/client/petstore/java/jersey2/src/main/gen/io/swagger/client/Manifest.java new file mode 100644 index 00000000000..41e0523a208 --- /dev/null +++ b/samples/client/petstore/java/jersey2/src/main/gen/io/swagger/client/Manifest.java @@ -0,0 +1,7 @@ +/*___Generated_by_IDEA___*/ + +package io.swagger.client; + +/* This stub is only used by the IDE. It is NOT the Manifest class actually packed into the APK */ +public final class Manifest { +} \ No newline at end of file diff --git a/samples/client/petstore/java/jersey2/src/main/gen/io/swagger/client/R.java b/samples/client/petstore/java/jersey2/src/main/gen/io/swagger/client/R.java new file mode 100644 index 00000000000..cd0683364d5 --- /dev/null +++ b/samples/client/petstore/java/jersey2/src/main/gen/io/swagger/client/R.java @@ -0,0 +1,7 @@ +/*___Generated_by_IDEA___*/ + +package io.swagger.client; + +/* This stub is only used by the IDE. It is NOT the R class actually packed into the APK */ +public final class R { +} \ No newline at end of file diff --git a/samples/client/petstore/java/okhttp-gson-parcelableModel/src/main/gen/io/swagger/client/BuildConfig.java b/samples/client/petstore/java/okhttp-gson-parcelableModel/src/main/gen/io/swagger/client/BuildConfig.java new file mode 100644 index 00000000000..720765940d3 --- /dev/null +++ b/samples/client/petstore/java/okhttp-gson-parcelableModel/src/main/gen/io/swagger/client/BuildConfig.java @@ -0,0 +1,8 @@ +/*___Generated_by_IDEA___*/ + +package io.swagger.client; + +/* This stub is only used by the IDE. It is NOT the BuildConfig class actually packed into the APK */ +public final class BuildConfig { + public final static boolean DEBUG = Boolean.parseBoolean(null); +} \ No newline at end of file diff --git a/samples/client/petstore/java/okhttp-gson-parcelableModel/src/main/gen/io/swagger/client/Manifest.java b/samples/client/petstore/java/okhttp-gson-parcelableModel/src/main/gen/io/swagger/client/Manifest.java new file mode 100644 index 00000000000..41e0523a208 --- /dev/null +++ b/samples/client/petstore/java/okhttp-gson-parcelableModel/src/main/gen/io/swagger/client/Manifest.java @@ -0,0 +1,7 @@ +/*___Generated_by_IDEA___*/ + +package io.swagger.client; + +/* This stub is only used by the IDE. It is NOT the Manifest class actually packed into the APK */ +public final class Manifest { +} \ No newline at end of file diff --git a/samples/client/petstore/java/okhttp-gson-parcelableModel/src/main/gen/io/swagger/client/R.java b/samples/client/petstore/java/okhttp-gson-parcelableModel/src/main/gen/io/swagger/client/R.java new file mode 100644 index 00000000000..cd0683364d5 --- /dev/null +++ b/samples/client/petstore/java/okhttp-gson-parcelableModel/src/main/gen/io/swagger/client/R.java @@ -0,0 +1,7 @@ +/*___Generated_by_IDEA___*/ + +package io.swagger.client; + +/* This stub is only used by the IDE. It is NOT the R class actually packed into the APK */ +public final class R { +} \ No newline at end of file diff --git a/samples/client/petstore/java/okhttp-gson/src/main/gen/io/swagger/client/BuildConfig.java b/samples/client/petstore/java/okhttp-gson/src/main/gen/io/swagger/client/BuildConfig.java new file mode 100644 index 00000000000..720765940d3 --- /dev/null +++ b/samples/client/petstore/java/okhttp-gson/src/main/gen/io/swagger/client/BuildConfig.java @@ -0,0 +1,8 @@ +/*___Generated_by_IDEA___*/ + +package io.swagger.client; + +/* This stub is only used by the IDE. It is NOT the BuildConfig class actually packed into the APK */ +public final class BuildConfig { + public final static boolean DEBUG = Boolean.parseBoolean(null); +} \ No newline at end of file diff --git a/samples/client/petstore/java/okhttp-gson/src/main/gen/io/swagger/client/Manifest.java b/samples/client/petstore/java/okhttp-gson/src/main/gen/io/swagger/client/Manifest.java new file mode 100644 index 00000000000..41e0523a208 --- /dev/null +++ b/samples/client/petstore/java/okhttp-gson/src/main/gen/io/swagger/client/Manifest.java @@ -0,0 +1,7 @@ +/*___Generated_by_IDEA___*/ + +package io.swagger.client; + +/* This stub is only used by the IDE. It is NOT the Manifest class actually packed into the APK */ +public final class Manifest { +} \ No newline at end of file diff --git a/samples/client/petstore/java/okhttp-gson/src/main/gen/io/swagger/client/R.java b/samples/client/petstore/java/okhttp-gson/src/main/gen/io/swagger/client/R.java new file mode 100644 index 00000000000..cd0683364d5 --- /dev/null +++ b/samples/client/petstore/java/okhttp-gson/src/main/gen/io/swagger/client/R.java @@ -0,0 +1,7 @@ +/*___Generated_by_IDEA___*/ + +package io.swagger.client; + +/* This stub is only used by the IDE. It is NOT the R class actually packed into the APK */ +public final class R { +} \ No newline at end of file diff --git a/samples/client/petstore/java/retrofit/src/main/gen/io/swagger/client/BuildConfig.java b/samples/client/petstore/java/retrofit/src/main/gen/io/swagger/client/BuildConfig.java new file mode 100644 index 00000000000..720765940d3 --- /dev/null +++ b/samples/client/petstore/java/retrofit/src/main/gen/io/swagger/client/BuildConfig.java @@ -0,0 +1,8 @@ +/*___Generated_by_IDEA___*/ + +package io.swagger.client; + +/* This stub is only used by the IDE. It is NOT the BuildConfig class actually packed into the APK */ +public final class BuildConfig { + public final static boolean DEBUG = Boolean.parseBoolean(null); +} \ No newline at end of file diff --git a/samples/client/petstore/java/retrofit/src/main/gen/io/swagger/client/Manifest.java b/samples/client/petstore/java/retrofit/src/main/gen/io/swagger/client/Manifest.java new file mode 100644 index 00000000000..41e0523a208 --- /dev/null +++ b/samples/client/petstore/java/retrofit/src/main/gen/io/swagger/client/Manifest.java @@ -0,0 +1,7 @@ +/*___Generated_by_IDEA___*/ + +package io.swagger.client; + +/* This stub is only used by the IDE. It is NOT the Manifest class actually packed into the APK */ +public final class Manifest { +} \ No newline at end of file diff --git a/samples/client/petstore/java/retrofit/src/main/gen/io/swagger/client/R.java b/samples/client/petstore/java/retrofit/src/main/gen/io/swagger/client/R.java new file mode 100644 index 00000000000..cd0683364d5 --- /dev/null +++ b/samples/client/petstore/java/retrofit/src/main/gen/io/swagger/client/R.java @@ -0,0 +1,7 @@ +/*___Generated_by_IDEA___*/ + +package io.swagger.client; + +/* This stub is only used by the IDE. It is NOT the R class actually packed into the APK */ +public final class R { +} \ No newline at end of file diff --git a/samples/client/petstore/java/retrofit2/src/main/gen/io/swagger/client/BuildConfig.java b/samples/client/petstore/java/retrofit2/src/main/gen/io/swagger/client/BuildConfig.java new file mode 100644 index 00000000000..720765940d3 --- /dev/null +++ b/samples/client/petstore/java/retrofit2/src/main/gen/io/swagger/client/BuildConfig.java @@ -0,0 +1,8 @@ +/*___Generated_by_IDEA___*/ + +package io.swagger.client; + +/* This stub is only used by the IDE. It is NOT the BuildConfig class actually packed into the APK */ +public final class BuildConfig { + public final static boolean DEBUG = Boolean.parseBoolean(null); +} \ No newline at end of file diff --git a/samples/client/petstore/java/retrofit2/src/main/gen/io/swagger/client/Manifest.java b/samples/client/petstore/java/retrofit2/src/main/gen/io/swagger/client/Manifest.java new file mode 100644 index 00000000000..41e0523a208 --- /dev/null +++ b/samples/client/petstore/java/retrofit2/src/main/gen/io/swagger/client/Manifest.java @@ -0,0 +1,7 @@ +/*___Generated_by_IDEA___*/ + +package io.swagger.client; + +/* This stub is only used by the IDE. It is NOT the Manifest class actually packed into the APK */ +public final class Manifest { +} \ No newline at end of file diff --git a/samples/client/petstore/java/retrofit2/src/main/gen/io/swagger/client/R.java b/samples/client/petstore/java/retrofit2/src/main/gen/io/swagger/client/R.java new file mode 100644 index 00000000000..cd0683364d5 --- /dev/null +++ b/samples/client/petstore/java/retrofit2/src/main/gen/io/swagger/client/R.java @@ -0,0 +1,7 @@ +/*___Generated_by_IDEA___*/ + +package io.swagger.client; + +/* This stub is only used by the IDE. It is NOT the R class actually packed into the APK */ +public final class R { +} \ No newline at end of file diff --git a/samples/client/petstore/java/retrofit2rx/src/main/gen/io/swagger/client/BuildConfig.java b/samples/client/petstore/java/retrofit2rx/src/main/gen/io/swagger/client/BuildConfig.java new file mode 100644 index 00000000000..720765940d3 --- /dev/null +++ b/samples/client/petstore/java/retrofit2rx/src/main/gen/io/swagger/client/BuildConfig.java @@ -0,0 +1,8 @@ +/*___Generated_by_IDEA___*/ + +package io.swagger.client; + +/* This stub is only used by the IDE. It is NOT the BuildConfig class actually packed into the APK */ +public final class BuildConfig { + public final static boolean DEBUG = Boolean.parseBoolean(null); +} \ No newline at end of file diff --git a/samples/client/petstore/java/retrofit2rx/src/main/gen/io/swagger/client/Manifest.java b/samples/client/petstore/java/retrofit2rx/src/main/gen/io/swagger/client/Manifest.java new file mode 100644 index 00000000000..41e0523a208 --- /dev/null +++ b/samples/client/petstore/java/retrofit2rx/src/main/gen/io/swagger/client/Manifest.java @@ -0,0 +1,7 @@ +/*___Generated_by_IDEA___*/ + +package io.swagger.client; + +/* This stub is only used by the IDE. It is NOT the Manifest class actually packed into the APK */ +public final class Manifest { +} \ No newline at end of file diff --git a/samples/client/petstore/java/retrofit2rx/src/main/gen/io/swagger/client/R.java b/samples/client/petstore/java/retrofit2rx/src/main/gen/io/swagger/client/R.java new file mode 100644 index 00000000000..cd0683364d5 --- /dev/null +++ b/samples/client/petstore/java/retrofit2rx/src/main/gen/io/swagger/client/R.java @@ -0,0 +1,7 @@ +/*___Generated_by_IDEA___*/ + +package io.swagger.client; + +/* This stub is only used by the IDE. It is NOT the R class actually packed into the APK */ +public final class R { +} \ No newline at end of file diff --git a/swagger-js-codegen b/swagger-js-codegen new file mode 160000 index 00000000000..8d753e3ffec --- /dev/null +++ b/swagger-js-codegen @@ -0,0 +1 @@ +Subproject commit 8d753e3ffecaca9820882c5200b1b3746f2aca0d diff --git a/swagger_orchestrator_sdk.sh b/swagger_orchestrator_sdk.sh new file mode 100644 index 00000000000..2de68cae18b --- /dev/null +++ b/swagger_orchestrator_sdk.sh @@ -0,0 +1,44 @@ +if $Build_Codegen; then + mvn3 clean package -Dmaven.test.skip=true +fi + +echo "{\"artifactVersion\":\"1.42-SNAPSHOT\"}" >config.json +echo "GENERATING SDK" + +if [ "$Branch" = "snapshot" ]; then + url="https://orchestratoradmin.crm-nightly-new.cctools.capillarytech.com/v3/api-docs" + version="https://orchestratoradmin.crm-nightly-new.cctools.capillarytech.com/v3/meta/version" +elif [ "$Branch" = "production" ]; then + url="https://orchestratoradmin.crm-staging-new.cctools.capillarytech.com/v2/api-docs" + version="https://orchestratoradmin.crm-staging-new.cctools.capillarytech.com/v3/meta/version" +else + "No Branch is selected" +fi + +if [ "$Client" = "java" ]; then + rm -rf orchestrator/java_client/java + mkdir -p orchestrator/java_client/java + java -jar modules/swagger-codegen-cli/target/swagger-codegen-cli.jar generate \ + -i orchestrator.json \ + -l java \ + -DdateLibrary=java11 \ + -o orchestrator/java_client/java \ + -c config.json --group-id com.capillary.promotion.engine --model-package com.capillary.promotion.engine.models --api-package com.capillary.promotion.engine.api --artifact-id promotion-engine-swagger-sdk + tar cvzf orchestrator/java_client/java_swagger_sdk_$BUILD_NUMBER.tar.gz -C ./orchestrator/java_client/java/ . + mvn3 clean deploy -f orchestrator/java_client/java/pom.xml + fpm -f -s "dir" -t "deb" -a "all" -n "java-swagger-orchestrator-sdk" -v $BUILD_NUMBER -C ./orchestrator/java_client --deb-no-default-config-files java="/usr/share/java/capillary-libs/swagger-orchestrator-sdk" + +elif [ "$Client" = "php" ]; then + rm -rf orchestrator/php_client/php + mkdir -p orchestrator/php_client/php + java -jar modules/swagger-codegen-cli/target/swagger-codegen-cli.jar generate \ + -i orchestrator.json \ + -l php \ + -o orchestrator/php_client/php \ + -c config.json + tar cvzf orchestrator/php_client/php_swagger_sdk_$BUILD_NUMBER.tar.gz -C ./orchestrator/php_client/php/ . + fpm -f -s "dir" -t "deb" -a "all" -n "swagger-orchestrator-sdk" -v $BUILD_NUMBER -C ./orchestrator/php_client --deb-no-default-config-files php="/usr/share/php/capillary-libs/swagger-orchestrator-sdk" +else + "no client is selected" +fi +echo "SWAGGER SDK SUCCESSFULLY GENERATED" diff --git a/swagger_sdk_gen.sh b/swagger_sdk_gen.sh new file mode 100644 index 00000000000..ab619b85535 --- /dev/null +++ b/swagger_sdk_gen.sh @@ -0,0 +1,69 @@ +if $Build_Codegen ; then + mvn3 clean package -Dmaven.test.skip=true +fi +if [ "$Branch" = "snapshot" ] + then + url="https://intouch-api-swagger.crm-nightly-new.cc.capillarytech.com/swagger.json" + version="https://newapi.crm-nightly-new.cc.capillarytech.com/version" +elif [ "$Branch" = "production" ] + then + url="https://intouch-api-swagger.crm-staging-new.cc.capillarytech.com/swagger.json" + version="https://newapi.intouch-a-crm-crm-staging-new.cc.capillarytech.com/version" +else " No Branch is selected" +fi +curl -k $version -o config.json +echo "GENERATING SDK" +if [ "$Client" = "java" ] +then + rm -rf intouch_api/java_client/java + java -jar modules/swagger-codegen-cli/target/swagger-codegen-cli.jar generate \ + -i $url \ + -l java \ + -DdateLibrary=java8 \ + -o intouch_api/java_client/java \ + -c config.json + tar cvzf intouch_api/java_client/java_swagger_sdk_$BUILD_NUMBER.tar.gz -C ./intouch_api/java_client/java/ . + mvn3 clean deploy -f intouch_api/java_client/java/pom.xml + fpm -f -s "dir" -t "deb" -a "all" -n "java-swagger-sdk" -v $BUILD_NUMBER -C ./intouch_api/java_client --deb-no-default-config-files java="/usr/share/java/capillary-libs/swagger-sdk" +elif [ "$Client" = "c#" ] +then rm -rf intouch_api/csharp_client/c# + java -jar modules/swagger-codegen-cli/target/swagger-codegen-cli.jar generate \ + -i $url \ + -l csharp\ + -DtargetFramework=v$Version \ + -o intouch_api/csharp_client/c# + tar cvzf intouch_api/csharp_client/c#swagger_sdK_$BUILD_NUMBER.tar.gz -C ./intouch_api/csharp_client/c#/ . + fpm -f -s "dir" -t "deb" -a "all" -n "csharp-swagger-sdk" -v $BUILD_NUMBER -C ./intouch_api/csharp_client --deb-no-default-config-files c#="/usr/share/c#/capillary-libs/swagger-sdk" +elif [ "$Client" = "php" ] +then rm -rf intouch_api/php_client/php + if [ "$CamelCase" = "Yes" ] + then + echo "setting camelcase variable name convention for php sdk" + echo '{"variableNamingConvention":"camelCase"}' > config.json + fi + java -jar modules/swagger-codegen-cli/target/swagger-codegen-cli.jar generate \ + -i $url \ + -l php \ + -c config.json \ + -o intouch_api/php_client/php + tar cvzf intouch_api/php_client/php_swagger_sdk_$BUILD_NUMBER.tar.gz -C ./intouch_api/php_client/php/ . + fpm -f -s "dir" -t "deb" -a "all" -n "swagger-sdk" -v $BUILD_NUMBER -C ./intouch_api/php_client --deb-no-default-config-files php="/usr/share/php/capillary-libs/swagger-sdk" +elif [ "$Client" = "nodejs" ] +then rm -rf intouch_api/nodejs_client + mkdir -p intouch_api/nodejs_client/ + curl $url > swagger.json + npm install swagger-js-codegen + cd swagger-js-codegen + node ../nodejs_sdk_gen > ../intouch_api/nodejs_client/node_$BUILD_NUMBER + fpm -f -s "dir" -t "deb" -a "all" -n "node-swagger-sdk" -v $BUILD_NUMBER -C ./intouch_api/nodejs_client --deb-no-default-config-files nodejs="/usr/share/nodejs/capillary-libs/swagger-sdk" +elif [ "$Client" = "python" ] +then rm -rf intouch_api/python_client + java -jar modules/swagger-codegen-cli/target/swagger-codegen-cli.jar generate \ + -i $url \ + -l python \ + -o intouch_api/python_client/python + tar cvzf intouch_api/python_client/python_swagger_sdk_$BUILD_NUMBER.tar.gz -C ./intouch_api/python_client/python/ . + fpm -f -s "dir" -t "deb" -a "all" -n "py-swagger-sdk" -v $BUILD_NUMBER -C ./intouch_api/python_client --deb-no-default-config-files python="/usr/share/python/capillary-libs/swagger-sdk" +else " no client is selected" +fi +echo "SWAGGER SDK SUCCESSFULLY GENERATED" diff --git a/swagger_sdk_gen_coupon_gateway.sh b/swagger_sdk_gen_coupon_gateway.sh new file mode 100644 index 00000000000..5ee04088c44 --- /dev/null +++ b/swagger_sdk_gen_coupon_gateway.sh @@ -0,0 +1,57 @@ +if $Build_Codegen ; then + mvn3 clean package -Dmaven.test.skip=true +fi + +echo "{\"artifactVersion\":\"${Version}\"}">config.json +echo "GENERATING SDK" +if [ "$Client" = "java" ] +then + rm -rf coupon_gateway/java_client/java + mkdir -p coupon_gateway/java_client/java + java -jar modules/swagger-codegen-cli/target/swagger-codegen-cli.jar generate \ + -i coupon-gateway.json \ + -l java \ + -DdateLibrary=java8 \ + -o coupon_gateway/java_client/java \ + -c config.json --group-id com.capillary.coupongateway --model-package com.capillary.coupon.gateway.models --api-package com.capillary.coupon.gateway.api --artifact-id coupon-gateway-swagger-sdk + tar cvzf coupon_gateway/java_client/java_swagger_sdk_$BUILD_NUMBER.tar.gz -C ./coupon_gateway/java_client/java/ . + mvn3 clean deploy -f coupon_gateway/java_client/java/pom.xml + fpm -f -s "dir" -t "deb" -a "all" -n "java-swagger-coupon-gateway-sdk" -v $BUILD_NUMBER -C ./coupon_gateway/java_client --deb-no-default-config-files java="/usr/share/java/capillary-libs/swagger_sdk_gen_coupon_gateway" + +elif [ "$Client" = "c#" ] +then rm -rf intouch_api/csharp_client/c# + java -jar modules/swagger-codegen-cli/target/swagger-codegen-cli.jar generate \ + -i $url \ + -l csharp\ + -DtargetFramework=v$Version \ + -o intouch_api/csharp_client/c# + tar cvzf intouch_api/csharp_client/c#swagger_sdK_$BUILD_NUMBER.tar.gz -C ./intouch_api/csharp_client/c#/ . + fpm -f -s "dir" -t "deb" -a "all" -n "c#-swagger-coupon-gateway-sdk" -v $BUILD_NUMBER -C ./intouch_api/csharp_client --deb-no-default-config-files csharp="/usr/share/c#/capillary-libs/swagger-coupon-gateway-sdk" +elif [ "$Client" = "php" ] +then rm -rf intouch_api/php_client/php + java -jar modules/swagger-codegen-cli/target/swagger-codegen-cli.jar generate \ + -i $url \ + -l php \ + -o intouch_api/php_client/php \ + -c config_php.json + tar cvzf intouch_api/php_client/php_swagger_sdk_$BUILD_NUMBER.tar.gz -C ./intouch_api/php_client/php/ . + fpm -f -s "dir" -t "deb" -a "all" -n "swagger-coupon-gateway-sdk" -v $BUILD_NUMBER -C ./intouch_api/php_client --deb-no-default-config-files php="/usr/share/php/capillary-libs/swagger-coupon-gateway-sdk" +elif [ "$Client" = "nodejs" ] +then rm -rf intouch_api/nodejs_client + mkdir -p intouch_api/nodejs_client/ + curl $url > swagger.json + npm install swagger-js-codegen + cd swagger-js-codegen + node ../nodejs_sdk_gen > ../intouch_api/nodejs_client/node_$BUILD_NUMBER + fpm -f -s "dir" -t "deb" -a "all" -n "node-swagger-coupon-gateway-sdk" -v $BUILD_NUMBER -C ./intouch_api/nodejs_client --deb-no-default-config-files nodejs="/usr/share/nodejs/capillary-libs/swagger-coupon-gateway-sdk" +elif [ "$Client" = "python" ] +then rm -rf intouch_api/python_client + java -jar modules/swagger-codegen-cli/target/swagger-codegen-cli.jar generate \ + -i $url \ + -l python \ + -o intouch_api/python_client/python + tar cvzf intouch_api/python_client/python_swagger_sdk_$BUILD_NUMBER.tar.gz -C ./intouch_api/python_client/python/ . + fpm -f -s "dir" -t "deb" -a "all" -n "py-swagger-coupon-gateway-sdk" -v $BUILD_NUMBER -C ./intouch_api/python_client --deb-no-default-config-files python="/usr/share/python/capillary-libs/swagger-coupon-gateway-sdk" +else " no client is selected" +fi +echo "SWAGGER SDK SUCCESSFULLY GENERATED" diff --git a/swagger_sdk_gen_fileService.sh b/swagger_sdk_gen_fileService.sh new file mode 100755 index 00000000000..81e95b9f65b --- /dev/null +++ b/swagger_sdk_gen_fileService.sh @@ -0,0 +1,34 @@ +if $Build_Codegen ; then + mvn3 clean package -Dmaven.test.skip=true +fi +if [ "$Branch" = "master" ] + then + url="https://crm-nightly-new.cc.capillarytech.com/api_gateway/file-service/v2/api-docs" + version="https://crm-nightly-new.cc.capillarytech.com/api_gateway/file-service/v1/meta/version" + ver=$(curl -H"Authorization: Basic a3Jpc2huYS50aWxsMDE6MjAyY2I5NjJhYzU5MDc1Yjk2NGIwNzE1MmQyMzRiNzA=" -k $version) + curl -H"Authorization:Basic a3Jpc2huYS50aWxsMDE6MjAyY2I5NjJhYzU5MDc1Yjk2NGIwNzE1MmQyMzRiNzA=" -o spec.json $url +elif [ "$Branch" = "production" ] + then + url="https://crm-staging-new.cc.capillarytech.com/api_gateway/file-service/v2/api-docs" + version="https://crm-staging-new.cc.capillarytech.com/api_gateway/file-service/v1/meta/version" + ver=$(curl -H"Authorization: Basic Zmlyc3RfdXNlckBjYXBpbGxhcnl0ZWNoLmNvbTo3ZmUzMmM5YjE1N2I0MDE0Y2QzOTg3MjhhYTJiM2UwYg==" -k $version) + curl -H"Authorization:Basic Zmlyc3RfdXNlckBjYXBpbGxhcnl0ZWNoLmNvbTo3ZmUzMmM5YjE1N2I0MDE0Y2QzOTg3MjhhYTJiM2UwYg==" -o spec.json $url +else " No Branch is selected" +fi +echo {'"artifactVersion"':\"$ver\"} > config.json +echo "GENERATING SDK" +if [ "$Client" = "java" ] +then + rm -rf fileservice/java_client/java + java -jar modules/swagger-codegen-cli/target/swagger-codegen-cli.jar generate \ + -i spec.json \ + -l java \ + -DdateLibrary=java8 \ + -o fileservice/java_client/java \ + -c config.json --group-id com.capillary.platforms --model-package com.capillary.platforms.fileservice.models --api-package com.capillary.platforms.fileservice.api --artifact-id fileservice-client + tar cvzf fileservice/java_client/java_swagger_sdk_$BUILD_NUMBER.tar.gz -C ./filservice/java_client/java/ . + mvn3 clean deploy -f fileservice/java_client/java/pom.xml + fpm -f -s "dir" -t "deb" -a "all" -n "swagger_sdk_gen_fileService" -v $BUILD_NUMBER -C ./fileservice/java_client --deb-no-default-config-files java="/usr/share/java/capillary-libs/swagger_sdk_gen_fileService" +else " no client is selected" +fi +echo "SWAGGER SDK SUCCESSFULLY GENERATED" diff --git a/swagger_sdk_gen_promotion_engine.sh b/swagger_sdk_gen_promotion_engine.sh new file mode 100644 index 00000000000..4c9054b5566 --- /dev/null +++ b/swagger_sdk_gen_promotion_engine.sh @@ -0,0 +1,57 @@ +if $Build_Codegen ; then + mvn3 clean package -Dmaven.test.skip=true +fi + +echo "{\"artifactVersion\":\"${Version}\"}">config.json +echo "GENERATING SDK" +if [ "$Client" = "java" ] +then + rm -rf promotion_engine/java_client/java + mkdir -p promotion_engine/java_client/java + java -jar modules/swagger-codegen-cli/target/swagger-codegen-cli.jar generate \ + -i promotion-engine.json \ + -l java \ + -DdateLibrary=java11 \ + -o promotion_engine/java_client/java \ + -c config.json --group-id com.capillary.promotion.engine --model-package com.capillary.promotion.engine.models --api-package com.capillary.promotion.engine.api --artifact-id promotion-engine-swagger-sdk + tar cvzf promotion_engine/java_client/java_swagger_sdk_$BUILD_NUMBER.tar.gz -C ./promotion_engine/java_client/java/ . + mvn3 clean deploy -f promotion_engine/java_client/java/pom.xml + fpm -f -s "dir" -t "deb" -a "all" -n "java-swagger-promotion-engine-sdk" -v $BUILD_NUMBER -C ./promotion_engine/java_client --deb-no-default-config-files java="/usr/share/java/capillary-libs/swagger_sdk_gen_promotion_engine" + +elif [ "$Client" = "c#" ] +then rm -rf intouch_api/csharp_client/c# + java -jar modules/swagger-codegen-cli/target/swagger-codegen-cli.jar generate \ + -i $url \ + -l csharp\ + -DtargetFramework=v$Version \ + -o intouch_api/csharp_client/c# + tar cvzf intouch_api/csharp_client/c#swagger_sdK_$BUILD_NUMBER.tar.gz -C ./intouch_api/csharp_client/c#/ . + fpm -f -s "dir" -t "deb" -a "all" -n "c#-swagger-promotion-engine-sdk" -v $BUILD_NUMBER -C ./intouch_api/csharp_client --deb-no-default-config-files csharp="/usr/share/c#/capillary-libs/swagger-promotion-engine-sdk" +elif [ "$Client" = "php" ] +then rm -rf promotion_engine/php_client/php + java -jar modules/swagger-codegen-cli/target/swagger-codegen-cli.jar generate \ + -i promotion-engine.json \ + -l php \ + -o promotion_engine/php_client/php \ + -c config_php.json + tar cvzf promotion_engine/php_client/php_swagger_sdk_$BUILD_NUMBER.tar.gz -C ./promotion_engine/php_client/php/ . + fpm -f -s "dir" -t "deb" -a "all" -n "swagger-promotion-engine-sdk" -v $BUILD_NUMBER -C ./promotion_engine/php_client --deb-no-default-config-files php="/usr/share/php/capillary-libs/swagger-promotion-engine-sdk" +elif [ "$Client" = "nodejs" ] +then rm -rf intouch_api/nodejs_client + mkdir -p intouch_api/nodejs_client/ + curl $url > swagger.json + npm install swagger-js-codegen + cd swagger-js-codegen + node ../nodejs_sdk_gen > ../intouch_api/nodejs_client/node_$BUILD_NUMBER + fpm -f -s "dir" -t "deb" -a "all" -n "node-swagger-promotion-engine-sdk" -v $BUILD_NUMBER -C ./intouch_api/nodejs_client --deb-no-default-config-files nodejs="/usr/share/nodejs/capillary-libs/swagger-promotion-engine-sdk" +elif [ "$Client" = "python" ] +then rm -rf intouch_api/python_client + java -jar modules/swagger-codegen-cli/target/swagger-codegen-cli.jar generate \ + -i $url \ + -l python \ + -o intouch_api/python_client/python + tar cvzf intouch_api/python_client/python_swagger_sdk_$BUILD_NUMBER.tar.gz -C ./intouch_api/python_client/python/ . + fpm -f -s "dir" -t "deb" -a "all" -n "py-swagger-promotion-engine-sdk" -v $BUILD_NUMBER -C ./intouch_api/python_client --deb-no-default-config-files python="/usr/share/python/capillary-libs/swagger-promotion-engine-sdk" +else " no client is selected" +fi +echo "SWAGGER SDK SUCCESSFULLY GENERATED" diff --git a/swagger_sdk_gen_v3.sh b/swagger_sdk_gen_v3.sh new file mode 100644 index 00000000000..4b468a53dd4 --- /dev/null +++ b/swagger_sdk_gen_v3.sh @@ -0,0 +1,66 @@ +if $Build_Codegen ; then + mvn3 clean package -Dmaven.test.skip=true +fi +if [ "$Branch" = "snapshot" ] + then + url="https://intouch-api-v3-swagger.crm-nightly-new.cc.capillarytech.com/v2/api-docs" + version="https://intouch-api-v3-swagger.crm-nightly-new.cc.capillarytech.com/v3/meta/version" +elif [ "$Branch" = "production" ] + then + url="https://intouch-api-v3-swagger.crm-staging-new.cc.capillarytech.com/v2/api-docs" + version="https://intouch-api-v3-swagger.crm-staging-new.cc.capillarytech.com/v3/meta/version" +else " No Branch is selected" +fi +curl -k $version -o config.json +#echo '{"artifactVersion":"0.0.1-SNAPSHOT","invokerPackage":"SwaggerV3\\\\Client","modelPackage":"SwaggerV3\\\\Client\\\\Model","apiPackage":"SwaggerV3\\\\Client\\\\Api"}'>config_php.json +echo "GENERATING SDK" +if [ "$Client" = "java" ] +then + rm -rf intouch_api/java_client/java + java -jar modules/swagger-codegen-cli/target/swagger-codegen-cli.jar generate \ + -i $url \ + -l java \ + -DdateLibrary=java8 \ + -o intouch_api/java_client/java \ + -c config.json + tar cvzf intouch_api/java_client/java_swagger_sdk_$BUILD_NUMBER.tar.gz -C ./intouch_api/java_client/java/ . + mvn3 clean deploy -f intouch_api/java_client/java/pom.xml + fpm -f -s "dir" -t "deb" -a "all" -n "java-swagger-v3-sdk" -v $BUILD_NUMBER -C ./intouch_api/java_client --deb-no-default-config-files java="/usr/share/java/capillary-libs/swagger-v3-sdk" + +elif [ "$Client" = "c#" ] +then rm -rf intouch_api/csharp_client/c# + java -jar modules/swagger-codegen-cli/target/swagger-codegen-cli.jar generate \ + -i $url \ + -l csharp\ + -DtargetFramework=v$Version \ + -o intouch_api/csharp_client/c# + tar cvzf intouch_api/csharp_client/c#swagger_sdK_$BUILD_NUMBER.tar.gz -C ./intouch_api/csharp_client/c#/ . + fpm -f -s "dir" -t "deb" -a "all" -n "c#-swagger-v3-sdk" -v $BUILD_NUMBER -C ./intouch_api/csharp_client --deb-no-default-config-files csharp="/usr/share/c#/capillary-libs/swagger-v3-sdk" +elif [ "$Client" = "php" ] +then rm -rf intouch_api/php_client/php + java -jar modules/swagger-codegen-cli/target/swagger-codegen-cli.jar generate \ + -i $url \ + -l php \ + -o intouch_api/php_client/php \ + -c config_php.json + tar cvzf intouch_api/php_client/php_swagger_sdk_$BUILD_NUMBER.tar.gz -C ./intouch_api/php_client/php/ . + fpm -f -s "dir" -t "deb" -a "all" -n "swagger-v3-sdk" -v $BUILD_NUMBER -C ./intouch_api/php_client --deb-no-default-config-files php="/usr/share/php/capillary-libs/swagger-v3-sdk" +elif [ "$Client" = "nodejs" ] +then rm -rf intouch_api/nodejs_client + mkdir -p intouch_api/nodejs_client/ + curl $url > swagger.json + npm install swagger-js-codegen + cd swagger-js-codegen + node ../nodejs_sdk_gen > ../intouch_api/nodejs_client/node_$BUILD_NUMBER + fpm -f -s "dir" -t "deb" -a "all" -n "node-swagger-v3-sdk" -v $BUILD_NUMBER -C ./intouch_api/nodejs_client --deb-no-default-config-files nodejs="/usr/share/nodejs/capillary-libs/swagger-v3-sdk" +elif [ "$Client" = "python" ] +then rm -rf intouch_api/python_client + java -jar modules/swagger-codegen-cli/target/swagger-codegen-cli.jar generate \ + -i $url \ + -l python \ + -o intouch_api/python_client/python + tar cvzf intouch_api/python_client/python_swagger_sdk_$BUILD_NUMBER.tar.gz -C ./intouch_api/python_client/python/ . + fpm -f -s "dir" -t "deb" -a "all" -n "py-swagger-v3-sdk" -v $BUILD_NUMBER -C ./intouch_api/python_client --deb-no-default-config-files python="/usr/share/python/capillary-libs/swagger-v3-sdk" +else " no client is selected" +fi +echo "SWAGGER SDK SUCCESSFULLY GENERATED" diff --git a/swagger_sdk_gen_v3_test.sh b/swagger_sdk_gen_v3_test.sh new file mode 100644 index 00000000000..81fffd2a068 --- /dev/null +++ b/swagger_sdk_gen_v3_test.sh @@ -0,0 +1,66 @@ +if $Build_Codegen ; then + mvn3 clean package -Dmaven.test.skip=true +fi +if [ "$Branch" = "snapshot" ] + then + url="https://intouch-api-v3-swagger.crm-nightly-new.cc.capillarytech.com/tl-docs-test/v2/api-docs" + version="https://intouch-api-v3-swagger.crm-nightly-new.cc.capillarytech.com/v3test/meta/version" +elif [ "$Branch" = "production" ] + then + url="http://newapi.staging.capillary.in/tl-docs-test/v2/api-docs" + version="http://newapi.staging.capillary.in/v3test/meta/version" +else " No Branch is selected" +fi +curl -k $version -o config.json +echo '{"artifactVersion":"0.0.1-SNAPSHOT","invokerPackage":"SwaggerV3\\\\Client","modelPackage":"SwaggerV3\\\\Client\\\\Model","apiPackage":"SwaggerV3\\\\Client\\\\Api"}'>config_php.json +echo "GENERATING SDK" +if [ "$Client" = "java" ] +then + rm -rf intouch_api/java_client/java + java -jar modules/swagger-codegen-cli/target/swagger-codegen-cli.jar generate \ + -i $url \ + -l java \ + -DdateLibrary=java8 \ + -o intouch_api/java_client/java \ + -c config.json + tar cvzf intouch_api/java_client/java_swagger_sdk_$BUILD_NUMBER.tar.gz -C ./intouch_api/java_client/java/ . + mvn3 clean deploy -f intouch_api/java_client/java/pom.xml + fpm -f -s "dir" -t "deb" -a "all" -n "java-swagger-v3-sdk-test" -v $BUILD_NUMBER -C ./intouch_api/java_client --deb-no-default-config-files java="/usr/share/java/capillary-libs/swagger-v3-sdk-test" + +elif [ "$Client" = "c#" ] +then rm -rf intouch_api/csharp_client/c# + java -jar modules/swagger-codegen-cli/target/swagger-codegen-cli.jar generate \ + -i $url \ + -l csharp\ + -DtargetFramework=v$Version \ + -o intouch_api/csharp_client/c# + tar cvzf intouch_api/csharp_client/c#swagger_sdK_$BUILD_NUMBER.tar.gz -C ./intouch_api/csharp_client/c#/ . + fpm -f -s "dir" -t "deb" -a "all" -n "c#-swagger-v3-sdk-test" -v $BUILD_NUMBER -C ./intouch_api/csharp_client --deb-no-default-config-files csharp="/usr/share/c#/capillary-libs/swagger-v3-sdk-test" +elif [ "$Client" = "php" ] +then rm -rf intouch_api/php_client/php + java -jar modules/swagger-codegen-cli/target/swagger-codegen-cli.jar generate \ + -i $url \ + -l php \ + -o intouch_api/php_client/php \ + -c config_php.json + tar cvzf intouch_api/php_client/php_swagger_sdk_$BUILD_NUMBER.tar.gz -C ./intouch_api/php_client/php/ . + fpm -f -s "dir" -t "deb" -a "all" -n "swagger-v3-sdk-test" -v $BUILD_NUMBER -C ./intouch_api/php_client --deb-no-default-config-files php="/usr/share/php/capillary-libs/swagger-v3-sdk-test" +elif [ "$Client" = "nodejs" ] +then rm -rf intouch_api/nodejs_client + mkdir -p intouch_api/nodejs_client/ + curl $url > swagger.json + npm install swagger-js-codegen + cd swagger-js-codegen + node ../nodejs_sdk_gen > ../intouch_api/nodejs_client/node_$BUILD_NUMBER + fpm -f -s "dir" -t "deb" -a "all" -n "node-swagger-v3-sdk-test" -v $BUILD_NUMBER -C ./intouch_api/nodejs_client --deb-no-default-config-files nodejs="/usr/share/nodejs/capillary-libs/swagger-v3-sdk-test" +elif [ "$Client" = "python" ] +then rm -rf intouch_api/python_client + java -jar modules/swagger-codegen-cli/target/swagger-codegen-cli.jar generate \ + -i $url \ + -l python \ + -o intouch_api/python_client/python + tar cvzf intouch_api/python_client/python_swagger_sdk_$BUILD_NUMBER.tar.gz -C ./intouch_api/python_client/python/ . + fpm -f -s "dir" -t "deb" -a "all" -n "py-swagger-v3-sdk-test" -v $BUILD_NUMBER -C ./intouch_api/python_client --deb-no-default-config-files python="/usr/share/python/capillary-libs/swagger-v3-sdk-test" +else " no client is selected" +fi +echo "SWAGGER SDK SUCCESSFULLY GENERATED"