├── start.sh ├── flushall.sh ├── random-driver.sh ├── random-ride.sh ├── README.md ├── test.py ├── additional-alias.sh ├── cpu.sh ├── replace-number.py ├── smart-ride.sh ├── server-start.sh ├── portkill.sh ├── aliases.sh ├── ride-flow.sh ├── cheats.txt ├── ride-flow-comment.py ├── register-driver.py ├── smart-ride.py ├── postman.py ├── NammaYatri-RideBooking.json └── new_file.txt /start.sh: -------------------------------------------------------------------------------- 1 | # change magic root here 2 | sh /Users/juspay/NammaYatriMagic/portkill.sh 3 | , run-mobility-stack-dev 4 | -------------------------------------------------------------------------------- /flushall.sh: -------------------------------------------------------------------------------- 1 | echo "[+] Flushed Redis Main Cluster" 2 | redis-cli -p 6379 FLUSHALL 3 | echo "[+] Flushed Redis Cluster 1" 4 | redis-cli -p 30001 FLUSHALL 5 | echo "[+] Flushed Redis Cluster 2" 6 | redis-cli -p 30002 FLUSHALL 7 | echo "[+] Flushed Redis Cluster 3" 8 | redis-cli -p 30003 FLUSHALL -------------------------------------------------------------------------------- /random-driver.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | 3 | # Generate a random 10-digit number 4 | random_number=$(shuf -i 1000000000-9999999999 -n 1) 5 | 6 | echo "[+] Driver number is $random_number" 7 | python3 /Users/juspay/NammaYatriMagic/replace-number.py $random_number 8 | python3 /Users/juspay/NammaYatriMagic/register-driver.py $random_number -------------------------------------------------------------------------------- /random-ride.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | 3 | # Generate a random 10-digit number 4 | random_number=$(shuf -i 1000000000-9999999999 -n 1) 5 | 6 | python3 /Users/juspay/NammaYatriMagic/register-driver.py $random_number 7 | 8 | json_file="/Users/juspay/NammaYatriMagic/NammaYatri-RideBooking.json" 9 | 10 | python3 /Users/juspay/NammaYatriMagic/replace-number.py $random_number -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # Namma Yatri Magic 2 | 3 | ## Guide 4 | 5 | 1. Restarting the docker and starting the server - server-start.sh 6 | 2. Kill all port - portkill.sh 7 | 3. Flush all redis clusters including replicas - flushall.sh 8 | 4. Only ride flow - ride-flow.sh 9 | 5. Automatic ride booking - newman run /UsersNammaYatri-RideBooking.json 10 | 11 | ## Troubleshooting 12 | 13 | 1. npm i -g newman 14 | 15 | 16 | 17 | 18 | -------------------------------------------------------------------------------- /test.py: -------------------------------------------------------------------------------- 1 | import sys 2 | import time 3 | 4 | def loading_animation(): 5 | underscores = '-' * 50 # Number of underscores to display 6 | delay = 0.1 # Delay between each frame 7 | 8 | while True: 9 | for i in range(len(underscores)): 10 | sys.stdout.write('\r' + 'Loading ' + underscores[:i] + ' ') 11 | sys.stdout.flush() 12 | time.sleep(delay) 13 | 14 | loading_animation() 15 | -------------------------------------------------------------------------------- /additional-alias.sh: -------------------------------------------------------------------------------- 1 | # copy paste in your zshrc file 2 | 3 | #!/bin/bash 4 | 5 | # Specify the aliases 6 | 7 | magic_root="/Users/juspay/NammaYatriMagic" 8 | project_root="" 9 | 10 | aliases=( 11 | "register='python3 /Users/juspay/NammaYatriMagic/register-driver.py'" 12 | "random-ride='sh /Users/juspay/NammaYatriMagic/random-ride.sh'" 13 | "replace-driver='python3 /Users/juspay/NammaYatriMagic/replace-number.py'" 14 | ) 15 | 16 | # Append aliases to the .zshrc file 17 | echo "=== Setting up aliases ===" 18 | for alias in "${aliases[@]}"; do 19 | echo "[+] set $alias" 20 | echo "alias $alias" >> ~/.zshrc 21 | done 22 | -------------------------------------------------------------------------------- /cpu.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | git add . 3 | git commit -n -m "test" 4 | branchName=`git rev-parse --abbrev-ref HEAD` 5 | git remote add gitea "http://192.168.11.192:9001/piyushk/beckn-test.git" 6 | git push gitea $branchName -f 7 | curl --location --request POST 'http://192.168.11.192:9002/startBuild' \ 8 | --header 'Content-Type: application/json' \ 9 | --data-raw '{ 10 | "user": "shantanu", 11 | "branch": "'"$branchName"'", 12 | "buildCommand": "" 13 | }' 14 | 15 | buildDone=false 16 | while [[ $buildDone == false ]] 17 | do 18 | res=`curl --location --request POST 'http://192.168.11.192:9002/status' \ 19 | --header 'Content-Type: application/json' \ 20 | --data-raw '{ 21 | "user": "username" 22 | }' 23 | ` 24 | buildDone=`echo $res | jq '.done'` 25 | echo $buildDone 26 | echo $res 27 | sleep 2 28 | done 29 | -------------------------------------------------------------------------------- /replace-number.py: -------------------------------------------------------------------------------- 1 | import json 2 | import random 3 | import sys 4 | 5 | 6 | 7 | # JSON file path 8 | 9 | json_file = "/Users/juspay/NammaYatriMagic/NammaYatri-RideBooking.json" 10 | 11 | random_number = sys.argv[1] 12 | customer_number = str(random.randint(1000000000, 9999999999)) 13 | 14 | # Load the JSON file 15 | with open(json_file, 'r') as file: 16 | json_data = json.load(file) 17 | json_data["item"][0]["item"][0]["item"][0]["event"][0]["script"]["exec"][0] = f"pm.variables.set(\"driver-number\", \"{random_number}\");//data.driver.ka.numbur);" 18 | json_data["item"][0]["item"][1]["item"][0]["event"][0]["script"]["exec"][0] = f"pm.variables.set(\"customer-number\", \"{customer_number}\");" 19 | 20 | 21 | print("[+] Customer number replaced with",customer_number) 22 | print("[+] Driver number replaced with",random_number) 23 | 24 | with open(json_file, 'w') as file: 25 | json.dump(json_data, file, indent=3) 26 | -------------------------------------------------------------------------------- /smart-ride.sh: -------------------------------------------------------------------------------- 1 | get_random_quote() { 2 | response=$(curl -s "https://zenquotes.io/api/random") 3 | if [ $? -eq 0 ]; then 4 | quote=$(echo "$response" | jq -r '.[0].q') 5 | author=$(echo "$response" | jq -r '.[0].a') 6 | echo "$quote - $author" 7 | else 8 | echo "Internet is good for your health - Shantanu Mukherjee" 9 | fi 10 | } 11 | 12 | banner() { 13 | quote=$(get_random_quote) 14 | quote_length=${#quote} 15 | banner_width=$((quote_length + 10)) 16 | space=5 17 | quote_width=$((banner_width - 10)) 18 | 19 | # Generate the separator line 20 | separator=$(printf -- '-%.0s' $(seq "$banner_width")) 21 | echo " " 22 | printf "Ride Automator" 23 | echo " " 24 | echo " " 25 | echo "+$separator+" 26 | echo " " 27 | echo " $quote" 28 | echo " " 29 | echo "+$separator+" 30 | echo " " 31 | 32 | } 33 | 34 | 35 | banner 36 | sleep 2 37 | 38 | 39 | 40 | python3 /Users/juspay/NammaYatriMagic/smart-ride.py -------------------------------------------------------------------------------- /server-start.sh: -------------------------------------------------------------------------------- 1 | get_random_quote() { 2 | response=$(curl -s "https://zenquotes.io/api/random") 3 | if [ $? -eq 0 ]; then 4 | quote=$(echo "$response" | jq -r '.[0].q') 5 | author=$(echo "$response" | jq -r '.[0].a') 6 | echo "$quote - $author" 7 | else 8 | echo "Internet is good for your health - Shantanu Mukherjee" 9 | fi 10 | } 11 | 12 | banner() { 13 | quote=$(get_random_quote) 14 | quote_length=${#quote} 15 | banner_width=$((quote_length + 10)) 16 | space=5 17 | quote_width=$((banner_width - 10)) 18 | 19 | # Generate the separator line 20 | separator=$(printf -- '-%.0s' $(seq "$banner_width")) 21 | echo " " 22 | printf "Restarting the server" 23 | echo " " 24 | echo " " 25 | echo "+$separator+" 26 | echo " " 27 | echo " $quote" 28 | echo " " 29 | echo "+$separator+" 30 | echo " " 31 | } 32 | 33 | 34 | banner 35 | sleep 3 36 | 37 | set +x 38 | nix run .#arion -- down --remove-orphans 39 | nix run .#arion -- up --remove-orphans -d 40 | nix run .#arion -- up --remove-orphans -d pg-admin 41 | sh /Users/juspay/NammaYatriMagic/portkill.sh 42 | echo "Go and sleep for 45 seconds." 43 | sleep 45 44 | , run-mobility-stack-dev 45 | -------------------------------------------------------------------------------- /portkill.sh: -------------------------------------------------------------------------------- 1 | get_random_quote() { 2 | response=$(curl -s "https://zenquotes.io/api/random") 3 | if [ $? -eq 0 ]; then 4 | quote=$(echo "$response" | jq -r '.[0].q') 5 | author=$(echo "$response" | jq -r '.[0].a') 6 | echo "$quote - $author" 7 | else 8 | echo "Internet is good for your health - Shantanu Mukherjee" 9 | fi 10 | } 11 | 12 | banner() { 13 | quote=$(get_random_quote) 14 | quote_length=${#quote} 15 | banner_width=$((quote_length + 10)) 16 | space=5 17 | quote_width=$((banner_width - 10)) 18 | 19 | # Generate the separator line 20 | separator=$(printf -- '-%.0s' $(seq "$banner_width")) 21 | echo " " 22 | printf "Killing all servers" 23 | echo " " 24 | echo " " 25 | echo "+$separator+" 26 | echo " " 27 | echo " $quote" 28 | echo " " 29 | echo "+$separator+" 30 | echo " " 31 | } 32 | 33 | banner "Killing All Servers" 34 | 35 | PORTS=(8013 8014 8015 8016 8017 8018 8019 8020 8023 8024 8025 8032 8050 8051 8053 8055 8099 8115 4545 6235 4343 8051) 36 | 37 | for PORT in "${PORTS[@]}"; do 38 | echo "[+] Killing processes on port $PORT" 39 | lsof -i :$PORT | awk 'NR!=1 {print $2}' | xargs kill -9 >/dev/null 2>&1 40 | done 41 | 42 | -------------------------------------------------------------------------------- /aliases.sh: -------------------------------------------------------------------------------- 1 | # copy paste in your zshrc file 2 | 3 | #!/bin/bash 4 | 5 | # Specify the aliases 6 | 7 | magic_root="" 8 | project_root="" 9 | 10 | aliases=( 11 | "cba='cabal build all'" 12 | "cc='cabal clean'" 13 | "cdh='cd ~'" 14 | "da='direnv allow'" 15 | "flushall='sh $magic_root/flushall.sh'" 16 | "gb='git branch'" 17 | "gbc='git checkout -b'" 18 | "gco='git checkout'" 19 | "gl='git pull'" 20 | "gpro='git pull --rebase origin'" 21 | "gprom='git pull --rebase origin main'" 22 | "gsta='git stash --include-untracked'" 23 | "gstaa='git stash apply'" 24 | "kill-server='sh $magic_root/portkill.sh'" 25 | "magic='cd $magic_root'" 26 | "ny='cd $project_root'" 27 | "backend='cd $project_root/Backend'" 28 | "pgadmin='nix run .#arion -- up --remove-orphans pg-admin'" 29 | "prune='git gc --prune=now'" 30 | "qpgadmin='nix run .#arion -- up --remove-orphans -d pg-admin'" 31 | "qsvc='nix run .#arion -- up --remove-orphans -d'" 32 | "repl-driver='cabal repl dynamic-offer-driver-app'" 33 | "repl-rider='cabal repl rider-app'" 34 | "ride-flow='sh $magic_root/ride-flow.sh'" 35 | "rms='sh $magic_root/start.sh'" 36 | "run-ride='newman run $magic_root/NammaYatri-RideBooking.json'" 37 | "run-server='nix run .#run-mobility-stack-dev'" 38 | "sac='nix run .#arion -- down --remove-orphans'" 39 | "server-cold-start='sh $magic_root/server-start.sh'" 40 | "svc=', run-svc'" 41 | ) 42 | 43 | # Append aliases to the .zshrc file 44 | echo "=== Setting up aliases ===" 45 | for alias in "${aliases[@]}"; do 46 | echo "[+] set $alias" 47 | # echo "alias $alias" >> ~/.zshrc 48 | done 49 | -------------------------------------------------------------------------------- /ride-flow.sh: -------------------------------------------------------------------------------- 1 | #!bin/bash 2 | banner() 3 | { 4 | echo "+--------------------------------------------------------------------------------------+" 5 | echo "| # |"; 6 | echo "| ### # # #### ## |"; 7 | echo "| # # # # # |"; 8 | echo "| # # ## ### ## ### # ## # # |"; 9 | echo "| ### # # # # ## # # # # # # # |"; 10 | echo "| # # # # # ## # # # # # # # |"; 11 | echo "| # # ### ### ### # ### ## # # |"; 12 | echo "+--------------------------------------------------------------------------------------+" 13 | } 14 | 15 | 16 | banner 17 | # change magic root here 18 | python3 /Users/juspay/.oh-my-zsh/custom/ride-flow-comment.py 19 | echo "[+] Killing servers" 20 | PORTS=(8013 8014 8015 8016 8017 8018 8019 8020 8023 8024 8025 8032 8050 8051 8053 8055 8099 8115 4545 6235 4343 8051) 21 | 22 | for PORT in "${PORTS[@]}"; do 23 | lsof -i :$PORT | awk 'NR!=1 {print $2}' | xargs kill -9 >/dev/null 2>&1 24 | done 25 | echo "All servers killed" 26 | echo "[+] Building Rider App" 27 | cabal build rider-app 28 | echo "[+] Building Driver App" 29 | cabal build dynamic-offer-driver-app 30 | echo "[+] Building Gateway" 31 | cabal build beckn-gateway 32 | echo "[+] Building Mock Registry" 33 | cabal build mock-registry 34 | echo "[+] Building Driver Offer Allocator" 35 | cabal build driver-offer-allocator 36 | nix run .#run-mobility-stack-dev -------------------------------------------------------------------------------- /cheats.txt: -------------------------------------------------------------------------------- 1 | .. = Go back 2 | backend = Go to backend folder 3 | build-driver = Build the driver app 4 | build-rider = Build the rider app 5 | cba = cabal build all 6 | cc = cabal clean 7 | cdh = cd ~ 8 | code-backend = code /Users/juspay/nammayatri/Backend 9 | code-config = code /Users/juspay/nix-config 10 | code-custom = code ~/.oh-my-zsh/custom/ 11 | code-driver = code /Users/juspay/nammayatri/Backend/app/provider-platform/dynamic-offer-driver-app/ 12 | code-kernel = code /Users/juspay/shared-kernel 13 | code-ny = code /Users/juspay/nammayatri/ 14 | code-other-driver = code /Users/juspay/ny/nammayatri/Backend/app/provider-platform/dynamic-offer-driver-app/ 15 | code-other-rider = code /Users/juspay/nammayatri/Backend/app/rider-platform/rider-app/ 16 | code-rider = code /Users/juspay/nammayatri/Backend/app/rider-platform/rider-app/ 17 | da = direnv allow 18 | flushall = sh /Users/juspay/NammaYatriMagic/flushall.sh 19 | gb = git branch 20 | gbc = git checkout -b 21 | gco = git checkout 22 | gl = git pull 23 | gpro = git pull --rebase origin 24 | gprom = git pull --rebase origin main 25 | gsta = git stash --include-untracked 26 | gstaa = git stash apply 27 | kernel = cd /Users/juspay/shared-kernel 28 | kill-server = Kill all the ports in the server 29 | magic = cd ~/NammaYatriMagic/ 30 | ny = cd /Users/juspay/nammayatri/ 31 | other-backend = cd /Users/juspay/ny/nammayatri/Backend 32 | pgadmin = nix run .#arion -- up --remove-orphans pg-admin 33 | prune = git gc --prune = now 34 | qpgadmin = nix run .#arion -- up --remove-orphans -d pg-admin 35 | qsvc = nix run .#arion -- up --remove-orphans -d 36 | repl-driver = cabal repl dynamic-offer-driver-app 37 | repl-rider = cabal repl rider-app 38 | ride-flow = shows only the ride flow builds 39 | rms = runs the server 40 | run-ride = automate ride booking flow 41 | run-server = only runs the server (no builds) 42 | sac = stops all docker container 43 | server-cold-start = restarts the docker container and starts the server 44 | svc = , run-svc 45 | gaa = git add . 46 | x86-brew = arch -x86_64 /usr/local/bin/brew 47 | register = registers the driver with the number 48 | random-ride = automate the random ride with driver and rider 49 | replace-driver = replace the driver number in ridebooking json file 50 | gpoc = git push origin (current branch) 51 | cheats = shows this menu -------------------------------------------------------------------------------- /ride-flow-comment.py: -------------------------------------------------------------------------------- 1 | import os 2 | 3 | current_directory = os.getcwd() 4 | 5 | 6 | 7 | file_path = current_directory + '/nix/run-mobility-stack.nix' 8 | 9 | 10 | lines_to_comment = [ 11 | "allocation-service-exe.command = getExe \"allocation-service-exe\";", 12 | "driver-tracking-healthcheck-exe.command = getExe \"driver-tracking-healthcheck-exe\";", 13 | "image-api-helper-exe.command = getExe \"image-api-helper-exe\";", 14 | "mock-fcm-exe.command = getExe \"mock-fcm-exe\";", 15 | "mock-google-exe.command = getExe \"mock-google-exe\";", 16 | "mock-idfy-exe.command = getExe \"mock-idfy-exe\";", 17 | "mock-sms-exe.command = getExe \"mock-sms-exe\";", 18 | "provider-dashboard-exe.command = getExe \"provider-dashboard-exe\";", 19 | "public-transport-rider-platform-exe.command = getExe \"public-transport-rider-platform-exe\";", 20 | "public-transport-search-consumer-exe.command = getExe \"public-transport-search-consumer-exe\";", 21 | "rider-dashboard-exe.command = getExe \"rider-dashboard-exe\";", 22 | "scheduler-example-app-exe.command = getExe \"scheduler-example-app-exe\";", 23 | "scheduler-example-scheduler-exe.command = getExe \"scheduler-example-scheduler-exe\";", 24 | "search-result-aggregator-exe.command = getExe \"search-result-aggregator-exe\";", 25 | "static-offer-driver-app-exe.command = getExe \"static-offer-driver-app-exe\";", 26 | "transporter-scheduler-exe.command = getExe \"transporter-scheduler-exe\";", 27 | "special-zone-exe.command = self'.apps.special-zone-exe.program;", 28 | "mock-fcm-exe = { };", 29 | "mock-google-exe = { };", 30 | "mock-idfy-exe = { };", 31 | "mock-sms-exe = { };", 32 | "provider-dashboard-exe = { };", 33 | "public-transport-rider-platform-exe = { };", 34 | "public-transport-search-consumer-exe = { };", 35 | "driver-tracking-healthcheck-exe = { };", 36 | "image-api-helper-exe = { };", 37 | "rider-dashboard-exe = { };", 38 | "scheduler-example-app-exe = { };", 39 | "scheduler-example-scheduler-exe = { };", 40 | "search-result-aggregator-exe = { };", 41 | "special-zone-exe = { };" 42 | ] 43 | 44 | commented_lines = [] 45 | previous_line = "" 46 | with open(file_path, "r") as file: 47 | lines = file.readlines() 48 | for line in lines: 49 | if line.strip() in lines_to_comment: 50 | commented_lines.append("# " + line) 51 | else: 52 | commented_lines.append(line) 53 | previous_line = line.strip() 54 | 55 | with open(file_path, "w") as file: 56 | file.writelines(commented_lines) 57 | 58 | -------------------------------------------------------------------------------- /register-driver.py: -------------------------------------------------------------------------------- 1 | import requests 2 | import sys 3 | import json 4 | import pprint 5 | import random 6 | 7 | def driver_enabler(): 8 | if len(sys.argv) < 2: 9 | print("Usage: python script.py ") 10 | sys.exit(1) 11 | 12 | # getting admin token 13 | dashboard_token = "1460d294-8c69-44b9-811a-c370949d056e" 14 | auth_body = { 15 | "mobileNumber": "9999999999", 16 | "mobileCountryCode": "+91", 17 | "merchantId": "favorit0-0000-0000-0000-00000favorit" 18 | } 19 | 20 | x_admin = requests.post('http://localhost:8016/ui/auth',json=auth_body) 21 | 22 | auth_id_admin = x_admin.json()["authId"] 23 | 24 | verify_body = { 25 | "otp": "7891", 26 | "deviceToken": "8e83b5dc-99a0-4306-b90d-2345f3050972" 27 | } 28 | 29 | y_admin = requests.post(f'http://localhost:8016/ui/auth/{auth_id_admin}/verify',json=verify_body) 30 | 31 | admin_token = y_admin.json()["token"] 32 | number = sys.argv[1] 33 | 34 | auth_body = { 35 | "mobileNumber": str(number), 36 | "mobileCountryCode": "+91", 37 | "merchantId": "favorit0-0000-0000-0000-00000favorit" 38 | } 39 | x = requests.post('http://localhost:8016/ui/auth',json=auth_body) 40 | print("[+] Authenticating the driver",x.json()) 41 | auth_id = x.json()["authId"] 42 | verify_body = { 43 | "otp": "7891", 44 | "deviceToken": "8e83b5dc-99a0-4306-b90d-2345f3050972" 45 | } 46 | y = requests.post(f'http://localhost:8016/ui/auth/{auth_id}/verify',json=verify_body) 47 | print("[+] Verifying the driver") 48 | driverId = y.json()["person"]["id"] 49 | token = admin_token 50 | 51 | a = requests.get(f'http://localhost:8016/ui/auth/logout') 52 | 53 | z = requests.post(f'http://localhost:8016/ui/org/driver/{driverId}?enabled=true',headers={'token' : token}) 54 | print("[+] enabling the driver",z.json()) 55 | vehicle = { 56 | "variant": "AUTO_RICKSHAW", 57 | "color": "string", 58 | "size": "string", 59 | "vehicleClass": "3WT", 60 | "category": "CAR", 61 | "capacity": 5, 62 | "model": "string", 63 | "registrationNo": str(random.randint(1000,9999)), 64 | "registrationCategory": "COMMERCIAL", 65 | "make": "string", 66 | "colour": "ipsum", 67 | "energyType": "string", 68 | "driverName": "", 69 | } 70 | 71 | a = requests.post(f'http://localhost:8018/bpp/driver-offer/NAMMA_YATRI_PARTNER/driver/{driverId}/addVehicle',json=vehicle,headers={'token' : dashboard_token}) 72 | print("[+] Adding the vehicle",a.json()) 73 | print("") 74 | 75 | driver_enabler() -------------------------------------------------------------------------------- /smart-ride.py: -------------------------------------------------------------------------------- 1 | import requests 2 | import json 3 | import time 4 | from prompt_toolkit import prompt 5 | from prompt_toolkit.completion import WordCompleter 6 | from prompt_toolkit.completion import Completer, Completion 7 | from datetime import datetime, timezone 8 | import subprocess 9 | import sys 10 | import random 11 | 12 | driver_normal_auth_succeed = True 13 | customer_normal_auth_succeed = True 14 | 15 | customer_base_url = "http://localhost:8013" 16 | driver_base_url = "http://localhost:8016" 17 | 18 | which_api_we_are_using = "customer" 19 | 20 | customer_url = "http://localhost:8013/openapi" 21 | driver_url = "http://localhost:8016/openapi" 22 | 23 | default_ridesearch_request = { 24 | "fareProductType": "ONE_WAY", 25 | "contents": { 26 | "origin": { 27 | "address": { 28 | "area": "8th Block Koramangala", 29 | "areaCode": "560047", 30 | "building": "Juspay Buildings", 31 | "city": "Bangalore", 32 | "country": "India", 33 | "door": "#444", 34 | "street": "18th Main", 35 | "state": "Karnataka" 36 | }, 37 | 38 | "gps": { 39 | "lat": 12.846907, 40 | "lon": 77.556936 41 | } 42 | }, 43 | "destination": { 44 | "address": { 45 | "area": "6th Block Koramangala", 46 | "areaCode": "560047", 47 | "building": "Juspay Apartments", 48 | "city": "Bangalore", 49 | "country": "India", 50 | "door": "#444", 51 | "street": "18th Main", 52 | "state": "Karnataka" 53 | }, 54 | "gps": { 55 | "lat": 12.846907, 56 | "lon": 77.566936 57 | } 58 | } 59 | } 60 | } 61 | 62 | default_ride_start_request = { 63 | "rideOtp": "0000", 64 | "point": { 65 | "lat": 12.959849, 66 | "lon": 77.611269 67 | } 68 | } 69 | 70 | default_ride_end_request = { 71 | "point": { 72 | "lat": 12.959849, 73 | "lon": 77.611269 74 | } 75 | } 76 | 77 | customer_data = { 78 | "merchantId" : "NAMMA_YATRI", 79 | "mobileNumber" : "9999999999", 80 | "mobileCountryCode" : "+91", 81 | "otp": "7891", 82 | "deviceToken": "8e83b5dc-99a0-4306-b90d-2345f3050972", 83 | "fareProductType": "ONE_WAY", 84 | "/v2/rideSearch" : default_ridesearch_request, 85 | "token" : "", 86 | "authId" : "", 87 | "autoAssignEnabled" : False 88 | } 89 | driver_data = { 90 | "mobileNumber" : "6666666666", 91 | "mobileCountryCode": "+91", 92 | "merchantId": "favorit0-0000-0000-0000-00000favorit", 93 | "otp": "7891", 94 | "deviceToken": "8e83b5dc-99a0-4306-b90d-2345f3050972", 95 | "active" : True 96 | } 97 | 98 | def isAffirmative(x): 99 | if x == "yes" or x == "Y" or x == "y" or x == "1" or x == "Yes" or x == "": 100 | return True 101 | else: 102 | return False 103 | 104 | def isNegative(x): 105 | if x == "no" or x == "N" or x == "n" or x == "0" or x == "No": 106 | return True 107 | else: 108 | return False 109 | 110 | 111 | # customer_object = { 112 | # path : "", 113 | # type : "", 114 | # request_body : [] 115 | # parameters : [] 116 | # } 117 | 118 | customer_api_data = [] 119 | driver_api_data = [] 120 | 121 | all_customer_api = [] 122 | 123 | 124 | 125 | def isTrue(verdict): 126 | if verdict == "False" or verdict == "F" or verdict == "f" or verdict == "false" or verdict == "0": 127 | return False 128 | else: 129 | return True 130 | 131 | # return (input_in_proper_form,is_success) 132 | def input_sanitizer(inp,type_of_input): 133 | if type_of_input == 'boolean': 134 | return (isTrue(inp),True) 135 | elif type_of_input == 'string': 136 | return (str(inp),True) 137 | elif type_of_input == 'integer': 138 | try: 139 | return (int(inp),True) 140 | except: 141 | print("[-] Write input in proper form ( " + str(type_of_input) + " ) " ) 142 | print("") 143 | return (inp,False) 144 | elif type_of_input == 'double': 145 | try: 146 | return (float(inp),True) 147 | except: 148 | print("[-] Write input in proper form ( " + str(type_of_input) + " ) " ) 149 | print("") 150 | return (inp,False) 151 | 152 | # return type = {'name' : 'value','name': 'value'} 153 | 154 | def query_parameter_filler(path,query_parameter_list,data): 155 | 156 | (body,isRequestBodyException,isQueryParamException) = handle_openapi_exception(path,data,"") 157 | 158 | if isQueryParamException: 159 | return body 160 | 161 | required_query_parameters = [parameter for parameter in query_parameter_list if parameter.get('required') == True ] 162 | non_required_query_parameters = [parameter for parameter in query_parameter_list if parameter.get('required') == False ] 163 | answers = {} 164 | 165 | for parameter in required_query_parameters: 166 | (sanitized_input,isSuccess) = input_sanitizer(data.get(str(parameter.get('name'))),str(parameter.get('type'))) 167 | answers[str(parameter.get('name'))] = sanitized_input 168 | 169 | return answers 170 | 171 | # return (body,isRequestBodyException,isQueryParamException) 172 | def handle_openapi_exception(path,data,rideOtp): 173 | 174 | request_body = {} 175 | 176 | if path == '/ui/driver/location': 177 | pt_lat = 12.846907 178 | pt_lon = 77.556936 179 | ts = datetime.utcnow().replace(tzinfo=timezone.utc).strftime("%Y-%m-%dT%H:%M:%SZ") 180 | 181 | return ([ 182 | { 183 | "pt": { 184 | "lat": pt_lat, 185 | "lon": pt_lon 186 | }, 187 | "ts": ts 188 | } 189 | ],True,False) 190 | elif path == '/v2/rideBooking/list' or path == '/ui/driver/ride/list': 191 | return ({'onlyActive' : True},False,True) 192 | 193 | elif path.startswith("/ui/driver/ride/") and path.endswith("/start"): 194 | default_ride_start_request["rideOtp"] = rideOtp 195 | print("ride start request is ",default_ride_start_request) 196 | return (default_ride_start_request,True,False) 197 | 198 | elif path.startswith("/ui/driver/ride/") and path.endswith("/end"): 199 | return (default_ride_end_request,True,False) 200 | 201 | return ({},False,False) 202 | 203 | 204 | 205 | 206 | def request_body_filler(initial_prompt,req_body,api_object,index,data,path,driver_data): 207 | 208 | (body,isRequestBodyException,isQueryParamException) = handle_openapi_exception(path,data,driver_data.get("rideOtp")) 209 | 210 | if isRequestBodyException: 211 | return body 212 | 213 | if req_body == None: 214 | print("[-] Empty request body") 215 | return {} 216 | 217 | all_properties_list = [] 218 | 219 | for x in req_body.get('properties'): 220 | all_properties_list.append(x) 221 | 222 | non_required_properties = [] 223 | 224 | if req_body.get("required") != None: 225 | non_required_properties = result = [x for x in all_properties_list if x not in req_body.get("required")] 226 | 227 | body = {} 228 | 229 | if req_body.get("required") != None: 230 | for param in req_body.get("required"): 231 | if str(req_body.get('properties').get(param).get('type')) != 'object': 232 | body[param] = data.get(param) 233 | else: 234 | body[param] = request_body_filler(initial_prompt + " [ " + param + " ] " ,req_body.get("properties").get(param),api_object,index,data,path,driver_data) 235 | 236 | # print(beautify_json(body)) 237 | return body 238 | 239 | def one_of_request_body_sorter(req_body): 240 | 241 | if req_body == None or len(req_body) == 0 or req_body[0] == None or req_body[0].get('oneOf') == None: 242 | return req_body 243 | 244 | else : 245 | listy = [] 246 | for x in range(len(req_body[0].get('oneOf'))): 247 | listy.append(req_body[0].get('oneOf')[0]) 248 | return listy 249 | 250 | def loader(prompt,delay): 251 | underscores = '-' * 10 * delay # Number of underscores to display 252 | delay_between_frame = 0.1 # Delay between each frame 253 | 254 | 255 | for i in range(len(underscores)): 256 | spaces = ' ' * (len(underscores) - i - 1) 257 | sys.stdout.write('\r' + prompt + " (" + underscores[:i] + '>' + spaces + ")") 258 | sys.stdout.flush() 259 | time.sleep(delay_between_frame) 260 | 261 | def ride_flow(customer_api_data,driver_api_data): 262 | 263 | found = url_runner('/ui/auth',customer_api_data,driver_api_data,"driver") 264 | found = url_runner('/ui/auth/{authId}/verify',customer_api_data,driver_api_data,"driver") 265 | found = url_runner('/ui/driver/setActivity',customer_api_data,driver_api_data,"driver") 266 | found = url_runner('/ui/driver/location',customer_api_data,driver_api_data,"driver") 267 | found = url_runner('/ui/driver/profile',customer_api_data,driver_api_data,"driver") 268 | 269 | found = url_runner('/v2/auth',customer_api_data,driver_api_data,"customer") 270 | found = url_runner('/v2/auth/{authId}/verify',customer_api_data,driver_api_data,"customer") 271 | found = url_runner('/v2/rideSearch',customer_api_data,driver_api_data,"customer") 272 | # time.sleep(3) 273 | loader("Getting estimates",5) 274 | found = url_runner('/v2/rideSearch/{searchId}/results',customer_api_data,driver_api_data,"customer") 275 | found = url_runner('/v2/estimate/{estimateId}/select2',customer_api_data,driver_api_data,"customer") 276 | 277 | loader("Getting nearby ride request",5) 278 | found = url_runner('/ui/driver/nearbyRideRequest',customer_api_data,driver_api_data,"driver") 279 | found = url_runner('/ui/driver/searchRequest/quote/offer',customer_api_data,driver_api_data,"driver") 280 | 281 | loader("Getting quotes",5) 282 | found = url_runner('/v2/estimate/{estimateId}/quotes',customer_api_data,driver_api_data,"customer") 283 | found = url_runner('/v2/rideSearch/quotes/{quoteId}/confirm',customer_api_data,driver_api_data,"customer") 284 | loader("Getting rides ",5) 285 | found = url_runner('/v2/rideBooking/list',customer_api_data,driver_api_data,"customer") 286 | found = url_runner('/ui/driver/ride/list',customer_api_data,driver_api_data,"driver") 287 | found = url_runner('/ui/driver/ride/{rideId}/start',customer_api_data,driver_api_data,"driver") 288 | found = url_runner('/ui/driver/ride/{rideId}/end',customer_api_data,driver_api_data,"driver") 289 | 290 | 291 | 292 | 293 | 294 | def get_object_from_schema_reference(request_body,open_api_json): 295 | for content in request_body: 296 | for appjson in request_body.get(content): 297 | for schema in request_body.get(content).get(appjson): 298 | for ref in request_body.get(content).get(appjson).get(schema): 299 | return open_api_json["components"]["schemas"].get(str(request_body.get(content).get(appjson).get(schema).get(ref)).split("/")[3]) 300 | 301 | def get_object_from_ref(ref,open_api_json): 302 | return open_api_json["components"]["schemas"].get(str(ref.split("/")[3])) 303 | 304 | def all_ref_remover(request_body,open_api_json): 305 | 306 | if request_body == None: 307 | return request_body 308 | 309 | if type(request_body) != dict and type(request_body) != list: 310 | return request_body 311 | 312 | for key in request_body: 313 | 314 | if type(request_body.get(key)) == dict and request_body.get(key).get('$ref') != None: 315 | obj = get_object_from_ref(request_body.get(key).get('$ref'),open_api_json) 316 | request_body[key] = obj 317 | 318 | if type(request_body.get(key)) == dict : 319 | request_body[key] = all_ref_remover(request_body.get(key),open_api_json) 320 | 321 | elif type(request_body.get(key)) == list : 322 | for l in range(len(request_body.get(key))): 323 | request_body[key][l] = all_ref_remover(request_body.get(key)[l],open_api_json) 324 | 325 | return request_body 326 | 327 | def make_curl_request(url,request_type,request_body,base_url,data,query_parameters): 328 | 329 | print("") 330 | print("==> Hitting " + base_url + url ) 331 | print("") 332 | 333 | api_key = data.get("token") 334 | headers = {"token": api_key} 335 | 336 | try: 337 | if request_type == "get": 338 | response = requests.get(base_url + url,headers=headers,params=query_parameters) 339 | try: 340 | return response.json() 341 | except: 342 | return response.text 343 | 344 | elif request_type == "post": 345 | response = requests.post(base_url + url,json=request_body,headers=headers,params=query_parameters) 346 | try: 347 | return response.json() 348 | except: 349 | return response.text 350 | 351 | elif request_type == "put": 352 | response = requests.put(base_url + url,json=request_body,headers=headers,params=query_parameters) 353 | try: 354 | return response.json() 355 | except: 356 | return response.text 357 | 358 | elif request_type == "delete": 359 | response = requests.delete(base_url + url,json=request_body,headers=headers,params=query_parameters) 360 | try: 361 | return response.json() 362 | except: 363 | return response.text 364 | except: 365 | print("[+] I am not able to hit " + base_url + url + " is the server running ? ") 366 | raise Error("Not able to hit the url") 367 | 368 | def beautify_json(json_text): 369 | try: 370 | beautified_json = json.dumps(json_text, indent=4) 371 | return beautified_json 372 | except json.JSONDecodeError: 373 | return None 374 | 375 | def config_loader(url): 376 | final_list = [] 377 | try: 378 | open_api_json = make_curl_request(url,"get","","",{},{}) 379 | except: 380 | raise Error("Not able to hit the url") 381 | return 382 | api_data = open_api_json["paths"] 383 | 384 | for path in api_data: 385 | api_instance = {} 386 | api_instance["url_path"] = path 387 | 388 | req_body = [] 389 | 390 | for rt in api_data[path]: 391 | api_instance["request_type"] = rt 392 | 393 | for content in api_data[path][rt]: 394 | if content == "parameters": 395 | api_instance["parameters"] = api_data[path][rt][content] 396 | elif content == "requestBody": 397 | req_body.append(all_ref_remover(get_object_from_schema_reference(api_data[path][rt][content],open_api_json),open_api_json)) 398 | 399 | break 400 | 401 | api_instance["request_body"] = one_of_request_body_sorter(req_body) 402 | 403 | final_list.append(api_instance) 404 | 405 | return final_list 406 | 407 | # url_path,customer_data,driver_data,customer_api_data,driver_api_data,customer_base_url,driver_base_url 408 | 409 | def url_runner(url,customer_api_data,driver_api_data,which_entity): 410 | print("") 411 | print("==> url is ",url) 412 | print("") 413 | 414 | data = None 415 | api_data = None 416 | base_url = None 417 | other_entity_data = None 418 | 419 | if which_entity == "driver": 420 | api_data = driver_api_data 421 | data = driver_data 422 | base_url = driver_base_url 423 | other_entity_data = customer_data 424 | elif which_entity == "customer": 425 | api_data = customer_api_data 426 | data = customer_data 427 | base_url = customer_base_url 428 | other_entity_data = driver_data 429 | 430 | # if url == '/v2/auth/{authId}/verify': 431 | # print("which entity is ",which_entity) 432 | # print("api_data is ",api_data) 433 | 434 | for api_object in api_data: 435 | 436 | if api_object['url_path'] == url: 437 | request_body = {} 438 | path_contents = api_object['url_path'].split('/') 439 | 440 | for c in range(len(path_contents)): 441 | if "{" in path_contents[c]: 442 | path_contents[c] = data.get(path_contents[c][1:-1]) 443 | 444 | 445 | final_path = '/'.join(path_contents) 446 | 447 | parametersList = api_object.get("parameters") 448 | 449 | # queryParametersList = [{ 450 | # 'name' : 'paramter name', 451 | # 'type' : 'parameter type' 452 | # 'required' : Bool 453 | # }] 454 | 455 | queryParametersList = [] 456 | if parametersList and len(parametersList) > 0: 457 | for parameter in parametersList: 458 | if parameter.get('in') == 'query': 459 | parameter_object = { 460 | 'name' : parameter.get('name'), 461 | 'type' : parameter.get('schema').get('type'), 462 | 'required' : parameter.get('required') 463 | } 464 | queryParametersList.append(parameter_object) 465 | 466 | # print(queryParametersList) 467 | 468 | # parameter object = [{'name','value'}] 469 | parameterObjects = query_parameter_filler(final_path,queryParametersList,data) 470 | 471 | response = None 472 | request_body = None 473 | if len(api_object.get("request_body")) != 0: 474 | print("") 475 | index = 0 476 | 477 | if data.get(final_path) != None: 478 | request_body = data.get(final_path) 479 | else: 480 | request_body = request_body_filler("",api_object.get("request_body")[index],api_object,index,data,final_path,driver_data) 481 | 482 | response = make_api_call_on_success(final_path,api_object,data,request_body,base_url,parameterObjects) 483 | 484 | 485 | 486 | (data,other_entity_data,should_show_response) = response_parser(data,response,api_data,base_url,other_entity_data,which_entity,customer_api_data,driver_api_data,url) 487 | 488 | if should_show_response: 489 | print("") 490 | print("==> Fetching the response") 491 | print("") 492 | print(beautify_json(response)) 493 | print("") 494 | 495 | 496 | return True 497 | 498 | print("[-] I was not able to hit the url") 499 | return False 500 | 501 | def api_runner(): 502 | print("") 503 | try: 504 | customer_api_data = config_loader(customer_url) 505 | driver_api_data = config_loader(driver_url) 506 | ride_flow(customer_api_data,driver_api_data) 507 | except: 508 | return 509 | 510 | # (data_currently_in_use,found_the_api_object) = url_runner(url,data_currently_in_use,apis_currently_in_use,base_url) 511 | 512 | def rescuer(response,which_entity,customer_api_data,driver_api_data,url_path): 513 | 514 | if not isinstance(response, dict): 515 | return False 516 | 517 | 518 | 519 | if response.get("errorCode") == "HITS_LIMIT_EXCEED": 520 | inp = input("> Hits limit is reached shall I flush redis ? ") 521 | 522 | if isAffirmative(inp): 523 | print("[+] Flushed Redis Main Cluster") 524 | subprocess.run(["redis-cli", "-p", "6379", "FLUSHALL"]) 525 | 526 | # Flushing Redis Cluster 1 527 | print("[+] Flushed Redis Cluster 1") 528 | subprocess.run(["redis-cli", "-p", "30001", "FLUSHALL"]) 529 | 530 | # Flushing Redis Cluster 2 531 | print("[+] Flushed Redis Cluster 2") 532 | subprocess.run(["redis-cli", "-p", "30002", "FLUSHALL"]) 533 | 534 | # Flushing Redis Cluster 3 535 | print("[+] Flushed Redis Cluster 3") 536 | subprocess.run(["redis-cli", "-p", "30003", "FLUSHALL"]) 537 | 538 | if which_entity == "customer": 539 | found = url_runner('/v2/auth',customer_api_data,driver_api_data,"customer") 540 | 541 | elif which_entity == "driver": 542 | found = url_runner('/ui/auth',customer_api_data,driver_api_data,"driver") 543 | 544 | return False 545 | 546 | 547 | elif response.get("errorMessage") == "ACTIVE_BOOKING_ALREADY_PRESENT": 548 | inp = input("> Active booking is present shall I change the customer number ? ") 549 | if isAffirmative(inp): 550 | customer_data["mobileNumber"] = str(random.randrange(10**9, 10**10)) 551 | found = url_runner('/v2/auth',customer_api_data,driver_api_data,"customer") 552 | found = url_runner('/v2/auth/{authId}/verify',customer_api_data,driver_api_data,"customer") 553 | found = url_runner('/v2/rideSearch',customer_api_data,driver_api_data,"customer") 554 | loader("Getting estimates",5) 555 | found = url_runner('/v2/rideSearch/{searchId}/results',customer_api_data,driver_api_data,"customer") 556 | 557 | return False 558 | 559 | elif response.get("estimates") == []: 560 | inp = print("Estimates are not coming, please ensure driver offer allocator is running ") 561 | 562 | inp = input("> Shall I rerun the request : ") 563 | 564 | if isAffirmative(inp): 565 | found = url_runner('/v2/rideSearch',customer_api_data,driver_api_data,"customer") 566 | loader("Getting estimates",5) 567 | found = url_runner('/v2/rideSearch/{searchId}/results',customer_api_data,driver_api_data,"customer") 568 | else: 569 | inp = input("> Shall I register a driver and put it into that location : ") 570 | 571 | if isAffirmative(inp): 572 | driver_number = str(random.randrange(10**9, 10**10)) 573 | driver_data["mobileNumber"] = driver_number 574 | print("[+] Registering the driver with ",driver_data["mobileNumber"]) 575 | print("") 576 | subprocess.run(f"python3 /Users/juspay/NammaYatriMagic/register-driver.py " + driver_number, shell=True) 577 | found = url_runner('/ui/auth',customer_api_data,driver_api_data,"driver") 578 | found = url_runner('/ui/auth/{authId}/verify',customer_api_data,driver_api_data,"driver") 579 | found = url_runner('/ui/driver/setActivity',customer_api_data,driver_api_data,"driver") 580 | found = url_runner('/ui/driver/location',customer_api_data,driver_api_data,"driver") 581 | found = url_runner('/ui/driver/profile',customer_api_data,driver_api_data,"driver") 582 | found = url_runner('/v2/rideSearch',customer_api_data,driver_api_data,"customer") 583 | loader("Getting estimates",5) 584 | found = url_runner('/v2/rideSearch/{searchId}/results',customer_api_data,driver_api_data,"customer") 585 | return False 586 | 587 | elif response.get("errorCode") == "INTERNAL_ERROR": 588 | inp = input("> Internal error is coming shall I rerun the request : ") 589 | 590 | if isAffirmative(inp): 591 | found = url_runner(url_path,customer_api_data,driver_api_data,which_entity) 592 | return False 593 | return True 594 | 595 | 596 | 597 | def response_parser(data,response,api_data,base_url,other_entity_data,which_entity,customer_api_data,driver_api_data,url_path): 598 | 599 | isAllGood = rescuer(response,which_entity,customer_api_data,driver_api_data,url_path) 600 | 601 | 602 | print("") 603 | if (type(response) != str and response.get("errorCode") == "INVALID_TOKEN") or (type(response) != str and response.get("errorMessage") == "Header \"token\" is missing" ) : 604 | answer = input("[+] Token is not present shall I generate for you : ") 605 | 606 | if isAffirmative(answer): 607 | return (auth_and_verify(data,api_data,base_url),False) 608 | 609 | try: 610 | for x in response: 611 | data[x] = response[x] 612 | print("[+] Added ",x,"=",str(response[x]),"in data") 613 | 614 | if x == "estimates" and len(response[x]) > 0: 615 | data["estimateId"] = response[x][0].get("id") 616 | print("[+] Added estimateId =",response[x][0].get("id")) 617 | elif x == "selectedQuotes" and len(response[x]) > 0: 618 | data["quoteId"] = response[x][0].get("id") 619 | print("[+] Added quoteId =",response[x][0].get("id")) 620 | elif x == "searchRequestsForDriver" and len(response[x]) > 0: 621 | data["searchRequestId"] = response[x][0].get("searchRequestId") 622 | print("[+] Added searchRequestId = ",data["searchRequestId"]) 623 | elif x == "list" and len(response[x]) > 0: 624 | 625 | if which_entity == "driver": 626 | rides = response[x] 627 | rideList = next((ride for ride in rides if ride['status'] == 'NEW'), None) 628 | data["rideId"] = rideList['id'] if rideList else None 629 | print("[+] Added rideId = ",data["rideId"]) 630 | elif which_entity == "customer": 631 | bookings = response[x] 632 | bookingObject = next((booking for booking in bookings if booking['status'] == 'TRIP_ASSIGNED'), None) 633 | other_entity_data["rideOtp"] = bookingObject['rideList'][0]['rideOtp'] if bookingObject else None 634 | print("[+] Added rideOtp = ",other_entity_data["rideOtp"]) 635 | 636 | 637 | 638 | 639 | return (data,other_entity_data,isAllGood) 640 | except: 641 | return (data,other_entity_data,isAllGood) 642 | 643 | def make_api_call_on_success(final_path,api_object,data,request,base_url,query_parameters): 644 | return make_curl_request(final_path,api_object.get('request_type'),request,base_url,data,query_parameters) 645 | 646 | def main(): 647 | try: 648 | api_runner() 649 | except KeyboardInterrupt: 650 | print("") 651 | print("[+] See ya !") 652 | 653 | if __name__ == "__main__": 654 | main() 655 | 656 | -------------------------------------------------------------------------------- /postman.py: -------------------------------------------------------------------------------- 1 | import requests 2 | import json 3 | from prompt_toolkit import prompt 4 | from prompt_toolkit.completion import WordCompleter 5 | from prompt_toolkit.completion import Completer, Completion 6 | from datetime import datetime, timezone 7 | 8 | customer_url = "http://localhost:8013/openapi" 9 | driver_url = "http://localhost:8016/openapi" 10 | 11 | customer_base_url = "http://localhost:8013" 12 | driver_base_url = "http://localhost:8016" 13 | which_api_we_are_using = "customer" 14 | 15 | 16 | default_ridesearch_request = { 17 | "fareProductType": "ONE_WAY", 18 | "contents": { 19 | "origin": { 20 | "address": { 21 | "area": "8th Block Koramangala", 22 | "areaCode": "560047", 23 | "building": "Juspay Buildings", 24 | "city": "Bangalore", 25 | "country": "India", 26 | "door": "#444", 27 | "street": "18th Main", 28 | "state": "Karnataka" 29 | }, 30 | 31 | "gps": { 32 | "lat": 12.846907, 33 | "lon": 77.556936 34 | } 35 | }, 36 | "destination": { 37 | "address": { 38 | "area": "6th Block Koramangala", 39 | "areaCode": "560047", 40 | "building": "Juspay Apartments", 41 | "city": "Bangalore", 42 | "country": "India", 43 | "door": "#444", 44 | "street": "18th Main", 45 | "state": "Karnataka" 46 | }, 47 | "gps": { 48 | "lat": 12.846907, 49 | "lon": 77.566936 50 | } 51 | } 52 | } 53 | } 54 | 55 | def set_which_api_we_are_using(api): 56 | global which_api_we_are_using 57 | which_api_we_are_using = api 58 | 59 | def isAffirmative(x): 60 | if x == "yes" or x == "Y" or x == "y" or x == "1" or x == "Yes" or x == "": 61 | return True 62 | else: 63 | return False 64 | 65 | def isNegative(x): 66 | if x == "no" or x == "N" or x == "n" or x == "0" or x == "No": 67 | return True 68 | else: 69 | return False 70 | 71 | 72 | # customer_object = { 73 | # path : "", 74 | # type : "", 75 | # request_body : [] 76 | # parameters : [] 77 | # } 78 | 79 | customer_api_data = [] 80 | driver_api_data = [] 81 | 82 | all_customer_api = [] 83 | 84 | # Custom completer class 85 | class MyCompleter(Completer): 86 | def __init__(self, completions): 87 | super().__init__() 88 | self.completions = completions 89 | 90 | def get_completions(self, document, complete_event): 91 | 92 | text = document.text 93 | 94 | for completion in self.completions: 95 | if completion in text: 96 | yield Completion(completion, start_position=-len(text)) 97 | 98 | 99 | def isTrue(verdict): 100 | if verdict == "False" or verdict == "F" or verdict == "f" or verdict == "false" or verdict == "0": 101 | return False 102 | else: 103 | return True 104 | 105 | # return (input_in_proper_form,is_success) 106 | def input_sanitizer(inp,type_of_input): 107 | if type_of_input == 'boolean': 108 | return (isTrue(inp),True) 109 | elif type_of_input == 'string': 110 | return (str(inp),True) 111 | elif type_of_input == 'integer': 112 | try: 113 | return (int(inp),True) 114 | except: 115 | print("[-] Write input in proper form ( " + str(type_of_input) + " ) " ) 116 | print("") 117 | return (inp,False) 118 | elif type_of_input == 'double': 119 | try: 120 | return (float(inp),True) 121 | except: 122 | print("[-] Write input in proper form ( " + str(type_of_input) + " ) " ) 123 | print("") 124 | return (inp,False) 125 | 126 | # return type = {'name' : 'value','name':value} 127 | 128 | def query_parameter_filler(query_parameter_list,data): 129 | required_query_parameters = [parameter for parameter in query_parameter_list if parameter.get('required') == True ] 130 | non_required_query_parameters = [parameter for parameter in query_parameter_list if parameter.get('required') == False ] 131 | answers = {} 132 | print("") 133 | print("==> Fill mandatory query parameters") 134 | print("") 135 | 136 | for parameter in required_query_parameters: 137 | ip = "" 138 | if data.get(str(parameter.get('name'))) == None: 139 | prompt = "> Enter " + str(parameter.get('name')) + " ( " + str(parameter.get('type')) + ") : " 140 | ip = input(prompt) 141 | else: 142 | prompt = "> Enter " + str(parameter.get('name')) + " ( " + str(parameter.get('type')) + " ) ( default " + str(data.get(str(parameter.get('name')))) + ") : " 143 | ip = input(prompt) 144 | 145 | if ip == "": 146 | ip = data.get(str(parameter.get('name'))) 147 | 148 | 149 | (sanitized_input,isSuccess) = input_sanitizer(ip,str(parameter.get('type'))) 150 | 151 | while isSuccess == False: 152 | (sanitized_input,isSuccess) = input_sanitizer(ip,str(parameter.get('type'))) 153 | 154 | answers[str(parameter.get('name'))] = sanitized_input 155 | 156 | if len(non_required_query_parameters) > 0: 157 | answer = input("> Want to add non required parameters: ") 158 | 159 | while isAffirmative(answer): 160 | print("") 161 | print("[+] Which one ?") 162 | print("") 163 | 164 | for i in range(len(non_required_query_parameters)): 165 | print("[" + str(i) + "] " + str(non_required_query_parameters[i].get('name'))) 166 | 167 | print("") 168 | 169 | idx = input("> ") 170 | 171 | if idx == "": 172 | break 173 | else: 174 | index = int(idx) 175 | 176 | value = input("Enter the value of " + str(non_required_query_parameters[index].get('name')) + " ( " + str(non_required_query_parameters[index].get('type')) + " ) " + " : ") 177 | 178 | (sanitized_input,isSuccess) = input_sanitizer(value,non_required_query_parameters[index].get('type')) 179 | 180 | answers[str(non_required_query_parameters[index].get('name'))] = sanitized_input 181 | 182 | answer = input("> Wanna add more : ") 183 | 184 | return answers 185 | 186 | # return (isException,body) 187 | def handle_openapi_exception(path,data): 188 | 189 | request_body = {} 190 | 191 | if path == '/ui/driver/location': 192 | pt_lat = 12.846907 193 | pt_lon = 77.556936 194 | ts = datetime.utcnow().replace(tzinfo=timezone.utc).strftime("%Y-%m-%dT%H:%M:%SZ") 195 | 196 | ip = input("> Enter lat (default " + str(pt_lat) + " ) : ") 197 | 198 | if ip != "": 199 | (pt_lat,isSuccess) = sanitized_input(ip,'double') 200 | 201 | ip = input("> Enter lon (default " + str(pt_lon) + " ) : ") 202 | 203 | if ip != "": 204 | (pt_lon,isSuccess) = sanitized_input(ip,'double') 205 | 206 | 207 | return ([ 208 | { 209 | "pt": { 210 | "lat": pt_lat, 211 | "lon": pt_lon 212 | }, 213 | "ts": ts 214 | } 215 | ],True) 216 | 217 | return ({},False) 218 | 219 | 220 | 221 | 222 | def request_body_filler(initial_prompt,req_body,api_object,index,data,path): 223 | 224 | (body,isException) = handle_openapi_exception(path,data) 225 | 226 | if isException: 227 | print("") 228 | print("[-] This is an exception") 229 | print("") 230 | print(body) 231 | return body 232 | 233 | if req_body == None: 234 | print("[-] Empty request body") 235 | return {} 236 | 237 | all_properties_list = [] 238 | 239 | for x in req_body.get('properties'): 240 | all_properties_list.append(x) 241 | 242 | non_required_properties = [] 243 | 244 | if req_body.get("required") != None: 245 | non_required_properties = result = [x for x in all_properties_list if x not in req_body.get("required")] 246 | 247 | body = {} 248 | 249 | if req_body.get("required") != None: 250 | for param in req_body.get("required"): 251 | if str(req_body.get('properties').get(param).get('type')) != 'object': 252 | prompt_statement = "> Enter " + param + " ( " + initial_prompt + str(req_body.get('properties').get(param).get('type')) + " ) : " 253 | if data.get(param) != None: 254 | prompt_statement += "( default " + str(data.get(param)) + " ) : " 255 | 256 | inp = input(prompt_statement) 257 | 258 | if inp == "" and data.get(param) != None: 259 | body[param] = data.get(param) 260 | 261 | elif str(req_body.get('properties').get(param).get('type')) == 'number': 262 | body[param] = float(inp) 263 | 264 | elif str(req_body.get('properties').get(param).get('type')) == 'boolean': 265 | body[param] = bool(inp) 266 | else: 267 | body[param] = inp 268 | else: 269 | body[param] = request_body_filler(initial_prompt + " [ " + param + " ] " ,req_body.get("properties").get(param),api_object,index,data,path) 270 | 271 | if non_required_properties != None: 272 | answer = input("> Want to add any non required properties : ") 273 | 274 | while isAffirmative(answer): 275 | print("") 276 | print("[+] Which one ?") 277 | print("") 278 | 279 | for i in range(len(non_required_properties)): 280 | print("[" + str(i) + "] " + non_required_properties[i]) 281 | 282 | print("") 283 | 284 | idx = input("> ") 285 | 286 | if idx == "": 287 | break 288 | else: 289 | index = int(idx) 290 | 291 | value = input("Enter the value of " + non_required_properties[index] + " : ") 292 | 293 | body[non_required_properties[index]] = value 294 | 295 | answer = input("> Wanna add more : ") 296 | 297 | custom_verdict = input("> Want to add custom properties : ") 298 | 299 | while isAffirmative(custom_verdict): 300 | key = input("> Enter key : ") 301 | value = input("> Enter value : ") 302 | body[key] = value 303 | print("") 304 | custom_verdict = input("> Wanna add more ? ") 305 | 306 | print("") 307 | print("==> Your request is ") 308 | print("") 309 | print(beautify_json(body)) 310 | 311 | return body 312 | 313 | def one_of_request_body_sorter(req_body): 314 | 315 | if req_body == None or len(req_body) == 0 or req_body[0] == None or req_body[0].get('oneOf') == None: 316 | return req_body 317 | 318 | else : 319 | listy = [] 320 | for x in range(len(req_body[0].get('oneOf'))): 321 | listy.append(req_body[0].get('oneOf')[0]) 322 | return listy 323 | 324 | 325 | def auth_and_verify(data,api_data,base_url): 326 | 327 | if which_api_we_are_using == "customer": 328 | 329 | (data,found) = url_runner('/v2/auth',data,api_data,base_url) 330 | (data,found) = url_runner('/v2/auth/{authId}/verify',data,api_data,base_url) 331 | return data 332 | elif which_api_we_are_using == "driver": 333 | (data,found) = url_runner('/ui/auth',data,api_data,base_url) 334 | (data,found) = url_runner('/ui/auth/{authId}/verify',data,api_data,base_url) 335 | return data 336 | 337 | 338 | def get_object_from_schema_reference(request_body,open_api_json): 339 | for content in request_body: 340 | for appjson in request_body.get(content): 341 | for schema in request_body.get(content).get(appjson): 342 | for ref in request_body.get(content).get(appjson).get(schema): 343 | return open_api_json["components"]["schemas"].get(str(request_body.get(content).get(appjson).get(schema).get(ref)).split("/")[3]) 344 | 345 | def get_object_from_ref(ref,open_api_json): 346 | return open_api_json["components"]["schemas"].get(str(ref.split("/")[3])) 347 | 348 | def all_ref_remover(request_body,open_api_json): 349 | 350 | if request_body == None: 351 | return request_body 352 | 353 | if type(request_body) != dict and type(request_body) != list: 354 | return request_body 355 | 356 | for key in request_body: 357 | 358 | if type(request_body.get(key)) == dict and request_body.get(key).get('$ref') != None: 359 | obj = get_object_from_ref(request_body.get(key).get('$ref'),open_api_json) 360 | request_body[key] = obj 361 | 362 | if type(request_body.get(key)) == dict : 363 | request_body[key] = all_ref_remover(request_body.get(key),open_api_json) 364 | 365 | elif type(request_body.get(key)) == list : 366 | for l in range(len(request_body.get(key))): 367 | request_body[key][l] = all_ref_remover(request_body.get(key)[l],open_api_json) 368 | 369 | return request_body 370 | 371 | def make_curl_request(url,request_type,request_body,base_url,data,query_parameters): 372 | 373 | print("") 374 | print("==> Hitting " + base_url + url ) 375 | print("") 376 | 377 | api_key = data.get("token") 378 | headers = {"token": api_key} 379 | 380 | if request_type == "get": 381 | response = requests.get(base_url + url,headers=headers,params=query_parameters) 382 | try: 383 | return response.json() 384 | except: 385 | return response.text 386 | 387 | elif request_type == "post": 388 | response = requests.post(base_url + url,json=request_body,headers=headers,params=query_parameters) 389 | try: 390 | return response.json() 391 | except: 392 | return response.text 393 | 394 | elif request_type == "put": 395 | response = requests.put(base_url + url,json=request_body,headers=headers,params=query_parameters) 396 | try: 397 | return response.json() 398 | except: 399 | return response.text 400 | 401 | elif request_type == "delete": 402 | response = requests.delete(base_url + url,json=request_body,headers=headers,params=query_parameters) 403 | try: 404 | return response.json() 405 | except: 406 | return response.text 407 | 408 | def beautify_json(json_text): 409 | try: 410 | beautified_json = json.dumps(json_text, indent=4) 411 | return beautified_json 412 | except json.JSONDecodeError: 413 | return None 414 | 415 | def config_loader(url): 416 | final_list = [] 417 | open_api_json = make_curl_request(url,"get","","",{},{}) 418 | api_data = open_api_json["paths"] 419 | 420 | for path in api_data: 421 | api_instance = {} 422 | api_instance["url_path"] = path 423 | 424 | req_body = [] 425 | 426 | for rt in api_data[path]: 427 | api_instance["request_type"] = rt 428 | 429 | for content in api_data[path][rt]: 430 | if content == "parameters": 431 | api_instance["parameters"] = api_data[path][rt][content] 432 | elif content == "requestBody": 433 | req_body.append(all_ref_remover(get_object_from_schema_reference(api_data[path][rt][content],open_api_json),open_api_json)) 434 | 435 | break 436 | 437 | api_instance["request_body"] = one_of_request_body_sorter(req_body) 438 | 439 | final_list.append(api_instance) 440 | 441 | return final_list 442 | 443 | def url_runner(url,data,api_data,base_url): 444 | print("") 445 | print("==> url is ",url) 446 | print("") 447 | for api_object in api_data: 448 | if api_object['url_path'] == url: 449 | request_body = {} 450 | path_contents = api_object['url_path'].split('/') 451 | 452 | for c in range(len(path_contents)): 453 | if "{" in path_contents[c]: 454 | if data.get(path_contents[c][1:-1]) != None and data.get(path_contents[c][1:-1]) != "": 455 | y = input("> Default " + str(path_contents[c][1:-1]) + " exists press yes if you wanna use that ( " + data.get(path_contents[c][1:-1]) + " ) :") 456 | if isAffirmative(y): 457 | path_contents[c] = data.get(path_contents[c][1:-1]) 458 | else: 459 | x = input("> Enter " + path_contents[c][1:-1] + " : ") 460 | path_contents[c] = x 461 | else: 462 | x = input("> Enter " + path_contents[c][1:-1] + " : ") 463 | path_contents[c] = x 464 | 465 | api_object['url_path'] = '/'.join(path_contents) 466 | 467 | parametersList = api_object.get("parameters") 468 | 469 | # queryParametersList = [{ 470 | # 'name' : 'paramter name', 471 | # 'type' : 'parameter type' 472 | # 'required' : Bool 473 | # }] 474 | 475 | queryParametersList = [] 476 | if parametersList and len(parametersList) > 0: 477 | for parameter in parametersList: 478 | if parameter.get('in') == 'query': 479 | parameter_object = { 480 | 'name' : parameter.get('name'), 481 | 'type' : parameter.get('schema').get('type'), 482 | 'required' : parameter.get('required') 483 | } 484 | queryParametersList.append(parameter_object) 485 | 486 | # print(queryParametersList) 487 | 488 | # parameter object = [{'name','value'}] 489 | parameterObjects = query_parameter_filler(queryParametersList,data) 490 | 491 | if len(api_object.get("request_body")) == 0: 492 | response = make_api_call_on_success(api_object,data,None,base_url,parameterObjects) 493 | (data,should_show_response) = response_parser(data,response,api_data,base_url) 494 | if should_show_response: 495 | print("") 496 | print("==> Fetching the response") 497 | print("") 498 | print(beautify_json(response)) 499 | print("") 500 | 501 | 502 | else: 503 | print(" ==> Type your request") 504 | print("") 505 | index = 0 506 | 507 | if len(api_object.get("request_body")) > 1: 508 | 509 | inp = input("There are " + str(len(api_object.get("request_body"))) + " ways to make a request , Pick one (default 0) : ") 510 | 511 | if inp == "": 512 | index = 0 513 | else: 514 | index = int(inp) 515 | 516 | if data.get(api_object['url_path']) != None: 517 | x = input("Default request exists write yes if you want to use that : ") 518 | if isAffirmative(x): 519 | request_body = data.get(api_object['url_path']) 520 | else: 521 | request_body = request_body_filler("",api_object.get("request_body")[index],api_object,index,data,api_object['url_path']) 522 | else: 523 | request_body = request_body_filler("",api_object.get("request_body")[index],api_object,index,data,api_object['url_path']) 524 | 525 | response = make_api_call_on_success(api_object,data,request_body,base_url,parameterObjects) 526 | (data,should_show_response) = response_parser(data,response,api_data,base_url) 527 | if should_show_response: 528 | print("") 529 | print("==> Fetching the response") 530 | print("") 531 | print(beautify_json(response)) 532 | print("") 533 | 534 | 535 | 536 | 537 | 538 | return (data,True) 539 | return (data,False) 540 | 541 | def api_runner(): 542 | print("") 543 | customer_api_data = config_loader(customer_url) 544 | driver_api_data = config_loader(driver_url) 545 | 546 | found_the_api_object = False 547 | retry = True 548 | 549 | customer_data = { 550 | "merchantId" : "NAMMA_YATRI", 551 | "mobileNumber" : "9999999999", 552 | "mobileCountryCode" : "+91", 553 | "otp": "7891", 554 | "deviceToken": "8e83b5dc-99a0-4306-b90d-2345f3050972", 555 | "fareProductType": "ONE_WAY", 556 | "/v2/rideSearch" : default_ridesearch_request, 557 | "token" : "", 558 | "authId" : "", 559 | "autoAssignEnabled" : False 560 | } 561 | driver_data = { 562 | "mobileNumber" : "6666666666", 563 | "mobileCountryCode": "+91", 564 | "merchantId": "favorit0-0000-0000-0000-00000favorit", 565 | "otp": "7891", 566 | "deviceToken": "8e83b5dc-99a0-4306-b90d-2345f3050972", 567 | "active" : True 568 | } 569 | 570 | available_paths = [] 571 | data_currently_in_use = customer_data 572 | apis_currently_in_use = customer_api_data 573 | base_url = customer_base_url 574 | for i in range(len(apis_currently_in_use)) : 575 | available_paths.append(apis_currently_in_use[i]['url_path']) 576 | 577 | completer = WordCompleter(available_paths) 578 | suggested_url = "" 579 | 580 | while found_the_api_object == False or retry == True: 581 | if suggested_url != "": 582 | url = suggested_url 583 | else: 584 | url = prompt("> Enter the URL to make the cURL request: ", completer=completer) 585 | 586 | if url == "other": 587 | if (which_api_we_are_using) == "customer": 588 | print("") 589 | print("==> Switching to Driver") 590 | customer_data = data_currently_in_use 591 | data_currently_in_use = driver_data 592 | apis_currently_in_use = driver_api_data 593 | set_which_api_we_are_using("driver") 594 | base_url = driver_base_url 595 | available_paths = [] 596 | for i in range(len(apis_currently_in_use)) : 597 | available_paths.append(apis_currently_in_use[i]['url_path']) 598 | completer = WordCompleter(available_paths) 599 | elif (which_api_we_are_using) == "driver": 600 | print("") 601 | print("==> Switching to Customer") 602 | driver_data = data_currently_in_use 603 | data_currently_in_use = customer_data 604 | apis_currently_in_use = customer_api_data 605 | set_which_api_we_are_using("customer") 606 | base_url = customer_base_url 607 | available_paths = [] 608 | for i in range(len(apis_currently_in_use)) : 609 | available_paths.append(apis_currently_in_use[i]['url_path']) 610 | completer = WordCompleter(available_paths) 611 | 612 | 613 | 614 | (data_currently_in_use,found_the_api_object) = url_runner(url,data_currently_in_use,apis_currently_in_use,base_url) 615 | 616 | if found_the_api_object == True: 617 | suggested_url = "" 618 | 619 | if found_the_api_object == False: 620 | suggest = [] 621 | 622 | for i in range(len(available_paths)): 623 | if url.lower() in available_paths[i].lower(): 624 | suggest.append(available_paths[i]) 625 | 626 | if len(suggest) == 0: 627 | print("[-] No API path found") 628 | print("") 629 | else: 630 | print("[-] URL path is not present in the code perhaps you meant ") 631 | print("") 632 | for i in range(len(suggest)): 633 | print("[" + str(i) + "]",suggest[i]) 634 | print("") 635 | suggestion_user = input("> Enter the index of the API (default 0): ") 636 | 637 | if suggestion_user == "": 638 | suggestion_number = 0 639 | suggested_url = suggest[suggestion_number] 640 | else: 641 | suggestion_number = int(suggestion_user) 642 | suggested_url = suggest[suggestion_number] 643 | 644 | print("") 645 | else: 646 | # retry = isAffirmative(input("[+] Wanna run again : ")) 647 | found_the_api_object = False 648 | 649 | def response_parser(data,response,api_data,base_url): 650 | print("") 651 | if (type(response) != str and response.get("errorCode") == "INVALID_TOKEN") or (type(response) != str and response.get("errorMessage") == "Header \"token\" is missing" ) : 652 | answer = input("[+] Token is not present shall I generate for you : ") 653 | 654 | if isAffirmative(answer): 655 | return (auth_and_verify(data,api_data,base_url),False) 656 | 657 | try: 658 | for x in response: 659 | data[x] = response[x] 660 | print("[+] Added ",x,"=",str(response[x]),"in data") 661 | 662 | if x == "estimates" and len(response[x]) > 0: 663 | data["estimateId"] = response[x][0].get("id") 664 | print("[+] Added estimateId =",response[x][0].get("id")) 665 | elif x == "selectedQuotes" and len(response[x]) > 0: 666 | data["quoteId"] = response[x][0].get("id") 667 | print("[+] Added quoteId =",response[x][0].get("id")) 668 | elif x == "searchRequestsForDriver" and len(response[x]) > 0: 669 | data["searchRequestId"] = response[x][0].get("searchRequestId") 670 | print("[+] Added searchRequestId = ",data["searchRequestId"]) 671 | elif x == "list" and len(response[x]) > 0: 672 | rides = response[x] 673 | rideList = next((ride for ride in rides if ride['status'] == 'NEW'), None) 674 | data["rideId"] = rideList['id'] if rideList else None 675 | print("[+] Added rideId = ",data["rideId"]) 676 | return (data,True) 677 | except: 678 | return (data,True) 679 | 680 | def make_api_call_on_success(api_object,data,request,base_url,query_parameters): 681 | return make_curl_request(api_object.get('url_path'),api_object.get('request_type'),request,base_url,data,query_parameters) 682 | 683 | def main(): 684 | try: 685 | api_runner() 686 | except KeyboardInterrupt: 687 | print("") 688 | print("[+] See ya !") 689 | 690 | 691 | 692 | if __name__ == "__main__": 693 | main() 694 | 695 | -------------------------------------------------------------------------------- /NammaYatri-RideBooking.json: -------------------------------------------------------------------------------- 1 | { 2 | "info": { 3 | "_postman_id": "66267cb6-6453-46e5-a85a-00f9185c2e00", 4 | "name": "NammaYatri | Ride Booking", 5 | "schema": "https://schema.getpostman.com/json/collection/v2.1.0/collection.json", 6 | "_exporter_id": "24792004" 7 | }, 8 | "item": [ 9 | { 10 | "name": "BookingAndStartFlow", 11 | "item": [ 12 | { 13 | "name": "LoginAndSetDriverLocation", 14 | "item": [ 15 | { 16 | "name": "/v2/auth", 17 | "event": [ 18 | { 19 | "listen": "prerequest", 20 | "script": { 21 | "exec": [ 22 | "pm.variables.set(\"driver-number\", \"6666666666\");//data.driver.number);" 23 | ], 24 | "type": "text/javascript" 25 | } 26 | }, 27 | { 28 | "listen": "test", 29 | "script": { 30 | "exec": [ 31 | "var jsonData = JSON.parse(responseBody);", 32 | "postman.setEnvironmentVariable(\"driver_authId\", jsonData.authId);", 33 | "console.log(jsonData)" 34 | ], 35 | "type": "text/javascript" 36 | } 37 | } 38 | ], 39 | "request": { 40 | "method": "POST", 41 | "header": [], 42 | "body": { 43 | "mode": "raw", 44 | "raw": "{\n \"mobileNumber\": \"{{driver-number}}\",\n \"mobileCountryCode\": \"+91\",\n \"merchantId\": \"favorit0-0000-0000-0000-00000favorit\"\n}", 45 | "options": { 46 | "raw": { 47 | "language": "json" 48 | } 49 | } 50 | }, 51 | "url": { 52 | "raw": "http://localhost:8016/ui/auth", 53 | "host": [ 54 | "http://localhost:8016/ui" 55 | ], 56 | "path": [ 57 | "auth" 58 | ] 59 | } 60 | }, 61 | "response": [] 62 | }, 63 | { 64 | "name": "/v2/auth/:authId/verify", 65 | "event": [ 66 | { 67 | "listen": "test", 68 | "script": { 69 | "exec": [ 70 | "var jsonData = JSON.parse(responseBody);", 71 | "postman.setEnvironmentVariable(\"driver_token\", jsonData.token);", 72 | "console.log(jsonData)" 73 | ], 74 | "type": "text/javascript" 75 | } 76 | } 77 | ], 78 | "protocolProfileBehavior": { 79 | "disabledSystemHeaders": { 80 | "connection": true, 81 | "accept-encoding": true, 82 | "accept": true, 83 | "user-agent": true 84 | } 85 | }, 86 | "request": { 87 | "method": "POST", 88 | "header": [ 89 | { 90 | "key": "Content-Type", 91 | "value": "application/json;charset=utf-8", 92 | "disabled": true 93 | }, 94 | { 95 | "key": "Accept", 96 | "value": "application/json;charset=utf-8", 97 | "disabled": true 98 | } 99 | ], 100 | "body": { 101 | "mode": "raw", 102 | "raw": "{\n \"otp\": \"7891\",\n \"deviceToken\": \"8e83b5dc-99a0-4306-b90d-2345f3050972\"\n}", 103 | "options": { 104 | "raw": { 105 | "language": "json" 106 | } 107 | } 108 | }, 109 | "url": { 110 | "raw": "http://localhost:8016/ui/auth/:authId/verify", 111 | "host": [ 112 | "http://localhost:8016/ui" 113 | ], 114 | "path": [ 115 | "auth", 116 | ":authId", 117 | "verify" 118 | ], 119 | "variable": [ 120 | { 121 | "key": "authId", 122 | "value": "{{driver_authId}}", 123 | "description": "(Requir" 124 | } 125 | ] 126 | } 127 | }, 128 | "response": [] 129 | }, 130 | { 131 | "name": "/driver/enable", 132 | "event": [ 133 | { 134 | "listen": "test", 135 | "script": { 136 | "exec": [ 137 | "var jsonData = JSON.parse(responseBody);", 138 | "console.log(jsonData)" 139 | ], 140 | "type": "text/javascript" 141 | } 142 | } 143 | ], 144 | "request": { 145 | "auth": { 146 | "type": "apikey", 147 | "apikey": [ 148 | { 149 | "key": "value", 150 | "value": "{{driver_token}}", 151 | "type": "string" 152 | }, 153 | { 154 | "key": "key", 155 | "value": "token", 156 | "type": "string" 157 | }, 158 | { 159 | "key": "in", 160 | "value": "header", 161 | "type": "string" 162 | } 163 | ] 164 | }, 165 | "method": "POST", 166 | "header": [ 167 | { 168 | "key": "Accept", 169 | "value": "application/json;charset=utf-8" 170 | } 171 | ], 172 | "url": { 173 | "raw": "http://localhost:8016/ui/driver/setActivity?active=true&mode=\"ONLINE\"", 174 | "raw": "http://localhost:8016/ui/driver/setActivity?active=true&mode=\"ONLINE\"", 175 | "host": [ 176 | "http://localhost:8016/ui" 177 | ], 178 | "path": [ 179 | "driver", 180 | "setActivity" 181 | ], 182 | "query": [ 183 | { 184 | "key": "active", 185 | "value": "true", 186 | "description": "(Required) " 187 | }, 188 | { 189 | "key": "mode", 190 | "value": "\"ONLINE\"" 191 | } 192 | ] 193 | } 194 | }, 195 | "response": [] 196 | }, 197 | { 198 | "name": "/driver/setActivity", 199 | "event": [ 200 | { 201 | "listen": "test", 202 | "script": { 203 | "exec": [ 204 | "var jsonData = JSON.parse(responseBody);", 205 | "console.log(jsonData)" 206 | ], 207 | "type": "text/javascript" 208 | } 209 | } 210 | ], 211 | "request": { 212 | "auth": { 213 | "type": "apikey", 214 | "apikey": [ 215 | { 216 | "key": "value", 217 | "value": "{{driver_token}}", 218 | "type": "string" 219 | }, 220 | { 221 | "key": "key", 222 | "value": "token", 223 | "type": "string" 224 | }, 225 | { 226 | "key": "in", 227 | "value": "header", 228 | "type": "string" 229 | } 230 | ] 231 | }, 232 | "method": "POST", 233 | "header": [ 234 | { 235 | "key": "Accept", 236 | "value": "application/json;charset=utf-8" 237 | } 238 | ], 239 | "url": { 240 | "raw": "http://localhost:8016/ui//driver/setActivity?active=true&mode=\"ONLINE\"", 241 | "host": [ 242 | "http://localhost:8016/ui" 243 | ], 244 | "path": [ 245 | "driver", 246 | "setActivity" 247 | ], 248 | "query": [ 249 | { 250 | "key": "active", 251 | "value": "true", 252 | "description": "(Required) " 253 | }, 254 | { 255 | "key": "mode", 256 | "value": "\"ONLINE\"" 257 | } 258 | ] 259 | } 260 | }, 261 | "response": [] 262 | }, 263 | { 264 | "name": "/profile", 265 | "event": [ 266 | { 267 | "listen": "test", 268 | "script": { 269 | "exec": [ 270 | "var jsonData = JSON.parse(responseBody);", 271 | "postman.setEnvironmentVariable(\"mId\", jsonData.organization.id);", 272 | "postman.setEnvironmentVariable(\"vt\", jsonData.linkedVehicle.variant);", 273 | "postman.setEnvironmentVariable(\"dm\", jsonData.mode);", 274 | "console.log(jsonData)" 275 | ], 276 | "type": "text/javascript" 277 | } 278 | } 279 | ], 280 | "request": { 281 | "auth": { 282 | "type": "apikey", 283 | "apikey": [ 284 | { 285 | "key": "value", 286 | "value": "{{driver_token}}", 287 | "type": "string" 288 | }, 289 | { 290 | "key": "key", 291 | "value": "token", 292 | "type": "string" 293 | }, 294 | { 295 | "key": "in", 296 | "value": "header", 297 | "type": "string" 298 | } 299 | ] 300 | }, 301 | 302 | "method": "GET", 303 | "header": [], 304 | "url": { 305 | "raw": "http://localhost:8016/ui/driver/profile", 306 | "host": [ 307 | "http://localhost:8016/ui" 308 | ], 309 | "path": [ 310 | "driver", 311 | "profile" 312 | ] 313 | } 314 | }, 315 | "response": [] 316 | }, 317 | { 318 | "name": "/v2/driver/location", 319 | "event": [ 320 | { 321 | "listen": "prerequest", 322 | "script": { 323 | "exec": [ 324 | "var moment = require('moment');", 325 | "var olat = 12.846907", 326 | "var ol = 77.556936", 327 | "pm.globals.set(\"current_time\",moment.utc().format(\"YYYY-MM-DDTHH:mm:ssZ\"))//moment.utc().format(\"YYYY-MM-DDTHH:mm:ssZ\"));", 328 | "pm.variables.set(\"driver-lat\", olat.toString());", 329 | "pm.variables.set(\"driver-lon\", ol.toString());" 330 | ], 331 | "type": "text/javascript" 332 | } 333 | }, 334 | { 335 | "listen": "test", 336 | "script": { 337 | "exec": [ 338 | "var jsonData = JSON.parse(responseBody);", 339 | "console.log(jsonData)" 340 | ], 341 | "type": "text/javascript" 342 | } 343 | } 344 | ], 345 | "request": { 346 | "auth": { 347 | "type": "apikey", 348 | "apikey": [ 349 | { 350 | "key": "value", 351 | "value": "{{driver_token}}", 352 | "type": "string" 353 | }, 354 | { 355 | "key": "key", 356 | "value": "token", 357 | "type": "string" 358 | }, 359 | { 360 | "key": "in", 361 | "value": "header", 362 | "type": "string" 363 | } 364 | ] 365 | }, 366 | "method": "POST", 367 | "header": [ 368 | { 369 | "key": "Content-Type", 370 | "value": "application/json;charset=utf-8" 371 | }, 372 | { 373 | "key": "Accept", 374 | "value": "application/json;charset=utf-8" 375 | }, 376 | { 377 | "key": "mId", 378 | "value": "{{mId}}" 379 | }, 380 | { 381 | "key" : "vt", 382 | "value": "{{vt}}" 383 | }, 384 | { 385 | "key": "dm", 386 | "value": "{{dm}}" 387 | } 388 | ], 389 | "body": { 390 | "mode": "raw", 391 | "raw": "[\n {\n \"pt\": {\n \"lat\": {{driver-lat}},\n \"lon\": {{driver-lon}}\n },\n \"ts\": \"{{current_time}}\"\n }\n]", 392 | "options": { 393 | "raw": { 394 | "language": "json" 395 | } 396 | } 397 | }, 398 | "url": { 399 | "raw": "http://localhost:8081/ui/driver/location", 400 | "host": [ 401 | "http://localhost:8081/ui" 402 | ], 403 | "path": [ 404 | "driver", 405 | "location" 406 | ] 407 | } 408 | }, 409 | "response": [] 410 | } 411 | ] 412 | }, 413 | { 414 | "name": "LoginCustomerAndSelectEstimate", 415 | "item": [ 416 | { 417 | "name": "auth", 418 | "event": [ 419 | { 420 | "listen": "prerequest", 421 | "script": { 422 | "exec": [ 423 | " pm.variables.set(\"customer-number\", \"1987654330\");" 424 | ], 425 | "type": "text/javascript" 426 | } 427 | }, 428 | { 429 | "listen": "test", 430 | "script": { 431 | "exec": [ 432 | "var jsonData = JSON.parse(responseBody);", 433 | "postman.setEnvironmentVariable(\"customer_authId\", jsonData.authId);", 434 | "var jsonData = JSON.parse(responseBody);", 435 | "console.log(jsonData)" 436 | ], 437 | "type": "text/javascript" 438 | } 439 | } 440 | ], 441 | "request": { 442 | "method": "POST", 443 | "header": [ 444 | { 445 | "key": "Content-Type", 446 | "value": "application/json;charset=utf-8" 447 | } 448 | ], 449 | "body": { 450 | "mode": "raw", 451 | "raw": "{\n \"mobileNumber\": \"{{customer-number}}\",\n \"mobileCountryCode\": \"+91\",\n \"merchantId\" : \"YATRI\"\n}", 452 | "options": { 453 | "raw": { 454 | "language": "json" 455 | } 456 | } 457 | }, 458 | "url": { 459 | "raw": "http://localhost:8013/v2/auth", 460 | "host": [ 461 | "http://localhost:8013/v2" 462 | ], 463 | "path": [ 464 | "auth" 465 | ] 466 | } 467 | }, 468 | "response": [] 469 | }, 470 | { 471 | "name": "auth/:authId/verify", 472 | "event": [ 473 | { 474 | "listen": "test", 475 | "script": { 476 | "exec": [ 477 | "var jsonData = JSON.parse(responseBody);", 478 | "postman.setEnvironmentVariable(\"customer_token\", jsonData.token);", 479 | "var jsonData = JSON.parse(responseBody);", 480 | "console.log(jsonData)" 481 | ], 482 | "type": "text/javascript" 483 | } 484 | } 485 | ], 486 | "request": { 487 | "method": "POST", 488 | "header": [ 489 | { 490 | "key": "Content-Type", 491 | "value": "application/json;charset=utf-8" 492 | } 493 | ], 494 | "body": { 495 | "mode": "raw", 496 | "raw": "{\n \"otp\": \"7891\",\n \"deviceToken\": \"5497873d-10ca-42f3-8a32-22de4c916026\"\n}", 497 | "options": { 498 | "raw": { 499 | "language": "json" 500 | } 501 | } 502 | }, 503 | "url": { 504 | "raw": "http://localhost:8013/v2/auth/:authId/verify", 505 | "host": [ 506 | "http://localhost:8013/v2" 507 | ], 508 | "path": [ 509 | "auth", 510 | ":authId", 511 | "verify" 512 | ], 513 | "variable": [ 514 | { 515 | "key": "authId", 516 | "value": "{{customer_authId}}", 517 | "description": "(Required) " 518 | } 519 | ] 520 | } 521 | }, 522 | "response": [] 523 | }, 524 | { 525 | "name": "/v2/rideSearch", 526 | "event": [ 527 | { 528 | "listen": "prerequest", 529 | "script": { 530 | "exec": [ 531 | "setTimeout(function(){}, 5000);", 532 | "pm.variables.set(\"customer-origin-lat\", \"12.846907\");", 533 | "pm.variables.set(\"customer-origin-lon\", \"77.556936\");", 534 | "pm.variables.set(\"customer-destination-lat\", \"12.846907\");", 535 | "pm.variables.set(\"customer-destination-lon\", \"77.566936\");" 536 | ], 537 | "type": "text/javascript" 538 | } 539 | }, 540 | { 541 | "listen": "test", 542 | "script": { 543 | "exec": [ 544 | "const body = JSON.parse(responseBody);", 545 | "postman.setEnvironmentVariable(\"customer_searchId\", body.searchId);", 546 | "var jsonData = JSON.parse(responseBody);", 547 | "console.log(jsonData)" 548 | ], 549 | "type": "text/javascript" 550 | } 551 | } 552 | ], 553 | "request": { 554 | "auth": { 555 | "type": "apikey", 556 | "apikey": [ 557 | { 558 | "key": "value", 559 | "value": "{{customer_token}}", 560 | "type": "string" 561 | }, 562 | { 563 | "key": "key", 564 | "value": "token", 565 | "type": "string" 566 | }, 567 | { 568 | "key": "in", 569 | "value": "header", 570 | "type": "string" 571 | } 572 | ] 573 | }, 574 | "method": "POST", 575 | "header": [ 576 | { 577 | "key": "Content-Type", 578 | "value": "application/json;charset=utf-8" 579 | }, 580 | { 581 | "key": "token", 582 | "value": "{{app-reg-token}}", 583 | "type": "text" 584 | } 585 | ], 586 | "body": { 587 | "mode": "raw", 588 | "raw": "{\n \"fareProductType\": \"ONE_WAY\",\n \"contents\": {\n \"origin\": {\n \"address\": {\n \"area\": \"8th Block Koramangala\",\n \"areaCode\": \"560047\",\n \"building\": \"Juspay Buildings\",\n \"city\": \"Bangalore\",\n \"country\": \"India\",\n \"door\": \"#444\",\n \"street\": \"18th Main\",\n \"state\": \"Karnataka\"\n },\n \"gps\": {\n \"lat\": {{customer-origin-lat}},\n \"lon\": {{customer-origin-lon}}\n }\n },\n \"destination\": {\n \"address\": {\n \"area\": \"6th Block Koramangala\",\n \"areaCode\": \"560047\",\n \"building\": \"Juspay Apartments\",\n \"city\": \"Bangalore\",\n \"country\": \"India\",\n \"door\": \"#444\",\n \"street\": \"18th Main\",\n \"state\": \"Karnataka\"\n },\n \"gps\": {\n \"lat\": {{customer-destination-lat}},\n \"lon\": {{customer-destination-lon}}\n }\n }\n }\n}", 589 | "options": { 590 | "raw": { 591 | "language": "json" 592 | } 593 | } 594 | }, 595 | "url": { 596 | "raw": "http://localhost:8013/v2/rideSearch", 597 | "host": [ 598 | "http://localhost:8013/v2" 599 | ], 600 | "path": [ 601 | "rideSearch" 602 | ] 603 | } 604 | }, 605 | "response": [] 606 | }, 607 | { 608 | "name": "/v2/rideSearch/:searchId/results", 609 | "event": [ 610 | { 611 | "listen": "test", 612 | "script": { 613 | "exec": [ 614 | "const body = JSON.parse(responseBody);", 615 | "postman.setEnvironmentVariable(\"customer_estimate_id\", body.estimates[0].id);", 616 | "var jsonData = JSON.parse(responseBody);", 617 | "console.log(jsonData)" 618 | ], 619 | "type": "text/javascript" 620 | } 621 | }, 622 | { 623 | "listen": "prerequest", 624 | "script": { 625 | "exec": [ 626 | "setTimeout(function(){}, 5000);" 627 | ], 628 | "type": "text/javascript" 629 | } 630 | } 631 | ], 632 | "request": { 633 | "auth": { 634 | "type": "apikey", 635 | "apikey": [ 636 | { 637 | "key": "value", 638 | "value": "{{customer_token}}", 639 | "type": "string" 640 | }, 641 | { 642 | "key": "key", 643 | "value": "token", 644 | "type": "string" 645 | }, 646 | { 647 | "key": "in", 648 | "value": "header", 649 | "type": "string" 650 | } 651 | ] 652 | }, 653 | "method": "GET", 654 | "header": [ 655 | { 656 | "key": "token", 657 | "value": "{{app-reg-token}}", 658 | "type": "text" 659 | } 660 | ], 661 | "url": { 662 | "raw": "http://localhost:8013/v2/rideSearch/:searchId/results", 663 | "host": [ 664 | "http://localhost:8013/v2" 665 | ], 666 | "path": [ 667 | "rideSearch", 668 | ":searchId", 669 | "results" 670 | ], 671 | "variable": [ 672 | { 673 | "key": "searchId", 674 | "value": "{{customer_searchId}}" 675 | } 676 | ] 677 | } 678 | }, 679 | "response": [] 680 | }, 681 | { 682 | "name": "/estimate/:estimateId/select2", 683 | "event": [ 684 | { 685 | "listen": "test", 686 | "script": { 687 | "exec": [ 688 | "var jsonData = JSON.parse(responseBody);", 689 | "console.log(jsonData)" 690 | ], 691 | "type": "text/javascript" 692 | } 693 | } 694 | ], 695 | "request": { 696 | "auth": { 697 | "type": "apikey", 698 | "apikey": [ 699 | { 700 | "key": "value", 701 | "value": "{{customer_token}}", 702 | "type": "string" 703 | }, 704 | { 705 | "key": "key", 706 | "value": "token", 707 | "type": "string" 708 | }, 709 | { 710 | "key": "in", 711 | "value": "header", 712 | "type": "string" 713 | } 714 | ] 715 | }, 716 | "method": "POST", 717 | "header": [], 718 | "body": { 719 | "mode": "raw", 720 | "raw": "{\n \"autoAssignEnabledV2\": false,\n \"autoAssignEnabled\": false,\n \"customerExtraFee\": 1\n}", 721 | "options": { 722 | "raw": { 723 | "language": "json" 724 | } 725 | } 726 | }, 727 | "url": { 728 | "raw": "http://localhost:8013/v2/estimate/:estimateId/select2", 729 | "host": [ 730 | "http://localhost:8013/v2" 731 | ], 732 | "path": [ 733 | "estimate", 734 | ":estimateId", 735 | "select2" 736 | ], 737 | "variable": [ 738 | { 739 | "key": "estimateId", 740 | "value": "{{customer_estimate_id}}" 741 | } 742 | ] 743 | } 744 | }, 745 | "response": [] 746 | } 747 | ] 748 | }, 749 | { 750 | "name": "DriverOfferQuote", 751 | "item": [ 752 | { 753 | "name": "/v2/driver/nearbyRideRequest", 754 | "event": [ 755 | { 756 | "listen": "test", 757 | "script": { 758 | "exec": [ 759 | "const body = JSON.parse(responseBody);", 760 | "postman.setEnvironmentVariable(\"driver_search_request_id\", body.searchRequestsForDriver[0].searchRequestId);", 761 | "var jsonData = JSON.parse(responseBody);", 762 | "console.log(jsonData)" 763 | ], 764 | "type": "text/javascript" 765 | } 766 | }, 767 | { 768 | "listen": "prerequest", 769 | "script": { 770 | "exec": [ 771 | "setTimeout(function(){}, 5000);" 772 | ], 773 | "type": "text/javascript" 774 | } 775 | } 776 | ], 777 | "request": { 778 | "auth": { 779 | "type": "apikey", 780 | "apikey": [ 781 | { 782 | "key": "value", 783 | "value": "{{driver_token}}", 784 | "type": "string" 785 | }, 786 | { 787 | "key": "key", 788 | "value": "token", 789 | "type": "string" 790 | }, 791 | { 792 | "key": "in", 793 | "value": "header", 794 | "type": "string" 795 | } 796 | ] 797 | }, 798 | "method": "GET", 799 | "header": [ 800 | { 801 | "key": "Accept", 802 | "value": "application/json;charset=utf-8" 803 | } 804 | ], 805 | "url": { 806 | "raw": "http://localhost:8016/ui/driver/nearbyRideRequest", 807 | "host": [ 808 | "http://localhost:8016/ui" 809 | ], 810 | "path": [ 811 | "driver", 812 | "nearbyRideRequest" 813 | ] 814 | } 815 | }, 816 | "response": [ 817 | { 818 | "name": "response", 819 | "originalRequest": { 820 | "method": "GET", 821 | "header": [ 822 | { 823 | "description": "Added as a part of security scheme: apikey", 824 | "key": "token", 825 | "value": "" 826 | } 827 | ], 828 | "url": { 829 | "raw": "http://localhost:8013/v2/driver/nearbyRideRequest", 830 | "host": [ 831 | "http://localhost:8013" 832 | ], 833 | "path": [ 834 | "v2", 835 | "driver", 836 | "nearbyRideRequest" 837 | ] 838 | } 839 | }, 840 | "status": "OK", 841 | "code": 200, 842 | "_postman_previewlanguage": "json", 843 | "header": [ 844 | { 845 | "key": "Content-Type", 846 | "value": "application/json;charset=utf-8" 847 | } 848 | ], 849 | "cookie": [], 850 | "body": "{\n \"searchRequests\": [\n {\n \"searchRequestId\": \"proident qui sunt et\",\n \"searchRequestValidTill\": \"2016-07-22T00:00:00Z\",\n \"distanceToPickup\": -8892007021473223000,\n \"durationToPickup\": 9193992596821537000,\n \"baseFare\": 37688420.94047874\n },\n {\n \"searchRequestId\": \"laborum Excepteur in amet commodo\",\n \"searchRequestValidTill\": \"2016-07-22T00:00:00Z\",\n \"distanceToPickup\": 5409711012229435000,\n \"durationToPickup\": 8041103522133586000,\n \"baseFare\": 26816793.720645607\n }\n ]\n}" 851 | }, 852 | { 853 | "name": "Invalid `token`", 854 | "originalRequest": { 855 | "method": "GET", 856 | "header": [ 857 | { 858 | "description": "Added as a part of security scheme: apikey", 859 | "key": "token", 860 | "value": "" 861 | } 862 | ], 863 | "url": { 864 | "raw": "http://localhost:8013/v2/driver/nearbyRideRequest", 865 | "host": [ 866 | "http://localhost:8013" 867 | ], 868 | "path": [ 869 | "v2", 870 | "driver", 871 | "nearbyRideRequest" 872 | ] 873 | } 874 | }, 875 | "status": "Bad Request", 876 | "code": 400, 877 | "_postman_previewlanguage": "text", 878 | "header": [ 879 | { 880 | "key": "Content-Type", 881 | "value": "text/plain" 882 | } 883 | ], 884 | "cookie": [], 885 | "body": "" 886 | }, 887 | { 888 | "name": "Unauthorized", 889 | "originalRequest": { 890 | "method": "GET", 891 | "header": [ 892 | { 893 | "description": "Added as a part of security scheme: apikey", 894 | "key": "token", 895 | "value": "" 896 | } 897 | ], 898 | "url": { 899 | "raw": "http://localhost:8013/v2/driver/nearbyRideRequest", 900 | "host": [ 901 | "http://localhost:8013" 902 | ], 903 | "path": [ 904 | "v2", 905 | "driver", 906 | "nearbyRideRequest" 907 | ] 908 | } 909 | }, 910 | "status": "Unauthorized", 911 | "code": 401, 912 | "_postman_previewlanguage": "text", 913 | "header": [ 914 | { 915 | "key": "Content-Type", 916 | "value": "text/plain" 917 | } 918 | ], 919 | "cookie": [], 920 | "body": "" 921 | } 922 | ] 923 | }, 924 | { 925 | "name": "/v2/driver/searchRequest/quote/offer", 926 | "event": [ 927 | { 928 | "listen": "test", 929 | "script": { 930 | "exec": [ 931 | "var jsonData = JSON.parse(responseBody);", 932 | "console.log(jsonData)" 933 | ], 934 | "type": "text/javascript" 935 | } 936 | } 937 | ], 938 | "request": { 939 | "auth": { 940 | "type": "apikey", 941 | "apikey": [ 942 | { 943 | "key": "value", 944 | "value": "{{driver_token}}", 945 | "type": "string" 946 | }, 947 | { 948 | "key": "key", 949 | "value": "token", 950 | "type": "string" 951 | }, 952 | { 953 | "key": "in", 954 | "value": "header", 955 | "type": "string" 956 | } 957 | ] 958 | }, 959 | "method": "POST", 960 | "header": [ 961 | { 962 | "key": "Content-Type", 963 | "value": "application/json;charset=utf-8" 964 | }, 965 | { 966 | "key": "Accept", 967 | "value": "application/json;charset=utf-8" 968 | } 969 | ], 970 | "body": { 971 | "mode": "raw", 972 | "raw": "{\n \"searchRequestId\": \"{{driver_search_request_id}}\"\n}", 973 | "options": { 974 | "raw": { 975 | "language": "json" 976 | } 977 | } 978 | }, 979 | "url": { 980 | "raw": "http://localhost:8016/ui/driver/searchRequest/quote/offer", 981 | "host": [ 982 | "http://localhost:8016/ui" 983 | ], 984 | "path": [ 985 | "driver", 986 | "searchRequest", 987 | "quote", 988 | "offer" 989 | ] 990 | } 991 | }, 992 | "response": [ 993 | { 994 | "name": "response", 995 | "originalRequest": { 996 | "method": "POST", 997 | "header": [ 998 | { 999 | "description": "Added as a part of security scheme: apikey", 1000 | "key": "token", 1001 | "value": "" 1002 | } 1003 | ], 1004 | "body": { 1005 | "mode": "raw", 1006 | "raw": "{\n \"searchRequestId\": \"Ut consequat ut\",\n \"offeredFare\": 22215642.991347462\n}", 1007 | "options": { 1008 | "raw": { 1009 | "language": "json" 1010 | } 1011 | } 1012 | }, 1013 | "url": { 1014 | "raw": "http://localhost:8013/v2/driver/searchRequest/quote/offer", 1015 | "host": [ 1016 | "http://localhost:8013" 1017 | ], 1018 | "path": [ 1019 | "v2", 1020 | "driver", 1021 | "searchRequest", 1022 | "quote", 1023 | "offer" 1024 | ] 1025 | } 1026 | }, 1027 | "status": "OK", 1028 | "code": 200, 1029 | "_postman_previewlanguage": "json", 1030 | "header": [ 1031 | { 1032 | "key": "Content-Type", 1033 | "value": "application/json;charset=utf-8" 1034 | } 1035 | ], 1036 | "cookie": [], 1037 | "body": "\"Success\"" 1038 | }, 1039 | { 1040 | "name": "Invalid `body` or `token`", 1041 | "originalRequest": { 1042 | "method": "POST", 1043 | "header": [ 1044 | { 1045 | "description": "Added as a part of security scheme: apikey", 1046 | "key": "token", 1047 | "value": "" 1048 | } 1049 | ], 1050 | "body": { 1051 | "mode": "raw", 1052 | "raw": "{\n \"searchRequestId\": \"Ut consequat ut\",\n \"offeredFare\": 22215642.991347462\n}", 1053 | "options": { 1054 | "raw": { 1055 | "language": "json" 1056 | } 1057 | } 1058 | }, 1059 | "url": { 1060 | "raw": "http://localhost:8013/v2/driver/searchRequest/quote/offer", 1061 | "host": [ 1062 | "http://localhost:8013" 1063 | ], 1064 | "path": [ 1065 | "v2", 1066 | "driver", 1067 | "searchRequest", 1068 | "quote", 1069 | "offer" 1070 | ] 1071 | } 1072 | }, 1073 | "status": "Bad Request", 1074 | "code": 400, 1075 | "_postman_previewlanguage": "text", 1076 | "header": [ 1077 | { 1078 | "key": "Content-Type", 1079 | "value": "text/plain" 1080 | } 1081 | ], 1082 | "cookie": [], 1083 | "body": "" 1084 | }, 1085 | { 1086 | "name": "Unauthorized", 1087 | "originalRequest": { 1088 | "method": "POST", 1089 | "header": [ 1090 | { 1091 | "description": "Added as a part of security scheme: apikey", 1092 | "key": "token", 1093 | "value": "" 1094 | } 1095 | ], 1096 | "body": { 1097 | "mode": "raw", 1098 | "raw": "{\n \"searchRequestId\": \"Ut consequat ut\",\n \"offeredFare\": 22215642.991347462\n}", 1099 | "options": { 1100 | "raw": { 1101 | "language": "json" 1102 | } 1103 | } 1104 | }, 1105 | "url": { 1106 | "raw": "http://localhost:8013/v2/driver/searchRequest/quote/offer", 1107 | "host": [ 1108 | "http://localhost:8013" 1109 | ], 1110 | "path": [ 1111 | "v2", 1112 | "driver", 1113 | "searchRequest", 1114 | "quote", 1115 | "offer" 1116 | ] 1117 | } 1118 | }, 1119 | "status": "Unauthorized", 1120 | "code": 401, 1121 | "_postman_previewlanguage": "text", 1122 | "header": [ 1123 | { 1124 | "key": "Content-Type", 1125 | "value": "text/plain" 1126 | } 1127 | ], 1128 | "cookie": [], 1129 | "body": "" 1130 | } 1131 | ] 1132 | } 1133 | ] 1134 | }, 1135 | { 1136 | "name": "CusomterAcceptQuote", 1137 | "item": [ 1138 | { 1139 | "name": "/estimate/:estimateId/quotes", 1140 | "event": [ 1141 | { 1142 | "listen": "prerequest", 1143 | "script": { 1144 | "exec": [ 1145 | "setTimeout(function(){}, 5000);" 1146 | ], 1147 | "type": "text/javascript" 1148 | } 1149 | }, 1150 | { 1151 | "listen": "test", 1152 | "script": { 1153 | "exec": [ 1154 | "const body = JSON.parse(responseBody);", 1155 | "postman.setEnvironmentVariable(\"customer_quote_id\", body.selectedQuotes[0].id);", 1156 | "var jsonData = JSON.parse(responseBody);", 1157 | "console.log(jsonData)" 1158 | ], 1159 | "type": "text/javascript" 1160 | } 1161 | } 1162 | ], 1163 | "request": { 1164 | "auth": { 1165 | "type": "apikey", 1166 | "apikey": [ 1167 | { 1168 | "key": "value", 1169 | "value": "{{customer_token}}", 1170 | "type": "string" 1171 | }, 1172 | { 1173 | "key": "key", 1174 | "value": "token", 1175 | "type": "string" 1176 | }, 1177 | { 1178 | "key": "in", 1179 | "value": "header", 1180 | "type": "string" 1181 | } 1182 | ] 1183 | }, 1184 | "method": "GET", 1185 | "header": [], 1186 | "url": { 1187 | "raw": "http://localhost:8013/v2/estimate/:estimateId/quotes", 1188 | "host": [ 1189 | "http://localhost:8013/v2" 1190 | ], 1191 | "path": [ 1192 | "estimate", 1193 | ":estimateId", 1194 | "quotes" 1195 | ], 1196 | "variable": [ 1197 | { 1198 | "key": "estimateId", 1199 | "value": "{{customer_estimate_id}}" 1200 | } 1201 | ] 1202 | } 1203 | }, 1204 | "response": [] 1205 | }, 1206 | { 1207 | "name": "/v2/rideSearch/quotes/:quoteId/confirm Copy", 1208 | "event": [ 1209 | { 1210 | "listen": "test", 1211 | "script": { 1212 | "exec": [ 1213 | "const body = JSON.parse(responseBody);", 1214 | "postman.setEnvironmentVariable(\"customer_bookingId\", body.bookingId);", 1215 | "var jsonData = JSON.parse(responseBody);", 1216 | "console.log(jsonData)" 1217 | ], 1218 | "type": "text/javascript" 1219 | } 1220 | } 1221 | ], 1222 | "request": { 1223 | "auth": { 1224 | "type": "apikey", 1225 | "apikey": [ 1226 | { 1227 | "key": "value", 1228 | "value": "{{customer_token}}", 1229 | "type": "string" 1230 | }, 1231 | { 1232 | "key": "key", 1233 | "value": "token", 1234 | "type": "string" 1235 | }, 1236 | { 1237 | "key": "in", 1238 | "value": "header", 1239 | "type": "string" 1240 | } 1241 | ] 1242 | }, 1243 | "method": "POST", 1244 | "header": [ 1245 | { 1246 | "key": "token", 1247 | "value": "{{app-reg-token}}", 1248 | "type": "text" 1249 | } 1250 | ], 1251 | "url": { 1252 | "raw": "http://localhost:8013/v2/rideSearch/quotes/:quoteId/confirm", 1253 | "host": [ 1254 | "http://localhost:8013/v2" 1255 | ], 1256 | "path": [ 1257 | "rideSearch", 1258 | "quotes", 1259 | ":quoteId", 1260 | "confirm" 1261 | ], 1262 | "variable": [ 1263 | { 1264 | "key": "quoteId", 1265 | "value": "{{customer_quote_id}}", 1266 | "description": "(Required) " 1267 | } 1268 | ] 1269 | } 1270 | }, 1271 | "response": [] 1272 | }, 1273 | { 1274 | "name": "/v2/rideSearch/quotes/:quoteId/confirm", 1275 | "event": [ 1276 | { 1277 | "listen": "test", 1278 | "script": { 1279 | "exec": [ 1280 | "const body = JSON.parse(responseBody);", 1281 | "postman.setEnvironmentVariable(\"customer_bookingId\", body.bookingId);", 1282 | "console.log(body)" 1283 | ], 1284 | "type": "text/javascript" 1285 | } 1286 | } 1287 | ], 1288 | "request": { 1289 | "auth": { 1290 | "type": "apikey", 1291 | "apikey": [ 1292 | { 1293 | "key": "value", 1294 | "value": "{{customer_token}}", 1295 | "type": "string" 1296 | }, 1297 | { 1298 | "key": "key", 1299 | "value": "token", 1300 | "type": "string" 1301 | }, 1302 | { 1303 | "key": "in", 1304 | "value": "header", 1305 | "type": "string" 1306 | } 1307 | ] 1308 | }, 1309 | "method": "POST", 1310 | "header": [ 1311 | { 1312 | "key": "token", 1313 | "value": "{{app-reg-token}}", 1314 | "type": "text" 1315 | } 1316 | ], 1317 | "url": { 1318 | "raw": "http://localhost:8013/v2/rideBooking/:bookingId", 1319 | "host": [ 1320 | "http://localhost:8013/v2" 1321 | ], 1322 | "path": [ 1323 | "rideBooking", 1324 | ":bookingId" 1325 | ], 1326 | "variable": [ 1327 | { 1328 | "key": "bookingId", 1329 | "value": "{{customer_bookingId}}" 1330 | } 1331 | ] 1332 | } 1333 | }, 1334 | "response": [] 1335 | } 1336 | ] 1337 | }, 1338 | { 1339 | "name": "StartRide", 1340 | "item": [ 1341 | { 1342 | "name": "/v2/rideBooking/list", 1343 | "event": [ 1344 | { 1345 | "listen": "prerequest", 1346 | "script": { 1347 | "exec": [ 1348 | "setTimeout(function(){}, 2000);" 1349 | ], 1350 | "type": "text/javascript" 1351 | } 1352 | }, 1353 | { 1354 | "listen": "test", 1355 | "script": { 1356 | "exec": [ 1357 | "const body = JSON.parse(responseBody);", 1358 | "const bookings = body.list.find ((booking) => booking.status=\"TRIP_ASSIGNED\")", 1359 | "postman.setEnvironmentVariable(\"ride_otp\", bookings.rideList[0].rideOtp);", 1360 | "postman.setEnvironmentVariable(\"customer_ride_id\", bookings.rideList[0].id);", 1361 | "var jsonData = JSON.parse(responseBody);", 1362 | "console.log(jsonData)" 1363 | ], 1364 | "type": "text/javascript" 1365 | } 1366 | } 1367 | ], 1368 | "request": { 1369 | "auth": { 1370 | "type": "apikey", 1371 | "apikey": [ 1372 | { 1373 | "key": "value", 1374 | "value": "{{customer_token}}", 1375 | "type": "string" 1376 | }, 1377 | { 1378 | "key": "key", 1379 | "value": "token", 1380 | "type": "string" 1381 | }, 1382 | { 1383 | "key": "in", 1384 | "value": "header", 1385 | "type": "string" 1386 | } 1387 | ] 1388 | }, 1389 | "method": "GET", 1390 | "header": [], 1391 | "url": { 1392 | "raw": "http://localhost:8013/v2/rideBooking/list?limit=20&onlyActive=true", 1393 | "host": [ 1394 | "http://localhost:8013/v2" 1395 | ], 1396 | "path": [ 1397 | "rideBooking", 1398 | "list" 1399 | ], 1400 | "query": [ 1401 | { 1402 | "key": "limit", 1403 | "value": "20" 1404 | }, 1405 | { 1406 | "key": "onlyActive", 1407 | "value": "true" 1408 | } 1409 | ] 1410 | } 1411 | }, 1412 | "response": [] 1413 | }, 1414 | { 1415 | "name": "/driver/ride/list", 1416 | "event": [ 1417 | { 1418 | "listen": "test", 1419 | "script": { 1420 | "exec": [ 1421 | "const body = JSON.parse(responseBody);", 1422 | "const rideList = body.list.find ((ride) => ride.status=\"NEW\")", 1423 | "postman.setEnvironmentVariable(\"driver_ride_id\", rideList.id);", 1424 | "var jsonData = JSON.parse(responseBody);", 1425 | "console.log(jsonData)" 1426 | ], 1427 | "type": "text/javascript" 1428 | } 1429 | } 1430 | ], 1431 | "request": { 1432 | "auth": { 1433 | "type": "apikey", 1434 | "apikey": [ 1435 | { 1436 | "key": "value", 1437 | "value": "{{driver_token}}", 1438 | "type": "string" 1439 | }, 1440 | { 1441 | "key": "key", 1442 | "value": "token", 1443 | "type": "string" 1444 | }, 1445 | { 1446 | "key": "in", 1447 | "value": "header", 1448 | "type": "string" 1449 | } 1450 | ] 1451 | }, 1452 | "method": "GET", 1453 | "header": [], 1454 | "url": { 1455 | "raw": "http://localhost:8016/ui/driver/ride/list?onlyActive=true&limit=10", 1456 | "host": [ 1457 | "http://localhost:8016/ui" 1458 | ], 1459 | "path": [ 1460 | "driver", 1461 | "ride", 1462 | "list" 1463 | ], 1464 | "query": [ 1465 | { 1466 | "key": "offset", 1467 | "value": "-87769918", 1468 | "disabled": true 1469 | }, 1470 | { 1471 | "key": "onlyActive", 1472 | "value": "true" 1473 | }, 1474 | { 1475 | "key": "limit", 1476 | "value": "10" 1477 | } 1478 | ] 1479 | } 1480 | }, 1481 | "response": [] 1482 | }, 1483 | { 1484 | "name": "/driver/ride/:rideId/start", 1485 | "event": [ 1486 | { 1487 | "listen": "prerequest", 1488 | "script": { 1489 | "exec": [ 1490 | "pm.variables.set(\"ride-start-lat\", \"12.959849\");", 1491 | "pm.variables.set(\"ride-start-lon\", \"77.611269\");" 1492 | ], 1493 | "type": "text/javascript" 1494 | } 1495 | }, 1496 | { 1497 | "listen": "test", 1498 | "script": { 1499 | "exec": [ 1500 | "var jsonData = JSON.parse(responseBody);", 1501 | "console.log(jsonData)" 1502 | ], 1503 | "type": "text/javascript" 1504 | } 1505 | } 1506 | ], 1507 | "request": { 1508 | "auth": { 1509 | "type": "apikey", 1510 | "apikey": [ 1511 | { 1512 | "key": "value", 1513 | "value": "{{driver_token}}", 1514 | "type": "string" 1515 | }, 1516 | { 1517 | "key": "key", 1518 | "value": "token", 1519 | "type": "string" 1520 | }, 1521 | { 1522 | "key": "in", 1523 | "value": "header", 1524 | "type": "string" 1525 | } 1526 | ] 1527 | }, 1528 | "method": "POST", 1529 | "header": [ 1530 | { 1531 | "key": "Content-Type", 1532 | "value": "application/json;charset=utf-8" 1533 | } 1534 | ], 1535 | "body": { 1536 | "mode": "raw", 1537 | "raw": "{\n \"rideOtp\": \"{{ride_otp}}\",\n \"point\": {\n \"lat\": {{ride-start-lat}},\n \"lon\": {{ride-start-lon}}\n }\n}", 1538 | "options": { 1539 | "raw": { 1540 | "language": "json" 1541 | } 1542 | } 1543 | }, 1544 | "url": { 1545 | "raw": "http://localhost:8016/ui/driver/ride/:rideId/start", 1546 | "host": [ 1547 | "http://localhost:8016/ui" 1548 | ], 1549 | "path": [ 1550 | "driver", 1551 | "ride", 1552 | ":rideId", 1553 | "start" 1554 | ], 1555 | "variable": [ 1556 | { 1557 | "key": "rideId", 1558 | "value": "{{driver_ride_id}}", 1559 | "description": "(Required) " 1560 | } 1561 | ] 1562 | } 1563 | }, 1564 | "response": [] 1565 | } 1566 | ] 1567 | } 1568 | ] 1569 | }, 1570 | { 1571 | "name": "EndRide", 1572 | "item": [ 1573 | { 1574 | "name": "/driver/ride/:rideId/end", 1575 | "event": [ 1576 | { 1577 | "listen": "prerequest", 1578 | "script": { 1579 | "exec": [ 1580 | "pm.variables.set(\"ride-end-lat\", \"12.94005\");", 1581 | "pm.variables.set(\"ride-end-lon\", \"77.62264\");", 1582 | "console.log('If you want to leave the ride open just exit now in 5 seconds')", 1583 | "setTimeout(function(){}, 5000);" 1584 | 1585 | ], 1586 | "type": "text/javascript" 1587 | } 1588 | }, 1589 | { 1590 | "listen": "test", 1591 | "script": { 1592 | "exec": [ 1593 | "var jsonData = JSON.parse(responseBody);", 1594 | "console.log(jsonData)" 1595 | ], 1596 | "type": "text/javascript" 1597 | } 1598 | } 1599 | ], 1600 | "protocolProfileBehavior": { 1601 | "disabledSystemHeaders": {} 1602 | }, 1603 | "request": { 1604 | "auth": { 1605 | "type": "apikey", 1606 | "apikey": [ 1607 | { 1608 | "key": "value", 1609 | "value": "{{driver_token}}", 1610 | "type": "string" 1611 | }, 1612 | { 1613 | "key": "key", 1614 | "value": "token", 1615 | "type": "string" 1616 | }, 1617 | { 1618 | "key": "in", 1619 | "value": "header", 1620 | "type": "string" 1621 | } 1622 | ] 1623 | }, 1624 | "method": "POST", 1625 | "header": [], 1626 | "body": { 1627 | "mode": "raw", 1628 | "raw": "{\n \"point\": {\n \"lat\": {{ride-end-lat}},\n \"lon\": {{ride-end-lon}}\n }\n}", 1629 | "options": { 1630 | "raw": { 1631 | "language": "json" 1632 | } 1633 | } 1634 | }, 1635 | "url": { 1636 | "raw": "http://localhost:8016/ui/driver/ride/:rideId/end", 1637 | "host": [ 1638 | "http://localhost:8016/ui" 1639 | ], 1640 | "path": [ 1641 | "driver", 1642 | "ride", 1643 | ":rideId", 1644 | "end" 1645 | ], 1646 | "variable": [ 1647 | { 1648 | "key": "rideId", 1649 | "value": "{{driver_ride_id}}" 1650 | } 1651 | ] 1652 | } 1653 | }, 1654 | "response": [] 1655 | } 1656 | ] 1657 | } 1658 | ] 1659 | } -------------------------------------------------------------------------------- /new_file.txt: -------------------------------------------------------------------------------- 1 | [ 2 | {'url_path': '/ui', 3 | 'request_type': 'get', 4 | 'request_body': []}, 5 | {'url_path': '/ui/auth', 6 | 'request_type': 7 | 'post', 8 | 'parameters': [{'name': 'x-bundle-version', 'required': False, 'in': 'header', 'schema': {'type': 'string', 'pattern': '^\\d+.\\d+.\\d+'}}, {'name': 'x-client-version', 'required': False, 'in': 'header', 'schema': {'type': 'string', 'pattern': '^\\d+.\\d+.\\d+'}}], 'request_body': [{'type': 'object', 'required': ['mobileNumber', 'mobileCountryCode', 'merchantId'], 'properties': {'merchantId': {'type': 'string'}, 'mobileCountryCode': {'type': 'string'}, 'mobileNumber': {'type': 'string'}}}]}, {'url_path': '/ui/auth/{authId}/verify', 'request_type': 'post', 'parameters': [{'name': 'authId', 'required': True, 'in': 'path', 'schema': {'type': 'string'}}], 'request_body': [{'type': 'object', 'required': ['otp', 'deviceToken'], 'properties': {'whatsappNotificationEnroll': {'type': 'string', 'enum': ['OPT_IN', 'OPT_OUT']}, 'deviceToken': {'type': 'string'}, 'otp': {'type': 'string'}}}]}, {'url_path': '/ui/auth/otp/{authId}/resend', 'request_type': 'post', 'parameters': [{'name': 'authId', 'required': True, 'in': 'path', 'schema': {'type': 'string'}}], 'request_body': []}, {'url_path': '/ui/auth/logout', 'request_type': 'post', 'request_body': []}, {'url_path': '/ui/driver/register/dl', 'request_type': 'post', 'request_body': [{'type': 'object', 'required': ['driverLicenseNumber', 'operatingCity', 'driverDateOfBirth', 'imageId1'], 'properties': {'imageId1': {'type': 'string'}, 'driverDateOfBirth': {'type': 'string', 'format': 'yyyy-mm-ddThh:MM:ssZ', 'example': '2016-07-22T00:00:00Z'}, 'imageId2': {'type': 'string'}, 'dateOfIssue': {'type': 'string', 'format': 'yyyy-mm-ddThh:MM:ssZ', 'example': '2016-07-22T00:00:00Z'}, 'operatingCity': {'type': 'string'}, 'driverLicenseNumber': {'type': 'string'}}}]}, {'url_path': '/ui/driver/register/rc', 'request_type': 'post', 'request_body': [{'type': 'object', 'required': ['vehicleRegistrationCertNumber', 'imageId', 'operatingCity'], 'properties': {'vehicleRegistrationCertNumber': {'type': 'string'}, 'dateOfRegistration': {'type': 'string', 'format': 'yyyy-mm-ddThh:MM:ssZ', 'example': '2016-07-22T00:00:00Z'}, 'operatingCity': {'type': 'string'}, 'imageId': {'type': 'string'}}}]}, {'url_path': '/ui/driver/register/status', 'request_type': 'get', 'request_body': []}, {'url_path': '/ui/driver/register/validateImage', 'request_type': 'post', 'request_body': [{'type': 'object', 'required': ['image', 'imageType'], 'properties': {'imageType': {'type': 'string', 'enum': ['DriverLicense', 'VehicleRegistrationCertificate']}, 'image': {'type': 'string'}}}]}, {'url_path': '/ui/driver/register/validateImageFile', 'request_type': 'post', 'request_body': []}, {'url_path': '/ui/driver/register/generateAadhaarOtp', 'request_type': 'post', 'request_body': [{'type': 'object', 'required': ['aadhaarNumber', 'consent'], 'properties': {'aadhaarNumber': {'type': 'string'}, 'consent': {'type': 'string'}}}]}, {'url_path': '/ui/driver/register/verifyAadhaarOtp', 'request_type': 'post', 'request_body': [{'type': 'object', 'required': ['otp', 'shareCode'], 'properties': {'otp': {'minimum': -9223372036854775808, 'type': 'integer', 'maximum': 9223372036854775807}, 'shareCode': {'type': 'string'}}}]}, {'url_path': '/ui/driver/referral', 'request_type': 'post', 'request_body': [{'type': 'object', 'required': ['value'], 'properties': {'value': {'type': 'string'}}}]}, {'url_path': '/ui/orgAdmin/profile', 'request_type': 'get', 'request_body': []}, {'url_path': '/ui/payment/{driverFeeId}/createOrder', 'request_type': 'post', 'parameters': [{'name': 'driverFeeId', 'required': True, 'in': 'path', 'schema': {'type': 'string'}}], 'request_body': []}, {'url_path': '/ui/payment/{orderId}/status', 'request_type': 'get', 'parameters': [{'name': 'orderId', 'required': True, 'in': 'path', 'schema': {'type': 'string'}}], 'request_body': []}, {'url_path': '/ui/payment', 'request_type': 'get', 'parameters': [{'name': 'orderId', 'required': True, 'in': 'query', 'schema': {'type': 'string'}}], 'request_body': []}, {'url_path': '/ui/org/driver', 'request_type': 'post', 'request_body': [{'type': 'object', 'required': ['person', 'vehicle'], 'properties': {'person': {'type': 'object', 'required': ['firstName', 'mobileNumber', 'mobileCountryCode'], 'properties': {'mobileCountryCode': {'type': 'string'}, 'firstName': {'type': 'string'}, 'lastName': {'type': 'string'}, 'middleName': {'type': 'string'}, 'mobileNumber': {'type': 'string'}}}, 'vehicle': {'type': 'object', 'required': ['category', 'model', 'variant', 'color', 'registrationNo', 'capacity'], 'properties': {'model': {'type': 'string'}, 'color': {'type': 'string'}, 'variant': {'type': 'string', 'enum': ['SEDAN', 'SUV', 'HATCHBACK', 'AUTO_RICKSHAW', 'TAXI', 'TAXI_PLUS']}, 'category': {'type': 'string', 'enum': ['CAR', 'MOTORCYCLE', 'TRAIN', 'BUS', 'FLIGHT', 'AUTO_CATEGORY']}, 'registrationNo': {'type': 'string'}, 'capacity': {'minimum': -9223372036854775808, 'type': 'integer', 'maximum': 9223372036854775807}}}}}]}, {'url_path': '/ui/org/driver/list', 'request_type': 'get', 'parameters': [{'name': 'searchString', 'required': False, 'in': 'query', 'schema': {'type': 'string'}}, {'name': 'limit', 'required': False, 'in': 'query', 'schema': {'type': 'integer'}}, {'name': 'DDriver', 'required': False, 'in': 'query', 'schema': {'type': 'integer'}}], 'request_body': []}, {'url_path': '/ui/org/driver/{driverId}', 'request_type': 'post', 'parameters': [{'name': 'driverId', 'required': True, 'in': 'path', 'schema': {'type': 'string'}}, {'name': 'enabled', 'required': True, 'in': 'query', 'schema': {'type': 'boolean'}}], 'request_body': []}, 9 | 10 | {'url_path': '/ui/driver/setActivity', 11 | 'request_type': 'post', 12 | 'parameters': 13 | [ 14 | {'name': 'active', 15 | 'required': True, 16 | 'in': 'query', 17 | 'schema': {'type': 'boolean'}}, 18 | {'name': 'mode', 19 | 'required': False, 20 | 'in': 'query', 21 | 'schema': 22 | {'type': 'string', 23 | 'enum': ['ONLINE', 'OFFLINE', 'SILENT'] 24 | } 25 | } 26 | ], 27 | 'request_body': []}, 28 | 29 | 30 | {'url_path': '/ui/driver/nearbyRideRequest', 'request_type': 'get', 'request_body': []}, {'url_path': '/ui/driver/searchRequest/quote/offer', 'request_type': 'post', 'request_body': [{'type': 'object', 'required': ['searchRequestId'], 'properties': {'searchRequestId': {'type': 'string'}, 'offeredFare': {'minimum': -9223372036854775808, 'type': 'integer', 'maximum': 9223372036854775807}}}]}, {'url_path': '/ui/driver/searchRequest/quote/respond', 'request_type': 'post', 'request_body': [{'type': 'object', 'required': ['response'], 'properties': {'searchTryId': {'type': 'string'}, 'response': {'type': 'string', 'enum': ['Accept', 'Reject', 'Pulled']}, 'searchRequestId': {'type': 'string'}, 'offeredFare': {'minimum': -9223372036854775808, 'type': 'integer', 'maximum': 9223372036854775807}}}]}, {'url_path': '/ui/driver/profile', 'request_type': 'get', 'request_body': []}, {'url_path': '/ui/driver/profile/stats', 'request_type': 'get', 'parameters': [{'name': 'day', 'required': True, 'in': 'query', 'schema': {'type': 'string', 'format': 'date'}}], 'request_body': []}, {'url_path': '/ui/driver/alternateNumber/validate', 'request_type': 'post', 'request_body': [{'type': 'object', 'required': ['mobileCountryCode', 'alternateNumber'], 'properties': {'mobileCountryCode': {'type': 'string'}, 'alternateNumber': {'type': 'string'}}}]}, {'url_path': '/ui/driver/alternateNumber/verify', 'request_type': 'post', 'request_body': [{'type': 'object', 'required': ['otp'], 'properties': {'otp': {'type': 'string'}}}]}, {'url_path': '/ui/driver/alternateNumber/resendOtp', 'request_type': 'post', 'request_body': [{'type': 'object', 'required': ['mobileCountryCode', 'alternateNumber'], 'properties': {'mobileCountryCode': {'type': 'string'}, 'alternateNumber': {'type': 'string'}}}]}, {'url_path': '/ui/driver/alternateNumber/remove', 'request_type': 'delete', 'request_body': []}, {'url_path': '/ui/driver/payments/history', 'request_type': 'get', 'parameters': [{'name': 'from', 'required': False, 'in': 'query', 'schema': {'type': 'string', 'format': 'date'}}, {'name': 'to', 'required': False, 'in': 'query', 'schema': {'type': 'string', 'format': 'date'}}, {'name': 'status', 'required': False, 'in': 'query', 'schema': {'type': 'string', 'enum': ['ONGOING', 'PAYMENT_PENDING', 'PAYMENT_OVERDUE', 'CLEARED', 'EXEMPTED', 'COLLECTED_CASH', 'INACTIVE']}}, {'name': 'limit', 'required': False, 'in': 'query', 'schema': {'minimum': -9223372036854775808, 'type': 'integer', 'maximum': 9223372036854775807}}, {'name': 'offset', 'required': False, 'in': 'query', 'schema': {'minimum': -9223372036854775808, 'type': 'integer', 'maximum': 9223372036854775807}}], 'request_body': []}, {'url_path': '/ui/org/vehicle/list', 'request_type': 'get', 'parameters': [{'name': 'variant', 'required': False, 'in': 'query', 'schema': {'type': 'string', 'enum': ['SEDAN', 'SUV', 'HATCHBACK', 'AUTO_RICKSHAW', 'TAXI', 'TAXI_PLUS']}}, {'name': 'registrationNo', 'required': False, 'in': 'query', 'schema': {'type': 'string'}}, {'name': 'limit', 'required': False, 'in': 'query', 'schema': {'minimum': -9223372036854775808, 'type': 'integer', 'maximum': 9223372036854775807}}, {'name': 'offset', 'required': False, 'in': 'query', 'schema': {'minimum': -9223372036854775808, 'type': 'integer', 'maximum': 9223372036854775807}}], 'request_body': []}, {'url_path': '/ui/org/vehicle/{driverId}', 'request_type': 'post', 'parameters': [{'name': 'driverId', 'required': True, 'in': 'path', 'schema': {'type': 'string'}}], 'request_body': [{'type': 'object', 'properties': {'model': {'type': 'string'}, 'color': {'type': 'string'}, 'size': {'type': 'string'}, 'variant': {'type': 'string', 'enum': ['SEDAN', 'SUV', 'HATCHBACK', 'AUTO_RICKSHAW', 'TAXI', 'TAXI_PLUS']}, 'energyType': {'type': 'string'}, 'registrationCategory': {'type': 'string', 'enum': ['COMMERCIAL', 'PERSONAL', 'OTHER', 'PUBLIC']}, 'make': {'type': 'string'}, 'category': {'type': 'string', 'enum': ['CAR', 'MOTORCYCLE', 'TRAIN', 'BUS', 'FLIGHT', 'AUTO_CATEGORY']}, 'registrationNo': {'type': 'string'}, 'capacity': {'minimum': -9223372036854775808, 'type': 'integer', 'maximum': 9223372036854775807}}}]}, {'url_path': '/ui/org/vehicle', 'request_type': 'get', 'parameters': [{'name': 'registrationNo', 'required': False, 'in': 'query', 'schema': {'type': 'string'}}, {'name': 'driverId', 'required': False, 'in': 'query', 'schema': {'type': 'string'}}], 'request_body': []}, {'url_path': '/ui/frontend/flowStatus', 'request_type': 'get', 'request_body': []}, {'url_path': '/ui/transporter', 'request_type': 'get', 'request_body': []}, {'url_path': '/ui/transporter/{merchantId}', 'request_type': 'post', 'parameters': [{'name': 'merchantId', 'required': True, 'in': 'path', 'schema': {'type': 'string'}}], 'request_body': [{'type': 'object', 'properties': {'name': {'type': 'string'}, 'description': {'type': 'string'}, 'enabled': {'type': 'boolean'}}}]}, {'url_path': '/ui/driver/location/{rideId}', 'request_type': 'get', 'parameters': [{'name': 'rideId', 'required': True, 'in': 'path', 'schema': {'type': 'string'}}], 'request_body': []}, {'url_path': '/ui/driver/location', 'request_type': 'post', 'request_body': [None]}, {'url_path': '/ui/route', 'request_type': 'post', 'request_body': [{'type': 'object', 'required': ['waypoints', 'calcPoints'], 'properties': {'mode': {'type': 'string', 'enum': ['CAR', 'MOTORCYCLE', 'BICYCLE', 'FOOT']}, 'waypoints': {'items': {'type': 'object', 'required': ['lat', 'lon'], 'properties': {'lat': {'type': 'number', 'format': 'double'}, 'lon': {'type': 'number', 'format': 'double'}}}, 'type': 'array', 'minItems': 1}, 'calcPoints': {'type': 'boolean'}}}]}, {'url_path': '/ui/pickup/route', 'request_type': 'post', 'request_body': [{'type': 'object', 'required': ['waypoints', 'calcPoints'], 'properties': {'mode': {'type': 'string', 'enum': ['CAR', 'MOTORCYCLE', 'BICYCLE', 'FOOT']}, 'waypoints': {'items': {'type': 'object', 'required': ['lat', 'lon'], 'properties': {'lat': {'type': 'number', 'format': 'double'}, 'lon': {'type': 'number', 'format': 'double'}}}, 'type': 'array', 'minItems': 1}, 'calcPoints': {'type': 'boolean'}}}]}, {'url_path': '/ui/trip/route', 'request_type': 'post', 'request_body': [{'type': 'object', 'required': ['waypoints', 'calcPoints'], 'properties': {'mode': {'type': 'string', 'enum': ['CAR', 'MOTORCYCLE', 'BICYCLE', 'FOOT']}, 'waypoints': {'items': {'type': 'object', 'required': ['lat', 'lon'], 'properties': {'lat': {'type': 'number', 'format': 'double'}, 'lon': {'type': 'number', 'format': 'double'}}}, 'type': 'array', 'minItems': 1}, 'calcPoints': {'type': 'boolean'}}}]}, {'url_path': '/ui/driver/otpRide/start', 'request_type': 'post', 'request_body': [{'type': 'object', 'required': ['specialZoneOtpCode', 'point'], 'properties': {'specialZoneOtpCode': {'type': 'string'}, 'point': {'type': 'object', 'required': ['lat', 'lon'], 'properties': {'lat': {'type': 'number', 'format': 'double'}, 'lon': {'type': 'number', 'format': 'double'}}}}}]}, {'url_path': '/ui/driver/ride/list', 'request_type': 'get', 'parameters': [{'name': 'limit', 'required': False, 'in': 'query', 'schema': {'type': 'integer'}}, {'name': 'offset', 'required': False, 'in': 'query', 'schema': {'type': 'integer'}}, {'name': 'onlyActive', 'required': False, 'in': 'query', 'schema': {'type': 'boolean'}}, {'name': 'status', 'required': False, 'in': 'query', 'schema': {'type': 'string', 'enum': ['NEW', 'INPROGRESS', 'COMPLETED', 'CANCELLED']}}, {'name': 'day', 'required': False, 'in': 'query', 'schema': {'type': 'string', 'format': 'date'}}], 'request_body': []}, {'url_path': '/ui/driver/ride/{rideId}/arrived/pickup', 'request_type': 'post', 'parameters': [{'name': 'rideId', 'required': True, 'in': 'path', 'schema': {'type': 'string'}}], 'request_body': [{'type': 'object', 'required': ['lat', 'lon'], 'properties': {'lat': {'type': 'number', 'format': 'double'}, 'lon': {'type': 'number', 'format': 'double'}}}]}, 31 | 32 | {'url_path': '/ui/driver/ride/{rideId}/start', 33 | 'request_type': 'post', 34 | 'parameters': [{'name': 'rideId', 'required': True, 'in': 'path', 'schema': {'type': 'string'}}], 35 | 'request_body': 36 | [{'type': 'object', 37 | 'properties': {'point': {'type': 'object', 38 | 'required': ['lat', 'lon'], 39 | 'properties': 40 | {'lat': {'type': 'number', 'format': 'double'}, 'lon': {'type': 'number', 'format': 'double'}}}}}]}, {'url_path': '/ui/driver/ride/{rideId}/end', 'request_type': 'post', 'parameters': [{'name': 'rideId', 'required': True, 'in': 'path', 'schema': {'type': 'string'}}], 'request_body': [{'type': 'object', 'properties': {'point': {'type': 'object', 'required': ['lat', 'lon'], 'properties': {'lat': {'type': 'number', 'format': 'double'}, 'lon': {'type': 'number', 'format': 'double'}}}}}]}, {'url_path': '/ui/driver/ride/{rideId}/cancel', 'request_type': 'post', 'parameters': [{'name': 'rideId', 'required': True, 'in': 'path', 'schema': {'type': 'string'}}], 'request_body': [{'type': 'object', 'required': ['reasonCode'], 'properties': {'additionalInfo': {'type': 'string'}, 'reasonCode': {'type': 'string'}}}]}, {'url_path': '/ui/driver/ride/{rideId}/call/customer', 'request_type': 'post', 'parameters': [{'name': 'rideId', 'required': True, 'in': 'path', 'schema': {'type': 'string'}}], 'request_body': []}, {'url_path': '/ui/driver/ride/{rideId}/call/{callId}/status', 'request_type': 'get', 'parameters': [{'name': 'rideId', 'required': True, 'in': 'path', 'schema': {'type': 'string'}}, {'name': 'callId', 'required': True, 'in': 'path', 'schema': {'type': 'string'}}], 'request_body': []}, {'url_path': '/ui/driver/ride/call/statusCallback', 'request_type': 'post', 'request_body': [{'type': 'object', 'required': ['callSid', 'eventType', 'dateCreated', 'dateUpdated', 'from', 'to', 'status', 'phoneNumberSid', 'startTime', 'endTime', 'direction', 'recordingUrl', 'conversationDuration', 'legs', 'customField'], 'properties': {'eventType': {'type': 'string'}, 'from': {'type': 'string'}, 'conversationDuration': {'minimum': -9223372036854775808, 'type': 'integer', 'maximum': 9223372036854775807}, 'to': {'type': 'string'}, 'callSid': {'type': 'string'}, 'recordingUrl': {'type': 'string'}, 'status': {'type': 'string', 'enum': ['QUEUED', 'RINGING', 'IN_PROGRESS', 'COMPLETED', 'FAILED', 'BUSY', 'NO_ANSWER', 'CANCELED', 'INVALID_STATUS']}, 'endTime': {'type': 'string'}, 'customField': {'type': 'object', 'required': ['callStatusId', 'rideId'], 'properties': {'rideId': {'type': 'string'}, 'callStatusId': {'type': 'string'}}}, 'legs': {'items': {'type': 'object', 'required': ['onCallDuration', 'status'], 'properties': {'status': {'type': 'string', 'enum': ['QUEUED', 'RINGING', 'IN_PROGRESS', 'COMPLETED', 'FAILED', 'BUSY', 'NO_ANSWER', 'CANCELED', 'INVALID_STATUS']}, 'onCallDuration': {'minimum': -9223372036854775808, 'type': 'integer', 'maximum': 9223372036854775807}}}, 'type': 'array'}, 'dateUpdated': {'type': 'string'}, 'dateCreated': {'type': 'string'}, 'startTime': {'type': 'string'}, 'direction': {'type': 'string', 'enum': ['INBOUND', 'OUTBOUND_DIAL', 'OUTBOUND_API']}, 'phoneNumberSid': {'type': 'string'}}}]}, {'url_path': '/ui/exotel/call/customer/number', 'request_type': 'get', 'parameters': [{'name': 'CallSid', 'required': True, 'in': 'query', 'schema': {'type': 'string'}}, {'name': 'CallFrom', 'required': True, 'in': 'query', 'schema': {'type': 'string'}}, {'name': 'CallTo', 'required': True, 'in': 'query', 'schema': {'type': 'string'}}, {'name': 'digits', 'required': False, 'in': 'query', 'schema': {'type': 'string'}}, {'name': 'CallStatus', 'required': True, 'in': 'query', 'schema': {'type': 'string', 'enum': ['QUEUED', 'RINGING', 'IN_PROGRESS', 'COMPLETED', 'FAILED', 'BUSY', 'NO_ANSWER', 'CANCELED', 'INVALID_STATUS']}}], 'request_body': []}, {'url_path': '/ui/exotel/call/statusCallback', 'request_type': 'get', 'parameters': [{'name': 'CallSid', 'required': True, 'in': 'query', 'schema': {'type': 'string'}}, {'name': 'DialCallStatus', 'required': True, 'in': 'query', 'schema': {'type': 'string', 'enum': ['QUEUED', 'RINGING', 'IN_PROGRESS', 'COMPLETED', 'FAILED', 'BUSY', 'NO_ANSWER', 'CANCELED', 'INVALID_STATUS']}}, {'name': 'RecordingUrl', 'required': False, 'in': 'query', 'schema': {'type': 'string'}}, {'name': 'Legs[0][OnCallDuration]', 'required': False, 'in': 'query', 'schema': {'minimum': -9223372036854775808, 'type': 'integer', 'maximum': 9223372036854775807}}], 'request_body': []}, {'url_path': '/ui/cancellationReason/list', 'request_type': 'get', 'request_body': []}, {'url_path': '/ui/whatsapp/opt', 'request_type': 'post', 'request_body': [{'type': 'object', 'required': ['status'], 'properties': {'status': {'type': 'string', 'enum': ['OPT_IN', 'OPT_OUT']}}}]}, {'url_path': '/ui/message/list', 'request_type': 'get', 'parameters': [{'name': 'limit', 'required': False, 'in': 'query', 'schema': {'minimum': -9223372036854775808, 'type': 'integer', 'maximum': 9223372036854775807}}, {'name': 'offset', 'required': False, 'in': 'query', 'schema': {'minimum': -9223372036854775808, 'type': 'integer', 'maximum': 9223372036854775807}}], 'request_body': []}, {'url_path': '/ui/message/{messageId}/seen', 'request_type': 'put', 'parameters': [{'name': 'messageId', 'required': True, 'in': 'path', 'schema': {'type': 'string'}}], 'request_body': []}, {'url_path': '/ui/message/{messageId}/like', 'request_type': 'put', 'parameters': [{'name': 'messageId', 'required': True, 'in': 'path', 'schema': {'type': 'string'}}], 'request_body': []}, {'url_path': '/ui/message/{messageId}/response', 'request_type': 'put', 'parameters': [{'name': 'messageId', 'required': True, 'in': 'path', 'schema': {'type': 'string'}}], 'request_body': [{'type': 'object', 'required': ['reply'], 'properties': {'reply': {'type': 'string'}}}]}, {'url_path': '/ui/message/media', 'request_type': 'get', 'parameters': [{'name': 'filePath', 'required': True, 'in': 'query', 'schema': {'type': 'string'}}], 'request_body': []}, {'url_path': '/ui/message/{messageId}', 'request_type': 'get', 'parameters': [{'name': 'messageId', 'required': True, 'in': 'path', 'schema': {'type': 'string'}}], 'request_body': []}, {'url_path': '/ui/driver/performance', 'request_type': 'get', 'request_body': []}, {'url_path': '/ui/driver/linkReferralCode', 'request_type': 'post', 'request_body': [{'type': 'object', 'required': ['referralCode', 'referralLinkPassword'], 'properties': {'referralLinkPassword': {'type': 'string'}, 'referralCode': {'type': 'string'}}}]}, {'url_path': '/ui/issue', 'request_type': 'post', 'request_body': [{'type': 'object', 'required': ['mediaFiles', 'categoryId', 'description'], 'properties': {'optionId': {'type': 'string'}, 'mediaFiles': {'items': {'type': 'string'}, 'type': 'array'}, 'rideId': {'type': 'string'}, 'description': {'type': 'string'}, 'categoryId': {'type': 'string'}}}]}, {'url_path': '/ui/issue/list', 'request_type': 'get', 'parameters': [{'name': 'language', 'required': False, 'in': 'query', 'schema': {'type': 'string', 'enum': ['ENGLISH', 'HINDI', 'KANNADA', 'TAMIL', 'MALAYALAM', 'BENGALI']}}], 'request_body': []}, {'url_path': '/ui/issue/upload', 'request_type': 'post', 'request_body': []}, {'url_path': '/ui/issue/media', 'request_type': 'get', 'parameters': [{'name': 'filePath', 'required': True, 'in': 'query', 'schema': {'type': 'string'}}], 'request_body': []}, {'url_path': '/ui/issue/category', 'request_type': 'get', 'parameters': [{'name': 'language', 'required': False, 'in': 'query', 'schema': {'type': 'string', 'enum': ['ENGLISH', 'HINDI', 'KANNADA', 'TAMIL', 'MALAYALAM', 'BENGALI']}}], 'request_body': []}, {'url_path': '/ui/issue/option', 'request_type': 'get', 'parameters': [{'name': 'categoryId', 'required': True, 'in': 'query', 'schema': {'type': 'string'}}, {'name': 'language', 'required': False, 'in': 'query', 'schema': {'type': 'string', 'enum': ['ENGLISH', 'HINDI', 'KANNADA', 'TAMIL', 'MALAYALAM', 'BENGALI']}}], 'request_body': []}, {'url_path': '/ui/issue/{issueId}/info', 'request_type': 'get', 'parameters': [{'name': 'issueId', 'required': True, 'in': 'path', 'schema': {'type': 'string'}}, {'name': 'language', 'required': False, 'in': 'query', 'schema': {'type': 'string', 'enum': ['ENGLISH', 'HINDI', 'KANNADA', 'TAMIL', 'MALAYALAM', 'BENGALI']}}], 'request_body': []}, {'url_path': '/ui/issue/{issueId}/option', 'request_type': 'put', 'parameters': [{'name': 'issueId', 'required': True, 'in': 'path', 'schema': {'type': 'string'}}], 'request_body': [{'type': 'object', 'required': ['categoryId', 'optionId'], 'properties': {'optionId': {'type': 'string'}, 'categoryId': {'type': 'string'}}}]}, {'url_path': '/ui/issue/{issueId}/delete', 'request_type': 'delete', 'parameters': [{'name': 'issueId', 'required': True, 'in': 'path', 'schema': {'type': 'string'}}], 'request_body': []}, {'url_path': '/ui/exotel/ride/end', 'request_type': 'get', 'parameters': [{'name': 'CallFrom', 'required': True, 'in': 'query', 'schema': {'type': 'string'}}, {'name': 'CallTo', 'required': True, 'in': 'query', 'schema': {'type': 'string'}}], 'request_body': []}, {'url_path': '/ui/driver/leaderBoard/daily', 'request_type': 'get', 'parameters': [{'name': 'date', 'required': True, 'in': 'query', 'schema': {'type': 'string', 'format': 'date'}}], 'request_body': []}, {'url_path': '/ui/driver/leaderBoard/weekly', 'request_type': 'get', 'parameters': [{'name': 'fromDate', 'required': True, 'in': 'query', 'schema': {'type': 'string', 'format': 'date'}}, {'name': 'toDate', 'required': True, 'in': 'query', 'schema': {'type': 'string', 'format': 'date'}}], 'request_body': []}, {'url_path': '/ui/onMessage', 'request_type': 'post', 'request_body': [{'type': 'object', 'required': ['rideId', 'message'], 'properties': {'message': {'type': 'string'}, 'rideId': {'type': 'string'}}}]}, {'url_path': '/beckn/{merchantId}/search', 'request_type': 'post', 'parameters': [{'name': 'merchantId', 'required': True, 'in': 'path', 'schema': {'type': 'string'}}], 'request_body': [{'type': 'object', 'required': ['context', 'message'], 'properties': {'message': {'type': 'object', 'required': ['intent'], 'properties': {'device': {'type': 'string'}, 'intent': {'type': 'object', 'required': ['fulfillment'], 'properties': {'fulfillment': {'type': 'object', 'required': ['start', 'tags'], 'properties': {'tags': {'type': 'object', 'properties': {'./komn/customer_language': {'type': 'string', 'enum': ['ENGLISH', 'HINDI', 'KANNADA', 'TAMIL', 'MALAYALAM', 'BENGALI']}}}, 'start': {'type': 'object', 'required': ['location', 'time'], 'properties': {'time': {'type': 'object', 'required': ['timestamp'], 'properties': {'timestamp': {'type': 'string', 'format': 'yyyy-mm-ddThh:MM:ssZ', 'example': '2016-07-22T00:00:00Z'}}}, 'location': {'type': 'object', 'required': ['gps'], 'properties': {'gps': {'type': 'string', 'format': '[-]?(?:0|[1-9][0-9]*)(?:\\.[0-9]+)?, [-]?(?:0|[1-9][0-9]*)(?:\\.[0-9]+)?', 'example': '123.321, 123.321', 'description': 'Gps value in a string representation with an optional leading "-" for negative numbers. Integer and fractional parts are separated with a dot.Lat and Long parts are separated with a comma. String format is used to prevent loss of precision.'}, 'address': {'type': 'object', 'properties': {'ward': {'type': 'string'}, 'country': {'type': 'string'}, 'building': {'type': 'string'}, 'state': {'type': 'string'}, 'city': {'type': 'string'}, 'locality': {'type': 'string'}, 'door': {'type': 'string'}, 'area_code': {'type': 'string'}, 'street': {'type': 'string'}}}}}}}, 'end': {'type': 'object', 'required': ['location'], 'properties': {'location': {'type': 'object', 'required': ['gps'], 'properties': {'gps': {'type': 'string', 'format': '[-]?(?:0|[1-9][0-9]*)(?:\\.[0-9]+)?, [-]?(?:0|[1-9][0-9]*)(?:\\.[0-9]+)?', 'example': '123.321, 123.321', 'description': 'Gps value in a string representation with an optional leading "-" for negative numbers. Integer and fractional parts are separated with a dot.Lat and Long parts are separated with a comma. String format is used to prevent loss of precision.'}, 'address': {'type': 'object', 'properties': {'ward': {'type': 'string'}, 'country': {'type': 'string'}, 'building': {'type': 'string'}, 'state': {'type': 'string'}, 'city': {'type': 'string'}, 'locality': {'type': 'string'}, 'door': {'type': 'string'}, 'area_code': {'type': 'string'}, 'street': {'type': 'string'}}}}}}}}}}}, 'routeInfo': {'type': 'object', 'properties': {'distance': {'minimum': -9223372036854775808, 'type': 'integer', 'maximum': 9223372036854775807}, 'duration': {'minimum': -9223372036854775808, 'type': 'integer', 'maximum': 9223372036854775807}}}}}, 'context': {'type': 'object', 'required': ['domain', 'country', 'city', 'action', 'core_version', 'bap_id', 'bap_uri', 'message_id', 'timestamp'], 'properties': {'country': {'type': 'string'}, 'bpp_uri': {'type': 'string'}, 'domain': {'type': 'string', 'enum': ['MOBILITY', 'LOCAL_RETAIL', 'FOOD_AND_BEVERAGE', 'HEALTHCARE', 'METRO', 'PARKING', 'PUBLIC_TRANSPORT', 'LOGISTICS']}, 'timestamp': {'type': 'string', 'description': 'UTCTimeRFC3339 is a representation of UTCTime in milliseconds instead of microseconds.'}, 'bap_id': {'type': 'string'}, 'transaction_id': {'type': 'string'}, 'bpp_id': {'type': 'string'}, 'message_id': {'type': 'string'}, 'city': {'type': 'string'}, 'core_version': {'type': 'string'}, 'action': {'type': 'string', 'enum': ['SEARCH', 'SELECT', 'INIT', 'CONFIRM', 'UPDATE', 'STATUS', 'TRACK', 'CANCEL', 'RATING', 'SUPPORT', 'ON_SEARCH', 'ON_SELECT', 'ON_INIT', 'ON_CONFIRM', 'ON_UPDATE', 'ON_STATUS', 'ON_TRACK', 'ON_CANCEL', 'ON_RATING', 'ON_SUPPORT']}, 'bap_uri': {'type': 'string'}}}}}]}, {'url_path': '/beckn/{merchantId}/select', 'request_type': 'post', 'parameters': [{'name': 'merchantId', 'required': True, 'in': 'path', 'schema': {'type': 'string'}}], 'request_body': [{'type': 'object', 'required': ['context', 'message'], 'properties': {'message': {'type': 'object', 'required': ['order'], 'properties': {'order': {'type': 'object', 'required': ['items', 'fulfillment', 'quote'], 'properties': {'items': {'items': {'type': 'object', 'required': ['id'], 'properties': {'id': {'type': 'string'}}}, 'type': 'array'}, 'fulfillment': {'type': 'object', 'required': ['start', 'tags'], 'properties': {'tags': {'type': 'object', 'required': ['./komn/auto_assign_enabled'], 'properties': {'./komn/auto_assign_enabled': {'type': 'boolean'}}}, 'start': {'type': 'object', 'required': ['time'], 'properties': {'time': {'type': 'object', 'required': ['timestamp'], 'properties': {'timestamp': {'type': 'string', 'format': 'yyyy-mm-ddThh:MM:ssZ', 'example': '2016-07-22T00:00:00Z'}}}}}}}, 'quote': {'type': 'object', 'required': ['breakup'], 'properties': {'breakup': {'items': {'type': 'object', 'required': ['title', 'price'], 'properties': {'price': {'type': 'object', 'required': ['currency', 'value'], 'properties': {'currency': {'type': 'string'}, 'value': {'type': 'string', 'format': '[-]?(?:0|[1-9][0-9]*)(?:\\.[0-9]+)?', 'description': 'Decimal value in a string representation with an optional leading "-" for negative numbers. Integer and fractional parts are separated with a dot.Maximum allowed precision (total number of digits) is 30 String format is used to prevent loss of precision.'}}}, 'title': {'type': 'string'}}}, 'type': 'array'}}}}}}}, 'context': {'type': 'object', 'required': ['domain', 'country', 'city', 'action', 'core_version', 'bap_id', 'bap_uri', 'message_id', 'timestamp'], 'properties': {'country': {'type': 'string'}, 'bpp_uri': {'type': 'string'}, 'domain': {'type': 'string', 'enum': ['MOBILITY', 'LOCAL_RETAIL', 'FOOD_AND_BEVERAGE', 'HEALTHCARE', 'METRO', 'PARKING', 'PUBLIC_TRANSPORT', 'LOGISTICS']}, 'timestamp': {'type': 'string', 'description': 'UTCTimeRFC3339 is a representation of UTCTime in milliseconds instead of microseconds.'}, 'bap_id': {'type': 'string'}, 'transaction_id': {'type': 'string'}, 'bpp_id': {'type': 'string'}, 'message_id': {'type': 'string'}, 'city': {'type': 'string'}, 'core_version': {'type': 'string'}, 'action': {'type': 'string', 'enum': ['SEARCH', 'SELECT', 'INIT', 'CONFIRM', 'UPDATE', 'STATUS', 'TRACK', 'CANCEL', 'RATING', 'SUPPORT', 'ON_SEARCH', 'ON_SELECT', 'ON_INIT', 'ON_CONFIRM', 'ON_UPDATE', 'ON_STATUS', 'ON_TRACK', 'ON_CANCEL', 'ON_RATING', 'ON_SUPPORT']}, 'bap_uri': {'type': 'string'}}}}}]}, {'url_path': '/beckn/{merchantId}/init', 'request_type': 'post', 'parameters': [{'name': 'merchantId', 'required': True, 'in': 'path', 'schema': {'type': 'string'}}], 'request_body': [{'type': 'object', 'required': ['context', 'message'], 'properties': {'message': {'type': 'object', 'required': ['order'], 'properties': {'order': {'type': 'object', 'required': ['items', 'fulfillment', 'payment'], 'properties': {'items': {'items': {'type': 'object', 'required': ['descriptor'], 'properties': {'id': {'type': 'string'}, 'descriptor': {'type': 'object', 'required': ['code'], 'properties': {'code': {'type': 'string'}}}}}, 'type': 'array'}, 'fulfillment': {'type': 'object', 'required': ['start', 'tags'], 'properties': {'tags': {'type': 'object', 'properties': {'./komn/max_estimated_distance': {'type': 'string', 'format': '[-]?(?:0|[1-9][0-9]*)(?:\\.[0-9]+)?', 'description': 'Monetary amount in a string representation with an optional leading "-" for negative numbers. Integer and fractional parts are separated with a dot.Maximum allowed precision (total number of digits) is 30 String format is used to prevent loss of precision.'}}}, 'start': {'type': 'object', 'required': ['location', 'time'], 'properties': {'time': {'type': 'object', 'required': ['timestamp'], 'properties': {'timestamp': {'type': 'string', 'format': 'yyyy-mm-ddThh:MM:ssZ', 'example': '2016-07-22T00:00:00Z'}}}, 'location': {'type': 'object', 'required': ['gps'], 'properties': {'gps': {'type': 'string', 'format': '[-]?(?:0|[1-9][0-9]*)(?:\\.[0-9]+)?, [-]?(?:0|[1-9][0-9]*)(?:\\.[0-9]+)?', 'example': '123.321, 123.321', 'description': 'Gps value in a string representation with an optional leading "-" for negative numbers. Integer and fractional parts are separated with a dot.Lat and Long parts are separated with a comma. String format is used to prevent loss of precision.'}, 'address': {'type': 'object', 'properties': {'ward': {'type': 'string'}, 'country': {'type': 'string'}, 'building': {'type': 'string'}, 'state': {'type': 'string'}, 'city': {'type': 'string'}, 'locality': {'type': 'string'}, 'door': {'type': 'string'}, 'area_code': {'type': 'string'}, 'street': {'type': 'string'}}}}}}}, 'end': {'type': 'object', 'required': ['location'], 'properties': {'location': {'type': 'object', 'required': ['gps'], 'properties': {'gps': {'type': 'string', 'format': '[-]?(?:0|[1-9][0-9]*)(?:\\.[0-9]+)?, [-]?(?:0|[1-9][0-9]*)(?:\\.[0-9]+)?', 'example': '123.321, 123.321', 'description': 'Gps value in a string representation with an optional leading "-" for negative numbers. Integer and fractional parts are separated with a dot.Lat and Long parts are separated with a comma. String format is used to prevent loss of precision.'}, 'address': {'type': 'object', 'properties': {'ward': {'type': 'string'}, 'country': {'type': 'string'}, 'building': {'type': 'string'}, 'state': {'type': 'string'}, 'city': {'type': 'string'}, 'locality': {'type': 'string'}, 'door': {'type': 'string'}, 'area_code': {'type': 'string'}, 'street': {'type': 'string'}}}}}}}}}, 'payment': {'type': 'object', 'required': ['collected_by', '_type', 'time'], 'properties': {'time': {'type': 'object', 'required': ['duration'], 'properties': {'duration': {'type': 'string'}}}, 'collected_by': {'type': 'string', 'enum': ['BAP', 'BPP']}, '_type': {'type': 'string', 'enum': ['ON-ORDER', 'ON-FULFILLMENT']}, 'instrument': {'type': 'object', 'oneOf': [{'type': 'object', 'required': ['instrumentType', 'instrumentName'], 'properties': {'instrumentType': {'type': 'string', 'enum': ['Card']}, 'instrumentName': {'type': 'string', 'enum': ['DefaultCardType']}}}, {'type': 'object', 'required': ['instrumentType', 'instrumentName'], 'properties': {'instrumentType': {'type': 'string', 'enum': ['Wallet']}, 'instrumentName': {'type': 'string', 'enum': ['DefaultWalletType']}}}, {'type': 'object', 'required': ['instrumentType'], 'properties': {'instrumentType': {'type': 'string', 'enum': ['UPI']}}}, {'type': 'object', 'required': ['instrumentType'], 'properties': {'instrumentType': {'type': 'string', 'enum': ['NetBanking']}}}, {'type': 'object', 'required': ['instrumentType'], 'properties': {'instrumentType': {'type': 'string', 'enum': ['Cash']}}}]}}}}}}}, 'context': {'type': 'object', 'required': ['domain', 'country', 'city', 'action', 'core_version', 'bap_id', 'bap_uri', 'message_id', 'timestamp'], 'properties': {'country': {'type': 'string'}, 'bpp_uri': {'type': 'string'}, 'domain': {'type': 'string', 'enum': ['MOBILITY', 'LOCAL_RETAIL', 'FOOD_AND_BEVERAGE', 'HEALTHCARE', 'METRO', 'PARKING', 'PUBLIC_TRANSPORT', 'LOGISTICS']}, 'timestamp': {'type': 'string', 'description': 'UTCTimeRFC3339 is a representation of UTCTime in milliseconds instead of microseconds.'}, 'bap_id': {'type': 'string'}, 'transaction_id': {'type': 'string'}, 'bpp_id': {'type': 'string'}, 'message_id': {'type': 'string'}, 'city': {'type': 'string'}, 'core_version': {'type': 'string'}, 'action': {'type': 'string', 'enum': ['SEARCH', 'SELECT', 'INIT', 'CONFIRM', 'UPDATE', 'STATUS', 'TRACK', 'CANCEL', 'RATING', 'SUPPORT', 'ON_SEARCH', 'ON_SELECT', 'ON_INIT', 'ON_CONFIRM', 'ON_UPDATE', 'ON_STATUS', 'ON_TRACK', 'ON_CANCEL', 'ON_RATING', 'ON_SUPPORT']}, 'bap_uri': {'type': 'string'}}}}}]}, {'url_path': '/beckn/{merchantId}/confirm', 'request_type': 'post', 'parameters': [{'name': 'merchantId', 'required': True, 'in': 'path', 'schema': {'type': 'string'}}], 'request_body': [{'type': 'object', 'required': ['context', 'message'], 'properties': {'message': {'type': 'object', 'required': ['order'], 'properties': {'order': {'type': 'object', 'required': ['id', 'fulfillment', 'customer', 'payment'], 'properties': {'fulfillment': {'type': 'object', 'required': ['start'], 'properties': {'start': {'type': 'object', 'required': ['location'], 'properties': {'location': {'type': 'object', 'required': ['address'], 'properties': {'address': {'type': 'object', 'properties': {'ward': {'type': 'string'}, 'country': {'type': 'string'}, 'building': {'type': 'string'}, 'state': {'type': 'string'}, 'city': {'type': 'string'}, 'locality': {'type': 'string'}, 'door': {'type': 'string'}, 'area_code': {'type': 'string'}, 'street': {'type': 'string'}}}}}}}, 'end': {'type': 'object', 'required': ['location'], 'properties': {'location': {'type': 'object', 'required': ['address'], 'properties': {'address': {'type': 'object', 'properties': {'ward': {'type': 'string'}, 'country': {'type': 'string'}, 'building': {'type': 'string'}, 'state': {'type': 'string'}, 'city': {'type': 'string'}, 'locality': {'type': 'string'}, 'door': {'type': 'string'}, 'area_code': {'type': 'string'}, 'street': {'type': 'string'}}}}}}}}}, 'customer': {'type': 'object', 'required': ['contact'], 'properties': {'contact': {'type': 'object', 'required': ['phone'], 'properties': {'phone': {'type': 'object', 'required': ['country_code', 'number'], 'properties': {'number': {'type': 'string'}, 'country_code': {'type': 'string'}}}}}, 'person': {'type': 'object', 'required': ['name'], 'properties': {'name': {'type': 'string'}}}}}, 'id': {'type': 'string'}, 'payment': {'type': 'object', 'required': ['collected_by', 'params', 'type', 'time'], 'properties': {'type': {'type': 'string', 'enum': ['ON-ORDER', 'ON-FULFILLMENT']}, 'time': {'type': 'object', 'required': ['duration'], 'properties': {'duration': {'type': 'string'}}}, 'collected_by': {'type': 'string'}, 'params': {'type': 'object', 'required': ['currency', 'amount'], 'properties': {'currency': {'type': 'string'}, 'amount': {'type': 'string', 'format': '[-]?(?:0|[1-9][0-9]*)(?:\\.[0-9]+)?', 'description': 'Decimal value in a string representation with an optional leading "-" for negative numbers. Integer and fractional parts are separated with a dot.Maximum allowed precision (total number of digits) is 30 String format is used to prevent loss of precision.'}}}}}}}}}, 'context': {'type': 'object', 'required': ['domain', 'country', 'city', 'action', 'core_version', 'bap_id', 'bap_uri', 'message_id', 'timestamp'], 'properties': {'country': {'type': 'string'}, 'bpp_uri': {'type': 'string'}, 'domain': {'type': 'string', 'enum': ['MOBILITY', 'LOCAL_RETAIL', 'FOOD_AND_BEVERAGE', 'HEALTHCARE', 'METRO', 'PARKING', 'PUBLIC_TRANSPORT', 'LOGISTICS']}, 'timestamp': {'type': 'string', 'description': 'UTCTimeRFC3339 is a representation of UTCTime in milliseconds instead of microseconds.'}, 'bap_id': {'type': 'string'}, 'transaction_id': {'type': 'string'}, 'bpp_id': {'type': 'string'}, 'message_id': {'type': 'string'}, 'city': {'type': 'string'}, 'core_version': {'type': 'string'}, 'action': {'type': 'string', 'enum': ['SEARCH', 'SELECT', 'INIT', 'CONFIRM', 'UPDATE', 'STATUS', 'TRACK', 'CANCEL', 'RATING', 'SUPPORT', 'ON_SEARCH', 'ON_SELECT', 'ON_INIT', 'ON_CONFIRM', 'ON_UPDATE', 'ON_STATUS', 'ON_TRACK', 'ON_CANCEL', 'ON_RATING', 'ON_SUPPORT']}, 'bap_uri': {'type': 'string'}}}}}]}, {'url_path': '/beckn/{merchantId}/track', 'request_type': 'post', 'parameters': [{'name': 'merchantId', 'required': True, 'in': 'path', 'schema': {'type': 'string'}}], 'request_body': [{'type': 'object', 'required': ['context', 'message'], 'properties': {'message': {'type': 'object', 'required': ['order'], 'properties': {'order': {'type': 'object', 'required': ['id'], 'properties': {'id': {'type': 'string'}}}}}, 'context': {'type': 'object', 'required': ['domain', 'country', 'city', 'action', 'core_version', 'bap_id', 'bap_uri', 'message_id', 'timestamp'], 'properties': {'country': {'type': 'string'}, 'bpp_uri': {'type': 'string'}, 'domain': {'type': 'string', 'enum': ['MOBILITY', 'LOCAL_RETAIL', 'FOOD_AND_BEVERAGE', 'HEALTHCARE', 'METRO', 'PARKING', 'PUBLIC_TRANSPORT', 'LOGISTICS']}, 'timestamp': {'type': 'string', 'description': 'UTCTimeRFC3339 is a representation of UTCTime in milliseconds instead of microseconds.'}, 'bap_id': {'type': 'string'}, 'transaction_id': {'type': 'string'}, 'bpp_id': {'type': 'string'}, 'message_id': {'type': 'string'}, 'city': {'type': 'string'}, 'core_version': {'type': 'string'}, 'action': {'type': 'string', 'enum': ['SEARCH', 'SELECT', 'INIT', 'CONFIRM', 'UPDATE', 'STATUS', 'TRACK', 'CANCEL', 'RATING', 'SUPPORT', 'ON_SEARCH', 'ON_SELECT', 'ON_INIT', 'ON_CONFIRM', 'ON_UPDATE', 'ON_STATUS', 'ON_TRACK', 'ON_CANCEL', 'ON_RATING', 'ON_SUPPORT']}, 'bap_uri': {'type': 'string'}}}}}]}, {'url_path': '/beckn/{merchantId}/cancel', 'request_type': 'post', 'parameters': [{'name': 'merchantId', 'required': True, 'in': 'path', 'schema': {'type': 'string'}}], 'request_body': [{'type': 'object', 'required': ['context', 'message'], 'properties': {'message': {'type': 'object', 'required': ['order_id', 'item_id', 'cancellation_reason_id'], 'properties': {'order_id': {'type': 'string'}, 'item_id': {'type': 'string'}, 'cancellation_reason_id': {'type': 'string', 'enum': ['ByUser', 'ByDriver', 'ByMerchant', 'ByAllocator', 'ByApplication']}}}, 'context': {'type': 'object', 'required': ['domain', 'country', 'city', 'action', 'core_version', 'bap_id', 'bap_uri', 'message_id', 'timestamp'], 'properties': {'country': {'type': 'string'}, 'bpp_uri': {'type': 'string'}, 'domain': {'type': 'string', 'enum': ['MOBILITY', 'LOCAL_RETAIL', 'FOOD_AND_BEVERAGE', 'HEALTHCARE', 'METRO', 'PARKING', 'PUBLIC_TRANSPORT', 'LOGISTICS']}, 'timestamp': {'type': 'string', 'description': 'UTCTimeRFC3339 is a representation of UTCTime in milliseconds instead of microseconds.'}, 'bap_id': {'type': 'string'}, 'transaction_id': {'type': 'string'}, 'bpp_id': {'type': 'string'}, 'message_id': {'type': 'string'}, 'city': {'type': 'string'}, 'core_version': {'type': 'string'}, 'action': {'type': 'string', 'enum': ['SEARCH', 'SELECT', 'INIT', 'CONFIRM', 'UPDATE', 'STATUS', 'TRACK', 'CANCEL', 'RATING', 'SUPPORT', 'ON_SEARCH', 'ON_SELECT', 'ON_INIT', 'ON_CONFIRM', 'ON_UPDATE', 'ON_STATUS', 'ON_TRACK', 'ON_CANCEL', 'ON_RATING', 'ON_SUPPORT']}, 'bap_uri': {'type': 'string'}}}}}]}, {'url_path': '/beckn/{merchantId}/rating', 'request_type': 'post', 'parameters': [{'name': 'merchantId', 'required': True, 'in': 'path', 'schema': {'type': 'string'}}], 'request_body': [{'type': 'object', 'required': ['context', 'message'], 'properties': {'message': {'type': 'object', 'required': ['id', 'value', 'feedback_form'], 'properties': {'id': {'type': 'string'}, 'feedback_form': {'type': 'object', 'required': ['question'], 'properties': {'question': {'type': 'string'}, 'answer': {'type': 'string'}}}, 'value': {'minimum': -9223372036854775808, 'type': 'integer', 'maximum': 9223372036854775807}}}, 'context': {'type': 'object', 'required': ['domain', 'country', 'city', 'action', 'core_version', 'bap_id', 'bap_uri', 'message_id', 'timestamp'], 'properties': {'country': {'type': 'string'}, 'bpp_uri': {'type': 'string'}, 'domain': {'type': 'string', 'enum': ['MOBILITY', 'LOCAL_RETAIL', 'FOOD_AND_BEVERAGE', 'HEALTHCARE', 'METRO', 'PARKING', 'PUBLIC_TRANSPORT', 'LOGISTICS']}, 'timestamp': {'type': 'string', 'description': 'UTCTimeRFC3339 is a representation of UTCTime in milliseconds instead of microseconds.'}, 'bap_id': {'type': 'string'}, 'transaction_id': {'type': 'string'}, 'bpp_id': {'type': 'string'}, 'message_id': {'type': 'string'}, 'city': {'type': 'string'}, 'core_version': {'type': 'string'}, 'action': {'type': 'string', 'enum': ['SEARCH', 'SELECT', 'INIT', 'CONFIRM', 'UPDATE', 'STATUS', 'TRACK', 'CANCEL', 'RATING', 'SUPPORT', 'ON_SEARCH', 'ON_SELECT', 'ON_INIT', 'ON_CONFIRM', 'ON_UPDATE', 'ON_STATUS', 'ON_TRACK', 'ON_CANCEL', 'ON_RATING', 'ON_SUPPORT']}, 'bap_uri': {'type': 'string'}}}}}]}, {'url_path': '/beckn/{merchantId}/update', 'request_type': 'post', 'parameters': [{'name': 'merchantId', 'required': True, 'in': 'path', 'schema': {'type': 'string'}}], 'request_body': [{'type': 'object', 'required': ['context', 'message'], 'properties': {'message': {'type': 'object', 'required': ['order'], 'properties': {'order': {'type': 'object', 'required': ['id', './komn/update_target', 'fulfillment', 'payment'], 'properties': {'fulfillment': {'type': 'object', 'required': ['id', 'state'], 'properties': {'state': {'type': 'object', 'required': ['code'], 'properties': {'code': {'type': 'string', 'enum': ['PAYMENT_COMPLETED']}}}, 'id': {'type': 'string'}}}, 'id': {'type': 'string'}, 'payment': {'type': 'object', 'required': ['collected_by', 'type', 'instrument', 'status'], 'properties': {'type': {'type': 'string', 'enum': ['ON-ORDER', 'ON-FULFILLMENT']}, 'status': {'type': 'string', 'enum': ['PAID', 'NOT-PAID']}, 'collected_by': {'type': 'string', 'enum': ['BAP', 'BPP']}, 'instrument': {'type': 'object', 'oneOf': [{'type': 'object', 'required': ['instrumentType', 'instrumentName'], 'properties': {'instrumentType': {'type': 'string', 'enum': ['Card']}, 'instrumentName': {'type': 'string', 'enum': ['DefaultCardType']}}}, {'type': 'object', 'required': ['instrumentType', 'instrumentName'], 'properties': {'instrumentType': {'type': 'string', 'enum': ['Wallet']}, 'instrumentName': {'type': 'string', 'enum': ['DefaultWalletType']}}}, {'type': 'object', 'required': ['instrumentType'], 'properties': {'instrumentType': {'type': 'string', 'enum': ['UPI']}}}, {'type': 'object', 'required': ['instrumentType'], 'properties': {'instrumentType': {'type': 'string', 'enum': ['NetBanking']}}}, {'type': 'object', 'required': ['instrumentType'], 'properties': {'instrumentType': {'type': 'string', 'enum': ['Cash']}}}]}}}, './komn/update_target': {'type': 'string'}}}}}, 'context': {'type': 'object', 'required': ['domain', 'country', 'city', 'action', 'core_version', 'bap_id', 'bap_uri', 'message_id', 'timestamp'], 'properties': {'country': {'type': 'string'}, 'bpp_uri': {'type': 'string'}, 'domain': {'type': 'string', 'enum': ['MOBILITY', 'LOCAL_RETAIL', 'FOOD_AND_BEVERAGE', 'HEALTHCARE', 'METRO', 'PARKING', 'PUBLIC_TRANSPORT', 'LOGISTICS']}, 'timestamp': {'type': 'string', 'description': 'UTCTimeRFC3339 is a representation of UTCTime in milliseconds instead of microseconds.'}, 'bap_id': {'type': 'string'}, 'transaction_id': {'type': 'string'}, 'bpp_id': {'type': 'string'}, 'message_id': {'type': 'string'}, 'city': {'type': 'string'}, 'core_version': {'type': 'string'}, 'action': {'type': 'string', 'enum': ['SEARCH', 'SELECT', 'INIT', 'CONFIRM', 'UPDATE', 'STATUS', 'TRACK', 'CANCEL', 'RATING', 'SUPPORT', 'ON_SEARCH', 'ON_SELECT', 'ON_INIT', 'ON_CONFIRM', 'ON_UPDATE', 'ON_STATUS', 'ON_TRACK', 'ON_CANCEL', 'ON_RATING', 'ON_SUPPORT']}, 'bap_uri': {'type': 'string'}}}}}]}, {'url_path': '/beckn/{merchantId}/status', 'request_type': 'post', 'parameters': [{'name': 'merchantId', 'required': True, 'in': 'path', 'schema': {'type': 'string'}}], 'request_body': [{'type': 'object', 'required': ['context', 'message'], 'properties': {'message': {'type': 'object', 'required': ['order_id'], 'properties': {'order_id': {'type': 'string'}}}, 'context': {'type': 'object', 'required': ['domain', 'country', 'city', 'action', 'core_version', 'bap_id', 'bap_uri', 'message_id', 'timestamp'], 'properties': {'country': {'type': 'string'}, 'bpp_uri': {'type': 'string'}, 'domain': {'type': 'string', 'enum': ['MOBILITY', 'LOCAL_RETAIL', 'FOOD_AND_BEVERAGE', 'HEALTHCARE', 'METRO', 'PARKING', 'PUBLIC_TRANSPORT', 'LOGISTICS']}, 'timestamp': {'type': 'string', 'description': 'UTCTimeRFC3339 is a representation of UTCTime in milliseconds instead of microseconds.'}, 'bap_id': {'type': 'string'}, 'transaction_id': {'type': 'string'}, 'bpp_id': {'type': 'string'}, 'message_id': {'type': 'string'}, 'city': {'type': 'string'}, 'core_version': {'type': 'string'}, 'action': {'type': 'string', 'enum': ['SEARCH', 'SELECT', 'INIT', 'CONFIRM', 'UPDATE', 'STATUS', 'TRACK', 'CANCEL', 'RATING', 'SUPPORT', 'ON_SEARCH', 'ON_SELECT', 'ON_INIT', 'ON_CONFIRM', 'ON_UPDATE', 'ON_STATUS', 'ON_TRACK', 'ON_CANCEL', 'ON_RATING', 'ON_SUPPORT']}, 'bap_uri': {'type': 'string'}}}}}]}, {'url_path': '/service/idfy/verification', 'request_type': 'post', 'parameters': [{'name': 'Authorization', 'required': False, 'in': 'header', 'schema': {'type': 'string'}}], 'request_body': [{'type': 'string', 'description': 'Some JSON.'}]}, {'url_path': '/{merchantId}/service/idfy/verification', 'request_type': 'post', 'parameters': [{'name': 'merchantId', 'required': True, 'in': 'path', 'schema': {'type': 'string'}}, {'name': 'Authorization', 'required': False, 'in': 'header', 'schema': {'type': 'string'}}], 'request_body': [{'type': 'string', 'description': 'Some JSON.'}]}, {'url_path': '/{merchantId}/service/juspay/payment', 'request_type': 'post', 'parameters': [{'name': 'merchantId', 'required': True, 'in': 'path', 'schema': {'type': 'string'}}], 'request_body': [{'type': 'string', 'description': 'Some JSON.'}]}, {'url_path': '/dashboard/{merchantId}/driver/documents/info', 'request_type': 'get', 'parameters': [{'name': 'merchantId', 'required': True, 'in': 'path', 'schema': {'type': 'string'}}], 'request_body': []}, {'url_path': '/dashboard/{merchantId}/driver/{driverId}/aadhaarInfo', 'request_type': 'get', 'parameters': [{'name': 'merchantId', 'required': True, 'in': 'path', 'schema': {'type': 'string'}}, {'name': 'driverId', 'required': True, 'in': 'path', 'schema': {'type': 'string'}}], 'request_body': []}, {'url_path': '/dashboard/{merchantId}/driver/list', 'request_type': 'get', 'parameters': [{'name': 'merchantId', 'required': True, 'in': 'path', 'schema': {'type': 'string'}}, {'name': 'limit', 'required': False, 'in': 'query', 'schema': {'minimum': -9223372036854775808, 'type': 'integer', 'maximum': 9223372036854775807}}, {'name': 'offset', 'required': False, 'in': 'query', 'schema': {'minimum': -9223372036854775808, 'type': 'integer', 'maximum': 9223372036854775807}}, {'name': 'verified', 'required': False, 'in': 'query', 'schema': {'type': 'boolean'}}, {'name': 'enabled', 'required': False, 'in': 'query', 'schema': {'type': 'boolean'}}, {'name': 'blocked', 'required': False, 'in': 'query', 'schema': {'type': 'boolean'}}, {'name': 'subscribed', 'required': False, 'in': 'query', 'schema': {'type': 'boolean'}}, {'name': 'phone', 'required': False, 'in': 'query', 'schema': {'type': 'string'}}, {'name': 'vehicleNumberSearchString', 'required': False, 'in': 'query', 'schema': {'type': 'string'}}], 'request_body': []}, {'url_path': '/dashboard/{merchantId}/driver/paymentDue', 'request_type': 'get', 'parameters': [{'name': 'merchantId', 'required': True, 'in': 'path', 'schema': {'type': 'string'}}, {'name': 'countryCode', 'required': False, 'in': 'query', 'schema': {'type': 'string'}}, {'name': 'phone', 'required': True, 'in': 'query', 'schema': {'type': 'string'}}], 'request_body': []}, {'url_path': '/dashboard/{merchantId}/driver/activity', 'request_type': 'get', 'parameters': [{'name': 'merchantId', 'required': True, 'in': 'path', 'schema': {'type': 'string'}}], 'request_body': []}, {'url_path': '/dashboard/{merchantId}/driver/{driverId}/enable', 'request_type': 'post', 'parameters': [{'name': 'merchantId', 'required': True, 'in': 'path', 'schema': {'type': 'string'}}, {'name': 'driverId', 'required': True, 'in': 'path', 'schema': {'type': 'string'}}], 'request_body': []}, {'url_path': '/dashboard/{merchantId}/driver/{driverId}/disable', 'request_type': 'post', 'parameters': [{'name': 'merchantId', 'required': True, 'in': 'path', 'schema': {'type': 'string'}}, {'name': 'driverId', 'required': True, 'in': 'path', 'schema': {'type': 'string'}}], 'request_body': []}, {'url_path': '/dashboard/{merchantId}/driver/{driverId}/block', 'request_type': 'post', 'parameters': [{'name': 'merchantId', 'required': True, 'in': 'path', 'schema': {'type': 'string'}}, {'name': 'driverId', 'required': True, 'in': 'path', 'schema': {'type': 'string'}}], 'request_body': []}, {'url_path': '/dashboard/{merchantId}/driver/{driverId}/collectCash', 'request_type': 'post', 'parameters': [{'name': 'merchantId', 'required': True, 'in': 'path', 'schema': {'type': 'string'}}, {'name': 'driverId', 'required': True, 'in': 'path', 'schema': {'type': 'string'}}], 'request_body': []}, {'url_path': '/dashboard/{merchantId}/driver/{driverId}/unblock', 'request_type': 'post', 'parameters': [{'name': 'merchantId', 'required': True, 'in': 'path', 'schema': {'type': 'string'}}, {'name': 'driverId', 'required': True, 'in': 'path', 'schema': {'type': 'string'}}], 'request_body': []}, {'url_path': '/dashboard/{merchantId}/driver/location', 'request_type': 'get', 'parameters': [{'name': 'merchantId', 'required': True, 'in': 'path', 'schema': {'type': 'string'}}, {'name': 'limit', 'required': False, 'in': 'query', 'schema': {'minimum': -9223372036854775808, 'type': 'integer', 'maximum': 9223372036854775807}}, {'name': 'offset', 'required': False, 'in': 'query', 'schema': {'minimum': -9223372036854775808, 'type': 'integer', 'maximum': 9223372036854775807}}], 'request_body': [{'type': 'object', 'required': ['driverIds'], 'properties': {'driverIds': {'items': {'type': 'string'}, 'type': 'array'}}}]}, {'url_path': '/dashboard/{merchantId}/driver/info', 'request_type': 'get', 'parameters': [{'name': 'merchantId', 'required': True, 'in': 'path', 'schema': {'type': 'string'}}, {'name': 'mobileNumber', 'required': False, 'in': 'query', 'schema': {'type': 'string'}}, {'name': 'mobileCountryCode', 'required': False, 'in': 'query', 'schema': {'type': 'string'}}, {'name': 'vehicleNumber', 'required': False, 'in': 'query', 'schema': {'type': 'string'}}, {'name': 'dlNumber', 'required': False, 'in': 'query', 'schema': {'type': 'string'}}, {'name': 'rcNumber', 'required': False, 'in': 'query', 'schema': {'type': 'string'}}], 'request_body': []}, {'url_path': '/dashboard/{merchantId}/driver/{driverId}/permanentlyDelete', 'request_type': 'delete', 'parameters': [{'name': 'merchantId', 'required': True, 'in': 'path', 'schema': {'type': 'string'}}, {'name': 'driverId', 'required': True, 'in': 'path', 'schema': {'type': 'string'}}], 'request_body': []}, {'url_path': '/dashboard/{merchantId}/driver/{driverId}/unlinkVehicle', 'request_type': 'post', 'parameters': [{'name': 'merchantId', 'required': True, 'in': 'path', 'schema': {'type': 'string'}}, {'name': 'driverId', 'required': True, 'in': 'path', 'schema': {'type': 'string'}}], 'request_body': []}, {'url_path': '/dashboard/{merchantId}/driver/{driverId}/unlinkDL', 'request_type': 'post', 'parameters': [{'name': 'merchantId', 'required': True, 'in': 'path', 'schema': {'type': 'string'}}, {'name': 'driverId', 'required': True, 'in': 'path', 'schema': {'type': 'string'}}], 'request_body': []}, {'url_path': '/dashboard/{merchantId}/driver/{driverId}/endRCAssociation', 'request_type': 'post', 'parameters': [{'name': 'merchantId', 'required': True, 'in': 'path', 'schema': {'type': 'string'}}, {'name': 'driverId', 'required': True, 'in': 'path', 'schema': {'type': 'string'}}], 'request_body': []}, {'url_path': '/dashboard/{merchantId}/driver/{driverId}/updatePhoneNumber', 'request_type': 'post', 'parameters': [{'name': 'merchantId', 'required': True, 'in': 'path', 'schema': {'type': 'string'}}, {'name': 'driverId', 'required': True, 'in': 'path', 'schema': {'type': 'string'}}], 'request_body': [{'type': 'object', 'required': ['newPhoneNumber', 'newCountryCode'], 'properties': {'newCountryCode': {'type': 'string'}, 'newPhoneNumber': {'type': 'string'}}}]}, {'url_path': '/dashboard/{merchantId}/driver/{driverId}/addVehicle', 'request_type': 'post', 'parameters': [{'name': 'merchantId', 'required': True, 'in': 'path', 'schema': {'type': 'string'}}, {'name': 'driverId', 'required': True, 'in': 'path', 'schema': {'type': 'string'}}], 'request_body': [{'type': 'object', 'required': ['variant', 'registrationNo', 'vehicleClass', 'colour', 'model', 'driverName'], 'properties': {'colour': {'type': 'string'}, 'driverName': {'type': 'string'}, 'model': {'type': 'string'}, 'variant': {'type': 'string', 'enum': ['SEDAN', 'SUV', 'HATCHBACK', 'AUTO_RICKSHAW', 'TAXI', 'TAXI_PLUS']}, 'vehicleClass': {'type': 'string'}, 'energyType': {'type': 'string'}, 'make': {'type': 'string'}, 'registrationNo': {'type': 'string'}, 'capacity': {'minimum': -9223372036854775808, 'type': 'integer', 'maximum': 9223372036854775807}}}]}, {'url_path': '/dashboard/{merchantId}/driver/{driverId}/updateName', 'request_type': 'post', 'parameters': [{'name': 'merchantId', 'required': True, 'in': 'path', 'schema': {'type': 'string'}}, {'name': 'driverId', 'required': True, 'in': 'path', 'schema': {'type': 'string'}}], 'request_body': [{'type': 'object', 'required': ['firstName'], 'properties': {'firstName': {'type': 'string'}, 'lastName': {'type': 'string'}, 'middleName': {'type': 'string'}}}]}, {'url_path': '/dashboard/{merchantId}/driver/{driverId}/documents/list', 'request_type': 'get', 'parameters': [{'name': 'merchantId', 'required': True, 'in': 'path', 'schema': {'type': 'string'}}, {'name': 'driverId', 'required': True, 'in': 'path', 'schema': {'type': 'string'}}], 'request_body': []}, {'url_path': '/dashboard/{merchantId}/driver/getDocument/{imageId}', 'request_type': 'get', 'parameters': [{'name': 'merchantId', 'required': True, 'in': 'path', 'schema': {'type': 'string'}}, {'name': 'imageId', 'required': True, 'in': 'path', 'schema': {'type': 'string'}}], 'request_body': []}, {'url_path': '/dashboard/{merchantId}/driver/{driverId}/document/upload', 'request_type': 'post', 'parameters': [{'name': 'merchantId', 'required': True, 'in': 'path', 'schema': {'type': 'string'}}, {'name': 'driverId', 'required': True, 'in': 'path', 'schema': {'type': 'string'}}], 'request_body': [{'type': 'object', 'required': ['imageBase64', 'imageType'], 'properties': {'imageType': {'type': 'string', 'enum': ['RC', 'DL', 'RCInsurance']}, 'imageBase64': {'type': 'string'}}}]}, {'url_path': '/dashboard/{merchantId}/driver/{driverId}/register/dl', 'request_type': 'post', 'parameters': [{'name': 'merchantId', 'required': True, 'in': 'path', 'schema': {'type': 'string'}}, {'name': 'driverId', 'required': True, 'in': 'path', 'schema': {'type': 'string'}}], 'request_body': [{'type': 'object', 'required': ['driverLicenseNumber', 'operatingCity', 'driverDateOfBirth', 'imageId1'], 'properties': {'imageId1': {'type': 'string'}, 'driverDateOfBirth': {'type': 'string', 'format': 'yyyy-mm-ddThh:MM:ssZ', 'example': '2016-07-22T00:00:00Z'}, 'imageId2': {'type': 'string'}, 'dateOfIssue': {'type': 'string', 'format': 'yyyy-mm-ddThh:MM:ssZ', 'example': '2016-07-22T00:00:00Z'}, 'operatingCity': {'type': 'string'}, 'driverLicenseNumber': {'type': 'string'}}}]}, {'url_path': '/dashboard/{merchantId}/driver/{driverId}/register/rc', 'request_type': 'post', 'parameters': [{'name': 'merchantId', 'required': True, 'in': 'path', 'schema': {'type': 'string'}}, {'name': 'driverId', 'required': True, 'in': 'path', 'schema': {'type': 'string'}}], 'request_body': [{'type': 'object', 'required': ['vehicleRegistrationCertNumber', 'imageId', 'operatingCity'], 'properties': {'vehicleRegistrationCertNumber': {'type': 'string'}, 'dateOfRegistration': {'type': 'string', 'format': 'yyyy-mm-ddThh:MM:ssZ', 'example': '2016-07-22T00:00:00Z'}, 'operatingCity': {'type': 'string'}, 'imageId': {'type': 'string'}}}]}, {'url_path': '/dashboard/{merchantId}/driver/{driverId}/register/generateAadhaarOtp', 'request_type': 'post', 'parameters': [{'name': 'merchantId', 'required': True, 'in': 'path', 'schema': {'type': 'string'}}, {'name': 'driverId', 'required': True, 'in': 'path', 'schema': {'type': 'string'}}], 'request_body': [{'type': 'object', 'required': ['aadhaarNumber', 'consent'], 'properties': {'aadhaarNumber': {'type': 'string'}, 'consent': {'type': 'string'}}}]}, {'url_path': '/dashboard/{merchantId}/driver/{driverId}/register/verifyAadhaarOtp', 'request_type': 'post', 'parameters': [{'name': 'merchantId', 'required': True, 'in': 'path', 'schema': {'type': 'string'}}, {'name': 'driverId', 'required': True, 'in': 'path', 'schema': {'type': 'string'}}], 'request_body': [{'type': 'object', 'required': ['otp', 'shareCode'], 'properties': {'otp': {'minimum': -9223372036854775808, 'type': 'integer', 'maximum': 9223372036854775807}, 'shareCode': {'type': 'string'}}}]}, {'url_path': '/dashboard/{merchantId}/driver/clearStuck/onRide', 'request_type': 'get', 'parameters': [{'name': 'merchantId', 'required': True, 'in': 'path', 'schema': {'type': 'string'}}], 'request_body': []}, {'url_path': '/dashboard/{merchantId}/ride/list', 'request_type': 'get', 'parameters': [{'name': 'merchantId', 'required': True, 'in': 'path', 'schema': {'type': 'string'}}, {'name': 'limit', 'required': False, 'in': 'query', 'schema': {'minimum': -9223372036854775808, 'type': 'integer', 'maximum': 9223372036854775807}}, {'name': 'offset', 'required': False, 'in': 'query', 'schema': {'minimum': -9223372036854775808, 'type': 'integer', 'maximum': 9223372036854775807}}, {'name': 'bookingStatus', 'required': False, 'in': 'query', 'schema': {'type': 'string', 'enum': ['UPCOMING', 'UPCOMING_6HRS', 'ONGOING', 'ONGOING_6HRS', 'COMPLETED', 'CANCELLED']}}, {'name': 'rideShortId', 'required': False, 'in': 'query', 'schema': {'type': 'string'}}, {'name': 'customerPhoneNo', 'required': False, 'in': 'query', 'schema': {'type': 'string'}}, {'name': 'driverPhoneNo', 'required': False, 'in': 'query', 'schema': {'type': 'string'}}, {'name': 'fareDiff', 'required': False, 'in': 'query', 'schema': {'minimum': -9223372036854775808, 'type': 'integer', 'maximum': 9223372036854775807}}, {'name': 'from', 'required': False, 'in': 'query', 'schema': {'type': 'string', 'format': 'yyyy-mm-ddThh:MM:ssZ'}}, {'name': 'to', 'required': False, 'in': 'query', 'schema': {'type': 'string', 'format': 'yyyy-mm-ddThh:MM:ssZ'}}], 'request_body': []}, {'url_path': '/dashboard/{merchantId}/ride/{rideId}/start', 'request_type': 'post', 'parameters': [{'name': 'merchantId', 'required': True, 'in': 'path', 'schema': {'type': 'string'}}, {'name': 'rideId', 'required': True, 'in': 'path', 'schema': {'type': 'string'}}], 'request_body': [{'type': 'object', 'properties': {'point': {'type': 'object', 'required': ['lat', 'lon'], 'properties': {'lat': {'type': 'number', 'format': 'double'}, 'lon': {'type': 'number', 'format': 'double'}}}}}]}, {'url_path': '/dashboard/{merchantId}/ride/{rideId}/end', 'request_type': 'post', 'parameters': [{'name': 'merchantId', 'required': True, 'in': 'path', 'schema': {'type': 'string'}}, {'name': 'rideId', 'required': True, 'in': 'path', 'schema': {'type': 'string'}}], 'request_body': [{'type': 'object', 'properties': {'point': {'type': 'object', 'required': ['lat', 'lon'], 'properties': {'lat': {'type': 'number', 'format': 'double'}, 'lon': {'type': 'number', 'format': 'double'}}}}}]}, {'url_path': '/dashboard/{merchantId}/ride/end', 'request_type': 'post', 'parameters': [{'name': 'merchantId', 'required': True, 'in': 'path', 'schema': {'type': 'string'}}], 'request_body': [{'type': 'object', 'required': ['rides'], 'properties': {'rides': {'items': {'type': 'object', 'required': ['rideId'], 'properties': {'rideId': {'type': 'string'}, 'point': {'type': 'object', 'required': ['lat', 'lon'], 'properties': {'lat': {'type': 'number', 'format': 'double'}, 'lon': {'type': 'number', 'format': 'double'}}}}}, 'type': 'array'}}}]}, {'url_path': '/dashboard/{merchantId}/ride/{rideId}/cancel', 'request_type': 'post', 'parameters': [{'name': 'merchantId', 'required': True, 'in': 'path', 'schema': {'type': 'string'}}, {'name': 'rideId', 'required': True, 'in': 'path', 'schema': {'type': 'string'}}], 'request_body': [{'type': 'object', 'required': ['reasonCode'], 'properties': {'additionalInfo': {'type': 'string'}, 'reasonCode': {'type': 'string'}}}]}, {'url_path': '/dashboard/{merchantId}/ride/cancel', 'request_type': 'post', 'parameters': [{'name': 'merchantId', 'required': True, 'in': 'path', 'schema': {'type': 'string'}}], 'request_body': [{'type': 'object', 'required': ['multiRideCancelReason'], 'properties': {'multiRideCancelReason': {'items': {'type': 'object', 'required': ['rideId', 'reasonCode'], 'properties': {'additionalInfo': {'type': 'string'}, 'rideId': {'type': 'string'}, 'reasonCode': {'type': 'string'}}}, 'type': 'array'}}}]}, {'url_path': '/dashboard/{merchantId}/ride/{rideId}/info', 'request_type': 'get', 'parameters': [{'name': 'merchantId', 'required': True, 'in': 'path', 'schema': {'type': 'string'}}, {'name': 'rideId', 'required': True, 'in': 'path', 'schema': {'type': 'string'}}], 'request_body': []}, {'url_path': '/dashboard/{merchantId}/ride/{rideId}/sync', 'request_type': 'post', 'parameters': [{'name': 'merchantId', 'required': True, 'in': 'path', 'schema': {'type': 'string'}}, {'name': 'rideId', 'required': True, 'in': 'path', 'schema': {'type': 'string'}}], 'request_body': []}, {'url_path': '/dashboard/{merchantId}/ride/sync', 'request_type': 'post', 'parameters': [{'name': 'merchantId', 'required': True, 'in': 'path', 'schema': {'type': 'string'}}], 'request_body': [{'type': 'object', 'required': ['rideIds'], 'properties': {'rideIds': {'items': {'type': 'string'}, 'type': 'array'}}}]}, {'url_path': '/dashboard/{merchantId}/ride/{rideId}/route', 'request_type': 'post', 'parameters': [{'name': 'merchantId', 'required': True, 'in': 'path', 'schema': {'type': 'string'}}, {'name': 'rideId', 'required': True, 'in': 'path', 'schema': {'type': 'string'}}], 'request_body': []}, {'url_path': '/dashboard/{merchantId}/booking/cancel/allStuck', 'request_type': 'post', 'parameters': [{'name': 'merchantId', 'required': True, 'in': 'path', 'schema': {'type': 'string'}}], 'request_body': [{'type': 'object', 'required': ['bookingIds'], 'properties': {'bookingIds': {'items': {'type': 'string'}, 'type': 'array'}}}]}, {'url_path': '/dashboard/{merchantId}/merchant/update', 'request_type': 'post', 'parameters': [{'name': 'merchantId', 'required': True, 'in': 'path', 'schema': {'type': 'string'}}], 'request_body': [{'type': 'object', 'properties': {'name': {'type': 'string'}, 'fcmConfig': {'type': 'object', 'required': ['fcmUrl', 'fcmServiceAccount'], 'properties': {'fcmServiceAccount': {'type': 'string'}, 'fcmUrl': {'type': 'string'}}}, 'description': {'type': 'string'}, 'enabled': {'type': 'boolean'}, 'exoPhones': {'items': {'type': 'object', 'required': ['primaryPhone', 'backupPhone'], 'properties': {'backupPhone': {'type': 'string'}, 'primaryPhone': {'type': 'string'}}}, 'type': 'array', 'minItems': 1}}}]}, {'url_path': '/dashboard/{merchantId}/merchant/config/common', 'request_type': 'get', 'parameters': [{'name': 'merchantId', 'required': True, 'in': 'path', 'schema': {'type': 'string'}}], 'request_body': []}, {'url_path': '/dashboard/{merchantId}/merchant/config/common/update', 'request_type': 'post', 'parameters': [{'name': 'merchantId', 'required': True, 'in': 'path', 'schema': {'type': 'string'}}], 'request_body': [{'type': 'object', 'properties': {'onboardingTryLimit': {'type': 'object', 'required': ['value'], 'properties': {'value': {'minimum': -9223372036854775808, 'type': 'integer', 'maximum': 9223372036854775807}}}, 'popupDelayToAddAsPenalty': {'type': 'object', 'properties': {'value': {'minimum': -9223372036854775808, 'type': 'integer', 'maximum': 9223372036854775807}}}, 'pickupLocThreshold': {'type': 'object', 'required': ['value'], 'properties': {'value': {'minimum': -9223372036854775808, 'type': 'integer', 'maximum': 9223372036854775807}}}, 'thresholdCancellationScore': {'type': 'object', 'properties': {'value': {'minimum': -9223372036854775808, 'type': 'integer', 'maximum': 9223372036854775807}}}, 'driverPaymentCycleDuration': {'type': 'object', 'required': ['value'], 'properties': {'value': {'type': 'number', 'multipleOf': 1e-12}}}, 'mediaFileSizeUpperLimit': {'type': 'object', 'required': ['value'], 'properties': {'value': {'minimum': -9223372036854775808, 'type': 'integer', 'maximum': 9223372036854775807}}}, 'driverPaymentReminderInterval': {'type': 'object', 'required': ['value'], 'properties': {'value': {'type': 'number', 'multipleOf': 1e-12}}}, 'dropLocThreshold': {'type': 'object', 'required': ['value'], 'properties': {'value': {'minimum': -9223372036854775808, 'type': 'integer', 'maximum': 9223372036854775807}}}, 'searchRepeatLimit': {'type': 'object', 'required': ['value'], 'properties': {'value': {'minimum': -9223372036854775808, 'type': 'integer', 'maximum': 9223372036854775807}}}, 'defaultPopupDelay': {'type': 'object', 'required': ['value'], 'properties': {'value': {'minimum': -9223372036854775808, 'type': 'integer', 'maximum': 9223372036854775807}}}, 'checkImageExtractionForDashboard': {'type': 'object', 'required': ['value'], 'properties': {'value': {'type': 'boolean'}}}, 'driverPaymentCycleBuffer': {'type': 'object', 'required': ['value'], 'properties': {'value': {'type': 'number', 'multipleOf': 1e-12}}}, 'onboardingRetryTimeInHours': {'type': 'object', 'required': ['value'], 'properties': {'value': {'minimum': -9223372036854775808, 'type': 'integer', 'maximum': 9223372036854775807}}}, 'mediaFileUrlPattern': {'type': 'object', 'required': ['value'], 'properties': {'value': {'type': 'string'}}}, 'minRidesForCancellationScore': {'type': 'object', 'properties': {'value': {'minimum': -9223372036854775808, 'type': 'integer', 'maximum': 9223372036854775807}}}, 'timeDiffFromUtc': {'type': 'object', 'required': ['value'], 'properties': {'value': {'minimum': -9223372036854775808, 'type': 'integer', 'maximum': 9223372036854775807}}}, 'driverPaymentCycleStartTime': {'type': 'object', 'required': ['value'], 'properties': {'value': {'type': 'number', 'multipleOf': 1e-12}}}, 'rideTimeEstimatedThreshold': {'type': 'object', 'required': ['value'], 'properties': {'value': {'minimum': -9223372036854775808, 'type': 'integer', 'maximum': 9223372036854775807}}}}}]}, {'url_path': '/dashboard/{merchantId}/merchant/config/driverPool', 'request_type': 'get', 'parameters': [{'name': 'merchantId', 'required': True, 'in': 'path', 'schema': {'type': 'string'}}, {'name': 'tripDistance', 'required': False, 'in': 'query', 'schema': {'minimum': -9223372036854775808, 'type': 'integer', 'maximum': 9223372036854775807}}], 'request_body': []}, {'url_path': '/dashboard/{merchantId}/merchant/config/driverPool/update', 'request_type': 'post', 'parameters': [{'name': 'merchantId', 'required': True, 'in': 'path', 'schema': {'type': 'string'}}, {'name': 'tripDistance', 'required': True, 'in': 'query', 'schema': {'minimum': -9223372036854775808, 'type': 'integer', 'maximum': 9223372036854775807}}], 'request_body': [{'type': 'object', 'properties': {'driverPositionInfoExpiry': {'type': 'object', 'properties': {'value': {'minimum': -9223372036854775808, 'type': 'integer', 'maximum': 9223372036854775807}}}, 'driverQuoteLimit': {'type': 'object', 'required': ['value'], 'properties': {'value': {'minimum': -9223372036854775808, 'type': 'integer', 'maximum': 9223372036854775807}}}, 'distanceBasedBatchSplit': {'type': 'object', 'required': ['value'], 'properties': {'value': {'items': {'type': 'object', 'required': ['batchSplitSize', 'batchSplitDelay'], 'properties': {'batchSplitSize': {'minimum': -9223372036854775808, 'type': 'integer', 'maximum': 9223372036854775807}, 'batchSplitDelay': {'minimum': -9223372036854775808, 'type': 'integer', 'maximum': 9223372036854775807}}}, 'type': 'array'}}}, 'driverRequestCountLimit': {'type': 'object', 'required': ['value'], 'properties': {'value': {'minimum': -9223372036854775808, 'type': 'integer', 'maximum': 9223372036854775807}}}, 'driverBatchSize': {'type': 'object', 'required': ['value'], 'properties': {'value': {'minimum': -9223372036854775808, 'type': 'integer', 'maximum': 9223372036854775807}}}, 'maxDriverQuotesRequired': {'type': 'object', 'required': ['value'], 'properties': {'value': {'minimum': -9223372036854775808, 'type': 'integer', 'maximum': 9223372036854775807}}}, 'singleBatchProcessTime': {'type': 'object', 'required': ['value'], 'properties': {'value': {'minimum': -9223372036854775808, 'type': 'integer', 'maximum': 9223372036854775807}}}, 'maxRadiusOfSearch': {'type': 'object', 'required': ['value'], 'properties': {'value': {'minimum': -9223372036854775808, 'type': 'integer', 'maximum': 9223372036854775807}}}, 'maxNumberOfBatches': {'type': 'object', 'required': ['value'], 'properties': {'value': {'minimum': -9223372036854775808, 'type': 'integer', 'maximum': 9223372036854775807}}}, 'poolSortingType': {'type': 'object', 'required': ['value'], 'properties': {'value': {'type': 'string', 'enum': ['Intelligent', 'Random']}}}, 'maxParallelSearchRequests': {'type': 'object', 'required': ['value'], 'properties': {'value': {'minimum': -9223372036854775808, 'type': 'integer', 'maximum': 9223372036854775807}}}, 'radiusStepSize': {'type': 'object', 'required': ['value'], 'properties': {'value': {'minimum': -9223372036854775808, 'type': 'integer', 'maximum': 9223372036854775807}}}, 'minRadiusOfSearch': {'type': 'object', 'required': ['value'], 'properties': {'value': {'minimum': -9223372036854775808, 'type': 'integer', 'maximum': 9223372036854775807}}}, 'actualDistanceThreshold': {'type': 'object', 'properties': {'value': {'minimum': -9223372036854775808, 'type': 'integer', 'maximum': 9223372036854775807}}}}}]}, {'url_path': '/dashboard/{merchantId}/merchant/config/driverPool/create', 'request_type': 'post', 'parameters': [{'name': 'merchantId', 'required': True, 'in': 'path', 'schema': {'type': 'string'}}, {'name': 'tripDistance', 'required': True, 'in': 'query', 'schema': {'minimum': -9223372036854775808, 'type': 'integer', 'maximum': 9223372036854775807}}], 'request_body': [{'type': 'object', 'required': ['minRadiusOfSearch', 'maxRadiusOfSearch', 'radiusStepSize', 'maxDriverQuotesRequired', 'driverQuoteLimit', 'driverRequestCountLimit', 'driverBatchSize', 'maxNumberOfBatches', 'maxParallelSearchRequests', 'poolSortingType', 'distanceBasedBatchSplit', 'singleBatchProcessTime', 'radiusShrinkValueForDriversOnRide', 'driverToDestinationDistanceThreshold', 'driverToDestinationDuration'], 'properties': {'driverPositionInfoExpiry': {'minimum': -9223372036854775808, 'type': 'integer', 'maximum': 9223372036854775807}, 'radiusShrinkValueForDriversOnRide': {'minimum': -9223372036854775808, 'type': 'integer', 'maximum': 9223372036854775807}, 'driverQuoteLimit': {'minimum': -9223372036854775808, 'type': 'integer', 'maximum': 9223372036854775807}, 'distanceBasedBatchSplit': {'items': {'type': 'object', 'required': ['batchSplitSize', 'batchSplitDelay'], 'properties': {'batchSplitSize': {'minimum': -9223372036854775808, 'type': 'integer', 'maximum': 9223372036854775807}, 'batchSplitDelay': {'minimum': -9223372036854775808, 'type': 'integer', 'maximum': 9223372036854775807}}}, 'type': 'array'}, 'driverRequestCountLimit': {'minimum': -9223372036854775808, 'type': 'integer', 'maximum': 9223372036854775807}, 'driverBatchSize': {'minimum': -9223372036854775808, 'type': 'integer', 'maximum': 9223372036854775807}, 'maxDriverQuotesRequired': {'minimum': -9223372036854775808, 'type': 'integer', 'maximum': 9223372036854775807}, 'singleBatchProcessTime': {'minimum': -9223372036854775808, 'type': 'integer', 'maximum': 9223372036854775807}, 'driverToDestinationDuration': {'minimum': -9223372036854775808, 'type': 'integer', 'maximum': 9223372036854775807}, 'maxRadiusOfSearch': {'minimum': -9223372036854775808, 'type': 'integer', 'maximum': 9223372036854775807}, 'driverToDestinationDistanceThreshold': {'minimum': -9223372036854775808, 'type': 'integer', 'maximum': 9223372036854775807}, 'maxNumberOfBatches': {'minimum': -9223372036854775808, 'type': 'integer', 'maximum': 9223372036854775807}, 'poolSortingType': {'type': 'string', 'enum': ['Intelligent', 'Random']}, 'maxParallelSearchRequests': {'minimum': -9223372036854775808, 'type': 'integer', 'maximum': 9223372036854775807}, 'radiusStepSize': {'minimum': -9223372036854775808, 'type': 'integer', 'maximum': 9223372036854775807}, 'minRadiusOfSearch': {'minimum': -9223372036854775808, 'type': 'integer', 'maximum': 9223372036854775807}, 'actualDistanceThreshold': {'minimum': -9223372036854775808, 'type': 'integer', 'maximum': 9223372036854775807}}}]}, {'url_path': '/dashboard/{merchantId}/merchant/config/driverIntelligentPool', 'request_type': 'get', 'parameters': [{'name': 'merchantId', 'required': True, 'in': 'path', 'schema': {'type': 'string'}}], 'request_body': []}, {'url_path': '/dashboard/{merchantId}/merchant/config/driverIntelligentPool/update', 'request_type': 'post', 'parameters': [{'name': 'merchantId', 'required': True, 'in': 'path', 'schema': {'type': 'string'}}], 'request_body': [{'type': 'object', 'properties': {'cancellationRatioWindowOption': {'type': 'object', 'required': ['period', 'periodType'], 'properties': {'period': {'type': 'integer'}, 'periodType': {'type': 'string', 'enum': ['Minutes', 'Hours', 'Days', 'Months', 'Years']}}}, 'cancellationRatioWeightage': {'type': 'object', 'required': ['value'], 'properties': {'value': {'minimum': -9223372036854775808, 'type': 'integer', 'maximum': 9223372036854775807}}}, 'availabilityTimeWeightage': {'type': 'object', 'required': ['value'], 'properties': {'value': {'minimum': -9223372036854775808, 'type': 'integer', 'maximum': 9223372036854775807}}}, 'speedNormalizer': {'type': 'object', 'required': ['value'], 'properties': {'value': {'type': 'number', 'format': 'double'}}}, 'driverSpeedWeightage': {'type': 'object', 'required': ['value'], 'properties': {'value': {'minimum': -9223372036854775808, 'type': 'integer', 'maximum': 9223372036854775807}}}, 'acceptanceRatioWeightage': {'type': 'object', 'required': ['value'], 'properties': {'value': {'minimum': -9223372036854775808, 'type': 'integer', 'maximum': 9223372036854775807}}}, 'availabilityTimeWindowOption': {'type': 'object', 'required': ['period', 'periodType'], 'properties': {'period': {'type': 'integer'}, 'periodType': {'type': 'string', 'enum': ['Minutes', 'Hours', 'Days', 'Months', 'Years']}}}, 'locationUpdateSampleTime': {'type': 'object', 'required': ['value'], 'properties': {'value': {'minimum': -9223372036854775808, 'type': 'integer', 'maximum': 9223372036854775807}}}, 'defaultDriverSpeed': {'type': 'object', 'required': ['value'], 'properties': {'value': {'type': 'number', 'format': 'double'}}}, 'minQuotesToQualifyForIntelligentPoolWindowOption': {'type': 'object', 'required': ['period', 'periodType'], 'properties': {'period': {'type': 'integer'}, 'periodType': {'type': 'string', 'enum': ['Minutes', 'Hours', 'Days', 'Months', 'Years']}}}, 'acceptanceRatioWindowOption': {'type': 'object', 'required': ['period', 'periodType'], 'properties': {'period': {'type': 'integer'}, 'periodType': {'type': 'string', 'enum': ['Minutes', 'Hours', 'Days', 'Months', 'Years']}}}, 'minQuotesToQualifyForIntelligentPool': {'type': 'object', 'required': ['value'], 'properties': {'value': {'minimum': -9223372036854775808, 'type': 'integer', 'maximum': 9223372036854775807}}}, 'intelligentPoolPercentage': {'type': 'object', 'properties': {'value': {'minimum': -9223372036854775808, 'type': 'integer', 'maximum': 9223372036854775807}}}, 'minLocationUpdates': {'type': 'object', 'required': ['value'], 'properties': {'value': {'minimum': -9223372036854775808, 'type': 'integer', 'maximum': 9223372036854775807}}}}}]}, {'url_path': '/dashboard/{merchantId}/merchant/config/onboardingDocument', 'request_type': 'get', 'parameters': [{'name': 'merchantId', 'required': True, 'in': 'path', 'schema': {'type': 'string'}}, {'name': 'documentType', 'required': False, 'in': 'query', 'schema': {'type': 'string', 'enum': ['RC', 'DL', 'RCInsurance']}}], 'request_body': []}, {'url_path': '/dashboard/{merchantId}/merchant/config/onboardingDocument/update', 'request_type': 'post', 'parameters': [{'name': 'merchantId', 'required': True, 'in': 'path', 'schema': {'type': 'string'}}, {'name': 'documentType', 'required': True, 'in': 'query', 'schema': {'type': 'string', 'enum': ['RC', 'DL', 'RCInsurance']}}], 'request_body': [{'type': 'object', 'properties': {'supportedVehicleClasses': {'type': 'object', 'oneOf': [{'type': 'object', 'required': ['documentType', 'vehicleClasses'], 'properties': {'vehicleClasses': {'items': {'type': 'string'}, 'type': 'array'}, 'documentType': {'type': 'string', 'enum': ['DLValidClasses']}}}, {'type': 'object', 'required': ['documentType', 'vehicleClasses'], 'properties': {'vehicleClasses': {'items': {'type': 'object', 'required': ['vehicleClass', 'vehicleVariant'], 'properties': {'vehicleVariant': {'type': 'string', 'enum': ['SEDAN', 'SUV', 'HATCHBACK', 'AUTO_RICKSHAW', 'TAXI', 'TAXI_PLUS']}, 'vehicleClass': {'type': 'string'}, 'vehicleCapacity': {'minimum': -9223372036854775808, 'type': 'integer', 'maximum': 9223372036854775807}}}, 'type': 'array'}, 'documentType': {'type': 'string', 'enum': ['RCValidClasses']}}}]}, 'vehicleClassCheckType': {'type': 'object', 'required': ['value'], 'properties': {'value': {'type': 'string', 'enum': ['Infix', 'Prefix', 'Suffix']}}}, 'rcNumberPrefix': {'type': 'object', 'required': ['value'], 'properties': {'value': {'type': 'string'}}}, 'checkExtraction': {'type': 'object', 'required': ['value'], 'properties': {'value': {'type': 'boolean'}}}, 'checkExpiry': {'type': 'object', 'required': ['value'], 'properties': {'value': {'type': 'boolean'}}}}}]}, {'url_path': '/dashboard/{merchantId}/merchant/config/onboardingDocument/create', 'request_type': 'post', 'parameters': [{'name': 'merchantId', 'required': True, 'in': 'path', 'schema': {'type': 'string'}}, {'name': 'documentType', 'required': True, 'in': 'query', 'schema': {'type': 'string', 'enum': ['RC', 'DL', 'RCInsurance']}}], 'request_body': [{'type': 'object', 'required': ['checkExtraction', 'checkExpiry', 'supportedVehicleClasses', 'rcNumberPrefix', 'vehicleClassCheckType'], 'properties': {'supportedVehicleClasses': {'type': 'object', 'oneOf': [{'type': 'object', 'required': ['documentType', 'vehicleClasses'], 'properties': {'vehicleClasses': {'items': {'type': 'string'}, 'type': 'array'}, 'documentType': {'type': 'string', 'enum': ['DLValidClasses']}}}, {'type': 'object', 'required': ['documentType', 'vehicleClasses'], 'properties': {'vehicleClasses': {'items': {'type': 'object', 'required': ['vehicleClass', 'vehicleVariant'], 'properties': {'vehicleVariant': {'type': 'string', 'enum': ['SEDAN', 'SUV', 'HATCHBACK', 'AUTO_RICKSHAW', 'TAXI', 'TAXI_PLUS']}, 'vehicleClass': {'type': 'string'}, 'vehicleCapacity': {'minimum': -9223372036854775808, 'type': 'integer', 'maximum': 9223372036854775807}}}, 'type': 'array'}, 'documentType': {'type': 'string', 'enum': ['RCValidClasses']}}}]}, 'vehicleClassCheckType': {'type': 'string', 'enum': ['Infix', 'Prefix', 'Suffix']}, 'rcNumberPrefix': {'type': 'string'}, 'checkExtraction': {'type': 'boolean'}, 'checkExpiry': {'type': 'boolean'}}}]}, {'url_path': '/dashboard/{merchantId}/merchant/serviceUsageConfig', 'request_type': 'get', 'parameters': [{'name': 'merchantId', 'required': True, 'in': 'path', 'schema': {'type': 'string'}}], 'request_body': []}, {'url_path': '/dashboard/{merchantId}/merchant/serviceConfig/maps/update', 'request_type': 'post', 'parameters': [{'name': 'merchantId', 'required': True, 'in': 'path', 'schema': {'type': 'string'}}], 'request_body': [{'type': 'object', 'required': ['serviceName', 'serviceConfig'], 'properties': {'serviceConfig': {'type': 'object', 'required': ['googleMapsUrl', 'googleRoadsUrl', 'googleKey'], 'properties': {'googleKey': {'type': 'string'}, 'googleRoadsUrl': {'type': 'string'}, 'googleMapsUrl': {'type': 'string'}}}, 'serviceName': {'type': 'string', 'enum': ['Google']}}}, {'type': 'object', 'required': ['serviceName', 'serviceConfig'], 'properties': {'serviceConfig': {'type': 'object', 'required': ['googleMapsUrl', 'googleRoadsUrl', 'googleKey'], 'properties': {'googleKey': {'type': 'string'}, 'googleRoadsUrl': {'type': 'string'}, 'googleMapsUrl': {'type': 'string'}}}, 'serviceName': {'type': 'string', 'enum': ['Google']}}}, {'type': 'object', 'required': ['serviceName', 'serviceConfig'], 'properties': {'serviceConfig': {'type': 'object', 'required': ['googleMapsUrl', 'googleRoadsUrl', 'googleKey'], 'properties': {'googleKey': {'type': 'string'}, 'googleRoadsUrl': {'type': 'string'}, 'googleMapsUrl': {'type': 'string'}}}, 'serviceName': {'type': 'string', 'enum': ['Google']}}}]}, {'url_path': '/dashboard/{merchantId}/merchant/serviceUsageConfig/maps/update', 'request_type': 'post', 'parameters': [{'name': 'merchantId', 'required': True, 'in': 'path', 'schema': {'type': 'string'}}], 'request_body': [{'type': 'object', 'properties': {'getRoutes': {'type': 'string', 'enum': ['Google', 'OSRM', 'MMI']}, 'getEstimatedPickupDistances': {'type': 'string', 'enum': ['Google', 'OSRM', 'MMI']}, 'autoComplete': {'type': 'string', 'enum': ['Google', 'OSRM', 'MMI']}, 'getDistances': {'type': 'string', 'enum': ['Google', 'OSRM', 'MMI']}, 'snapToRoad': {'type': 'string', 'enum': ['Google', 'OSRM', 'MMI']}, 'getPlaceDetails': {'type': 'string', 'enum': ['Google', 'OSRM', 'MMI']}, 'getPlaceName': {'type': 'string', 'enum': ['Google', 'OSRM', 'MMI']}}}]}, {'url_path': '/dashboard/{merchantId}/merchant/serviceConfig/sms/update', 'request_type': 'post', 'parameters': [{'name': 'merchantId', 'required': True, 'in': 'path', 'schema': {'type': 'string'}}], 'request_body': [{'type': 'object', 'required': ['serviceName', 'serviceConfig'], 'properties': {'serviceConfig': {'type': 'object', 'required': ['username', 'password', 'url'], 'properties': {'password': {'type': 'string'}, 'username': {'type': 'string'}, 'url': {'type': 'string'}}}, 'serviceName': {'type': 'string', 'enum': ['MyValueFirst']}}}, {'type': 'object', 'required': ['serviceName', 'serviceConfig'], 'properties': {'serviceConfig': {'type': 'object', 'required': ['username', 'password', 'url'], 'properties': {'password': {'type': 'string'}, 'username': {'type': 'string'}, 'url': {'type': 'string'}}}, 'serviceName': {'type': 'string', 'enum': ['MyValueFirst']}}}]}, {'url_path': '/dashboard/{merchantId}/merchant/serviceUsageConfig/sms/update', 'request_type': 'post', 'parameters': [{'name': 'merchantId', 'required': True, 'in': 'path', 'schema': {'type': 'string'}}], 'request_body': [{'type': 'object', 'required': ['smsProvidersPriorityList'], 'properties': {'smsProvidersPriorityList': {'items': {'type': 'string', 'enum': ['MyValueFirst', 'ExotelSms']}, 'type': 'array'}}}]}, {'url_path': '/dashboard/{merchantId}/merchant/serviceConfig/verification/update', 'request_type': 'post', 'parameters': [{'name': 'merchantId', 'required': True, 'in': 'path', 'schema': {'type': 'string'}}], 'request_body': [{'type': 'object', 'required': ['accountId', 'apiKey', 'secret', 'url'], 'properties': {'apiKey': {'type': 'string'}, 'url': {'type': 'string'}, 'accountId': {'type': 'string'}, 'secret': {'type': 'string'}}}]}, {'url_path': '/dashboard/{merchantId}/merchant/config/farePolicy/{farePolicyId}/driverExtraFeeBounds/create', 'request_type': 'post', 'parameters': [{'name': 'merchantId', 'required': True, 'in': 'path', 'schema': {'type': 'string'}}, {'name': 'farePolicyId', 'required': True, 'in': 'path', 'schema': {'type': 'string'}}, {'name': 'startDistance', 'required': True, 'in': 'query', 'schema': {'minimum': -9223372036854775808, 'type': 'integer', 'maximum': 9223372036854775807}}], 'request_body': [{'type': 'object', 'required': ['minFee', 'maxFee'], 'properties': {'minFee': {'minimum': -9223372036854775808, 'type': 'integer', 'maximum': 9223372036854775807}, 'maxFee': {'minimum': -9223372036854775808, 'type': 'integer', 'maximum': 9223372036854775807}}}]}, {'url_path': '/dashboard/{merchantId}/merchant/config/farePolicy/{farePolicyId}/driverExtraFeeBounds/update', 'request_type': 'post', 'parameters': [{'name': 'merchantId', 'required': True, 'in': 'path', 'schema': {'type': 'string'}}, {'name': 'farePolicyId', 'required': True, 'in': 'path', 'schema': {'type': 'string'}}, {'name': 'startDistance', 'required': True, 'in': 'query', 'schema': {'minimum': -9223372036854775808, 'type': 'integer', 'maximum': 9223372036854775807}}], 'request_body': [{'type': 'object', 'required': ['minFee', 'maxFee'], 'properties': {'minFee': {'minimum': -9223372036854775808, 'type': 'integer', 'maximum': 9223372036854775807}, 'maxFee': {'minimum': -9223372036854775808, 'type': 'integer', 'maximum': 9223372036854775807}}}]}, {'url_path': '/dashboard/{merchantId}/message/uploadFile', 'request_type': 'post', 'parameters': [{'name': 'merchantId', 'required': True, 'in': 'path', 'schema': {'type': 'string'}}], 'request_body': []}, {'url_path': '/dashboard/{merchantId}/message/addLink', 'request_type': 'post', 'parameters': [{'name': 'merchantId', 'required': True, 'in': 'path', 'schema': {'type': 'string'}}], 'request_body': [{'type': 'object', 'required': ['url', 'fileType'], 'properties': {'url': {'type': 'string'}, 'fileType': {'type': 'string', 'enum': ['Audio', 'Image']}}}]}, {'url_path': '/dashboard/{merchantId}/message/add', 'request_type': 'post', 'parameters': [{'name': 'merchantId', 'required': True, 'in': 'path', 'schema': {'type': 'string'}}], 'request_body': [{'type': 'object', 'required': ['_type', 'title', 'description', 'shortDescription', 'translations', 'mediaFiles'], 'properties': {'mediaFiles': {'items': {'type': 'string'}, 'type': 'array'}, 'shortDescription': {'type': 'string'}, 'label': {'type': 'string'}, 'translations': {'items': {'type': 'object', 'required': ['language', 'title', 'description', 'shortDescription'], 'properties': {'shortDescription': {'type': 'string'}, 'label': {'type': 'string'}, 'description': {'type': 'string'}, 'title': {'type': 'string'}, 'language': {'type': 'string', 'enum': ['ENGLISH', 'HINDI', 'KANNADA', 'TAMIL', 'MALAYALAM', 'BENGALI']}}}, 'type': 'array'}, 'description': {'type': 'string'}, 'title': {'type': 'string'}, '_type': {'type': 'object', 'oneOf': [{'type': 'object', 'required': ['tag', 'contents'], 'properties': {'contents': {'type': 'string'}, 'tag': {'type': 'string', 'enum': ['Action']}}}, {'type': 'object', 'required': ['tag'], 'properties': {'tag': {'type': 'string', 'enum': ['Read']}}}]}}}]}, {'url_path': '/dashboard/{merchantId}/message/send', 'request_type': 'post', 'parameters': [{'name': 'merchantId', 'required': True, 'in': 'path', 'schema': {'type': 'string'}}], 'request_body': []}, {'url_path': '/dashboard/{merchantId}/message/list', 'request_type': 'get', 'parameters': [{'name': 'merchantId', 'required': True, 'in': 'path', 'schema': {'type': 'string'}}, {'name': 'limit', 'required': False, 'in': 'query', 'schema': {'minimum': -9223372036854775808, 'type': 'integer', 'maximum': 9223372036854775807}}, {'name': 'offset', 'required': False, 'in': 'query', 'schema': {'minimum': -9223372036854775808, 'type': 'integer', 'maximum': 9223372036854775807}}], 'request_body': []}, {'url_path': '/dashboard/{merchantId}/message/{messageId}/info', 'request_type': 'get', 'parameters': [{'name': 'merchantId', 'required': True, 'in': 'path', 'schema': {'type': 'string'}}, {'name': 'messageId', 'required': True, 'in': 'path', 'schema': {'type': 'string'}}], 'request_body': []}, {'url_path': '/dashboard/{merchantId}/message/{messageId}/deliveryInfo', 'request_type': 'get', 'parameters': [{'name': 'merchantId', 'required': True, 'in': 'path', 'schema': {'type': 'string'}}, {'name': 'messageId', 'required': True, 'in': 'path', 'schema': {'type': 'string'}}], 'request_body': []}, {'url_path': '/dashboard/{merchantId}/message/{messageId}/receiverList', 'request_type': 'get', 'parameters': [{'name': 'merchantId', 'required': True, 'in': 'path', 'schema': {'type': 'string'}}, {'name': 'messageId', 'required': True, 'in': 'path', 'schema': {'type': 'string'}}, {'name': 'number', 'required': False, 'in': 'query', 'schema': {'type': 'string'}}, {'name': 'status', 'required': False, 'in': 'query', 'schema': {'type': 'string', 'enum': ['Failed', 'Success', 'Queued', 'Sending']}}, {'name': 'limit', 'required': False, 'in': 'query', 'schema': {'minimum': -9223372036854775808, 'type': 'integer', 'maximum': 9223372036854775807}}, {'name': 'offset', 'required': False, 'in': 'query', 'schema': {'minimum': -9223372036854775808, 'type': 'integer', 'maximum': 9223372036854775807}}], 'request_body': []}, {'url_path': '/dashboard/{merchantId}/referralProgram/referralOpsPassword', 'request_type': 'post', 'parameters': [{'name': 'merchantId', 'required': True, 'in': 'path', 'schema': {'type': 'string'}}], 'request_body': [{'type': 'object', 'required': ['referralLinkPassword'], 'properties': {'referralLinkPassword': {'type': 'string'}}}]}, {'url_path': '/dashboard/{merchantId}/referralProgram/linkReferral', 'request_type': 'post', 'parameters': [{'name': 'merchantId', 'required': True, 'in': 'path', 'schema': {'type': 'string'}}], 'request_body': []}, {'url_path': '/dashboard/{merchantId}/volunteer/{bookingOtp}/booking', 'request_type': 'get', 'parameters': [{'name': 'merchantId', 'required': True, 'in': 'path', 'schema': {'type': 'string'}}, {'name': 'bookingOtp', 'required': True, 'in': 'path', 'schema': {'type': 'string'}}], 'request_body': []}, {'url_path': '/dashboard/{merchantId}/volunteer/assign/start', 'request_type': 'post', 'parameters': [{'name': 'merchantId', 'required': True, 'in': 'path', 'schema': {'type': 'string'}}], 'request_body': [{'type': 'object', 'required': ['bookingId', 'driverId', 'point'], 'properties': {'driverId': {'type': 'string'}, 'bookingId': {'type': 'string'}, 'point': {'type': 'object', 'required': ['lat', 'lon'], 'properties': {'lat': {'type': 'number', 'format': 'double'}, 'lon': {'type': 'number', 'format': 'double'}}}}}]}, {'url_path': '/dashboard/{merchantId}/issue/category', 'request_type': 'get', 'parameters': [{'name': 'merchantId', 'required': True, 'in': 'path', 'schema': {'type': 'string'}}], 'request_body': []}, {'url_path': '/dashboard/{merchantId}/issue/list', 'request_type': 'get', 'parameters': [{'name': 'merchantId', 'required': True, 'in': 'path', 'schema': {'type': 'string'}}, {'name': 'limit', 'required': False, 'in': 'query', 'schema': {'minimum': -9223372036854775808, 'type': 'integer', 'maximum': 9223372036854775807}}, {'name': 'offset', 'required': False, 'in': 'query', 'schema': {'minimum': -9223372036854775808, 'type': 'integer', 'maximum': 9223372036854775807}}, {'name': 'status', 'required': False, 'in': 'query', 'schema': {'type': 'string', 'enum': ['NEW', 'INPROGRESS', 'RESOLVED']}}, {'name': 'category', 'required': False, 'in': 'query', 'schema': {'type': 'string'}}, {'name': 'assignee', 'required': False, 'in': 'query', 'schema': {'type': 'string'}}], 'request_body': []}, {'url_path': '/dashboard/{merchantId}/issue/{issueId}/info', 'request_type': 'get', 'parameters': [{'name': 'merchantId', 'required': True, 'in': 'path', 'schema': {'type': 'string'}}, {'name': 'issueId', 'required': True, 'in': 'path', 'schema': {'type': 'string'}}], 'request_body': []}, {'url_path': '/dashboard/{merchantId}/issue/{issueId}/update', 'request_type': 'put', 'parameters': [{'name': 'merchantId', 'required': True, 'in': 'path', 'schema': {'type': 'string'}}, {'name': 'issueId', 'required': True, 'in': 'path', 'schema': {'type': 'string'}}], 'request_body': [{'type': 'object', 'required': ['userId'], 'properties': {'status': {'type': 'string', 'enum': ['NEW', 'INPROGRESS', 'RESOLVED']}, 'assignee': {'type': 'string'}, 'userId': {'type': 'string'}}}]}, {'url_path': '/dashboard/{merchantId}/issue/{issueId}/comment', 'request_type': 'post', 'parameters': [{'name': 'merchantId', 'required': True, 'in': 'path', 'schema': {'type': 'string'}}, {'name': 'issueId', 'required': True, 'in': 'path', 'schema': {'type': 'string'}}], 'request_body': [{'type': 'object', 'required': ['comment', 'userId'], 'properties': {'comment': {'type': 'string'}, 'userId': {'type': 'string'}}}]}, {'url_path': '/dashboard/{merchantId}/issue/media', 'request_type': 'get', 'parameters': [{'name': 'merchantId', 'required': True, 'in': 'path', 'schema': {'type': 'string'}}, {'name': 'filePath', 'required': True, 'in': 'query', 'schema': {'type': 'string'}}], 'request_body': []}, {'url_path': '/exotel/heartbeat', 'request_type': 'post', 'request_body': [{'type': 'object', 'required': ['timestamp', 'status_type', 'incoming_affected', 'outgoing_affected'], 'properties': {'incoming_affected': {'items': {'type': 'object', 'required': ['phone_number_sid', 'phone_number'], 'properties': {'phone_number_sid': {'type': 'string'}, 'phone_number': {'type': 'string'}}}, 'type': 'array'}, 'status_type': {'type': 'string', 'enum': ['OK', 'WARNING', 'CRITICAL', 'PAYLOAD_TOO_LARGE']}, 'outgoing_affected': {'items': {'type': 'object', 'required': ['phone_number_sid', 'phone_number'], 'properties': {'phone_number_sid': {'type': 'string'}, 'phone_number': {'type': 'string'}}}, 'type': 'array'}, 'timestamp': {'type': 'string', 'format': 'yyyy-mm-ddThh:MM:ssZ', 'example': '2016-07-22T00:00:00Z'}}}]}, {'url_path': '/internal/{merchantId}/referee', 'request_type': 'post', 'parameters': [{'name': 'merchantId', 'required': True, 'in': 'path', 'schema': {'type': 'string'}}, {'name': 'token', 'required': False, 'in': 'header', 'schema': {'type': 'string'}}], 'request_body': [{'type': 'object', 'required': ['referralCode', 'customerMobileNumber', 'customerMobileCountryCode'], 'properties': {'customerMobileCountryCode': {'type': 'string'}, 'customerMobileNumber': {'type': 'string'}, 'referralCode': {'type': 'string'}}}]}] --------------------------------------------------------------------------------