openapi: 3.0.3
info:
  title: 'ABYAN API Documentation'
  description: ''
  version: 1.0.0
servers:
  -
    url: 'https://api-dev.abyan.ph'
paths:
  /api/v1/address/regions:
    get:
      summary: 'Get Regions'
      operationId: getRegions
      description: 'Use this endpoint to get regions'
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: array
                items:
                  type: object
                example:
                  -
                    id: 1
                    psgcCode: '010000000'
                    regDesc: 'REGION I (ILOCOS REGION)'
                    regCode: '01'
                  -
                    id: 2
                    psgcCode: '020000000'
                    regDesc: 'REGION II (CAGAYAN VALLEY)'
                    regCode: '02'
                  -
                    id: 3
                    psgcCode: '030000000'
                    regDesc: 'REGION III (CENTRAL LUZON)'
                    regCode: '03'
                  -
                    id: 4
                    psgcCode: '040000000'
                    regDesc: 'REGION IV-A (CALABARZON)'
                    regCode: '04'
                  -
                    id: 5
                    psgcCode: '170000000'
                    regDesc: 'REGION IV-B (MIMAROPA)'
                    regCode: '17'
                  -
                    id: 6
                    psgcCode: '050000000'
                    regDesc: 'REGION V (BICOL REGION)'
                    regCode: '05'
                  -
                    id: 7
                    psgcCode: '060000000'
                    regDesc: 'REGION VI (WESTERN VISAYAS)'
                    regCode: '06'
                  -
                    id: 8
                    psgcCode: '070000000'
                    regDesc: 'REGION VII (CENTRAL VISAYAS)'
                    regCode: '07'
                  -
                    id: 9
                    psgcCode: '080000000'
                    regDesc: 'REGION VIII (EASTERN VISAYAS)'
                    regCode: '08'
                  -
                    id: 10
                    psgcCode: '090000000'
                    regDesc: 'REGION IX (ZAMBOANGA PENINSULA)'
                    regCode: '09'
                  -
                    id: 11
                    psgcCode: '100000000'
                    regDesc: 'REGION X (NORTHERN MINDANAO)'
                    regCode: '10'
                  -
                    id: 12
                    psgcCode: '110000000'
                    regDesc: 'REGION XI (DAVAO REGION)'
                    regCode: '11'
                  -
                    id: 13
                    psgcCode: '120000000'
                    regDesc: 'REGION XII (SOCCSKSARGEN)'
                    regCode: '12'
                  -
                    id: 14
                    psgcCode: '130000000'
                    regDesc: 'NATIONAL CAPITAL REGION (NCR)'
                    regCode: '13'
                  -
                    id: 15
                    psgcCode: '140000000'
                    regDesc: 'CORDILLERA ADMINISTRATIVE REGION (CAR)'
                    regCode: '14'
                  -
                    id: 16
                    psgcCode: '150000000'
                    regDesc: 'AUTONOMOUS REGION IN MUSLIM MINDANAO (ARMM)'
                    regCode: '15'
                  -
                    id: 17
                    psgcCode: '160000000'
                    regDesc: 'REGION XIII (Caraga)'
                    regCode: '16'
      tags:
        - Address
      security: []
  '/api/v1/address/provinces/{regCode}':
    get:
      summary: 'Get Provinces'
      operationId: getProvinces
      description: 'Use this endpoint to get provinces'
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: array
                items:
                  type: object
                example: []
      tags:
        - Address
      security: []
    parameters:
      -
        in: path
        name: regCode
        description: ''
        example: nobis
        required: true
        schema:
          type: string
  '/api/v1/address/cities/{provCode}':
    get:
      summary: 'Get Cities'
      operationId: getCities
      description: 'Use this endpoint to get cities'
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: array
                items:
                  type: object
                example: []
      tags:
        - Address
      security: []
    parameters:
      -
        in: path
        name: provCode
        description: ''
        example: sapiente
        required: true
        schema:
          type: string
  '/api/v1/address/barangays/{citymunCode}':
    get:
      summary: 'Get Barangays'
      operationId: getBarangays
      description: 'Use this endpoint to get barangays'
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: array
                items:
                  type: object
                example: []
      tags:
        - Address
      security: []
    parameters:
      -
        in: path
        name: citymunCode
        description: ''
        example: officia
        required: true
        schema:
          type: string
  /api/v1/admin/details:
    get:
      summary: 'Admin details'
      operationId: adminDetails
      description: 'Use this endpoint to get admin details'
      parameters: []
      responses:
        200:
          description: success
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Request was successful.'
                properties:
                  message:
                    type: string
                    example: 'Request was successful.'
      tags:
        - Administrator
  /api/v1/admin/role:
    post:
      summary: 'Create Role'
      operationId: createRole
      description: "<small class=\"badge badge-darkred\">Super Administrator only!</small>\n\nUse this endpoint to create a role"
      parameters: []
      responses:
        200:
          description: success
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Request was successful.'
                properties:
                  message:
                    type: string
                    example: 'Request was successful.'
      tags:
        - Administrator
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                role:
                  type: string
                  description: 'Must not be greater than 50 characters.'
                  example: oyoznhcore
              required:
                - role
    delete:
      summary: 'Remove Role'
      operationId: removeRole
      description: "<small class=\"badge badge-darkred\">Super Administrator only!</small>\n\nUse this endpoint to remove a role"
      parameters: []
      responses:
        200:
          description: success
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Request was successful.'
                properties:
                  message:
                    type: string
                    example: 'Request was successful.'
      tags:
        - Administrator
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                role:
                  type: string
                  description: 'Must not be greater than 50 characters.'
                  example: sempnljv
              required:
                - role
    get:
      summary: 'Get Roles'
      operationId: getRoles
      description: "<small class=\"badge badge-darkred\">Super Administrator only!</small>\n\nUse this endpoint to get all roles"
      parameters: []
      responses:
        200:
          description: success
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Request was successful.'
                properties:
                  message:
                    type: string
                    example: 'Request was successful.'
      tags:
        - Administrator
  /api/v1/admin/role/permissions:
    get:
      summary: 'Get Permissions'
      operationId: getPermissions
      description: "<small class=\"badge badge-darkred\">Super Administrator only!</small>\n\nUse this endpoint to get all permissions"
      parameters: []
      responses:
        200:
          description: success
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Request was successful.'
                properties:
                  message:
                    type: string
                    example: 'Request was successful.'
      tags:
        - Administrator
    post:
      summary: 'Assign a Permissions to a Role'
      operationId: assignAPermissionsToARole
      description: "<small class=\"badge badge-darkred\">Super Administrator only!</small>\n\nGrant the given permission(s) to a role."
      parameters: []
      responses:
        200:
          description: success
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Request was successful.'
                properties:
                  message:
                    type: string
                    example: 'Request was successful.'
      tags:
        - Administrator
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                permissions:
                  type: array
                  description: ''
                  example:
                    - []
                  items:
                    type: object
                    properties:
                      name:
                        type: string
                        description: ''
                        example: illum
                    required:
                      - name
                role:
                  type: string
                  description: ''
                  example: laboriosam
              required:
                - permissions
                - role
    delete:
      summary: 'Remove Permissions from a Role'
      operationId: removePermissionsFromARole
      description: "<small class=\"badge badge-darkred\">Super Administrator only!</small>\n\nRevoke the given permission(s)."
      parameters: []
      responses:
        200:
          description: success
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Request was successful.'
                properties:
                  message:
                    type: string
                    example: 'Request was successful.'
      tags:
        - Administrator
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                permissions:
                  type: array
                  description: ''
                  example:
                    - []
                  items:
                    type: object
                    properties:
                      name:
                        type: string
                        description: ''
                        example: vel
                    required:
                      - name
                role:
                  type: string
                  description: ''
                  example: placeat
              required:
                - permissions
                - role
  /api/v1/admin/role/permissions/sync:
    post:
      summary: 'Sync Permissions to a Role'
      operationId: syncPermissionsToARole
      description: "<small class=\"badge badge-darkred\">Super Administrator only!</small>\n\nRemove all current permissions and set the given ones."
      parameters: []
      responses:
        200:
          description: success
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Request was successful.'
                properties:
                  message:
                    type: string
                    example: 'Request was successful.'
      tags:
        - Administrator
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                permissions:
                  type: array
                  description: ''
                  example:
                    - []
                  items:
                    type: object
                    properties:
                      name:
                        type: string
                        description: ''
                        example: aspernatur
                    required:
                      - name
                role:
                  type: string
                  description: ''
                  example: amet
              required:
                - permissions
                - role
  /api/v1/admin/role/roles-permissions:
    get:
      summary: 'Get Roles with Permission'
      operationId: getRolesWithPermission
      description: "<small class=\"badge badge-darkred\">Super Administrator only!</small>\n\nUse this endpoint to get all roles and permissions"
      parameters: []
      responses:
        200:
          description: success
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Request was successful.'
                properties:
                  message:
                    type: string
                    example: 'Request was successful.'
      tags:
        - Administrator
  /api/v1/admin/role/user:
    post:
      summary: 'Assign a Role to a User'
      operationId: assignARoleToAUser
      description: "<small class=\"badge badge-darkred\">Super Administrator only!</small>\n\nUse this endpoint to assigns roles to users"
      parameters: []
      responses:
        200:
          description: success
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Request was successful.'
                properties:
                  message:
                    type: string
                    example: 'Request was successful.'
      tags:
        - Administrator
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                email:
                  type: string
                  description: 'Must be a valid email address.'
                  example: lbogan@example.com
                role:
                  type: string
                  description: ''
                  example: in
              required:
                - email
                - role
  /api/v1/admin/users:
    get:
      summary: Users
      operationId: users
      description: 'Use this endpoint to get list of users'
      parameters: []
      responses:
        200:
          description: success
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Request was successful.'
                properties:
                  message:
                    type: string
                    example: 'Request was successful.'
      tags:
        - Administrator
    post:
      summary: 'Create User'
      operationId: createUser
      description: 'Use this endpoint to create new user.'
      parameters: []
      responses: {  }
      tags:
        - Administrator
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                name:
                  type: string
                  description: ''
                  example: eveniet
                email:
                  type: string
                  description: 'Must be a valid email address.'
                  example: gorczany.alexane@example.net
                password:
                  type: string
                  description: 'Must be at least 6 characters.'
                  example: 'm!C,e4dE`\K*'
              required:
                - name
                - email
                - password
      security: []
  '/api/v1/admin/users/{id}':
    get:
      summary: 'Show admin details'
      operationId: showAdminDetails
      description: 'Use this endpoint to get admin details'
      parameters: []
      responses:
        200:
          description: success
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Request was successful.'
                properties:
                  message:
                    type: string
                    example: 'Request was successful.'
      tags:
        - Administrator
    put:
      summary: 'Update User'
      operationId: updateUser
      description: 'Use this endpoint to update user information'
      parameters: []
      responses:
        200:
          description: success
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Request was successful.'
                properties:
                  message:
                    type: string
                    example: 'Request was successful.'
      tags:
        - Administrator
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                name:
                  type: string
                  description: ''
                  example: velit
                email:
                  type: string
                  description: 'Must be a valid email address.'
                  example: kirstin.ruecker@example.com
                password:
                  type: string
                  description: 'Must be at least 6 characters.'
                  example: '*Sx_C%f,Q|-'
                status:
                  type: string
                  description: ''
                  example: active
                  enum:
                    - active
                    - inactive
              required:
                - name
                - status
    parameters:
      -
        in: path
        name: id
        description: 'The ID of the user.'
        example: facilis
        required: true
        schema:
          type: string
  /api/v1/admin/riders:
    get:
      summary: Riders
      operationId: riders
      description: 'Use this endpoint to get list of riders'
      parameters:
        -
          in: query
          name: 'filter[status.riderStatus]'
          description: 'Search any.'
          example: active
          required: true
          schema:
            type: string
            description: 'Search any.'
            example: active
      responses:
        200:
          description: success
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Request was successful.'
                properties:
                  message:
                    type: string
                    example: 'Request was successful.'
      tags:
        - Administrator
  /api/v1/admin/update-riders-status:
    post:
      summary: 'Update Riders Status'
      operationId: updateRidersStatus
      description: 'Use this endpoint to update riders status'
      parameters: []
      responses:
        200:
          description: success
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Request was successful.'
                properties:
                  message:
                    type: string
                    example: 'Request was successful.'
      tags:
        - Administrator
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                riders:
                  type: array
                  description: ''
                  example:
                    - []
                  items:
                    type: object
                    properties:
                      riderUsername:
                        type: string
                        description: ''
                        example: et
                    required:
                      - riderUsername
                status:
                  type: string
                  description: ''
                  example: sick
                  enum:
                    - active
                    - inactive
                    - sick
                    - vacation
                    - terminated
                    - suspended
              required:
                - riders
                - status
  /api/v1/admin/deliveries:
    get:
      summary: Deliveries
      operationId: deliveries
      description: 'Use this endpoint to get list of deliveries'
      parameters:
        -
          in: query
          name: 'filter[deliveryStatus.deliveryStatus]'
          description: 'Search any.'
          example: '01 paid'
          required: true
          schema:
            type: string
            description: 'Search any.'
            example: '01 paid'
        -
          in: query
          name: 'filter[targetPickup]'
          description: 'Search any.'
          example: '2024-09-23'
          required: true
          schema:
            type: string
            description: 'Search any.'
            example: '2024-09-23'
        -
          in: query
          name: 'filter[referenceId]'
          description: 'Search any.'
          example: DLS1724406945
          required: true
          schema:
            type: string
            description: 'Search any.'
            example: DLS1724406945
      responses:
        200:
          description: success
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Request was successful.'
                properties:
                  message:
                    type: string
                    example: 'Request was successful.'
      tags:
        - Administrator
  /api/v1/admin/delivery/statuses:
    get:
      summary: 'Get Delivery Status Codes'
      operationId: getDeliveryStatusCodes
      description: 'Use this endpoint to get the list of delivery status codes'
      parameters: []
      responses:
        200:
          description: success
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Request was successful.'
                properties:
                  message:
                    type: string
                    example: 'Request was successful.'
      tags:
        - Administrator
  /api/v1/admin/update-deliveries-status:
    post:
      summary: 'Update Deliveries Status'
      operationId: updateDeliveriesStatus
      description: 'Use this endpoint to update deliveries status'
      parameters: []
      responses:
        200:
          description: success
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Request was successful.'
                properties:
                  message:
                    type: string
                    example: 'Request was successful.'
      tags:
        - Administrator
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                deliveries:
                  type: array
                  description: 'Must not have more than 20 items.'
                  example:
                    - []
                  items:
                    type: object
                    properties:
                      transactionReferenceNumber:
                        type: string
                        description: 'Must not be greater than 100 characters.'
                        example: rd
                    required:
                      - transactionReferenceNumber
                deliveryStatus:
                  type: string
                  description: ''
                  example: '09 received'
                  enum:
                    - '09 received'
                    - '10 not received'
                    - '42 return to lto'
                    - '30 delivered'
              required:
                - deliveries
                - deliveryStatus
  /api/v1/admin/sequence-deliveries:
    post:
      summary: 'Execute the Batch and Sequence Deliveries Job'
      operationId: executeTheBatchAndSequenceDeliveriesJob
      description: 'Use this endpoint to batch and sequence the deliveries.'
      parameters: []
      responses:
        200:
          description: success
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Request was successful.'
                properties:
                  message:
                    type: string
                    example: 'Request was successful.'
      tags:
        - Administrator
      requestBody:
        required: false
        content:
          application/json:
            schema:
              type: object
              properties:
                date:
                  type: string
                  description: 'Must be a valid date in the format <code>Y-m-d</code>.'
                  example: '2025-07-10'
  /api/v1/admin/unassign-deliveries:
    get:
      summary: 'Unassign Deliveries'
      operationId: unassignDeliveries
      description: 'Use this endpoint to get list of unassign deliveries'
      parameters: []
      responses:
        200:
          description: success
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Request was successful.'
                properties:
                  message:
                    type: string
                    example: 'Request was successful.'
      tags:
        - Administrator
  /api/v1/admin/assigned-deliveries:
    get:
      summary: 'Assigned Deliveries'
      operationId: assignedDeliveries
      description: 'Use this endpoint to get list of assigned deliveries'
      parameters: []
      responses:
        200:
          description: success
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Request was successful.'
                properties:
                  message:
                    type: string
                    example: 'Request was successful.'
      tags:
        - Administrator
  /api/v1/admin/assigns-riders:
    post:
      summary: 'Assigns Deliveries to a Rider'
      operationId: assignsDeliveriesToARider
      description: 'Use this endpoint to assigns deliveries to a rider'
      parameters: []
      responses:
        200:
          description: success
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Request was successful.'
                properties:
                  message:
                    type: string
                    example: 'Request was successful.'
      tags:
        - Administrator
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                fromRiderUsername:
                  type: string
                  description: ''
                  example: qui
                deliveryIds:
                  type: string
                  description: ''
                  example: culpa
                toRiderUsername:
                  type: string
                  description: ''
                  example: sapiente
              required:
                - fromRiderUsername
                - deliveryIds
                - toRiderUsername
  /api/v1/admin/deliveries/count:
    get:
      summary: 'Deliveries Count'
      operationId: deliveriesCount
      description: 'Use this endpoint to get the deliveries count.'
      parameters: []
      responses:
        200:
          description: success
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Request was successful.'
                properties:
                  message:
                    type: string
                    example: 'Request was successful.'
      tags:
        - Administrator
  /api/v1/admin/riders/count:
    get:
      summary: 'Riders Count'
      operationId: ridersCount
      description: 'Use this endpoint to get the riders count.'
      parameters: []
      responses:
        200:
          description: success
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Request was successful.'
                properties:
                  message:
                    type: string
                    example: 'Request was successful.'
      tags:
        - Administrator
  /api/v1/admin/revenue/count:
    get:
      summary: 'Revenue Count'
      operationId: revenueCount
      description: 'Use this endpoint to get the revenue count.'
      parameters: []
      responses:
        200:
          description: success
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Request was successful.'
                properties:
                  message:
                    type: string
                    example: 'Request was successful.'
      tags:
        - Administrator
  /api/v1/admin/payment/count:
    get:
      summary: 'Payment Count'
      operationId: paymentCount
      description: 'Use this endpoint to get the payment count.'
      parameters: []
      responses:
        200:
          description: success
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Request was successful.'
                properties:
                  message:
                    type: string
                    example: 'Request was successful.'
      tags:
        - Administrator
  /api/v1/admin/status-sms:
    get:
      summary: 'Display a listing of the status SMS.'
      operationId: displayAListingOfTheStatusSMS
      description: ''
      parameters: []
      responses:
        401:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: Unauthenticated.
                properties:
                  message:
                    type: string
                    example: Unauthenticated.
      tags:
        - Administrator
    post:
      summary: 'Store a newly created status SMS.'
      operationId: storeANewlyCreatedStatusSMS
      description: ''
      parameters: []
      responses: {  }
      tags:
        - Administrator
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                statusValue:
                  type: string
                  description: ''
                  example: beatae
                statusText:
                  type: string
                  description: ''
                  example: voluptatibus
                status:
                  type: string
                  description: ''
                  example: inactive
                  enum:
                    - active
                    - inactive
              required:
                - statusValue
                - statusText
                - status
  '/api/v1/admin/status-sms/{id}':
    get:
      summary: 'Display the specified status SMS.'
      operationId: displayTheSpecifiedStatusSMS
      description: ''
      parameters: []
      responses:
        401:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: Unauthenticated.
                properties:
                  message:
                    type: string
                    example: Unauthenticated.
      tags:
        - Administrator
    put:
      summary: 'Update the specified status SMS.'
      operationId: updateTheSpecifiedStatusSMS
      description: ''
      parameters: []
      responses: {  }
      tags:
        - Administrator
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                statusValue:
                  type: string
                  description: ''
                  example: architecto
                statusText:
                  type: string
                  description: 'Ensure uniqueness excluding current record.'
                  example: odit
                status:
                  type: string
                  description: ''
                  example: inactive
                  enum:
                    - active
                    - inactive
              required:
                - statusValue
                - statusText
                - status
    delete:
      summary: 'Remove the specified status SMS.'
      operationId: removeTheSpecifiedStatusSMS
      description: ''
      parameters: []
      responses: {  }
      tags:
        - Administrator
    parameters:
      -
        in: path
        name: id
        description: 'The ID of the status sm.'
        example: voluptates
        required: true
        schema:
          type: string
  /api/v1/admin/reconciliation/settlement/upload_dayon_file:
    post:
      summary: 'Dayon Settlement'
      operationId: dayonSettlement
      description: 'Use this endpoint to upload a file for the dayon settlement'
      parameters: []
      responses:
        200:
          description: success
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Request was successful.'
                properties:
                  message:
                    type: string
                    example: 'Request was successful.'
      tags:
        - Administrator
      requestBody:
        required: true
        content:
          multipart/form-data:
            schema:
              type: object
              properties:
                file:
                  type: string
                  format: binary
                  description: 'Must be a file. Must not be greater than 10240 kilobytes.'
              required:
                - file
  /api/v1/admin/reconciliation/manual-reconciliation:
    post:
      summary: 'Manual Reconciliation'
      operationId: manualReconciliation
      description: 'Use this endpoint to manual reconciliation'
      parameters: []
      responses:
        200:
          description: success
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Request was successful.'
                properties:
                  message:
                    type: string
                    example: 'Request was successful.'
      tags:
        - Administrator
  /api/v1/admin/reconciliation/report:
    get:
      summary: 'Reconciliation Report'
      operationId: reconciliationReport
      description: 'Use this endpoint to get the reconciliation report'
      parameters:
        -
          in: query
          name: 'filter[referenceId]'
          description: 'Search any.'
          example: '172551802425'
          required: true
          schema:
            type: string
            description: 'Search any.'
            example: '172551802425'
        -
          in: query
          name: 'filter[pickupBetween]'
          description: 'Search any.'
          example: '2024-09-28,2024-10-17'
          required: true
          schema:
            type: string
            description: 'Search any.'
            example: '2024-09-28,2024-10-17'
        -
          in: query
          name: 'filter[reconcileStatus]'
          description: 'Search any.'
          example: Reconciled
          required: true
          schema:
            type: string
            description: 'Search any.'
            example: Reconciled
      responses:
        200:
          description: success
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Request was successful.'
                properties:
                  message:
                    type: string
                    example: 'Request was successful.'
      tags:
        - Administrator
  /api/v1/admin/reconciliation/export-report:
    get:
      summary: 'Export Reconciliation Report'
      operationId: exportReconciliationReport
      description: 'Use this endpoint to export the reconciliation report'
      parameters: []
      responses:
        401:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: Unauthenticated.
                properties:
                  message:
                    type: string
                    example: Unauthenticated.
      tags:
        - Administrator
  /api/v1/auth/register-rider:
    post:
      summary: 'Register Rider'
      operationId: registerRider
      description: 'Use this endpoint to register rider.'
      parameters: []
      responses: {  }
      tags:
        - Authentication
      requestBody:
        required: true
        content:
          multipart/form-data:
            schema:
              type: object
              properties:
                username:
                  type: string
                  description: ''
                  example: sit
                password:
                  type: string
                  description: 'Must be at least 8 characters.'
                  example: 'pC[Wal['
                nameFirst:
                  type: string
                  description: ''
                  example: nobis
                nameLast:
                  type: string
                  description: ''
                  example: voluptatibus
                phoneMobile:
                  type: string
                  description: ''
                  example: rerum
                phoneOther:
                  type: string
                  description: ''
                  example: sit
                vehicleId:
                  type: string
                  description: ''
                  example: quos
                riderImage:
                  type: string
                  format: binary
                  description: 'Must be an image. Must not be greater than 2048 kilobytes.'
              required:
                - username
                - password
                - nameFirst
                - nameLast
                - phoneMobile
                - vehicleId
                - riderImage
      security: []
  /api/v1/auth/login-rider:
    post:
      summary: 'Login Rider'
      operationId: loginRider
      description: 'Use this endpoint to login rider.'
      parameters: []
      responses: {  }
      tags:
        - Authentication
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                username:
                  type: string
                  description: ''
                  example: sint
                password:
                  type: string
                  description: ''
                  example: 'dxh?thr~\YMh'
              required:
                - username
                - password
      security: []
  /api/v1/auth/logout-rider:
    post:
      summary: 'Rider Logout'
      operationId: riderLogout
      description: 'Use this endpoint to logout rider.'
      parameters: []
      responses: {  }
      tags:
        - Authentication
  /api/v1/auth/login-admin:
    post:
      summary: 'Admin Login'
      operationId: adminLogin
      description: 'Use this endpoint to login admin.'
      parameters: []
      responses: {  }
      tags:
        - Authentication
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                email:
                  type: string
                  description: 'Must be a valid email address.'
                  example: euna.cruickshank@example.org
                password:
                  type: string
                  description: ''
                  example: architecto
              required:
                - email
                - password
      security: []
  /api/v1/auth/login-dispatcher:
    post:
      summary: 'Dispatcher Login'
      operationId: dispatcherLogin
      description: 'Use this endpoint to login dispatcher.'
      parameters: []
      responses: {  }
      tags:
        - Authentication
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                email:
                  type: string
                  description: 'Must be a valid email address.'
                  example: judy36@example.net
                password:
                  type: string
                  description: ''
                  example: aut
              required:
                - email
                - password
      security: []
  /api/v1/auth/logout:
    post:
      summary: Logout
      operationId: logout
      description: 'Use this endpoint to logout.'
      parameters: []
      responses: {  }
      tags:
        - Authentication
  /api/partners/v1/oauth2/token:
    post:
      summary: 'Generate access token'
      operationId: generateAccessToken
      description: "Use this endpoint to generate access token using\nyour client id and client secret"
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Request was successful.'
                  details:
                    access_token: eyJraWQiOiJJNnYxOTZKVUFncVl...
                    expires_in: 3600
                    token_type: Bearer
                properties:
                  message:
                    type: string
                    example: 'Request was successful.'
                  details:
                    type: object
                    properties:
                      access_token:
                        type: string
                        example: eyJraWQiOiJJNnYxOTZKVUFncVl...
                      expires_in:
                        type: integer
                        example: 3600
                      token_type:
                        type: string
                        example: Bearer
      tags:
        - Authentication
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                grant_type:
                  type: string
                  description: client_credentials.
                  example: client_credentials
                client_id:
                  type: string
                  description: 'Your client id.'
                  example: 6j3mj13bmntioepd0o622ed2g4
                client_secret:
                  type: string
                  description: 'Your client secret.'
                  example: c915on174ls8dq9el5ljuqi696fckntqgqn0k4t1p753ursfrac
                scope:
                  type: string
                  description: 'Your scope.'
                  example: delivery
              required:
                - grant_type
                - client_id
                - client_secret
                - scope
      security: []
  /api/partners/v1/order-via-xendit:
    post:
      summary: "Xendit Checkout delivery order.\n\nUse this endpoint to checkout delivery order with xendit payment gateway."
      operationId: xenditCheckoutDeliveryOrderUseThisEndpointToCheckoutDeliveryOrderWithXenditPaymentGateway
      description: ''
      parameters: []
      responses:
        200:
          description: success
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Request was successful.'
                properties:
                  message:
                    type: string
                    example: 'Request was successful.'
      tags:
        - Checkout
      requestBody:
        required: true
        content:
          multipart/form-data:
            schema:
              type: object
              properties:
                requestReferenceNumber:
                  type: string
                  description: ''
                  example: illum
                valid_id1:
                  type: string
                  format: binary
                  description: 'Must be an image. Must not be greater than 2048 kilobytes.'
                valid_id2:
                  type: string
                  format: binary
                  description: 'Must be an image. Must not be greater than 2048 kilobytes.'
                shippingDetail:
                  type: object
                  description: ''
                  example: []
                  properties:
                    nameLast:
                      type: string
                      description: ''
                      example: vitae
                    nameFirst:
                      type: string
                      description: ''
                      example: dicta
                    nameMiddle:
                      type: string
                      description: ''
                      example: culpa
                    nameSuffix:
                      type: string
                      description: ''
                      example: et
                    phoneMobile:
                      type: string
                      description: ''
                      example: est
                    phoneOther:
                      type: string
                      description: ''
                      example: et
                    emailAddress:
                      type: string
                      description: 'Must be a valid email address.'
                      example: shana.shanahan@example.com
                    region:
                      type: string
                      description: ''
                      example: est
                    province:
                      type: string
                      description: ''
                      example: repellat
                    municity:
                      type: string
                      description: ''
                      example: adipisci
                    barangay:
                      type: string
                      description: ''
                      example: soluta
                    address1:
                      type: string
                      description: ''
                      example: delectus
                    address2:
                      type: string
                      description: ''
                      example: cumque
                    postalCode:
                      type: string
                      description: ''
                      example: ad
                    latitude:
                      type: string
                      description: ''
                      example: earum
                    longitude:
                      type: string
                      description: ''
                      example: non
                items:
                  type: array
                  description: ''
                  example:
                    - []
                  items:
                    type: object
                    properties:
                      name:
                        type: string
                        description: ''
                        example: excepturi
                      quantity:
                        type: integer
                        description: ''
                        example: 12
                      type:
                        type: string
                        description: ''
                        example: plate
                        enum:
                          - plate
                          - license
                      code:
                        type: string
                        description: ''
                        example: minima
                      description:
                        type: string
                        description: ''
                        example: 'Dolorum quidem accusantium eos.'
                      amount:
                        type: number
                        description: ''
                        example: 3649192.0
                    required:
                      - name
                      - quantity
                      - type
                      - amount
                redirectUrl:
                  type: object
                  description: ''
                  example: []
                  properties:
                    success:
                      type: string
                      description: ''
                      example: et
                    failure:
                      type: string
                      description: ''
                      example: voluptatem
                    cancel:
                      type: string
                      description: ''
                      example: numquam
              required:
                - requestReferenceNumber
                - valid_id1
                - valid_id2
                - items
  /api/partners/v1/delivery/inquire:
    post:
      summary: 'Inquire delivery order'
      operationId: inquireDeliveryOrder
      description: 'Use this endpoint to inquire deliver order'
      parameters: []
      responses:
        200:
          description: ''
          content:
            text/plain:
              schema:
                type: string
                example: "{\n        \"message\": \"Request was successful.\",\n        \"details\": {\n            \"courier_fee\": 150,\n            \"price_reference\": P1234567789\n        }\n    }"
      tags:
        - Delivery
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                sender:
                  type: 'Sender Details'
                  description: ''
                  example: ''
                receiver:
                  type: 'Receiver Details'
                  description: ''
                  example: ''
                transactable_type:
                  type: 'Transactable Type'
                  description: ''
                  example: ''
              required:
                - sender
                - receiver
                - transactable_type
  /api/partners/v1/delivery/create:
    post:
      summary: 'Create delivery order'
      operationId: createDeliveryOrder
      description: 'Use this endpoint to create deliver order'
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Request was successful.'
                  details:
                    client_reference_number: P143-36EG-DY11
                    reference_number: DLS1724406945
                    status: '02 booked'
                    tracking_url: 'https://delivery.dev.abyan.ph/track/DLS1724406945'
                    waybill_url: 'https://sls-laravel-lto-delivery-api-dev-storage-private.s3.ap-southeast-1.amazonaws.com/waybill/P143-36EG-DY11.pdf'
                properties:
                  message:
                    type: string
                    example: 'Request was successful.'
                  details:
                    type: object
                    properties:
                      client_reference_number:
                        type: string
                        example: P143-36EG-DY11
                      reference_number:
                        type: string
                        example: DLS1724406945
                      status:
                        type: string
                        example: '02 booked'
                      tracking_url:
                        type: string
                        example: 'https://delivery.dev.abyan.ph/track/DLS1724406945'
                      waybill_url:
                        type: string
                        example: 'https://sls-laravel-lto-delivery-api-dev-storage-private.s3.ap-southeast-1.amazonaws.com/waybill/P143-36EG-DY11.pdf'
      tags:
        - Delivery
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                client_reference_number:
                  type: string
                  description: 'The client reference number provided by the partner corresponds to this transaction. Must not be greater than 100 characters. Must not be greater than 100 characters.'
                  example: P143-36EG-DY01
                sender:
                  type: 'Sender Details'
                  description: ''
                  example: ''
                receiver:
                  type: 'Receiver Details'
                  description: ''
                  example: ''
                webhook_url:
                  type: string
                  description: "The partner server's URL that is called for this webhook. Must not be greater than 255 characters."
                  example: 'https://partnersite.com/webhook/notify'
                price_reference:
                  type: string
                  description: ''
                  example: non
                transactable_type:
                  type: string
                  description: ''
                  example: "Driver's License"
                  enum:
                    - 'Plate Number'
                    - "Driver's License"
              required:
                - client_reference_number
                - sender
                - receiver
                - webhook_url
                - price_reference
                - transactable_type
  '/api/partners/v1/delivery/status/{reference_number}':
    get:
      summary: 'Check delivery order'
      operationId: checkDeliveryOrder
      description: 'Use this endpoint to check the status of a transaction given a reference number.'
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Request was successful.'
                  details:
                    client_reference_number: P143-36EG-DY11
                    reference_number: DLS1724406945
                    status: '02 booked'
                    tracking_url: 'https://delivery.dev.abyan.ph/track/DLS1724406945'
                    waybill_url: 'https://sls-laravel-lto-delivery-api-dev-storage-private.s3.ap-southeast-1.amazonaws.com/waybill/P143-36EG-DY11.pdf'
                properties:
                  message:
                    type: string
                    example: 'Request was successful.'
                  details:
                    type: object
                    properties:
                      client_reference_number:
                        type: string
                        example: P143-36EG-DY11
                      reference_number:
                        type: string
                        example: DLS1724406945
                      status:
                        type: string
                        example: '02 booked'
                      tracking_url:
                        type: string
                        example: 'https://delivery.dev.abyan.ph/track/DLS1724406945'
                      waybill_url:
                        type: string
                        example: 'https://sls-laravel-lto-delivery-api-dev-storage-private.s3.ap-southeast-1.amazonaws.com/waybill/P143-36EG-DY11.pdf'
      tags:
        - Delivery
    parameters:
      -
        in: path
        name: reference_number
        description: ''
        example: DLS1724406945
        required: true
        schema:
          type: 'Tracking reference number, corresponding to the create order transaction.'
  /api/partners/v1/delivery/notify:
    post:
      summary: 'For Pickup Notification'
      operationId: forPickupNotification
      description: 'Allows partner to notify the system when an item is ready for pickup.'
      parameters: []
      responses:
        204:
          description: ''
      tags:
        - Delivery
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                reference_numbers:
                  type: array
                  description: 'Each reference number within the array. Must be a string.'
                  example:
                    - animi
                  items:
                    type: string
              required:
                - reference_numbers
  /api/partners/v1/delivery/test-webhook:
    post:
      summary: 'Test Webhook Call'
      operationId: testWebhookCall
      description: 'Allows partner to test the webhook call'
      parameters: []
      responses:
        200:
          description: ''
          content:
            text/plain:
              schema:
                type: string
                example: ''
      tags:
        - Delivery
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                webhook_url:
                  type: string
                  description: "The partner server's URL that is called for this webhook. Must be a valid URL."
                  example: 'https://partnersite.com/webhook/notify'
                payload:
                  type: array
                  description: 'An array of objects, each containing details about a specific transaction or update.'
                  example:
                    -
                      client_reference_number: '12345'
                      reference_number: ABCDE12345
                      status: '30 delivered'
                      tracking_url: 'https://tracking.com/track/ABCDE12345'
                      waybill_url: 'https://waybill.com/waybill/ABCDE12345.pdf'
                    -
                      client_reference_number: '67890'
                      reference_number: FGHIJ67890
                      status: '30 delivered'
                      tracking_url: 'https://tracking.com/track/FGHIJ67890'
                      waybill_url: 'https://waybill.com/waybill/FGHIJ67890.pdf'
                  items:
                    type: object
                    properties:
                      client_reference_number:
                        type: string
                        description: 'A unique identifier provided by the client for each transaction. Must not be greater than 255 characters.'
                        example: '12345'
                      reference_number:
                        type: string
                        description: 'The internal reference number associated with the transaction. Must not be greater than 255 characters.'
                        example: ABCDE12345
                      status:
                        type: string
                        description: 'The current status of the transaction.'
                        example: '30 delivered'
                        enum:
                          - '08 assigned'
                          - '09 received'
                          - '10 not received'
                          - '11 picked up'
                          - '12 not picked up'
                          - '20 out for delivery'
                          - '30 delivered'
                          - '40 not delivered'
                          - '41 return to dispatcher'
                          - '42 return to lto'
                      tracking_url:
                        type: string
                        description: 'The URL where the client can track the shipment.'
                        example: 'https://tracking.com/track/ABCDE12345'
                      waybill_url:
                        type: string
                        description: 'The URL to access the waybill associated with the shipment.'
                        example: 'https://waybill.com/waybill/ABCDE12345.pdf'
                    required:
                      - client_reference_number
                      - reference_number
                      - status
              required:
                - webhook_url
                - payload
  /api/v1/dispatcher/details:
    get:
      summary: 'Dispatcher details'
      operationId: dispatcherDetails
      description: 'Use this endpoint to get dispatcher details'
      parameters: []
      responses:
        200:
          description: success
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Request was successful.'
                properties:
                  message:
                    type: string
                    example: 'Request was successful.'
      tags:
        - Dispatcher
  /api/v1/dispatcher/deliveries:
    get:
      summary: Deliveries
      operationId: deliveries
      description: 'Use this endpoint to get list of deliveries'
      parameters:
        -
          in: query
          name: 'filter[deliveryStatus.deliveryStatus]'
          description: 'Search any.'
          example: '01 paid'
          required: true
          schema:
            type: string
            description: 'Search any.'
            example: '01 paid'
        -
          in: query
          name: 'filter[targetPickup]'
          description: 'Search any.'
          example: '2024-09-23'
          required: true
          schema:
            type: string
            description: 'Search any.'
            example: '2024-09-23'
        -
          in: query
          name: 'filter[referenceId]'
          description: 'Search any.'
          example: DLS1724406945
          required: true
          schema:
            type: string
            description: 'Search any.'
            example: DLS1724406945
      responses:
        200:
          description: success
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Request was successful.'
                properties:
                  message:
                    type: string
                    example: 'Request was successful.'
      tags:
        - Dispatcher
  /api/v1/dispatcher/delivery/statuses:
    get:
      summary: 'Get Delivery Status Codes'
      operationId: getDeliveryStatusCodes
      description: 'Use this endpoint to get the list of delivery status codes'
      parameters: []
      responses:
        200:
          description: success
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Request was successful.'
                properties:
                  message:
                    type: string
                    example: 'Request was successful.'
      tags:
        - Dispatcher
  /api/v1/dispatcher/update-deliveries-status:
    post:
      summary: 'Update Deliveries Status'
      operationId: updateDeliveriesStatus
      description: 'Use this endpoint to update deliveries status'
      parameters: []
      responses:
        200:
          description: success
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Request was successful.'
                properties:
                  message:
                    type: string
                    example: 'Request was successful.'
      tags:
        - Dispatcher
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                deliveries:
                  type: array
                  description: 'Must not have more than 20 items.'
                  example:
                    - []
                  items:
                    type: object
                    properties:
                      transactionReferenceNumber:
                        type: string
                        description: 'Must not be greater than 100 characters.'
                        example: piobkwndjhfuaxakuxxzoxy
                    required:
                      - transactionReferenceNumber
                deliveryStatus:
                  type: string
                  description: ''
                  example: '30 delivered'
                  enum:
                    - '09 received'
                    - '10 not received'
                    - '42 return to lto'
                    - '30 delivered'
              required:
                - deliveries
                - deliveryStatus
  /api/v1/rider/details:
    get:
      summary: 'Rider details'
      operationId: riderDetails
      description: 'Use this endpoint to get rider details'
      parameters: []
      responses:
        200:
          description: success
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Request was successful.'
                properties:
                  message:
                    type: string
                    example: 'Request was successful.'
      tags:
        - Riders
  /api/v1/rider/accept-delivery:
    post:
      summary: 'Accept Delivery'
      operationId: acceptDelivery
      description: 'Use this endpoint to accept the delivery request'
      parameters: []
      responses:
        200:
          description: success
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Request was successful.'
                properties:
                  message:
                    type: string
                    example: 'Request was successful.'
      tags:
        - Riders
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                requestReferenceNumber:
                  type: string
                  description: ''
                  example: autem
              required:
                - requestReferenceNumber
  /api/v1/rider/update-deliveries-status:
    post:
      summary: 'Update Deliveries'
      operationId: updateDeliveries
      description: "Use this endpoint to update the riders' deliveries status."
      parameters: []
      responses:
        200:
          description: success
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Request was successful.'
                properties:
                  message:
                    type: string
                    example: 'Request was successful.'
      tags:
        - Riders
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                deliveries:
                  type: array
                  description: 'Must not have more than 20 items.'
                  example:
                    - []
                  items:
                    type: object
                    properties:
                      transactionReferenceNumber:
                        type: string
                        description: 'Must not be greater than 100 characters.'
                        example: lexreanqrhmuov
                    required:
                      - transactionReferenceNumber
                deliveryStatus:
                  type: string
                  description: ''
                  example: '41 return to dispatcher'
                  enum:
                    - '11 picked up'
                    - '12 not picked up'
                    - '20 out for delivery'
                    - '30 delivered'
                    - '40 not delivered'
                    - '41 return to dispatcher'
              required:
                - deliveries
                - deliveryStatus
  /api/v1/rider/sequence-deliveries:
    post:
      summary: 'Sequence Deliveries'
      operationId: sequenceDeliveries
      description: "Use this endpoint to sequence the riders' deliveries."
      parameters: []
      responses:
        200:
          description: success
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Request was successful.'
                properties:
                  message:
                    type: string
                    example: 'Request was successful.'
      tags:
        - Riders
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                latitude:
                  type: string
                  description: 'Current Latitude.'
                  example: '14.5352'
                longitude:
                  type: string
                  description: 'Current Longitude.'
                  example: '120.9830'
              required:
                - latitude
                - longitude
  /api/v1/rider/queue-deliveries:
    get:
      summary: 'Queue Deliveries'
      operationId: queueDeliveries
      description: "Use this endpoint to get the riders' deliveries."
      parameters: []
      responses:
        200:
          description: success
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Request was successful.'
                properties:
                  message:
                    type: string
                    example: 'Request was successful.'
      tags:
        - Riders
  /api/v1/rider/switch-availability:
    post:
      summary: 'Rider Online Switch'
      operationId: riderOnlineSwitch
      description: "Use this endpoint to update the riders' availability status."
      parameters: []
      responses:
        200:
          description: success
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Request was successful.'
                properties:
                  message:
                    type: string
                    example: 'Request was successful.'
      tags:
        - Riders
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                availability:
                  type: string
                  description: ''
                  example: online
                  enum:
                    - online
                    - offline
              required:
                - availability
  /api/v1/admin/territories:
    get:
      summary: 'Get Territories'
      operationId: getTerritories
      description: 'Use this endpoint to get list of territories'
      parameters: []
      responses:
        200:
          description: success
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Request was successful.'
                properties:
                  message:
                    type: string
                    example: 'Request was successful.'
      tags:
        - Territory
    post:
      summary: 'Create Territory'
      operationId: createTerritory
      description: 'Use this endpoint to create new territory'
      parameters: []
      responses:
        200:
          description: success
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Request was successful.'
                properties:
                  message:
                    type: string
                    example: 'Request was successful.'
      tags:
        - Territory
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                territoryName:
                  type: string
                  description: 'Must not be greater than 255 characters.'
                  example: hkziwrm
                territoryStatus:
                  type: string
                  description: ''
                  example: active
                  enum:
                    - active
                    - inactive
              required:
                - territoryName
                - territoryStatus
  '/api/v1/admin/territories/{id}':
    get:
      summary: 'Get Territory details'
      operationId: getTerritoryDetails
      description: 'Use this endpoint to get the territory details'
      parameters: []
      responses:
        200:
          description: success
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Request was successful.'
                properties:
                  message:
                    type: string
                    example: 'Request was successful.'
      tags:
        - Territory
    put:
      summary: 'Update Territory'
      operationId: updateTerritory
      description: 'Use this endpoint to update the territory'
      parameters: []
      responses:
        200:
          description: success
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Request was successful.'
                properties:
                  message:
                    type: string
                    example: 'Request was successful.'
      tags:
        - Territory
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                territoryName:
                  type: string
                  description: 'Must not be greater than 255 characters.'
                  example: eftxrjrfooytynccr
                territoryStatus:
                  type: string
                  description: ''
                  example: inactive
                  enum:
                    - active
                    - inactive
              required:
                - territoryName
                - territoryStatus
    parameters:
      -
        in: path
        name: id
        description: 'The ID of the territory.'
        example: explicabo
        required: true
        schema:
          type: string
  '/api/v1/admin/territories/{territory_id}/rider-territories':
    get:
      summary: 'Display a listing of rider territories for a specific territory.'
      operationId: displayAListingOfRiderTerritoriesForASpecificTerritory
      description: ''
      parameters: []
      responses:
        401:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: Unauthenticated.
                properties:
                  message:
                    type: string
                    example: Unauthenticated.
      tags:
        - Territory
    post:
      summary: 'Store a newly created rider territory in a specific territory.'
      operationId: storeANewlyCreatedRiderTerritoryInASpecificTerritory
      description: ''
      parameters: []
      responses: {  }
      tags:
        - Territory
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                riderId:
                  type: string
                  description: ''
                  example: voluptatem
                areaStatus:
                  type: string
                  description: ''
                  example: active
                  enum:
                    - active
                    - inactive
              required:
                - riderId
                - areaStatus
    parameters:
      -
        in: path
        name: territory_id
        description: 'The ID of the territory.'
        example: 1
        required: true
        schema:
          type: integer
  '/api/v1/admin/territories/{territory_id}/rider-territories/{id}':
    get:
      summary: 'Display the specified rider territory for a specific territory.'
      operationId: displayTheSpecifiedRiderTerritoryForASpecificTerritory
      description: ''
      parameters: []
      responses:
        401:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: Unauthenticated.
                properties:
                  message:
                    type: string
                    example: Unauthenticated.
      tags:
        - Territory
    put:
      summary: 'Update the specified rider territory in a specific territory.'
      operationId: updateTheSpecifiedRiderTerritoryInASpecificTerritory
      description: ''
      parameters: []
      responses: {  }
      tags:
        - Territory
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                riderId:
                  type: string
                  description: ''
                  example: deserunt
                areaStatus:
                  type: string
                  description: ''
                  example: inactive
                  enum:
                    - active
                    - inactive
              required:
                - riderId
                - areaStatus
    parameters:
      -
        in: path
        name: territory_id
        description: 'The ID of the territory.'
        example: 1
        required: true
        schema:
          type: integer
      -
        in: path
        name: id
        description: 'The ID of the rider territory.'
        example: molestias
        required: true
        schema:
          type: string
  '/api/v1/admin/territories/{territory_id}/user-territories':
    get:
      summary: 'Display a listing of user territories for a specific territory.'
      operationId: displayAListingOfUserTerritoriesForASpecificTerritory
      description: ''
      parameters: []
      responses:
        401:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: Unauthenticated.
                properties:
                  message:
                    type: string
                    example: Unauthenticated.
      tags:
        - Territory
    post:
      summary: 'Store a newly created user territory in a specific territory.'
      operationId: storeANewlyCreatedUserTerritoryInASpecificTerritory
      description: ''
      parameters: []
      responses: {  }
      tags:
        - Territory
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                userId:
                  type: string
                  description: ''
                  example: aut
                areaStatus:
                  type: string
                  description: ''
                  example: inactive
                  enum:
                    - active
                    - inactive
              required:
                - userId
                - areaStatus
    parameters:
      -
        in: path
        name: territory_id
        description: 'The ID of the territory.'
        example: 1
        required: true
        schema:
          type: integer
  '/api/v1/admin/territories/{territory_id}/user-territories/{id}':
    get:
      summary: 'Display the specified user territory for a specific territory.'
      operationId: displayTheSpecifiedUserTerritoryForASpecificTerritory
      description: ''
      parameters: []
      responses:
        401:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: Unauthenticated.
                properties:
                  message:
                    type: string
                    example: Unauthenticated.
      tags:
        - Territory
    put:
      summary: 'Update the specified user territory in a specific territory.'
      operationId: updateTheSpecifiedUserTerritoryInASpecificTerritory
      description: ''
      parameters: []
      responses: {  }
      tags:
        - Territory
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                userId:
                  type: string
                  description: ''
                  example: similique
                areaStatus:
                  type: string
                  description: ''
                  example: inactive
                  enum:
                    - active
                    - inactive
              required:
                - userId
                - areaStatus
    parameters:
      -
        in: path
        name: territory_id
        description: 'The ID of the territory.'
        example: 1
        required: true
        schema:
          type: integer
      -
        in: path
        name: id
        description: 'The ID of the user territory.'
        example: non
        required: true
        schema:
          type: string
  '/api/v1/admin/territories/{territory_id}/territory-areas':
    get:
      summary: 'Display a listing of territory areas for a specific territory.'
      operationId: displayAListingOfTerritoryAreasForASpecificTerritory
      description: ''
      parameters: []
      responses:
        401:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: Unauthenticated.
                properties:
                  message:
                    type: string
                    example: Unauthenticated.
      tags:
        - Territory
    post:
      summary: 'Store a newly created territory area in a specific territory.'
      operationId: storeANewlyCreatedTerritoryAreaInASpecificTerritory
      description: ''
      parameters: []
      responses: {  }
      tags:
        - Territory
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                areaType:
                  type: string
                  description: ''
                  example: postcode
                  enum:
                    - county
                    - city
                    - district
                    - postcode
                areaStatus:
                  type: string
                  description: ''
                  example: inactive
                  enum:
                    - active
                    - inactive
                areaValue:
                  type: string
                  description: 'Must not be greater than 255 characters.'
                  example: bbytqbmgapgtqvrjs
              required:
                - areaType
                - areaStatus
                - areaValue
    parameters:
      -
        in: path
        name: territory_id
        description: 'The ID of the territory.'
        example: 1
        required: true
        schema:
          type: integer
  '/api/v1/admin/territories/{territory_id}/territory-areas/{id}':
    get:
      summary: 'Display the specified territory area for a specific territory.'
      operationId: displayTheSpecifiedTerritoryAreaForASpecificTerritory
      description: ''
      parameters: []
      responses:
        401:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: Unauthenticated.
                properties:
                  message:
                    type: string
                    example: Unauthenticated.
      tags:
        - Territory
    put:
      summary: 'Update the specified territory area in a specific territory.'
      operationId: updateTheSpecifiedTerritoryAreaInASpecificTerritory
      description: ''
      parameters: []
      responses: {  }
      tags:
        - Territory
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                areaType:
                  type: string
                  description: ''
                  example: county
                  enum:
                    - county
                    - city
                    - district
                    - postcode
                areaStatus:
                  type: string
                  description: ''
                  example: inactive
                  enum:
                    - active
                    - inactive
                areaValue:
                  type: string
                  description: 'Must not be greater than 255 characters.'
                  example: ibpwbeadjhqehsyjnwrjpibyo
              required:
                - areaType
                - areaStatus
                - areaValue
    parameters:
      -
        in: path
        name: territory_id
        description: 'The ID of the territory.'
        example: 1
        required: true
        schema:
          type: integer
      -
        in: path
        name: id
        description: 'The ID of the territory area.'
        example: ut
        required: true
        schema:
          type: string
  '/api/partners/v1/track/{trackingReferenceNumber}':
    get:
      summary: ''
      operationId: getApiPartnersV1TrackTrackingReferenceNumber
      description: ''
      parameters: []
      responses:
        200:
          description: ''
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Request was successful.'
                  details:
                    -
                      status: '00 pending'
                      statusDate: '2024-08-07 05:03:52'
                      statusNotes: null
                      statusImage: null
                    -
                      status: '07 ready for pickup'
                      statusDate: '2024-08-07 05:10:11'
                      statusNotes: null
                      statusImage: null
                properties:
                  message:
                    type: string
                    example: 'Request was successful.'
                  details:
                    type: array
                    example:
                      -
                        status: '00 pending'
                        statusDate: '2024-08-07 05:03:52'
                        statusNotes: null
                        statusImage: null
                      -
                        status: '07 ready for pickup'
                        statusDate: '2024-08-07 05:10:11'
                        statusNotes: null
                        statusImage: null
                    items:
                      type: object
                      properties:
                        status:
                          type: string
                          example: '00 pending'
                        statusDate:
                          type: string
                          example: '2024-08-07 05:03:52'
                        statusNotes:
                          type: string
                          example: null
                        statusImage:
                          type: string
                          example: null
      tags:
        - Transactions
      security: []
    parameters:
      -
        in: path
        name: trackingReferenceNumber
        description: ''
        example: DLS1724406945
        required: true
        schema:
          type: 'Tracking reference number, corresponding to the create order transaction.'
  /api/partners/v1/order:
    get:
      summary: "Get transaction details for the delivery order.\n\nUse this endpoint to get transaction details for the delivery."
      operationId: getTransactionDetailsForTheDeliveryOrderUseThisEndpointToGetTransactionDetailsForTheDelivery
      description: ''
      parameters:
        -
          in: query
          name: expires
          description: Expires.
          example: 1716111060.0
          required: true
          schema:
            type: number
            description: Expires.
            example: 1716111060.0
        -
          in: query
          name: requestReferenceNumber
          description: 'Request Id.'
          example: LTO-000000000001
          required: true
          schema:
            type: string
            description: 'Request Id.'
            example: LTO-000000000001
        -
          in: query
          name: signature
          description: Signature.
          example: ac8d06273b7340ce69cd97963aa637d914240376a8dbf269dbe6f7c776c31a60
          required: true
          schema:
            type: string
            description: Signature.
            example: ac8d06273b7340ce69cd97963aa637d914240376a8dbf269dbe6f7c776c31a60
      responses:
        200:
          description: success
          content:
            application/json:
              schema:
                type: object
                example:
                  message: 'Request was successful.'
                properties:
                  message:
                    type: string
                    example: 'Request was successful.'
      tags:
        - Transactions
      security: []
tags:
  -
    name: Address
    description: ''
  -
    name: Administrator
    description: ''
  -
    name: Authentication
    description: ''
  -
    name: Checkout
    description: ''
  -
    name: Delivery
    description: ''
  -
    name: Dispatcher
    description: ''
  -
    name: Riders
    description: ''
  -
    name: Territory
    description: ''
  -
    name: Transactions
    description: ''
components:
  securitySchemes:
    default:
      type: http
      scheme: bearer
      description: 'You can retrieve your token by visiting your Authentication dashboard.'
security:
  -
    default: []
