{"openapi":"3.0.0","info":{"description":"This is an API for AAP Mobile App\n","version":"1.0.0","title":"AAP Mobile Api","termsOfService":"http://swagger.io/terms/","contact":{"email":"king.mark.kevin@icloud.com"},"license":{"name":"Apache 2.0","url":"http://www.apache.org/licenses/LICENSE-2.0.html"}},"servers":[{"description":"SwaggerHub API Auto Mocking","url":"https://virtserver.swaggerhub.com/swiftymarks/aap-mobile/1.0.0"},{"description":"Headers","url":"http://localhost:3000"},{"url":"https://staging.aap-mobile.com"}],"tags":[{"name":"User's Authentications"},{"name":"User's Profile"},{"name":"Apply For Membership"},{"name":"Memberships"},{"name":"Admin's Authentications"},{"name":"Admin's Management"},{"name":"Admin's Partner Categories"},{"name":"User's Database"},{"name":"Tow's Database"},{"name":"Products's Database"},{"name":"Regular Membership's Database"},{"name":"Dispatcher's Database"}],"paths":{"/v1/users/authentications/sign_in":{"post":{"tags":["User's Authentications"],"summary":"User Sign in","operationId":"userSignIn","requestBody":{"content":{"application/json":{"schema":{"type":"object","properties":{"email":{"type":"string"},"password":{"type":"string"}}},"example":{"email":"user@mail.com","password":"1234567890"}}}},"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"message":{"type":"string"},"access_token":{"type":"string"}}}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"type":"object","$ref":"#/components/schemas/UnauthorizedError"}}}},"422":{"description":"Missing Parameters","content":{"application/json":{"schema":{"type":"object","$ref":"#/components/schemas/UnprocessableEntityError"}}}}}}},"/v1/users/authentications/sign_up":{"post":{"tags":["User's Authentications"],"summary":"User Sign up","operationId":"userSignUp","requestBody":{"content":{"application/json":{"schema":{"type":"object","properties":{"email":{"type":"string"},"password":{"type":"string"},"mobile_number":{"type":"string"}}},"example":{"email":"user@mail.com","password":"1234567890","mobile_number":"+6391712345678"}}}},"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"message":{"type":"string"},"access_token":{"type":"string"}}}}}},"422":{"description":"Unprocessable Entity Error (Missing Parameters, Email Taken)","content":{"application/json":{"schema":{"type":"object","$ref":"#/components/schemas/UnprocessableEntityError"}}}},"598":{"description":"There's an issue with the Weis Service for member's pin code","content":{"application/json":{"schema":{"type":"object","properties":{"status":{"type":"integer"},"message":{"type":"string"}}},"example":{"status":598,"message":"Weis Server cannot be reach"}}}}}}},"/v1/users/authentications/facebook_signin":{"post":{"tags":["User's Authentications"],"summary":"Facebook Sign in","operationId":"userFacebookSignin","requestBody":{"content":{"application/json":{"schema":{"type":"object","properties":{"access_token":{"type":"string"},"facebook_id":{"type":"string"}}}}}},"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"message":{"type":"string"},"access_token":{"type":"string"}}}}}},"422":{"description":"Unprocessable Entity Error (Missing Parameters)","content":{"application/json":{"schema":{"type":"object","$ref":"#/components/schemas/UnprocessableEntityError"}}}}}}},"/v1/users/authentications/facebook_signup":{"post":{"tags":["User's Authentications"],"summary":"Facebook Sign up","operationId":"userFacebookSignup","requestBody":{"content":{"application/json":{"schema":{"type":"object","properties":{"access_token":{"type":"string"},"facebook_id":{"type":"string"}}}}}},"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"message":{"type":"string"},"access_token":{"type":"string"}}}}}},"422":{"description":"Unprocessable Entity Error or Invalid Pin Code","content":{"application/json":{"schema":{"type":"object","$ref":"#/components/schemas/UnprocessableEntityError"}}}},"598":{"description":"There's an issue with the Weis Service for member's pin code","content":{"application/json":{"schema":{"type":"object","properties":{"status":{"type":"integer"},"message":{"type":"string"}}},"example":{"status":598,"message":"Weis Server cannot be reach"}}}}}}},"/v1/users/authentications/apple_signin":{"post":{"tags":["User's Authentications"],"summary":"Apple Sign in","operationId":"userAppleSignin","requestBody":{"content":{"application/json":{"schema":{"type":"object","properties":{"access_token":{"type":"string"}}}}}},"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"message":{"type":"string"},"access_token":{"type":"string"}}}}}},"422":{"description":"Unprocessable Entity Error or Invalid Pin Code","content":{"application/json":{"schema":{"type":"object","$ref":"#/components/schemas/UnprocessableEntityError"}}}},"598":{"description":"There's an issue with the Weis Service for member's pin code","content":{"application/json":{"schema":{"type":"object","properties":{"status":{"type":"integer"},"message":{"type":"string"}}},"example":{"status":598,"message":"Weis Server cannot be reach"}}}}}}},"/v1/users/authentications/apple_signup":{"post":{"tags":["User's Authentications"],"summary":"Apple Sign up","operationId":"userAppleSignup","requestBody":{"content":{"application/json":{"schema":{"type":"object","properties":{"access_token":{"type":"string"}}}}}},"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"message":{"type":"string"},"access_token":{"type":"string"}}}}}},"422":{"description":"Unprocessable Entity Error or Invalid Pin Code","content":{"application/json":{"schema":{"type":"object","$ref":"#/components/schemas/UnprocessableEntityError"}}}},"598":{"description":"There's an issue with the Weis Service for member's pin code","content":{"application/json":{"schema":{"type":"object","properties":{"status":{"type":"integer"},"message":{"type":"string"}}},"example":{"status":598,"message":"Weis Server cannot be reach"}}}}}}},"/v1/users/authentications/forgot_password":{"post":{"tags":["User's Authentications"],"summary":"Forgot Password","operationId":"forgotPassword","requestBody":{"content":{"application/json":{"schema":{"type":"object","properties":{"email":{"type":"string"}}}}}},"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"email":{"type":"string"}}}}}},"422":{"description":"Unprocessable Entity Error or Invalid Pin Code","content":{"application/json":{"schema":{"type":"object","$ref":"#/components/schemas/UnprocessableEntityError"}}}}}}},"/v1/users/me":{"get":{"tags":["User's Profile"],"summary":"Fetch User's Profile and check if has a valid membership.","description":"A valid membership must have application_form object or a pidp_form object for pidp","operationId":"getUserProfile","responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","$ref":"#/components/schemas/User"}}}}},"security":[{"Authorization":[]}]}},"/v1/users/update_me":{"put":{"tags":["User's Profile"],"summary":"Update User's Profile","description":"All fields are optional. Do not add the field on the json if you don't want to update the field","operationId":"updateUserProfile","requestBody":{"content":{"application/json":{"schema":{"type":"object","properties":{"preferred_branch_form":{"type":"object","properties":{"preferred_branch":{"type":"string"}}},"personal_information_form":{"type":"object","$ref":"#/components/schemas/PersonalInformationApplication"},"document_upload_form":{"type":"object","$ref":"#/components/schemas/DocumentUploadApplication"},"contact_form":{"type":"object","$ref":"#/components/schemas/ContactFormApplication"},"vehicle_forms":{"type":"array","items":{"$ref":"#/components/schemas/VehicleApplication"}}}},"example":{"preferred_branch_form":{"preferred_branch":"Branch Name"},"personal_information_form":{"first_name":"First Name","middle_nqme":"Middle Name","last_name":"Last Name","title":"Title","gender":"Gender","birth_date":"Birth Date","place_of_birth":"Place of Birth","occupation":"Occupation","civil_status":"Civil Status","citizenship":"Citizenship","acr_number":"ACR Number","mailing_preference":"Mailing Preferences","building_number":"Building Number","barangay":"Barangay","city":"City","province":"Province","country":"Country","zip_code":"Zip Code"},"document_upload_form":{"scanned_id":"Base 64 Image File","lto_license":"Base 64 Image File"},"contact_form":{"mobile_number":"+6391712345678","telephone_number":"82423434","email":"user@mail.com"},"vehicle_forms":[{"id":"Vehicle Id 1","plate_number":"Plate Number","make":"Make","model":"Model","color":"Color","year_model":"2004","fuel_type":"Fuel Type","transmission_type":"Transmission Type","official_receipt":"Base 64 Image File","certificate_of_registration":"Base 64 Image File"},{"id":"Vehicle Id 2","plate_number":"Plate Number","make":"Make","model":"Model","color":"Color","year_model":"2004","fuel_type":"Fuel Type","transmission_type":"Transmission Type","official_receipt":"Base 64 Image File","certificate_of_registration":"Base 64 Image File"}]}}}},"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","$ref":"#/components/schemas/User"}}}}},"security":[{"Authorization":[]}]}},"/v1/users/link":{"post":{"tags":["User's Profile"],"summary":"Link User's Profile","description":"kAll fields are optional. Do not add the field on the json if you don't want to update the field","operationId":"linkUserProfile","requestBody":{"content":{"application/json":{"schema":{"type":"object","properties":{"first_name":{"type":"string"},"last_name":{"type":"string"},"birth_date":{"type":"string"}},"example":{"first_name":"MAK","last_name":"Wu","birth_date":"08/10/1976"}}}}},"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"message":{"type":"string"}}}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"type":"object","$ref":"#/components/schemas/UnauthorizedError"}}}},"404":{"description":"Unauthorized","content":{"application/json":{"schema":{"type":"object","$ref":"#/components/schemas/NotFoundError"}}}}}}},"/v1/users/change_password":{"post":{"tags":["User's Profile"],"summary":"Change Password","description":"kAll fields are optional. Do not add the field on the json if you don't want to update the field","operationId":"changePassword","requestBody":{"content":{"application/json":{"schema":{"type":"object","properties":{"old_password":{"type":"string"},"new_password":{"type":"string"},"verify_new_password":{"type":"string"}},"example":{"old_password":"123456","new_password":"123456","verify_new_password":"1234567"}}}}},"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"message":{"type":"string"}}}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"type":"object","$ref":"#/components/schemas/UnauthorizedError"}}}},"404":{"description":"Unauthorized","content":{"application/json":{"schema":{"type":"object","$ref":"#/components/schemas/NotFoundError"}}}}}}},"/v1/users/dispatchers":{"get":{"parameters":[{"in":"query","name":"plate_number","required":true,"schema":{"type":"string"},"description":"The plate number"}],"tags":["User's Database"],"summary":"Admin Get User","operationId":"getAdminUsers","responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"message":{"type":"string"},"access_token":{"type":"object","$ref":"#/components/schemas/Dispatcher"}}}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"type":"object","$ref":"#/components/schemas/UnauthorizedError"}}}},"404":{"description":"Unauthorized","content":{"application/json":{"schema":{"type":"object","$ref":"#/components/schemas/NotFoundError"}}}}}}},"/v1/users/application_forms":{"post":{"tags":["Apply For Membership"],"summary":"Apply for User Membership","description":"List of Payment Status (0) - Paynamics","operationId":"applyMembership","requestBody":{"content":{"application/json":{"schema":{"type":"object","properties":{"regular_membership_id":{"type":"string"},"payment_type":{"type":"number"},"preferred_branch_form":{"type":"object","properties":{"preferred_branch":{"type":"string"}}},"personal_information_form":{"type":"object","$ref":"#/components/schemas/PersonalInformationApplication"},"document_upload_form":{"type":"object","$ref":"#/components/schemas/DocumentUploadApplication"},"contact_form":{"type":"object","$ref":"#/components/schemas/ContactFormApplication"},"vehicle_forms":{"type":"array","items":{"$ref":"#/components/schemas/VehicleApplication"}}}},"example":{"regular_membership_id":"1","payment_type":1,"preferred_branch_form":{"preferred_branch":"Branch Name"},"personal_information_form":{"first_name":"First Name","middle_nqme":"Middle Name","last_name":"Last Name","title":"Title","gender":"Gender","birth_date":"Birth Date","place_of_birth":"Place of Birth","occupation":"Occupation","civil_status":"Civil Status","citizenship":"Citizenship","acr_number":"ACR Number","mailing_preference":"Mailing Preferences","building_number":"Building Number","barangay":"Barangay","city":"City","province":"Province","country":"Country","zip_code":"Zip Code"},"document_upload_form":{"scanned_id":"Base 64 Image File","lto_license":"Base 64 Image File"},"contact_form":{"mobile_number":"+6391712345678","telephone_number":"82423434","email":"user@mail.com"},"vehicle_forms":[{"id":"Vehicle Id 1","plate_number":"Plate Number","make":"Make","model":"Model","color":"Color","year_model":"2004","fuel_type":"Fuel Type","transmission_type":"Transmission Type","official_receipt":"Base 64 Image File","certificate_of_registration":"Base 64 Image File"},{"id":"Vehicle Id 2","plate_number":"Plate Number","make":"Make","model":"Model","color":"Color","year_model":"2004","fuel_type":"Fuel Type","transmission_type":"Transmission Type","official_receipt":"Base 64 Image File","certificate_of_registration":"Base 64 Image File"}]}}}},"responses":{"201":{"description":"If Payment status is 0 or (Paynamics)","content":{"application/json":{"schema":{"type":"object","properties":{"message":{"type":"string"},"paynamics_instruction":{"$ref":"#/components/schemas/PaynamicsInstruction"}}},"example":{"message":"Payment request success","paynamics_instruction":{"url":"http://xxxx.xxxx.com","body":"Base 64 String base on inputs","response_url":"http://xxxx.xxxxx.com","cancel_url":"https://xxxx.xxxxx.com"}}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UnauthorizedError"}}}},"422":{"description":"Missing Paramter Errors","content":{"application/json":{"schema":{"$ref":"#/components/schemas/MissingParametersError"}}}}},"security":[{"Authorization":[]}]}},"/v1/users/regular_memberships":{"get":{"tags":["Memberships"],"summary":"Fetch Lists of Available Memberships to apply","operationId":"getMemberships","responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","$ref":"#/components/schemas/RegularMembership"}}}}}}},"/v1/admins/authentications/sign_in":{"post":{"tags":["Admin's Authentications"],"summary":"Admin Sign in","operationId":"adminSignIn","requestBody":{"content":{"application/json":{"schema":{"type":"object","properties":{"email":{"type":"string"},"password":{"type":"string"}}},"example":{"email":"user@mail.com","password":"1234567890"}}}},"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"message":{"type":"string"},"access_token":{"type":"string"}}}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"type":"object","$ref":"#/components/schemas/UnauthorizedError"}}}},"422":{"description":"Missing Parameters","content":{"application/json":{"schema":{"type":"object","$ref":"#/components/schemas/UnprocessableEntityError"}}}}}}},"/v1/admins/admins/add":{"post":{"tags":["Admin's Management"],"summary":"Admin add Admin","operationId":"adminAdd","requestBody":{"content":{"application/json":{"schema":{"type":"object","properties":{"email":{"type":"string"},"password":{"type":"string"},"roles":{"type":"string"}}},"example":{"email":"user@mail.com","password":"1234567890","roles":"Super"}}}},"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"message":{"type":"string"}}}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"type":"object","$ref":"#/components/schemas/UnauthorizedError"}}}},"422":{"description":"Missing Parameters","content":{"application/json":{"schema":{"type":"object","$ref":"#/components/schemas/UnprocessableEntityError"}}}}}}},"/v1/admins/admins/remove":{"post":{"tags":["Admin's Management"],"summary":"Admin remove Admin","operationId":"adminDelete","requestBody":{"content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"string"}}},"example":{"id":"1"}}}},"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"message":{"type":"string"},"access_token":{"type":"string"}}}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"type":"object","$ref":"#/components/schemas/UnauthorizedError"}}}},"422":{"description":"Missing Parameters","content":{"application/json":{"schema":{"type":"object","$ref":"#/components/schemas/UnprocessableEntityError"}}}}}}},"/v1/admins/admins/update":{"put":{"tags":["Admin's Management"],"summary":"Admin add Admin","operationId":"updateAdmins","requestBody":{"content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"string"},"email":{"type":"string"},"password":{"type":"string"},"roles":{"type":"string"}}},"example":{"id":"1","email":"user@mail.com","password":"1234567890","roles":"Super"}}}},"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"message":{"type":"string"},"access_token":{"type":"string"}}}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"type":"object","$ref":"#/components/schemas/UnauthorizedError"}}}},"422":{"description":"Missing Parameters","content":{"application/json":{"schema":{"type":"object","$ref":"#/components/schemas/UnprocessableEntityError"}}}}}}},"/v1/admins/admins/me":{"get":{"tags":["Admin's Management"],"summary":"Admin Get Me","operationId":"getAdminMe","responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"email":{"type":"string"},"roles":{"type":"string"}}}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"type":"object","$ref":"#/components/schemas/UnauthorizedError"}}}}}}},"/v1/admins/admins":{"get":{"tags":["Admin's Management"],"summary":"Admin Get User","operationId":"getAdminUserss","responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"message":{"type":"string"},"access_token":{"type":"string"}}}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"type":"object","$ref":"#/components/schemas/UnauthorizedError"}}}}}}},"/v1/admins/users":{"get":{"parameters":[{"in":"query","name":"page","required":true,"schema":{"type":"integer","minimum":1},"description":"The page number"},{"in":"query","name":"limit","required":false,"schema":{"type":"integer","minimum":1},"description":"The limit per page"}],"tags":["User's Database"],"summary":"Admin Get User","operationId":"getAdminUserssss","responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"message":{"type":"string"},"access_token":{"type":"string"}}}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"type":"object","$ref":"#/components/schemas/UnauthorizedError"}}}}}},"put":{"tags":["User's Database"],"summary":"Admin Edit User","description":"Other fields are optional except id. A provided field will update the record","operationId":"adminEditUser","requestBody":{"content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"string"},"email":{"type":"string"},"mobile_number":{"type":"string"},"birth_date":{"type":"string"}}}}}},"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"message":{"type":"string"},"results":{"type":"object","$ref":"#/components/schemas/User"}}}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"type":"object","$ref":"#/components/schemas/UnauthorizedError"}}}},"404":{"description":"Unauthorized","content":{"application/json":{"schema":{"type":"object","$ref":"#/components/schemas/UnauthorizedError"}}}}}}},"/v1/admins/partner_categories":{"get":{"tags":["Admin's Partner Categories"],"summary":"Admin Get Partner Categories","operationId":"getAdminPartnerCategories","responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"results":{"type":"array","items":{"$ref":"#/components/schemas/PartnerCategory"}}}}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"type":"object","$ref":"#/components/schemas/UnauthorizedError"}}}}}},"post":{"tags":["Admin's Partner Categories"],"summary":"Admin Add Partner Categories","operationId":"getAdminPartnerCategoriessss","requestBody":{"content":{"application/json":{"schema":{"type":"object","properties":{"name":{"type":"string"}}}}}},"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"results":{"type":"array","items":{"$ref":"#/components/schemas/PartnerCategory"}}}}}}}}},"put":{"tags":["Admin's Partner Categories"],"summary":"Admin Edit Partner Categories","operationId":"editAdminPartnerCategories","requestBody":{"content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"string"},"name":{"type":"string"}}}}}},"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"results":{"type":"array","items":{"$ref":"#/components/schemas/PartnerCategory"}}}}}}}}}},"/v1/admins/partner_categories/remove":{"post":{"tags":["Admin's Partner Categories"],"summary":"Admin Remove Partner Categories","operationId":"removeAdminPartnerCategories","requestBody":{"content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"string"}}}}}},"responses":{"200":{"description":"OK"}}}},"/v1/admins/partners/remove":{"post":{"tags":["Admin's Partners"],"summary":"Admin's Partner","operationId":"addAdminPartners","requestBody":{"content":{"application/json":{"schema":{"type":"object","properties":{"is":{"type":"string"}}}}}},"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"results":{"type":"array","items":{"$ref":"#/components/schemas/Partner"}}}}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"type":"object","$ref":"#/components/schemas/UnauthorizedError"}}}}}}},"/v1/admins/partners":{"get":{"tags":["Admin's Partners"],"summary":"Admin Get Partner","operationId":"getPartners","responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"results":{"type":"array","items":{"$ref":"#/components/schemas/Partner"}}}}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"type":"object","$ref":"#/components/schemas/UnauthorizedError"}}}}}},"post":{"tags":["Admin's Partners"],"summary":"Admin Add Partner","operationId":"addAdminPartnersss","requestBody":{"content":{"application/json":{"schema":{"type":"object","properties":{"title":{"type":"string"},"subtitle":{"type":"string"},"image_url":{"type":"string"},"url":{"type":"string"},"partner_category_id":{"type":"string"}}}}}},"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"results":{"type":"array","items":{"$ref":"#/components/schemas/Partner"}}}}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"type":"object","$ref":"#/components/schemas/UnauthorizedError"}}}}}}},"/v1/admins/application_forms":{"get":{"tags":["Application Form's Database"],"summary":"Admin Get Application Forms","operationId":"getApplicationForms","parameters":[{"in":"query","name":"page","required":true,"schema":{"type":"integer","minimum":1},"description":"The page number"},{"in":"query","name":"limit","required":false,"schema":{"type":"integer","minimum":1},"description":"The limit per page"},{"in":"query","name":"status","required":false,"schema":{"type":"integer","minimum":0,"maximum":5},"description":"The status of tow"}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"message":{"type":"string"},"access_token":{"type":"string"}}}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"type":"object","$ref":"#/components/schemas/UnauthorizedError"}}}}}},"put":{"tags":["Application Form's Database"],"summary":"Admin Edit Application","description":"Other fields are optional except id. A provided field will update the record","operationId":"adminEditApplication","requestBody":{"content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"string"},"personal_information_form":{"type":"object","$ref":"#/components/schemas/PersonalInformationApplication"},"contact_form":{"type":"object","$ref":"#/components/schemas/ContactFormApplication"},"preferred_branch_form":{"type":"object","$ref":"#/components/schemas/PreferredBranchApplication"},"pidp_detail_form":{"type":"object","$ref":"#/components/schemas/PidpDetailApplication"},"vehicle_forms":{"type":"array","items":{"$ref":"#/components/schemas/VehicleApplication"}},"beneficiary_forms":{"type":"array","items":{"$ref":"#/components/schemas/BeneficiaryApplication"}}}}}}},"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"message":{"type":"string"},"results":{"type":"object","$ref":"#/components/schemas/User"}}}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"type":"object","$ref":"#/components/schemas/UnauthorizedError"}}}},"404":{"description":"Unauthorized","content":{"application/json":{"schema":{"type":"object","$ref":"#/components/schemas/UnauthorizedError"}}}}}}},"/v1/admins/application_forms/success":{"post":{"tags":["Application Form's Database"],"summary":"Mark as approved application form","description":"Other fields are optional except id. A provided field will update the record","operationId":"adminApproveApplicationForm","requestBody":{"content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"string"}}}}}},"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"message":{"type":"string"},"results":{"type":"object","$ref":"#/components/schemas/User"}}}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"type":"object","$ref":"#/components/schemas/UnauthorizedError"}}}},"404":{"description":"Unauthorized","content":{"application/json":{"schema":{"type":"object","$ref":"#/components/schemas/UnauthorizedError"}}}}}}},"/v1/admins/dispatchers":{"get":{"tags":["Dispatcher's Database"],"summary":"Get Dispatchers","operationId":"getAdminDispatchers","responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"message":{"type":"string"},"results":{"type":"array","items":{"$ref":"#/components/schemas/Dispatcher"}}}}}}}}}},"/v1/admins/tows":{"get":{"parameters":[{"in":"query","name":"page","required":true,"schema":{"type":"integer","minimum":1},"description":"The page number"},{"in":"query","name":"limit","required":false,"schema":{"type":"integer","minimum":1},"description":"The limit per page"},{"in":"query","name":"status","required":false,"schema":{"type":"integer","minimum":0,"maximum":2},"description":"The status of tow"}],"tags":["Tow's Database"],"summary":"Admin Get Tows","operationId":"getAdminTows","responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"message":{"type":"string"},"results":{"type":"object","$ref":"#/components/schemas/Tow"}}}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"type":"object","$ref":"#/components/schemas/UnauthorizedError"}}}}}},"put":{"tags":["Tow's Database"],"summary":"Admin Edit tow","description":"Other fields are optional except id. A provided field will update the record","operationId":"adminEditTow","requestBody":{"content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"string"},"status":{"type":"integer"},"plate_number":{"type":"string"}}}}}},"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"message":{"type":"string"},"results":{"type":"object","$ref":"#/components/schemas/Tow"}}}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"type":"object","$ref":"#/components/schemas/UnauthorizedError"}}}},"404":{"description":"Unauthorized","content":{"application/json":{"schema":{"type":"object","$ref":"#/components/schemas/UnauthorizedError"}}}}}}},"/v1/admins/products":{"get":{"parameters":[{"in":"query","name":"page","required":true,"schema":{"type":"integer","minimum":1},"description":"The page number"},{"in":"query","name":"limit","required":false,"schema":{"type":"integer","minimum":1},"description":"The limit per page"}],"tags":["Products's Database"],"summary":"Admin Get Products","operationId":"getAdminProducts","responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"message":{"type":"string"},"results":{"type":"object","$ref":"#/components/schemas/Product"}}}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"type":"object","$ref":"#/components/schemas/UnauthorizedError"}}}}}},"post":{"tags":["Products's Database"],"summary":"Admin Add Product","description":"Other fields are optional except id. A provided field will update the record","operationId":"addminAddProduct","requestBody":{"content":{"application/json":{"schema":{"type":"object","properties":{"title":{"type":"string"},"info":{"type":"string"},"lowest_amount":{"type":"number"},"link":{"type":"string"},"is_pidp":{"type":"boolean"}}}}}},"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"message":{"type":"string"},"results":{"type":"object","$ref":"#/components/schemas/Product"}}}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"type":"object","$ref":"#/components/schemas/UnauthorizedError"}}}},"404":{"description":"Unauthorized","content":{"application/json":{"schema":{"type":"object","$ref":"#/components/schemas/UnauthorizedError"}}}}}},"put":{"tags":["Products's Database"],"summary":"Admin Edit Product","description":"Other fields are optional except id. A provided field will update the record","operationId":"adminEditProduct","requestBody":{"content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"string"},"title":{"type":"string"},"info":{"type":"string"},"lowest_amount":{"type":"number"},"link":{"type":"string"},"is_pidp":{"type":"boolean"}}}}}},"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"message":{"type":"string"},"results":{"type":"object","$ref":"#/components/schemas/Product"}}}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"type":"object","$ref":"#/components/schemas/UnauthorizedError"}}}},"404":{"description":"Unauthorized","content":{"application/json":{"schema":{"type":"object","$ref":"#/components/schemas/UnauthorizedError"}}}}}}},"/v1/admins/regular_memberships/add":{"post":{"tags":["Regular Membership's Database"],"summary":"Admin Add Regular Membership","description":"All fields are required","operationId":"adminAddRegularMembership","requestBody":{"content":{"application/json":{"schema":{"type":"object","properties":{"title":{"type":"string"},"amount":{"type":"number"},"info":{"type":"string"},"amount_info":{"type":"string"},"duration":{"type":"number"},"desc":{"type":"string"},"benefits_description":{"type":"string"},"pidp_multiple_amount":{"type":"number"},"member_type":{"type":"string"},"plan_type":{"type":"string"},"is_pidp":{"type":"boolean"}}}}}},"responses":{"201":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"message":{"type":"string"},"results":{"type":"object","$ref":"#/components/schemas/RegularMembership"}}}}}}}}},"/v1/admins/regular_memberships":{"get":{"tags":["Regular Membership's Database"],"summary":"Admin Get Regular Memberships","operationId":"getAdminRegularMemberships","responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"message":{"type":"string"},"results":{"type":"object","$ref":"#/components/schemas/Tow"}}}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"type":"object","$ref":"#/components/schemas/UnauthorizedError"}}}}}},"put":{"tags":["Regular Membership's Database"],"summary":"Admin Edit Regular Membership","description":"Other fields are optional except id. A provided field will update the record","operationId":"adminEditRegularMembership","requestBody":{"content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"string"},"title":{"type":"integer"},"amount":{"type":"number"},"duration":{"type":"number"},"desc":{"type":"string"},"benefits_description":{"type":"string"},"pidp_multiple_amount":{"type":"number"},"member_type":{"type":"string"},"plan_type":{"type":"string"},"is_pidp":{"type":"boolean"},"product_id":{"type":"string"}}}}}},"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"message":{"type":"string"},"results":{"type":"object","$ref":"#/components/schemas/RegularMembership"}}}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"type":"object","$ref":"#/components/schemas/UnauthorizedError"}}}},"404":{"description":"Unauthorized","content":{"application/json":{"schema":{"type":"object","$ref":"#/components/schemas/UnauthorizedError"}}}}}}}},"externalDocs":{"description":"Find out more about Swagger","url":"http://swagger.io"},"components":{"schemas":{"Admin":{"type":"object","properties":{"id":{"type":"string"},"email":{"type":"string"},"roles":{"type":"string"}}},"User":{"type":"object","properties":{"facebook_id":{"type":"string"},"apple_id":{"type":"string"},"email":{"type":"string"},"mobile_number":{"type":"string"},"birth_date":{"type":"string"},"is_verified":{"type":"boolean"},"application_form":{"$ref":"#/components/schemas/ApplicationForm"},"pidp_form":{"$ref":"#/components/schemas/ApplicationForm"}}},"ApplicationForm":{"type":"object","properties":{"status":{"type":"integer"},"payment_type":{"type":"integer"},"personal_information":{"$ref":"#/components/schemas/PersonalInformationApplication"},"contact_form":{"$ref":"#/components/schemas/ContactFormApplication"},"document_upload_form":{"$ref":"#/components/schemas/DocumentUploadApplication"},"preferred_branch":{"$ref":"#/components/schemas/PreferredBranchApplication"},"regular_membership":{"$ref":"#/components/schemas/RegularMembershipApplication"},"vehicles":{"type":"array","items":{"$ref":"#/components/schemas/VehicleApplication"}}}},"ContactFormApplication":{"type":"object","properties":{"id":{"type":"string"},"email":{"type":"string"},"mobile_number":{"type":"string"},"telephone_number":{"type":"string"},"alternate_email":{"type":"string"},"alternate_mobile_number":{"type":"string"},"mailing_preference":{"type":"string"},"building_number":{"type":"string"},"barangay":{"type":"string"},"city":{"type":"string"},"province":{"type":"string"},"company_name":{"type":"string"},"zip_code":{"type":"string"},"office_building_number":{"type":"string"},"office_barangay":{"type":"string"},"office_city":{"type":"string"},"office_province":{"type":"string"},"office_company_name":{"type":"string"},"office_zip_code":{"type":"string"}}},"DocumentUploadApplication":{"type":"object","properties":{"id":{"type":"string"},"scanned_id":{"type":"string"},"lto_license":{"type":"string"}}},"PreferredBranchApplication":{"type":"object","properties":{"id":{"type":"string"},"branch_id":{"type":"string"},"branch":{"type":"string"}}},"RegularMembershipApplication":{"type":"object","properties":{"title":{"type":"string"},"info":{"type":"string"},"amount":{"type":"number"},"amount_info":{"type":"string"},"duration":{"type":"integer"},"desc":{"type":"string"},"is_pidp":{"type":"string"},"benefits_description":{"type":"string"},"start_duration":{"type":"string"},"end_duration":{"type":"string"}}},"RegularMembership":{"type":"object","properties":{"id":{"type":"string"},"title":{"type":"string"},"info":{"type":"string"},"amount":{"type":"number"},"amount_info":{"type":"string"},"duration":{"type":"integer"},"desc":{"type":"string"},"is_pidp":{"type":"string"},"benefits_description":{"type":"string"},"member_type":{"type":"string"},"plan_type":{"type":"string"},"pidp_multiple_amount":{"type":"number"}}},"PersonalInformationApplication":{"type":"object","properties":{"id":{"type":"string"},"title":{"type":"string"},"gender":{"type":"string"},"first_name":{"type":"string"},"last_name":{"type":"string"},"middle_nqme":{"type":"string"},"birth_date":{"type":"string"},"place_of_birth":{"type":"string"},"occupation":{"type":"string"},"civil_status":{"type":"string"},"citizenship":{"type":"string"},"acr_number":{"type":"string"}}},"VehicleApplication":{"type":"object","properties":{"id":{"type":"string"},"plate_number":{"type":"string"},"make":{"type":"string"},"model":{"type":"string"},"color":{"type":"string"},"year_model":{"type":"string"},"conduction_sticker_no":{"type":"string"},"fuel_type":{"type":"string"},"transmission_type":{"type":"string"},"official_receipt":{"type":"string"},"certificate_of_registration":{"type":"string"}}},"Tow":{"type":"object","properties":{"id":{"type":"string"},"uuid":{"type":"string"},"name":{"type":"string"},"status":{"type":"integer"},"location":{"type":"string"},"lat":{"type":"number"},"lng":{"type":"number"},"mobile_number":{"type":"string"},"details":{"type":"string"},"dispatcher_plate_number":{"type":"string"},"created_at":{"type":"string"},"updated_at":{"type":"string"}}},"Dispatcher":{"type":"object","properties":{"id":{"type":"string"},"plate_number":{"type":"string"},"lat":{"type":"number"},"lng":{"type":"number"},"created_at":{"type":"string"},"updated_at":{"type":"string"}}},"BeneficiaryApplication":{"type":"object","properties":{"id":{"type":"string"},"full_name":{"type":"string"},"relationship":{"type":"string"},"birth_date":{"type":"string"}}},"PidpDetailApplication":{"type":"object","properties":{"id":{"type":"string"},"license_no":{"type":"string"},"license_expiration_date":{"type":"string"},"card_type":{"type":"string"},"license_type":{"type":"string"},"restrictions":{"type":"string"},"is_single_pidp":{"type":"boolean"},"destinations":{"type":"string"}}},"PaynamicsInstruction":{"type":"object","properties":{"url":{"type":"string"},"body":{"type":"string"},"response_url":{"type":"string"},"cancel_url":{"type":"string"}}},"Product":{"type":"object","properties":{"id":{"type":"string"},"title":{"type":"string"},"info":{"type":"string"},"lowest_amount":{"type":"number"},"link":{"type":"string"},"is_pidp":{"type":"boolean"}}},"PartnerCategory":{"type":"object","properties":{"id":{"type":"string"},"name":{"type":"string"}}},"Partner":{"type":"object","properties":{"id":{"type":"string"},"title":{"type":"string"},"subtitle":{"type":"string"},"image_url":{"type":"string"},"url":{"type":"string"}}},"ApiResponse":{"type":"object","properties":{"code":{"type":"integer","format":"int32"},"type":{"type":"string"},"message":{"type":"string"}}},"UnprocessableEntityError":{"type":"object","properties":{"status":{"type":"string"},"code":{"type":"integer"},"message":{"type":"string"}},"example":{"status":"error | failure","code":2,"message":"Missing Parameter Error"}},"UnauthorizedError":{"type":"object","properties":{"status":{"type":"string"},"error":{"type":"string"}},"example":{"status":401,"error":"Unauthorized"}},"MissingParametersError":{"type":"object","properties":{"status":{"type":"string"},"errors":{"type":"array","items":{"type":"string"}}},"example":{"errors":["Error details"]}},"NotFoundError":{"type":"object","properties":{"status":{"type":"string"},"code":{"type":"integer"},"message":{"type":"string"}},"example":{"status":"error | failure","code":3,"message":"Not Found Error"}}},"securitySchemes":{"Authorization":{"type":"http","scheme":"bearer","bearerFormat":"JWT"}}}}