openapi: 3.0.3
info:
    title: Laravel
    description: ''
    version: 1.0.0
servers:
    -
        url: 'https://api-staging.zanifu.com'
paths:
    /api/advance:
        post:
            summary: 'Agent advance'
            description: ''
            parameters:
                -
                    in: header
                    name: Authorization
                    description: ''
                    example: 'Bearer {YOUR_AUTH_KEY}'
                    schema:
                        type: string
                -
                    in: header
                    name: Content-Type
                    description: ''
                    example: application/json
                    schema:
                        type: string
                -
                    in: header
                    name: Accept
                    description: ''
                    example: application/json
                    schema:
                        type: string
            responses: {  }
            tags:
                - Advance
            requestBody:
                required: false
                content:
                    application/json:
                        schema:
                            type: object
                            properties:
                                amount:
                                    type: integer
                                    description: 'Amount being requested'
                                    example: 2000
    /api/agent-limit:
        get:
            summary: 'Agent limit'
            description: ''
            parameters:
                -
                    in: header
                    name: Authorization
                    description: ''
                    example: 'Bearer {YOUR_AUTH_KEY}'
                    schema:
                        type: string
                -
                    in: header
                    name: Content-Type
                    description: ''
                    example: application/json
                    schema:
                        type: string
                -
                    in: header
                    name: Accept
                    description: ''
                    example: application/json
                    schema:
                        type: string
            responses:
                401:
                    description: ''
                    content:
                        application/json:
                            schema:
                                type: object
                                example:
                                    message: Unauthenticated.
                                properties:
                                    message: { type: string, example: Unauthenticated. }
            tags:
                - Advance
    /api/login:
        post:
            summary: 'Validate user credentials'
            description: ''
            parameters:
                -
                    in: header
                    name: Content-Type
                    description: ''
                    example: application/json
                    schema:
                        type: string
                -
                    in: header
                    name: Accept
                    description: ''
                    example: application/json
                    schema:
                        type: string
            responses: {  }
            tags:
                - Authentication
            requestBody:
                required: false
                content:
                    application/json:
                        schema:
                            type: object
                            properties:
                                key:
                                    type: string
                                    description: 'This can also be email|phone'
                                    example: nisi
                                email:
                                    type: string
                                    description: 'This can also be phone|key'
                                    example: nam
                                phone:
                                    type: string
                                    description: 'This can also be email|key'
                                    example: fugit
                                password:
                                    type: string
                                    description: 'This can also be secret'
                                    example: explicabo
                                secret:
                                    type: string
                                    description: 'This can also be password'
                                    example: suscipit
            security: []
    /api/sign-up:
        post:
            summary: 'Register new distributor'
            description: ''
            parameters:
                -
                    in: header
                    name: Content-Type
                    description: ''
                    example: application/json
                    schema:
                        type: string
                -
                    in: header
                    name: Accept
                    description: ''
                    example: application/json
                    schema:
                        type: string
            responses: {  }
            tags:
                - Authentication
            requestBody:
                required: false
                content:
                    application/json:
                        schema:
                            type: object
                            properties:
                                account_type:
                                    type: integer
                                    description: ''
                                    example: 5
                                name:
                                    type: string
                                    description: 'Distributor Name'
                                    example: commodi
                                phone:
                                    type: string
                                    description: 'Distributor Phone number'
                                    example: qui
                                email:
                                    type: string
                                    description: 'Distributor Email'
                                    example: repudiandae
            security: []
    /api/password-reset:
        post:
            summary: 'Initiate a password reset request'
            description: ''
            parameters:
                -
                    in: header
                    name: Content-Type
                    description: ''
                    example: application/json
                    schema:
                        type: string
                -
                    in: header
                    name: Accept
                    description: ''
                    example: application/json
                    schema:
                        type: string
            responses: {  }
            tags:
                - Authentication
            requestBody:
                required: true
                content:
                    application/json:
                        schema:
                            type: object
                            properties:
                                email:
                                    type: string
                                    description: 'Distributor Email'
                                    example: nostrum
                            required:
                                - email
            security: []
    /api/reset-password:
        post:
            summary: 'Complete password reset'
            description: ''
            parameters:
                -
                    in: header
                    name: Content-Type
                    description: ''
                    example: application/json
                    schema:
                        type: string
                -
                    in: header
                    name: Accept
                    description: ''
                    example: application/json
                    schema:
                        type: string
            responses: {  }
            tags:
                - Authentication
            requestBody:
                required: true
                content:
                    application/json:
                        schema:
                            type: object
                            properties:
                                email:
                                    type: string
                                    description: 'Distributor Email'
                                    example: aspernatur
                                token:
                                    type: string
                                    description: 'Generated token from email'
                                    example: placeat
                                new_password:
                                    type: string
                                    description: 'New password'
                                    example: eum
                            required:
                                - email
                                - token
                                - new_password
            security: []
    /api/pin-reset:
        post:
            summary: 'Initiate a pin reset'
            description: ''
            parameters:
                -
                    in: header
                    name: Content-Type
                    description: ''
                    example: application/json
                    schema:
                        type: string
                -
                    in: header
                    name: Accept
                    description: ''
                    example: application/json
                    schema:
                        type: string
            responses: {  }
            tags:
                - Authentication
            requestBody:
                required: true
                content:
                    application/json:
                        schema:
                            type: object
                            properties:
                                phone_number:
                                    type: string
                                    description: 'Phone number'
                                    example: '+254712345678'
                            required:
                                - phone_number
            security: []
    /api/reset-pin:
        post:
            summary: 'Reset the pin'
            description: ''
            parameters:
                -
                    in: header
                    name: Content-Type
                    description: ''
                    example: application/json
                    schema:
                        type: string
                -
                    in: header
                    name: Accept
                    description: ''
                    example: application/json
                    schema:
                        type: string
            responses: {  }
            tags:
                - Authentication
            requestBody:
                required: true
                content:
                    application/json:
                        schema:
                            type: object
                            properties:
                                otp:
                                    type: string
                                    description: 'Otp sent for the number'
                                    example: recusandae
                                phone_number:
                                    type: string
                                    description: 'phone number'
                                    example: cupiditate
                                new_pin:
                                    type: string
                                    description: 'New user pin'
                                    example: hic
                            required:
                                - otp
                                - phone_number
                                - new_pin
            security: []
    /api/change-password:
        post:
            summary: 'Change the current user password'
            description: ''
            parameters:
                -
                    in: header
                    name: Authorization
                    description: ''
                    example: 'Bearer {YOUR_AUTH_KEY}'
                    schema:
                        type: string
                -
                    in: header
                    name: Content-Type
                    description: ''
                    example: application/json
                    schema:
                        type: string
                -
                    in: header
                    name: Accept
                    description: ''
                    example: application/json
                    schema:
                        type: string
            responses: {  }
            tags:
                - Authentication
            requestBody:
                required: true
                content:
                    application/json:
                        schema:
                            type: object
                            properties:
                                current_password:
                                    type: string
                                    description: 'Current user password'
                                    example: in
                                new_password:
                                    type: string
                                    description: 'New user password'
                                    example: quia
                            required:
                                - current_password
                                - new_password
    /api/change-pin:
        post:
            summary: 'Change the current user pin'
            description: ''
            parameters:
                -
                    in: header
                    name: Authorization
                    description: ''
                    example: 'Bearer {YOUR_AUTH_KEY}'
                    schema:
                        type: string
                -
                    in: header
                    name: Content-Type
                    description: ''
                    example: application/json
                    schema:
                        type: string
                -
                    in: header
                    name: Accept
                    description: ''
                    example: application/json
                    schema:
                        type: string
            responses: {  }
            tags:
                - Authentication
            requestBody:
                required: true
                content:
                    application/json:
                        schema:
                            type: object
                            properties:
                                current_pin:
                                    type: string
                                    description: 'Current user pin'
                                    example: atque
                                new_pin:
                                    type: string
                                    description: 'New user pin'
                                    example: sequi
                            required:
                                - current_pin
                                - new_pin
    /api/logout:
        post:
            summary: 'Log out the distributor.'
            description: 'Remove current distributor token'
            parameters:
                -
                    in: header
                    name: Authorization
                    description: ''
                    example: 'Bearer {YOUR_AUTH_KEY}'
                    schema:
                        type: string
                -
                    in: header
                    name: Content-Type
                    description: ''
                    example: application/json
                    schema:
                        type: string
                -
                    in: header
                    name: Accept
                    description: ''
                    example: application/json
                    schema:
                        type: string
            responses: {  }
            tags:
                - Authentication
    /api/carts:
        get:
            summary: 'List carts'
            description: ''
            parameters:
                -
                    in: header
                    name: Authorization
                    description: ''
                    example: 'Bearer {YOUR_AUTH_KEY}'
                    schema:
                        type: string
                -
                    in: header
                    name: Content-Type
                    description: ''
                    example: application/json
                    schema:
                        type: string
                -
                    in: header
                    name: Accept
                    description: ''
                    example: application/json
                    schema:
                        type: string
            responses:
                401:
                    description: ''
                    content:
                        application/json:
                            schema:
                                type: object
                                example:
                                    message: Unauthenticated.
                                properties:
                                    message: { type: string, example: Unauthenticated. }
            tags:
                - Cart
    '/api/carts/{cart}':
        get:
            summary: 'Get single cart details'
            description: ''
            parameters:
                -
                    in: header
                    name: Authorization
                    description: ''
                    example: 'Bearer {YOUR_AUTH_KEY}'
                    schema:
                        type: string
                -
                    in: header
                    name: Content-Type
                    description: ''
                    example: application/json
                    schema:
                        type: string
                -
                    in: header
                    name: Accept
                    description: ''
                    example: application/json
                    schema:
                        type: string
            responses:
                401:
                    description: ''
                    content:
                        application/json:
                            schema:
                                type: object
                                example:
                                    message: Unauthenticated.
                                properties:
                                    message: { type: string, example: Unauthenticated. }
            tags:
                - Cart
        parameters:
            -
                in: path
                name: cart
                description: 'Cart id'
                example: 5
                required: true
                schema:
                    type: integer
    /api/categories:
        get:
            summary: 'List of categories'
            description: ''
            parameters:
                -
                    in: header
                    name: Content-Type
                    description: ''
                    example: application/json
                    schema:
                        type: string
                -
                    in: header
                    name: Accept
                    description: ''
                    example: application/json
                    schema:
                        type: string
            responses:
                200:
                    description: ''
                    content:
                        application/json:
                            schema:
                                type: object
                                example:
                                    data: [{ id: 12, category_code: 5813, name: 'Bars and Restaurants' }, { id: 28, category_code: 5921, name: 'Liquor Stores' }, { id: 37, category_code: 5412, name: 'Dukas and Mini-Marts' }, { id: 38, category_code: 5413, name: 'Cooking Gas' }, { id: 19, category_code: 5251, name: Hardwares }, { id: 35, category_code: 5411, name: Supermarkets }, { id: 39, category_code: 5414, name: Agrovets }, { id: 11, category_code: 5451, name: 'Milk and other Dairy Products' }, { id: 14, category_code: 5812, name: Restaurants }, { id: 40, category_code: 5415, name: 'Motorcycle Parts' }, { id: 31, category_code: 5732, name: 'Phones and Electronics' }, { id: 4, category_code: 5942, name: Bookshops }, { id: 41, category_code: 5416, name: 'Chemists and Pharmercists Shop' }, { id: 15, category_code: 5065, name: 'Electricals Shop' }, { id: 3, category_code: 5422, name: Butcheries }, { id: 42, category_code: 5417, name: Markets }, { id: 43, category_code: 5418, name: Clothes }, { id: 44, category_code: 5419, name: Carwash }, { id: 34, category_code: 5111, name: 'Stationery shops' }, { id: 1, category_code: 5462, name: Bakeries }, { id: 2, category_code: 7230, name: 'Barber and Beauty Shops' }, { id: 5, category_code: 7216, name: 'Carwash and Dry Cleaners' }, { id: 6, category_code: 5169, name: 'Chemicals and Allied Products' }, { id: 7, category_code: 5641, name: 'Children’s and Infant’s Wear Stores' }, { id: 8, category_code: 5993, name: 'Cigar Stores and suppliers' }, { id: 9, category_code: 5139, name: 'Commercial Footwear' }, { id: 10, category_code: 5045, name: 'Computers, Computer Peripheral Equipment, Software' }, { id: 13, category_code: 5912, name: 'Drug Stores and Pharmacies' }, { id: 16, category_code: 5814, name: 'Fast Food Restaurants' }, { id: 17, category_code: 5193, name: 'Florists’ Supplies, Nursery Stock and Flowers' }, { id: 18, category_code: 5950, name: 'Glassware/Crystal Stores' }, { id: 20, category_code: 7298, name: 'Health and Beauty Shops' }, { id: 21, category_code: 5722, name: 'Household Appliance Stores' }, { id: 22, category_code: 5085, name: 'Industrial Supplies' }, { id: 23, category_code: 5047, name: 'Medical, Dental Ophthalmic, Hospital Equipment and Supplies' }, { id: 24, category_code: 5137, name: 'Men’s Women’s and Children’s Uniforms and Commercial Clothing' }, { id: 25, category_code: 5399, name: 'Misc. General Merchandise' }, { id: 26, category_code: 5571, name: 'Motorcycle Dealers' }, { id: 27, category_code: 5013, name: 'Motor vehicle supplies and new parts' }, { id: 29, category_code: 5198, name: 'Paints, Varnishes, and Supplies' }, { id: 30, category_code: 5172, name: 'Petroleum and Petroleum Products' }, { id: 32, category_code: 5074, name: 'Plumbing and Heating Equipment and Supplies' }, { id: 33, category_code: 5655, name: 'Sports Apparel Stores' }, { id: 36, category_code: 7692, name: 'Welding and Repair' }]
                                properties:
                                    data: { type: array, example: [{ id: 12, category_code: 5813, name: 'Bars and Restaurants' }, { id: 28, category_code: 5921, name: 'Liquor Stores' }, { id: 37, category_code: 5412, name: 'Dukas and Mini-Marts' }, { id: 38, category_code: 5413, name: 'Cooking Gas' }, { id: 19, category_code: 5251, name: Hardwares }, { id: 35, category_code: 5411, name: Supermarkets }, { id: 39, category_code: 5414, name: Agrovets }, { id: 11, category_code: 5451, name: 'Milk and other Dairy Products' }, { id: 14, category_code: 5812, name: Restaurants }, { id: 40, category_code: 5415, name: 'Motorcycle Parts' }, { id: 31, category_code: 5732, name: 'Phones and Electronics' }, { id: 4, category_code: 5942, name: Bookshops }, { id: 41, category_code: 5416, name: 'Chemists and Pharmercists Shop' }, { id: 15, category_code: 5065, name: 'Electricals Shop' }, { id: 3, category_code: 5422, name: Butcheries }, { id: 42, category_code: 5417, name: Markets }, { id: 43, category_code: 5418, name: Clothes }, { id: 44, category_code: 5419, name: Carwash }, { id: 34, category_code: 5111, name: 'Stationery shops' }, { id: 1, category_code: 5462, name: Bakeries }, { id: 2, category_code: 7230, name: 'Barber and Beauty Shops' }, { id: 5, category_code: 7216, name: 'Carwash and Dry Cleaners' }, { id: 6, category_code: 5169, name: 'Chemicals and Allied Products' }, { id: 7, category_code: 5641, name: 'Children’s and Infant’s Wear Stores' }, { id: 8, category_code: 5993, name: 'Cigar Stores and suppliers' }, { id: 9, category_code: 5139, name: 'Commercial Footwear' }, { id: 10, category_code: 5045, name: 'Computers, Computer Peripheral Equipment, Software' }, { id: 13, category_code: 5912, name: 'Drug Stores and Pharmacies' }, { id: 16, category_code: 5814, name: 'Fast Food Restaurants' }, { id: 17, category_code: 5193, name: 'Florists’ Supplies, Nursery Stock and Flowers' }, { id: 18, category_code: 5950, name: 'Glassware/Crystal Stores' }, { id: 20, category_code: 7298, name: 'Health and Beauty Shops' }, { id: 21, category_code: 5722, name: 'Household Appliance Stores' }, { id: 22, category_code: 5085, name: 'Industrial Supplies' }, { id: 23, category_code: 5047, name: 'Medical, Dental Ophthalmic, Hospital Equipment and Supplies' }, { id: 24, category_code: 5137, name: 'Men’s Women’s and Children’s Uniforms and Commercial Clothing' }, { id: 25, category_code: 5399, name: 'Misc. General Merchandise' }, { id: 26, category_code: 5571, name: 'Motorcycle Dealers' }, { id: 27, category_code: 5013, name: 'Motor vehicle supplies and new parts' }, { id: 29, category_code: 5198, name: 'Paints, Varnishes, and Supplies' }, { id: 30, category_code: 5172, name: 'Petroleum and Petroleum Products' }, { id: 32, category_code: 5074, name: 'Plumbing and Heating Equipment and Supplies' }, { id: 33, category_code: 5655, name: 'Sports Apparel Stores' }, { id: 36, category_code: 7692, name: 'Welding and Repair' }], items: { type: object } }
            tags:
                - Categories
            security: []
    /api/checkout:
        post:
            summary: 'Post checkout request'
            description: ''
            parameters:
                -
                    in: header
                    name: Authorization
                    description: ''
                    example: 'Bearer {YOUR_AUTH_KEY}'
                    schema:
                        type: string
                -
                    in: header
                    name: Content-Type
                    description: ''
                    example: application/json
                    schema:
                        type: string
                -
                    in: header
                    name: Accept
                    description: ''
                    example: application/json
                    schema:
                        type: string
            responses: {  }
            tags:
                - 'Checkout Orders'
            requestBody:
                required: true
                content:
                    application/json:
                        schema:
                            type: object
                            properties:
                                payment_method:
                                    type: string
                                    description: 'Payment Method (zanifu_credit, wallet)'
                                    example: hic
                                till:
                                    type: integer
                                    description: 'Distributor Till Number'
                                    example: 12345
                                account_number:
                                    type: string
                                    description: 'Payer Account Number'
                                    example: '+254727123456789'
                                phone_number:
                                    type: string
                                    description: 'Alternative Phone Number'
                                    example: '+254123456789'
                                amount:
                                    type: integer
                                    description: 'Amount when without products'
                                    example: 4000
                                products:
                                    type: array
                                    description: 'Products selected for payment'
                                    example: [[], []]
                                    items: { type: object, properties: { id: { type: integer, description: '', example: 10 }, quantity: { type: integer, description: '', example: 10 }, distributor_id: { type: integer, description: '', example: 2 } }, required: [id, quantity] }
                                redeem_code:
                                    type: string
                                    description: ''
                                    example: mollitia
                            required:
                                - payment_method
                                - till
    '/api/checkout/{cart}':
        put:
            summary: 'Checkout Order'
            description: ''
            parameters:
                -
                    in: header
                    name: Authorization
                    description: ''
                    example: 'Bearer {YOUR_AUTH_KEY}'
                    schema:
                        type: string
                -
                    in: header
                    name: Content-Type
                    description: ''
                    example: application/json
                    schema:
                        type: string
                -
                    in: header
                    name: Accept
                    description: ''
                    example: application/json
                    schema:
                        type: string
            responses: {  }
            tags:
                - 'Checkout Orders'
        parameters:
            -
                in: path
                name: cart
                description: 'Pending Cart Id'
                example: 16
                required: true
                schema:
                    type: integer
    /api/postcomment:
        post:
            summary: 'Stores user comment in the database'
            description: ''
            parameters:
                -
                    in: header
                    name: Authorization
                    description: ''
                    example: 'Bearer {YOUR_AUTH_KEY}'
                    schema:
                        type: string
                -
                    in: header
                    name: Content-Type
                    description: ''
                    example: application/json
                    schema:
                        type: string
                -
                    in: header
                    name: Accept
                    description: ''
                    example: application/json
                    schema:
                        type: string
            responses: {  }
            tags:
                - Comments
            requestBody:
                required: true
                content:
                    application/json:
                        schema:
                            type: object
                            properties:
                                comment:
                                    type: string
                                    description: ''
                                    example: tempore
                                commentid:
                                    type: string
                                    description: ''
                                    example: aut
                                user:
                                    type: string
                                    description: ''
                                    example: blanditiis
                                type:
                                    type: string
                                    description: ''
                                    example: veniam
                                name:
                                    type: string
                                    description: ''
                                    example: suscipit
                            required:
                                - comment
                                - commentid
                                - user
                                - type
                                - name
    /api/getcomments:
        post:
            summary: 'Returns user comment in the database'
            description: ''
            parameters:
                -
                    in: header
                    name: Authorization
                    description: ''
                    example: 'Bearer {YOUR_AUTH_KEY}'
                    schema:
                        type: string
                -
                    in: header
                    name: Content-Type
                    description: ''
                    example: application/json
                    schema:
                        type: string
                -
                    in: header
                    name: Accept
                    description: ''
                    example: application/json
                    schema:
                        type: string
            responses: {  }
            tags:
                - Comments
            requestBody:
                required: true
                content:
                    application/json:
                        schema:
                            type: object
                            properties:
                                commentid:
                                    type: string
                                    description: ''
                                    example: dicta
                            required:
                                - commentid
    /api/removecomment:
        post:
            summary: 'Depreciated but used to delete comment from db'
            description: ''
            parameters:
                -
                    in: header
                    name: Authorization
                    description: ''
                    example: 'Bearer {YOUR_AUTH_KEY}'
                    schema:
                        type: string
                -
                    in: header
                    name: Content-Type
                    description: ''
                    example: application/json
                    schema:
                        type: string
                -
                    in: header
                    name: Accept
                    description: ''
                    example: application/json
                    schema:
                        type: string
            responses: {  }
            tags:
                - Comments
            requestBody:
                required: true
                content:
                    application/json:
                        schema:
                            type: object
                            properties:
                                commentid:
                                    type: string
                                    description: ''
                                    example: dolores
                            required:
                                - commentid
    /api/agent/commissions:
        get:
            summary: 'Commission Balance'
            description: ''
            parameters:
                -
                    in: header
                    name: Authorization
                    description: ''
                    example: 'Bearer {YOUR_AUTH_KEY}'
                    schema:
                        type: string
                -
                    in: header
                    name: Content-Type
                    description: ''
                    example: application/json
                    schema:
                        type: string
                -
                    in: header
                    name: Accept
                    description: ''
                    example: application/json
                    schema:
                        type: string
            responses:
                401:
                    description: ''
                    content:
                        application/json:
                            schema:
                                type: object
                                example:
                                    message: Unauthenticated.
                                properties:
                                    message: { type: string, example: Unauthenticated. }
            tags:
                - Commissions
        post:
            summary: 'Withdraw Commission'
            description: ''
            parameters:
                -
                    in: header
                    name: Authorization
                    description: ''
                    example: 'Bearer {YOUR_AUTH_KEY}'
                    schema:
                        type: string
                -
                    in: header
                    name: Content-Type
                    description: ''
                    example: application/json
                    schema:
                        type: string
                -
                    in: header
                    name: Accept
                    description: ''
                    example: application/json
                    schema:
                        type: string
            responses: {  }
            tags:
                - Commissions
    /api/customers:
        get:
            summary: 'Customer summary per region'
            description: ''
            parameters:
                -
                    in: query
                    name: 'page[number]'
                    description: 'Page number'
                    example: 8
                    required: false
                    schema:
                        type: integer
                        description: 'Page number'
                        example: 8
                -
                    in: query
                    name: 'page[size]'
                    description: 'Number of records on a page'
                    example: 2
                    required: false
                    schema:
                        type: integer
                        description: 'Number of records on a page'
                        example: 2
                -
                    in: query
                    name: 'filter[search]'
                    description: 'Filter by query'
                    example: voluptatem
                    required: false
                    schema:
                        type: string
                        description: 'Filter by query'
                        example: voluptatem
                -
                    in: header
                    name: Authorization
                    description: ''
                    example: 'Bearer {YOUR_AUTH_KEY}'
                    schema:
                        type: string
                -
                    in: header
                    name: Content-Type
                    description: ''
                    example: application/json
                    schema:
                        type: string
                -
                    in: header
                    name: Accept
                    description: ''
                    example: application/json
                    schema:
                        type: string
            responses:
                401:
                    description: ''
                    content:
                        application/json:
                            schema:
                                type: object
                                example:
                                    message: Unauthenticated.
                                properties:
                                    message: { type: string, example: Unauthenticated. }
            tags:
                - Customers
    '/api/customers/{customer}/transactions':
        get:
            summary: 'Customer transactions'
            description: ''
            parameters:
                -
                    in: query
                    name: 'page[number]'
                    description: 'Page number'
                    example: 11
                    required: false
                    schema:
                        type: integer
                        description: 'Page number'
                        example: 11
                -
                    in: query
                    name: 'page[size]'
                    description: 'Number of records on a page'
                    example: 16
                    required: false
                    schema:
                        type: integer
                        description: 'Number of records on a page'
                        example: 16
                -
                    in: header
                    name: Authorization
                    description: ''
                    example: 'Bearer {YOUR_AUTH_KEY}'
                    schema:
                        type: string
                -
                    in: header
                    name: Content-Type
                    description: ''
                    example: application/json
                    schema:
                        type: string
                -
                    in: header
                    name: Accept
                    description: ''
                    example: application/json
                    schema:
                        type: string
            responses:
                401:
                    description: ''
                    content:
                        application/json:
                            schema:
                                type: object
                                example:
                                    message: Unauthenticated.
                                properties:
                                    message: { type: string, example: Unauthenticated. }
            tags:
                - Customers
        parameters:
            -
                in: path
                name: customer
                description: 'Customer ID'
                example: 4
                required: true
                schema:
                    type: integer
    '/api/customers/{region}':
        get:
            summary: 'Customers in a region'
            description: ''
            parameters:
                -
                    in: query
                    name: 'page[number]'
                    description: 'Page number'
                    example: 7
                    required: false
                    schema:
                        type: integer
                        description: 'Page number'
                        example: 7
                -
                    in: query
                    name: 'page[size]'
                    description: 'Number of records on a page'
                    example: 3
                    required: false
                    schema:
                        type: integer
                        description: 'Number of records on a page'
                        example: 3
                -
                    in: query
                    name: 'filter[search]'
                    description: 'Filter by query'
                    example: explicabo
                    required: false
                    schema:
                        type: string
                        description: 'Filter by query'
                        example: explicabo
                -
                    in: header
                    name: Authorization
                    description: ''
                    example: 'Bearer {YOUR_AUTH_KEY}'
                    schema:
                        type: string
                -
                    in: header
                    name: Content-Type
                    description: ''
                    example: application/json
                    schema:
                        type: string
                -
                    in: header
                    name: Accept
                    description: ''
                    example: application/json
                    schema:
                        type: string
            responses:
                401:
                    description: ''
                    content:
                        application/json:
                            schema:
                                type: object
                                example:
                                    message: Unauthenticated.
                                properties:
                                    message: { type: string, example: Unauthenticated. }
            tags:
                - Customers
        parameters:
            -
                in: path
                name: region
                description: 'Region ID'
                example: 19
                required: true
                schema:
                    type: integer
    /api/agent/customers:
        get:
            summary: 'Agent Customers'
            description: 'Get all customers assigned to an agent'
            parameters:
                -
                    in: query
                    name: 'page[number]'
                    description: 'Page number'
                    example: 3
                    required: false
                    schema:
                        type: integer
                        description: 'Page number'
                        example: 3
                -
                    in: query
                    name: 'page[size]'
                    description: 'Number of records on a page'
                    example: 14
                    required: false
                    schema:
                        type: integer
                        description: 'Number of records on a page'
                        example: 14
                -
                    in: query
                    name: 'filter[search]'
                    description: 'Filter by query'
                    example: eos
                    required: false
                    schema:
                        type: string
                        description: 'Filter by query'
                        example: eos
                -
                    in: query
                    name: 'filter[status]'
                    description: 'Filter by status'
                    example: blacklisted
                    required: false
                    schema:
                        type: string
                        description: 'Filter by status'
                        example: blacklisted
                -
                    in: header
                    name: Authorization
                    description: ''
                    example: 'Bearer {YOUR_AUTH_KEY}'
                    schema:
                        type: string
                -
                    in: header
                    name: Content-Type
                    description: ''
                    example: application/json
                    schema:
                        type: string
                -
                    in: header
                    name: Accept
                    description: ''
                    example: application/json
                    schema:
                        type: string
            responses:
                401:
                    description: ''
                    content:
                        application/json:
                            schema:
                                type: object
                                example:
                                    message: Unauthenticated.
                                properties:
                                    message: { type: string, example: Unauthenticated. }
            tags:
                - Customers
    '/api/customers/geotag/{customer}':
        put:
            summary: Geotag
            description: 'Geotag the customer business'
            parameters:
                -
                    in: header
                    name: Authorization
                    description: ''
                    example: 'Bearer {YOUR_AUTH_KEY}'
                    schema:
                        type: string
                -
                    in: header
                    name: Content-Type
                    description: ''
                    example: application/json
                    schema:
                        type: string
                -
                    in: header
                    name: Accept
                    description: ''
                    example: application/json
                    schema:
                        type: string
            responses: {  }
            tags:
                - Customers
            requestBody:
                required: true
                content:
                    application/json:
                        schema:
                            type: object
                            properties:
                                latitude:
                                    type: number
                                    description: Latitude
                                    example: 12386380.286467
                                longitude:
                                    type: number
                                    description: Longitude
                                    example: !!float 5675440
                            required:
                                - latitude
                                - longitude
        parameters:
            -
                in: path
                name: customer
                description: 'customer id'
                example: 14
                required: true
                schema:
                    type: integer
    '/api/redeem/{code}/verify':
        get:
            summary: 'Verify if redeem code works'
            description: ''
            parameters:
                -
                    in: header
                    name: Authorization
                    description: ''
                    example: 'Bearer {YOUR_AUTH_KEY}'
                    schema:
                        type: string
                -
                    in: header
                    name: Content-Type
                    description: ''
                    example: application/json
                    schema:
                        type: string
                -
                    in: header
                    name: Accept
                    description: ''
                    example: application/json
                    schema:
                        type: string
            responses:
                401:
                    description: ''
                    content:
                        application/json:
                            schema:
                                type: object
                                example:
                                    message: Unauthenticated.
                                properties:
                                    message: { type: string, example: Unauthenticated. }
            tags:
                - Discounts
            requestBody:
                required: true
                content:
                    application/json:
                        schema:
                            type: object
                            properties:
                                redeem_code:
                                    type: string
                                    description: 'Redeem Code'
                                    example: et
                            required:
                                - redeem_code
        parameters:
            -
                in: path
                name: code
                description: ''
                example: asperiores
                required: true
                schema:
                    type: string
    /api/distributors:
        get:
            summary: 'List of distributors'
            description: ''
            parameters:
                -
                    in: query
                    name: 'filter[category]'
                    description: 'Filter by category'
                    example: 8
                    required: false
                    schema:
                        type: integer
                        description: 'Filter by category'
                        example: 8
                -
                    in: query
                    name: 'page[number]'
                    description: 'Page number'
                    example: 9
                    required: false
                    schema:
                        type: integer
                        description: 'Page number'
                        example: 9
                -
                    in: query
                    name: 'page[size]'
                    description: 'Number of records on a page'
                    example: 8
                    required: false
                    schema:
                        type: integer
                        description: 'Number of records on a page'
                        example: 8
                -
                    in: query
                    name: 'filter[search]'
                    description: 'Filter by query'
                    example: architecto
                    required: false
                    schema:
                        type: string
                        description: 'Filter by query'
                        example: architecto
                -
                    in: header
                    name: Content-Type
                    description: ''
                    example: application/json
                    schema:
                        type: string
                -
                    in: header
                    name: Accept
                    description: ''
                    example: application/json
                    schema:
                        type: string
            responses:
                200:
                    description: ''
                    content:
                        application/json:
                            schema:
                                type: object
                                example:
                                    data: [{ distributor_id: 2, distributor_name: 'Mt Kenya Beer', distributor_alias: E, status: 1, date_created: '2018-10-18 12:10:13', created_by: 25, distributor_email: '', distributor_phone: '254722556306', manager_id: 3, updated_at: '1970-01-01T00:33:42.000000Z', created_at: '2018-10-18T09:10:13.000000Z', last_alias: 554, loan_type: 2, region_id: 2, contact_name: null, merchant_type: 5813, interest_rate: 0, pay_wallet_balance: 0, advance_limit: 0 }, { distributor_id: 3, distributor_name: 'Lawrence Duncan Rift Valley', distributor_alias: '', status: 1, date_created: '2018-10-18 12:13:16', created_by: 25, distributor_email: '', distributor_phone: '254701897794', manager_id: 4, updated_at: '1970-01-01T00:33:41.000000Z', created_at: '2018-10-18T09:13:16.000000Z', last_alias: 159, loan_type: 2, region_id: 2, contact_name: null, merchant_type: 5813, interest_rate: 0, pay_wallet_balance: 0, advance_limit: 0 }, { distributor_id: 4, distributor_name: 'Peanco Limited', distributor_alias: C, status: 1, date_created: '2018-10-18 12:14:41', created_by: 25, distributor_email: '', distributor_phone: '254790147214', manager_id: 3, updated_at: '1970-01-01T00:33:41.000000Z', created_at: '2018-10-18T09:14:41.000000Z', last_alias: 527, loan_type: 2, region_id: 2, contact_name: null, merchant_type: 5813, interest_rate: 2, pay_wallet_balance: 840, advance_limit: 1000 }, { distributor_id: 5, distributor_name: 'Erinpet Enterprises', distributor_alias: P, status: 1, date_created: '2018-10-18 12:15:29', created_by: 25, distributor_email: '', distributor_phone: '254721424830', manager_id: 3, updated_at: '1970-01-01T00:33:41.000000Z', created_at: '2018-10-18T09:15:29.000000Z', last_alias: 437, loan_type: 2, region_id: 2, contact_name: null, merchant_type: 5813, interest_rate: 0, pay_wallet_balance: 0, advance_limit: 0 }, { distributor_id: 6, distributor_name: 'G K Kamuri', distributor_alias: G, status: 1, date_created: '2018-10-18 12:16:25', created_by: 25, distributor_email: '', distributor_phone: '254726738571', manager_id: 3, updated_at: '1970-01-01T00:33:41.000000Z', created_at: '2018-10-18T09:16:25.000000Z', last_alias: 253, loan_type: 2, region_id: 2, contact_name: null, merchant_type: 5813, interest_rate: 0, pay_wallet_balance: 0, advance_limit: 0 }, { distributor_id: 7, distributor_name: 'Aspendos K Limited', distributor_alias: A, status: 1, date_created: '2018-10-18 12:17:34', created_by: 25, distributor_email: '', distributor_phone: '254725080622', manager_id: 3, updated_at: '1970-01-01T00:33:42.000000Z', created_at: '2018-10-18T09:17:34.000000Z', last_alias: 335, loan_type: 2, region_id: 2, contact_name: null, merchant_type: 5813, interest_rate: 0, pay_wallet_balance: 0, advance_limit: 0 }, { distributor_id: 8, distributor_name: 'Ibangua Distributors', distributor_alias: U, status: 1, date_created: '2018-10-18 12:18:08', created_by: 25, distributor_email: '', distributor_phone: '254716102372', manager_id: 3, updated_at: '1970-01-01T00:33:41.000000Z', created_at: '2018-10-18T09:18:08.000000Z', last_alias: 285, loan_type: 2, region_id: 2, contact_name: null, merchant_type: 5813, interest_rate: 0, pay_wallet_balance: 0, advance_limit: 0 }, { distributor_id: 9, distributor_name: 'Muranga Wholesalers', distributor_alias: R, status: 1, date_created: '2018-10-18 12:18:53', created_by: 25, distributor_email: '', distributor_phone: '254723236591', manager_id: 3, updated_at: '1970-01-01T00:33:41.000000Z', created_at: '2018-10-18T09:18:53.000000Z', last_alias: 268, loan_type: 2, region_id: 2, contact_name: null, merchant_type: 5813, interest_rate: 0, pay_wallet_balance: 0, advance_limit: 0 }, { distributor_id: 10, distributor_name: 'Kinginya and Sons', distributor_alias: 'Y', status: 1, date_created: '2018-10-18 12:26:49', created_by: 25, distributor_email: '', distributor_phone: '254719575653', manager_id: 3, updated_at: '1970-01-01T00:33:42.000000Z', created_at: '2018-10-18T09:26:49.000000Z', last_alias: 561, loan_type: 2, region_id: 2, contact_name: null, merchant_type: 5813, interest_rate: 0, pay_wallet_balance: 0, advance_limit: 0 }, { distributor_id: 11, distributor_name: 'D O Stores Eldoret', distributor_alias: D, status: 1, date_created: '2018-10-18 12:28:56', created_by: 25, distributor_email: '', distributor_phone: '254703777902', manager_id: 4, updated_at: '1970-01-01T00:33:41.000000Z', created_at: '2018-10-18T09:28:56.000000Z', last_alias: 1196, loan_type: 2, region_id: 2, contact_name: null, merchant_type: 5813, interest_rate: 0, pay_wallet_balance: 0, advance_limit: 0 }]
                                    links: { first: 'http://localhost/api/distributors?filter%5Bcategory%5D=8&page%5Bsize%5D=8&filter%5Bsearch%5D=architecto&page%5Bnumber%5D=1', last: 'http://localhost/api/distributors?filter%5Bcategory%5D=8&page%5Bsize%5D=8&filter%5Bsearch%5D=architecto&page%5Bnumber%5D=23', prev: null, next: 'http://localhost/api/distributors?filter%5Bcategory%5D=8&page%5Bsize%5D=8&filter%5Bsearch%5D=architecto&page%5Bnumber%5D=2' }
                                    meta: { current_page: 1, from: 1, last_page: 23, path: 'http://localhost/api/distributors', per_page: 10, to: 10, total: 228 }
                                properties:
                                    data: { type: array, example: [{ distributor_id: 2, distributor_name: 'Mt Kenya Beer', distributor_alias: E, status: 1, date_created: '2018-10-18 12:10:13', created_by: 25, distributor_email: '', distributor_phone: '254722556306', manager_id: 3, updated_at: '1970-01-01T00:33:42.000000Z', created_at: '2018-10-18T09:10:13.000000Z', last_alias: 554, loan_type: 2, region_id: 2, contact_name: null, merchant_type: 5813, interest_rate: 0, pay_wallet_balance: 0, advance_limit: 0 }, { distributor_id: 3, distributor_name: 'Lawrence Duncan Rift Valley', distributor_alias: '', status: 1, date_created: '2018-10-18 12:13:16', created_by: 25, distributor_email: '', distributor_phone: '254701897794', manager_id: 4, updated_at: '1970-01-01T00:33:41.000000Z', created_at: '2018-10-18T09:13:16.000000Z', last_alias: 159, loan_type: 2, region_id: 2, contact_name: null, merchant_type: 5813, interest_rate: 0, pay_wallet_balance: 0, advance_limit: 0 }, { distributor_id: 4, distributor_name: 'Peanco Limited', distributor_alias: C, status: 1, date_created: '2018-10-18 12:14:41', created_by: 25, distributor_email: '', distributor_phone: '254790147214', manager_id: 3, updated_at: '1970-01-01T00:33:41.000000Z', created_at: '2018-10-18T09:14:41.000000Z', last_alias: 527, loan_type: 2, region_id: 2, contact_name: null, merchant_type: 5813, interest_rate: 2, pay_wallet_balance: 840, advance_limit: 1000 }, { distributor_id: 5, distributor_name: 'Erinpet Enterprises', distributor_alias: P, status: 1, date_created: '2018-10-18 12:15:29', created_by: 25, distributor_email: '', distributor_phone: '254721424830', manager_id: 3, updated_at: '1970-01-01T00:33:41.000000Z', created_at: '2018-10-18T09:15:29.000000Z', last_alias: 437, loan_type: 2, region_id: 2, contact_name: null, merchant_type: 5813, interest_rate: 0, pay_wallet_balance: 0, advance_limit: 0 }, { distributor_id: 6, distributor_name: 'G K Kamuri', distributor_alias: G, status: 1, date_created: '2018-10-18 12:16:25', created_by: 25, distributor_email: '', distributor_phone: '254726738571', manager_id: 3, updated_at: '1970-01-01T00:33:41.000000Z', created_at: '2018-10-18T09:16:25.000000Z', last_alias: 253, loan_type: 2, region_id: 2, contact_name: null, merchant_type: 5813, interest_rate: 0, pay_wallet_balance: 0, advance_limit: 0 }, { distributor_id: 7, distributor_name: 'Aspendos K Limited', distributor_alias: A, status: 1, date_created: '2018-10-18 12:17:34', created_by: 25, distributor_email: '', distributor_phone: '254725080622', manager_id: 3, updated_at: '1970-01-01T00:33:42.000000Z', created_at: '2018-10-18T09:17:34.000000Z', last_alias: 335, loan_type: 2, region_id: 2, contact_name: null, merchant_type: 5813, interest_rate: 0, pay_wallet_balance: 0, advance_limit: 0 }, { distributor_id: 8, distributor_name: 'Ibangua Distributors', distributor_alias: U, status: 1, date_created: '2018-10-18 12:18:08', created_by: 25, distributor_email: '', distributor_phone: '254716102372', manager_id: 3, updated_at: '1970-01-01T00:33:41.000000Z', created_at: '2018-10-18T09:18:08.000000Z', last_alias: 285, loan_type: 2, region_id: 2, contact_name: null, merchant_type: 5813, interest_rate: 0, pay_wallet_balance: 0, advance_limit: 0 }, { distributor_id: 9, distributor_name: 'Muranga Wholesalers', distributor_alias: R, status: 1, date_created: '2018-10-18 12:18:53', created_by: 25, distributor_email: '', distributor_phone: '254723236591', manager_id: 3, updated_at: '1970-01-01T00:33:41.000000Z', created_at: '2018-10-18T09:18:53.000000Z', last_alias: 268, loan_type: 2, region_id: 2, contact_name: null, merchant_type: 5813, interest_rate: 0, pay_wallet_balance: 0, advance_limit: 0 }, { distributor_id: 10, distributor_name: 'Kinginya and Sons', distributor_alias: 'Y', status: 1, date_created: '2018-10-18 12:26:49', created_by: 25, distributor_email: '', distributor_phone: '254719575653', manager_id: 3, updated_at: '1970-01-01T00:33:42.000000Z', created_at: '2018-10-18T09:26:49.000000Z', last_alias: 561, loan_type: 2, region_id: 2, contact_name: null, merchant_type: 5813, interest_rate: 0, pay_wallet_balance: 0, advance_limit: 0 }, { distributor_id: 11, distributor_name: 'D O Stores Eldoret', distributor_alias: D, status: 1, date_created: '2018-10-18 12:28:56', created_by: 25, distributor_email: '', distributor_phone: '254703777902', manager_id: 4, updated_at: '1970-01-01T00:33:41.000000Z', created_at: '2018-10-18T09:28:56.000000Z', last_alias: 1196, loan_type: 2, region_id: 2, contact_name: null, merchant_type: 5813, interest_rate: 0, pay_wallet_balance: 0, advance_limit: 0 }], items: { type: object } }
                                    links: { type: object, example: { first: 'http://localhost/api/distributors?filter%5Bcategory%5D=8&page%5Bsize%5D=8&filter%5Bsearch%5D=architecto&page%5Bnumber%5D=1', last: 'http://localhost/api/distributors?filter%5Bcategory%5D=8&page%5Bsize%5D=8&filter%5Bsearch%5D=architecto&page%5Bnumber%5D=23', prev: null, next: 'http://localhost/api/distributors?filter%5Bcategory%5D=8&page%5Bsize%5D=8&filter%5Bsearch%5D=architecto&page%5Bnumber%5D=2' } }
                                    meta: { type: object, example: { current_page: 1, from: 1, last_page: 23, path: 'http://localhost/api/distributors', per_page: 10, to: 10, total: 228 } }
            tags:
                - Distributors
            security: []
    /api/contact-us:
        post:
            summary: ''
            description: ''
            parameters:
                -
                    in: header
                    name: Content-Type
                    description: ''
                    example: application/json
                    schema:
                        type: string
                -
                    in: header
                    name: Accept
                    description: ''
                    example: application/json
                    schema:
                        type: string
            responses: {  }
            tags:
                - Endpoints
            security: []
    /api/agents:
        post:
            summary: 'Agent/VSM Registration'
            description: 'Register a new agent or VSM'
            parameters:
                -
                    in: header
                    name: Content-Type
                    description: ''
                    example: application/json
                    schema:
                        type: string
                -
                    in: header
                    name: Accept
                    description: ''
                    example: application/json
                    schema:
                        type: string
            responses: {  }
            tags:
                - Endpoints
            requestBody:
                required: true
                content:
                    application/json:
                        schema:
                            type: object
                            properties:
                                name:
                                    type: string
                                    description: 'Agent Name'
                                    example: accusantium
                                phone_number:
                                    type: string
                                    description: 'Agent Phone Number'
                                    example: omnis
                                distributor_id:
                                    type: integer
                                    description: 'Agent Assigned Distributor'
                                    example: 4
                                pin:
                                    type: integer
                                    description: 'Agent log in PIN'
                                    example: 5
                            required:
                                - name
                                - phone_number
                                - distributor_id
                                - pin
            security: []
    /api/dashboard:
        get:
            summary: 'Distributor dashboard'
            description: ''
            parameters:
                -
                    in: query
                    name: 'filters[period]'
                    description: 'Filter by transaction period'
                    example: monthly
                    required: false
                    schema:
                        type: string
                        description: 'Filter by transaction period'
                        example: monthly
                -
                    in: header
                    name: Authorization
                    description: ''
                    example: 'Bearer {YOUR_AUTH_KEY}'
                    schema:
                        type: string
                -
                    in: header
                    name: Content-Type
                    description: ''
                    example: application/json
                    schema:
                        type: string
                -
                    in: header
                    name: Accept
                    description: ''
                    example: application/json
                    schema:
                        type: string
            responses:
                401:
                    description: ''
                    content:
                        application/json:
                            schema:
                                type: object
                                example:
                                    message: Unauthenticated.
                                properties:
                                    message: { type: string, example: Unauthenticated. }
            tags:
                - Endpoints
    /api/sales:
        get:
            summary: 'Sales summary'
            description: ''
            parameters:
                -
                    in: query
                    name: 'filters[period]'
                    description: 'Filter by transaction period'
                    example: monthly
                    required: false
                    schema:
                        type: string
                        description: 'Filter by transaction period'
                        example: monthly
                -
                    in: header
                    name: Authorization
                    description: ''
                    example: 'Bearer {YOUR_AUTH_KEY}'
                    schema:
                        type: string
                -
                    in: header
                    name: Content-Type
                    description: ''
                    example: application/json
                    schema:
                        type: string
                -
                    in: header
                    name: Accept
                    description: ''
                    example: application/json
                    schema:
                        type: string
            responses:
                401:
                    description: ''
                    content:
                        application/json:
                            schema:
                                type: object
                                example:
                                    message: Unauthenticated.
                                properties:
                                    message: { type: string, example: Unauthenticated. }
            tags:
                - Endpoints
    /api/stock-credit:
        get:
            summary: 'Stock credit summary'
            description: ''
            parameters:
                -
                    in: query
                    name: 'filters[period]'
                    description: 'Filter by transaction period'
                    example: monthly
                    required: false
                    schema:
                        type: string
                        description: 'Filter by transaction period'
                        example: monthly
                -
                    in: header
                    name: Authorization
                    description: ''
                    example: 'Bearer {YOUR_AUTH_KEY}'
                    schema:
                        type: string
                -
                    in: header
                    name: Content-Type
                    description: ''
                    example: application/json
                    schema:
                        type: string
                -
                    in: header
                    name: Accept
                    description: ''
                    example: application/json
                    schema:
                        type: string
            responses:
                401:
                    description: ''
                    content:
                        application/json:
                            schema:
                                type: object
                                example:
                                    message: Unauthenticated.
                                properties:
                                    message: { type: string, example: Unauthenticated. }
            tags:
                - Endpoints
    /api/finance/stock-credit:
        get:
            summary: 'Stock credit details'
            description: ''
            parameters:
                -
                    in: query
                    name: 'page[number]'
                    description: 'Page number'
                    example: 12
                    required: false
                    schema:
                        type: integer
                        description: 'Page number'
                        example: 12
                -
                    in: query
                    name: 'page[size]'
                    description: 'Number of records on a page'
                    example: 10
                    required: false
                    schema:
                        type: integer
                        description: 'Number of records on a page'
                        example: 10
                -
                    in: query
                    name: 'filter[start_date]'
                    description: 'date Filter start date'
                    example: '2021-06-01'
                    required: false
                    schema:
                        type: string
                        description: 'date Filter start date'
                        example: '2021-06-01'
                -
                    in: query
                    name: 'filter[end_date]'
                    description: 'date Filter end date'
                    example: '2021-06-30'
                    required: false
                    schema:
                        type: string
                        description: 'date Filter end date'
                        example: '2021-06-30'
                -
                    in: query
                    name: 'filter[search]'
                    description: 'Filter by query'
                    example: voluptatem
                    required: false
                    schema:
                        type: string
                        description: 'Filter by query'
                        example: voluptatem
                -
                    in: header
                    name: Authorization
                    description: ''
                    example: 'Bearer {YOUR_AUTH_KEY}'
                    schema:
                        type: string
                -
                    in: header
                    name: Content-Type
                    description: ''
                    example: application/json
                    schema:
                        type: string
                -
                    in: header
                    name: Accept
                    description: ''
                    example: application/json
                    schema:
                        type: string
            responses:
                401:
                    description: ''
                    content:
                        application/json:
                            schema:
                                type: object
                                example:
                                    message: Unauthenticated.
                                properties:
                                    message: { type: string, example: Unauthenticated. }
            tags:
                - Endpoints
    /api/finance/stock-credit/export:
        get:
            summary: 'Export credit sales'
            description: ''
            parameters:
                -
                    in: query
                    name: 'filter[start_date]'
                    description: 'date Filter start date'
                    example: '2021-06-01'
                    required: false
                    schema:
                        type: string
                        description: 'date Filter start date'
                        example: '2021-06-01'
                -
                    in: query
                    name: 'filter[end_date]'
                    description: 'date Filter end date'
                    example: '2021-06-30'
                    required: false
                    schema:
                        type: string
                        description: 'date Filter end date'
                        example: '2021-06-30'
                -
                    in: query
                    name: 'filter[search]'
                    description: 'Filter by query'
                    example: delectus
                    required: false
                    schema:
                        type: string
                        description: 'Filter by query'
                        example: delectus
                -
                    in: header
                    name: Authorization
                    description: ''
                    example: 'Bearer {YOUR_AUTH_KEY}'
                    schema:
                        type: string
                -
                    in: header
                    name: Content-Type
                    description: ''
                    example: application/json
                    schema:
                        type: string
                -
                    in: header
                    name: Accept
                    description: ''
                    example: application/json
                    schema:
                        type: string
            responses:
                401:
                    description: ''
                    content:
                        application/json:
                            schema:
                                type: object
                                example:
                                    message: Unauthenticated.
                                properties:
                                    message: { type: string, example: Unauthenticated. }
            tags:
                - Endpoints
    /api/finance/sales:
        get:
            summary: 'Sales details'
            description: ''
            parameters:
                -
                    in: query
                    name: 'page[number]'
                    description: 'Page number'
                    example: 15
                    required: false
                    schema:
                        type: integer
                        description: 'Page number'
                        example: 15
                -
                    in: query
                    name: 'page[size]'
                    description: 'Number of records on a page'
                    example: 18
                    required: false
                    schema:
                        type: integer
                        description: 'Number of records on a page'
                        example: 18
                -
                    in: query
                    name: 'filter[start_date]'
                    description: 'date Filter start date'
                    example: '2021-06-01'
                    required: false
                    schema:
                        type: string
                        description: 'date Filter start date'
                        example: '2021-06-01'
                -
                    in: query
                    name: 'filter[end_date]'
                    description: 'date Filter end date'
                    example: '2021-06-30'
                    required: false
                    schema:
                        type: string
                        description: 'date Filter end date'
                        example: '2021-06-30'
                -
                    in: query
                    name: 'filter[search]'
                    description: 'Filter by query'
                    example: unde
                    required: false
                    schema:
                        type: string
                        description: 'Filter by query'
                        example: unde
                -
                    in: header
                    name: Authorization
                    description: ''
                    example: 'Bearer {YOUR_AUTH_KEY}'
                    schema:
                        type: string
                -
                    in: header
                    name: Content-Type
                    description: ''
                    example: application/json
                    schema:
                        type: string
                -
                    in: header
                    name: Accept
                    description: ''
                    example: application/json
                    schema:
                        type: string
            responses:
                401:
                    description: ''
                    content:
                        application/json:
                            schema:
                                type: object
                                example:
                                    message: Unauthenticated.
                                properties:
                                    message: { type: string, example: Unauthenticated. }
            tags:
                - Endpoints
    /api/tills:
        get:
            summary: 'Shows authenticated user tills assigned'
            description: ''
            parameters:
                -
                    in: header
                    name: Authorization
                    description: ''
                    example: 'Bearer {YOUR_AUTH_KEY}'
                    schema:
                        type: string
                -
                    in: header
                    name: Content-Type
                    description: ''
                    example: application/json
                    schema:
                        type: string
                -
                    in: header
                    name: Accept
                    description: ''
                    example: application/json
                    schema:
                        type: string
            responses:
                401:
                    description: ''
                    content:
                        application/json:
                            schema:
                                type: object
                                example:
                                    message: Unauthenticated.
                                properties:
                                    message: { type: string, example: Unauthenticated. }
            tags:
                - Endpoints
    /api/whitelist:
        get:
            summary: ''
            description: ''
            parameters:
                -
                    in: header
                    name: Content-Type
                    description: ''
                    example: application/json
                    schema:
                        type: string
                -
                    in: header
                    name: Accept
                    description: ''
                    example: application/json
                    schema:
                        type: string
            responses:
                401:
                    description: ''
                    content:
                        application/json:
                            schema:
                                type: object
                                example:
                                    message: Unauthenticated.
                                properties:
                                    message: { type: string, example: Unauthenticated. }
            tags:
                - Endpoints
            security: []
    /api/reassign/till:
        post:
            summary: 'Auto-Assign/Revoke automated till number'
            description: ''
            parameters:
                -
                    in: header
                    name: Authorization
                    description: ''
                    example: 'Bearer {YOUR_AUTH_KEY}'
                    schema:
                        type: string
                -
                    in: header
                    name: Content-Type
                    description: ''
                    example: application/json
                    schema:
                        type: string
                -
                    in: header
                    name: Accept
                    description: ''
                    example: application/json
                    schema:
                        type: string
            responses: {  }
            tags:
                - Endpoints
            requestBody:
                required: true
                content:
                    application/json:
                        schema:
                            type: object
                            properties:
                                action:
                                    type: string
                                    description: 'for action only two options. i.e assign, revoke'
                                    example: blanditiis
                                till_number:
                                    type: integer
                                    description: 'Distributor till number'
                                    example: 12345
                            required:
                                - action
                                - till_number
    '/api/tills/{till}':
        get:
            summary: 'Get till details'
            description: ''
            parameters:
                -
                    in: header
                    name: Authorization
                    description: ''
                    example: 'Bearer {YOUR_AUTH_KEY}'
                    schema:
                        type: string
                -
                    in: header
                    name: Content-Type
                    description: ''
                    example: application/json
                    schema:
                        type: string
                -
                    in: header
                    name: Accept
                    description: ''
                    example: application/json
                    schema:
                        type: string
            responses:
                401:
                    description: ''
                    content:
                        application/json:
                            schema:
                                type: object
                                example:
                                    message: Unauthenticated.
                                properties:
                                    message: { type: string, example: Unauthenticated. }
            tags:
                - Endpoints
        parameters:
            -
                in: path
                name: till
                description: 'Till Number'
                example: 17
                required: true
                schema:
                    type: integer
    /api/loans:
        get:
            summary: ''
            description: ''
            parameters:
                -
                    in: header
                    name: Content-Type
                    description: ''
                    example: application/json
                    schema:
                        type: string
                -
                    in: header
                    name: Accept
                    description: ''
                    example: application/json
                    schema:
                        type: string
            responses:
                401:
                    description: ''
                    content:
                        application/json:
                            schema:
                                type: object
                                example:
                                    message: Unauthenticated.
                                properties:
                                    message: { type: string, example: Unauthenticated. }
            tags:
                - Loans
            security: []
        post:
            summary: 'Make Loan Payment'
            description: ''
            parameters:
                -
                    in: header
                    name: Authorization
                    description: ''
                    example: 'Bearer {YOUR_AUTH_KEY}'
                    schema:
                        type: string
                -
                    in: header
                    name: Content-Type
                    description: ''
                    example: application/json
                    schema:
                        type: string
                -
                    in: header
                    name: Accept
                    description: ''
                    example: application/json
                    schema:
                        type: string
            responses: {  }
            tags:
                - Loans
            requestBody:
                required: true
                content:
                    application/json:
                        schema:
                            type: object
                            properties:
                                amount:
                                    type: string
                                    description: 'Amount being paid'
                                    example: '2'
                                phone_number:
                                    type: string
                                    description: 'Alternative Phone Number'
                                    example: '+254123456789'
                            required:
                                - amount
    /api/loans/limit:
        get:
            summary: 'Check loan limit'
            description: ''
            parameters:
                -
                    in: header
                    name: Authorization
                    description: ''
                    example: 'Bearer {YOUR_AUTH_KEY}'
                    schema:
                        type: string
                -
                    in: header
                    name: Content-Type
                    description: ''
                    example: application/json
                    schema:
                        type: string
                -
                    in: header
                    name: Accept
                    description: ''
                    example: application/json
                    schema:
                        type: string
            responses:
                401:
                    description: ''
                    content:
                        application/json:
                            schema:
                                type: object
                                example:
                                    message: Unauthenticated.
                                properties:
                                    message: { type: string, example: Unauthenticated. }
            tags:
                - Loans
    '/api/loans/{loan}':
        get:
            summary: 'Get single loan details'
            description: ''
            parameters:
                -
                    in: header
                    name: Authorization
                    description: ''
                    example: 'Bearer {YOUR_AUTH_KEY}'
                    schema:
                        type: string
                -
                    in: header
                    name: Content-Type
                    description: ''
                    example: application/json
                    schema:
                        type: string
                -
                    in: header
                    name: Accept
                    description: ''
                    example: application/json
                    schema:
                        type: string
            responses:
                401:
                    description: ''
                    content:
                        application/json:
                            schema:
                                type: object
                                example:
                                    message: Unauthenticated.
                                properties:
                                    message: { type: string, example: Unauthenticated. }
            tags:
                - Loans
        parameters:
            -
                in: path
                name: loan
                description: 'loan id'
                example: 10
                required: true
                schema:
                    type: integer
    /api/loans/agentlimit:
        post:
            summary: ''
            description: ''
            parameters:
                -
                    in: header
                    name: Content-Type
                    description: ''
                    example: application/json
                    schema:
                        type: string
                -
                    in: header
                    name: Accept
                    description: ''
                    example: application/json
                    schema:
                        type: string
            responses: {  }
            tags:
                - Loans
            security: []
    /api/merchants:
        post:
            summary: 'Register a new merchant.'
            description: ''
            parameters:
                -
                    in: header
                    name: Content-Type
                    description: ''
                    example: application/json
                    schema:
                        type: string
                -
                    in: header
                    name: Accept
                    description: ''
                    example: application/json
                    schema:
                        type: string
            responses: {  }
            tags:
                - Merchants
            requestBody:
                required: true
                content:
                    application/json:
                        schema:
                            type: object
                            properties:
                                phone_number:
                                    type: string
                                    description: ''
                                    example: omnis
                                otp:
                                    type: string
                                    description: ''
                                    example: omnis
                                category_code:
                                    type: string
                                    description: ''
                                    example: vel
                            required:
                                - phone_number
                                - otp
                                - category_code
            security: []
    '/api/merchants/{merchant}/national-id':
        post:
            summary: 'Upload merchant ID'
            description: ''
            parameters:
                -
                    in: header
                    name: Authorization
                    description: ''
                    example: 'Bearer {YOUR_AUTH_KEY}'
                    schema:
                        type: string
                -
                    in: header
                    name: Content-Type
                    description: ''
                    example: multipart/form-data
                    schema:
                        type: string
                -
                    in: header
                    name: Accept
                    description: ''
                    example: application/json
                    schema:
                        type: string
            responses: {  }
            tags:
                - Merchants
            requestBody:
                required: true
                content:
                    multipart/form-data:
                        schema:
                            type: object
                            properties:
                                front:
                                    type: string
                                    format: binary
                                    description: ''
                                back:
                                    type: string
                                    format: binary
                                    description: ''
                            required:
                                - front
                                - back
        parameters:
            -
                in: path
                name: merchant
                description: ''
                example: 2
                required: true
                schema:
                    type: integer
    '/api/merchants/{merchant}/business-permit':
        post:
            summary: 'Upload business permit'
            description: ''
            parameters:
                -
                    in: header
                    name: Authorization
                    description: ''
                    example: 'Bearer {YOUR_AUTH_KEY}'
                    schema:
                        type: string
                -
                    in: header
                    name: Content-Type
                    description: ''
                    example: multipart/form-data
                    schema:
                        type: string
                -
                    in: header
                    name: Accept
                    description: ''
                    example: application/json
                    schema:
                        type: string
            responses: {  }
            tags:
                - Merchants
            requestBody:
                required: true
                content:
                    multipart/form-data:
                        schema:
                            type: object
                            properties:
                                business_permit:
                                    type: string
                                    format: binary
                                    description: ''
                            required:
                                - business_permit
        parameters:
            -
                in: path
                name: merchant
                description: ''
                example: 20
                required: true
                schema:
                    type: integer
    '/api/merchants/{merchant}/mpesa-statement':
        post:
            summary: 'Upload mpesa statement'
            description: ''
            parameters:
                -
                    in: header
                    name: Authorization
                    description: ''
                    example: 'Bearer {YOUR_AUTH_KEY}'
                    schema:
                        type: string
                -
                    in: header
                    name: Content-Type
                    description: ''
                    example: multipart/form-data
                    schema:
                        type: string
                -
                    in: header
                    name: Accept
                    description: ''
                    example: application/json
                    schema:
                        type: string
            responses: {  }
            tags:
                - Merchants
            requestBody:
                required: true
                content:
                    multipart/form-data:
                        schema:
                            type: object
                            properties:
                                mpesa_statement:
                                    type: string
                                    format: binary
                                    description: ''
                            required:
                                - mpesa_statement
        parameters:
            -
                in: path
                name: merchant
                description: ''
                example: 17
                required: true
                schema:
                    type: integer
    '/api/merchants{merchant}':
        put:
            summary: 'Update merchant details.'
            description: ''
            parameters:
                -
                    in: header
                    name: Authorization
                    description: ''
                    example: 'Bearer {YOUR_AUTH_KEY}'
                    schema:
                        type: string
                -
                    in: header
                    name: Content-Type
                    description: ''
                    example: application/json
                    schema:
                        type: string
                -
                    in: header
                    name: Accept
                    description: ''
                    example: application/json
                    schema:
                        type: string
            responses: {  }
            tags:
                - Merchants
            requestBody:
                required: true
                content:
                    application/json:
                        schema:
                            type: object
                            properties:
                                merchant_name:
                                    type: string
                                    description: ''
                                    example: velit
                                business_name:
                                    type: string
                                    description: ''
                                    example: nesciunt
                                email:
                                    type: string
                                    description: ''
                                    example: ipsa
                                location:
                                    type: string
                                    description: ''
                                    example: et
                            required:
                                - merchant_name
                                - business_name
                                - email
                                - location
        parameters:
            -
                in: path
                name: merchant
                description: ''
                example: 12
                required: true
                schema:
                    type: integer
    '/api/merchants/{merchant}/application':
        get:
            summary: 'Get application status.'
            description: ''
            parameters:
                -
                    in: header
                    name: Content-Type
                    description: ''
                    example: application/json
                    schema:
                        type: string
                -
                    in: header
                    name: Accept
                    description: ''
                    example: application/json
                    schema:
                        type: string
            responses:
                401:
                    description: ''
                    content:
                        application/json:
                            schema:
                                type: object
                                example:
                                    message: Unauthenticated.
                                properties:
                                    message: { type: string, example: Unauthenticated. }
            tags:
                - Merchants
            security: []
        parameters:
            -
                in: path
                name: merchant
                description: ''
                example: 7
                required: true
                schema:
                    type: integer
    /api/send-otp:
        post:
            summary: 'Generate OTP'
            description: ''
            parameters:
                -
                    in: header
                    name: Content-Type
                    description: ''
                    example: application/json
                    schema:
                        type: string
                -
                    in: header
                    name: Accept
                    description: ''
                    example: application/json
                    schema:
                        type: string
            responses: {  }
            tags:
                - OTP
            requestBody:
                required: true
                content:
                    application/json:
                        schema:
                            type: object
                            properties:
                                phone_number:
                                    type: string
                                    description: 'Phone Number'
                                    example: magni
                            required:
                                - phone_number
            security: []
    '/api/verify-otp/{otp}':
        get:
            summary: 'Verify OTP'
            description: ''
            parameters:
                -
                    in: header
                    name: Content-Type
                    description: ''
                    example: application/json
                    schema:
                        type: string
                -
                    in: header
                    name: Accept
                    description: ''
                    example: application/json
                    schema:
                        type: string
            responses:
                422:
                    description: ''
                    content:
                        application/json:
                            schema:
                                type: object
                                example:
                                    message: 'OTP code is not valid'
                                properties:
                                    message: { type: string, example: 'OTP code is not valid' }
            tags:
                - OTP
            security: []
        parameters:
            -
                in: path
                name: otp
                description: 'OTP code'
                example: eveniet
                required: true
                schema:
                    type: string
    /api/orders:
        get:
            summary: 'List of orders'
            description: ''
            parameters:
                -
                    in: query
                    name: 'page[number]'
                    description: 'Page number'
                    example: 20
                    required: false
                    schema:
                        type: integer
                        description: 'Page number'
                        example: 20
                -
                    in: query
                    name: 'page[size]'
                    description: 'Number of records on a page'
                    example: 5
                    required: false
                    schema:
                        type: integer
                        description: 'Number of records on a page'
                        example: 5
                -
                    in: query
                    name: 'filter[start_date]'
                    description: 'date Filter start date'
                    example: '2021-06-01'
                    required: false
                    schema:
                        type: string
                        description: 'date Filter start date'
                        example: '2021-06-01'
                -
                    in: query
                    name: 'filter[end_date]'
                    description: 'date Filter end date'
                    example: 2021-06-30`
                    required: false
                    schema:
                        type: string
                        description: 'date Filter end date'
                        example: 2021-06-30`
                -
                    in: query
                    name: 'filter[search]'
                    description: 'Filter by query'
                    example: officiis
                    required: false
                    schema:
                        type: string
                        description: 'Filter by query'
                        example: officiis
                -
                    in: header
                    name: Authorization
                    description: ''
                    example: 'Bearer {YOUR_AUTH_KEY}'
                    schema:
                        type: string
                -
                    in: header
                    name: Content-Type
                    description: ''
                    example: application/json
                    schema:
                        type: string
                -
                    in: header
                    name: Accept
                    description: ''
                    example: application/json
                    schema:
                        type: string
            responses:
                401:
                    description: ''
                    content:
                        application/json:
                            schema:
                                type: object
                                example:
                                    message: Unauthenticated.
                                properties:
                                    message: { type: string, example: Unauthenticated. }
            tags:
                - Orders
    '/api/orders/{order}':
        patch:
            summary: 'Update order'
            description: ''
            parameters:
                -
                    in: header
                    name: Authorization
                    description: ''
                    example: 'Bearer {YOUR_AUTH_KEY}'
                    schema:
                        type: string
                -
                    in: header
                    name: Content-Type
                    description: ''
                    example: application/json
                    schema:
                        type: string
                -
                    in: header
                    name: Accept
                    description: ''
                    example: application/json
                    schema:
                        type: string
            responses: {  }
            tags:
                - Orders
            requestBody:
                required: true
                content:
                    application/json:
                        schema:
                            type: object
                            properties:
                                status:
                                    type: string
                                    description: 'Order Status'
                                    example: aperiam
                            required:
                                - status
        parameters:
            -
                in: path
                name: order
                description: ''
                example: consequatur
                required: true
                schema:
                    type: string
    /api/agent/orders:
        get:
            summary: 'Agent Orders'
            description: 'Get all orders assigned to an agent'
            parameters:
                -
                    in: query
                    name: 'page[number]'
                    description: 'Page number'
                    example: 8
                    required: false
                    schema:
                        type: integer
                        description: 'Page number'
                        example: 8
                -
                    in: query
                    name: 'page[size]'
                    description: 'Number of records on a page'
                    example: 13
                    required: false
                    schema:
                        type: integer
                        description: 'Number of records on a page'
                        example: 13
                -
                    in: query
                    name: 'filter[search]'
                    description: 'Filter by query'
                    example: dolorum
                    required: false
                    schema:
                        type: string
                        description: 'Filter by query'
                        example: dolorum
                -
                    in: query
                    name: 'filter[status]'
                    description: 'Filter by agent status'
                    example: Pending
                    required: false
                    schema:
                        type: string
                        description: 'Filter by agent status'
                        example: Pending
                -
                    in: query
                    name: 'filter[due]'
                    description: 'Filter by due date'
                    example: today
                    required: false
                    schema:
                        type: string
                        description: 'Filter by due date'
                        example: today
                -
                    in: header
                    name: Authorization
                    description: ''
                    example: 'Bearer {YOUR_AUTH_KEY}'
                    schema:
                        type: string
                -
                    in: header
                    name: Content-Type
                    description: ''
                    example: application/json
                    schema:
                        type: string
                -
                    in: header
                    name: Accept
                    description: ''
                    example: application/json
                    schema:
                        type: string
            responses:
                401:
                    description: ''
                    content:
                        application/json:
                            schema:
                                type: object
                                example:
                                    message: Unauthenticated.
                                properties:
                                    message: { type: string, example: Unauthenticated. }
            tags:
                - Orders
        post:
            summary: 'Agent New Order'
            description: 'Create a new order on behalf of customer'
            parameters:
                -
                    in: header
                    name: Authorization
                    description: ''
                    example: 'Bearer {YOUR_AUTH_KEY}'
                    schema:
                        type: string
                -
                    in: header
                    name: Content-Type
                    description: ''
                    example: application/json
                    schema:
                        type: string
                -
                    in: header
                    name: Accept
                    description: ''
                    example: application/json
                    schema:
                        type: string
            responses: {  }
            tags:
                - Orders
            requestBody:
                required: true
                content:
                    application/json:
                        schema:
                            type: object
                            properties:
                                customer_id:
                                    type: string
                                    description: 'Customer ID'
                                    example: '1245'
                                amount:
                                    type: integer
                                    description: 'Amount to borrow'
                                    example: 5000
                                till_number:
                                    type: integer
                                    description: 'Distributor till number'
                                    example: 12345
                                account_number:
                                    type: string
                                    description: 'Customer account number'
                                    example: XS234
                                products:
                                    type: array
                                    description: 'Products selected for payment'
                                    example: [[], []]
                                    items: { type: object, properties: { id: { type: integer, description: '', example: 14 }, quantity: { type: integer, description: '', example: 6 } }, required: [id, quantity] }
                            required:
                                - customer_id
                                - amount
                                - till_number
    /api/agent/orders-due:
        get:
            summary: 'Agent Orders Due'
            description: ''
            parameters:
                -
                    in: query
                    name: 'page[number]'
                    description: 'Page number'
                    example: 11
                    required: false
                    schema:
                        type: integer
                        description: 'Page number'
                        example: 11
                -
                    in: query
                    name: 'page[size]'
                    description: 'Number of records on a page'
                    example: 18
                    required: false
                    schema:
                        type: integer
                        description: 'Number of records on a page'
                        example: 18
                -
                    in: header
                    name: Authorization
                    description: ''
                    example: 'Bearer {YOUR_AUTH_KEY}'
                    schema:
                        type: string
                -
                    in: header
                    name: Content-Type
                    description: ''
                    example: application/json
                    schema:
                        type: string
                -
                    in: header
                    name: Accept
                    description: ''
                    example: application/json
                    schema:
                        type: string
            responses:
                401:
                    description: ''
                    content:
                        application/json:
                            schema:
                                type: object
                                example:
                                    message: Unauthenticated.
                                properties:
                                    message: { type: string, example: Unauthenticated. }
            tags:
                - Orders
    /api/agent/orders-duemap:
        get:
            summary: ''
            description: ''
            parameters:
                -
                    in: header
                    name: Content-Type
                    description: ''
                    example: application/json
                    schema:
                        type: string
                -
                    in: header
                    name: Accept
                    description: ''
                    example: application/json
                    schema:
                        type: string
            responses:
                401:
                    description: ''
                    content:
                        application/json:
                            schema:
                                type: object
                                example:
                                    message: Unauthenticated.
                                properties:
                                    message: { type: string, example: Unauthenticated. }
            tags:
                - Orders
            security: []
    /api/agent/orders-past:
        get:
            summary: ''
            description: ''
            parameters:
                -
                    in: header
                    name: Content-Type
                    description: ''
                    example: application/json
                    schema:
                        type: string
                -
                    in: header
                    name: Accept
                    description: ''
                    example: application/json
                    schema:
                        type: string
            responses:
                401:
                    description: ''
                    content:
                        application/json:
                            schema:
                                type: object
                                example:
                                    message: Unauthenticated.
                                properties:
                                    message: { type: string, example: Unauthenticated. }
            tags:
                - Orders
            security: []
    /api/agent/orders-pastmap:
        get:
            summary: ''
            description: ''
            parameters:
                -
                    in: header
                    name: Content-Type
                    description: ''
                    example: application/json
                    schema:
                        type: string
                -
                    in: header
                    name: Accept
                    description: ''
                    example: application/json
                    schema:
                        type: string
            responses:
                401:
                    description: ''
                    content:
                        application/json:
                            schema:
                                type: object
                                example:
                                    message: Unauthenticated.
                                properties:
                                    message: { type: string, example: Unauthenticated. }
            tags:
                - Orders
            security: []
    '/api/agent/orders/{order}':
        put:
            summary: 'Agent Order Action'
            description: 'Approve or reject an order'
            parameters:
                -
                    in: header
                    name: Authorization
                    description: ''
                    example: 'Bearer {YOUR_AUTH_KEY}'
                    schema:
                        type: string
                -
                    in: header
                    name: Content-Type
                    description: ''
                    example: application/json
                    schema:
                        type: string
                -
                    in: header
                    name: Accept
                    description: ''
                    example: application/json
                    schema:
                        type: string
            responses: {  }
            tags:
                - Orders
            requestBody:
                required: false
                content:
                    application/json:
                        schema:
                            type: object
                            properties:
                                action:
                                    type: required
                                    description: 'string Selected agent action'
                                    example: Approve
        parameters:
            -
                in: path
                name: order
                description: 'Optional parameter. Selected order id'
                required: true
                schema:
                    type: integer
                examples:
                    omitted:
                        summary: 'When the value is omitted'
                        value: ''
                    present:
                        summary: 'When the value is present'
                        value: 0
    /api/tmregion:
        post:
            summary: ''
            description: ''
            parameters:
                -
                    in: header
                    name: Content-Type
                    description: ''
                    example: application/json
                    schema:
                        type: string
                -
                    in: header
                    name: Accept
                    description: ''
                    example: application/json
                    schema:
                        type: string
            responses: {  }
            tags:
                - Orders
            security: []
    /api/fetchProducts:
        get:
            summary: 'List of products'
            description: ''
            parameters:
                -
                    in: query
                    name: 'filter[category]'
                    description: 'Filter by category'
                    example: 14
                    required: false
                    schema:
                        type: integer
                        description: 'Filter by category'
                        example: 14
                -
                    in: query
                    name: 'filter[distributor]'
                    description: 'Filter by distributor'
                    example: 2
                    required: false
                    schema:
                        type: integer
                        description: 'Filter by distributor'
                        example: 2
                -
                    in: query
                    name: 'page[number]'
                    description: 'Page number'
                    example: 20
                    required: false
                    schema:
                        type: integer
                        description: 'Page number'
                        example: 20
                -
                    in: query
                    name: 'page[size]'
                    description: 'Number of records on a page'
                    example: 13
                    required: false
                    schema:
                        type: integer
                        description: 'Number of records on a page'
                        example: 13
                -
                    in: query
                    name: 'filter[search]'
                    description: 'Filter by query'
                    example: cumque
                    required: false
                    schema:
                        type: string
                        description: 'Filter by query'
                        example: cumque
                -
                    in: header
                    name: Authorization
                    description: ''
                    example: 'Bearer {YOUR_AUTH_KEY}'
                    schema:
                        type: string
                -
                    in: header
                    name: Content-Type
                    description: ''
                    example: application/json
                    schema:
                        type: string
                -
                    in: header
                    name: Accept
                    description: ''
                    example: application/json
                    schema:
                        type: string
            responses:
                401:
                    description: ''
                    content:
                        application/json:
                            schema:
                                type: object
                                example:
                                    message: Unauthenticated.
                                properties:
                                    message: { type: string, example: Unauthenticated. }
            tags:
                - Products
    /api/products/bulkUpload:
        post:
            summary: 'Bulk upload products'
            description: ''
            parameters:
                -
                    in: header
                    name: Content-Type
                    description: ''
                    example: application/json
                    schema:
                        type: string
                -
                    in: header
                    name: Accept
                    description: ''
                    example: application/json
                    schema:
                        type: string
            responses: {  }
            tags:
                - Products
            requestBody:
                required: false
                content:
                    application/json:
                        schema:
                            type: object
                            properties:
                                upload_batch:
                                    type: Excel
                                    description: 'doxument with upload list'
                                    example: dolor
                                image_batch:
                                    type: Array
                                    description: 'of images to upload'
                                    example: quidem
            security: []
    /api/products:
        get:
            summary: 'List of products'
            description: ''
            parameters:
                -
                    in: query
                    name: 'filter[category]'
                    description: 'Filter by category'
                    example: 1
                    required: false
                    schema:
                        type: integer
                        description: 'Filter by category'
                        example: 1
                -
                    in: query
                    name: 'filter[distributor]'
                    description: 'Filter by distributor'
                    example: 20
                    required: false
                    schema:
                        type: integer
                        description: 'Filter by distributor'
                        example: 20
                -
                    in: query
                    name: 'page[number]'
                    description: 'Page number'
                    example: 20
                    required: false
                    schema:
                        type: integer
                        description: 'Page number'
                        example: 20
                -
                    in: query
                    name: 'page[size]'
                    description: 'Number of records on a page'
                    example: 3
                    required: false
                    schema:
                        type: integer
                        description: 'Number of records on a page'
                        example: 3
                -
                    in: query
                    name: 'filter[search]'
                    description: 'Filter by query'
                    example: quis
                    required: false
                    schema:
                        type: string
                        description: 'Filter by query'
                        example: quis
                -
                    in: header
                    name: Authorization
                    description: ''
                    example: 'Bearer {YOUR_AUTH_KEY}'
                    schema:
                        type: string
                -
                    in: header
                    name: Content-Type
                    description: ''
                    example: application/json
                    schema:
                        type: string
                -
                    in: header
                    name: Accept
                    description: ''
                    example: application/json
                    schema:
                        type: string
            responses:
                401:
                    description: ''
                    content:
                        application/json:
                            schema:
                                type: object
                                example:
                                    message: Unauthenticated.
                                properties:
                                    message: { type: string, example: Unauthenticated. }
            tags:
                - Products
        post:
            summary: 'Add a new product'
            description: ''
            parameters:
                -
                    in: header
                    name: Authorization
                    description: ''
                    example: 'Bearer {YOUR_AUTH_KEY}'
                    schema:
                        type: string
                -
                    in: header
                    name: Content-Type
                    description: ''
                    example: multipart/form-data
                    schema:
                        type: string
                -
                    in: header
                    name: Accept
                    description: ''
                    example: application/json
                    schema:
                        type: string
            responses: {  }
            tags:
                - Products
            requestBody:
                required: true
                content:
                    multipart/form-data:
                        schema:
                            type: object
                            properties:
                                title:
                                    type: string
                                    description: 'Product Title'
                                    example: quod
                                description:
                                    type: string
                                    description: 'Product description'
                                    example: provident
                                price:
                                    type: integer
                                    description: 'Product price'
                                    example: 3
                                category_id:
                                    type: integer
                                    description: 'Product category'
                                    example: 18
                                discount_price:
                                    type: integer
                                    description: 'Discounted price'
                                    example: 19
                                discount_percentage:
                                    type: number
                                    description: 'Discount Percentage'
                                    example: 362927.2
                                start_date:
                                    type: Date
                                    description: 'Discount Start Date'
                                    example: beatae
                                start_time:
                                    type: Time
                                    description: 'Discount Start Time'
                                    example: sint
                                expiry_date:
                                    type: Date
                                    description: 'Discount Expiry Date'
                                    example: ea
                                expiry_time:
                                    type: Time
                                    description: 'Discount Expiry Time'
                                    example: sit
                                image:
                                    type: string
                                    format: binary
                                    description: 'Product image'
                            required:
                                - title
                                - price
                                - category_id
    '/api/products/{product}':
        get:
            summary: 'Get single product details'
            description: ''
            parameters:
                -
                    in: header
                    name: Authorization
                    description: ''
                    example: 'Bearer {YOUR_AUTH_KEY}'
                    schema:
                        type: string
                -
                    in: header
                    name: Content-Type
                    description: ''
                    example: application/json
                    schema:
                        type: string
                -
                    in: header
                    name: Accept
                    description: ''
                    example: application/json
                    schema:
                        type: string
            responses:
                401:
                    description: ''
                    content:
                        application/json:
                            schema:
                                type: object
                                example:
                                    message: Unauthenticated.
                                properties:
                                    message: { type: string, example: Unauthenticated. }
            tags:
                - Products
        put:
            summary: 'Update a product'
            description: ''
            parameters:
                -
                    in: header
                    name: Authorization
                    description: ''
                    example: 'Bearer {YOUR_AUTH_KEY}'
                    schema:
                        type: string
                -
                    in: header
                    name: Content-Type
                    description: ''
                    example: multipart/form-data
                    schema:
                        type: string
                -
                    in: header
                    name: Accept
                    description: ''
                    example: application/json
                    schema:
                        type: string
            responses: {  }
            tags:
                - Products
            requestBody:
                required: true
                content:
                    multipart/form-data:
                        schema:
                            type: object
                            properties:
                                title:
                                    type: string
                                    description: 'Product Title'
                                    example: sed
                                description:
                                    type: string
                                    description: 'Product description'
                                    example: dignissimos
                                price:
                                    type: integer
                                    description: 'Product price'
                                    example: 5
                                category_id:
                                    type: integer
                                    description: 'Product category'
                                    example: 20
                                discount_price:
                                    type: integer
                                    description: 'Discounted price'
                                    example: 5
                                discount_percentage:
                                    type: number
                                    description: 'Discount Percentage'
                                    example: !!float 40
                                start_date:
                                    type: Date
                                    description: 'Discount Start Date'
                                    example: fuga
                                start_time:
                                    type: Time
                                    description: 'Discount Start Time'
                                    example: omnis
                                expiry_date:
                                    type: Date
                                    description: 'Discount Expiry Date'
                                    example: repudiandae
                                expiry_time:
                                    type: Time
                                    description: 'Discount Expiry Time'
                                    example: qui
                                image_name:
                                    type: string
                                    description: 'Image name'
                                    example: est
                                image:
                                    type: string
                                    format: binary
                                    description: 'Product image'
                            required:
                                - title
                                - price
                                - category_id
                                - discount_price
                                - discount_percentage
                                - start_date
                                - start_time
                                - expiry_date
                                - expiry_time
        delete:
            summary: 'Delete a product'
            description: ''
            parameters:
                -
                    in: header
                    name: Authorization
                    description: ''
                    example: 'Bearer {YOUR_AUTH_KEY}'
                    schema:
                        type: string
                -
                    in: header
                    name: Content-Type
                    description: ''
                    example: application/json
                    schema:
                        type: string
                -
                    in: header
                    name: Accept
                    description: ''
                    example: application/json
                    schema:
                        type: string
            responses: {  }
            tags:
                - Products
        parameters:
            -
                in: path
                name: product
                description: 'Product id'
                example: 5
                required: true
                schema:
                    type: integer
    /api/history:
        get:
            summary: ''
            description: ''
            parameters:
                -
                    in: header
                    name: Content-Type
                    description: ''
                    example: application/json
                    schema:
                        type: string
                -
                    in: header
                    name: Accept
                    description: ''
                    example: application/json
                    schema:
                        type: string
            responses:
                401:
                    description: ''
                    content:
                        application/json:
                            schema:
                                type: object
                                example:
                                    message: Unauthenticated.
                                properties:
                                    message: { type: string, example: Unauthenticated. }
            tags:
                - Products
            security: []
    /api/populardistributors:
        get:
            summary: ''
            description: ''
            parameters:
                -
                    in: header
                    name: Content-Type
                    description: ''
                    example: application/json
                    schema:
                        type: string
                -
                    in: header
                    name: Accept
                    description: ''
                    example: application/json
                    schema:
                        type: string
            responses:
                401:
                    description: ''
                    content:
                        application/json:
                            schema:
                                type: object
                                example:
                                    message: Unauthenticated.
                                properties:
                                    message: { type: string, example: Unauthenticated. }
            tags:
                - Products
            security: []
    /api/loan-request:
        post:
            summary: 'Create a Loan request from solveIt'
            description: ''
            parameters:
                -
                    in: header
                    name: Authorization
                    description: ''
                    example: 'Bearer {YOUR_AUTH_KEY}'
                    schema:
                        type: string
                -
                    in: header
                    name: Content-Type
                    description: ''
                    example: application/json
                    schema:
                        type: string
                -
                    in: header
                    name: Accept
                    description: ''
                    example: application/json
                    schema:
                        type: string
            responses: {  }
            tags:
                - SolveIt
            requestBody:
                required: true
                content:
                    application/json:
                        schema:
                            type: object
                            properties:
                                dealer_id:
                                    type: string
                                    description: ''
                                    example: corrupti
                                bankName:
                                    type: string
                                    description: ''
                                    example: illum
                                branchName:
                                    type: string
                                    description: ''
                                    example: in
                                accountNumber:
                                    type: string
                                    description: ''
                                    example: architecto
                                accountName:
                                    type: string
                                    description: ''
                                    example: eius
                            required:
                                - dealer_id
                                - branchName
                                - accountNumber
                                - accountName
    /api/loan-inquiry:
        post:
            summary: 'Check loan status request from solveIt'
            description: ''
            parameters:
                -
                    in: header
                    name: Authorization
                    description: ''
                    example: 'Bearer {YOUR_AUTH_KEY}'
                    schema:
                        type: string
                -
                    in: header
                    name: Content-Type
                    description: ''
                    example: application/json
                    schema:
                        type: string
                -
                    in: header
                    name: Accept
                    description: ''
                    example: application/json
                    schema:
                        type: string
            responses: {  }
            tags:
                - SolveIt
            requestBody:
                required: false
                content:
                    application/json:
                        schema:
                            type: object
                            properties:
                                dealer_id:
                                    type: required
                                    description: ''
                                    example: dignissimos
                                loan_reference:
                                    type: required
                                    description: ''
                                    example: aut
    /api/users:
        get:
            summary: 'Show all users'
            description: ''
            parameters:
                -
                    in: query
                    name: 'page[number]'
                    description: 'Page number'
                    example: 17
                    required: false
                    schema:
                        type: integer
                        description: 'Page number'
                        example: 17
                -
                    in: query
                    name: 'page[size]'
                    description: 'Number of records on a page'
                    example: 15
                    required: false
                    schema:
                        type: integer
                        description: 'Number of records on a page'
                        example: 15
                -
                    in: query
                    name: 'filter[search]'
                    description: 'Filter by query'
                    example: recusandae
                    required: false
                    schema:
                        type: string
                        description: 'Filter by query'
                        example: recusandae
                -
                    in: header
                    name: Authorization
                    description: ''
                    example: 'Bearer {YOUR_AUTH_KEY}'
                    schema:
                        type: string
                -
                    in: header
                    name: Content-Type
                    description: ''
                    example: application/json
                    schema:
                        type: string
                -
                    in: header
                    name: Accept
                    description: ''
                    example: application/json
                    schema:
                        type: string
            responses:
                401:
                    description: ''
                    content:
                        application/json:
                            schema:
                                type: object
                                example:
                                    message: Unauthenticated.
                                properties:
                                    message: { type: string, example: Unauthenticated. }
            tags:
                - Users
        post:
            summary: 'Create a new user'
            description: ''
            parameters:
                -
                    in: header
                    name: Authorization
                    description: ''
                    example: 'Bearer {YOUR_AUTH_KEY}'
                    schema:
                        type: string
                -
                    in: header
                    name: Content-Type
                    description: ''
                    example: application/json
                    schema:
                        type: string
                -
                    in: header
                    name: Accept
                    description: ''
                    example: application/json
                    schema:
                        type: string
            responses: {  }
            tags:
                - Users
            requestBody:
                required: true
                content:
                    application/json:
                        schema:
                            type: object
                            properties:
                                first_name:
                                    type: string
                                    description: 'User''s first name'
                                    example: molestias
                                last_name:
                                    type: string
                                    description: 'User''s last name'
                                    example: aspernatur
                                email:
                                    type: string
                                    description: 'User''s email'
                                    example: qui
                                phone_number:
                                    type: string
                                    description: 'User''s phone number'
                                    example: eveniet
                                is_admin:
                                    type: boolean
                                    description: 'If user is an admin'
                                    example: true
                                permissions:
                                    type: array
                                    description: 'Permissions for non admin'
                                    example: '[''sales'',''orders'']'
                            required:
                                - first_name
                                - last_name
                                - email
                                - phone_number
                                - is_admin
    '/api/users/{user}':
        get:
            summary: 'Get single user details'
            description: ''
            parameters:
                -
                    in: header
                    name: Authorization
                    description: ''
                    example: 'Bearer {YOUR_AUTH_KEY}'
                    schema:
                        type: string
                -
                    in: header
                    name: Content-Type
                    description: ''
                    example: application/json
                    schema:
                        type: string
                -
                    in: header
                    name: Accept
                    description: ''
                    example: application/json
                    schema:
                        type: string
            responses:
                401:
                    description: ''
                    content:
                        application/json:
                            schema:
                                type: object
                                example:
                                    message: Unauthenticated.
                                properties:
                                    message: { type: string, example: Unauthenticated. }
            tags:
                - Users
        put:
            summary: 'Update user details.'
            description: ''
            parameters:
                -
                    in: header
                    name: Authorization
                    description: ''
                    example: 'Bearer {YOUR_AUTH_KEY}'
                    schema:
                        type: string
                -
                    in: header
                    name: Content-Type
                    description: ''
                    example: application/json
                    schema:
                        type: string
                -
                    in: header
                    name: Accept
                    description: ''
                    example: application/json
                    schema:
                        type: string
            responses: {  }
            tags:
                - Users
            requestBody:
                required: true
                content:
                    application/json:
                        schema:
                            type: object
                            properties:
                                first_name:
                                    type: string
                                    description: 'User''s first name'
                                    example: et
                                last_name:
                                    type: string
                                    description: 'User''s last name'
                                    example: ad
                                phone_number:
                                    type: string
                                    description: 'User''s phone number'
                                    example: ab
                                is_admin:
                                    type: boolean
                                    description: 'If user is an admin'
                                    example: false
                                permissions:
                                    type: array
                                    description: 'Permissions for non admin'
                                    example: '[''sales'',''orders'']'
                                email:
                                    type: string
                                    description: 'User''s email'
                                    example: voluptas
                            required:
                                - first_name
                                - last_name
                                - phone_number
                                - is_admin
                                - email
        delete:
            summary: 'Deactivate a user'
            description: ''
            parameters:
                -
                    in: header
                    name: Authorization
                    description: ''
                    example: 'Bearer {YOUR_AUTH_KEY}'
                    schema:
                        type: string
                -
                    in: header
                    name: Content-Type
                    description: ''
                    example: application/json
                    schema:
                        type: string
                -
                    in: header
                    name: Accept
                    description: ''
                    example: application/json
                    schema:
                        type: string
            responses: {  }
            tags:
                - Users
        parameters:
            -
                in: path
                name: user
                description: 'User''s id'
                example: 3
                required: true
                schema:
                    type: integer
    /api/wallets/balance:
        get:
            summary: 'Wallet Balances'
            description: ''
            parameters:
                -
                    in: header
                    name: Authorization
                    description: ''
                    example: 'Bearer {YOUR_AUTH_KEY}'
                    schema:
                        type: string
                -
                    in: header
                    name: Content-Type
                    description: ''
                    example: application/json
                    schema:
                        type: string
                -
                    in: header
                    name: Accept
                    description: ''
                    example: application/json
                    schema:
                        type: string
            responses:
                401:
                    description: ''
                    content:
                        application/json:
                            schema:
                                type: object
                                example:
                                    message: Unauthenticated.
                                properties:
                                    message: { type: string, example: Unauthenticated. }
            tags:
                - Wallets
    /api/wallets/transactions:
        get:
            summary: 'List of wallet transactions'
            description: ''
            parameters:
                -
                    in: query
                    name: 'page[number]'
                    description: 'Page number'
                    example: 16
                    required: false
                    schema:
                        type: integer
                        description: 'Page number'
                        example: 16
                -
                    in: query
                    name: 'page[size]'
                    description: 'Number of records on a pag'
                    example: 19
                    required: false
                    schema:
                        type: integer
                        description: 'Number of records on a pag'
                        example: 19
                -
                    in: header
                    name: Authorization
                    description: ''
                    example: 'Bearer {YOUR_AUTH_KEY}'
                    schema:
                        type: string
                -
                    in: header
                    name: Content-Type
                    description: ''
                    example: application/json
                    schema:
                        type: string
                -
                    in: header
                    name: Accept
                    description: ''
                    example: application/json
                    schema:
                        type: string
            responses:
                401:
                    description: ''
                    content:
                        application/json:
                            schema:
                                type: object
                                example:
                                    message: Unauthenticated.
                                properties:
                                    message: { type: string, example: Unauthenticated. }
            tags:
                - Wallets
    /api/wallets/withdraw:
        put:
            summary: 'Withdraw from wallet Example: 200'
            description: ''
            parameters:
                -
                    in: header
                    name: Authorization
                    description: ''
                    example: 'Bearer {YOUR_AUTH_KEY}'
                    schema:
                        type: string
                -
                    in: header
                    name: Content-Type
                    description: ''
                    example: application/json
                    schema:
                        type: string
                -
                    in: header
                    name: Accept
                    description: ''
                    example: application/json
                    schema:
                        type: string
            responses: {  }
            tags:
                - Wallets
            requestBody:
                required: true
                content:
                    application/json:
                        schema:
                            type: object
                            properties:
                                amount:
                                    type: integer
                                    description: 'Amount to withdraw'
                                    example: 6
                            required:
                                - amount
    /api/wallets/pay-loan:
        put:
            summary: 'Pay loan from wallet'
            description: ''
            parameters:
                -
                    in: header
                    name: Authorization
                    description: ''
                    example: 'Bearer {YOUR_AUTH_KEY}'
                    schema:
                        type: string
                -
                    in: header
                    name: Content-Type
                    description: ''
                    example: application/json
                    schema:
                        type: string
                -
                    in: header
                    name: Accept
                    description: ''
                    example: application/json
                    schema:
                        type: string
            responses: {  }
            tags:
                - Wallets
            requestBody:
                required: true
                content:
                    application/json:
                        schema:
                            type: object
                            properties:
                                amount:
                                    type: integer
                                    description: 'Amount to pay'
                                    example: 200
                            required:
                                - amount
    /api/wallets/topup:
        post:
            summary: 'Topup wallet'
            description: ''
            parameters:
                -
                    in: header
                    name: Authorization
                    description: ''
                    example: 'Bearer {YOUR_AUTH_KEY}'
                    schema:
                        type: string
                -
                    in: header
                    name: Content-Type
                    description: ''
                    example: application/json
                    schema:
                        type: string
                -
                    in: header
                    name: Accept
                    description: ''
                    example: application/json
                    schema:
                        type: string
            responses: {  }
            tags:
                - Wallets
            requestBody:
                required: true
                content:
                    application/json:
                        schema:
                            type: object
                            properties:
                                amount:
                                    type: integer
                                    description: 'Amount to topup: 200'
                                    example: 19
                            required:
                                - amount
    /api/documents:
        get:
            summary: 'Get user documents'
            description: ''
            parameters:
                -
                    in: header
                    name: Authorization
                    description: ''
                    example: 'Bearer {YOUR_AUTH_KEY}'
                    schema:
                        type: string
                -
                    in: header
                    name: Content-Type
                    description: ''
                    example: application/json
                    schema:
                        type: string
                -
                    in: header
                    name: Accept
                    description: ''
                    example: application/json
                    schema:
                        type: string
            responses:
                401:
                    description: ''
                    content:
                        application/json:
                            schema:
                                type: object
                                example:
                                    message: Unauthenticated.
                                properties:
                                    message: { type: string, example: Unauthenticated. }
            tags:
                - profile
        post:
            summary: 'Download documents'
            description: ''
            parameters:
                -
                    in: header
                    name: Authorization
                    description: ''
                    example: 'Bearer {YOUR_AUTH_KEY}'
                    schema:
                        type: string
                -
                    in: header
                    name: Content-Type
                    description: ''
                    example: application/json
                    schema:
                        type: string
                -
                    in: header
                    name: Accept
                    description: ''
                    example: application/json
                    schema:
                        type: string
            responses: {  }
            tags:
                - profile
            requestBody:
                required: true
                content:
                    application/json:
                        schema:
                            type: object
                            properties:
                                file_name:
                                    type: string
                                    description: 'File Name'
                                    example: cum
                            required:
                                - file_name
    /api/invite-friend:
        post:
            summary: 'Send invitation message'
            description: ''
            parameters:
                -
                    in: header
                    name: Authorization
                    description: ''
                    example: 'Bearer {YOUR_AUTH_KEY}'
                    schema:
                        type: string
                -
                    in: header
                    name: Content-Type
                    description: ''
                    example: application/json
                    schema:
                        type: string
                -
                    in: header
                    name: Accept
                    description: ''
                    example: application/json
                    schema:
                        type: string
            responses: {  }
            tags:
                - profile
            requestBody:
                required: true
                content:
                    application/json:
                        schema:
                            type: object
                            properties:
                                phone_number:
                                    type: string
                                    description: 'Phone number'
                                    example: alias
                            required:
                                - phone_number
components:
    securitySchemes:
        default:
            type: http
            scheme: bearer
            description: ''
security:
    -
        default: []
