From bb6c1b3b834c91c5e81a0be9ff6bdc77d56e4d60 Mon Sep 17 00:00:00 2001 From: tarentomaheshvakkund <139739142+tarentomaheshvakkund@users.noreply.github.com> Date: Tue, 5 Mar 2024 16:31:38 +0530 Subject: [PATCH] KB-2925 | New API for the OTP generation for email/phone verification 1. Kong mapping for otp generate and verification. --- ansible/roles/kong-api/defaults/main.yml | 38 +++++++++++++++++++++++- 1 file changed, 37 insertions(+), 1 deletion(-) diff --git a/ansible/roles/kong-api/defaults/main.yml b/ansible/roles/kong-api/defaults/main.yml index 738b4e43b2..3ca6d75909 100644 --- a/ansible/roles/kong-api/defaults/main.yml +++ b/ansible/roles/kong-api/defaults/main.yml @@ -12507,4 +12507,40 @@ kong_apis: config.hour: "{{ medium_rate_limit_per_hour }}" config.limit_by: credential - name: request-size-limiting - config.allowed_payload_size: "{{ medium_request_size_limit }}" \ No newline at end of file + config.allowed_payload_size: "{{ medium_request_size_limit }}" + + - name: verifyOtpV3 + uris: "{{ otp_service_prefix }}/v3/verify" + upstream_url: "{{ learning_service_url }}/v3/otp/verify" + strip_uri: true + plugins: + - name: jwt + - name: cors + - "{{ statsd_pulgin }}" + - name: acl + config.whitelist: + - 'anonymousUserAccess' + - name: rate-limiting + config.policy: local + config.hour: "{{ medium_rate_limit_per_hour }}" + config.limit_by: credential + - name: request-size-limiting + config.allowed_payload_size: "{{ small_request_size_limit }}" + + - name: generateOtpV3 + uris: "{{ otp_service_prefix }}/v3/generate" + upstream_url: "{{ learning_service_url }}/v3/otp/generate" + strip_uri: true + plugins: + - name: jwt + - name: cors + - "{{ statsd_pulgin }}" + - name: acl + config.whitelist: + - 'anonymousUserAccess' + - name: rate-limiting + config.policy: local + config.hour: "{{ medium_rate_limit_per_hour }}" + config.limit_by: credential + - name: request-size-limiting + config.allowed_payload_size: "{{ small_request_size_limit }}" \ No newline at end of file